/* ===== Tokens ===== */
:root {
  --ink: #0E1526;
  --flame: #FF6A00;
  --flame-dark: #E55D00;
  --slate: #7C8AA0;
  --bone: #F7F6F2;
  --white: #FFFFFF;
  --line: rgba(14, 21, 38, .08);
  --radius: 16px;
  --font-head: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bone);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }

/* ===== Typography ===== */
h1, h2, h3 { font-family: var(--font-head); line-height: 1.15; letter-spacing: -.02em; }
h1 { font-size: clamp(2.5rem, 5vw, 4rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3vw, 2rem); font-weight: 600; }
h3 { font-size: 1.15rem; font-weight: 600; }

.label {
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 12px;
}
.label .fl { color: var(--flame); }

.muted { color: var(--slate); }

/* ===== Nav ===== */
.nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 0;
}
.nav img.logo { height: 34px; width: auto; }
.nav-links { display: flex; gap: 28px; font-size: .95rem; font-weight: 500; }
.nav-links a { position: relative; color: var(--slate); transition: color .2s; }
.nav-links a:hover, .nav-links a.active { color: var(--ink); }
.nav-links a.active::after {
  content: ''; position: absolute; left: 0; bottom: -6px;
  width: 100%; height: 2px; background: var(--flame); border-radius: 2px;
}

/* ===== Buttons ===== */
.btn {
  display: inline-block; padding: 14px 28px; border-radius: 999px;
  font-weight: 600; font-size: .95rem; transition: all .2s ease;
  cursor: pointer; border: 1px solid transparent;
}
.btn-primary { background: var(--flame); color: var(--white); }
.btn-primary:hover { background: var(--flame-dark); transform: translateY(-1px); }
.btn-ghost { border-color: var(--ink); color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--white); }

/* ===== Landing ===== */
.hero {
  min-height: calc(100vh - 78px);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; gap: 24px; padding-bottom: 8vh;
}
.hero .acorn { width: 96px; animation: sway 5s ease-in-out infinite; transform-origin: bottom center; }
@keyframes sway { 0%, 100% { transform: rotate(-3deg); } 50% { transform: rotate(3deg); } }
@media (prefers-reduced-motion: reduce) { .hero .acorn { animation: none; } }
.hero p.sub { max-width: 480px; color: var(--slate); font-size: 1.05rem; }

/* ===== Sections / Cards ===== */
.section { padding: 72px 0; }
.grid { display: grid; gap: 24px; margin-top: 40px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 28px;
  transition: transform .25s ease, box-shadow .25s ease;
  display: flex; flex-direction: column; gap: 12px;
}
.card:hover { transform: translateY(-2px); box-shadow: 0 12px 32px rgba(14, 21, 38, .08); }
.card .tag {
  font-size: .72rem; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--flame);
}
.card h3 span { background-image: linear-gradient(var(--flame), var(--flame));
  background-size: 0% 2px; background-repeat: no-repeat;
  background-position: 0 100%; transition: background-size .3s; padding-bottom: 2px; }
.card:hover h3 span { background-size: 100% 2px; }
.card p { color: var(--slate); font-size: .92rem; flex-grow: 1; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font-size: .72rem; font-weight: 500; color: var(--slate);
  border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px;
  background: var(--bone);
}

/* Browser-frame mockup for web-design cards */
.frame {
  border: 1px solid var(--line); border-radius: 10px; overflow: hidden;
  background: var(--bone); margin-bottom: 4px;
}
.frame .bar { display: flex; gap: 6px; padding: 8px 12px; border-bottom: 1px solid var(--line); }
.frame .bar i { width: 8px; height: 8px; border-radius: 50%; background: #D8DCE3; }

/* ===== Filter pills ===== */
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 32px; }
.pill {
  padding: 10px 20px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--white); font-size: .88rem; font-weight: 500;
  color: var(--slate); cursor: pointer; transition: all .2s;
}
.pill:hover { border-color: var(--ink); color: var(--ink); }
.pill.active { background: var(--ink); color: var(--white); border-color: var(--ink); }

.card.hide { display: none; }
.card.reveal { animation: rise .5s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* ===== Scroll reveal ===== */
.reveal-on-scroll { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal-on-scroll.in { opacity: 1; transform: none; }

/* ===== CTA band + footer ===== */
.cta-band {
  background: var(--ink); color: var(--white); border-radius: var(--radius);
  padding: 56px 40px; text-align: center; margin: 40px 0 80px;
}
.cta-band p { color: var(--slate); margin: 12px auto 28px; max-width: 440px; }
footer { border-top: 1px solid var(--line); padding: 28px 0; }
footer .container { display: flex; justify-content: space-between; font-size: .85rem; color: var(--slate); }

/* ===== Responsive ===== */
@media (max-width: 900px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .nav-links { gap: 18px; }
}

/* ===== Growth scroll layout ===== */
.growth { display: grid; grid-template-columns: minmax(280px, 420px) 1fr; gap: 64px; }

.tree-wrap { position: relative; }
#tree { position: sticky; top: 5vh; max-height: 90vh; width: 100%; }

/* Acorn states */
#tree .shell, #tree .body { fill: none; stroke: #C9CFD9; stroke-width: 3; transition: stroke .4s; }
#tree .fill-shell { fill: var(--ink); }
#tree .fill-body  { fill: url(#gradFlame); } /* or var(--ink) for monochrome */
#leaf { fill: none; stroke: #C9CFD9; stroke-width: 3; transform-origin: 200px 80px;
        transform: scale(0); transition: transform .6s cubic-bezier(.34,1.56,.64,1); }
.is-alive #leaf { transform: scale(1); }          /* JS adds when acorn fills */
.is-alive .shell, .is-alive .body { stroke: var(--ink); }

/* Root drawing */
.root { stroke: #DDE1E8; stroke-width: 4; }
.root.drawn { stroke: var(--ink); }
.hair   { stroke: #E6E9EF; stroke-width: 2; }
.hair.drawn { stroke: var(--slate); }

/* Nodes */
.node { fill: #DDE1E8; transform-box: fill-box; transform-origin: center;
        transform: scale(0); transition: transform .5s cubic-bezier(.34,1.56,.64,1), fill .3s; }
.node.on { transform: scale(1); fill: var(--flame); }

/* Content column */
.growth-sections article {
  min-height: 85vh; display: flex; flex-direction: column; justify-content: center;
  opacity: .25; transition: opacity .5s;
}
.growth-sections article.lit { opacity: 1; }
.growth-sections h2 { margin-bottom: 12px; }
.growth-sections p.muted { max-width: 460px; }

@media (prefers-reduced-motion: reduce) {
  #tree { position: static; }
  .growth-sections article { opacity: 1; min-height: auto; padding: 48px 0; }
}
@media (max-width: 860px) {
  .growth { grid-template-columns: 1fr; }
  #tree { display: none; } /* fallback: plain sections on mobile */
}