/* ==========================================================================
   BasiApps Studio — "Coloring Book" design system
   Paper-white canvas, deep-ink outlines, crayon accents, sticker shadows.
   ========================================================================== */

:root {
  /* Palette */
  --paper: #FFFDF7;
  --paper-tint: #FFF4E2;
  --white: #FFFFFF;
  --ink: #232742;
  --ink-soft: #5B6078;
  --coral: #FF6B6B;
  --sun: #FFC93C;
  --mint: #2EC4A7;
  --sky: #4D96FF;
  --grape: #9B5DE5;
  --coral-soft: #FFE3E3;
  --sun-soft: #FFF1CC;
  --mint-soft: #D9F6EF;
  --sky-soft: #DFEAFF;
  --grape-soft: #EFE3FC;

  /* Type */
  --font-display: "Baloo 2", system-ui, sans-serif;
  --font-body: "Nunito", system-ui, sans-serif;

  /* Shape */
  --line: 2.5px solid var(--ink);
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 26px;
  --shadow-card: 8px 8px 0 rgba(35, 39, 66, 0.09);

  --container: 1120px;
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.15;
  margin: 0 0 0.5em;
  letter-spacing: 0.2px;
}

h1 { font-size: clamp(2.4rem, 5.2vw, 3.7rem); font-weight: 800; }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.5rem); font-weight: 800; }
h3 { font-size: 1.25rem; font-weight: 700; }

p { margin: 0 0 1em; color: var(--ink-soft); }

a { color: var(--sky); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
  outline: 3px solid var(--sky);
  outline-offset: 3px;
  border-radius: 6px;
}

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

.section { padding: 88px 0; }
.section-tint { background: var(--paper-tint); }

/* ---------- Section headings ---------- */
.section-head { max-width: 640px; margin: 0 auto 52px; text-align: center; }
.section-head p { font-size: 1.1rem; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 6px 16px;
  box-shadow: 3px 3px 0 rgba(35, 39, 66, 0.12);
  margin-bottom: 18px;
}
.eyebrow .dot { width: 10px; height: 10px; border-radius: 50%; }
.dot-coral { background: var(--coral); }
.dot-sun   { background: var(--sun); }
.dot-mint  { background: var(--mint); }
.dot-sky   { background: var(--sky); }
.dot-grape { background: var(--grape); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--ink);
  background: var(--white);
  border: var(--line);
  border-radius: 16px;
  padding: 13px 26px;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 4px 4px 0 var(--ink);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); }
.btn:active { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--ink); }

.btn-sun   { background: var(--sun); }
.btn-coral { background: var(--coral); color: #fff; }
.btn-mint  { background: var(--mint); color: #fff; }
.btn-sm    { padding: 9px 18px; font-size: 0.95rem; border-radius: 13px; box-shadow: 3px 3px 0 var(--ink); }
.btn-lg    { padding: 16px 32px; font-size: 1.12rem; }

.btn .play-icon { width: 20px; height: 20px; }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 253, 247, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  height: 76px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  color: var(--ink);
}
.brand:hover { text-decoration: none; }
.brand .crayon { width: 34px; height: 34px; flex: none; }
.brand span { color: var(--coral); }

.nav-menu {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-menu a:not(.btn) {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  padding: 6px 2px;
  border-bottom: 3px solid transparent;
}
.nav-menu a:not(.btn):hover { text-decoration: none; border-bottom-color: var(--sun); }
.nav-menu a.active { border-bottom-color: var(--coral); }

.nav-toggle {
  display: none;
  background: var(--white);
  border: var(--line);
  border-radius: 12px;
  padding: 8px 10px;
  cursor: pointer;
  box-shadow: 3px 3px 0 var(--ink);
}
.nav-toggle svg { width: 22px; height: 22px; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 84px 0 96px; }

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 48px;
  align-items: center;
}

.hero h1 { margin-bottom: 20px; }
.hero .lede { font-size: 1.2rem; max-width: 30rem; margin-bottom: 30px; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 30px; }

.hero-note {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink-soft);
}
.hero-note .stars { color: var(--sun); letter-spacing: 2px; font-size: 1.05rem; }

/* Scribble-highlighted word — the signature */
.scribble { position: relative; display: inline-block; white-space: nowrap; }
.scribble svg {
  position: absolute;
  left: -6%;
  bottom: -0.18em;
  width: 112%;
  height: 0.55em;
  z-index: -1;
  overflow: visible;
}
.scribble svg path {
  fill: none;
  stroke: var(--coral);
  stroke-width: 14;
  stroke-linecap: round;
  opacity: 0.55;
  stroke-dasharray: 900;
  stroke-dashoffset: 900;
  animation: draw 1.1s ease-out 0.35s forwards;
}
@keyframes draw { to { stroke-dashoffset: 0; } }

/* Hero art: sticker cluster */
.hero-art { position: relative; min-height: 440px; }

