/* =========================================================
   Cloudy with a Chance of Feelings: shared styles
   Art direction: pastel sky blue (#D7EEFF) as the main color,
   cloud white, navy text (#243650), small lavender and
   butter-yellow accents. Airy, rounded, easy to read from
   across a classroom.
   ========================================================= */

:root {
  /* sky */
  --sky: #D7EEFF;
  --sky-50: #F3FAFF;
  --sky-100: #E8F5FF;
  --sky-200: #D7EEFF;
  --sky-300: #B8DFFB;
  --sky-400: #82C3F1;
  --sky-600: #3F8FD9;
  --sky-800: #24507A;

  /* action blue (buttons) */
  --blue: #4096E8;
  --blue-dark: #2B77C4;
  --navy-btn: #2A5A8F;
  --navy-btn-dark: #1B3F68;

  /* accents */
  --purple-100: #F3EEFE;
  --purple-200: #E4DAFA;
  --purple-400: #BBA6EE;
  --purple-600: #7A63C6;

  --yellow-100: #FFF8DC;
  --yellow-200: #FFEFB3;
  --yellow-400: #FFD96B;
  --yellow-600: #B98E12;

  --pink-100: #FDEEF2;
  --pink-200: #FAD5DF;
  --pink-400: #F2A3B8;
  --pink-600: #C9557A;

  --mint-200: #D4F1E3;
  --mint-600: #2F8B63;

  /* text */
  --ink: #213650;
  --ink-soft: #5B6B84;
  --white: #FFFFFF;
  --cloud: #FFFFFF;

  --radius-sm: 14px;
  --radius: 22px;
  --radius-lg: 30px;
  --shadow-soft: 0 10px 30px rgba(36, 54, 80, .08);
  --shadow-card: 0 2px 0 rgba(36, 54, 80, .04), 0 12px 32px rgba(63, 143, 217, .12);

  --font-head: "Fredoka", "Baloo 2", "Trebuchet MS", system-ui, sans-serif;
  --font-body: "Nunito", "Segoe UI", system-ui, sans-serif;
  --header-h: 68px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
section[id] { scroll-margin-top: calc(var(--header-h) + 8px); }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--sky-50);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 .5em;
  color: var(--ink);
}
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); font-weight: 700; letter-spacing: -.01em; }
h2 { font-size: clamp(1.5rem, 3.2vw, 2.1rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
a { color: var(--sky-600); }
a:hover { color: var(--blue-dark); }
img, svg { max-width: 100%; }
.friend-img { display: block; max-width: 100%; height: auto; object-fit: contain; margin-inline: auto; }

.wrap { width: min(1140px, 100% - 32px); margin-inline: auto; }
main, header, footer { position: relative; }

/* ---------- Header (compact, white) ---------- */
.site-header {
  position: sticky; top: 0; z-index: 30;
  background: var(--white);
  box-shadow: 0 1px 0 rgba(36, 54, 80, .06), 0 6px 18px rgba(36, 54, 80, .05);
}
.site-header .wrap {
  min-height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--ink);
  font: 700 1.15rem/1.05 var(--font-head);
}
.brand:hover { color: var(--ink); }
.brand svg { width: 58px; height: 42px; flex: none; }
.brand-mark { width: 58px; height: 44px; flex: none; display: grid; place-items: center; }
.brand-mark svg, .brand-mark img { width: 100%; height: 100%; object-fit: contain; }
.brand span { max-width: 17ch; }

.nav-toggle {
  display: none;
  border: 0; background: var(--sky-100); color: var(--ink);
  border-radius: 999px; padding: 8px 14px; font: 800 .95rem var(--font-body);
  cursor: pointer;
}
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; align-items: center; }
.site-nav a {
  display: block; padding: 7px 14px; border-radius: 999px;
  text-decoration: none; color: var(--ink); font-weight: 700; font-size: .98rem;
}
.site-nav a:hover { background: var(--sky-100); color: var(--ink); }
.site-nav a[aria-current="page"] { background: var(--yellow-200); }

