/* Wild Wisdom — shared design system.
   Palette, typography and section layout carried over from the existing visual identity. */

:root {
  --forest: #0D2B1F;
  --sage: #2C5F3F;
  --gold: #C9A84C;
  --gold-light: #E8D5A3;
  --cream: #F8F5EE;
  --warm-gray: #8B8579;
  --near-black: #1C1C1C;
  --light-sage: #E8F0EA;
  --white: #ffffff;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--cream);
  color: var(--near-black);
  font-weight: 300;
  line-height: 1.7;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 400;
  line-height: 1.15;
}

/* NAV */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  background: rgba(13, 43, 31, 0.97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(201, 168, 76, 0.2);
}

.nav-logo {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--white);
  letter-spacing: 0.08em;
  text-decoration: none;
}

.nav-logo span { color: var(--gold); }

.nav-cta {
  background: var(--gold);
  color: var(--forest);
  padding: 10px 22px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background 0.2s ease;
  white-space: nowrap;
}

.nav-cta:hover { background: var(--gold-light); }

/* BUTTONS */
.btn-primary {
  background: var(--gold);
  color: var(--forest);
  padding: 16px 36px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background 0.2s ease, transform 0.2s ease;
  display: inline-block;
}

.btn-primary:hover { background: var(--gold-light); transform: translateY(-1px); }

/* HERO */
.hero {
  min-height: 100vh;
  background: var(--forest);
  display: flex;
  align-items: center;
  padding: 140px 24px 80px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -200px; right: -200px;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(201,168,76,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero-inner { position: relative; z-index: 2; max-width: 640px; }

.hero h1 {
  font-size: clamp(2.5rem, 5.8vw, 4.8rem);
  color: var(--white);
  margin-bottom: 30px;
  font-weight: 300;
  letter-spacing: -0.01em;
}

.hero h1 em { color: var(--gold); font-style: italic; }

.hero-sub {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.78);
  max-width: 600px;
  margin-bottom: 40px;
  font-weight: 300;
  line-height: 1.65;
}

.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; }

/* Static hero visual — an abstract conversion-path motif rendered from the palette (no video, no figures).
   z-index:1 establishes a stacking context so the visual and its ::before stay behind .hero-inner (z-index:2). */
.hero-visual {
  position: absolute;
  right: 0; top: 0; bottom: 0;
  width: 50%;
  pointer-events: none;
  overflow: hidden;
  z-index: 1;
  background:
    radial-gradient(circle at 72% 50%, rgba(201,168,76,0.16) 0%, transparent 55%),
    linear-gradient(135deg, var(--sage) 0%, var(--forest) 72%);
}

/* Contained within .hero-visual's stacking context — cannot overlay .hero-inner. */
.hero-visual::before {
  content: '';
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 55%;
  background: linear-gradient(to right, var(--forest), transparent);
  z-index: 1;
}

.hero-visual svg {
  position: absolute;
  top: 50%;
  right: -8%;
  transform: translateY(-50%);
  width: 118%;
  height: auto;
}

/* SECTIONS */
section { padding: 120px 24px; }

.wrap { max-width: 1120px; margin: 0 auto; }
.wrap-narrow { max-width: 780px; margin: 0 auto; }

.section-eyebrow {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 20px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

/* restrained gold accent rule preceding the eyebrow label */
.section-eyebrow::before {
  content: '';
  width: 28px;
  height: 1px;
  background: var(--gold);
  opacity: 0.8;
}

.section-title {
  font-size: clamp(2.3rem, 4.4vw, 3.6rem);
  color: var(--forest);
  margin-bottom: 28px;
  max-width: 840px;
  letter-spacing: -0.015em;
  line-height: 1.08;
}

.section-title em { color: var(--sage); font-style: italic; }

.prose p {
  font-size: 1.02rem;
  color: #16211B;
  max-width: 700px;
  margin-bottom: 20px;
  line-height: 1.85;
}

.prose p:last-child { margin-bottom: 0; }

/* Lead paragraph — a clearly differentiated intro size. */
.lead {
  font-size: 1.25rem !important;
  line-height: 1.65 !important;
  color: var(--near-black);
  max-width: 760px;
  margin-bottom: 24px;
}
.bg-forest .lead { color: rgba(255,255,255,0.92); }

.muted { color: var(--warm-gray) !important; }

/* Section colour variants */
.bg-forest { background: var(--forest); }
.bg-forest .section-title { color: var(--white); }
.bg-forest .prose p { color: rgba(255,255,255,0.82); }
.bg-white { background: var(--white); }
.bg-cream { background: var(--cream); }

/* EXAMPLE CARDS (The blind spot) */
.example-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin: 44px 0; }
.example-card {
  background: var(--cream);
  border: 1px solid rgba(13,43,31,0.12);
  border-radius: 3px;
  padding: 32px 28px;
  box-shadow: 0 1px 2px rgba(13,43,31,0.04), 0 14px 32px rgba(13,43,31,0.06);
}
.example-marker {
  display: block;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 4px rgba(201,168,76,0.16);
  margin-bottom: 22px;
}
.example-card p { font-size: 1.05rem; color: var(--forest); line-height: 1.55; font-weight: 400; max-width: none; }