.sticker-tile {
  position: absolute;
  display: grid;
  place-items: center;
  width: 118px;
  height: 118px;
  border: var(--line);
  border-radius: 26px;
  font-size: 3rem;
  background: var(--white);
  box-shadow: 6px 6px 0 rgba(35, 39, 66, 0.14);
  animation: floaty 5.5s ease-in-out infinite;
}
.sticker-tile.t1 { top: 4%;  left: 8%;  background: var(--coral-soft); transform: rotate(-7deg); }
.sticker-tile.t2 { top: 0;   right: 12%; background: var(--sky-soft);  transform: rotate(6deg);  animation-delay: 0.6s; }
.sticker-tile.t3 { top: 36%; left: 28%;  background: var(--sun-soft);  width: 150px; height: 150px; font-size: 4rem; transform: rotate(2deg); animation-delay: 1.1s; }
.sticker-tile.t4 { bottom: 6%; left: 4%; background: var(--mint-soft); transform: rotate(8deg);  animation-delay: 1.7s; }
.sticker-tile.t5 { bottom: 10%; right: 6%; background: var(--grape-soft); transform: rotate(-5deg); animation-delay: 2.3s; }

@keyframes floaty {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -10px; }
}

.sticker-badge {
  position: absolute;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  background: var(--sun);
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 7px 15px;
  box-shadow: 3px 3px 0 var(--ink);
  z-index: 2;
}
.sticker-badge.b1 { top: 30%; right: 0; transform: rotate(5deg); }
.sticker-badge.b2 { bottom: 0; left: 34%; transform: rotate(-4deg); background: var(--mint); color: #fff; }

/* Doodles: coloring-book line art floating in the background */
.doodle { position: absolute; z-index: -1; opacity: 0.85; }
.doodle path, .doodle circle, .doodle polygon {
  fill: none;
  stroke: var(--ink);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.18;
}
.doodle.filled path { fill: var(--sun); fill-opacity: 0.5; }

/* ---------- Stats strip ---------- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}

.stat-card {
  background: var(--white);
  border: var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 28px 24px;
  text-align: center;
}
.stat-card .num {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 2.3rem;
  line-height: 1.1;
}
.stat-card .num.c-coral { color: var(--coral); }
.stat-card .num.c-sun   { color: #E8A912; }
.stat-card .num.c-mint  { color: var(--mint); }
.stat-card .num.c-sky   { color: var(--sky); }
.stat-card .label { font-weight: 700; color: var(--ink); margin: 2px 0 4px; }
.stat-card .sub { font-size: 0.9rem; color: var(--ink-soft); margin: 0; }

/* ---------- App cards ---------- */
.apps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.app-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: var(--line);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-card);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.app-card:hover { transform: translateY(-6px); box-shadow: 10px 12px 0 rgba(35, 39, 66, 0.12); }

.app-card .icon-tile {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border: var(--line);
  border-radius: 22px;
  font-size: 2.6rem;
  margin-bottom: 18px;
}
.app-card .icon-tile img { width: 100%; height: 100%; object-fit: cover; border-radius: 19px; }