@media (max-width: 880px) {
  :root { --header-h: 58px; }
  .brand { font-size: 1rem; }
  .brand svg { width: 46px; height: 34px; }
  .brand-mark { width: 46px; height: 36px; }
  .nav-toggle { display: inline-block; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--white); box-shadow: 0 12px 20px rgba(36, 54, 80, .08);
    display: none; padding: 8px 16px 14px;
  }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; align-items: stretch; }
}

/* ---------- Buttons & chips ---------- */
.btn {
  --btn-bg: var(--blue);
  --btn-shadow: var(--blue-dark);
  --btn-ink: var(--white);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; cursor: pointer; text-decoration: none;
  font: 600 1.05rem var(--font-head);
  color: var(--btn-ink);
  background: var(--btn-bg);
  padding: 12px 24px;
  border-radius: 999px;
  box-shadow: 0 4px 0 var(--btn-shadow);
  transition: transform .12s, box-shadow .12s, filter .2s;
  user-select: none;
  white-space: nowrap;
}
.btn:hover { filter: brightness(1.05); transform: translateY(-1px); color: var(--btn-ink); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--btn-shadow); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-yellow { --btn-bg: var(--yellow-400); --btn-shadow: #E5BC3E; --btn-ink: var(--ink); }
.btn-purple { --btn-bg: var(--purple-200); --btn-shadow: var(--purple-400); --btn-ink: var(--ink); }
.btn-pink   { --btn-bg: var(--pink-400); --btn-shadow: var(--pink-600); }
.btn-ghost  { --btn-bg: var(--white); --btn-shadow: var(--sky-300); --btn-ink: var(--ink); }
.btn-navy   { --btn-bg: var(--navy-btn); --btn-shadow: var(--navy-btn-dark); }
.btn-sm { padding: 8px 16px; font-size: .95rem; }
.btn-lg { padding: 15px 30px; font-size: 1.25rem; }

:focus-visible { outline: 3px solid var(--purple-400); outline-offset: 3px; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-weight: 800; font-size: .78rem; letter-spacing: .03em; text-transform: uppercase;
  padding: 4px 12px; border-radius: 999px;
  background: var(--sky-100); color: var(--sky-800);
}
.chip-free   { background: var(--mint-200); color: #1E6B49; }
.chip-soon   { background: var(--purple-100); color: var(--purple-600); }
.chip-member { background: var(--yellow-200); color: #7A5A00; }
.chip-new    { background: var(--pink-100); color: var(--pink-600); }

/* ---------- Sections & cards ---------- */
.section { padding: 52px 0; }
.section-title { text-align: center; margin-bottom: 28px; }
.section-title p { color: var(--ink-soft); max-width: 620px; margin-inline: auto; }

.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-card);
}
.card-grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.tool-card {
  display: flex; flex-direction: column; gap: 10px;
  text-decoration: none; color: var(--ink);
  transition: transform .2s, box-shadow .2s;
}
a.tool-card:hover { transform: translateY(-4px); color: var(--ink); }
.tool-card .art {
  height: 150px; border-radius: var(--radius-sm);
  display: grid; place-items: center; background: var(--sky-100);
}
.tool-card .art svg, .tool-card .art img { height: 120px; width: auto; max-width: 90%; object-fit: contain; }
.tool-card h3 { margin: 4px 0 0; }
.tool-card p { margin: 0; color: var(--ink-soft); font-size: .95rem; }
.bg-pink   { background: var(--pink-100) !important; }
.bg-purple { background: var(--purple-100) !important; }
.bg-yellow { background: var(--yellow-100) !important; }
.bg-sky    { background: var(--sky-100) !important; }

.feature-list { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.feature { display: flex; gap: 12px; align-items: flex-start; }
.feature .icon { flex: none; width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; font-size: 1.35rem; }
.feature h3 { font-size: 1.05rem; margin-bottom: 2px; }
.feature p { margin: 0; color: var(--ink-soft); font-size: .95rem; }

/* ---------- Page heads & prose ---------- */
.page-head { text-align: center; padding: 40px 0 8px; }
.page-head p { color: var(--ink-soft); }
.prose { max-width: 760px; margin: 0 auto; }
.prose h2 { font-size: 1.45rem; margin-top: 1.6em; }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: .4em; }
.note {
  background: var(--yellow-100); border: 2px dashed var(--yellow-400);
  border-radius: var(--radius-sm); padding: 12px 16px; font-size: .95rem;
}
.fineprint { font-size: .82rem; color: var(--ink-soft); text-align: center; max-width: 720px; margin: 10px auto 0; }

/* ---------- Pricing ---------- */
.pricing { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); align-items: stretch; }
.price-card { display: flex; flex-direction: column; gap: 12px; }
.price-card .price { font-family: var(--font-head); font-size: 2.4rem; font-weight: 600; }
.price-card .price small { font-size: 1rem; color: var(--ink-soft); font-weight: 500; }
.price-card ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.price-card li { padding-left: 30px; position: relative; }
.price-card li::before {
  content: ""; position: absolute; left: 0; top: 3px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--sky-200) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3 3 7-7' stroke='%23243650' stroke-width='2.6' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/16px no-repeat;
}
.price-card.featured { outline: 3px solid var(--yellow-400); background: linear-gradient(180deg, var(--yellow-100), var(--white) 50%); }
.price-card .grow { flex: 1; }

