:root {
  --brand-bg: #faf8f2;
  --brand-surface: #ffffff;
  --brand-ink: #101828;
  --brand-muted: #667085;
  --brand-navy: #0b2343;
  --brand-border: #e7e2d8;
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --container: 1200px;
  --section-space: clamp(2.75rem, 4.5vw, 4.25rem);
  --shadow-sm: 0 10px 30px rgba(11, 35, 67, 0.08);
  --shadow-lg: 0 26px 70px rgba(11, 35, 67, 0.14);
  --theme-primary: #ffb800;
  --theme-secondary: #ef5b36;
  --theme-soft: #fff4d2;
  --theme-dark: #8f3a23;
  --theme-contrast: #101828;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

[data-theme="shoplist"] {
  --theme-primary: #2f7d32;
  --theme-secondary: #8bc34a;
  --theme-soft: #eef8e8;
  --theme-dark: #17451f;
  --theme-contrast: #ffffff;
}

[data-theme="math"] {
  --theme-primary: #3157d5;
  --theme-secondary: #6c4ce4;
  --theme-soft: #eef1ff;
  --theme-dark: #24388f;
  --theme-warm: #ff7a66;
  --theme-contrast: #ffffff;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  color-scheme: light;
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  color: var(--brand-ink);
  background: var(--brand-bg);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

body::before {
  position: fixed;
  z-index: -2;
  inset: 0;
  background:
    radial-gradient(circle at 12% 8%, rgba(255, 184, 0, 0.05), transparent 28rem),
    radial-gradient(circle at 92% 22%, rgba(49, 87, 213, 0.04), transparent 30rem);
  content: "";
  pointer-events: none;
}

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

a {
  color: inherit;
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid #3478f6;
  outline-offset: 4px;
}

::selection {
  color: #fff;
  background: var(--brand-navy);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.container {
  width: min(calc(100% - 48px), var(--container));
  margin-inline: auto;
}

.narrow-container {
  width: min(calc(100% - 48px), 920px);
  margin-inline: auto;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  letter-spacing: -0.035em;
  line-height: 1.08;
}

h1 {
  margin-bottom: 1.35rem;
  font-size: clamp(2.5rem, 5vw, 4.5rem);
}

h2 {
  margin-bottom: 1rem;
  font-size: clamp(1.75rem, 3vw, 2.75rem);
}

h3 {
  margin-bottom: 0.7rem;
  font-size: clamp(1.15rem, 2vw, 1.45rem);
}

.lead {
  max-width: 660px;
  margin-bottom: 1.8rem;
  color: #475467;
  font-size: clamp(1.08rem, 1.5vw, 1.25rem);
  line-height: 1.65;
}

.muted {
  color: var(--brand-muted);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  color: var(--theme-dark);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.eyebrow::before {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--theme-primary);
  content: "";
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--theme-primary) 17%, transparent);
}

.section {
  position: relative;
  padding-block: var(--section-space);
}

.section--tight {
  padding-block: clamp(2.25rem, 3.5vw, 3.5rem);
}

body[data-page="home"] .section {
  padding-block: clamp(2.75rem, 4.5vw, 4.25rem);
}

.section--surface {
  background: var(--brand-surface);
}

.section--soft {
  background: color-mix(in srgb, var(--theme-soft) 72%, var(--brand-bg));
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 2.25rem;
}

.section-heading > div {
  max-width: 720px;
}

.section-heading p {
  margin-bottom: 0;
  color: var(--brand-muted);
}

.section-heading--center {
  display: block;
  max-width: 780px;
  margin-inline: auto;
  text-align: center;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--brand-navy);
  font-weight: 750;
  text-decoration: none;
}

.text-link:hover {
  color: var(--theme-dark);
}

site-header,
site-footer,
app-icon,
store-button,
phone-mockup,
video-slot {
  display: block;
}

site-header {
  min-height: 72px;
}

.site-header {
  position: relative;
  z-index: 100;
  min-height: 72px;
  border-bottom: 1px solid color-mix(in srgb, var(--brand-border) 78%, transparent);
  background: rgba(250, 248, 242, 0.9);
  backdrop-filter: blur(18px);
}

.site-header__inner {
  display: flex;
  min-height: 72px;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.brand {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 0.65rem;
  color: var(--brand-navy);
  font-size: 1.25rem;
  font-weight: 850;
  letter-spacing: -0.035em;
  text-decoration: none;
}

.brand-logo {
  display: block;
  width: 32px;
  height: 32px;
  overflow: hidden;
  border-radius: 9px;
}

.brand-logo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(1.3rem, 3vw, 2.6rem);
}

.site-nav a {
  position: relative;
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  color: #344054;
  font-size: 0.95rem;
  font-weight: 650;
  text-decoration: none;
}

.site-nav a::after {
  position: absolute;
  right: 0;
  bottom: 2px;
  left: 0;
  height: 2px;
  border-radius: 2px;
  background: var(--theme-primary);
  content: "";
  opacity: 0;
  transform: scaleX(0.45);
  transition: 160ms ease;
}

.site-nav a:hover::after,
.site-nav a[aria-current="page"]::after {
  opacity: 1;
  transform: scaleX(1);
}

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-sm);
  background: var(--brand-surface);
}

.menu-button > span:not(.sr-only) {
  display: block;
  width: 100%;
  height: 2px;
  margin-block: 4px;
  border-radius: 2px;
  background: var(--brand-navy);
}

.site-footer {
  padding: 4rem 0 1.5rem;
  color: #dbe6f3;
  background:
    radial-gradient(circle at 90% -10%, rgba(68, 112, 166, 0.26), transparent 28rem),
    var(--brand-navy);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr repeat(3, 1fr);
  gap: clamp(2rem, 5vw, 5rem);
}

.brand--footer {
  color: #fff;
}

.brand--footer .brand-logo {
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.footer-grid h2 {
  margin-bottom: 1.2rem;
  color: #fff;
  font-size: 0.92rem;
  letter-spacing: 0.02em;
}

.footer-grid p {
  max-width: 280px;
  margin: 1rem 0;
  color: #b8c8db;
  font-size: 0.92rem;
}

.footer-grid > div > a:not(.brand) {
  display: block;
  width: fit-content;
  margin-bottom: 0.65rem;
  color: #c7d4e4;
  font-size: 0.9rem;
  text-decoration: none;
}

.footer-grid > div > a:hover {
  color: #fff;
}

.footer-email {
  overflow-wrap: anywhere;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 3.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.13);
  color: #91a7c0;
  font-size: 0.82rem;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.8rem;
}

