/* =========================================================
   1. Variables
========================================================= */
:root {
  --bg: #faf8f5;
  --text: #1d1d1d;
  --muted: #6f6f6f;
  --accent: #b89b5e;
  --sand: #e8dccb;
  --ocean: #2c5f73;
  --palm: #3d5a40;
  --white: #ffffff;
  --shadow-soft: 0 12px 30px rgba(29, 29, 29, 0.08);
  --shadow-card: 0 18px 40px rgba(29, 29, 29, 0.12);
  --radius: 1.1rem;
  --radius-sm: 0.75rem;
  --max-width: 1200px;
  --space-1: clamp(0.5rem, 1vw, 0.8rem);
  --space-2: clamp(0.9rem, 1.8vw, 1.2rem);
  --space-3: clamp(1.2rem, 2vw, 1.8rem);
  --space-4: clamp(1.8rem, 3vw, 2.8rem);
  --space-5: clamp(2.6rem, 4vw, 4rem);
  --space-6: clamp(3.8rem, 7vw, 7rem);
  --font-heading: "Cormorant Garamond", Georgia, serif;
  --font-body: "Inter", system-ui, sans-serif;
  --nav-height: 86px;
  --transition: 280ms ease;
}

html[data-theme="light"] {
  --bg: #faf8f5;
  --text: #1d1d1d;
  --muted: #6f6f6f;
  --accent: #b89b5e;
  --sand: #e8dccb;
  --ocean: #2c5f73;
  --palm: #3d5a40;
  --white: #ffffff;
  --surface: rgba(255, 255, 255, 0.72);
  --card-bg: #f3e6d7;
  --product-card-gradient-start: #b89b5e;
  --product-card-gradient-end: #f3e6d7;
}

html[data-theme="dark"] {
  --bg: #081a14;
  --text: #f6efe2;
  --muted: #c5d5cd;
  --accent: #67b6c9;
  --sand: #f1e7d4;
  --ocean: #2f8aa3;
  --palm: #0f3a2e;
  --white: #10281f;
  --surface: rgba(16, 40, 31, 0.68);
  --card-bg: rgba(19, 49, 38, 0.72);
  --product-card-gradient-start: #f1e7d4;
  --product-card-gradient-end: #1b4c3c;
  --shadow-soft: 0 14px 34px rgba(0, 0, 0, 0.46);
  --shadow-card: 0 20px 48px rgba(0, 0, 0, 0.58);
}

/* =========================================================
   2. Reset
========================================================= */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body,
h1, h2, h3, h4, p,
ul {
  margin: 0;
}

img {
  display: block;
  width: 100%;
  max-width: 100%;
  border-radius: var(--radius-sm);
}

ul {
  padding: 0;
  list-style: none;
}

a {
  text-decoration: none;
  color: inherit;
}

button,
input {
  font: inherit;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
}

html[data-theme="light"] body {
  background:
    radial-gradient(72rem 40rem at 8% -10%, rgba(232, 203, 39, 0.605), transparent 62%),
    radial-gradient(54rem 30rem at 88% -12%, rgba(70, 169, 202, 0.647), transparent 64%),
    radial-gradient(46rem 28rem at 24% 52%, rgba(225, 204, 175, 0.286), transparent 68%),
    radial-gradient(34rem 22rem at 78% 64%, rgba(146, 197, 212, 0.379), transparent 72%),
    radial-gradient(42rem 24rem at 16% 76%, rgba(201, 147, 99, 0.317), transparent 70%),
    radial-gradient(30rem 20rem at 86% 86%, rgba(165, 119, 86, 0.398), transparent 72%),
    linear-gradient(180deg, #faf5ee 0%, #f6efe3 54%, #f2e9dc 100%);
  background-attachment: fixed;
}

html[data-theme="dark"] body {
  background:
    radial-gradient(76rem 44rem at 6% -10%, rgba(80, 190, 130, 0.34), transparent 60%),
    radial-gradient(62rem 36rem at 88% -12%, rgba(54, 164, 232, 0.32), transparent 62%),
    radial-gradient(54rem 34rem at 18% 32%, rgba(36, 138, 96, 0.24), transparent 66%),
    radial-gradient(50rem 30rem at 78% 38%, rgba(35, 170, 235, 0.24), transparent 68%),
    radial-gradient(44rem 30rem at 50% 118%, rgba(241, 231, 212, 0.14), transparent 70%),
    radial-gradient(38rem 22rem at 38% 72%, rgba(44, 156, 111, 0.2), transparent 72%),
    linear-gradient(180deg, #071a14 0%, #092119 52%, #0b241d 100%);
  background-attachment: fixed;
}

:focus-visible {
  outline: 2px solid var(--ocean);
  outline-offset: 3px;
}

/* =========================================================
   3. Typography
========================================================= */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  line-height: 1.1;
  letter-spacing: 0.01em;
  font-weight: 600;
}

h1 {
  font-size: clamp(2.4rem, 6vw, 5rem);
}

h2 {
  font-size: clamp(1.9rem, 4vw, 3.2rem);
}

h3 {
  font-size: clamp(1.25rem, 2.3vw, 1.8rem);
}

p {
  font-family: "Lora", serif;
  color: var(--muted);
  font-size: clamp(0.98rem, 1.5vw, 1.08rem);
}


.eyebrow {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

.section-head {
  max-width: 680px;
  margin: 0 auto var(--space-5);
  text-align: center;
}

/* =========================================================
   4. Layout
========================================================= */
.section {
  width: min(var(--max-width), 92vw);
  margin-inline: auto;
  padding: var(--space-6) 0;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--text);
  color: var(--white);
  padding: 0.6rem 0.9rem;
  z-index: 1000;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.82rem 1.4rem;
  border: 1px solid transparent;
  transition: transform var(--transition), background var(--transition), color var(--transition), border-color var(--transition);
  cursor: pointer;
  min-height: 46px;
  font-weight: 600;
}

.btn-primary {
  background: linear-gradient(135deg, #1f8f4e 0%, #2bbf6a 55%, #47d985 100%);
  color: #ffffff;
  box-shadow: 0 10px 22px rgba(31, 143, 78, 0.28);
  border: none; 
  cursor: pointer;
}

.btn-primary:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, #27a95b 0%, #39cf77 52%, #6aeba2 100%);
  box-shadow: 0 14px 30px rgba(57, 207, 119, 0.38);
}

.btn-ghost {
  border-color: rgba(255, 255, 255, 0.6);
  color: #f7ead8;
  backdrop-filter: blur(2px);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.14);
}

