
:root {
  --bg: #eef3ff;
  --card: #ffffff;
  --primary: #7f95e8;
  --primary-dark: #5f75ca;
  --text: #1b2440;
  --muted: #66708f;
  --line: #d8def3;
}
*{box-sizing:border-box}
body{margin:0;font-family:"Avenir Next","Nunito","Segoe UI",sans-serif;background:linear-gradient(180deg,#f4f7ff 0%,#e9efff 100%);color:var(--text);min-height:100vh;padding:20px}
.shell{width:min(1100px,100%);margin:0 auto;background:var(--card);border:1px solid var(--line);border-radius:28px;overflow:hidden;box-shadow:0 24px 60px rgba(71,96,181,.12)}
.top{background:#b8c7f8;padding:18px 24px;display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap}
.title{font-size:28px;font-weight:800}.sub{color:#33406e;font-weight:700}
.stage-nav{padding:14px 24px 0;display:flex;gap:10px;flex-wrap:wrap}
.stage-tab{border:1px solid #d6def8;background:#eef2ff;color:#51608c;padding:10px 14px;border-radius:999px;font-size:14px;font-weight:800;cursor:pointer}
.stage-tab.active{background:var(--primary);color:#fff;border-color:var(--primary)}
.progress-wrap{padding:18px 24px 0}.progress-bar{width:100%;height:10px;border-radius:999px;background:#edf1ff;overflow:hidden}.progress-fill{height:100%;width:0;background:linear-gradient(90deg,#f6a5b6 0%,#8ba4ff 100%);transition:width .25s ease}
.stage{padding:10px 24px 24px;color:var(--primary-dark);font-weight:800;font-size:18px}
.main{display:grid;grid-template-columns:1.2fr .8fr;gap:20px;padding:0 24px 24px}
.panel{border:1px solid var(--line);border-radius:24px;padding:22px;background:#fcfdff}
.guide{background:#f7f9ff;color:var(--muted);border-radius:18px;padding:14px 16px;line-height:1.6;margin-bottom:18px}
.sentence-index,.section-index{font-size:14px;font-weight:800;color:var(--primary-dark);letter-spacing:.04em;text-transform:uppercase}
.sentence{font-size:clamp(24px,3vw,38px);line-height:1.35;margin:12px 0 10px;min-height:220px;display:flex;align-items:center}
.paragraph-text{font-size:clamp(20px,2.2vw,29px);line-height:1.55;min-height:250px}
.page-text{font-size:clamp(18px,2vw,26px);line-height:1.7;min-height:320px;white-space:pre-wrap}
.sentence-jumps,.jump-progress{display:flex;flex-wrap:wrap;gap:10px;margin-top:6px}
.jump-btn,.progress-chip{border:1px solid var(--line);background:#f5f7ff;color:var(--primary-dark);padding:10px 12px;border-radius:14px;font-size:14px;font-weight:800;cursor:pointer}
.jump-btn.active,.progress-chip.active{background:var(--primary);color:#fff;border-color:var(--primary)}
.meta{color:var(--muted);font-size:14px}
.controls{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-top:18px}.controls.three{grid-template-columns:repeat(3,1fr)}
button,.link-btn{border:0;border-radius:16px;padding:14px 16px;font-size:16px;font-weight:800;cursor:pointer;text-decoration:none;display:inline-flex;align-items:center;justify-content:center}
.primary{background:var(--primary);color:white}.secondary{background:#eef2ff;color:var(--primary-dark)}.ghost{background:#f3f5fb;color:#44516f}
.aside h3{margin:0 0 12px}.list{display:grid;gap:8px;max-height:62vh;overflow:auto;padding-right:4px}.list-item{padding:12px 14px;border-radius:14px;background:#f7f9ff;border:1px solid transparent;color:#44516f;font-size:14px;line-height:1.45;cursor:pointer}.list-item.active{background:#edf1ff;border-color:#cfd8fb;color:var(--text);font-weight:700}
.footer-nav{display:flex;justify-content:space-between;gap:12px;padding:0 24px 24px;flex-wrap:wrap}.link-btn{background:#f3f5fb;color:#44516f;min-width:140px}
.hidden{display:none !important}.timer-box{display:flex;gap:12px;flex-wrap:wrap;align-items:center;margin-top:18px}.timer{font-size:30px;font-weight:900;color:var(--primary-dark)}.small{font-size:13px;color:var(--muted)}
.grid-home{display:grid;grid-template-columns:repeat(auto-fit,minmax(250px,1fr));gap:18px;padding:24px}.card-link{display:block;text-decoration:none;color:inherit;border:1px solid var(--line);border-radius:24px;padding:24px;background:#fcfdff;box-shadow:0 12px 28px rgba(71,96,181,.08)}.card-link h3{margin:0 0 8px;font-size:24px}.card-link p{margin:0;color:var(--muted);line-height:1.6}
.hero{padding:24px}.hero h2{margin:0 0 10px;font-size:32px}.hero p{margin:0;color:var(--muted);line-height:1.7}
@media (max-width:900px){.main{grid-template-columns:1fr}.controls{grid-template-columns:repeat(2,1fr)}.sentence{min-height:150px}.page-text{min-height:240px}}

.sentence-frag{display:inline;padding:2px 6px;border-radius:10px;transition:all .2s ease;outline:2px solid transparent}
.sentence-frag.active{background:#eef3ff;outline:2px solid #9bb2ff;box-shadow:0 0 0 4px rgba(127,149,232,.12)}
.paragraph-text.paragraph-outline{padding:14px 16px;border:2px solid #cfd8fb;border-radius:20px;background:#fafcff}


.stats-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px;padding:0 24px 24px}
.stat-card{background:#fcfdff;border:1px solid var(--line);border-radius:24px;padding:18px 20px;box-shadow:0 12px 28px rgba(71,96,181,.06)}
.stat-label{font-size:13px;color:var(--muted);font-weight:800;margin-bottom:8px}
.stat-value{font-size:36px;line-height:1.1;font-weight:900;color:var(--text)}
.stat-sub{font-size:13px;color:var(--muted);margin-top:6px}
@media (max-width:900px){.stats-grid{grid-template-columns:repeat(2,1fr)}}
@media (max-width:640px){.stats-grid{grid-template-columns:1fr}}


.stats-grid.four{grid-template-columns:repeat(4,minmax(0,1fr));}
.unit-table-wrap{padding:0 24px 24px}
.unit-table{width:100%;border-collapse:separate;border-spacing:0 10px}
.unit-table th{font-size:13px;color:var(--muted);text-align:left;padding:0 18px 4px}
.unit-table td{background:#fcfdff;border-top:1px solid var(--line);border-bottom:1px solid var(--line);padding:16px 18px;vertical-align:middle}
.unit-table td:first-child{border-left:1px solid var(--line);border-radius:18px 0 0 18px;font-weight:800;width:90px}
.unit-table td:last-child{border-right:1px solid var(--line);border-radius:0 18px 18px 0;width:130px}
.unit-title-cell{font-weight:800}
.unit-sub{font-size:12px;color:var(--muted);margin-top:4px}
.report-sections{display:grid;gap:24px;padding:0 24px 24px}
.report-card{background:#fcfdff;border:1px solid var(--line);border-radius:24px;padding:20px 22px;box-shadow:0 12px 28px rgba(71,96,181,.06)}
.report-card h3{margin:0 0 14px;font-size:24px}
.report-table{width:100%;border-collapse:collapse}
.report-table th,.report-table td{padding:12px 10px;border-bottom:1px solid var(--line);text-align:left;font-size:14px}
.report-table th{color:var(--muted);font-size:12px}
@media (max-width:900px){.stats-grid.four{grid-template-columns:repeat(2,minmax(0,1fr));}.unit-table thead{display:none}.unit-table,.unit-table tbody,.unit-table tr,.unit-table td{display:block;width:100%}.unit-table tr{margin-bottom:12px}.unit-table td{border:1px solid var(--line)!important;border-radius:18px!important}.unit-table td:last-child{width:100%}}


.choice-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;padding:24px}
.choice-card{display:block;text-decoration:none;color:inherit;border:1px solid var(--line);border-radius:24px;padding:28px;background:#fcfdff;box-shadow:none;text-align:center}
.choice-title{font-size:28px;font-weight:800;margin-bottom:10px}
.choice-desc{color:var(--muted);line-height:1.55;font-weight:500}
.choice-actions{margin-top:18px}
.choice-chip{display:inline-flex;padding:10px 16px;border-radius:999px;background:#eef2ff;color:#51608c;font-size:12px;font-weight:800;margin-bottom:14px}
.template-footer{display:flex;justify-content:space-between;gap:12px;padding:18px 24px 24px;flex-wrap:wrap}
.template-footer .link-btn,.template-footer button{min-width:150px;background:#f3f5fb;color:#44516f}
.template-footer .primary{background:var(--primary);color:#fff}
@media (max-width:760px){.choice-grid{grid-template-columns:1fr}}
