/* ==========================================================================
   Solace 21 — landing page styles
   1. Tokens  2. Base  3. Shared  4. Header  5. Hero  6. Products
   7. Story   8. Ritual  9. Footer  10. Responsive
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
  --red: #A23931;        /* brand */
  --red-deep: #7E2A24;
  --cream: #F5EFE4;
  --paper: #FBF8F2;
  --ink: #231D1A;
  --ink-soft: #5B514B;
  --moss: #4C5638;
  --sage: #D9DDC3;
  --clay: #E8D2C4;

  --font-display: "Instrument Serif", Georgia, "Times New Roman", serif;
  --font-body: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;

  --gutter: clamp(20px, 5vw, 56px);
  --max: 1240px;
  --radius: 28px;
  --section-space: clamp(72px, 10vw, 136px);

  /* Image placeholder colours; overridden per context */
  --ph-bg: var(--clay);
  --ph-fg: var(--ink-soft);
  /* Emblem cut-out colour (should match the background it sits on) */
  --cut: var(--cream);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 88px; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.01em;
}
h1 em, h2 em { font-style: italic; color: var(--red); }

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

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* 3. Shared ---------------------------------------------------------------- */
.container {
  width: min(100% - var(--gutter) * 2, var(--max));
  margin-inline: auto;
}

.section { padding-block: var(--section-space); }

.section-head { margin-bottom: clamp(36px, 5vw, 64px); }
.section-head h2 { font-size: clamp(2.5rem, 6vw, 4.75rem); margin-top: 14px; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red);
}
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 30px;
  border: 1.5px solid var(--red);
  border-radius: 999px;
  background: var(--red);
  color: var(--cream);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}
.btn:hover { background: var(--red-deep); border-color: var(--red-deep); }
.btn--small { padding: 10px 20px; font-size: 0.9375rem; }
.btn--ghost { background: transparent; color: var(--red); }
.btn--ghost:hover { background: var(--red); color: var(--cream); border-color: var(--red); }
.btn--light { background: var(--cream); color: var(--red); border-color: var(--cream); }
.btn--light:hover { background: var(--clay); border-color: var(--clay); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1.5px solid currentColor;
  padding-bottom: 3px;
}
.link-arrow::after { content: "→"; transition: transform 0.2s; }
.link-arrow:hover::after { transform: translateX(4px); }

/* Images. A real <img> placed inside .media covers the placeholder beneath it. */
.media {
  position: relative;
  aspect-ratio: var(--ratio, 4 / 5);
  overflow: hidden;
  border-radius: 20px;
  background: var(--ph-bg);
}
.media > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.media--arch { border-radius: 999px 999px 24px 24px; }
.media--circle { border-radius: 50%; }

.placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 24px;
  text-align: center;
  color: var(--ph-fg);
  font-size: 0.8125rem;
  line-height: 1.4;
}
.placeholder::before {
  content: "";
  width: 36px;
  height: 36px;
  margin-bottom: 14px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  opacity: 0.6;
}
.placeholder strong {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.5rem;
  line-height: 1.1;
}
.placeholder span { opacity: 0.75; word-break: break-all; }

/* 4. Header ---------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(245, 239, 228, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(35, 29, 26, 0.08);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--red);
}
.emblem { width: 34px; height: 34px; }
.brand-name {
  font-family: var(--font-display);
  font-size: 1.75rem;
  line-height: 1;
  color: var(--ink);
}
.brand-name em { font-style: italic; color: var(--red); }

.nav { display: flex; gap: 28px; margin-left: auto; }
.nav a {
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9375rem;
  padding-block: 6px;
  border-bottom: 1.5px solid transparent;
  transition: border-color 0.2s, color 0.2s;
}
.nav a:hover { color: var(--red); border-color: var(--red); }

.nav-toggle {
  display: none;
  margin-left: auto;
  padding: 8px 16px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
}

/* 5. Hero ------------------------------------------------------------------ */
.hero { padding-block: clamp(40px, 6vw, 88px) 0; overflow: clip; }

.hero-inner {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(32px, 6vw, 96px);
  align-items: center;
}

.hero h1 {
  margin-top: 22px;
  font-size: clamp(3.5rem, 9vw, 7.75rem);
  line-height: 0.94;
  letter-spacing: -0.02em;
}
.hero .lead {
  max-width: 34rem;
  margin-top: 28px;
  font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
  color: var(--ink-soft);
}
.actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 40px; }

.hero-visual { position: relative; }
.hero-visual::before {       /* the "sun" behind the arch */
  content: "";
  position: absolute;
  top: -8%;
  right: -14%;
  width: 72%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--red);
}
.hero-visual .media { position: relative; --ph-bg: var(--clay); }

/* 6. Products -------------------------------------------------------------- */
.products {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(16px, 2.5vw, 32px);
}