.text-link {
  color: var(--ocean);
  font-weight: 600;
  position: relative;
}

.text-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.2rem;
  width: 100%;
  height: 1px;
  background: var(--ocean);
  transform: scaleX(0.6);
  transform-origin: left;
  transition: transform var(--transition);
}

.text-link:hover::after {
  transform: scaleX(1);
}


/* =======================================================
Highlights
==========================================================*/

.highlighted-box-gradient-pink {
    background: linear-gradient(to left, #f8d3e0, #e361a2); 
    border-radius: 10px; 
    padding: 15px; 
    margin: 20px 0; 
    color: #000; 
}

.highlighted-box-gradient-purple {
    background: linear-gradient(to left, #e2d3f3, #956edf); 
    border-radius: 10px; 
    padding: 15px; 
    margin: 20px 0; 
    color: #000; }

.highlighted-box-gradient-blue {
    background: linear-gradient(to left, #cce5ff, #52c7f9); 
    border-radius: 10px; 
    padding: 15px; 
    margin: 20px 0; 
    color: #000; }

.highlighted-box-gradient-green {
    background: linear-gradient(to left, #d4edda, #5cc975); 
    border-radius: 10px; 
    padding: 15px; 
    margin: 20px 0; 
    color: #000; }

.highlighted-box-gradient-orange {
    background: linear-gradient(to left, #f4e1c1, #f9c873); 
    border-radius: 10px; 
    padding: 15px; 
    margin: 20px 0; 
    color: #000; }

.highlighted-box-gradient-yellow {
    background: linear-gradient(to left, #fffdd1, #f5ef77); 
    border-radius: 10px; 
    padding: 15px; 
    margin: 20px 0; 
    color: #000; }



/* =========================================================
   Blog Layouts
========================================================= */

/* side by side images */
/* DESKTOP: 2 images side-by-side */
.row.my-4 {
    display: flex;
    justify-content: center;
    gap: 10px; /* space between images */
}

.column {
    flex: 1;                     /* Each takes 50% */
    display: flex;
    justify-content: center;
}

.column img.landscape {
    width: auto;                /* keep natural size */
    max-width: 100%;            /* prevent overflow */
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* MOBILE: Stack the columns */
@media screen and (max-width: 600px) {
    .row.my-4 {
        flex-direction: column;   /* STACK the images */
        align-items: center;      /* center them */
    }

    .column {
        width: 100%;              /* full width */
        margin-bottom: 15px;
    }
}


/* end side by side images */

/* -------------------------------------- */
/* Image Styles for Side-by-Side with Text */
/* -------------------------------------- */

/* Horizontal images */
.image-left,
.image-right {
  width: 70%;          /* Adjust width as necessary */
  height: auto;        /* Maintain aspect ratio */
  border-radius: 8px;
}

/* Left vs Right margin spacing */
.image-left { margin-right: 5px; }
.image-right { margin-left: 5px; }

/* Vertical images */
.image-left-vertical,
.image-right-vertical {
  width: auto;          /* scale width naturally */
  max-height: 500px;    /* limit vertical height */
  height: auto;         /* maintain aspect ratio */
  border-radius: 8px;
}

/* Left vs Right margin spacing for vertical images */
.image-left-vertical { margin-right: 5px; }
.image-right-vertical { margin-left: 5px; }


/* Image Left / Text Right Container */
.image-left-text-right {
  display: flex;        /* Horizontal alignment */
  align-items: center;  /* Vertical center */
}

.text-right {
  width: 50%;           /* Adjust width as necessary */
  padding-left: 30px;    /* Space between text and image */
}


/* Text Left / Image Right Container */
.text-left-image-right {
  display: flex;        /* Horizontal alignment */
  align-items: center;  /* Vertical center */
}

.text-left {
  width: 50%;           /* Adjust width as necessary */
  padding-right: 5px;   /* Space between text and image */
}


/* Responsive Layout for Mobile (≤600px) */
@media screen and (max-width: 600px) {

  /* Stack containers vertically */
  .image-left-text-right,
  .text-left-image-right {
      flex-direction: column;
      align-items: center;
  }

  /* Horizontal images scale full width */
  .image-left,
  .image-right {
      width: 80%;
      height: auto;          /* keep aspect ratio */
      margin: 0 0 10px 0;
  }

  /* Vertical images scale full width, no distortion */
  .image-left-vertical,
  .image-right-vertical {
      width: 60%;
      height: auto;          /* maintain natural aspect ratio */
      max-height: 80vh;      /* limit to 80% of viewport height */
      margin: 0 0 10px 0;
  }

  /* Text boxes full width */
  .text-left,
  .text-right {
      width: 80%;
      padding-left: 0;
      padding-right: 0;
  }

  /* Optional: add some horizontal padding inside text */
  .text-left { padding-left: 30px; }
  .text-right { padding-left: 30px; }

}

  

/* Side by Side picture layout */
  .column {
    float: left;
    width: 50%;
    padding: 5px;
  }
  
  /* Clearfix (clear floats) */
  .row::after {
    content: "";
    clear: both;
    display: table;
  }
  
  /* Responsive layout - makes the three columns stack on top of each other instead of next to each other */
  @media screen and (max-width: 500px) {
    .column {
      width: 100%;
    }
  }

/* END Side by Side picture layout */


/* Landscape Image Styles */
.landscape {
  width: 100%; /* Full width of the column */
  height: auto; /* Maintain aspect ratio */
  object-fit: cover; /* Cover the area without stretching */
  border-radius: 8px; /* Optional: Add rounded corners */
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Optional: Add a subtle shadow */
  margin-bottom: 10px; /* Space below the image */
}

/* Responsive adjustments for landscape images */
@media screen and (max-width: 768px) {
  .landscape {
      width: 100%; /* Ensure full width on smaller screens */
  }
}
/* END Landscape Image Styles */


/* Vertical Image Styles */
.big-vertical-image {
  width: 100%; /* Full width of the container */
  height: auto; /* Maintain aspect ratio */
  object-fit: cover; /* Cover the area without stretching */
  border-radius: 8px; /* Optional: Add rounded corners */
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Optional: Add a subtle shadow */
  margin-bottom: 10px; /* Space below the image */
}

/* Centering the vertical image */
.big-vertical-imgae-container {
  display: flex; /* Use flexbox for centering */
  justify-content: center; /* Center horizontally */
  align-items: center; /* Center vertically */
  height: 75%; /* Optional: Set a height for the container */
}

/* Responsive adjustments for vertical images */
@media screen and (max-width: 768px) {
  .big-vertical-image {
      width: 100%; /* Ensure full width on smaller screens */
  }
}

/* END Vertical Image Styles */


/* Vertical Image Styles */
.vertical {
  width: 50%;            /* Image will take up half the container */
  max-width: 350px;      /* Prevents huge vertical images */
  height: auto;          /* Maintain aspect ratio */
  object-fit: cover;     /* Neatly fills the box without distortion */
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  margin-bottom: 10px;
}

/* Centering Container */
.vertical-container {
  display: flex;
  justify-content: center;
  align-items: center;
  height: auto;          /* Remove forced height to prevent squishing */
  padding: 20px 0;       /* Add soft spacing */
}

/* Responsive: Image becomes larger on small screens */
@media screen and (max-width: 768px) {
  .vertical {
      width: 80%;        /* Larger on mobile */
      max-width: 450px;  /* Cap the max size */
  }
}

/* Quote/Proverb square image component (optimized for mobile + Lighthouse CLS) */
.quote-image-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(0.8rem, 2vw, 1.2rem);
  margin: 1rem 0 1.4rem;
}

.quote-image-card {
  margin: 0;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--text) 12%, transparent);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  box-shadow: var(--shadow-soft);
}

.quote-square-image {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 0;
  display: block;
}

@media (max-width: 760px) {
  .quote-image-grid {
    grid-template-columns: 1fr;
    gap: 0.9rem;
  }
}

/* =========================================================
   5. Navigation
========================================================= */
.site-header {
  min-height: 100vh;
}

.site-header.account-header {
  min-height: 120px;
}

.nav {
  height: var(--nav-height);
  width: min(var(--max-width), 96vw);
  margin-inline: auto;
  position: fixed;
  top: 0.9rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--space-2);
  padding: 0 var(--space-3);
  border: 1px solid color-mix(in srgb, var(--text) 18%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: blur(12px);
  transition: all var(--transition);
}

.nav .logo {
  grid-column: 1;
}

.nav-list.nav-right {
  grid-column: 2;
  justify-content: center;
}

.nav-icons {
  grid-column: 3;
}

.nav.scrolled {
  top: 0.5rem;
  height: 70px;
  background: color-mix(in srgb, var(--surface) 96%, transparent);
  box-shadow: var(--shadow-soft);
}

.logo {
  font-family: var(--font-heading);
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  white-space: nowrap;
}

.nav-list {
  display: flex;
  gap: var(--space-3);
}

.nav-list a {
  color: var(--text);
  font-size: 1.3rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  position: relative;
}

.nav-list a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.35rem;
  width: 100%;
  height: 1px;
  background: var(--text);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition);
}

.nav-list a:hover::after {
  transform: scaleX(1);
}

.nav-icons {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.theme-toggle {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--text) 14%, transparent);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 10px 20px rgba(0, 0, 0, 0.08);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition), background var(--transition);
}

.theme-toggle:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--accent) 58%, transparent);
  box-shadow: 0 14px 24px rgba(0, 0, 0, 0.12);
}

.theme-toggle:focus-visible {
  outline: 2px solid var(--ocean);
  outline-offset: 2px;
}

.theme-toggle-icon {
  font-size: 1rem;
  line-height: 1;
}

.mobile-toggle {
  display: none;
  border: 0;
  background: transparent;
}

.mobile-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  margin: 5px 0;
  transition: transform var(--transition);
}

/* =========================================================
   6. Hero
========================================================= */


   .hero {
  min-height: 100vh;
  position: relative;
  overflow: hidden;
  border-radius: 0 0 2rem 2rem;
}

.hero-image {
  height: 100vh;
  object-fit: cover;
  border-radius: 0;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(15, 19, 22, 0.68), rgba(15, 19, 22, 0.2));
}

