/* Flibop website. Colours mirror the app's "school" theme (DesignSystem/Themes/ThemeCatalog.swift). */
:root {
  --bg: #FFF4DE;
  --surface: #FFFCF4;
  --primary: #C2410C;
  --on-primary: #FFFFFF;
  --accent: #FFC23D;
  --text: #2A1E14;
  --text-2: #6A5444;
  --ink: #2A1E14;
  --tint-1: #FFC4AE;
  --tint-2: #B4E8C2;
  --tint-3: #D6C8FF;
  --tint-4: #FFE38A;
  --tint-5: #AEDCFF;
  --radius: 26px;
  --shadow: 4px 4px 0 var(--ink);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1E1B33;
    --surface: #2C2847;
    --primary: #FF9466;
    --on-primary: #1E1B33;
    --accent: #FFC857;
    --text: #FBF1DE;
    --text-2: #D2C4B0;
    --ink: #0B0914;
    --tint-1: #5C2E24;
    --tint-2: #1F4A33;
    --tint-3: #3B3266;
    --tint-4: #564414;
    --tint-5: #1E3D5E;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: ui-rounded, "SF Pro Rounded", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.55;
}
img { max-width: 100%; height: auto; }
a { color: var(--primary); }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; hyphens: auto; overflow-wrap: break-word; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.2rem; }

.top, main, footer { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding-top: 16px; padding-bottom: 16px; flex-wrap: wrap;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 800; font-size: 1.4rem; color: var(--text); text-decoration: none;
}
.brand img { border-radius: 10px; }
.top nav { display: flex; gap: 18px; flex-wrap: wrap; }
.top nav a { color: var(--text); text-decoration: none; font-weight: 600; }
.top nav a[aria-current="page"], .top nav a:hover { color: var(--primary); }

.hero {
  display: grid; grid-template-columns: 1fr auto; gap: 32px; align-items: center;
  padding: 32px 0 48px;
}
.hero .mascot { width: clamp(140px, 22vw, 264px); }
.lead { font-size: 1.2rem; color: var(--text-2); max-width: 38em; }
.badge {
  display: inline-flex; flex-direction: column; gap: 2px; margin-top: 12px;
  background: var(--primary); color: var(--on-primary);
  border: 2.5px solid var(--ink); border-radius: 22px; box-shadow: var(--shadow);
  padding: 12px 22px; font-weight: 700;
}
.badge small { font-weight: 500; opacity: .85; }

.features { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.feature {
  display: flex; flex-direction: column; gap: 16px;
  background: var(--surface); border: 2.5px solid var(--ink); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 20px; overflow: hidden;
}
.feature:nth-child(5n+1) { background: var(--tint-1); }
.feature:nth-child(5n+2) { background: var(--tint-2); }
.feature:nth-child(5n+3) { background: var(--tint-3); }
.feature:nth-child(5n+4) { background: var(--tint-4); }
.feature:nth-child(5n+5) { background: var(--tint-5); }
.feature img {
  align-self: center; width: 62%; border-radius: 22px; border: 2.5px solid var(--ink);
}
.feature p { margin: 0; }

.card {
  background: var(--surface); border: 2.5px solid var(--ink); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 24px; margin: 32px 0;
}
.grows { display: flex; align-items: center; gap: 24px; }
.grows img { width: 160px; flex: none; }
.grows p { margin: 0; }
.parents ul { padding-left: 1.2em; }
.parents li { margin: .3em 0; }

.page { padding: 16px 0 32px; max-width: 760px; }
.prose h2 { margin-top: 1.6em; }
.prose h3 { margin-top: 1.2em; }
.muted { color: var(--text-2); }
.faq details {
  background: var(--surface); border: 2.5px solid var(--ink); border-radius: 18px;
  padding: 14px 18px; margin: 12px 0;
}
.faq summary { font-weight: 700; cursor: pointer; }
.faq details p { margin: .6em 0 0; }
.button {
  display: inline-block; background: var(--primary); color: var(--on-primary); text-decoration: none;
  border: 2.5px solid var(--ink); border-radius: 22px; box-shadow: var(--shadow);
  padding: 10px 20px; font-weight: 700;
}

footer { text-align: center; padding-top: 32px; padding-bottom: 40px; color: var(--text-2); }
footer p { margin: .4em 0; }
footer .links { display: flex; justify-content: center; gap: 20px; flex-wrap: wrap; }

@media (max-width: 640px) {
  .hero { grid-template-columns: 1fr; text-align: center; padding-top: 8px; }
  .hero .mascot { order: -1; justify-self: center; width: 150px; }
  .lead { margin-left: auto; margin-right: auto; }
  .grows { flex-direction: column; text-align: center; }
  .top { justify-content: center; }
}

.notfound { text-align: center; margin: 0 auto; }
.notfound img { width: 160px; }
.notfound > div + div { margin-top: 32px; padding-top: 24px; border-top: 2px dashed var(--text-2); }