/* ---------- Steps ---------- */
.steps { counter-reset: step; display: grid; gap: 22px 16px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.step { position: relative; padding-top: 34px; }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; top: -14px; left: 20px; width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center; font: 600 1.2rem var(--font-head);
  background: var(--yellow-200); color: var(--ink);
}

/* ---------- Home: hero ---------- */
.home-hero {
  background: linear-gradient(100deg, #E6F3FE 0%, var(--sky) 45%, #C6E4FB 100%);
  overflow: hidden;
  padding: 64px 0 56px;
}
.home-hero .wrap { display: grid; grid-template-columns: 1.35fr .9fr; gap: 24px; align-items: center; }
.home-hero h1 {
  font-size: clamp(2.5rem, 4.6vw, 4.2rem); line-height: 1.04; letter-spacing: -.025em;
  margin: 0 0 22px;
}
.hh-accent { display: block; color: var(--navy-btn); }
@media (min-width: 901px) { .hh-accent { white-space: nowrap; } }
.hh-lead { font-size: clamp(1.1rem, 1.8vw, 1.35rem); color: var(--ink-soft); max-width: 42ch; margin-bottom: 30px; }
.home-hero .btn-lg { border-radius: 14px; padding: 15px 28px; font-size: 1.2rem; }
.hh-art { position: relative; aspect-ratio: 1 / .78; }
.hh-cloud { position: absolute; fill: #fff; opacity: .75; }
.hh-spark { position: absolute; fill: #FFEDA6; }
.hh-char { position: absolute; display: grid; place-items: center; }
.hh-char img, .hh-char svg { width: 100%; height: auto; display: block; filter: drop-shadow(0 10px 18px rgba(33, 54, 80, .12)); }
.hh-iris { left: 10%; top: 22%; width: 66%; }
.hh-sunny { right: 0; top: 0; width: 34%; }

/* ---------- Home: sections ---------- */
.home-section { padding: 44px 0 8px; }
.home-section h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); margin-bottom: 22px; }
body[data-page="home"] .site-footer { margin-top: 0; }
.home-characters { margin-top: 34px; padding-bottom: 40px; background: var(--white); border-top: 1px solid rgba(33, 54, 80, .06); padding-top: 28px; }

/* ---------- Timer cards (reusable) ---------- */
.timer-cards { display: grid; gap: 16px; max-width: 920px; }
.timer-card {
  display: grid; grid-template-columns: 176px 1fr auto; gap: 24px; align-items: center;
  background: var(--white); border: 1.5px solid #DCE8F3; border-radius: 22px;
  padding: 16px 26px 16px 16px; box-shadow: 0 6px 20px rgba(33, 54, 80, .05);
  transition: box-shadow .2s, transform .2s;
}
.timer-card:hover { box-shadow: 0 12px 28px rgba(63, 143, 217, .14); transform: translateY(-2px); }
.tc-thumb {
  display: grid; place-items: center; aspect-ratio: 176 / 130;
  border-radius: 16px; border: 1.5px solid #F2E3D2;
}
.tc-thumb svg { width: 64%; height: auto; }
.tc-body h3 { font-size: 1.6rem; margin: 0 0 6px; }
.tc-body h3 a { color: var(--ink); text-decoration: none; }
.tc-body p { margin: 0; color: var(--ink-soft); font-size: 1.1rem; }
.tc-btn {
  justify-self: end; white-space: nowrap;
  background: #E3F1FD; color: var(--navy-btn);
  font: 600 1.1rem var(--font-head); text-decoration: none;
  padding: 12px 26px; border-radius: 12px;
}
.tc-btn:hover { background: #D2E8FC; color: var(--navy-btn-dark); }

/* ---------- Character grid ---------- */
.char-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.char-card {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 16px 10px 14px; border-radius: 16px;
  text-decoration: none; color: var(--ink);
  transition: transform .2s;
}
.char-card.is-white { border: 1.5px solid #DCE8F3; }
.char-card:hover { transform: translateY(-3px); color: var(--ink); }
.char-art { height: 96px; width: 100%; display: flex; align-items: center; justify-content: center; }
.char-art img, .char-art svg { max-width: 78%; max-height: 96px; width: auto; height: auto; object-fit: contain; }
.char-name { font: 600 1.12rem var(--font-head); }

@media (max-width: 900px) {
  .home-hero { padding: 36px 0 30px; }
  .home-hero .wrap { grid-template-columns: 1fr; }
  .hh-art { max-width: 460px; width: 100%; margin: 0 auto; }
  .char-grid { grid-template-columns: repeat(3, 1fr); gap: 12px; }
}
@media (max-width: 640px) {
  .home-hero { text-align: center; }
  .home-hero h1 { font-size: clamp(2rem, 8.6vw, 2.5rem); }
  .hh-lead { margin-inline: auto; }
  .timer-card { grid-template-columns: 1fr; text-align: center; padding: 14px 14px 18px; gap: 14px; }
  .tc-thumb { aspect-ratio: 16 / 8; }
  .tc-thumb svg { width: 34%; }
  .tc-btn { justify-self: stretch; text-align: center; }
  .char-grid { gap: 10px; }
  .char-card { padding: 12px 6px 10px; gap: 6px; }
  .char-art { height: 66px; }
  .char-art img, .char-art svg { max-height: 66px; max-width: 86%; }
  .char-name { font-size: 1rem; }
}

/* ---------- SEL & weather friends ---------- */
.sel-mini { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.sel-mini-card {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px;
  padding: 18px 12px 16px; border-radius: var(--radius); text-decoration: none; color: var(--ink);
  transition: transform .2s;
}
.sel-mini-card:hover { transform: translateY(-4px); color: var(--ink); }
.sel-art { height: 86px; display: grid; place-items: center; }
.sel-art svg { height: 80px; width: auto; }
.sel-art img { max-height: 80px; width: auto; max-width: 100%; }
.sel-kid { font: 600 1.1rem var(--font-head); line-height: 1.2; }
.sel-casel { font-weight: 800; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; }
.sel-full { display: grid; gap: 20px; }
.sel-card { display: grid; grid-template-columns: 170px 1fr; gap: 22px; align-items: center; scroll-margin-top: 90px; }
.sel-card h3 { font-size: 1.5rem; margin: 2px 0 6px; }
.sel-card p { color: var(--ink-soft); }
.sel-art-lg { border-radius: var(--radius); height: 150px; display: grid; place-items: center; }
.sel-art-lg svg { height: 110px; width: auto; }
.sel-art-lg img { max-height: 120px; width: auto; max-width: 90%; }
.sel-acts { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.sel-acts li { font-weight: 700; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.sel-acts li::before { content: "☁️"; }
@media (max-width: 600px) { .sel-card { grid-template-columns: 1fr; } }

.series-card { display: grid; gap: 22px; }
.series-intro { max-width: 720px; }
.books { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.book { text-align: center; }
.book h3 { margin: 12px 0 4px; font-size: 1.1rem; }
.book p { color: var(--ink-soft); font-size: .93rem; margin: 0; }
.book-cover { aspect-ratio: 4 / 3; border-radius: 10px 20px 20px 10px; display: grid; place-items: center; box-shadow: inset 10px 0 0 rgba(255,255,255,.45); }
.book-cover > div { width: 52%; height: 70%; display: grid; place-items: center; }
.book-cover svg { max-height: 100%; max-width: 100%; }
.book-cover img { max-height: 130px; max-width: 100%; }

.friends-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.friend-card { border-radius: var(--radius); padding: 14px 14px 18px; text-align: center; }
.friend-art { height: 110px; display: grid; place-items: center; margin-bottom: 6px; }
.friend-art svg, .friend-art img { max-height: 110px; width: auto; max-width: 100%; }
.friend-card h3 { margin: 0 0 4px; font-size: 1.3rem; }
.friend-card .chip { background: var(--white); text-transform: none; letter-spacing: 0; font-size: .8rem; }
.friend-card p { color: var(--ink-soft); font-size: .9rem; margin: 8px 0 0; line-height: 1.45; }

/* Weather photos with hand-drawn characters on top.
   Real photos go in assets/photos/; a soft painted sky shows until then. */
.photo-sky {
  position: relative; overflow: hidden;
  border-radius: var(--radius-lg);
  border: 5px solid var(--white);
  background-color: var(--sky-200);
  background-image:
    var(--photo, none),
    radial-gradient(ellipse 30% 18% at 22% 30%, rgba(255,255,255,.95), rgba(255,255,255,0) 70%),
    radial-gradient(ellipse 34% 20% at 70% 22%, rgba(255,255,255,.9), rgba(255,255,255,0) 70%),
    radial-gradient(ellipse 45% 22% at 50% 92%, rgba(255,255,255,.95), rgba(255,255,255,0) 70%),
    linear-gradient(180deg, #A9D7F7 0%, #CDE9FD 55%, #EEF8FF 100%);
  background-size: cover, auto, auto, auto, auto;
  background-position: center;
}
.photo-sky img, .friend-art img { filter: drop-shadow(0 6px 10px rgba(36, 54, 80, .22)); }
.friend-art.photo-sky { height: 150px; margin: 0 0 10px; border-width: 4px; border-radius: 18px; padding: 10px; }

/* ---------- Footer ---------- */
.site-footer { margin-top: 64px; background: var(--white); border-top: 1px solid rgba(36, 54, 80, .06); }
.site-footer .wrap { display: flex; gap: 16px 24px; justify-content: space-between; flex-wrap: wrap; align-items: center; padding: 22px 0; }
.site-footer nav { display: flex; gap: 6px 18px; flex-wrap: wrap; }
.site-footer a { color: var(--ink); font-weight: 700; text-decoration: none; }
.site-footer a:hover { color: var(--sky-600); }
.site-footer p { margin: 0; font-size: .9rem; color: var(--ink-soft); }

.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