.hero-content {
  position: absolute;
  inset: auto auto 12% 6%;
  max-width: 680px;
  color: #f7ead8;
}

.hero-content p {
  color: rgba(255, 255, 255, 0.88);
  max-width: 52ch;
}

.hero-actions {
  margin-top: var(--space-4);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}



/* =========================================================
   9. Story
========================================================= */
.story {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: var(--space-5);
  align-items: center;
}

.story-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  min-height: 380px;
  object-fit: cover;
}

.story-copy p + p {
  margin-top: var(--space-2);
}

/* =========================================================
   10. Lifestyle Journal Cards
========================================================= */
.lifestyle-grid {
  display: grid;
  gap: var(--space-3);
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.journal-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(29, 29, 29, 0.06);
  display: flex;
  flex-direction: column;
  min-height: 100%;
  transition: transform var(--transition), box-shadow var(--transition);
}

.journal-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-card);
}

.journal-media {
  position: relative;
  overflow: hidden;
}

.journal-media img {
  height: clamp(220px, 26vw, 300px);
  object-fit: cover;
  border-radius: 0;
  transition: transform 700ms ease;
}

.journal-card:hover .journal-media img {
  transform: scale(1.05);
}

.journal-content {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: var(--space-3);
  background: linear-gradient(
    180deg,
    color-mix(in srgb, var(--white) 94%, var(--bg)) 0%,
    color-mix(in srgb, var(--sand) 82%, var(--bg)) 100%
  );
  flex: 1;
}

