/* ============================================================
   Bloom & Grow Co. — design concept
   "The Field Journal" — a child scientist's nature notebook.
   Paper ground · construction-paper cutouts · taped cards ·
   crayon path of discovery winding through every page.
   ============================================================ */

:root {
  --forest: #244C3A;
  --leaf: #76A84F;
  --leaf-deep: #4F7A33;
  --sun: #F2C84B;
  --sun-pale: #FBE9B7;
  --coral: #ED725D;
  --coral-ink: #B04531;   /* accessible text version of coral */
  --sky: #72B9D1;
  --sky-pale: #D9EEF5;
  --sky-ink: #23617A;     /* accessible text version of sky */
  --paper: #FFF9EC;
  --paper-deep: #FBF0D7;
  --ink: #27312D;
  --ink-soft: #46534D;
  --white: #FFFFFF;

  --font-display: "Baloo 2", "Trebuchet MS", sans-serif;
  --font-body: "Mulish", "Segoe UI", sans-serif;
  --font-hand: "Gochi Hand", "Comic Sans MS", cursive;

  --radius: 18px;
  --radius-big: 28px;
  --shadow-card: 0 6px 0 rgba(39, 49, 45, 0.08), 0 14px 30px rgba(39, 49, 45, 0.09);
  --shadow-lift: 0 10px 0 rgba(39, 49, 45, 0.06), 0 22px 44px rgba(39, 49, 45, 0.13);
  --wrap: 1120px;
}

/* ---------- Reset-ish ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background-color: var(--paper);
  /* faint paper grain */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0.15 0 0 0 0 0.19 0 0 0 0 0.17 0 0 0 0.035 0'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
}
img, svg { max-width: 100%; height: auto; }
/* illustration SVGs carry only a viewBox — give them real width or they collapse to 0 */
svg[role="img"] { width: 100%; height: auto; }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--forest); line-height: 1.15; margin: 0 0 0.5em; }
h1 { font-size: clamp(2.4rem, 5.5vw, 4rem); font-weight: 800; }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); font-weight: 700; }
h3 { font-size: clamp(1.25rem, 2.2vw, 1.55rem); font-weight: 700; }
p { margin: 0 0 1em; }
a { color: var(--sky-ink); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--coral-ink); }
ul, ol { padding-left: 1.35em; }
strong { color: var(--forest); }

/* Visible focus everywhere — crayon style */
:focus-visible {
  outline: 3px dashed var(--coral-ink);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Skip link */
.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--forest); color: var(--paper);
  padding: 0.7em 1.2em; z-index: 200; border-radius: 0 0 12px 0;
  font-weight: 700; text-decoration: none;
}
.skip-link:focus { left: 0; color: var(--paper); }

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: clamp(1.1rem, 4vw, 2rem); }

/* ---------- Hand-drawn helpers ---------- */
.hand { font-family: var(--font-hand); }
.hand-label {
  font-family: var(--font-hand);
  font-size: 1.25rem;
  color: var(--coral-ink);
  letter-spacing: 0.02em;
  display: inline-block;
  margin-bottom: 0.4rem;
}
.hand-label--leaf { color: var(--leaf-deep); }
.hand-label--sky { color: var(--sky-ink); }

/* crayon circle around a word (SVG sits behind text) */
.circled { position: relative; white-space: nowrap; }
.circled svg {
  position: absolute; inset: -0.22em -0.35em;
  width: calc(100% + 0.7em); height: calc(100% + 0.44em);
  z-index: -1; overflow: visible;
}