/* LAYER CARDS (What Wild Wisdom does) */
.layers { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 52px; }
.layer-card {
  background: rgba(255,255,255,0.035);
  border: 1px solid rgba(201,168,76,0.18);
  border-radius: 3px;
  padding: 44px 38px;
}
.layer-head {
  display: flex;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 26px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(201,168,76,0.22);
}
.layer-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.7rem;
  color: var(--gold);
  line-height: 1;
  font-weight: 500;
}
.layer-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.55rem;
  color: var(--white);
  font-weight: 500;
  line-height: 1.15;
}
.layer-card p { font-size: 0.96rem; color: rgba(255,255,255,0.8); line-height: 1.8; margin-bottom: 16px; }
.layer-card p:last-child { margin-bottom: 0; }

.closes-loop {
  margin-top: 24px;
  background: var(--forest);
  border: 1px solid rgba(201,168,76,0.18);
  border-left: 3px solid var(--gold);
  padding: 36px;
}
.closes-loop h3 { font-size: 1.4rem; color: var(--white); margin-bottom: 12px; font-weight: 500; }
.closes-loop p { font-size: 0.95rem; color: rgba(255,255,255,0.72); line-height: 1.8; }

/* PRODUCT INTERFACE — illustrative monitoring view (static; demo-ready container) */
.product-section .section-title { max-width: 900px; }
.product-media { margin: 48px 0 40px; }

.browser-window {
  background: var(--white);
  border: 1px solid rgba(13,43,31,0.14);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(13,43,31,0.05), 0 30px 60px -22px rgba(13,43,31,0.28);
}
.bw-chrome {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  background: var(--forest);
  border-bottom: 1px solid rgba(201,168,76,0.25);
}
.bw-dots { display: inline-flex; gap: 7px; }
.bw-dots i { width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,0.28); display: block; }
.bw-label {
  margin-left: auto;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid rgba(201,168,76,0.4);
  padding: 5px 13px;
  border-radius: 999px;
}
.bw-body { padding: 6px 6px 10px; background: var(--white); }