.button,
.store-button {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.75rem 1.25rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 750;
  line-height: 1.2;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover,
.store-button:hover {
  transform: translateY(-2px);
}

.button--primary {
  color: #fff;
  background: var(--brand-navy);
  box-shadow: 0 8px 20px rgba(11, 35, 67, 0.18);
}

.button--secondary {
  border-color: #c8cdd4;
  color: var(--brand-navy);
  background: rgba(255, 255, 255, 0.72);
}

.button--theme {
  color: var(--theme-contrast);
  background: var(--theme-primary);
  box-shadow: 0 10px 26px color-mix(in srgb, var(--theme-primary) 26%, transparent);
}

store-button {
  display: inline-block;
}

.store-button {
  color: #fff;
  background: var(--brand-navy);
  box-shadow: 0 8px 20px rgba(11, 35, 67, 0.18);
}

.store-button--googleplay {
  border-color: #c8cdd4;
  color: var(--brand-ink);
  background: #fff;
  box-shadow: none;
}

.store-button svg {
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.chip {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.8rem;
  border: 1px solid color-mix(in srgb, var(--theme-primary) 25%, var(--brand-border));
  border-radius: 999px;
  color: var(--theme-dark);
  background: color-mix(in srgb, var(--theme-soft) 78%, #fff);
  font-size: 0.84rem;
  font-weight: 700;
}

.chip svg {
  width: 17px;
  height: 17px;
}

.app-icon {
  display: grid;
  width: var(--icon-size, 76px);
  height: var(--icon-size, 76px);
  flex: 0 0 auto;
  place-items: center;
  border-radius: calc(var(--icon-size) * 0.24);
  color: var(--theme-dark);
  background: linear-gradient(145deg, #fff, var(--theme-soft));
  box-shadow: 0 12px 30px color-mix(in srgb, var(--theme-primary) 15%, rgba(11, 35, 67, 0.08));
}

.app-icon svg {
  width: 68%;
  height: 68%;
}

.app-icon--calendar {
  color: #b84a2b;
  background: linear-gradient(145deg, #fff9e8, #ffd96b);
}

.app-icon--shoplist {
  color: #276b2b;
  background: linear-gradient(145deg, #f7fff2, #b8dd8a);
}

.app-icon--math {
  color: #fff;
  background: linear-gradient(145deg, #3157d5, #6c4ce4);
}

phone-mockup {
  width: var(--phone-width, 250px);
  max-width: 100%;
}

.phone-frame {
  position: relative;
  display: block;
  width: 100%;
  padding: 7px;
  border: 2px solid #060b11;
  border-radius: clamp(26px, calc(var(--phone-width, 250px) * 0.12), 38px);
  background: linear-gradient(145deg, #3b4148 0%, #090d12 30%, #2d333a 78%, #080b0f 100%);
  box-shadow: 0 25px 50px rgba(8, 15, 24, 0.22), inset 0 0 0 1px rgba(255, 255, 255, 0.15);
}

.phone-camera {
  position: absolute;
  z-index: 3;
  top: 15px;
  left: 50%;
  width: clamp(8px, calc(var(--phone-width, 250px) * 0.045), 12px);
  aspect-ratio: 1;
  border: 2px solid #242d37;
  border-radius: 50%;
  background: #020408;
  transform: translateX(-50%);
  box-shadow: inset 0 0 0 2px #07111e;
}

.phone-screen {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1220 / 2712;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: clamp(20px, calc(var(--phone-width, 250px) * 0.092), 31px);
  background: #dfe2e6;
}

.phone-screen img {
  position: absolute;
  z-index: 2;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  filter: grayscale(0.35) contrast(0.96);
  object-fit: contain;
  object-position: center top;
  transform: scale(1.012);
  transition: opacity 520ms ease, filter 520ms ease, transform 680ms ease;
}

phone-mockup.has-image .phone-screen img {
  opacity: 1;
  filter: none;
  transform: scale(1);
}

.screenshot-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 0.6rem;
  padding: 1rem;
  color: #727881;
  background: linear-gradient(145deg, #eceef0, #d7dade);
  text-align: center;
  transition: opacity 420ms ease, visibility 0s linear 420ms;
}

.screenshot-fallback::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, 0.58) 50%, transparent 65%);
  content: "";
  transform: translateX(-100%);
  animation: screenshot-loading 1.35s ease-in-out infinite;
}

phone-mockup.has-image .screenshot-fallback {
  visibility: hidden;
  opacity: 0;
}

@keyframes screenshot-loading {
  to { transform: translateX(100%); }
}

.screenshot-fallback svg {
  width: 48px;
  opacity: 0.72;
}

.screenshot-fallback strong {
  font-size: clamp(0.72rem, calc(var(--phone-width, 250px) * 0.052), 0.95rem);
  line-height: 1.25;
}

.screenshot-fallback span {
  max-width: 100%;
  color: var(--brand-muted);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: clamp(0.5rem, calc(var(--phone-width, 250px) * 0.032), 0.68rem);
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.home-hero,
.app-hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--brand-border);
}

.home-hero::before,
.app-hero::before {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(color-mix(in srgb, var(--theme-primary) 26%, transparent) 1.5px, transparent 1.5px);
  background-size: 24px 24px;
  content: "";
  opacity: 0.45;
  mask-image: linear-gradient(90deg, transparent 30%, #000 100%);
}

.home-hero__inner,
.app-hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  min-height: min(720px, calc(100vh - 72px));
  align-items: center;
  gap: clamp(2.5rem, 7vw, 7rem);
}

.home-hero__inner {
  grid-template-columns: minmax(0, 0.95fr) minmax(460px, 1.05fr);
  min-height: min(620px, calc(100vh - 72px));
}

.home-hero__copy {
  padding-block: 3rem;
}

.hero-actions {
  margin-bottom: 1.5rem;
}

.hero-phone-stage {
  position: relative;
  min-height: 580px;
}

.hero-phone-stage::before,
.app-hero__phones::before {
  position: absolute;
  width: 82%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 184, 0, 0.23), rgba(139, 195, 74, 0.12) 38%, rgba(49, 87, 213, 0.08) 58%, transparent 72%);
  content: "";
  filter: blur(8px);
}

.hero-phone-stage phone-mockup {
  position: absolute;
  bottom: 42px;
  --phone-width: 235px;
}

.hero-phone-stage phone-mockup:nth-child(1) {
  z-index: 1;
  left: 0;
  bottom: 48px;
  --phone-width: 225px;
  --theme-primary: #2f7d32;
  --theme-soft: #eef8e8;
  --theme-dark: #17451f;
}

.hero-phone-stage phone-mockup:nth-child(2) {
  z-index: 3;
  left: 50%;
  bottom: 62px;
  --phone-width: 255px;
  --theme-primary: #ffb800;
  --theme-soft: #fff4d2;
  --theme-dark: #8f3a23;
  transform: translateX(-50%);
}

.hero-phone-stage phone-mockup:nth-child(3) {
  z-index: 2;
  right: 0;
  bottom: 48px;
  --phone-width: 225px;
  --theme-primary: #3157d5;
  --theme-soft: #eef1ff;
  --theme-dark: #24388f;
}

.featured-app {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.72fr);
  align-items: center;
  gap: clamp(3rem, 8vw, 7rem);
}

.featured-app__content-link,
.app-card__copy-link,
.app-card__icon-link,
.app-card__media {
  color: inherit;
  text-decoration: none;
}

.featured-app__content-link {
  display: block;
  border-radius: var(--radius-sm);
}

.featured-app__content-link h2,
.app-card__copy-link h3 {
  transition: color 180ms ease;
}

.featured-app__content-link:hover h2,
.app-card__copy-link:hover h3 {
  color: var(--theme-dark);
}

.featured-app__content-link:focus-visible,
.featured-app__visual:focus-visible,
.app-card__copy-link:focus-visible,
.app-card__icon-link:focus-visible,
.app-card__media:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--theme-primary) 72%, #fff);
  outline-offset: 5px;
}