/* crayon underline for section intros */
.scribble-under { position: relative; display: inline-block; }
.scribble-under::after {
  content: "";
  position: absolute; left: -2%; right: -2%; bottom: -0.18em; height: 0.42em;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 12' preserveAspectRatio='none'%3E%3Cpath d='M2 8 C 20 3, 40 10, 60 6 S 100 4, 118 7' fill='none' stroke='%23F2C84B' stroke-width='5' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat center / 100% 100%;
  z-index: -1;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 249, 236, 0.94);
  backdrop-filter: blur(6px);
  border-bottom: 3px solid var(--forest);
}
.site-header .wrap {
  display: flex; align-items: center; gap: 1rem;
  min-height: 74px;
}
.brand {
  display: flex; align-items: center; gap: 0.6rem;
  text-decoration: none; margin-right: auto;
}
.brand-mark {
  width: 58px; height: auto; flex: none;
  /* real logo is a white-background JPEG; multiply melts the white into the paper header */
  mix-blend-mode: multiply;
}
.brand-name {
  font-family: var(--font-display); font-weight: 800;
  font-size: 1.35rem; color: var(--forest); line-height: 1.05;
}
.brand-name small {
  display: block; font-family: var(--font-hand); font-weight: 400;
  font-size: 0.8rem; color: var(--coral-ink); letter-spacing: 0.03em;
}
.main-nav ul { display: flex; gap: 0.2rem; list-style: none; margin: 0; padding: 0; }
.main-nav a {
  display: block; padding: 0.55em 0.75em;
  font-weight: 700; font-size: 0.98rem; color: var(--forest);
  text-decoration: none; border-radius: 10px; position: relative;
}
.main-nav a:hover { background: var(--sun-pale); color: var(--forest); }
.main-nav a[aria-current="page"] { color: var(--coral-ink); }
.main-nav a[aria-current="page"]::after {
  content: ""; position: absolute; left: 0.6em; right: 0.6em; bottom: 0.25em; height: 5px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 8' preserveAspectRatio='none'%3E%3Cpath d='M2 5 C 15 2, 30 7, 44 4 S 55 3, 58 5' fill='none' stroke='%23ED725D' stroke-width='3.5' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat center / 100% 100%;
}
.nav-cta {
  flex: none;
}