.console { width: 100%; border-collapse: collapse; }
.console thead th {
  text-align: left;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--warm-gray);
  padding: 16px 18px;
  border-bottom: 1px solid rgba(13,43,31,0.12);
}
.console tbody td {
  padding: 17px 18px;
  font-size: 0.95rem;
  color: var(--near-black);
  border-bottom: 1px solid rgba(13,43,31,0.07);
  vertical-align: middle;
}
.console tbody tr:last-child td { border-bottom: none; }
.console tbody tr:hover { background: rgba(201,168,76,0.05); }
.console td[data-label="Location"] {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  color: var(--forest);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 500;
  padding: 5px 13px;
  border-radius: 999px;
  white-space: nowrap;
  color: var(--forest);
}
.pill::before { content: ''; width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.pill-ok { background: rgba(44,95,63,0.12); }
.pill-ok::before { background: var(--sage); }
.pill-warn { background: rgba(201,168,76,0.18); }
.pill-warn::before { background: var(--gold); }
.pill-alert { background: var(--gold); font-weight: 600; }
.pill-alert::before { background: var(--forest); }

/* Disabled demo control (video-ready placeholder) */
.demo-control {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  margin-top: 16px;
  padding: 16px 20px;
  background: var(--forest);
  border: 1px solid rgba(201,168,76,0.25);
  border-radius: 10px;
  color: var(--white);
  font-family: 'DM Sans', sans-serif;
  cursor: pointer;
  text-align: left;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.demo-control:hover { border-color: rgba(201,168,76,0.55); background: #0B241A; }
.demo-control:hover .demo-play { background: rgba(201,168,76,0.16); }
.demo-play {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid rgba(201,168,76,0.5);
  color: var(--gold);
  background: rgba(201,168,76,0.08);
}
.demo-play-tri {
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 7px 0 7px 12px;
  border-color: transparent transparent transparent currentColor;
  margin-left: 3px;
}
.demo-control-label { font-size: 0.92rem; letter-spacing: 0.03em; color: rgba(255,255,255,0.9); }
.product-lead { margin-top: 40px; }

/* Visible focus states */
.demo-control:focus-visible,
.modal-close:focus-visible,
.modal-video:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

/* DEMO VIDEO MODAL */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(13,43,31,0.74);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}
.modal-overlay[hidden] { display: none; }
body.modal-open { overflow: hidden; }

.modal-panel {
  width: 100%;
  max-width: 940px;
  max-height: calc(100vh - 48px);
  overflow: auto;
  background: var(--cream);
  border: 1px solid rgba(201,168,76,0.3);
  border-radius: 12px;
  box-shadow: 0 40px 90px -24px rgba(0,0,0,0.55);
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  border-bottom: 1px solid rgba(13,43,31,0.1);
}
.modal-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.5rem, 2.6vw, 1.9rem);
  color: var(--forest);
  font-weight: 500;
}
.modal-close {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.74rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--forest);
  background: transparent;
  border: 1px solid rgba(13,43,31,0.28);
  border-radius: 999px;
  padding: 9px 16px;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.modal-close:hover { background: var(--gold); border-color: var(--gold); }
.modal-close-x { font-size: 1.2rem; line-height: 1; }

.modal-media { padding: 24px 24px 0; }
.modal-video {
  display: block;
  width: 100%;
  height: auto;
  background: #000;
  border-radius: 6px;
  border: 1px solid rgba(13,43,31,0.12);
}
.modal-desc {
  padding: 20px 24px 26px;
  font-size: 0.95rem;
  color: var(--near-black);
  line-height: 1.7;
}

@media (prefers-reduced-motion: no-preference) {
  .modal-overlay { animation: modalFade 0.16s ease-out; }
  @keyframes modalFade { from { opacity: 0; } to { opacity: 1; } }
}

/* LISTS */
.check-list { list-style: none; margin-top: 28px; max-width: 760px; }
.check-list li {
  font-size: 0.95rem;
  color: var(--near-black);
  padding: 14px 0 14px 28px;
  position: relative;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  line-height: 1.7;
}
.check-list li::before {
  content: '';
  position: absolute;
  left: 0; top: 22px;
  width: 8px; height: 8px;
  background: var(--gold);
}
.bg-forest .check-list li { color: rgba(255,255,255,0.75); border-bottom: 1px solid rgba(255,255,255,0.1); }

/* THE LOOP — horizontal six-step sequence (01–06) with connecting lines */
.loop-steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 28px;
  margin-top: 56px;
}
.loop-step { position: relative; }
.loop-num {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(201,168,76,0.6);
  border-radius: 50%;
  background: var(--cream);
  color: var(--gold);
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  margin-bottom: 24px;
  position: relative;
  z-index: 1;
}
/* connecting line running from this node toward the next */
.loop-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 24px;
  left: 56px;
  width: calc(100% + 28px - 56px);
  height: 1px;
  background: rgba(201,168,76,0.4);
}
.loop-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.4rem;
  color: var(--forest);
  font-weight: 500;
  margin-bottom: 12px;
}
.loop-step p {
  font-size: 0.86rem;
  color: #33372F;
  line-height: 1.6;
}

/* CALLOUT / NOTICE */
.callout {
  background: var(--light-sage);
  border-left: 4px solid var(--sage);
  padding: 28px 32px;
  max-width: 760px;
  margin: 0 0 8px;
}
.callout p { font-size: 0.98rem; color: var(--near-black); line-height: 1.8; }

.note-block {
  background: var(--forest);
  border-left: 3px solid var(--gold);
  padding: 28px 32px;
  max-width: 760px;
  margin-top: 32px;
}
.note-block p { font-size: 0.92rem; color: rgba(255,255,255,0.75); line-height: 1.8; }