.featured-app__visual {
  position: relative;
  display: grid;
  min-height: 610px;
  place-items: center;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.62), transparent),
    var(--theme-soft);
}

.featured-app__visual::before {
  position: absolute;
  inset: 8% 7%;
  border: 1px dashed color-mix(in srgb, var(--theme-primary) 38%, transparent);
  border-radius: 50%;
  content: "";
}

.featured-app__visual phone-mockup {
  position: relative;
  z-index: 1;
  --phone-width: 275px;
}

.benefit-list {
  display: grid;
  gap: 0.8rem;
  margin: 2rem 0;
  padding: 0;
  list-style: none;
}

.benefit-list li {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  color: #344054;
  font-weight: 650;
}

.benefit-list li::before {
  display: grid;
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  place-items: center;
  border-radius: 50%;
  color: var(--theme-dark);
  background: var(--theme-soft);
  content: "✓";
  font-size: 0.82rem;
  font-weight: 900;
}

.app-grid,
[data-app-list] {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
}

.app-grid--three,
[data-app-list].app-grid--three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.app-card {
  position: relative;
  display: grid;
  min-height: 260px;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 1.4rem;
  padding: clamp(1.5rem, 3vw, 2.25rem);
  overflow: hidden;
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  background: var(--brand-surface);
  box-shadow: var(--shadow-sm);
}

.app-card::after {
  position: absolute;
  right: -80px;
  bottom: -110px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: var(--app-soft, #f4f5f7);
  content: "";
  opacity: 0.75;
}

.app-card > * {
  position: relative;
  z-index: 1;
}

.app-card p {
  color: var(--brand-muted);
}

.app-card--calendar {
  --app-soft: #fff4d2;
}

.app-card--shoplist {
  --app-soft: #eef8e8;
}

.app-card--math {
  --app-soft: #eef1ff;
}

.app-card--with-phone {
  min-height: 360px;
  grid-template-columns: auto minmax(0, 1fr) 145px;
  align-items: center;
}

.app-card__media {
  position: relative;
  z-index: 2;
  display: block;
  align-self: end;
  max-height: 340px;
  overflow: hidden;
}

.app-card__media phone-mockup {
  --phone-width: 132px;
}

.app-card__media .phone-frame {
  padding: 4px;
  border-width: 1px;
}

.principles-grid,
.feature-grid,
.scenario-grid,
.topic-grid,
.practice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
}

.principle-card,
.feature-card,
.scenario-card,
.topic-card,
.practice-card {
  padding: clamp(1.35rem, 3vw, 2rem);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.72);
}

.principle-card,
.feature-card,
.scenario-card {
  text-align: center;
}

.principle-icon,
.feature-icon,
.scenario-icon {
  display: grid;
  width: 48px;
  height: 48px;
  margin: 0 auto 1.25rem;
  place-items: center;
  border-radius: 50%;
  color: var(--theme-dark);
  background: var(--theme-soft);
}

.principle-icon svg,
.feature-icon svg,
.scenario-icon svg {
  width: 25px;
  height: 25px;
}

.principle-card p,
.feature-card p,
.scenario-card p,
.practice-card p {
  margin-bottom: 0;
  color: var(--brand-muted);
  font-size: 0.94rem;
}

.about-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.65fr);
  align-items: center;
  gap: 3rem;
  padding: clamp(2rem, 5vw, 4rem);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  color: #fff;
  background:
    radial-gradient(circle at 85% 20%, rgba(255, 255, 255, 0.13), transparent 18rem),
    var(--brand-navy);
}

.about-panel p {
  margin-bottom: 0;
  color: #c7d4e4;
}

.about-mark {
  display: grid;
  min-height: 220px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-lg);
  background-image: radial-gradient(rgba(255, 255, 255, 0.22) 1.5px, transparent 1.5px);
  background-size: 22px 22px;
}

.about-mark .brand-logo {
  width: 96px;
  height: 96px;
  color: #fff;
  filter: drop-shadow(0 15px 25px rgba(0, 0, 0, 0.2));
}

.app-hero {
  background:
    radial-gradient(circle at 82% 22%, color-mix(in srgb, var(--theme-primary) 17%, transparent), transparent 25rem),
    linear-gradient(140deg, #fff 0%, var(--brand-bg) 55%, var(--theme-soft) 130%);
}

.app-hero__inner {
  grid-template-columns: minmax(0, 0.82fr) minmax(470px, 1.18fr);
  padding-block: clamp(2.75rem, 4.5vw, 4.25rem);
}

.app-hero__copy .app-icon {
  margin-bottom: 1.5rem;
  --icon-size: 88px;
}

.app-hero__copy .chip-row {
  margin-top: 1.5rem;
}

.app-hero__phones {
  position: relative;
  display: flex;
  min-height: 590px;
  align-items: end;
  justify-content: center;
}

.app-hero__phones::before {
  top: 3%;
  left: 9%;
  background: radial-gradient(circle, color-mix(in srgb, var(--theme-primary) 25%, transparent), transparent 68%);
}

.app-hero__phones phone-mockup {
  position: relative;
  z-index: 2;
  margin-inline: -6px;
  --phone-width: 225px;
}

.app-hero__phones phone-mockup:nth-child(2) {
  z-index: 3;
  --phone-width: 255px;
  transform: translateY(-26px);
}

.app-hero__phones phone-mockup:nth-child(3) {
  z-index: 1;
  transform: translateY(14px);
}

.app-hero__phones--two phone-mockup:first-child {
  --phone-width: 280px;
}

.app-hero__phones--two phone-mockup:nth-child(2) {
  --phone-width: 235px;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.2rem;
  counter-reset: steps;
}

.step-arrow {
  position: absolute;
  z-index: 5;
  top: 50%;
  right: -1.65rem;
  display: grid;
  width: 2.1rem;
  height: 2.1rem;
  place-items: center;
  border: 1px solid var(--brand-border);
  border-radius: 50%;
  color: var(--theme-dark);
  background: var(--brand-surface);
  box-shadow: var(--shadow-sm);
  transform: translateY(-50%);
}

.step-card {
  position: relative;
  display: grid;
  min-width: 0;
  grid-template-rows: auto 1fr;
  justify-items: center;
  padding: 1.5rem;
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-md);
  background: var(--brand-surface);
  counter-increment: steps;
}

