:root {
  color-scheme: light;
  --ink: #18304a;
  --muted: #607186;
  --blue: #1565d8;
  --blue-dark: #0b4fab;
  --cream: #fff9ed;
  --pink: #ffedf1;
  --yellow: #fff2a8;
  --line: #dce6ef;
  --green: #138a62;
  --red: #d94a61;
  --shadow: 0 22px 70px rgba(32, 58, 90, 0.13);
  font-family: Inter, ui-rounded, "SF Pro Rounded", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: #fbfdff; line-height: 1.55; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
[hidden] { display: none !important; }
.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; }

.site-header { max-width: 1180px; margin: 0 auto; padding: 22px 24px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-mark { display: grid; place-items: center; width: 44px; height: 44px; color: white; background: var(--blue); border-radius: 14px; font-weight: 900; transform: rotate(-3deg); }
.brand strong, .brand small { display: block; }
.brand small { color: var(--muted); font-size: .78rem; }
.site-header nav, footer nav { display: flex; flex-wrap: wrap; gap: 20px; }
.site-header nav a, footer a { text-decoration: none; font-weight: 750; }
.site-header nav a:hover, footer a:hover { color: var(--blue); }

main { overflow: hidden; }
.hero { max-width: 1180px; margin: 36px auto 54px; padding: 0 24px; display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(300px, .75fr); gap: 64px; align-items: center; }
.hero::before { content: ""; position: absolute; left: -180px; top: 120px; width: 420px; height: 420px; border-radius: 50%; background: #e9f5ff; filter: blur(4px); z-index: -1; }
.eyebrow { margin: 0 0 10px; color: var(--blue); font-weight: 900; font-size: .8rem; letter-spacing: .13em; text-transform: uppercase; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 22px; max-width: 780px; font-size: clamp(2.7rem, 6vw, 5.6rem); line-height: .98; letter-spacing: -.055em; }
h1 span { color: var(--blue); }
.lead { max-width: 690px; color: #43566d; font-size: clamp(1.08rem, 2vw, 1.28rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 30px 0 22px; }
.button { border: 0; border-radius: 14px; padding: 14px 20px; cursor: pointer; text-decoration: none; font-weight: 850; transition: transform .16s ease, box-shadow .16s ease, background .16s ease; }
.button:hover { transform: translateY(-2px); }
.button.primary { color: white; background: var(--blue); box-shadow: 0 10px 25px rgba(21, 101, 216, .25); }
.button.primary:hover { background: var(--blue-dark); }
.button.secondary { color: var(--ink); background: white; border: 1px solid var(--line); }
.button.full { width: 100%; }
.button:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.trust-list { display: flex; flex-wrap: wrap; gap: 10px 24px; margin: 0; padding: 0; list-style: none; color: var(--muted); font-size: .92rem; }
.trust-list li::before { content: "✓"; margin-right: 7px; color: var(--green); font-weight: 900; }

.hero-card { position: relative; padding: 32px; border: 1px solid #cfe0ef; border-radius: 32px; background: linear-gradient(155deg, white, #eef7ff); box-shadow: var(--shadow); transform: rotate(1.5deg); }
.hero-card::after { content: "A1–B1"; position: absolute; top: -18px; right: 22px; padding: 8px 14px; border-radius: 99px; background: var(--yellow); font-weight: 900; transform: rotate(4deg); }
.card-kicker { color: var(--muted); font-weight: 800; }
.hero-card h2 { margin: 0; color: var(--blue); font-size: 4rem; line-height: 1; }
.meaning { color: var(--muted); }
.mini-table { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 18px; margin: 26px 0; padding: 20px; border-radius: 18px; background: white; font-size: 1.15rem; }
.mini-table strong { color: var(--blue); }
.memory-tip { display: flex; gap: 12px; align-items: flex-start; padding: 15px; border-radius: 16px; background: var(--pink); }
.memory-tip p { margin: 0; font-size: .9rem; }

.stats-strip { max-width: 1120px; margin: 0 auto 90px; padding: 20px 28px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; border-radius: 24px; background: var(--ink); color: white; }
.stats-strip div { display: flex; align-items: baseline; gap: 10px; }
.stats-strip strong { color: #8dc6ff; font-size: 2rem; }
.stats-strip span { font-size: .9rem; }

.trainer-section, .program-section, .access-section { max-width: 1180px; margin: 0 auto; padding: 80px 24px; }
.trainer-section { max-width: none; background: linear-gradient(180deg, #f0f8ff, #fbfdff); }
.trainer-section > * { max-width: 1180px; margin-left: auto; margin-right: auto; }
.section-heading { margin-bottom: 34px; }
.section-heading h2, .access-copy h2 { margin-bottom: 10px; font-size: clamp(2rem, 4vw, 3.2rem); letter-spacing: -.035em; }
.section-heading > p:last-child { color: var(--muted); }
.trainer-layout { display: grid; grid-template-columns: 230px minmax(0, 1fr) 230px; gap: 20px; align-items: start; }
.control-panel, .practice-card, .table-card, .progress-panel { padding: 24px; border: 1px solid var(--line); border-radius: 24px; background: white; box-shadow: 0 12px 35px rgba(39, 73, 107, .08); }
.control-panel label { display: block; margin: 0 0 7px; font-size: .84rem; font-weight: 850; }
.control-panel select { width: 100%; margin-bottom: 18px; padding: 11px 36px 11px 12px; border: 1px solid #ccd9e4; border-radius: 12px; background: white; color: var(--ink); }
.mode-tabs { display: grid; gap: 8px; margin-top: 8px; }
.mode-tab { padding: 10px 12px; text-align: left; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: #f7fafc; cursor: pointer; font-weight: 750; }
.mode-tab.is-active { color: white; border-color: var(--blue); background: var(--blue); }
.access-chip { margin-top: 18px; padding: 10px; border-radius: 12px; background: var(--cream); color: #7b5b12; font-size: .82rem; font-weight: 750; }
.practice-card { min-height: 410px; text-align: center; }
.practice-meta { display: flex; justify-content: space-between; color: var(--muted); font-size: .84rem; font-weight: 750; }
.prompt-label { margin-top: 46px; color: var(--muted); }
.task-prompt { margin: 12px 0 5px; font-size: clamp(2.2rem, 5vw, 4rem); letter-spacing: -.03em; }
.task-prompt strong { color: var(--blue); }
.task-translation { color: var(--muted); }
#answerForm { max-width: 560px; margin: 30px auto 0; display: flex; gap: 10px; }
#answerInput, .modal-card > input, .inline-form input { min-width: 0; flex: 1; padding: 14px 16px; border: 2px solid #c8d8e6; border-radius: 14px; color: var(--ink); background: white; outline: none; }
#answerInput:focus, .modal-card > input:focus, .inline-form input:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(21, 101, 216, .1); }
.feedback { min-height: 64px; margin: 20px auto 0; padding: 14px; max-width: 560px; border-radius: 14px; font-weight: 750; }
.feedback.is-correct { color: #075f41; background: #def8ed; }
.feedback.is-wrong { color: #9b263a; background: #ffe6eb; }
.practice-actions { display: flex; justify-content: center; gap: 18px; align-items: center; }
.text-button { padding: 8px; border: 0; color: var(--blue); background: transparent; cursor: pointer; font-weight: 800; }
.score strong { display: block; color: var(--blue); font-size: 3rem; line-height: 1; }
.score span { color: var(--muted); font-size: .85rem; }
.progress-bar { height: 9px; margin: 22px 0 9px; overflow: hidden; border-radius: 99px; background: #e7edf3; }
.progress-bar span { display: block; width: 0; height: 100%; background: var(--blue); transition: width .25s ease; }
.progress-panel > p:not(.eyebrow) { margin: 8px 0; font-size: .9rem; }
.table-heading { display: flex; justify-content: space-between; gap: 20px; align-items: end; }
.table-heading h3 { margin: 0; color: var(--blue); font-size: 2.7rem; }
.table-heading > span { color: var(--muted); }
.conjugation-table { margin: 24px 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.conjugation-row { display: grid; grid-template-columns: 75px 1fr; padding: 14px 16px; border-radius: 13px; background: #f3f8fc; }
.conjugation-row strong { color: var(--blue); }
.grammar-note { padding: 14px; border-radius: 13px; background: var(--cream); color: #6a5520; }

.program-section { padding-top: 100px; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature-grid article { min-height: 220px; padding: 26px; border-radius: 22px; border: 1px solid var(--line); background: white; }
.feature-grid article:nth-child(2n) { background: var(--cream); }
.feature-grid article:nth-child(3n) { background: #eef7ff; }
.feature-grid article > span { color: var(--blue); font-weight: 950; }
.feature-grid h3 { margin: 42px 0 8px; font-size: 1.35rem; }
.feature-grid p { color: var(--muted); }

.access-section { margin-top: 60px; display: grid; grid-template-columns: 1fr 420px; gap: 70px; align-items: center; }
.access-section::before { content: ""; position: absolute; left: 0; right: 0; height: 570px; z-index: -1; background: var(--pink); }
.access-copy > p { color: var(--muted); font-size: 1.08rem; }
.access-copy li { margin: 10px 0; }
.price-card { padding: 34px; border-radius: 28px; background: white; box-shadow: var(--shadow); }
.price-note { display: inline-block; padding: 6px 10px; border-radius: 99px; background: var(--yellow); font-weight: 850; }
.price { margin: 22px 0; }
.price strong, .price span { display: block; }
.price strong { font-size: 3rem; letter-spacing: -.04em; }
.price span, .payment-note, .form-help, .status { color: var(--muted); font-size: .85rem; }
.price-card hr { margin: 25px 0; border: 0; border-top: 1px solid var(--line); }
.price-card form > label { display: block; margin-bottom: 9px; font-weight: 800; }
.inline-form { display: flex; gap: 8px; }
.status { min-height: 22px; margin: 8px 0 0; }

footer { max-width: 1180px; margin: 90px auto 0; padding: 34px 24px 50px; display: flex; justify-content: space-between; gap: 30px; color: var(--muted); border-top: 1px solid var(--line); }

.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(15, 35, 55, .7); backdrop-filter: blur(6px); }
.modal-card { position: relative; width: min(600px, 100%); max-height: calc(100vh - 40px); overflow: auto; padding: 32px; border-radius: 26px; background: white; box-shadow: var(--shadow); }
.modal-card h2 { font-size: 2rem; }
.modal-close { position: absolute; right: 18px; top: 14px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: #f0f4f8; cursor: pointer; font-size: 1.6rem; }
.modal-card > label { display: block; margin: 20px 0 8px; font-weight: 800; }
.modal-card > input { width: 100%; }
.selected-plan { padding: 14px; border-radius: 14px; background: #eef7ff; font-weight: 850; }
.consents { display: grid; gap: 10px; margin: 20px 0; font-size: .86rem; }
.consents label { display: flex; gap: 8px; align-items: flex-start; }
.consents input { margin-top: 4px; }
body.has-modal { overflow: hidden; }

@media (max-width: 950px) {
  .hero { grid-template-columns: 1fr; gap: 44px; }
  .hero-card { max-width: 560px; }
  .trainer-layout { grid-template-columns: 210px 1fr; }
  .progress-panel { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, 1fr); align-items: center; gap: 14px; }
  .progress-panel .eyebrow, .progress-panel .text-button { grid-column: 1 / -1; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .access-section { grid-template-columns: 1fr 360px; gap: 35px; }
}

@media (max-width: 680px) {
  .site-header { align-items: flex-start; }
  .site-header nav { display: none; }
  .hero { margin-top: 18px; }
  h1 { font-size: clamp(2.6rem, 14vw, 4rem); }
  .stats-strip { margin-left: 14px; margin-right: 14px; grid-template-columns: repeat(2, 1fr); }
  .trainer-section, .program-section, .access-section { padding-left: 16px; padding-right: 16px; }
  .trainer-layout { grid-template-columns: 1fr; }
  .control-panel { display: block; }
  #answerForm, .inline-form { flex-direction: column; }
  .conjugation-table { grid-template-columns: 1fr; }
  .progress-panel { grid-column: auto; grid-template-columns: repeat(2, 1fr); }
  .feature-grid, .access-section { grid-template-columns: 1fr; }
  .access-section::before { height: 900px; }
  footer { flex-direction: column; }
}
