/* Together, Unprocessed — Brand Design System */
/* Version 1.0 */

:root {
  /* Primary */
  --green: #387F45;
  --green-hover: #2d6938;
  --olive: #70A24E;
  --golden: #E0A53D;

  /* Secondary */
  --light-orange: #F3E0B8;
  --teal: #377A86;

  /* Neutrals */
  --cream: #FEFBF3;
  --white: #FFFFFF;
  --dark: #2A2A2A;
  --medium: #4A4A4A;
  --light: #6A6A6A;
  --muted: #9a9084;

  /* Feedback */
  --error: #c0392b;

  /* Typography */
  --font-display: 'DM Serif Display', serif;
  --font-body: 'DM Sans', sans-serif;

  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;

  /* Radius */
  --radius: 10px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: var(--font-body);
  background: var(--cream);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-xl) var(--space-lg);
}

.container {
  max-width: 460px;
  width: 100%;
  text-align: center;
}

/* Logo */
.logo-wrap {
  margin-bottom: var(--space-xl);
  animation: fadeDown 0.8s ease-out;
}
.logo-wrap img {
  width: 140px;
  height: auto;
  filter: drop-shadow(0 4px 12px rgba(56, 127, 69, 0.1));
}

/* Typography */
.headline {
  font-family: var(--font-display);
  font-size: 2.1rem;
  line-height: 1.2;
  color: var(--green);
  margin-bottom: var(--space-md);
  animation: fadeUp 0.8s ease-out 0.15s both;
}
.subtext {
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--medium);
  margin-bottom: var(--space-xl);
  animation: fadeUp 0.8s ease-out 0.3s both;
}
.subtext strong {
  color: var(--teal);
  font-weight: 500;
}