.step-card::before {
  position: absolute;
  z-index: 4;
  top: 1rem;
  left: 1rem;
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 50%;
  color: var(--theme-contrast);
  background: var(--theme-primary);
  content: counter(steps);
  font-weight: 850;
}

.step-card phone-mockup {
  margin-bottom: 1.4rem;
  --phone-width: 155px;
}

.step-card h3 {
  text-align: center;
}

.step-card p {
  margin-bottom: 0;
  color: var(--brand-muted);
  font-size: 0.9rem;
  text-align: center;
}

.carousel-shell {
  position: relative;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
}

.carousel-viewport {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
  padding: 4px;
  touch-action: pan-y;
}

.carousel-track {
  display: grid;
  width: max-content;
  grid-auto-flow: column;
  gap: 1rem;
  align-items: stretch;
  will-change: transform;
}

.carousel-track.is-animating {
  transition: transform 460ms cubic-bezier(0.22, 0.7, 0.2, 1);
}

.carousel-card {
  display: grid;
  height: 100%;
  min-width: 0;
  justify-items: center;
  padding: 1.5rem 1.25rem;
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  background: var(--brand-surface);
  scroll-snap-align: center;
}

.carousel-card phone-mockup {
  margin-bottom: 1.5rem;
  --phone-width: 180px;
}

.carousel-card p {
  margin-bottom: 0;
  color: var(--brand-muted);
  font-size: 0.9rem;
  text-align: center;
}

.carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.carousel-arrow,
.carousel-dots button {
  display: grid;
  place-items: center;
  border: 1px solid var(--brand-border);
  color: var(--brand-navy);
  background: var(--brand-surface);
  cursor: pointer;
}

.carousel-arrow {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 1.2rem;
}

.carousel-dots {
  display: flex;
  gap: 0.45rem;
}

.carousel-dots button {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #c7ccd3;
}

.carousel-dots button[aria-current="true"] {
  width: 24px;
  border-radius: 999px;
  background: var(--theme-primary);
}

.feature-grid--five {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.feature-grid--five .feature-card {
  padding: 1.35rem;
}

.feature-grid--five h3 {
  font-size: 1.08rem;
}

.story-stack {
  display: grid;
  gap: 1.25rem;
  margin-top: 3rem;
}

.subsection-heading {
  margin-top: 4rem;
}

.math-practice-card {
  position: relative;
  min-height: 250px;
  padding: 2rem;
  overflow: hidden;
  border: 0;
}

.math-practice-card > * {
  position: relative;
  z-index: 1;
}

.math-practice-card--blue {
  color: #173e9f;
  background: linear-gradient(145deg, #eaf2ff, #f7faff);
}

.math-practice-card--purple {
  color: #5138b5;
  background: linear-gradient(145deg, #f0ecff, #faf9ff);
}

.math-practice-card--warm {
  color: #873e33;
  background: linear-gradient(145deg, #fff0ec, #fff9f7);
}

.math-card-symbol {
  display: block;
  margin-bottom: 2.5rem;
  font-size: clamp(2.5rem, 6vw, 4.8rem);
  font-weight: 850;
  letter-spacing: -0.08em;
  line-height: 0.9;
  opacity: 0.85;
}

.math-story-visual .number-cloud {
  position: absolute;
  z-index: 2;
  color: var(--theme-primary);
  font-size: 2rem;
  font-weight: 850;
  opacity: 0.28;
}

.number-cloud--one { top: 10%; left: 13%; }
.number-cloud--two { top: 22%; right: 12%; color: var(--theme-secondary) !important; }
.number-cloud--three { right: 16%; bottom: 10%; color: var(--theme-warm) !important; }

.adults-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(420px, 1.22fr);
  align-items: start;
  gap: clamp(2.5rem, 7vw, 6rem);
  padding: clamp(2rem, 5vw, 4rem);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, #fff, #f6f8ff);
}

.adult-checklist {
  display: grid;
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: none;
}

.adult-checklist li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1rem;
  padding: 1.15rem;
  border: 1px solid #e3e7f4;
  border-radius: var(--radius-sm);
  background: #fff;
}

.adult-checklist li > span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--theme-primary);
  font-weight: 800;
}

.adult-checklist strong {
  display: block;
  margin-bottom: 0.25rem;
}

.adult-checklist p {
  margin: 0;
  color: var(--brand-muted);
  font-size: 0.88rem;
}

.story-panel {
  position: relative;
  display: grid;
  min-height: 440px;
  grid-template-columns: minmax(0, 0.9fr) minmax(300px, 1.1fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
  padding: clamp(2rem, 5vw, 4rem);
  overflow: hidden;
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  background: var(--brand-surface);
}

.story-panel:nth-child(even) .story-panel__visual {
  order: 2;
}

.story-panel__visual {
  position: relative;
  display: grid;
  height: 350px;
  place-items: center;
  overflow: hidden;
  border-radius: var(--radius-md);
  background:
    radial-gradient(circle at 50% 55%, color-mix(in srgb, var(--theme-primary) 25%, transparent), transparent 14rem),
    var(--theme-soft);
}

.story-panel__visual phone-mockup {
  position: absolute;
  top: 32px;
  --phone-width: 220px;
}

.story-panel--phone-bottom .story-panel__visual phone-mockup {
  top: auto;
  bottom: 16px;
  --phone-width: 290px;
}

@media (prefers-reduced-motion: reduce) {
  .phone-screen img,
  .screenshot-fallback {
    transition-duration: 0.01ms;
  }

  .screenshot-fallback::after {
    animation: none;
  }
}

.story-panel__copy p {
  margin-bottom: 0;
  color: var(--brand-muted);
}

.data-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.55fr);
  align-items: center;
  gap: 2.5rem;
  padding: clamp(2rem, 5vw, 4rem);
  border: 1px solid color-mix(in srgb, var(--theme-primary) 26%, var(--brand-border));
  border-radius: var(--radius-lg);
  background: linear-gradient(125deg, #fff, var(--theme-soft));
}

.data-panel p {
  margin-bottom: 0;
  color: #475467;
}

.lock-illustration {
  position: relative;
  display: grid;
  min-height: 230px;
  place-items: center;
}

.lock-device {
  width: 155px;
  height: 105px;
  border: 8px solid var(--brand-navy);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow-lg);
}

.lock-shape {
  position: absolute;
  display: grid;
  width: 95px;
  height: 88px;
  bottom: 28px;
  place-items: center;
  border-radius: 18px;
  color: var(--brand-navy);
  background: var(--theme-primary);
  box-shadow: 0 12px 30px color-mix(in srgb, var(--theme-primary) 28%, transparent);
}

.lock-shape::before {
  position: absolute;
  top: -52px;
  width: 58px;
  height: 63px;
  border: 10px solid var(--brand-navy);
  border-bottom: 0;
  border-radius: 30px 30px 0 0;
  content: "";
}