/* mobile menu button */
.menu-btn {
  display: none;
  background: none; border: 3px solid var(--forest); border-radius: 12px;
  padding: 0.45em 0.8em; font-family: var(--font-display); font-weight: 700;
  font-size: 1rem; color: var(--forest); cursor: pointer;
}
.menu-btn[aria-expanded="true"] { background: var(--sun); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-display); font-weight: 700; font-size: 1.05rem;
  padding: 0.72em 1.5em; border-radius: 999px;
  text-decoration: none; border: 3px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  cursor: pointer;
}
.btn:hover { transform: translateY(-2px) rotate(-1deg); }
.btn-primary {
  background: var(--coral); color: #3B0F06;
  border-color: var(--coral-ink);
  box-shadow: 0 4px 0 var(--coral-ink);
}
.btn-primary:hover { color: #3B0F06; box-shadow: 0 6px 0 var(--coral-ink); }
.btn-secondary {
  background: var(--sun); color: #4A3608;
  border-color: #C79A22; box-shadow: 0 4px 0 #C79A22;
}
.btn-secondary:hover { color: #4A3608; box-shadow: 0 6px 0 #C79A22; }
.btn-ghost {
  background: var(--white); color: var(--forest);
  border-color: var(--forest); box-shadow: 0 4px 0 var(--forest);
}
.btn-ghost:hover { color: var(--forest); box-shadow: 0 6px 0 var(--forest); }
.btn-big { font-size: 1.2rem; padding: 0.85em 1.9em; }

/* ---------- Sections ---------- */
.section { padding-block: clamp(3rem, 7vw, 5.5rem); position: relative; }
.section-tint-sun { background: var(--sun-pale); }
.section-tint-sky { background: var(--sky-pale); }
.section-tint-leaf { background: #E7F0DC; }
.section-tint-deep { background: var(--forest); color: var(--paper); }
.section-tint-deep h2, .section-tint-deep h3 { color: var(--paper); }
.section-tint-deep a:not(.btn) { color: var(--sun); }

.section-head { max-width: 46rem; margin-bottom: clamp(1.6rem, 4vw, 2.6rem); }
.section-head p { color: var(--ink-soft); font-size: 1.1rem; }

/* torn construction-paper edge between sections */
.torn-edge { display: block; width: 100%; height: 26px; margin-bottom: -1px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  padding-block: clamp(3.2rem, 8vw, 6.5rem) clamp(4rem, 9vw, 7rem);
  /* sky wash melting into the paper */
  background: linear-gradient(180deg, #D9EEF5 0%, #EDF3E4 45%, var(--paper) 100%);
}
.hero-hills {
  position: absolute; left: 0; right: 0; bottom: 0;
  width: 100%; height: clamp(120px, 22vw, 220px);
  z-index: 0; pointer-events: none;
}
/* full-bleed hero render: the image IS the hero, text lives in its open sky */
.hero-bg {
  position: absolute; inset: 0; z-index: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: 70% 100%;
}
/* living-sky sprites (from her layered renders) */
.hero-sunwrap {
  position: absolute; z-index: 0; pointer-events: none;
  width: clamp(240px, 28vw, 480px); aspect-ratio: 1;
  right: 2vw; top: -6vw;
}
.hero-sunrays, .hero-sundisc {
  position: absolute; inset: 0; width: 100%; height: 100%;
}
.hero-cloud { position: absolute; z-index: 0; height: auto; }
.hero-cloud--1 { top: 12%; left: 38%; width: clamp(70px, 9vw, 145px); }
.hero-cloud--2 { top: 30%; left: 55%; width: clamp(100px, 13vw, 200px); }
.hero-cloud--3 { top: 46%; left: 6%; width: clamp(80px, 10vw, 160px); }
@media (prefers-reduced-motion: no-preference) {
  .hero-sunrays { animation: raysTurn 80s linear infinite; }
  .hero-cloud--1 { animation: cloudDrift 26s ease-in-out infinite alternate; }
  .hero-cloud--2 { animation: cloudDrift 34s ease-in-out infinite alternate-reverse; }
  .hero-cloud--3 { animation: cloudDrift 42s ease-in-out infinite alternate; }
  @keyframes raysTurn { to { transform: rotate(360deg); } }
  @keyframes cloudDrift {
    from { transform: translateX(0); }
    to { transform: translateX(clamp(30px, 5vw, 80px)); }
  }
}
.hero-veil {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(90deg, rgba(255,249,236,0.85) 0%, rgba(255,249,236,0.45) 42%, rgba(255,249,236,0) 65%);
}
.hero--wide { min-height: clamp(480px, 56vw, 640px); display: flex; align-items: center; }
/* soft dissolve into the next section — no hard bottom line */
.hero--wide::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: clamp(70px, 10vw, 130px);
  background: linear-gradient(to bottom, rgba(255,249,236,0) 0%, var(--paper) 92%);
  z-index: 1; pointer-events: none;
}
.hero--wide > .wrap { position: relative; z-index: 2; width: 100%; }
.hero-copy { max-width: 36rem; }
@media (max-width: 700px) {
  .hero-veil { background: rgba(255, 249, 236, 0.68); }
  .hero--wide { min-height: 520px; }
  .hero-bg { object-position: 62% 100%; }
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(2rem, 5vw, 4rem); align-items: center; }
/* sink the hero drawing so it stands on the hills instead of floating */
.hero-art--grounded { transform: translateY(clamp(24px, 7vw, 90px)); }
.hero h1 { margin-bottom: 0.4em; }
.hero-lede { font-size: clamp(1.1rem, 2vw, 1.3rem); color: var(--ink-soft); max-width: 34rem; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 1.6rem; }
.hero-note { margin-top: 1.1rem; font-family: var(--font-hand); font-size: 1.15rem; color: var(--leaf-deep); }

/* floating construction-paper shapes */
.paper-shape { position: absolute; z-index: 0; pointer-events: none; }
.hero > .wrap { position: relative; z-index: 1; }

/* ---------- Cards ---------- */
.card-grid { display: grid; gap: 1.4rem; grid-template-columns: repeat(auto-fit, minmax(255px, 1fr)); }
.card {
  background: var(--white);
  border: 2.5px solid var(--forest);
  border-radius: var(--radius);
  padding: 1.5rem 1.5rem 1.3rem;
  box-shadow: var(--shadow-card);
  position: relative;
}
.card.taped { transform: rotate(-0.6deg); }
.card.taped:nth-child(2n) { transform: rotate(0.7deg); }
.card.taped:nth-child(3n) { transform: rotate(-0.3deg); }
.card.taped::before {
  content: "";
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%) rotate(-3deg);
  width: 92px; height: 26px;
  background: rgba(242, 200, 75, 0.65);
  border-left: 2px dashed rgba(74, 54, 8, 0.25);
  border-right: 2px dashed rgba(74, 54, 8, 0.25);
  border-radius: 2px;
}
.card h3 { margin-top: 0.4rem; }
.card p:last-child { margin-bottom: 0; }
.card-icon { width: 56px; height: 56px; margin-bottom: 0.4rem; }

/* placeholder / to-confirm chips */
.chip {
  display: inline-block; font-family: var(--font-hand); font-size: 1.02rem;
  background: var(--sun-pale); color: #6B5312;
  border: 2px dashed #C79A22; border-radius: 999px;
  padding: 0.15em 0.85em;
}
.chip--confirm { background: var(--sky-pale); color: var(--sky-ink); border-color: var(--sky-ink); }

/* callout / note blocks */
.note {
  background: var(--white);
  border: 2.5px dashed var(--sky-ink);
  border-radius: var(--radius);
  padding: 1.2rem 1.4rem;
  margin-block: 1.5rem;
}
.note--sun { border-color: #C79A22; background: var(--sun-pale); }
.note--coral { border-color: var(--coral-ink); background: #FCEAE6; }
.note h3 { margin-top: 0; font-size: 1.15rem; }
.note p:last-child { margin-bottom: 0; }

/* ---------- Steps (getting started) ---------- */
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 1.4rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); counter-reset: step; }
.steps li {
  counter-increment: step;
  background: var(--white); border: 2.5px solid var(--forest); border-radius: var(--radius);
  padding: 1.9rem 1.5rem 1.4rem; position: relative; box-shadow: var(--shadow-card);
}
.steps li::before {
  content: counter(step);
  position: absolute; top: -22px; left: 1.2rem;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--sun); color: #4A3608;
  border: 3px solid #C79A22;
  font-family: var(--font-display); font-weight: 800; font-size: 1.4rem;
  display: grid; place-items: center;
}
.steps h3 { margin-top: 0; }
.steps p:last-child { margin-bottom: 0; }

/* ---------- FAQ ---------- */
.faq-list { display: grid; gap: 0.9rem; max-width: 52rem; }
details.faq {
  background: var(--white); border: 2.5px solid var(--forest); border-radius: var(--radius);
  padding: 0; overflow: hidden; box-shadow: var(--shadow-card);
}
details.faq summary {
  cursor: pointer; list-style: none;
  font-family: var(--font-display); font-weight: 700; font-size: 1.12rem; color: var(--forest);
  padding: 1.05rem 3.2rem 1.05rem 1.3rem; position: relative;
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after {
  content: "+"; position: absolute; right: 1.1rem; top: 50%; transform: translateY(-50%);
  font-family: var(--font-hand); font-size: 1.7rem; color: var(--coral-ink);
}
details.faq[open] summary::after { content: "–"; }
details.faq[open] summary { background: var(--sun-pale); }
.faq-body { padding: 0.9rem 1.3rem 1.2rem; border-top: 2px dashed var(--paper-deep); }
.faq-body p:last-child { margin-bottom: 0; }

/* ---------- Forms ---------- */
.form-grid { display: grid; gap: 1.1rem; max-width: 40rem; }
.field label { display: block; font-weight: 800; font-family: var(--font-display); color: var(--forest); margin-bottom: 0.3rem; }
.field .hint { font-size: 0.9rem; color: var(--ink-soft); margin: 0.15rem 0 0.35rem; }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; color: var(--ink);
  background: var(--white);
  border: 2.5px solid var(--forest); border-radius: 12px;
  padding: 0.65em 0.85em;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 3px dashed var(--coral-ink); outline-offset: 2px;
}
fieldset { border: 2.5px dashed var(--leaf-deep); border-radius: var(--radius); padding: 1rem 1.2rem; margin: 0; }
legend { font-family: var(--font-display); font-weight: 700; color: var(--forest); padding-inline: 0.4em; }

/* ---------- Two-path (contact) ---------- */
.two-paths { display: grid; gap: 1.6rem; grid-template-columns: repeat(auto-fit, minmax(310px, 1fr)); align-items: start; }
.path-card {
  background: var(--white); border: 3px solid var(--forest); border-radius: var(--radius-big);
  padding: 2rem 1.8rem; box-shadow: var(--shadow-lift); position: relative;
}
.path-card--secure { border-color: var(--leaf-deep); }
.path-card--general { border-color: var(--sky-ink); }
.path-flag {
  position: absolute; top: -18px; left: 1.4rem;
  font-family: var(--font-hand); font-size: 1.2rem;
  background: var(--leaf); color: #14300A; border: 2.5px solid var(--leaf-deep);
  padding: 0.1em 0.9em; border-radius: 999px;
}
.path-card--general .path-flag { background: var(--sky); color: #0E3648; border-color: var(--sky-ink); }

/* ---------- Battery check-in ---------- */
.battery-row { display: flex; gap: clamp(1.4rem, 4vw, 2.5rem); align-items: center; flex-wrap: wrap; }
svg.battery-svg[role="img"] { width: clamp(90px, 12vw, 130px); flex: none; height: auto; }
.battery-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.9rem; flex: 1; min-width: 240px; }

/* ---------- Resource list ---------- */
.resource-grid { display: grid; gap: 1.4rem; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

/* ---------- Journal figure (illustration placeholders) ---------- */
.journal-fig {
  background: var(--white); border: 2.5px solid var(--forest); border-radius: var(--radius);
  padding: 1rem; box-shadow: var(--shadow-card); text-align: center;
}
.journal-fig figcaption { font-family: var(--font-hand); font-size: 1.05rem; color: var(--ink-soft); margin-top: 0.5rem; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--forest); color: var(--paper);
  padding: clamp(2.5rem, 6vw, 4rem) 0 2rem;
  margin-top: 0;
}
.site-footer a { color: var(--sun-pale); }
.site-footer a:hover { color: var(--sun); }
.footer-grid { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-bottom: 2rem; }
.footer-grid h3 { color: var(--sun); font-size: 1.1rem; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.4rem; }
.footer-legal {
  border-top: 2px dashed rgba(255, 249, 236, 0.3);
  padding-top: 1.4rem; font-size: 0.92rem; color: #CFE0D3;
}
.concept-ribbon {
  background: var(--sun); color: #4A3608;
  border: 2.5px dashed #C79A22; border-radius: 12px;
  font-weight: 700; padding: 0.7rem 1rem; margin-bottom: 1.6rem;
  font-size: 0.95rem;
}

/* ---------- Discovery path SVG ---------- */
.discovery-path { display: block; width: 100%; height: auto; }
.path-divider { display: block; width: min(560px, 80%); margin: 0 auto; height: auto; }

/* gentle grow-in for hero art */
@media (prefers-reduced-motion: no-preference) {
  .grow-in { animation: growIn 0.9s cubic-bezier(0.22, 1, 0.36, 1) both; }
  .grow-in-2 { animation: growIn 0.9s 0.15s cubic-bezier(0.22, 1, 0.36, 1) both; }
  .grow-in-3 { animation: growIn 0.9s 0.3s cubic-bezier(0.22, 1, 0.36, 1) both; }
  @keyframes growIn {
    from { opacity: 0; transform: translateY(18px) scale(0.97); }
    to { opacity: 1; transform: none; }
  }
  .sway { animation: sway 6s ease-in-out infinite alternate; transform-origin: bottom center; }
  @keyframes sway { from { transform: rotate(-2deg); } to { transform: rotate(2.5deg); } }
  .draw-path { stroke-dasharray: 12 10; animation: dashMove 30s linear infinite; }
  @keyframes dashMove { to { stroke-dashoffset: -440; } }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { max-width: 420px; margin-inline: auto; }

  .menu-btn { display: inline-block; }
  .main-nav {
    display: none;
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--paper);
    border-bottom: 3px solid var(--forest);
    box-shadow: 0 18px 30px rgba(39, 49, 45, 0.14);
  }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; padding: 0.6rem 1rem 1rem; }
  .main-nav a { font-size: 1.1rem; padding: 0.7em 0.8em; }
  .nav-cta { display: none; }
  .main-nav .nav-cta-mobile { display: block; padding: 0.4rem 0.8rem 0.6rem; }
}
@media (min-width: 901px) {
  .main-nav .nav-cta-mobile { display: none; }
}
@media (max-width: 560px) {
  body { font-size: 1rem; }
  .hero-ctas .btn { width: 100%; text-align: center; }
  .card.taped, .card.taped:nth-child(2n), .card.taped:nth-child(3n) { transform: none; }
}

/* ---------- Print ---------- */
@media print {
  .site-header, .site-footer, .hero-ctas, .menu-btn { display: none; }
  body { background: #fff; }
}
