/* ============================================================
   components.css — reusable UI: buttons, header, footer, cards,
   badges, pills, blobs, phone mockup, FAB, forms
   ============================================================ */

/* ============ Buttons ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  padding: 0.95rem 1.6rem;
  border-radius: var(--r-pill);
  transition: transform var(--t-fast) var(--ease),
              box-shadow var(--t) var(--ease),
              background var(--t) var(--ease);
  white-space: nowrap;
  border: 2px solid transparent;
}
.btn:hover { transform: translateY(-3px); }
.btn:active { transform: translateY(-1px); }
.btn svg { width: 1.1em; height: 1.1em; }

.btn--primary {
  background: var(--purple-600);
  color: var(--white);
  box-shadow: var(--shadow-brand);
}
.btn--primary:hover { background: var(--purple-700); }

.btn--coral {
  background: var(--coral);
  color: var(--white);
  box-shadow: var(--shadow-coral);
}
.btn--coral:hover { background: #ff7388; }

.btn--ghost {
  background: var(--white);
  color: var(--purple-700);
  border-color: var(--lavender-300);
  box-shadow: var(--shadow-xs);
}
.btn--ghost:hover { border-color: var(--purple-400); background: var(--lavender-50); }

.btn--on-brand {
  background: var(--white);
  color: var(--purple-700);
  box-shadow: 0 16px 30px rgba(0,0,0,0.18);
}
.btn--outline-light {
  background: transparent;
  color: var(--white);
  border-color: rgba(255,255,255,0.6);
}
.btn--outline-light:hover { background: rgba(255,255,255,0.12); }

.btn--sm { padding: 0.6rem 1.1rem; font-size: 0.92rem; }
.btn--lg { padding: 1.1rem 2rem; font-size: 1.1rem; }
.btn--block { width: 100%; }

/* Text link with arrow */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--purple-600);
}
.link-arrow svg { transition: transform var(--t) var(--ease); width: 1.05em; }
.link-arrow:hover svg { transform: translateX(5px); }

/* ============ Header / Nav ============ */
.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  transition: background var(--t) var(--ease), box-shadow var(--t) var(--ease);
  background: transparent;
}
.site-header.is-stuck {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(140%) blur(12px);
  box-shadow: var(--shadow-sm);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
  padding-block: 1rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.45rem;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.brand__mark { width: 38px; height: 38px; flex: none; }
.brand small {
  display: block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--purple-500);
  margin-top: 2px;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: clamp(0.3rem, 1.4vw, 1.2rem);
}
.nav__link {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1rem;
  color: var(--ink-soft);
  padding: 0.5rem 0.7rem;
  border-radius: var(--r-pill);
  position: relative;
  transition: color var(--t-fast) var(--ease), background var(--t-fast) var(--ease);
}
.nav__link:hover { color: var(--purple-700); }
.nav__link.is-active { color: var(--purple-700); }
.nav__link.is-active::after {
  content: "";
  position: absolute;
  left: 50%; bottom: 2px;
  transform: translateX(-50%);
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--coral);
}
.nav__links .btn { display: none; } /* in-menu CTA shows on mobile only */
.nav__actions { display: flex; align-items: center; gap: 0.8rem; }

.nav__toggle {
  display: none;
  width: 46px; height: 46px;
  border-radius: var(--r-md);
  background: var(--white);
  box-shadow: var(--shadow-xs);
  position: relative;
}
.nav__toggle span,
.nav__toggle span::before,
.nav__toggle span::after {
  content: "";
  position: absolute;
  left: 50%; top: 50%;
  width: 20px; height: 2.4px;
  background: var(--ink);
  border-radius: 2px;
  transform: translate(-50%, -50%);
  transition: transform var(--t) var(--ease), opacity var(--t-fast) var(--ease);
}
.nav__toggle span::before { transform: translate(-50%, -7px); }
.nav__toggle span::after  { transform: translate(-50%, 7px); }
.nav.is-open .nav__toggle span { background: transparent; }
.nav.is-open .nav__toggle span::before { transform: translate(-50%, 0) rotate(45deg); }
.nav.is-open .nav__toggle span::after  { transform: translate(-50%, 0) rotate(-45deg); }