.journal-date {
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
}

.journal-content h3 {
  margin: 0;
}

.journal-content p {
  margin: 0;
}

.journal-btn {
  margin-top: auto;
  width: fit-content;
}

.section-cta {
  margin-top: var(--space-4);
  display: flex;
  justify-content: center;
}

.btn-premium-link {
  position: relative;
  padding: 0.9rem 1.8rem;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--ocean) 30%, transparent);
  color: #ffffff;
  letter-spacing: 0.02em;
  background:
    linear-gradient(135deg, #1f8f4e 0%, #2f8aa3 52%, #4ec9a8 100%);
  box-shadow:
    0 12px 28px rgba(19, 102, 117, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.24);
  transition:
    transform var(--transition),
    box-shadow var(--transition),
    filter var(--transition);
}

.btn-premium-link:hover,
.btn-premium-link:focus-visible {
  transform: translateY(-2px);
  filter: saturate(1.08);
  box-shadow:
    0 16px 34px rgba(19, 102, 117, 0.36),
    0 0 0 3px color-mix(in srgb, var(--accent) 24%, transparent);
}

.btn-premium-link:focus-visible {
  outline: none;
}

html[data-theme="dark"] .btn-premium-link {
  color: #f8f1e4;
  border-color: color-mix(in srgb, var(--sand) 28%, transparent);
  background:
    linear-gradient(135deg, #1f8f4e 0%, #2c5f73 48%, #2ba36f 100%);
  box-shadow:
    0 14px 30px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}


/* =========================================================
   12. Contact Form
========================================================= */
.contact-form-wrap {
  background: linear-gradient(
    to bottom,
    #4a2f20 0%,
    #8b684d 50%,
    #d8bfa5 100%
  );
  border-radius: var(--radius);
  padding: clamp(1.8rem, 5vw, 3.6rem);
  text-align: center;
  text-align: center;
}

.contact-form-wrap p {
  max-width: 56ch;
  margin: 0.8rem auto 0;
}

.contact-form {
  margin-top: var(--space-3);
  display: flex;
  gap: var(--space-2);
  justify-content: center;
  flex-wrap: wrap;
}

/* Premium contact-style form */
.premium-form {
  width: min(760px, 100%);
  margin-inline: auto;
  text-align: left;
  gap: var(--space-2);
}

.premium-form .form-row {
  width: 100%;
}

.premium-form .form-row.two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-2);
}

.premium-form .form-field {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.premium-form label {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--text);
}

.premium-form input,
.premium-form select,
.premium-form textarea {
  width: 100%;
  border: 1px solid color-mix(in srgb, var(--text) 20%, transparent);
  border-radius: 0.95rem;
  padding: 0.82rem 0.95rem;
  background: color-mix(in srgb, var(--white) 88%, transparent);
  color: var(--text);
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}

.premium-form textarea {
  resize: vertical;
  min-height: 138px;
}

.premium-form select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) calc(50% - 3px),
    calc(100% - 12px) calc(50% - 3px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 2.2rem;
}