.product {
  display: flex;
  flex-direction: column;
  padding: clamp(14px, 1.8vw, 22px);
  border-radius: 36px;
}
.product .media { border-radius: 24px; }

.product--everyday {
  background: var(--sage);
  color: var(--ink);
  --ph-bg: rgba(251, 248, 242, 0.55);
  --ph-fg: var(--moss);
}
.product--premium {
  background: var(--ink);
  color: var(--cream);
  --ph-bg: #362D28;
  --ph-fg: #D9C9BC;
}
.product--premium .link-arrow { color: var(--cream); }

.product-body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  padding: 28px clamp(8px, 1.5vw, 18px) clamp(10px, 1.5vw, 18px);
  flex: 1;
}
.product-tag {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.8;
}
.product-tag span { margin-right: 10px; }
.product--premium .product-tag { color: #E0A59F; opacity: 1; }
.product h3 { font-size: clamp(2.25rem, 4vw, 3.25rem); }
.product-body p:not(.product-tag) { max-width: 26rem; opacity: 0.85; }
.product-body .link-arrow { margin-top: auto; }

/* 7. Story ----------------------------------------------------------------- */
.story {
  background: var(--red);
  color: var(--cream);
  --ph-bg: rgba(245, 239, 228, 0.12);
  --ph-fg: var(--cream);
}
.story .eyebrow { color: var(--clay); }
.story h2 em { color: var(--clay); }

.story-inner {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(36px, 7vw, 112px);
  align-items: center;
}
.story-visual .media { max-width: 520px; margin-inline: auto; }

.story-copy h2 { font-size: clamp(2.5rem, 6vw, 4.75rem); margin-top: 14px; }
.story-copy p + p { margin-top: 18px; }
.story-copy .statement {
  margin-top: 28px;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.6vw, 2.125rem);
  line-height: 1.2;
}
.story-copy .statement + p { margin-top: 28px; }
.story-copy p:not(.eyebrow):not(.statement) { max-width: 32rem; opacity: 0.9; }

/* 8. Ritual ---------------------------------------------------------------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(20px, 3vw, 40px);
  align-items: start;
}
.step:nth-child(2) { margin-top: clamp(0px, 5vw, 64px); }
.step .media { margin-bottom: 22px; }
.step-number {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-style: italic;
  color: var(--red);
}
.step h3 { font-size: 2.25rem; margin-top: 2px; }
.step p:last-child { margin-top: 10px; max-width: 22rem; color: var(--ink-soft); }

/* 9. Footer ---------------------------------------------------------------- */
.site-footer {
  background: var(--ink);
  color: var(--cream);
  padding-block: clamp(56px, 8vw, 104px) 32px;
  --cut: var(--ink);
}
.site-footer .brand { color: #D26A60; }
.site-footer .brand-name { color: var(--cream); }
.site-footer .brand-name em { color: #D26A60; }

.footer-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding-bottom: clamp(40px, 6vw, 72px);
  border-bottom: 1px solid rgba(245, 239, 228, 0.16);
}
.footer-cta h2 { font-size: clamp(2.5rem, 6vw, 4.5rem); }
.footer-cta h2 em { color: #D26A60; }

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  padding-block: clamp(36px, 5vw, 56px);
}
.footer-brand p { margin-top: 16px; max-width: 20rem; opacity: 0.7; }
.site-footer h3 {
  margin-bottom: 14px;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.6;
}
.site-footer li { margin-top: 6px; }
.site-footer li a { text-decoration: none; }
.site-footer li a:hover { text-decoration: underline; text-underline-offset: 4px; }
.legal { padding-top: 24px; border-top: 1px solid rgba(245, 239, 228, 0.16); font-size: 0.875rem; opacity: 0.6; }

/* 10. Responsive ----------------------------------------------------------- */
@media (max-width: 860px) {
  .hero-inner,
  .story-inner { grid-template-columns: 1fr; }

  .hero-visual { max-width: 420px; margin-inline: auto; width: 100%; }
  .hero-visual::before { right: -8%; }

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

  .steps { grid-template-columns: 1fr; max-width: 420px; }
  .step:nth-child(2) { margin-top: 0; }

  .story-visual .media { max-width: 340px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }

  /* Mobile navigation */
  .header-cta { display: none; }
  .nav-toggle { display: inline-block; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    padding: 8px var(--gutter) 20px;
    background: var(--cream);
    border-bottom: 1px solid rgba(35, 29, 26, 0.08);
  }
  .nav.is-open { display: flex; }
  .nav a { padding-block: 14px; border-bottom: 1px solid rgba(35, 29, 26, 0.08); font-size: 1.125rem; }
}

@media (max-width: 480px) {
  .actions .btn { flex: 1 1 100%; }
  .footer-cta .btn { width: 100%; }
}