@media (max-width: 940px) {
  .nav__toggle { display: block; }
  .nav__links {
    position: fixed;
    inset: 0 0 0 auto;
    width: min(82vw, 340px);
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
    background: var(--white);
    padding: 6rem 1.6rem 2rem;
    box-shadow: var(--shadow-lg);
    transform: translateX(110%);
    transition: transform var(--t) var(--ease);
    overflow-y: auto;
  }
  .nav.is-open .nav__links { transform: translateX(0); }
  .nav__link { width: 100%; font-size: 1.15rem; padding: 0.7rem 0.9rem; }
  .nav__link.is-active::after { left: 0.9rem; transform: none; }
  .nav__actions .btn--header { display: none; }
  .nav__links .btn { display: inline-flex; width: 100%; margin-top: 0.6rem; }
  .nav-scrim {
    position: fixed; inset: 0;
    background: rgba(42, 35, 80, 0.42);
    opacity: 0; visibility: hidden;
    transition: opacity var(--t) var(--ease), visibility var(--t);
    z-index: calc(var(--z-header) - 1);
  }
  .nav.is-open ~ .nav-scrim,
  body.nav-open .nav-scrim { opacity: 1; visibility: visible; }
}

/* ============ Cards ============ */
.card {
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: clamp(1.4rem, 3vw, 2rem);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line);
  transition: transform var(--t) var(--ease), box-shadow var(--t) var(--ease);
  position: relative;
  overflow: hidden;
}
.card--hover:hover { transform: translateY(-8px); box-shadow: var(--shadow-md); }
.card__icon {
  width: 60px; height: 60px;
  display: grid; place-items: center;
  border-radius: var(--r-md);
  margin-bottom: 1rem;
}
.card__icon svg { width: 32px; height: 32px; }
.card h3 { margin-bottom: 0.5rem; }
.card p { font-size: var(--fs-body); }

/* Numbered pillar card (Incredible-style faded number) */
.pillar {
  position: relative;
  padding-top: 2.2rem;
}
.pillar__num {
  position: absolute;
  top: -0.6rem; right: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 5.2rem;
  line-height: 1;
  color: var(--lavender-200);
  z-index: 0;
  pointer-events: none;
}
.pillar > * { position: relative; z-index: 1; }

/* Circular icon badge (who-we-help) */
.badge-circle {
  width: 84px; height: 84px;
  border-radius: 50%;
  display: grid; place-items: center;
  box-shadow: var(--shadow-sm);
  margin-inline: auto;
}
.badge-circle svg { width: 42px; height: 42px; }