.lock-shape::after {
  width: 12px;
  height: 22px;
  border-radius: 8px;
  background: var(--brand-navy);
  content: "";
}

.subscription-panel {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 1.5rem;
  padding: clamp(1.5rem, 3vw, 2.25rem);
  border: 1px solid color-mix(in srgb, var(--theme-secondary) 50%, var(--brand-border));
  border-radius: var(--radius-md);
  background: #fff;
}

.subscription-mark {
  display: grid;
  width: 64px;
  height: 64px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--theme-secondary);
  font-size: 1.8rem;
}

.subscription-panel p {
  margin-bottom: 0;
  color: var(--brand-muted);
  font-size: 0.94rem;
}

.apk-meta {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.65rem;
}

.apk-meta strong {
  color: var(--brand-ink);
  font-variant-numeric: tabular-nums;
}

.apk-meta__separator {
  color: var(--brand-border-strong);
}

.warning-note {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
  padding: 1rem 1.2rem;
  border-radius: var(--radius-sm);
  color: #344054;
  background: #edf5ff;
  font-size: 0.9rem;
}

.warning-note strong {
  display: grid;
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: #3676cc;
}

.cta-band {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 2rem;
  padding: clamp(2rem, 5vw, 3.5rem);
  overflow: hidden;
  border-radius: var(--radius-lg);
  color: var(--theme-contrast);
  background: var(--theme-primary);
}

.cta-band::after {
  position: absolute;
  right: -80px;
  width: 290px;
  height: 290px;
  border: 1px solid color-mix(in srgb, var(--theme-contrast) 30%, transparent);
  border-radius: 50%;
  content: "";
}

.cta-band > * {
  position: relative;
  z-index: 1;
}

.cta-band h2,
.cta-band p {
  color: inherit;
}

.cta-band p {
  max-width: 600px;
  margin-bottom: 0;
  opacity: 0.82;
}

.cta-band .store-button {
  color: #fff;
  background: var(--brand-navy);
}

.cta-band .store-button--googleplay {
  color: var(--brand-ink);
  background: #fff;
}

.article-grid,
[data-article-list][data-variant="grid"],
[data-article-list][data-variant="compact"] {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
}

.article-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-md);
  background: var(--brand-surface);
  box-shadow: 0 8px 25px rgba(11, 35, 67, 0.05);
}

.article-card__body {
  padding: 1.4rem;
}

.article-card h3 {
  font-size: 1.16rem;
}

.article-card h3 a {
  text-decoration: none;
}

.article-card h3 a:hover {
  color: var(--brand-navy);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.article-card p {
  color: var(--brand-muted);
  font-size: 0.91rem;
}

.article-category {
  display: block;
  margin-bottom: 0.75rem;
  color: var(--article-color, #c64e2f);
  font-size: 0.79rem;
  font-weight: 800;
}

.article-card--calendar {
  --article-color: #c64e2f;
}

.article-card--shoplist {
  --article-color: #2f7d32;
}

.article-card--math {
  --article-color: #5540cf;
}

.article-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.25rem;
  color: var(--brand-muted);
  font-size: 0.8rem;
}

.round-link {
  display: grid;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  place-items: center;
  border-radius: 50%;
  color: var(--brand-navy);
  background: #f2f4f7;
  font-size: 1.15rem;
  font-weight: 800;
  text-decoration: none;
}

.article-preview {
  position: relative;
  height: 190px;
  overflow: hidden;
}

.article-preview--calendar {
  background:
    radial-gradient(circle at 80% 12%, rgba(239, 91, 54, 0.22), transparent 9rem),
    #fff4d2;
}

.preview-calendar {
  position: absolute;
  top: 30px;
  left: 50%;
  display: grid;
  width: 180px;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
  padding: 24px 18px 18px;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 18px 30px rgba(143, 58, 35, 0.15);
  transform: translateX(-50%);
}

.preview-calendar b {
  position: absolute;
  top: 4px;
  left: 17px;
  color: var(--brand-navy);
  font-size: 0.7rem;
}

.preview-calendar i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #d9dde3;
}

.preview-calendar i:nth-of-type(4n) {
  background: #ef5b36;
}

.preview-note {
  position: absolute;
  right: 10%;
  bottom: 13px;
  padding: 0.45rem 0.7rem;
  border-radius: 8px;
  color: #8f3a23;
  background: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  box-shadow: var(--shadow-sm);
}

.article-preview--shoplist {
  background: #eef8e8;
}

.preview-basket {
  position: absolute;
  top: 34px;
  left: 15%;
  display: block;
  width: 105px;
  color: #2f7d32;
}

.preview-line {
  position: absolute;
  right: 12%;
  width: 42%;
  height: 10px;
  border-radius: 8px;
  background: #b7d5a7;
}

.preview-line--one { top: 66px; }
.preview-line--two { top: 96px; width: 34%; }

.preview-check {
  position: absolute;
  right: 15%;
  bottom: 24px;
  display: grid;
  width: 43px;
  height: 43px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: #2f7d32;
  font-weight: 900;
}

.article-preview--math {
  background: #eef1ff;
}

.math-sheet {
  position: absolute;
  top: 30px;
  left: 12%;
  display: grid;
  width: 145px;
  gap: 14px;
  padding: 28px 18px;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 18px 30px rgba(49, 87, 213, 0.14);
}

.math-sheet b {
  color: #24388f;
  font-size: 1.25rem;
}

.math-sheet i {
  width: 100%;
  height: 7px;
  border-radius: 7px;
  background: #dce2f8;
}

.math-symbol {
  position: absolute;
  top: 35px;
  right: 13%;
  color: #6c4ce4;
  font-size: 3.5rem;
  font-weight: 800;
}

.math-bars {
  position: absolute;
  right: 13%;
  bottom: 28px;
  display: flex;
  height: 60px;
  align-items: end;
  gap: 7px;
}

.math-bars i {
  width: 12px;
  border-radius: 5px 5px 0 0;
  background: #3157d5;
}

.math-bars i:nth-child(1) { height: 28%; opacity: 0.4; }
.math-bars i:nth-child(2) { height: 58%; opacity: 0.65; }
.math-bars i:nth-child(3) { height: 100%; }

.editorial-hero {
  padding: clamp(4rem, 8vw, 7rem) 0 2.5rem;
}

.editorial-hero .lead {
  margin-bottom: 0;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 2rem;
}

.filter-chip {
  min-height: 42px;
  padding: 0.5rem 1rem;
  border: 1px solid var(--brand-border);
  border-radius: 999px;
  color: #344054;
  background: var(--brand-surface);
  cursor: pointer;
}

.filter-chip[aria-pressed="true"] {
  border-color: var(--brand-navy);
  color: #fff;
  background: var(--brand-navy);
}

[data-article-list][data-variant="featured"] {
  margin-bottom: 1.25rem;
}

.article-card--featured {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr);
  min-height: 390px;
}

.article-card--featured .article-preview {
  height: 100%;
  min-height: 390px;
}