.premium-form input:focus,
.premium-form select:focus,
.premium-form textarea:focus {
  outline: none;
  border-color: color-mix(in srgb, var(--ocean) 65%, transparent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
  background: color-mix(in srgb, var(--white) 96%, transparent);
}

.form-fun-text {
  margin-top: 0.25rem;
  margin-bottom: 0.2rem;
  text-align: center;
  color: var(--ocean);
  font-weight: 500;
  font-size: 1.1rem;
}

.btn-form-premium {
  width: fit-content;
  margin-inline: auto;
  border: 1px solid color-mix(in srgb, var(--ocean) 28%, transparent);
  color: #ffffff;
  letter-spacing: 0.02em;
  background: linear-gradient(135deg, #2f8aa3 0%, #1f8f4e 50%, #67c49f 100%);
  box-shadow:
    0 14px 28px rgba(28, 109, 126, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.24);
  transition:
    transform var(--transition),
    box-shadow var(--transition),
    filter var(--transition);
}

.btn-form-premium:hover,
.btn-form-premium:focus-visible {
  transform: translateY(-2px);
  filter: saturate(1.08);
  box-shadow:
    0 18px 34px rgba(28, 109, 126, 0.36),
    0 0 0 3px color-mix(in srgb, var(--accent) 26%, transparent);
}

.btn-form-premium:focus-visible {
  outline: none;
}

/* Dark mode: light green → deeper green */
html[data-theme="dark"] .contact-form-wrap {
  background: linear-gradient(
    to bottom,
    #b8e0c2 0%,
    #62a878 50%,
    #24704d 100%
  );
}

/* =========================================================
   Contact Form — Theme Text Colors
========================================================= */

/* Light mode: light text on brown gradient */
html[data-theme="light"] .contact-form-wrap {
  color: #fff8ed;
}

html[data-theme="light"] .contact-form-wrap h1,
html[data-theme="light"] .contact-form-wrap h2,
html[data-theme="light"] .contact-form-wrap h3,
html[data-theme="light"] .contact-form-wrap p,
html[data-theme="light"] .contact-form-wrap label {
  color: #fff8ed;
}

html[data-theme="light"] .contact-form-wrap .form-fun-text {
  color: #f3dfb9;
}

/* Dark mode: dark text on green gradient */
html[data-theme="dark"] .contact-form-wrap {
  color: #173d2d;
}

html[data-theme="dark"] .contact-form-wrap h1,
html[data-theme="dark"] .contact-form-wrap h2,
html[data-theme="dark"] .contact-form-wrap h3,
html[data-theme="dark"] .contact-form-wrap p,
html[data-theme="dark"] .contact-form-wrap label {
  color: #173d2d;
}

html[data-theme="dark"] .contact-form-wrap .form-fun-text {
  color: #245b43;
}



html[data-theme="dark"] .premium-form input,
html[data-theme="dark"] .premium-form select,
html[data-theme="dark"] .premium-form textarea {
  background: color-mix(in srgb, var(--white) 22%, transparent);
  border-color: color-mix(in srgb, var(--sand) 22%, transparent);
  color: #f6efe2;
}

html[data-theme="dark"] .premium-form input::placeholder,
html[data-theme="dark"] .premium-form textarea::placeholder {
  color: color-mix(in srgb, #f6efe2 68%, transparent);
}

html[data-theme="dark"] .premium-form label {
  color: #f4ead8;
}

html[data-theme="dark"] .form-fun-text {
  color: #9fd4e2;
}

html[data-theme="dark"] .btn-form-premium {
  color: #f8f1e4;
  border-color: color-mix(in srgb, var(--sand) 28%, transparent);
  background: linear-gradient(135deg, #2c5f73 0%, #1f8f4e 52%, #2ba36f 100%);
  box-shadow:
    0 16px 32px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

@media (max-width: 760px) {
  .premium-form .form-row.two-col {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   13. Footer
========================================================= */

.site-footer {
  background: color-mix(in srgb, var(--sand) 88%, var(--bg));
  margin-top: var(--space-5);
  padding: var(--space-5) 4vw var(--space-3);
}

/* =========================================================
   Light Theme
========================================================= */

html[data-theme="light"] .site-footer {
  background:
    linear-gradient(
      135deg,
      rgba(248, 240, 228, 0.9) 0%,
      rgba(240, 227, 207, 0.9) 56%,
      rgba(228, 239, 241, 0.84) 100%
    );

  border-top: 1px solid
    color-mix(in srgb, var(--ocean) 18%, transparent);

  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .site-footer a:hover {
  color: #2f8aa3;
}

/* =========================================================
   Dark Theme
========================================================= */

html[data-theme="dark"] .site-footer {
  background:
    linear-gradient(
      135deg,
      rgba(10, 42, 33, 0.92) 0%,
      rgba(11, 52, 41, 0.9) 52%,
      rgba(13, 62, 70, 0.86) 100%
    );

  border-top: 1px solid
    color-mix(in srgb, var(--ocean) 34%, transparent);

  box-shadow:
    inset 0 1px 0 rgba(241, 231, 212, 0.08);
}

html[data-theme="dark"] .site-footer h3,
html[data-theme="dark"] .site-footer h4 {
  color: #f4ead8;
}

html[data-theme="dark"] .site-footer p,
html[data-theme="dark"] .site-footer li,
html[data-theme="dark"] .copyright {
  color: #d6e2db;
}

html[data-theme="dark"] .site-footer a {
  color: #e8dfcf;
}

html[data-theme="dark"] .site-footer a:hover {
  color: #79cbe3;
}

/* =========================================================
   Footer Grid
========================================================= */

.footer-grid {
  width: min(var(--max-width), 94vw);
  margin-inline: auto;

  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);

  align-items: start;
}

/* =========================================================
   Footer Typography
========================================================= */

.site-footer h3,
.site-footer h4 {
  margin-top: 0;
  margin-bottom: 0.75rem;
}

.site-footer p {
  margin-top: 0;
  line-height: 1.7;
}

.site-footer ul {
  margin: 0;
  padding: 0;
}

.site-footer li + li {
  margin-top: 0.4rem;
}

.site-footer a {
  font-family: "Lora", serif;
  color: var(--text);
}

/* =========================================================
   Developer Credit
========================================================= */

.footer-developer {
  display: flex;
  flex-direction: column;

  align-items: center;
  justify-content: center;

  text-align: center;
  height: 100%;
}

.developer-logo {
  display: block;

  width: 110px;
  height: auto;

  margin: 0 auto 0.75rem;
}

.footer-developer a {
  display: inline-block;

  font-family: "Lora", serif;
  font-size: 0.9rem;
  line-height: 1.4;

  color: var(--text);
  text-decoration: none;

  transition:
    color 0.25s ease,
    opacity 0.25s ease;
}

.footer-developer a:hover {
  color: #2f8aa3;
  opacity: 0.9;
}

/* Dark mode developer credit */

html[data-theme="dark"] .footer-developer a {
  color: #e8dfcf;
}

html[data-theme="dark"] .footer-developer a:hover {
  color: #79cbe3;
}

/* =========================================================
   Social Links
========================================================= */

.social-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.social-links li + li {
  margin-top: 0.6rem;
}

.social-links a {
  display: inline-flex;

  align-items: center;
  gap: 0.6rem;

  color: var(--text);
  text-decoration: none;

  transition:
    color 0.25s ease,
    transform 0.2s ease;
}

.social-links i {
  font-size: 1.3rem;

  width: 1.5rem;
  text-align: center;

  transition:
    color 0.25s ease,
    transform 0.2s ease;
}

.social-links a:hover {
  transform: translateX(3px);
}

.social-links a:hover i {
  transform: scale(1.08);
}

/* Instagram */

.social-links a:hover .fa-instagram {
  color: #e4405f;
}

/* Facebook */

.social-links a:hover .fa-facebook {
  color: #1877f2;
}

/* Theme-specific social colors */

html[data-theme="dark"] .social-links a {
  color: #e8dfcf;
}

html[data-theme="light"] .social-links a {
  color: var(--text);
}

/* =========================================================
   Copyright
========================================================= */

.copyright {
  font-family: "Lora", serif;

  text-align: center;

  margin-top: var(--space-4);
  margin-bottom: 0;

  color: var(--muted);

  font-size: 0.9rem;
  line-height: 1.5;
}

/* =========================================================
   Tablet
========================================================= */

@media (max-width: 900px) {
  .site-footer {
    padding-inline: 5vw;
  }

  .footer-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-3);
  }

  .developer-logo {
    width: 95px;
  }

  .footer-developer a {
    font-size: 0.85rem;
  }
}

/* =========================================================
   Mobile
========================================================= */

@media (max-width: 700px) {
  .site-footer {
    margin-top: var(--space-4);
    padding: var(--space-5) 6vw var(--space-3);
  }

  .footer-grid {
    width: 100%;

    grid-template-columns: 1fr;
    gap: var(--space-4);

    text-align: center;
  }

  /* Brand column */

  .site-footer > .footer-grid > div:first-child {
    max-width: 420px;
    margin-inline: auto;
  }

  /* Developer column */

  .footer-developer {
    width: 100%;
    margin: 0 auto;
  }

  .developer-logo {
    width: 105px;
    margin-bottom: 0.75rem;
  }

  .footer-developer a {
    font-size: 0.9rem;
  }

  /* Follow column */

  .site-footer > .footer-grid > div:last-child {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .social-links {
    display: flex;
    justify-content: center;
  }

  .social-links li + li {
    margin-top: 0;
    margin-left: 0.75rem;
  }

  .social-links a {
    justify-content: center;
  }

  .social-links a:hover {
    transform: translateY(-2px);
  }

  /* Copyright */

  .copyright {
    margin-top: var(--space-4);
    font-size: 0.82rem;
  }
}

/* =========================================================
   Small Mobile
========================================================= */

@media (max-width: 420px) {
  .site-footer {
    padding-inline: 5vw;
  }

  .footer-grid {
    gap: var(--space-3);
  }

  .site-footer h3,
  .site-footer h4 {
    margin-bottom: 0.6rem;
  }

  .site-footer p {
    font-size: 0.9rem;
  }

  .developer-logo {
    width: 90px;
  }

  .footer-developer a {
    font-size: 0.82rem;
  }

  .copyright {
    font-size: 0.78rem;
  }
}


/* =========================================================
   14. Utilities
========================================================= */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  clip: rect(0, 0, 0, 0);
  overflow: hidden;
  white-space: nowrap;
  border: 0;
}

.back-to-top {
  position: fixed;
  right: 1.2rem;
  bottom: 1.2rem;
  width: 44px;
  height: 44px;
  border: 1px solid transparent;
  border-radius: 50%;
  background: var(--text);
  color: var(--white);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
  transition: opacity var(--transition), transform var(--transition), visibility var(--transition), background var(--transition), color var(--transition), border-color var(--transition), box-shadow var(--transition);
}

html[data-theme="light"] .back-to-top {
  background: #123126;
  color: #ffffff;
  border-color: rgba(18, 49, 38, 0.2);
}

html[data-theme="dark"] .back-to-top {
  background: #f3e9d7;
  color: #0b241d;
  border-color: rgba(243, 233, 215, 0.24);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.42);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 600ms ease, transform 600ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Story page fail-safe:
   Ensure main story content is visible even if IntersectionObserver/reveal fails on some mobile browsers (e.g., iPhone SE).
   Keep hero reveal animation behavior unchanged. */
.story-page main .reveal {
  opacity: 1;
  transform: none;
}

/* =========================================================
   15. Hawaiiana Page
========================================================= */
.journal-hero {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  overflow: hidden;
  text-align: center;
  isolation: isolate;
}

.journal-hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

.journal-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 16, 23, 0.25), rgba(10, 16, 23, 0.6));
  z-index: -1;
}

.journal-hero .hero-content {
  max-width: 760px;
  padding: 2rem 1.25rem;
  color: #fff;
}

.filter-wrap {
  margin-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
}

.filter-chip {
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease, transform 180ms ease;
  backdrop-filter: blur(2px);
}

.filter-chip:hover,
.filter-chip:focus-visible {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.18);
  transform: translateY(-1px);
  outline: none;
}

.filter-chip.is-active {
  background: #fff;
  color: #111;
  border-color: #fff;
}

/* Light mode: dark chips/text for Hawaiiana filters */
html[data-theme="light"] .filter-chip {
  border-color: rgba(17, 17, 17, 0.45);
  background: rgba(255, 255, 255, 0.78);
  color: #111;
}

html[data-theme="light"] .filter-chip:hover,
html[data-theme="light"] .filter-chip:focus-visible {
  border-color: #111;
  background: rgba(255, 255, 255, 0.92);
}

html[data-theme="light"] .filter-chip.is-active {
  background: #111;
  color: #fff;
  border-color: #111;
}

.hawaiiana-grid {
  display: grid;
  /* Fixed column count so card widths don't expand when fewer cards are visible */
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.1rem;
  margin-top: 1.5rem;
}

.hawaiiana-card {
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  overflow: hidden;
  background: var(--surface, #fff);
  border: 1px solid rgba(120, 120, 120, 0.16);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.08);
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
  min-height: 100%;
}

.hawaiiana-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.12);
  border-color: rgba(120, 120, 120, 0.24);
}