/* tints */
.tint-purple { background: var(--lavender-200); color: var(--purple-600); }
.tint-teal   { background: var(--teal-soft);  color: #16a99a; }
.tint-sun    { background: var(--sun-soft);   color: #d99b00; }
.tint-coral  { background: var(--coral-soft); color: #e85d70; }
.tint-sky    { background: var(--sky-soft);   color: #2f8fe0; }
.tint-mint   { background: var(--mint-soft);  color: #4faf2f; }

/* ============ Pills / chips / tags ============ */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--fs-sm);
  padding: 0.4rem 0.9rem;
  border-radius: var(--r-pill);
  background: var(--lavender-200);
  color: var(--purple-700);
}
.tag {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.28rem 0.7rem;
  border-radius: var(--r-pill);
}
.tag--research { background: var(--sky-soft);   color: #2f8fe0; }
.tag--ai       { background: var(--lavender-200); color: var(--purple-700); }
.tag--bd       { background: var(--mint-soft);  color: #3f9a26; }
.tag--awareness{ background: var(--coral-soft); color: #e85d70; }

/* ============ Feature list with check ============ */
.checklist { display: grid; gap: 0.85rem; }
.checklist li {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
  font-size: var(--fs-body);
}
.checklist li::before {
  content: "";
  flex: none;
  width: 24px; height: 24px;
  margin-top: 1px;
  border-radius: 50%;
  background: var(--mint-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234faf2f' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 13l4 4L19 7'/%3E%3C/svg%3E") center / 15px no-repeat;
}

/* ============ Phone mockup (CSS) ============ */
.phone {
  width: 270px;
  max-width: 100%;
  aspect-ratio: 9 / 18.5;
  background: var(--ink);
  border-radius: 38px;
  padding: 12px;
  box-shadow: var(--shadow-lg);
  position: relative;
}
.phone::before {
  content: "";
  position: absolute;
  top: 14px; left: 50%; transform: translateX(-50%);
  width: 90px; height: 20px;
  background: var(--ink);
  border-radius: var(--r-pill);
  z-index: 3;
}
.phone__screen {
  width: 100%; height: 100%;
  border-radius: 28px;
  background: var(--lavender-50);
  overflow: hidden;
  position: relative;
}

/* Phone-screen UI (used on home, solution, for-parents) */
.appscreen { position: absolute; inset: 0; display: flex; flex-direction: column; padding: 44px 15px 15px; }
.appscreen__top { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.appscreen__top .dot { width: 30px; height: 30px; border-radius: 50%; background: var(--lavender-200); flex: none; }
.appscreen__hi { font-family: var(--font-display); font-weight: 700; color: var(--ink); font-size: 0.95rem; line-height: 1.15; }
.appscreen__hi small { display: block; font-family: var(--font-body); font-weight: 600; color: var(--ink-faint); font-size: 0.7rem; }
.appcard { background: #fff; border-radius: 16px; padding: 12px; box-shadow: var(--shadow-xs); margin-bottom: 10px; }
.appcard__bar { height: 8px; border-radius: 6px; background: var(--lavender-200); margin-top: 7px; }
.appcard__bar.is-fill { background: linear-gradient(90deg, var(--purple-500), var(--teal)); width: 72%; }
.appcard__label { font-family: var(--font-display); font-weight: 600; color: var(--ink); font-size: 0.8rem; display: flex; justify-content: space-between; }
.appchip { display: inline-flex; gap: 5px; align-items: center; font-size: 0.66rem; font-weight: 700; font-family: var(--font-display); color: var(--purple-700); background: var(--lavender-100); padding: 4px 9px; border-radius: 999px; }
.appscreen__cta { margin-top: auto; background: var(--purple-600); color: #fff; border-radius: 14px; text-align: center; padding: 11px; font-family: var(--font-display); font-weight: 600; font-size: 0.85rem; }

/* ============ Floating help button (FAB) ============ */
.fab {
  position: fixed;
  right: clamp(1rem, 3vw, 2rem);
  bottom: clamp(1rem, 3vw, 2rem);
  z-index: var(--z-fab);
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--purple-600);
  color: var(--white);
  padding: 0.7rem 1.1rem 0.7rem 0.8rem;
  border-radius: var(--r-pill);
  box-shadow: var(--shadow-brand);
  font-family: var(--font-display);
  font-weight: 600;
  transition: transform var(--t) var(--ease), background var(--t) var(--ease);
}
.fab:hover { transform: translateY(-3px) scale(1.02); background: var(--purple-700); }
.fab__dot {
  width: 34px; height: 34px; border-radius: 50%;
  background: rgba(255,255,255,0.18);
  display: grid; place-items: center;
}
.fab__dot svg { width: 20px; height: 20px; }
@media (max-width: 560px) { .fab__label { display: none; } .fab { padding: 0.7rem; } }

/* ============ Forms ============ */
.field { display: grid; gap: 0.45rem; }
.field label {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  font-size: var(--fs-sm);
}
.input, .textarea, .select {
  width: 100%;
  background: var(--white);
  border: 2px solid var(--line);
  border-radius: var(--r-md);
  padding: 0.85rem 1rem;
  color: var(--ink);
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.input:focus, .textarea:focus, .select:focus {
  outline: none;
  border-color: var(--purple-400);
  box-shadow: 0 0 0 4px var(--lavender-200);
}
.textarea { min-height: 130px; resize: vertical; }

/* ============ Footer ============ */
.site-footer {
  background: var(--ink);
  color: rgba(255, 255, 255, 0.72);
  padding-top: clamp(3rem, 6vw, 5rem);
  margin-top: var(--space-7);
  border-top-left-radius: clamp(28px, 6vw, 64px);
  border-top-right-radius: clamp(28px, 6vw, 64px);
}
.site-footer a { transition: color var(--t-fast) var(--ease); }
.site-footer a:hover { color: var(--white); }
.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: clamp(1.6rem, 4vw, 3rem);
  padding-bottom: var(--space-7);
}
.footer__brand .brand { color: var(--white); }
.footer__brand p { color: rgba(255,255,255,0.6); margin-top: 1rem; max-width: 34ch; }
.footer__col h4 {
  color: var(--white);
  font-size: 1.05rem;
  margin-bottom: 1rem;
}
.footer__col li { margin-bottom: 0.6rem; }
.footer__social { display: flex; gap: 0.6rem; margin-top: 1.2rem; }
.footer__social a {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  display: grid; place-items: center;
}
.footer__social a:hover { background: var(--purple-500); }
.footer__social svg { width: 18px; height: 18px; }
.footer__news { display: flex; gap: 0.5rem; margin-top: 1rem; }
.footer__news input {
  flex: 1;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.16);
  border-radius: var(--r-pill);
  padding: 0.7rem 1rem;
  color: var(--white);
}
.footer__news input::placeholder { color: rgba(255,255,255,0.5); }
.footer__bottom {
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-block: 1.4rem 2rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: var(--fs-sm);
  color: rgba(255,255,255,0.55);
}
@media (max-width: 760px) {
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 460px) {
  .footer__grid { grid-template-columns: 1fr; }
}

/* ============ News cards (home + news + article) ============ */
.news-card {
  background: var(--surface);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line);
  overflow: hidden;
  transition: transform var(--t) var(--ease), box-shadow var(--t) var(--ease);
}
.news-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.news-card__link { display: flex; flex-direction: column; height: 100%; }
.news-card__thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  display: grid; place-items: center;
  overflow: hidden;
}
.news-card__thumb-icon { color: rgba(255,255,255,0.92); }
.news-card__thumb-icon svg { width: 54px; height: 54px; }
.news-card__thumb-blob {
  position: absolute; width: 130px; height: 130px; border-radius: 50%;
  right: -36px; bottom: -46px; background: rgba(255,255,255,0.18);
}
.news-card__ext {
  position: absolute; top: 10px; right: 10px;
  font-family: var(--font-display); font-weight: 600; font-size: 0.7rem;
  color: var(--ink); background: rgba(255,255,255,0.92);
  padding: 3px 9px; border-radius: 999px;
}
.news-card__body { padding: 1.3rem; display: flex; flex-direction: column; gap: 0.6rem; flex: 1; }
.news-card__title { font-size: 1.12rem; line-height: 1.25; }
.news-card__link:hover .news-card__title { color: var(--purple-700); }
.news-card__excerpt { font-size: var(--fs-sm); color: var(--ink-soft); }
.news-card__meta {
  margin-top: auto; padding-top: 0.4rem;
  display: flex; align-items: center; gap: 0.5rem;
  font-size: var(--fs-xs); color: var(--ink-faint); font-weight: 700;
}
.dot-sep { color: var(--lavender-300); }

/* Filter pills */
.filter-pills { display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: center; }
.filter-pill {
  font-family: var(--font-display); font-weight: 500; font-size: 0.95rem;
  padding: 0.55rem 1.15rem; border-radius: var(--r-pill);
  background: var(--white); color: var(--ink-soft);
  border: 2px solid var(--line);
  transition: all var(--t-fast) var(--ease);
}
.filter-pill:hover { border-color: var(--purple-300); color: var(--purple-700); }
.filter-pill.is-active { background: var(--purple-600); color: #fff; border-color: var(--purple-600); }

/* ============ FAQ accordion ============ */
.faq { max-width: 760px; margin-inline: auto; display: grid; gap: 0.8rem; }
.faq__item {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-md);
  box-shadow: var(--shadow-xs); overflow: hidden;
  transition: box-shadow var(--t) var(--ease);
}
.faq__item.is-open { box-shadow: var(--shadow-sm); }
.faq__q {
  width: 100%; display: flex; justify-content: space-between; align-items: center;
  gap: 1rem; padding: 1.1rem 1.3rem; text-align: left;
  font-family: var(--font-display); font-weight: 600; color: var(--ink); font-size: 1.06rem;
}
.faq__q:hover { color: var(--purple-700); }
.faq__ico {
  position: relative; flex: none; width: 28px; height: 28px; border-radius: 50%;
  background: var(--lavender-200); transition: background var(--t) var(--ease), transform var(--t) var(--ease);
}
.faq__ico::before, .faq__ico::after {
  content: ""; position: absolute; left: 50%; top: 50%; background: var(--purple-600);
  border-radius: 2px; transform: translate(-50%, -50%);
}
.faq__ico::before { width: 12px; height: 2.4px; }
.faq__ico::after  { width: 2.4px; height: 12px; transition: transform var(--t) var(--ease); }
.faq__item.is-open .faq__ico { background: var(--purple-600); }
.faq__item.is-open .faq__ico::before { background: #fff; }
.faq__item.is-open .faq__ico::after { background: #fff; transform: translate(-50%, -50%) rotate(90deg); }
.faq__a { max-height: 0; overflow: hidden; transition: max-height var(--t) var(--ease); }
.faq__a-inner { padding: 0 1.3rem 1.2rem; color: var(--ink-soft); }
.faq__a-inner p { font-size: var(--fs-body); }

/* ============ App-store badges ============ */
.store-badges { display: flex; gap: 0.8rem; flex-wrap: wrap; }
.store-badge {
  display: inline-flex; align-items: center; gap: 0.7rem;
  background: var(--ink); color: #fff; border-radius: 14px; padding: 0.6rem 1.1rem;
}
.store-badge svg { width: 26px; height: 26px; flex: none; }
.store-badge small { display: block; font-size: 0.62rem; opacity: 0.8; }
.store-badge strong { font-family: var(--font-display); font-weight: 600; font-size: 1rem; line-height: 1; }

/* ============ Shared sub-page hero ============ */
.page-hero {
  position: relative;
  padding-top: clamp(2.5rem, 5vw, 4rem);
  padding-bottom: clamp(2.5rem, 5vw, 4rem);
  text-align: center;
  overflow: hidden;
}
.page-hero__bg {
  position: absolute; inset: 0; z-index: 0;
  background: radial-gradient(60% 80% at 50% -10%, var(--lavender-200), transparent 70%);
}
.page-hero .container { position: relative; z-index: 1; }
.page-hero h1 { font-size: var(--fs-h1); margin-top: 1rem; }
.page-hero p { margin-inline: auto; margin-top: 1.1rem; }
.page-hero__art { margin-top: 2rem; }

/* ============ CTA band ============ */
.cta-band {
  position: relative;
  overflow: hidden;
  border-radius: var(--r-xl);
  background: linear-gradient(130deg, var(--purple-600), var(--purple-500) 60%, var(--purple-400));
  color: var(--white);
  padding: clamp(2.4rem, 6vw, 4.5rem);
  text-align: center;
}
.cta-band h2 { color: var(--white); margin-bottom: 0.8rem; }
.cta-band p { color: rgba(255,255,255,0.88); margin-inline: auto; max-width: 52ch; }
.cta-band__actions {
  display: flex; gap: 0.9rem; justify-content: center; flex-wrap: wrap;
  margin-top: 1.8rem;
}
.cta-band .blob { opacity: 0.5; }
