/********** COLOR VARIABLES **********/
/* DEFAULT PALETTE */
:root:not(.dark-mode) {
  --palette-text: hsl(0, 100%, 7%);
  --palette-heading: hsl(28, 96%, 22%);
  --palette-link: hsl(154, 58%, 29%);
  --palette-link-hover-background: hsl(43, 100%, 88%);
  --palette-link-red: hsl(0, 58%, 42%);
  --palette-border: hsl(24 44% 48%);
  --palette-background-body: hsl(23, 50%, 80%);
  --palette-background-containers: hsl(30, 60%, 90%);
}

/* DARK MODE PALETTE PALETTE */
:root.dark-mode {
  --palette-text: hsl(27 59% 66%);
  --palette-heading: hsl(27 100% 92%);
  --palette-link: hsl(149 31% 55%);
  --palette-link-hover-background: hsl(28 54% 35%);
  --palette-link-red: hsl(9 47% 65%);
  --palette-border: hsl(31 89% 22%);
  --palette-background-body: hsl(9 50% 10%);
  --palette-background-containers: hsl(17 100% 4%);
}

/* CSS is how you can add style to your website, such as colors, fonts, and positioning of your
   HTML content. To learn how to do something, just try searching Google for questions like
   "how to change link color." */

body {
  background-color: var(--palette-background-body);
  color: var(--palette-text);
  font-size: 1rem;
  font-family: sans-serif;
  margin: 0;
}

p {
  line-height: 1.6em; /*I find the default HTML line-height tends to be a bit claustrophobic for main text*/
}

a {
  color: var(--palette-link);
  text-decoration: underline;
}
a:hover {
  background-color: var(--palette-link-hover-background);
}

h1,
h2,
h3,
h4,
h5 {
  color: var(--palette-heading);
  padding: 5px;
}

h1 {
  background-color: var(--palette-background-body);
  border-radius: 10px;
  border-bottom: none;
}

hr {
  border: solid var(--palette-border);
  border-width: 2px 0 0 0;
}

ul {
  list-style-type: "\2600   ";
  list-style-position: inside;
}

img {
  max-width: 100%;
  height: auto;
  margin-top: 0.5em;
  margin-bottom: 0.5em;
}
.right {
  float: right;
  margin-left: 1em;
}
.left {
  float: left;
  margin-right: 1em;
}
.center {
  display: block;
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.caption {
  margin-top: 0;
  font-size: 0.9em;
  font-style: italic;
}

.logo-image {
  border-radius: 0 10px 10px 0;
  border: 2px solid var(--mainborder);
  max-width: 98px;
  max-height: 98px;
  background-color: var(--mainbg);
}

/*#CONTAINER is the rectangle that has contains everything but the background!*/
#container {
  margin: 3em auto;
  width: 90%;
  max-width: 700px;
  background-color: var(--palette-background-containers);
  outline-color: var(--palette-border);
  outline-style: ridge;
  outline-width: 6px;
  outline-offset: 0;
}

#content {
  padding: 10px 5% 20px 5%;
}

/*HEADER STYLE*/
#header {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  background-color: var(--palette-border);
  padding: 0 5%;
  border-color: var(--palette-border);
  border-style: ridge;
  border-width: 0 0 6px 0;
}
#header ul {
  list-style-type: none;
  padding: 0.5em 0;
  margin: 0;
}
#header li {
  font-size: 1.2em;
  display: inline-block;
  margin-right: 1.5em;
  margin-bottom: 0.2em;
  margin-top: 0.2em;
}
#header li a {
  color: wheat;
  text-decoration: none;
}
#header li a:hover {
  text-decoration: underline;
  background-color: transparent;
}

#header button {
  border: none;
  border-radius: 10px;
  background-color: var(--palette-background-containers);
  color: var(--palette-heading);
  cursor: pointer;
  font-size: 1rem;
  padding: 15px 20px;
}

#header button:hover {
  background-color: var(--palette-background-body);
}

.header-right {
  display: flex;
  flex-direction: row;
  gap: 10px;
  align-items: center;
}

/*POST LIST STYLE*/
#postlistdiv ul {
  font-size: 1.2em;
  padding: 0;
}
#recentpostlistdiv ul {
  font-size: 1.2em;
  padding: 0;
}
.moreposts {
  font-size: 0.8em;
  margin-top: 0.2em;
}

/*NEXT AND PREVIOUS LINKS STYLE*/
#nextprev {
  text-align: center;
  margin-top: 1.4em;
}

/* MEDIA QUERY */
@media only screen and (min-width: 600px) {
  .small {
    max-width: 60%;
    height: auto;
  }
}

@media (max-width: 480px) {
  .header-right {
    flex-direction: column;
  }
}