.hawaiiana-media {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.04);
}

/* Portrait-first gallery cards for clothing showcases */
.gallery-grid .hawaiiana-media {
  aspect-ratio: 4 / 5;
}

.gallery-grid .hawaiiana-content {
  min-height: 9.5rem;
}

.hawaiiana-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 280ms ease;
}

.hawaiiana-card:hover .hawaiiana-media img {
  transform: scale(1.03);
}

.hawaiiana-content {
  padding: 1rem 1rem 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.hawaiiana-kicker {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.8;
  margin: 0;
}

.hawaiiana-content h3 {
  margin: 0;
  font-size: 1.18rem;
  line-height: 1.25;
}

.hawaiiana-content p {
  margin: 0;
  opacity: 0.9;
  line-height: 1.55;
  font-size: 0.96rem;
}

.hawaiiana-card .btn {
  margin-top: 0.4rem;
  width: fit-content;
}

.is-hidden {
  display: none !important;
}

.journal-intro {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

/* Premium glassmorphism pagination for gallery pages */
.gallery-pagination {
  margin-top: 2rem;
  display: flex;
  justify-content: center;
}

.pagination-list {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  border: 1px solid color-mix(in srgb, var(--text) 14%, transparent);
  backdrop-filter: blur(14px) saturate(115%);
  -webkit-backdrop-filter: blur(14px) saturate(115%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.36),
    0 14px 30px rgba(0, 0, 0, 0.12);
}

.page-item {
  display: inline-flex;
}

.page-link {
  min-width: 42px;
  height: 42px;
  padding: 0 0.9rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: var(--text);
  border: 1px solid color-mix(in srgb, var(--text) 12%, transparent);
  background: color-mix(in srgb, var(--white) 72%, transparent);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
  transition:
    transform var(--transition),
    box-shadow var(--transition),
    border-color var(--transition),
    background var(--transition),
    color var(--transition);
}

.page-link:hover,
.page-link:focus-visible {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--accent) 50%, transparent);
  background: color-mix(in srgb, var(--white) 88%, transparent);
  box-shadow:
    0 10px 20px rgba(0, 0, 0, 0.14),
    0 0 0 2px color-mix(in srgb, var(--accent) 22%, transparent);
  outline: none;
}