.article-card--featured .article-card__body {
  display: flex;
  justify-content: center;
  flex-direction: column;
  padding: clamp(2rem, 5vw, 3.5rem);
}

.article-card--featured h3 {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
}

[data-article-list][data-variant="grid"] {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

[data-article-list][data-variant="grid"] .article-card {
  display: grid;
  grid-template-columns: minmax(160px, 0.65fr) minmax(0, 1.35fr);
}

[data-article-list][data-variant="grid"] .article-preview {
  height: 100%;
  min-height: 280px;
}

.topic-card h3 {
  color: var(--topic-color, var(--brand-navy));
}

.topic-card a {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.45rem 0;
  color: #344054;
  font-size: 0.9rem;
  text-decoration: none;
}

.topic-card a::after {
  content: "→";
}

.topic-card--calendar { --topic-color: #c64e2f; }
.topic-card--shoplist { --topic-color: #2f7d32; }
.topic-card--math { --topic-color: #5540cf; }

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 1.25rem;
  color: var(--brand-muted);
  font-size: 0.86rem;
}

.breadcrumbs a {
  text-decoration: none;
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 760px) 290px;
  align-items: start;
  justify-content: center;
  gap: clamp(2rem, 6vw, 5rem);
  padding-block: clamp(3rem, 7vw, 6rem);
}

.article-main h1 {
  font-size: clamp(2.35rem, 4.5vw, 4rem);
}

.article-standfirst {
  color: #475467;
  font-size: 1.12rem;
}

.article-meta-row {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  color: var(--brand-muted);
  font-size: 0.82rem;
}

.article-hero-visual {
  position: relative;
  display: grid;
  min-height: 570px;
  margin: 2rem 0 3rem;
  place-items: center;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.4), transparent),
    var(--theme-soft);
}