/* FOUNDER (single column) */
.founder { background: var(--forest); }
.founder-single { max-width: 820px; margin: 0 auto; }
.founder .section-title { color: var(--white); max-width: 100%; }
.founder-bio { font-size: 0.98rem; color: rgba(255,255,255,0.6); line-height: 1.85; margin-bottom: 20px; max-width: 720px; }
.founder-operated { font-size: 0.92rem; color: rgba(255,255,255,0.75); margin-bottom: 0; }
.credentials-plain {
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid rgba(201,168,76,0.25);
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  letter-spacing: 0.04em;
  line-height: 1.9;
}

/* FINAL CTA */
.final-cta { background: var(--forest); text-align: center; padding: 120px 24px; }
.final-cta .section-title { color: var(--white); margin: 0 auto 32px; text-align: center; max-width: 760px; }
.final-cta .cta-lead { font-size: 1.1rem; color: rgba(255,255,255,0.7); max-width: 620px; margin: 0 auto 36px; }

/* PAGE HEADER (interior pages) */
.page-header { background: var(--forest); padding: 160px 24px 80px; }
.page-header .section-title { color: var(--white); margin-bottom: 0; }
.page-header .page-eyebrow {
  font-size: 0.72rem; font-weight: 500; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 16px;
}

/* SUB-HEADINGS inside content sections */
.sub-heading {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--forest);
  margin-bottom: 16px;
  font-weight: 500;
}
.bg-forest .sub-heading { color: var(--white); }
.content-block { margin-bottom: 64px; max-width: 820px; }
.content-block:last-child { margin-bottom: 0; }

/* FOOTER */
footer {
  background: var(--near-black);
  padding: 40px 24px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-logo { font-family: 'Cormorant Garamond', serif; font-size: 1.1rem; color: var(--white); letter-spacing: 0.08em; }
.footer-logo span { color: var(--gold); }
.footer-links { display: flex; gap: 24px; flex-wrap: wrap; }
.footer-links a { font-size: 0.75rem; color: rgba(255,255,255,0.4); text-decoration: none; letter-spacing: 0.05em; transition: color 0.2s ease; }
.footer-links a:hover { color: var(--gold); }
.footer-copy { font-size: 0.72rem; color: rgba(255,255,255,0.3); width: 100%; margin-top: 8px; }

/* RESPONSIVE */
@media (max-width: 768px) {
  .hero { padding: 120px 24px 64px; }
  .hero-visual { display: none; }
  .hero-inner { max-width: 100%; }
  section { padding: 76px 24px; }
  .layers { grid-template-columns: 1fr; }
  .example-cards { grid-template-columns: 1fr; gap: 16px; }
  .page-header { padding: 130px 24px 60px; }
  footer { flex-direction: column; align-items: flex-start; }
  .final-cta { padding: 80px 24px; }

  /* The loop stacks vertically on mobile; connectors hidden. */
  .loop-steps { grid-template-columns: 1fr; gap: 0; margin-top: 36px; }
  .loop-step { padding: 26px 0; border-top: 1px solid rgba(0,0,0,0.1); }
  .loop-step:last-child { border-bottom: 1px solid rgba(0,0,0,0.1); }
  .loop-num { margin-bottom: 16px; }
  .loop-step:not(:last-child)::after { display: none; }

  /* Product interface: table becomes stacked cards — no horizontal scroll. */
  .product-media { margin: 32px 0; }
  .console thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .console, .console tbody, .console tr, .console td { display: block; width: 100%; }
  .console tbody tr {
    border: 1px solid rgba(13,43,31,0.14);
    border-radius: 8px;
    margin-bottom: 14px;
    background: var(--white);
    overflow: hidden;
  }
  .console tbody tr:last-child { margin-bottom: 0; }
  .console tbody tr:hover { background: var(--white); }
  .console tbody td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 13px 16px;
    border-bottom: 1px solid rgba(13,43,31,0.07);
  }
  .console tbody tr td:last-child { border-bottom: none; }
  .console td[data-label]::before {
    content: attr(data-label);
    font-family: 'DM Sans', sans-serif;
    font-size: 0.62rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--warm-gray);
    font-weight: 500;
    flex-shrink: 0;
  }
  .console td[data-label="Location"] { font-size: 1.1rem; }
  .demo-control { flex-wrap: wrap; gap: 12px; }
  .demo-control-badge { margin-left: 0; }
}
