/* ============================================
   FUNCTIONAL FERTILITY CO. — DESIGN SYSTEM
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;1,400&family=Jost:wght@300;400;500;600&display=swap');

:root {
  /* Palette — drawn from the logo */
  --blush: #fbf5f7;
  --blush-deep: #f4e6eb;
  --cream: #fffdfc;
  --plum-deep: #3f2e48;
  --plum: #5c4366;
  --plum-mid: #74587d;
  --mauve: #a27fa2;
  --mauve-light: #c9aec9;
  --gold: #c9a769;
  --gold-soft: #e3cf9e;
  --rose: #b9697a;
  --sage: #8a9b87;
  --line: #e3d2da;

  /* Type */
  --display: 'Cormorant Garamond', serif;
  --body: 'Jost', sans-serif;

  --max-width: 1180px;
}

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

body {
  margin: 0;
  font-family: var(--body);
  background: var(--blush);
  color: var(--plum-mid);
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

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

h1, h2, h3, h4 {
  font-family: var(--display);
  color: var(--plum-deep);
  margin: 0;
  font-weight: 500;
  line-height: 1.15;
}

p { margin: 0 0 1.1em 0; }

.eyebrow {
  font-family: var(--body);
  font-size: 0.74rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--mauve);
  font-weight: 500;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}

/* Visible keyboard focus */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}

/* ============================================
   HEADER / NAV
   ============================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(251, 245, 247, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.nav-wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 18px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand img { height: 44px; width: auto; }

.brand-text {
  font-family: var(--display);
  font-size: 1.05rem;
  letter-spacing: 0.08em;
  color: var(--plum-deep);
}

.brand-text span { color: var(--mauve); }

nav.main-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

nav.main-nav a {
  font-size: 0.86rem;
  letter-spacing: 0.04em;
  color: var(--plum);
  position: relative;
  padding: 4px 0;
  transition: color 0.2s ease;
}

nav.main-nav a:hover { color: var(--plum-deep); }

nav.main-nav a.current::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 1px;
  background: var(--gold);
}

.nav-cta {
  font-family: var(--body);
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  padding: 11px 24px;
  background: var(--plum-deep);
  color: var(--cream) !important;
  border-radius: 2px;
  transition: background 0.25s ease;
  white-space: nowrap;
}

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

.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.menu-toggle span {
  display: block;
  width: 26px;
  height: 1.5px;
  background: var(--plum-deep);
  margin: 6px 0;
}

@media (max-width: 880px) {
  nav.main-nav {
    position: fixed;
    top: 78px;
    left: 0; right: 0;
    background: var(--blush);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: flex-start;
    gap: 22px;
    padding: 28px 32px 32px;
    transform: translateY(-110%);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    pointer-events: none;
  }
  nav.main-nav.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  .menu-toggle { display: block; }
  .nav-cta { align-self: flex-start; }
}

/* ============================================
   CONSTELLATION MOTIF — signature element
   the rising dotted line from the logo, repurposed
   as a literal cycle-phase / temperature-rise diagram
   ============================================ */
.constellation-divider {
  width: 100%;
  display: block;
  margin: 0 auto;
}

.constellation-divider .path {
  fill: none;
  stroke: var(--mauve-light);
  stroke-width: 1.2;
  stroke-dasharray: 1 7;
  stroke-linecap: round;
}

.constellation-divider .star {
  fill: var(--gold);
}

.constellation-divider .node {
  fill: var(--mauve);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-block;
  font-family: var(--body);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  padding: 16px 36px;
  border-radius: 2px;
  transition: all 0.25s ease;
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--plum-deep);
  color: var(--cream);
}
.btn-primary:hover { background: var(--mauve); transform: translateY(-1px); }

.btn-outline {
  background: transparent;
  border-color: var(--plum-deep);
  color: var(--plum-deep);
}
.btn-outline:hover { background: var(--plum-deep); color: var(--cream); }

.btn-ghost {
  background: transparent;
  color: var(--mauve);
  border-bottom: 1px solid var(--mauve);
  border-radius: 0;
  padding: 4px 0;
}
.btn-ghost:hover { color: var(--plum-deep); border-color: var(--plum-deep); }

/* ============================================
   SECTION SPACING
   ============================================ */
section { padding: 100px 0; }
section.tight { padding: 70px 0; }

@media (max-width: 768px) {
  section { padding: 64px 0; }
  section.tight { padding: 48px 0; }
}

/* ============================================
   FOOTER
   ============================================ */
footer {
  background: var(--plum-deep);
  color: var(--blush-deep);
  padding: 64px 0 32px;
}

footer .footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

footer h4 {
  color: var(--gold-soft);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-family: var(--body);
  margin-bottom: 18px;
}

footer a { color: var(--blush-deep); opacity: 0.85; }
footer a:hover { opacity: 1; color: var(--gold-soft); }

footer .footer-links { display: flex; flex-direction: column; gap: 12px; font-size: 0.92rem; }

footer .brand-text { color: var(--blush); }
footer .brand-text span { color: var(--mauve-light); }

footer .disclaimer {
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: 28px;
  font-size: 0.8rem;
  opacity: 0.65;
  line-height: 1.6;
}

footer .copyright {
  margin-top: 18px;
  font-size: 0.78rem;
  opacity: 0.5;
}

@media (max-width: 768px) {
  footer .footer-grid { grid-template-columns: 1fr; gap: 32px; }
}

/* ============================================
   RESPONSIVE GRID FIXES
   (targets inline grid-template-columns used on
   the signal cards and numbered method rows)
   ============================================ */
@media (max-width: 760px) {
  section .container > div[style*="grid-template-columns: repeat(3"] {
    grid-template-columns: 1fr !important;
  }
  section .container > div[style*="grid-template-columns: 90px 1fr"] {
    grid-template-columns: 1fr !important;
  }
  section .container > div[style*="grid-template-columns: 90px 1fr"] > div:first-child {
    margin-bottom: -8px;
  }
  section .container > div[style*="grid-template-columns: 260px 1fr"] {
    grid-template-columns: 1fr !important;
    text-align: center;
  }
  section .container > div[style*="grid-template-columns: 260px 1fr"] > div:first-child {
    margin: 0 auto;
    max-width: 260px;
  }
}

/* ============================================
   UTILITY
   ============================================ */
.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }
.mb-0 { margin-bottom: 0; }

.fade-up {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.fade-up.in-view {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .fade-up { opacity: 1; transform: none; }
}