/* Form */
.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  animation: fadeUp 0.8s ease-out 0.45s both;
}
.email-input {
  width: 100%;
  padding: var(--space-md) 1.25rem;
  font-family: var(--font-body);
  font-size: 1rem;
  border: 2px solid var(--light-orange);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--dark);
  outline: none;
  transition: border-color 0.3s ease;
}
.email-input:focus { border-color: var(--golden); }
.email-input::placeholder { color: #b0a898; }

/* Buttons */
.submit-btn {
  width: 100%;
  padding: var(--space-md);
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  background: var(--green);
  color: var(--white);
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.3s ease;
}
.submit-btn:hover {
  background: var(--green-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(56, 127, 69, 0.25);
}
.submit-btn:active { transform: translateY(0); }
.submit-btn:disabled {
  background: #9abfa0;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.download-btn {
  display: inline-block;
  padding: var(--space-md) var(--space-xl);
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 700;
  background: var(--green);
  color: var(--white);
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s ease;
}
.download-btn:hover {
  background: var(--green-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(56, 127, 69, 0.25);
}

/* Supporting text */
.trust-line {
  margin-top: var(--space-md);
  font-size: 0.8rem;
  color: var(--muted);
  animation: fadeUp 0.8s ease-out 0.6s both;
}
.error-msg {
  color: var(--error);
  font-size: 0.85rem;
  margin-top: var(--space-xs);
  display: none;
}
.divider {
  width: 40px;
  height: 3px;
  background: var(--golden);
  border-radius: 2px;
  margin: var(--space-xl) auto;
  animation: fadeUp 0.8s ease-out 0.7s both;
}
.brand-line {
  font-size: 0.85rem;
  color: var(--olive);
  font-weight: 500;
  animation: fadeUp 0.8s ease-out 0.8s both;
}
/* Success state */
.success-msg { display: none; animation: fadeUp 0.5s ease-out; }
.success-msg h2 {
  font-family: var(--font-display);
  color: var(--green);
  font-size: 1.6rem;
  margin-bottom: var(--space-sm);
}
.success-msg p {
  color: var(--medium);
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: var(--space-lg);
}

/* Purchase disclosure (paid product landing pages) */
.purchase-disclosure {
  margin-top: var(--space-sm);
  font-size: 0.78rem;
  color: var(--muted);
}
.purchase-disclosure a {
  color: var(--muted);
  text-decoration: underline;
}

/* Legal footer links */
.page-legal-links {
  margin-top: var(--space-md);
  font-size: 0.78rem;
  color: var(--muted);
}
.page-legal-links a {
  color: var(--muted);
  text-decoration: underline;
}
.page-legal-links a:hover { color: var(--medium); }

/* Animations */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ─────────────────────────────────────────────────────────────
   Product pages (/guides/[slug]/, /shop/[slug]/)
   ───────────────────────────────────────────────────────────── */
.product-body {
  display: block;
  align-items: initial;
  justify-content: initial;
  padding: 0;
  background: var(--cream);
  position: relative;
}
.product-body::after {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none; z-index: 9999; opacity: 0.4;
}
.product-container {
  max-width: 1040px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-lg);
  text-align: left;
  position: relative;
  z-index: 1;
}
.product-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: var(--space-md);
}
.product-header__logo img {
  width: 86px; height: auto;
  filter: drop-shadow(0 2px 8px rgba(56, 127, 69, 0.12));
}
.product-header__nav a {
  margin-left: var(--space-lg);
  color: var(--medium);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  position: relative;
  padding-bottom: 2px;
  transition: color 0.2s ease;
}
.product-header__nav a::after {
  content: '';
  position: absolute; left: 0; bottom: 0;
  width: 100%; height: 1.5px;
  background: var(--golden);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.3s ease;
}
.product-header__nav a:hover { color: var(--green); }
.product-header__nav a:hover::after { transform: scaleX(1); }

/* Hero — cover floats with a real frame, page background is calm */
.product-hero {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  padding: clamp(1.5rem, 4vw, 3rem) 0 clamp(2rem, 5vw, 3.5rem);
  animation: fadeUp 0.8s ease-out 0.1s both;
}
/* Cover hero: real 3D perspective on a small stack of pages.
   The whole group (cover + 2 stacked pages) tilts forward very
   slightly via perspective() + rotateY/rotateX, so the cover reads
   as a physical booklet you could pick up rather than a flat image
   with offset rectangles behind it. */
/* Cover hero: a 6-layer stack (cover + 5 cream pages) using stacked
   solid box-shadows. Each shadow is one page with a sharp top-and-left
   edge in a slightly darker cream than the one above. Reads instantly
   as a multi-page PDF guide. No rotation — the stack does the work. */
.product-hero__media {
  position: relative;
  /* Reserve room for the stack to peek out beyond the cover */
  margin-right: 36px;
  margin-bottom: 36px;
}
.product-hero__media img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow:
    /* Page 5 (closest behind cover, lightest cream) */
    6px 6px 0 0 #fdf8ea, 6px 6px 0 1px rgba(0, 0, 0, 0.05),
    /* Page 4 */
    12px 12px 0 0 #faf2db, 12px 12px 0 1px rgba(0, 0, 0, 0.06),
    /* Page 3 */
    18px 18px 0 0 #f4ebd0, 18px 18px 0 1px rgba(0, 0, 0, 0.06),
    /* Page 2 */
    24px 24px 0 0 #ede2c2, 24px 24px 0 1px rgba(0, 0, 0, 0.07),
    /* Page 1 (deepest, darkest cream) */
    30px 30px 0 0 #e3d6ad, 30px 30px 0 1px rgba(0, 0, 0, 0.07),
    /* Atmospheric drop under the whole stack */
    24px 44px 60px -22px rgba(0, 0, 0, 0.18),
    8px 16px 24px -12px rgba(0, 0, 0, 0.10);
}
.product-hero__eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-xs);
  border-bottom: 1.5px solid var(--golden);
}
.product-hero__title {
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 4vw, 2.8rem);
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--green);
  margin-bottom: var(--space-md);
}
.product-hero__subtitle {
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--medium);
  margin-bottom: var(--space-xl);
  max-width: 32em;
}
.product-hero__pricerow {
  display: flex;
  align-items: baseline;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
}
.product-hero__price {
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--dark);
  line-height: 1;
}
.product-hero__price-currency {
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.buy-button-mount { margin-bottom: var(--space-md); max-width: 26rem; }
.buy-button {
  width: 100%;
  padding: 1rem var(--space-xl);
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  background: var(--green);
  color: var(--white);
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  box-shadow: 0 4px 12px rgba(56, 127, 69, 0.18);
}
.buy-button::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, transparent 0%, rgba(255,255,255,0.08) 50%, transparent 100%);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
}
.buy-button:hover:not(:disabled)::before { transform: translateX(100%); }
.buy-button:hover:not(:disabled) {
  background: var(--green-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(56, 127, 69, 0.28);
}
.buy-button:active:not(:disabled) { transform: translateY(0); }
.buy-button:disabled,
.buy-button[aria-busy="true"] {
  background: #9abfa0;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
.buy-button-error {
  margin-top: var(--space-xs);
  font-size: 0.9rem;
  color: var(--error);
}

/* Sections — wider rhythm, hairline rule, golden accent on h2 */
.product-section {
  padding: clamp(2rem, 5vw, 3.5rem) 0;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}
.product-section h2 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 1.9rem);
  color: var(--green);
  margin-bottom: var(--space-lg);
  position: relative;
  padding-left: 0;
}
.product-section h2::before {
  content: '';
  display: block;
  width: 32px; height: 3px;
  background: var(--golden);
  border-radius: 2px;
  margin-bottom: var(--space-sm);
}

/* Long-form description: typographic care */
.product-description {
  font-size: 1.05rem;
  max-width: 38em;
}
.product-description p {
  line-height: 1.75;
  margin-bottom: var(--space-md);
  color: var(--medium);
}
.product-description ul {
  list-style: none;
  margin: 0 0 var(--space-lg) 0;
  padding: 0;
}
.product-description ul li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: var(--space-sm);
  color: var(--medium);
  line-height: 1.6;
}
.product-description ul li::before {
  content: '';
  position: absolute;
  left: 0; top: 0.6rem;
  width: 8px; height: 2px;
  background: var(--golden);
}
.product-description h3 {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--teal);
  margin: var(--space-xl) 0 var(--space-sm);
  padding-bottom: var(--space-xs);
  border-bottom: 1px solid rgba(55, 122, 134, 0.18);
}
.product-description h3:first-child { margin-top: 0; }
.product-description strong { color: var(--dark); }