.tile-coral { background: linear-gradient(135deg, var(--coral-soft), #FFD1D1); }
.tile-sun   { background: linear-gradient(135deg, var(--sun-soft), #FFE49A); }
.tile-mint  { background: linear-gradient(135deg, var(--mint-soft), #B9EFE3); }
.tile-sky   { background: linear-gradient(135deg, var(--sky-soft), #C4D9FF); }
.tile-grape { background: linear-gradient(135deg, var(--grape-soft), #E0CCF8); }

.app-card h3 { margin-bottom: 6px; }
.app-card .desc { flex: 1; font-size: 0.98rem; margin-bottom: 18px; }

.app-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.chip {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.78rem;
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 3px 11px;
  background: var(--paper);
}
.chip-sun  { background: var(--sun-soft); }
.chip-mint { background: var(--mint-soft); }
.chip-sky  { background: var(--sky-soft); }

.app-card .btn { align-self: flex-start; }

/* ---------- Feature (why parents trust us) ---------- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--white);
  border: var(--line);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  box-shadow: var(--shadow-card);
}
.feature-card .icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border: 2px solid var(--ink);
  border-radius: 16px;
  font-size: 1.7rem;
  margin-bottom: 16px;
}
.feature-card p { font-size: 0.95rem; margin: 0; }

/* ---------- Steps (about page: how we build) ---------- */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  counter-reset: step;
}
.step-card {
  position: relative;
  background: var(--white);
  border: var(--line);
  border-radius: var(--radius-lg);
  padding: 30px 24px 26px;
  box-shadow: var(--shadow-card);
}
.step-card::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  top: -18px;
  left: 22px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  font-family: var(--font-display);
  font-weight: 800;
  background: var(--sun);
  border: 2px solid var(--ink);
  border-radius: 50%;
  box-shadow: 3px 3px 0 var(--ink);
}
.step-card p { font-size: 0.95rem; margin: 0; }

/* ---------- Founder / about ---------- */
.founder-card {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 28px;
  align-items: center;
  background: var(--white);
  border: var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 32px;
  max-width: 760px;
  margin-inline: auto;
}
.founder-card .avatar {
  display: grid;
  place-items: center;
  width: 130px;
  height: 130px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 2.6rem;
  color: #fff;
  background: linear-gradient(135deg, var(--sky), var(--grape));
  border: var(--line);
  border-radius: 32px;
}
.founder-card h3 { margin-bottom: 2px; }
.founder-card .role { font-weight: 700; color: var(--coral); margin-bottom: 10px; }
.founder-card p:last-child { margin: 0; }

.about-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.value-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.value-list li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  font-weight: 600;
  box-shadow: 4px 4px 0 rgba(35, 39, 66, 0.08);
}
.value-list .tick { flex: none; font-size: 1.1rem; }

/* ---------- CTA banner ---------- */
.cta-banner {
  position: relative;
  overflow: hidden;
  background: var(--ink);
  border-radius: 34px;
  border: var(--line);
  box-shadow: 10px 10px 0 rgba(35, 39, 66, 0.15);
  padding: 64px 40px;
  text-align: center;
  color: #fff;
}
.cta-banner h2 { color: #fff; }
.cta-banner p { color: #C7CBE3; max-width: 34rem; margin-inline: auto; }
.cta-banner .btn { margin-top: 12px; box-shadow: 4px 4px 0 rgba(255, 255, 255, 0.85); }
.cta-banner .confetti { position: absolute; border-radius: 50%; width: 14px; height: 14px; opacity: 0.9; }

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 40px;
  align-items: start;
}

.contact-card {
  background: var(--white);
  border: var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 28px;
  margin-bottom: 22px;
}
.contact-card h3 { display: flex; align-items: center; gap: 10px; }
.contact-card p { margin: 0; }

.form-card {
  background: var(--white);
  border: var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 34px;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 6px;
}
.field input, .field textarea, .field select {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 14px;
  padding: 12px 14px;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none;
  border-color: var(--sky);
  box-shadow: 0 0 0 4px var(--sky-soft);
}

/* ---------- Legal / prose pages ---------- */
.prose { max-width: 760px; margin-inline: auto; }
.prose h2 { font-size: 1.5rem; margin-top: 2.2em; }
.prose h3 { margin-top: 1.6em; }
.prose ul { color: var(--ink-soft); padding-left: 1.3em; }
.prose li { margin-bottom: 0.4em; }
.notice {
  background: var(--sun-soft);
  border: 2px solid var(--ink);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  font-weight: 600;
  color: var(--ink);
}

/* ---------- Page hero (inner pages) ---------- */
.page-hero {
  padding: 72px 0 56px;
  text-align: center;
  background:
    radial-gradient(circle at 12% 20%, var(--sun-soft) 0 90px, transparent 91px),
    radial-gradient(circle at 88% 30%, var(--mint-soft) 0 70px, transparent 71px),
    radial-gradient(circle at 78% 85%, var(--coral-soft) 0 60px, transparent 61px),
    var(--paper);
}
.page-hero p { max-width: 620px; margin-inline: auto; font-size: 1.15rem; }

/* ---------- Footer ---------- */
.footer-wave { display: block; width: 100%; height: 60px; margin-bottom: -1px; }
.footer-wave path { fill: var(--ink); }

.site-footer { background: var(--ink); color: #C7CBE3; padding: 56px 0 28px; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 36px;
  margin-bottom: 40px;
}
.site-footer h4 { color: #fff; font-size: 1.05rem; margin-bottom: 14px; }
.site-footer .brand { color: #fff; margin-bottom: 12px; }
.site-footer .brand span { color: var(--sun); }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.site-footer a { color: #C7CBE3; }
.site-footer a:hover { color: var(--sun); }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  padding-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  font-size: 0.9rem;
}

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.55s ease, transform 0.55s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .sticker-tile { animation: none; }
  .scribble svg path { animation: none; stroke-dashoffset: 0; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .app-card { transition: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { min-height: 360px; max-width: 520px; margin-inline: auto; width: 100%; }
  .apps-grid { grid-template-columns: repeat(2, 1fr); }
  .features-grid, .steps-grid, .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .about-cols, .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .section { padding: 64px 0; }
  .hero { padding: 56px 0 72px; }

  .nav-toggle { display: inline-flex; }
  .nav-menu {
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    background: var(--paper);
    border-bottom: var(--line);
    padding: 14px 24px 22px;
    display: none;
  }
  .nav-menu.open { display: flex; }
  .nav-menu a:not(.btn) { display: block; padding: 10px 4px; border-bottom: none; }
  .nav-menu .btn { margin-top: 8px; justify-content: center; }
}

@media (max-width: 560px) {
  .apps-grid, .features-grid, .steps-grid, .stats-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .founder-card { grid-template-columns: 1fr; text-align: center; }
  .founder-card .avatar { margin-inline: auto; }
  .hero-art { min-height: 320px; }
  .sticker-tile { width: 92px; height: 92px; font-size: 2.4rem; }
  .sticker-tile.t3 { width: 118px; height: 118px; font-size: 3rem; }
  .cta-banner { padding: 48px 24px; }
}
