/* ============================================================
   Pine Bros. — premium editorial demo stylesheet
   Iteration 1: core layout, palette, markers, responsive shell
   ============================================================ */

:root {
  --bone: #f2ead8;
  --bone-deep: #e8dcc2;
  --cream: #faf5ea;
  --pine: #1f4d3a;
  --pine-deep: #16382b;
  --amber: #c98b3b;
  --rose: #c24e5c;
  --ink: #1a1712;
  --ink-soft: rgba(26, 23, 18, 0.62);

  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, "Segoe UI", sans-serif;

  --header-h: 76px;
  --container: 1240px;
  --gutter: clamp(20px, 4vw, 56px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

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

.wrap {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------- Typography ---------- */
h1, h2, h3, .display {
  font-family: var(--serif);
  font-weight: 500;
  line-height: 1.05;
  margin: 0;
  letter-spacing: -0.01em;
}

.eyebrow {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: var(--amber);
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.eyebrow::before {
  content: "";
  width: 34px; height: 1px; background: var(--amber);
}
.eyebrow.on-ink { color: var(--amber); }
.eyebrow.center::after { content: ""; width: 34px; height: 1px; background: var(--amber); }
.eyebrow.center::before { content: ""; }

.serif { font-family: var(--serif); }

.lede { font-size: clamp(1.05rem, 1.3vw, 1.25rem); color: var(--ink-soft); }

p { margin: 0 0 1em; }

/* ---------- Sticky header ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--header-h);
  z-index: 60;
  display: flex;
  align-items: center;
  transition: background 0.3s ease, box-shadow 0.3s ease, color 0.3s ease;
}
.site-header.scrolled {
  background: var(--cream);
  box-shadow: 0 1px 0 rgba(26,23,18,0.08), 0 8px 30px rgba(26,23,18,0.06);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand { font-family: var(--serif); font-size: 1.5rem; font-weight: 600; letter-spacing: 0.02em;
  color: var(--cream); text-shadow: 0 1px 8px rgba(26,23,18,0.35); }
.site-header.scrolled .brand { color: var(--ink); text-shadow: none; }
.brand em { font-style: normal; color: var(--amber); }

.main-nav ul { display: flex; gap: 28px; list-style: none; margin: 0; padding: 0; align-items: center; }
.main-nav a {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: rgba(255,255,255,0.85);
  text-shadow: 0 1px 6px rgba(26,23,18,0.4);
  transition: color 0.2s;
}
.site-header.scrolled .main-nav a { color: var(--ink-soft); text-shadow: none; }
.main-nav a:hover { color: var(--amber); }
.site-header.scrolled .main-nav a:hover { color: var(--pine); }

.nav-toggle {
  display: none;
  background: none; border: none; cursor: pointer;
  width: 44px; height: 44px; position: relative; z-index: 70;
}
.nav-toggle span {
  position: absolute; left: 10px; right: 10px; height: 2px;
  background: var(--cream); transition: transform 0.25s, opacity 0.25s;
}
.nav-toggle span:nth-child(1) { top: 15px; }
.nav-toggle span:nth-child(2) { top: 22px; }
.nav-toggle span:nth-child(3) { top: 29px; }
.site-header.scrolled .nav-toggle span { background: var(--ink); }
body.nav-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
body.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile drawer */
.mobile-nav {
  position: fixed; inset: 0; z-index: 55;
  background: var(--pine-deep);
  display: flex; flex-direction: column;
  padding: calc(var(--header-h) + 24px) var(--gutter) 40px;
  transform: translateY(-100%);
  transition: transform 0.35s ease;
}
body.nav-open .mobile-nav { transform: translateY(0); }
.mobile-nav a {
  font-family: var(--serif); font-size: 1.9rem; color: var(--cream);
  padding: 10px 0; border-bottom: 1px solid rgba(242,234,216,0.12);
}
.mobile-nav .eyebrow { margin-bottom: 18px; color: var(--amber); }

body.nav-open { overflow: hidden; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--sans); font-size: 0.8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.16em;
  padding: 15px 30px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.25s, color 0.25s, border-color 0.25s;
}
.btn-solid { background: var(--pine); color: var(--cream); }
.btn-solid:hover { background: var(--pine-deep); }
.btn-line { border-color: currentColor; color: var(--ink); background: transparent; }
.btn-line:hover { background: var(--ink); color: var(--cream); }
.btn-line.on-ink { color: var(--cream); }
.btn-line.on-ink:hover { background: var(--cream); color: var(--ink); }
.btn-amber { background: var(--amber); color: var(--ink); }
.btn-amber:hover { background: #b57a2c; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 92vh;
  display: flex; align-items: flex-end;
  background:
    radial-gradient(120% 90% at 80% 10%, rgba(201,139,59,0.35), transparent 55%),
    linear-gradient(160deg, var(--pine) 0%, var(--pine-deep) 100%);
  color: var(--cream);
  padding: 0 0 calc(var(--header-h) + 42px);
  overflow: hidden;
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background-image:
    radial-gradient(circle at 12% 120%, rgba(242,234,216,0.14) 0, transparent 30%),
    radial-gradient(circle at 88% 20%, rgba(194,78,92,0.16) 0, transparent 26%);
  pointer-events: none;
}
.hero-inner { position: relative; z-index: 2; max-width: 720px; margin-left: calc(var(--gutter)); }
.hero h1 { font-size: clamp(3rem, 7vw, 5.6rem); margin: 18px 0 22px; }
.hero h1 em { font-style: italic; color: var(--amber); }
.hero p { font-size: clamp(1.05rem, 1.3vw, 1.25rem); color: rgba(242,234,216,0.82); max-width: 560px; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 30px; }
.hero-word {
  position: absolute; right: var(--gutter); top: 24vh; z-index: 2;
  font-family: var(--serif); font-style: italic; font-size: clamp(1rem,3vw,2rem);
  color: rgba(242,234,216,0.4); max-width: 200px; text-align: right; line-height: 1.2;
}

/* ---------- Sections ---------- */
.section { padding: clamp(64px, 9vw, 120px) 0; position: relative; }
.section-head { max-width: 720px; margin-bottom: clamp(36px, 5vw, 64px); }
.section-head h2 { font-size: clamp(2rem, 4vw, 3.4rem); margin: 16px 0 14px; }

/* Asymmetric story blocks */
.story { display: grid; grid-template-columns: 7fr 5fr; gap: 0; align-items: center; }
.story.flip { grid-template-columns: 5fr 7fr; }
.story-visual {
  min-height: 480px;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(100% 100% at 30% 20%, var(--bone), var(--bone-deep));
  color: var(--pine);
}
.story-visual .label {
  font-family: var(--serif); font-size: clamp(3rem,7vw,6rem); font-style: italic;
  opacity: 0.5; user-select: none;
}
.story-body { padding: var(--gutter) clamp(24px,5vw,72px); }
.story-body h3 { font-size: clamp(1.7rem,3vw,2.6rem); margin: 14px 0 16px; }

/* flagship feature */
.feature { display: grid; grid-template-columns: 1fr 1fr; min-height: 560px; }
.feature .feature-visual {
  background: linear-gradient(150deg, var(--amber) 0%, #b0782a 60%, var(--pine) 160%);
  position: relative; overflow: hidden;
  display: flex; align-items: flex-end; padding: var(--gutter);
  color: var(--cream);
}
.feature .feature-visual span.big {
  font-family: var(--serif); font-style: italic; font-size: clamp(2.5rem,6vw,5rem); line-height: 1;
}
.feature .feature-body {
  background: var(--ink); color: var(--cream);
  padding: clamp(32px,6vw,72px);
  display: flex; flex-direction: column; justify-content: center;
}
.feature .feature-body h2 { font-size: clamp(2rem,4vw,3.2rem); margin: 16px 0 18px; }
.feature .feature-body p { color: rgba(242,234,216,0.78); }

/* 7+5 / 5+7 product showcase */
.showcase { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; }
.product {
  grid-column: span 7; position: relative;
  background: var(--bone);
  min-height: 420px;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: var(--gutter);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.product:nth-child(even) { grid-column: span 5; }
.product:nth-child(1), .product:nth-child(3) { margin-top: 48px; }
.product:hover { transform: translateY(-6px); box-shadow: 0 20px 60px rgba(26,23,18,0.14); }
.product .swatch {
  position: absolute; inset: 20px; border: 1px solid rgba(26,23,18,0.08);
}
.product .num {
  position: absolute; top: var(--gutter); left: var(--gutter);
  font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--amber);
}
.product .flavor {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  font-family: var(--serif); font-style: italic; font-size: clamp(2.4rem,5vw,4rem);
  color: rgba(26,23,18,0.55); text-align: center; line-height: 1.1;
}
.product h3 { font-size: clamp(1.5rem,2.4vw,2rem); margin-bottom: 6px; }
.product .meta { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.14em; color: var(--ink-soft); margin-bottom: 10px; }
.product .cta { margin-top: 14px; }

/* dark brand section */
.brand-section { background: var(--pine-deep); color: var(--cream); }
.brand-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; align-items: center; min-height: 460px; }
.brand-text { padding: var(--gutter) clamp(24px,5vw,72px); }
.brand-text blockquote {
  margin: 0; font-family: var(--serif); font-style: italic;
  font-size: clamp(1.8rem,3.4vw,2.8rem); line-height: 1.2;
}
.brand-text cite { display: block; margin-top: 20px; font-style: normal; font-family: var(--sans); font-size: 0.8rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--amber); }
.brand-visual { min-height: 460px; display: flex; align-items: center; justify-content: center; background: radial-gradient(circle at 50% 50%, rgba(201,139,59,0.25), transparent 60%); }

/* masonry / UGC */
.masonry {
  column-count: 3; column-gap: 20px;
}
.tile {
  break-inside: avoid; margin-bottom: 20px;
  background: var(--bone); border: 1px solid rgba(26,23,18,0.06);
  padding: 26px; min-height: 160px;
}
.tile.tall { min-height: 260px; background: var(--bone-deep); }
.tile .tile-cap { font-family: var(--serif); font-style: italic; font-size: 1.2rem; color: var(--ink-soft); }
.tile .tile-tag { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.14em; color: var(--amber); margin-bottom: 10px; }

/* stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; text-align: center; }
.stat .n { font-family: var(--serif); font-size: clamp(2.6rem,5vw,4rem); color: var(--pine); }
.stat .k { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.18em; color: var(--ink-soft); }

/* closing CTA */
.cta-band { text-align: center; background: linear-gradient(180deg, var(--cream), var(--bone)); }
.cta-band h2 { font-size: clamp(2.2rem,5vw,4rem); margin: 16px auto 18px; max-width: 640px; }

/* ---------- Footer (5 col) ---------- */
.site-footer { background: var(--ink); color: var(--cream); padding: clamp(48px,7vw,80px) 0 40px; }
.footer-grid {
  display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr 1fr;
  gap: 32px; padding-bottom: 40px; border-bottom: 1px solid rgba(242,234,216,0.12);
}
.footer-grid .col h4 { font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.18em; color: var(--amber); margin: 0 0 16px; font-family: var(--sans); }
.footer-grid .col a, .footer-grid .col li {
  display: block; color: rgba(242,234,216,0.72); font-size: 0.92rem; padding: 3px 0;
}
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid .col a:hover { color: var(--amber); }
.footer-brand { font-family: var(--serif); font-size: 1.7rem; }
.footer-brand em { font-style: normal; color: var(--amber); }
.footer-note { color: rgba(242,234,216,0.5); font-size: 0.85rem; }
.footer-base { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 24px; font-size: 0.78rem; color: rgba(242,234,216,0.5); }

/* ---------- Claim & placeholder markers ---------- */
[data-claim] {
  text-decoration: underline;
  text-decoration-color: var(--rose);
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
  cursor: help;
}
[data-claim]:hover { background: rgba(194,78,92,0.08); }
[data-slot] {
  display: inline-block;
  background: rgba(194,78,92,0.12);
  color: var(--rose);
  border: 1px dashed rgba(194,78,92,0.5);
  border-radius: 3px;
  padding: 0 4px;
  font-weight: 600;
}
.slot-note {
  margin-top: 18px; font-size: 0.8rem; color: var(--ink-soft);
  border-top: 1px dashed rgba(194,78,92,0.4); padding-top: 14px;
}

/* ---------- Our Story ---------- */
.page-hero {
  position: relative; padding: calc(var(--header-h) + clamp(48px,9vw,110px)) var(--gutter);
  color: var(--cream);
  background: linear-gradient(165deg, var(--pine), var(--pine-deep));
  overflow: hidden;
}
.page-hero h1 { font-size: clamp(2.6rem,6vw,4.6rem); margin: 16px 0 18px; }
.page-hero p { color: rgba(242,234,216,0.82); max-width: 620px; }
.page-hero .eyebrow { color: var(--amber); }

.timeline { max-width: 760px; margin: 0 auto; position: relative; }
.timeline::before {
  content: ""; position: absolute; left: 16px; top: 0; bottom: 0; width: 1px;
  background: rgba(26,23,18,0.14);
}
.tl-item { position: relative; padding: 0 0 44px 64px; }
.tl-item::before {
  content: ""; position: absolute; left: 9px; top: 8px; width: 16px; height: 16px;
  border-radius: 50%; background: var(--amber); border: 3px solid var(--cream);
}
.tl-year { font-family: var(--serif); font-size: 1.6rem; color: var(--pine); font-style: italic; }
.tl-item h3 { font-size: 1.4rem; margin: 6px 0 8px; }
.tl-item p { color: var(--ink-soft); }

.people { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.person { background: var(--bone); border: 1px solid rgba(26,23,18,0.06); padding: clamp(24px,4vw,44px); }
.person .initials {
  width: 72px; height: 72px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--serif); font-style: italic; font-size: 2rem; color: var(--cream);
  background: var(--pine); margin-bottom: 18px;
}
.person h3 { font-size: 1.6rem; }
.person .role { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.16em; color: var(--amber); margin-bottom: 12px; }

/* ---------- Where to buy / locator ---------- */
.locator { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.locator-form { background: var(--bone); border: 1px solid rgba(26,23,18,0.06); padding: clamp(24px,4vw,40px); }
.locator-form label { display: block; font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.16em; margin-bottom: 8px; color: var(--ink-soft); }
.locator-form input {
  width: 100%; padding: 14px 16px; border: 1px solid rgba(26,23,18,0.2); background: var(--cream);
  font-family: var(--sans); font-size: 1rem; margin-bottom: 18px; color: var(--ink);
}
.locator-results { margin-top: 24px; }
.result {
  border: 1px solid rgba(26,23,18,0.1); background: var(--cream); padding: 18px; margin-bottom: 14px;
}
.result h4 { margin: 0 0 4px; font-family: var(--serif); font-size: 1.2rem; }
.result p { margin: 0; color: var(--ink-soft); font-size: 0.9rem; }

/* ---------- Product detail ---------- */
.pdp-hero {
  display: grid; grid-template-columns: 7fr 5fr; min-height: 72vh; margin-top: var(--header-h);
}
.pdp-visual {
  background: radial-gradient(120% 100% at 30% 20%, var(--bone), var(--bone-deep));
  display: flex; align-items: center; justify-content: center; color: var(--pine);
}
.pdp-visual .big { font-family: var(--serif); font-style: italic; font-size: clamp(3rem,9vw,7rem); opacity: 0.45; }
.pdp-info { padding: clamp(28px,6vw,72px); display: flex; flex-direction: column; justify-content: center; }
.pdp-info h1 { font-size: clamp(2.4rem,5vw,4rem); margin: 14px 0 16px; }
.pdp-info .lede { margin-bottom: 20px; }
.pdp-meta { display: flex; flex-wrap: wrap; gap: 12px; margin: 22px 0; }
.chip { border: 1px solid rgba(26,23,18,0.2); padding: 8px 16px; font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.12em; }
.chip.amber { border-color: var(--amber); color: var(--pine); background: rgba(201,139,59,0.12); }

/* ---------- Responsive ---------- */
@media (max-width: 1280px) {
  :root { --container: 1120px; }
  .story, .story.flip { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 900px) {
  :root { --header-h: 64px; }
  .main-nav { display: none; }
  .nav-toggle { display: block; }
  .story, .story.flip { grid-template-columns: 1fr; }
  .story-visual { min-height: 320px; }
  .story.flip .story-visual { order: 1; }
  .story.flip .story-body { order: 2; }
  .feature { grid-template-columns: 1fr; }
  .feature .feature-body { padding: 40px var(--gutter); }
  .product, .product:nth-child(even) { grid-column: span 6; }
  .product:nth-child(1), .product:nth-child(3) { margin-top: 0; }
  .product:nth-child(odd) { margin-top: 0; }
  .brand-grid { grid-template-columns: 1fr; }
  .masonry { column-count: 2; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .people { grid-template-columns: 1fr; }
  .locator { grid-template-columns: 1fr; }
  .pdp-hero { grid-template-columns: 1fr; }
  .pdp-visual { min-height: 360px; }
  .hero { min-height: 80vh; }
  .hero-word { display: none; }
}

@media (max-width: 480px) {
  .masonry { column-count: 1; }
  .showcase { grid-template-columns: 1fr; }
  .product, .product:nth-child(even) { grid-column: span 1; }
  .footer-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr; }
  .hero-actions .btn { width: 100%; justify-content: center; }
}
