/* ---- GLOBAL STYLE ---- */

:root {
  --bg: #ffffff;
  --text: #111111;
  --accent: #26541a;
  --article: #a93737;
  --date: #3f1414;
  --menu-bg: #e7c29f;
  --max-width: 2000px;
  --font-serif: "Times New Roman", serif;
}

body {
  margin: 0;
  font-size: 1.3rem;
  font-family: var(--font-serif);
  background: var(--bg);
  color: var(--text);
  line-height: 1.4;
}

/* Container just constrains width if needed later */
.container {
  max-width: var(--max-width);
  padding: 0;
}

/* ---- SKIP LINK (ACCESSIBILITY) ---- */

.skip-link {
  position: absolute;
  left: 0;
  top: 0;
  transform: translateY(-200%);
  background: var(--bg);
  color: var(--text);
  padding: 0.5rem 1rem;
  z-index: 1000;
  text-decoration: none;
  border: 2px solid var(--accent);
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.skip-link:focus-visible {
  transform: translateY(0);
  clip: auto;
}


/* ---- FOCUS STYLES (ACCESSIBILITY) ---- */

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ---- HEADER ---- */

header {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

header h1 {
  font-size: 4rem;
  margin: 0.2rem 0 0;
  padding-left: 1rem;
}

/* Hide the desktop nav completely; side-menu is main nav */
.top-nav {
  display: none !important;
}

/* ---- HAMBURGER TOGGLE ---- */

.menu-toggle {
  position: fixed;
  top: 1rem;
  right: 1.5rem;
  font-size: 3rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--accent);
  z-index: 200;
}

/* ---- RIGHT SIDE MENU ---- */

.side-menu {
  position: fixed;
  top: 0;
  right: -500px; /* completely off-screen */
  width: 320px;
  height: 100vh;
  background: var(--menu-bg);
  padding-top: 6rem;
  padding-left: 2.5rem;
  padding-right: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 2.2rem;
  transition: right 0.35s ease-in-out;
  z-index: 150;
}

.side-menu.open {
  right: 0;
}

.side-menu a {
  font-size: 2.4rem;
  color: var(--accent);
  text-decoration: none;
}

.side-menu a:hover,
.side-menu a.active {
  text-decoration: underline;
}

/* ---- MAIN CONTENT ---- */

main {
  padding: 0 1rem;
}

/* ---- SECTION IMAGES ---- */

section img {
  width: 100%;
  border-radius: 4px;
  margin: 1.2rem 0;
}

/* ---- ARTICLE LIST (WRITING PAGE) ---- */

.entry {
  display: flex;
  gap: 2rem;
  align-items: baseline;
  margin-top: 1rem;
}

.date {
  font-size: 2rem;
  font-weight: bold;
  color: var(--date);
  white-space: nowrap;
}

.entry-text {
  display: flex;
  flex-direction: column;
}

.article {
  font-size: 2.8rem;
  color: var(--article);
  text-decoration: none;
}

.article:hover {
  text-decoration: underline;
}

/* Article metadata under titles */

.meta {
  font-size: 1.6rem;
  margin-top: 0.4rem;
  color: var(--accent);
  display: flex;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.meta a {
  color: #a06d3f; /* beige/orange tone */
  text-decoration: underline;
  font-weight: 500;
  text-shadow: 0.15px 0 currentColor; /* “medium bold” */
}

.meta a:hover {
  opacity: 0.6;
}

/* ---- ARTICLE IMAGES (INSIDE ARTICLES) ---- */

.article-images {
  margin: 1.5rem 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.article-images figure {
  margin: 0;
}

.article-images img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 2px;
}

.article-images figcaption {
  font-size: 1.2rem;
  color: #555;
  margin-top: 0.25rem;
}

/* Full-width “hero” style image option */
.full-width-image img {
  width: 100%;
}

/* Smaller “supporting” image option for inline content */
.supporting-image img {
  width: 70%;
  margin-left: auto;
  margin-right: auto;
}

/* Footer */

footer {
  margin-top: 5rem;
  margin-left: 0;
  font-size: 1.3rem;
  color: var(--accent);
}


/* --- Writing list: responsive layout --- */
.entry{
  display: flex;
  align-items: flex-start;
  gap: 2rem;
}

/* date column */
.entry .date{
  flex: 0 0 auto;
  white-space: nowrap;
}

/* text column */
.entry .entry-text{
  flex: 1 1 auto;
  min-width: 0; /* prevents overflow issues in flex */
}

/* nicer mobile layout */
@media (max-width: 600px){
  .entry{
    flex-direction: column;
    gap: 0.5rem;
  }

  .entry .date{
    font-size: 0.95rem;
    opacity: 0.9;
  }

  .entry a.article{
    font-size: 1.15rem;   /* smaller on phone */
    line-height: 1.25;
    text-decoration: underline;
  }

  .entry .meta{
    font-size: 0.95rem;
    line-height: 1.25;
  }
}

/* ---------------------------------------
   CURATION LIST LAYOUT
--------------------------------------- */

.curation-entry{
  display: flex;
  align-items: flex-start;
  gap: 2.5rem;
  margin-top: 1.2rem;
}

/* left date column */
.curation-dates{
  flex: 0 0 auto;
  min-width: 170px;
  color: var(--date);
}

.curation-date-top,
.curation-date-bottom{
  font-size: 2rem;
  font-weight: bold;
  white-space: nowrap;
}

.curation-arrow{
  font-size: 2.2rem;
  line-height: 1;
  margin: 0.4rem 0 0.6rem;
}

/* right content column */
.curation-main{
  flex: 1 1 auto;
  min-width: 0;
}

/* image row (3-up) */
.curation-images{
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 1rem;
  margin-top: 0.2rem;
  margin-bottom: 0.6rem;
}

/* IMPORTANT: override global section img { width:100% } behavior */
.curation-images img{
  width: 100%;
  height: 180px;          /* adjust to taste */
  object-fit: cover;
  border-radius: 2px;
  display: block;
  margin: 0;              /* override section img margin */
}

/* placeholders (if image paths missing) */
.curation-img.placeholder{
  width: 100%;
  height: 180px;
  background: #efefef;
  border: 1px solid #777;
}

/* title link */
.curation-title{
  font-size: 1.25rem;
  color: var(--article);
  text-decoration: none;
  display: inline-block;
}

.curation-title:hover{
  text-decoration: underline;
}

/* meta links reuse your existing .meta styling */
.curation-text .meta{
  margin-top: 0.4rem;
}

/* ---------------------------------------
   CURATION DETAIL PAGE HEADER (optional, but matches script output)
--------------------------------------- */

.curation-detail{
  margin: 1rem 0 1.5rem;
}

.curation-detail-dates{
  font-size: 1.8rem;
  font-weight: bold;
  color: var(--date);
  margin-bottom: 0.75rem;
}

.curation-detail-images{
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 1rem;
}

.curation-detail-images img{
  width: 100%;
  height: 220px;          /* slightly bigger on detail page */
  object-fit: cover;
  border-radius: 2px;
  display: block;
  margin: 0;
}

/* ---------------------------------------
   Mobile
--------------------------------------- */
@media (max-width: 800px){
  .curation-entry{
    flex-direction: column;
    gap: 0.8rem;
  }

  .curation-dates{
    min-width: 0;
  }

  .curation-date-top,
  .curation-date-bottom{
    font-size: 1.5rem;
  }

  .curation-arrow{
    font-size: 1.2rem;
    margin: 0.2rem 0 0.3rem;
  }

  .curation-images,
  .curation-detail-images{
    grid-template-columns: 1fr;
  }

  .curation-images img,
  .curation-img.placeholder{
    height: 170px;
  }

  .curation-detail-images img{
    height: 200px;
  }

  .curation-title{
    font-size: 1.25rem;
    line-height: 1.25;
    text-decoration: underline; /* match your mobile writing style */
  }

  .curation-text .meta{
    font-size: 0.95rem;   /* match writing tags size */
    line-height: 1.25;
    gap: 0.8rem;
  }

  .curation-text .meta a{
    font-size: inherit;   /* ensure links follow meta size */
  }

}
/* ---------------------------------------
   CURATION LIST LAYOUT (square thumbnails + dash)
--------------------------------------- */

.curation-entry{
  display: flex;
  align-items: flex-start;
  gap: 2.5rem;
  margin-top: 1.2rem;
}

/* left date column */
.curation-dates{
  flex: 0 0 auto;
  min-width: 170px;
  color: var(--date);
}

.curation-date-top,
.curation-date-bottom{
  font-size: 2rem;
  font-weight: bold;
  white-space: nowrap;
}

/* centered dash between dates */
.curation-sep{
  display: flex;
  align-items: center;
  justify-content: center;
  height: 2rem;          /* matches date text block height feel */
  font-size: 2.2rem;
  line-height: 1;
  margin: 0.25rem 0 0.35rem;
}

/* right content column */
.curation-main{
  flex: 1 1 auto;
  min-width: 0;
}

/* image row (3-up) */
.curation-images{
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 1rem;
  margin-top: 0.2rem;
  margin-bottom: 0.6rem;
}

/* IMPORTANT: override global section img { width:100%; margin:... } */
.curation-images img{
  width: 100%;
  aspect-ratio: 1 / 1;   /* SQUARE */
  height: auto;          /* lets aspect-ratio control it */
  object-fit: cover;
  border-radius: 2px;
  display: block;
  margin: 0;
}

/* placeholder squares */
.curation-img.placeholder{
  width: 100%;
  aspect-ratio: 1 / 1;   /* SQUARE */
  background: #efefef;
  border: 1px solid #ccc;
}

/* title link */
.curation-title{
  font-size: 2.8rem;
  color: var(--article);
  text-decoration: none;
  display: inline-block;
}

.curation-title:hover{
  text-decoration: underline;
}

/* meta links reuse your existing .meta styling */
.curation-text .meta{
  margin-top: 0.4rem;
}

/* ---------------------------------------
   CURATION DETAIL PAGE HEADER (optional, but matches script output)
   Also square thumbnails.
--------------------------------------- */

.curation-detail{
  margin: 1rem 0 1.5rem;
}

.curation-detail-dates{
  font-size: 1.8rem;
  font-weight: bold;
  color: var(--date);
  margin-bottom: 0.75rem;
}

.curation-detail-images{
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 1rem;
}

.curation-detail-images img{
  width: 100%;
  aspect-ratio: 1 / 1;   /* SQUARE */
  height: auto;
  object-fit: cover;
  border-radius: 2px;
  display: block;
  margin: 0;
}

/* ---------------------------------------
   Mobile
--------------------------------------- */
@media (max-width: 800px){
  .curation-entry{
    flex-direction: column;
    gap: 0.8rem;
  }

  .curation-dates{
    min-width: 0;
  }

  .curation-date-top,
  .curation-date-bottom{
    font-size: 1.1rem;
  }

  .curation-sep{
    font-size: 1.2rem;
    height: 1.2rem;
    margin: 0.15rem 0 0.2rem;
  }

  .curation-images,
  .curation-detail-images{
    grid-template-columns: 1fr;
  }

  .curation-title{
    font-size: 1.4rem;
    line-height: 1.25;
    text-decoration: underline;
  }
}


.md-figure{
  margin: 1.2rem 0;
}

.md-figure img{
  display: block;
  width: 100%;
  margin: 0; /* override section img margin behavior */
}

.md-figure figcaption{
  margin-top: 0.4rem;
  font-size: 0.95rem;
  line-height: 1.35;
  color: #444;
}
