/* Math Learner website: the app's glossy candy look (Lilita One titles, Andika text, ink outlines). */
:root {
  --ink: #1d2a5c;
  --ink-2: #3b4c86;
  --sky: #7fcbff;
  --sky-deep: #3aa0f0;
  --paper: #ffffff;
  --mint: #2fbf4a;
  --mint-deep: #1d8a33;
  --sun: #ffd23d;
  --title: 'Lilita One', 'Arial Rounded MT Bold', system-ui, sans-serif;
  --read: 'Andika', 'Trebuchet MS', system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; color: var(--ink); font: 400 18px/1.55 var(--read); overflow-x: hidden;
  background: #9fd8ff linear-gradient(180deg, #bfe6ff 0, var(--sky) 640px, #9fd8ff 1600px) no-repeat;
}
a { color: var(--sky-deep); font-weight: 700; }
img { max-width: 100%; height: auto; display: block; }
.wrap { width: min(1080px, 100% - 32px); margin: 0 auto; }

/* Top bar */
.top { padding: 14px 0; }
.top .wrap { display: flex; align-items: center; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand img { width: 46px; height: 46px; border-radius: 12px; border: 3px solid var(--ink); box-shadow: 0 3px 0 var(--ink); }
.brand b { font: 400 26px/1 var(--title); }
.top nav { margin-left: auto; display: flex; gap: 6px; }
.top nav a { padding: 8px 12px; border-radius: 12px; color: var(--ink); text-decoration: none; }
.top nav a:hover, .top nav a:focus-visible { background: rgba(255, 255, 255, .6); }

/* Candy pieces */
.panel { background: var(--paper); border: 3px solid var(--ink); border-radius: 26px; box-shadow: 0 6px 0 var(--ink); }
.btn {
  display: inline-flex; align-items: center; gap: 10px; padding: 14px 22px; border-radius: 20px; border: 3px solid var(--ink);
  background: linear-gradient(180deg, #6ee27f, var(--mint)); color: #fff; text-decoration: none;
  font: 400 22px/1 var(--title); letter-spacing: .3px; box-shadow: 0 5px 0 var(--mint-deep), 0 5px 0 3px var(--ink);
  -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; text-shadow: 0 2px 0 var(--ink);
}
.btn:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--mint-deep), 0 2px 0 3px var(--ink); }
.btn svg { width: 26px; height: 26px; -webkit-text-stroke: 0; }
.btn.soft { background: #fff; color: var(--ink); -webkit-text-stroke: 0; text-shadow: none; box-shadow: 0 5px 0 #c9d6f2, 0 5px 0 3px var(--ink); }
:focus-visible { outline: 4px solid var(--sun); outline-offset: 3px; }

/* Home: the hero */
.hero { display: grid; grid-template-columns: 1.05fr 1fr; gap: 32px; align-items: center; padding: 28px 0 40px; }
.hero h1 {
  margin: 0 0 14px; font: 400 clamp(40px, 6.4vw, 68px)/1.02 var(--title); color: #fff;
  -webkit-text-stroke: 7px var(--ink); paint-order: stroke fill; text-shadow: 0 6px 0 var(--ink);
}
.hero p.lede { margin: 0 0 22px; font-size: 21px; max-width: 34em; }
.hero .cta { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.hero .cta small { color: var(--ink-2); font-weight: 700; }
.phones { position: relative; display: flex; justify-content: center; gap: 14px; }
.phone { width: min(46%, 230px); border: 4px solid var(--ink); border-radius: 30px; overflow: hidden; box-shadow: 0 8px 0 var(--ink); background: #fff; }
.phone:nth-child(1) { transform: rotate(-4deg) translateY(10px); }
.phone:nth-child(2) { transform: rotate(3deg); }

/* Home: what's inside */
.section-title {
  margin: 8px 0 18px; font: 400 clamp(30px, 4.2vw, 40px)/1.1 var(--title); color: #fff; text-align: center;
  -webkit-text-stroke: 6px var(--ink); paint-order: stroke fill; text-shadow: 0 4px 0 var(--ink);
}
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 36px; }
.feature { padding: 18px 18px 20px; }
.feature .dot { width: 54px; height: 54px; border-radius: 18px; display: grid; place-items: center; font-size: 30px; border: 3px solid var(--ink); box-shadow: 0 3px 0 var(--ink); margin-bottom: 10px; }
.feature h3 { margin: 0 0 6px; font: 400 22px/1.15 var(--title); }
.feature p { margin: 0; font-size: 16.5px; line-height: 1.45; color: var(--ink-2); }
.shots { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-bottom: 36px; }
.shot { display: grid; grid-template-columns: 170px 1fr; gap: 18px; align-items: center; padding: 14px; }
.shot img { border-radius: 18px; border: 3px solid var(--ink); }
.shot h3 { margin: 0 0 6px; font: 400 23px/1.15 var(--title); }
.shot p { margin: 0; color: var(--ink-2); font-size: 16.5px; }
.honest { padding: 22px 24px; margin-bottom: 40px; display: grid; grid-template-columns: 1fr 1fr; gap: 18px 28px; }
.honest h3 { margin: 0 0 4px; font: 400 21px/1.2 var(--title); }
.honest p { margin: 0; font-size: 16.5px; color: var(--ink-2); }

/* Reading pages: privacy and help */
.doc { padding: clamp(20px, 4vw, 40px); margin: 12px 0 40px; }
.doc h1 { margin: 0 0 6px; font: 400 clamp(32px, 5vw, 44px)/1.1 var(--title); }
.doc h2 { margin: 28px 0 6px; font: 400 24px/1.2 var(--title); }
.doc p, .doc li { max-width: 46em; }
.doc .muted { color: var(--ink-2); margin-top: 0; }
.faq details { border-top: 2px dashed #c9d6f2; padding: 12px 0; }
.faq details:last-of-type { border-bottom: 2px dashed #c9d6f2; }
.faq summary { cursor: pointer; font: 400 21px/1.25 var(--title); list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: '+'; display: inline-block; width: 1.2em; color: var(--sky-deep); }
.faq details[open] summary::before { content: '−'; }
.faq details p, .faq details ol { margin: 8px 0 4px 1.2em; }
.contact { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 10px; }

/* Footer */
footer { padding: 24px 0 40px; text-align: center; color: var(--ink-2); font-size: 15.5px; }
footer nav { display: flex; justify-content: center; gap: 18px; margin-bottom: 6px; flex-wrap: wrap; }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; text-align: center; }
  .hero p.lede { margin-left: auto; margin-right: auto; }
  .hero .cta { justify-content: center; }
  .features { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
  body { font-size: 17px; }
  .top nav a { padding: 8px; }
  .features, .shots, .honest { grid-template-columns: 1fr; }
  .shot { grid-template-columns: 110px 1fr; }
  .brand b { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) { .phone { transform: none !important; } }