.article-topic-hero {
  position: relative;
  display: flex;
  min-height: 330px;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  margin: 2rem 0 3rem;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.article-topic-hero::before {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(currentColor 1px, transparent 1px);
  background-size: 24px 24px;
  content: "";
  opacity: 0.07;
}

.article-topic-hero > * {
  position: relative;
  z-index: 1;
}

.article-topic-hero .app-icon {
  --icon-size: 120px;
}

.article-topic-hero--shoplist {
  color: #17451f;
  background: linear-gradient(135deg, #f8fff3, #dff1d3);
}

.article-topic-hero--math {
  color: #24388f;
  background: linear-gradient(135deg, #f9faff, #dfe5ff);
}

.article-topic-hero--math strong {
  font-size: clamp(1.7rem, 5vw, 3.2rem);
}

.topic-list-line {
  width: 100px;
  height: 11px;
  border-radius: 8px;
  background: #8fbd76;
}

.topic-list-check {
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: #2f7d32;
  font-size: 1.5rem;
  font-weight: 900;
}

.topic-level {
  position: absolute;
  right: 1.5rem;
  bottom: 1.5rem;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  color: #24388f;
  background: #fff;
  font-size: 0.78rem;
  font-weight: 750;
}

.article-hero-visual::before {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(color-mix(in srgb, var(--theme-primary) 28%, transparent) 1.5px, transparent 1.5px);
  background-size: 25px 25px;
  content: "";
  opacity: 0.48;
}

.article-hero-visual phone-mockup {
  position: relative;
  z-index: 2;
  --phone-width: 270px;
}

.context-note {
  position: absolute;
  z-index: 3;
  display: flex;
  width: 150px;
  align-items: center;
  gap: 0.55rem;
  padding: 0.8rem;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-sm);
  font-size: 0.82rem;
  font-weight: 800;
  backdrop-filter: blur(10px);
}

.context-note::before {
  width: 12px;
  height: 12px;
  flex: 0 0 12px;
  border-radius: 50%;
  background: var(--note-color);
  content: "";
}

.context-note--work { top: 15%; right: 8%; --note-color: #3157d5; }
.context-note--home { top: 47%; left: 6%; --note-color: #2f7d32; }
.context-note--personal { right: 7%; bottom: 13%; --note-color: #ef5b36; }

.prose {
  color: #344054;
}

.prose h2 {
  margin-top: 3.2rem;
  font-size: clamp(1.6rem, 3vw, 2.15rem);
}

.prose h3 {
  margin-top: 2rem;
}

.prose p,
.prose li {
  line-height: 1.78;
}

.prose p {
  margin-bottom: 1.3rem;
}

.prose ol,
.prose ul {
  margin: 1.25rem 0 1.7rem;
  padding-left: 1.4rem;
}

.prose li + li {
  margin-top: 0.55rem;
}

.prose a {
  color: #174ea6;
  text-underline-offset: 0.18em;
}

.prose blockquote {
  margin: 2rem 0;
  padding: 1.25rem 1.5rem;
  border-left: 4px solid var(--theme-primary);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--brand-navy);
  background: var(--theme-soft);
}

.prose blockquote p:last-child {
  margin-bottom: 0;
}

.prose figure {
  margin: 2.5rem 0;
}

.prose figcaption {
  margin-top: 0.8rem;
  color: var(--brand-muted);
  font-size: 0.82rem;
  text-align: center;
}

.prose table {
  width: 100%;
  margin: 2rem 0;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.prose th,
.prose td {
  padding: 0.8rem;
  border: 1px solid var(--brand-border);
  text-align: left;
}

.inline-phones {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  margin-block: 3rem;
}

.inline-phones figure {
  display: grid;
  justify-items: center;
  margin: 0;
  padding: 1.5rem;
  border-radius: var(--radius-md);
  background: var(--theme-soft);
}

.inline-phones phone-mockup {
  --phone-width: 215px;
}

.year-grid-figure {
  position: relative;
  display: grid;
  min-height: 520px;
  place-items: center;
  border-radius: var(--radius-lg);
  background: var(--theme-soft);
}

.year-grid-figure phone-mockup {
  --phone-width: 240px;
}

.year-callout {
  position: absolute;
  max-width: 155px;
  padding: 0.8rem;
  border-radius: var(--radius-sm);
  color: var(--theme-dark);
  background: #fff;
  box-shadow: var(--shadow-sm);
  font-size: 0.8rem;
  font-weight: 750;
}

.year-callout--left { left: 5%; top: 28%; }
.year-callout--right { right: 5%; bottom: 24%; }

.practice-box {
  margin: 3rem 0;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border-radius: var(--radius-md);
  background: linear-gradient(120deg, var(--theme-soft), #fff);
}

.practice-grid {
  margin-top: 1.5rem;
}

.practice-card {
  padding: 0;
  border: 0;
  background: transparent;
}

.app-sidebar {
  position: sticky;
  top: 92px;
  padding: 1.5rem;
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-md);
  background: var(--brand-surface);
  box-shadow: var(--shadow-sm);
}

.app-sidebar .app-icon {
  margin-bottom: 1.25rem;
  --icon-size: 78px;
}

.app-sidebar p {
  color: var(--brand-muted);
  font-size: 0.9rem;
}

.app-sidebar store-button,
.app-sidebar .store-button,
.app-sidebar .button {
  width: 100%;
}

.app-sidebar .text-link {
  margin-top: 1rem;
  font-size: 0.88rem;
}

video-slot {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius-md);
  color: #fff;
  background: var(--brand-navy);
}

video-slot video {
  position: absolute;
  z-index: 3;
  inset: 0;
  width: 100%;
  height: 100%;
  background: #000;
}

.video-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at 82% 22%, rgba(255, 184, 0, 0.24), transparent 15rem),
    linear-gradient(145deg, #12335c, var(--brand-navy));
}

.video-brand {
  position: absolute;
  top: 1.2rem;
  left: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.video-brand .app-icon {
  --icon-size: 52px;
}

.video-brand strong,
.video-brand span {
  display: block;
}

.video-brand span,
.video-file,
.video-status {
  color: #b8c8db;
  font-size: 0.75rem;
}

.video-play {
  width: 84px;
  height: 84px;
  padding: 0;
  border: 0;
  color: #fff;
  background: transparent;
  cursor: pointer;
}

.video-play:disabled {
  opacity: 0.4;
}

.video-file {
  position: absolute;
  bottom: 1rem;
  left: 1.2rem;
}

.video-status {
  position: absolute;
  right: 1.2rem;
  bottom: 1rem;
  left: 1.2rem;
  text-align: right;
}

.article-cta {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 1.3rem;
  margin-top: 3rem;
  padding: 1.5rem;
  border: 1px solid color-mix(in srgb, var(--theme-primary) 35%, var(--brand-border));
  border-radius: var(--radius-md);
  background: linear-gradient(120deg, var(--theme-soft), #fff);
}

.article-cta .app-icon {
  --icon-size: 68px;
}

.article-cta h2 {
  margin-bottom: 0.3rem;
  font-size: 1.25rem;
}

.article-cta p {
  margin-bottom: 0;
  color: var(--brand-muted);
  font-size: 0.85rem;
}

.contact-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 2rem;
  padding: clamp(2rem, 6vw, 4rem);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  background: var(--brand-surface);
  box-shadow: var(--shadow-sm);
}

.contact-card .app-icon {
  --icon-size: 110px;
}

.contact-symbol {
  width: 170px;
  max-width: 32vw;
}

@media (min-width: 901px) {
  .carousel-viewport {
    overflow: hidden;
  }
}

@media (max-width: 1050px) {
  .home-hero__inner,
  .app-hero__inner {
    grid-template-columns: minmax(0, 0.9fr) minmax(400px, 1.1fr);
    gap: 2rem;
  }

  .hero-phone-stage phone-mockup {
    --phone-width: 190px;
  }

  .hero-phone-stage phone-mockup:nth-child(2) {
    --phone-width: 215px;
  }

  .app-hero__phones phone-mockup {
    --phone-width: 185px;
  }

  .app-hero__phones phone-mockup:nth-child(2) {
    --phone-width: 215px;
  }

  .app-hero__phones--two phone-mockup:first-child {
    --phone-width: 235px;
  }

  .feature-grid--five {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .footer-grid {
    grid-template-columns: 1.3fr repeat(3, 1fr);
    gap: 2rem;
  }
}

@media (max-width: 900px) {
  .container,
  .narrow-container {
    width: min(calc(100% - 40px), var(--container));
  }

  .menu-button {
    display: block;
  }

  .site-nav {
    position: absolute;
    z-index: 20;
    top: calc(100% + 1px);
    right: 20px;
    left: 20px;
    display: none;
    align-items: stretch;
    flex-direction: column;
    gap: 0;
    padding: 0.65rem;
    border: 1px solid var(--brand-border);
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    background: var(--brand-surface);
    box-shadow: var(--shadow-lg);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding-inline: 0.8rem;
  }

  .site-nav a::after {
    right: auto;
    bottom: 7px;
    left: 0.8rem;
    width: 34px;
  }

  .home-hero__inner,
  .app-hero__inner,
  .featured-app,
  .about-panel,
  .data-panel,
  .article-layout {
    grid-template-columns: 1fr;
  }

  .home-hero__inner,
  .app-hero__inner {
    min-height: auto;
  }

  .home-hero__copy,
  .app-hero__copy {
    padding-top: 4.5rem;
    padding-bottom: 0;
  }

  .hero-phone-stage {
    width: min(100%, 600px);
    min-height: 540px;
    margin-inline: auto;
  }

  .hero-phone-stage phone-mockup {
    --phone-width: 205px;
  }

  .hero-phone-stage phone-mockup:nth-child(2) {
    --phone-width: 230px;
  }

  .featured-app__visual {
    min-height: 540px;
  }

  .app-hero__phones {
    min-height: 555px;
  }

  .app-hero__phones phone-mockup {
    --phone-width: 205px;
  }

  .app-hero__phones phone-mockup:nth-child(2) {
    --phone-width: 230px;
  }

  .app-hero__phones--two phone-mockup:first-child {
    --phone-width: 255px;
  }

  .principles-grid,
  .feature-grid,
  .scenario-grid,
  .topic-grid,
  .practice-grid,
  .steps-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .adults-panel {
    grid-template-columns: 1fr;
  }

  .feature-grid--five {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .story-panel {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }

  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr;
  }

  .footer-grid > div:last-child {
    grid-column: 2 / 4;
  }

  .article-layout {
    width: min(calc(100% - 40px), 760px);
  }

  .app-sidebar {
    position: static;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 1.25rem;
  }

  .app-sidebar .app-icon {
    grid-row: 1 / 4;
    margin-bottom: 0;
  }

  .app-sidebar store-button,
  .app-sidebar .store-button,
  .app-sidebar .button {
    width: fit-content;
  }

  [data-article-list][data-variant="compact"] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .article-card--featured {
    grid-template-columns: 1fr;
  }

  .article-card--featured .article-preview {
    min-height: 320px;
  }

  [data-article-list][data-variant="grid"] {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  body {
    font-size: 16px;
  }

  .container,
  .narrow-container,
  .article-layout {
    width: min(calc(100% - 32px), var(--container));
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .home-hero::before,
  .app-hero::before {
    mask-image: linear-gradient(180deg, transparent 15%, #000 100%);
  }

  .hero-phone-stage {
    min-height: 430px;
  }

  .hero-phone-stage phone-mockup {
    --phone-width: 155px;
  }

  .hero-phone-stage phone-mockup:nth-child(1) {
    left: 0;
  }

  .hero-phone-stage phone-mockup:nth-child(2) {
    left: 50%;
    --phone-width: 180px;
  }

  .hero-phone-stage phone-mockup:nth-child(3) {
    right: 0;
  }

  .app-hero__phones {
    min-height: 440px;
    justify-content: center;
  }

  .app-hero__phones phone-mockup {
    --phone-width: 145px;
  }

  .app-hero__phones phone-mockup:nth-child(2) {
    --phone-width: 170px;
  }

  .app-hero__phones--two phone-mockup:first-child {
    --phone-width: 190px;
  }

  .app-hero__phones--two phone-mockup:nth-child(2) {
    --phone-width: 165px;
  }

  .featured-app__visual {
    min-height: 480px;
  }

  .featured-app__visual phone-mockup {
    --phone-width: 225px;
  }

  .app-grid,
  [data-app-list],
  .app-grid--three,
  [data-app-list].app-grid--three,
  .principles-grid,
  .feature-grid,
  .scenario-grid,
  .topic-grid,
  .practice-grid,
  .steps-grid,
  .feature-grid--five,
  .inline-phones,
  [data-article-list][data-variant="compact"] {
    grid-template-columns: 1fr;
  }

  .app-card {
    min-height: auto;
  }

  .carousel-viewport {
    margin-inline: 0;
    padding-inline: 4px;
  }

  .story-panel,
  .story-panel:nth-child(even) {
    grid-template-columns: 1fr;
  }

  .story-panel:nth-child(even) .story-panel__visual {
    order: 0;
  }

  .story-panel__visual {
    height: 310px;
  }

  .story-panel__visual phone-mockup {
    --phone-width: 185px;
  }

  .story-panel--phone-bottom .story-panel__visual phone-mockup {
    bottom: 12px;
    --phone-width: 235px;
  }

  .phone-frame {
    padding: 3px;
    border-width: 1px;
    border-radius: clamp(20px, calc(var(--phone-width, 250px) * 0.1), 30px);
    box-shadow: 0 16px 34px rgba(8, 15, 24, 0.2), inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  }

  .phone-screen {
    border-radius: clamp(17px, calc(var(--phone-width, 250px) * 0.08), 26px);
  }

  .phone-camera {
    top: 9px;
    border-width: 1px;
  }

  .data-panel,
  .subscription-panel,
  .cta-band,
  .article-cta,
  .contact-card {
    grid-template-columns: 1fr;
  }

  .step-arrow {
    display: none;
  }

  .article-topic-hero {
    align-items: center;
    flex-direction: column;
    gap: 1rem;
  }

  .article-topic-hero--shoplist .topic-list-line {
    display: none;
  }

  .contact-symbol {
    max-width: 150px;
  }

  .subscription-panel {
    align-items: start;
  }

  .cta-band .button-row {
    align-items: stretch;
    flex-direction: column;
  }

  .cta-band store-button,
  .cta-band .store-button {
    width: 100%;
  }

  .article-card--featured .article-preview {
    min-height: 250px;
  }

  [data-article-list][data-variant="grid"] .article-card {
    grid-template-columns: 1fr;
  }

  [data-article-list][data-variant="grid"] .article-preview {
    min-height: 210px;
  }

  .article-hero-visual {
    min-height: 520px;
  }

  .article-hero-visual phone-mockup {
    --phone-width: 225px;
  }

  .context-note {
    width: auto;
    max-width: 130px;
    padding: 0.6rem;
    font-size: 0.72rem;
  }

  .inline-phones figure {
    padding: 1.25rem;
  }

  .year-callout {
    max-width: 120px;
    font-size: 0.7rem;
  }

  .app-sidebar {
    display: block;
  }

  .app-sidebar .app-icon {
    margin-bottom: 1rem;
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid > div:first-child,
  .footer-grid > div:last-child {
    grid-column: 1 / -1;
  }

  .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 430px) {
  .button-row {
    align-items: stretch;
    flex-direction: column;
  }

  .button-row .button,
  .button-row store-button,
  .button-row .store-button {
    width: 100%;
  }

  .hero-phone-stage {
    min-height: 390px;
  }

  .hero-phone-stage phone-mockup {
    --phone-width: 132px;
  }

  .hero-phone-stage phone-mockup:nth-child(2) {
    --phone-width: 153px;
  }

  .app-hero__phones {
    min-height: 395px;
  }

  .app-hero__phones phone-mockup {
    --phone-width: 124px;
  }

  .app-hero__phones phone-mockup:nth-child(2) {
    --phone-width: 145px;
  }

  .app-hero__phones--two phone-mockup:first-child {
    --phone-width: 165px;
  }

  .app-hero__phones--two phone-mockup:nth-child(2) {
    --phone-width: 140px;
  }

  .app-card {
    grid-template-columns: 1fr;
  }

  .app-card--with-phone {
    grid-template-columns: auto 1fr;
  }

  .app-card--with-phone .app-card__media {
    grid-column: 1 / -1;
    justify-self: center;
  }

  .app-card .app-icon {
    --icon-size: 64px;
  }

  .year-grid-figure {
    min-height: 480px;
  }

  .year-grid-figure phone-mockup {
    --phone-width: 205px;
  }

  .year-callout {
    max-width: 105px;
  }
}

/* The home phone trio stays in normal flow so its height can never overlap
   the copy above or be clipped by the hero container. */
body[data-page="home"] .hero-phone-stage {
  display: flex;
  width: 100%;
  min-height: 0;
  align-items: flex-end;
  justify-content: center;
  padding: 1.5rem 0 2.5rem;
}

body[data-page="home"] .hero-phone-stage phone-mockup {
  position: relative;
  right: auto;
  bottom: auto;
  left: auto;
  flex: 0 0 auto;
  margin: 0;
  --phone-width: 200px;
}

body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1) {
  z-index: 1;
  margin-right: -55px;
  --phone-width: 200px;
}

body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(2) {
  z-index: 3;
  margin: 0;
  --phone-width: 230px;
  transform: translateY(-12px);
}

body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
  z-index: 1;
  margin-left: -55px;
  --phone-width: 200px;
}

@media (max-width: 1050px) {
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1),
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    --phone-width: 180px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1) {
    margin-right: -48px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(2) {
    --phone-width: 205px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    margin-left: -48px;
  }
}

@media (max-width: 900px) {
  body[data-page="home"] .hero-phone-stage {
    max-width: 620px;
    margin-inline: auto;
    padding-top: 2rem;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1),
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    --phone-width: 200px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1) {
    margin-right: -60px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(2) {
    --phone-width: 220px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    margin-left: -60px;
  }
}

@media (max-width: 700px) {
  body[data-page="home"] .hero-phone-stage {
    padding: 2rem 0 2.25rem;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1),
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(2),
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    --phone-width: 160px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1) {
    margin-right: -42px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    margin-left: -42px;
  }
}

@media (max-width: 430px) {
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1),
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(2),
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    --phone-width: 140px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1) {
    margin-right: -32px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    margin-left: -32px;
  }
}

@media (max-width: 350px) {
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1),
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(2),
  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    --phone-width: 120px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(1) {
    margin-right: -36px;
  }

  body[data-page="home"] .hero-phone-stage phone-mockup:nth-child(3) {
    margin-left: -36px;
  }
}

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