.page-item.active .page-link {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #1f8f4e 0%, #2bbf6a 55%, #47d985 100%);
  box-shadow:
    0 12px 24px rgba(31, 143, 78, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.page-item.disabled .page-link {
  opacity: 0.45;
  pointer-events: none;
  cursor: not-allowed;
}

/* Dark theme tuning for glass pagination */
html[data-theme="dark"] .pagination-list {
  background: color-mix(in srgb, var(--surface) 90%, transparent);
  border-color: color-mix(in srgb, var(--sand) 20%, transparent);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 16px 34px rgba(0, 0, 0, 0.4);
}

html[data-theme="dark"] .page-link {
  color: #e9e1cf;
  border-color: color-mix(in srgb, var(--sand) 18%, transparent);
  background: color-mix(in srgb, var(--white) 24%, transparent);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

html[data-theme="dark"] .page-link:hover,
html[data-theme="dark"] .page-link:focus-visible {
  background: color-mix(in srgb, var(--white) 30%, transparent);
  border-color: color-mix(in srgb, var(--accent) 45%, transparent);
}

/* Mobile comfort/touch sizing */
@media (max-width: 760px) {
  .pagination-list {
    gap: 0.4rem;
    padding: 0.5rem;
  }

  .page-link {
    min-width: 40px;
    height: 40px;
    padding: 0 0.78rem;
    font-size: 0.95rem;
  }
}

/* =========================================================
   16. Responsive
========================================================= */
@media (max-width: 1024px) {
  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hawaiiana-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .story {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lifestyle-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .nav-list {
    gap: var(--space-2);
  }
}

@media (max-width: 760px) {
  /* Keep hamburger on left, logo centered, theme icon on right */
  .nav {
    grid-template-columns: 1fr auto 1fr;
    gap: 0.4rem;
    padding-inline: 0.7rem;
  }

  .mobile-toggle {
    grid-column: 1;
    justify-self: start;
    display: block;
    z-index: 120;
  }

  .nav .logo {
    grid-column: 2;
    justify-self: center;
    text-align: center;
  }

  .nav-icons {
    grid-column: 3;
    justify-self: end;
  }

  /* Mobile drawer uses the same links as desktop (nav-right) */
  .nav-list.nav-right {
    position: fixed;

    /* Open from the LEFT side so hamburger can remain on the left */
    top: 0.9rem;
    left: 0;
    right: auto;
    bottom: auto;

    width: min(78vw, 320px);

    background: var(--surface);
    backdrop-filter: blur(16px) saturate(118%);
    -webkit-backdrop-filter: blur(16px) saturate(118%);
    border: 1px solid color-mix(in srgb, var(--text) 14%, transparent);
    box-shadow: var(--shadow-soft);
    border-radius: 1.3rem;

    padding: 6rem 1.2rem 1.2rem;

    /* Hide off-canvas to the left when closed */
    transform: translateX(-104%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;

    transition:
      transform var(--transition),
      opacity var(--transition),
      visibility var(--transition);

    /* Vertical stack for ALL items */
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;

    /* Constrain height so all nav items can display (scroll if needed) */
    max-height: calc(100vh - 1.8rem);

    z-index: 110;

    overflow-y: auto;
    overflow-x: hidden;
  }

  /* Ensure each item takes full row width */
  .nav-list.nav-right a {
    width: 100%;
    display: block;
  }

  .nav-list.nav-right.open {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .hero-content {
    inset: auto var(--space-3) 10% var(--space-3);
  }

  .collection-grid,
  .product-grid,
  .testimonial-grid,
  .footer-grid,
  .lifestyle-grid,
  .hawaiiana-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   17. Story Page: Child Version - Maui Snaring the Sun
========================================================= */
.story-page {
  font-family: "Cormorant Garamond", Georgia, serif;
}

.story-page p,
.story-page label,
.story-page input,
.story-page textarea,
.story-page small,
.story-page button {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.1rem;
  color: var(--text);
}

.story-hero {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  overflow: hidden;
  text-align: center;
  isolation: isolate;
}

.story-hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  border-radius: 0;
}

.story-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 16, 23, 0.25), rgba(10, 16, 23, 0.6));
  z-index: -1;
}

.story-hero .hero-content {
  max-width: 760px;
  padding: 2rem 1.25rem;
  color: #fff;
}

.story-hero .hero-content p {
  color: rgba(255, 255, 255, 0.9);
  margin-inline: auto;
}

.story-wrap {
  width: min(860px, 92vw);
  margin: 0 auto;
  padding: var(--space-5) 0;
}

.story-card {
  background: var(--surface);
  border: 1px solid color-mix(in srgb, var(--text) 14%, transparent);
  border-radius: var(--radius);
  padding: clamp(1.2rem, 2vw, 2rem);
  box-shadow: var(--shadow-soft);
  text-align: left;
}

.story-card h2,
.story-card h3 {
  text-align: left;
  margin-bottom: 0.9rem;
}

.story-card p {
  text-align: left;
  margin-bottom: 1rem;
  color: var(--text);
  font-size: 1.1rem;
}

.author-section {
  border-bottom: 1px solid color-mix(in srgb, var(--text) 18%, transparent);
  margin-bottom: 1.2rem;
  padding-bottom: 1rem;
}

.author-row {
  display: flex;
  gap: 0.8rem;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  text-align: center;
}

.author-avatar {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  object-fit: cover;
}

.muted {
  color: var(--muted);
}

.highlighted-box-green,
.highlighted-box-blue,
.highlighted-box-yellow,
.highlighted-box-pink,
.highlighted-box-orange-brown {
  border-radius: var(--radius-sm);
  padding: 0.95rem 1rem;
  margin: 1rem 0;
  border: 1px solid transparent;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.12);
}

.highlighted-box-green {
  background: color-mix(in srgb, #56b887 20%, var(--surface));
  border-color: color-mix(in srgb, #56b887 45%, transparent);
}

.highlighted-box-blue {
  background: color-mix(in srgb, #52a8ff 20%, var(--surface));
  border-color: color-mix(in srgb, #2f7fd6 48%, transparent);
}

.highlighted-box-yellow {
  background: color-mix(in srgb, #e8c86e 28%, var(--surface));
  border-color: color-mix(in srgb, #d7ae43 50%, transparent);
}

.highlighted-box-pink {
  background: color-mix(in srgb, #d28ab4 24%, var(--surface));
  border-color: color-mix(in srgb, #c46d9e 48%, transparent);
}

.highlighted-box-orange-brown {
  background: color-mix(in srgb, #c78a5e 24%, var(--surface));
  border-color: color-mix(in srgb, #b6723f 48%, transparent);
}

.about-author {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 1rem;
  align-items: center;
  text-align: left;
  background: color-mix(in srgb, var(--sand) 52%, var(--bg));
  border-radius: var(--radius-sm);
  padding: 1rem;
}

.about-author img {
  border-radius: 50%;
  width: 72px;
  height: 72px;
  object-fit: cover;
  margin: 0;
}

.comment-form {
  margin-top: 2rem;
  text-align: left;
}

.comment-form h2 {
  text-align: center;
}

.form-group {
  margin-bottom: 0.85rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.35rem;
  font-weight: 600;
}

.form-control {
  width: 100%;
  border: 1px solid color-mix(in srgb, var(--text) 22%, transparent);
  background: color-mix(in srgb, var(--white) 82%, transparent);
  color: var(--text);
  border-radius: 0.65rem;
  padding: 0.68rem 0.8rem;
}

html[data-theme="dark"] .form-control {
  background: color-mix(in srgb, var(--sand) 30%, var(--bg));
  border-color: color-mix(in srgb, var(--text) 28%, transparent);
}

.form-text {
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--muted);
  font-size: 1.1rem;
}

.comment-submit {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 0.4rem;
}

/* Larger text for full story content under "SNARING THE SUN" */
.story-card > h2:first-of-type {
  font-size: clamp(2.5rem, 5.2vw, 4rem);
  line-height: 1.1;
}

.story-card > h2:first-of-type ~ p,
.story-card > h2:first-of-type ~ div p {
  font-size: clamp(1.3rem, 2.5vw, 1.6rem);
  line-height: 1.8;
}

@media (max-width: 900px) {
  .story-card > h2:first-of-type {
    font-size: clamp(2.2rem, 5.5vw, 3.2rem);
  }

  .story-card > h2:first-of-type ~ p,
  .story-card > h2:first-of-type ~ div p {
    font-size: clamp(1.2rem, 3.2vw, 1.45rem);
    line-height: 1.75;
  }
}

@media (max-width: 760px) {
  .story-hero {
    min-height: 56vh;
  }

  .about-author {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .about-author img {
    margin-inline: auto;
  }

  .story-card p {
    font-size: 1.22rem;
    line-height: 1.75;
  }

  .story-card > h2:first-of-type {
    font-size: clamp(2rem, 7vw, 2.8rem);
  }

  .story-card > h2:first-of-type ~ p,
  .story-card > h2:first-of-type ~ div p {
    font-size: clamp(1.12rem, 4.4vw, 1.3rem);
    line-height: 1.7;
  }
}

.story-nav {
  margin-top: 2.2rem;
  border-top: 1px solid color-mix(in srgb, var(--text) 16%, transparent);
  padding-top: 1.25rem;
}

.story-nav-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
}

.story-nav-card {
  display: grid;
  grid-template-columns: 84px 1fr;
  gap: 0.75rem;
  align-items: center;
  min-height: 96px;
  padding: 0.6rem;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--text) 14%, transparent);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.08);
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease, background-color 220ms ease;
}

.story-nav-card img {
  width: 84px;
  height: 84px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  background: color-mix(in srgb, var(--bg) 80%, transparent);
  transition: transform 220ms ease;
}

.story-nav-card:hover,
.story-nav-card:focus-visible {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--accent) 42%, transparent);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.14);
}

.story-nav-card:hover img,
.story-nav-card:focus-visible img {
  transform: scale(1.02);
}

.story-nav-card:focus-visible {
  outline: 2px solid var(--ocean);
  outline-offset: 2px;
}

.story-nav-content {
  position: static;
  padding: 0;
  color: var(--text);
  min-width: 0;
}

.story-nav-label {
  display: inline-block;
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 0.15rem;
  color: var(--muted);
}

.story-nav-content h3 {
  margin: 0;
  font-size: clamp(1.3rem, 1.9vw, 1.2rem);
  line-height: 1.2;
  color: var(--text);
  overflow-wrap: anywhere;
}

@media (max-width: 760px) {
  .story-nav-grid {
    grid-template-columns: 1fr;
  }

  .story-nav-card {
    grid-template-columns: 76px 1fr;
    min-height: 88px;
    padding: 0.5rem;
  }

  .story-nav-card img {
    width: 76px;
    height: 76px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0ms !important;
  }

  .story-nav-card img {
    transition: none !important;
  }
}