.product-preview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--space-md);
}
.product-preview img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

/* Features — counter-numbered, no boxes */
.product-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(1.25rem, 3vw, 2rem) var(--space-xl);
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: feature;
}
.product-features li {
  position: relative;
  padding-left: 3rem;
  color: var(--medium);
  line-height: 1.55;
  counter-increment: feature;
  font-size: 1rem;
}
.product-features li::before {
  content: counter(feature, decimal-leading-zero);
  position: absolute;
  left: 0; top: -2px;
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--golden);
  line-height: 1;
}
.product-features li::after {
  content: '';
  position: absolute;
  left: 0; bottom: -1rem;
  width: 24px; height: 1px;
  background: rgba(0, 0, 0, 0.08);
}

/* FAQ — questions weighted, divided */
.product-faq dl { display: block; }
.product-faq dt {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--green);
  margin-top: var(--space-lg);
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}
.product-faq dl dt:first-of-type { border-top: none; padding-top: 0; margin-top: 0; }
.product-faq dd {
  margin: var(--space-sm) 0 0 0;
  color: var(--medium);
  line-height: 1.7;
  font-size: 1rem;
}
.product-faq dd a { color: var(--teal); }

.product-disclaimer {
  margin: var(--space-xl) 0;
  padding: var(--space-lg);
  background: rgba(243, 224, 184, 0.35);
  border-left: 3px solid var(--golden);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 0.94rem;
  color: var(--medium);
  line-height: 1.65;
}
.product-disclaimer strong { color: var(--dark); }

.product-footer {
  text-align: center;
  margin-top: var(--space-xl);
  padding-top: var(--space-xl);
}
.product-footer .divider {
  margin: var(--space-xl) auto var(--space-lg);
}

/* Section entrance animations */
.product-section { animation: fadeUp 0.7s ease-out both; }
.product-section:nth-of-type(1) { animation-delay: 0.05s; }
.product-section:nth-of-type(2) { animation-delay: 0.10s; }
.product-section:nth-of-type(3) { animation-delay: 0.15s; }
.product-section:nth-of-type(4) { animation-delay: 0.20s; }

@media (max-width: 720px) {
  .product-hero {
    grid-template-columns: minmax(0, 1fr);
    padding: var(--space-md) 0 var(--space-xl);
    gap: var(--space-xl);
    perspective: none;
  }
  .product-hero__media,
  .product-hero__media:hover {
    transform: none;
  }
  .product-hero__title { font-size: 1.85rem; }
  .product-header__logo img { width: 68px; }
  .product-header__nav a { margin-left: var(--space-md); font-size: 0.9rem; }
  .product-features li { padding-left: 2.5rem; }
}

/* ─────────────────────────────────────────────────────────────
   Product index pages (/guides/, /shop/)
   ───────────────────────────────────────────────────────────── */
.product-index-hero {
  padding: clamp(2rem, 5vw, 3.5rem) 0 clamp(2.5rem, 5vw, 4rem);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
  animation: fadeUp 0.7s ease-out 0.1s both;
}
.product-index-hero .product-hero__title {
  font-size: clamp(2.4rem, 5vw, 3.5rem);
  margin-bottom: var(--space-md);
}
.product-index-hero .product-hero__subtitle {
  font-size: 1.15rem;
  max-width: 36em;
}

.product-index {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 320px));
  gap: clamp(1.5rem, 3vw, 2.5rem);
  list-style: none;
  margin: 0;
  padding: 0;
  justify-content: start;
}
.product-index a {
  display: flex;
  flex-direction: column;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  color: inherit;
  text-decoration: none;
  position: relative;
  transition: transform 0.25s ease;
}
.product-index a:hover { transform: translateY(-3px); }
.product-index a:hover img {
  box-shadow:
    0 1px 2px rgba(56, 127, 69, 0.10),
    0 18px 44px -12px rgba(56, 127, 69, 0.32),
    0 36px 64px -24px rgba(0, 0, 0, 0.20);
}
.product-index img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  margin-bottom: var(--space-md);
  box-shadow:
    0 1px 2px rgba(56, 127, 69, 0.08),
    0 12px 32px -10px rgba(56, 127, 69, 0.22),
    0 24px 48px -20px rgba(0, 0, 0, 0.16);
  transition: box-shadow 0.3s ease;
}
.product-index h3 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  line-height: 1.2;
  color: var(--green);
  margin-bottom: var(--space-xs);
}
.product-index p {
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--medium);
  margin-bottom: var(--space-sm);
}
.product-index .price {
  display: inline-block;
  margin-top: auto;
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--dark);
  padding-top: var(--space-xs);
  border-top: 1.5px solid var(--golden);
  letter-spacing: 0.02em;
}
