:root{--ink:#15243b;--blue:#1e3a5f;--gold:#d7a84b;--terra:#b85f45;--paper:#f7f2e8;--card:#fffdf8;--muted:#687487;--ok:#2e7d5b;--bad:#a23b3b;--line:#ddd5c7;--shadow:0 12px 35px rgba(21,36,59,.10)}
*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;font-family:Inter,system-ui,-apple-system,Segoe UI,sans-serif;background:linear-gradient(180deg,#efe8dc,#f8f5ef 38%,#f2eee6);color:var(--ink);min-height:100vh;min-height:100dvh}.hero{background:radial-gradient(circle at 80% 0,#284f76 0,#15243b 58%);color:white;padding:38px 20px 28px;border-bottom:4px solid var(--gold)}.hero__inner{max-width:1100px;margin:auto;display:flex;justify-content:space-between;align-items:center;gap:25px}.hero h1{font-family:Georgia,serif;font-size:clamp(2.4rem,6vw,4.6rem);margin:3px 0 7px;letter-spacing:-.03em}.hero p{margin:0;max-width:760px;color:#dbe5ef;font-size:1.08rem}.eyebrow{font-size:.76rem;letter-spacing:.18em;font-weight:800;color:var(--gold)}.seal{width:116px;height:116px;border:2px solid var(--gold);outline:1px solid rgba(255,255,255,.25);outline-offset:-10px;border-radius:50%;display:grid;place-items:center;text-align:center;font-family:Georgia,serif;font-size:1.35rem;color:#ffe0a2;transform:rotate(5deg);flex:0 0 auto}
.tabs{position:sticky;top:0;z-index:20;display:flex;justify-content:center;gap:8px;padding:10px;background:rgba(247,242,232,.93);backdrop-filter:blur(12px);border-bottom:1px solid var(--line)}button,select,input{font:inherit}.tab{border:0;background:transparent;padding:10px 20px;border-radius:999px;color:var(--blue);font-weight:800;cursor:pointer}.tab.active{background:var(--blue);color:white}main{max-width:1100px;margin:28px auto 60px;padding:0 18px}.panel{display:none}.panel.active{display:block}.grid{display:grid;gap:18px;margin-bottom:18px}.grid.two{grid-template-columns:1.15fr .85fr}.grid.three{grid-template-columns:repeat(3,1fr)}.card{background:rgba(255,253,248,.97);border:1px solid rgba(190,175,151,.55);border-radius:22px;box-shadow:var(--shadow);padding:24px}.card h2,.card h3{font-family:Georgia,serif;margin-top:0}.step{display:inline-grid;place-items:center;width:32px;height:32px;border-radius:50%;background:var(--terra);color:white;font-weight:900;margin-bottom:8px}.formula{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:16px;background:#eef2f5;border-left:4px solid var(--blue);border-radius:12px;margin:16px 0}.latin{font-family:Georgia,serif;color:#6f2d20}.latin.big{font-size:1.55rem;line-height:1.5}.translation{font-size:1.03rem;margin:16px 0;color:#33465f}.chips{display:flex;gap:7px;flex-wrap:wrap}.chips span,.tag{background:#efe7d8;border:1px solid #dfd2bd;padding:6px 9px;border-radius:999px;font-size:.82rem}mark{background:#ffe5a8;color:#633411;padding:2px 6px;border-radius:6px}.mini p{line-height:1.5}.method-list{display:grid;gap:11px;padding-left:1.35rem}.notice{margin:20px 0;padding:14px 16px;background:#fff3d3;border-left:4px solid var(--gold);border-radius:10px;line-height:1.5}.bad-notice{background:#f8e3e1;border-left-color:var(--bad)}.compare-row{display:grid;grid-template-columns:auto 1fr;gap:12px;align-items:start;padding:13px 0;border-bottom:1px solid #eee5d9}.compare-row:last-of-type{border-bottom:0}.compare-row small{color:var(--muted);line-height:1.45}.ending-table{width:100%;border-collapse:collapse;margin:10px 0 14px}.ending-table th,.ending-table td{padding:10px;border-bottom:1px solid #e6dfd4;text-align:left}.ending-table th{background:#f2ece2}
.primary,.secondary,.ghost{border:0;border-radius:12px;padding:12px 17px;font-weight:800;cursor:pointer;font-size:.95rem;min-height:44px}.primary{background:var(--terra);color:white}.secondary{background:var(--blue);color:white}.ghost{background:transparent;color:var(--blue);border:1px solid #bfc7cf}.primary:hover,.secondary:hover,.ghost:hover{filter:brightness(.96)}button:disabled{opacity:.45;cursor:default;filter:none!important}.plan-head,.free-head,.trainer-head{display:flex;align-items:center;justify-content:space-between;gap:20px}.plan-side{display:flex;align-items:center;gap:16px}.big-progress,.score{width:92px;height:92px;background:var(--ink);color:white;border-radius:50%;display:grid;place-content:center;text-align:center;flex:0 0 auto}.big-progress span,.score span{font-size:1.6rem;font-weight:900}.big-progress small,.score small{color:#ccd8e5}.progress{height:8px;background:#ddd4c5;border-radius:99px;overflow:hidden;margin:14px 3px 20px}.progress div{height:100%;width:0;background:var(--gold);transition:width .3s}.station-grid,.mode-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:16px}.station,.mode-card{position:relative;overflow:hidden}.station::after{content:"";position:absolute;inset:auto -30px -45px auto;width:110px;height:110px;border-radius:50%;background:rgba(215,168,75,.12)}.station-top,.mode-top{display:flex;justify-content:space-between;gap:12px;align-items:flex-start}.station-num{width:38px;height:38px;display:grid;place-items:center;border-radius:12px;background:var(--blue);color:white;font-weight:900}.station h3,.mode-card h3{font-family:Georgia,serif;margin:10px 0 8px}.station p,.mode-card p{color:var(--muted);line-height:1.45;margin:0 0 14px}.station-meta{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:15px}.station .mini-progress{height:7px;background:#e6dfd4;border-radius:99px;overflow:hidden;margin-bottom:13px}.station .mini-progress div{height:100%;background:var(--terra)}.station.completed{border-color:#8dbba6;background:#f5fff8}.station.completed .station-num{background:var(--ok)}.plan-actions{display:flex;gap:10px;justify-content:center;margin-top:20px}.lesson-limit{display:grid;gap:5px;font-size:.8rem;font-weight:800;color:var(--muted)}.lesson-limit select{padding:10px 12px;border:1px solid #cfc3af;border-radius:10px;background:white}.mode-icon{font-size:1.8rem}.mode-card button{width:100%}.back-link{border:0;background:transparent;padding:0 0 9px;color:var(--blue);font-weight:800;cursor:pointer}.task-card{margin:16px 0;min-height:330px;scroll-margin-top:75px}.task-label{font-weight:900;color:var(--terra);letter-spacing:.04em;margin-bottom:6px}.hint{color:var(--muted);line-height:1.5}.sentence{display:flex;gap:8px;flex-wrap:wrap;font-family:Georgia,serif;font-size:1.55rem;margin:22px 0}.word{padding:10px 12px;min-height:44px;border:1px solid #d6cbb9;border-radius:9px;background:white;cursor:pointer;user-select:none;color:var(--ink);position:relative}.word:hover{border-color:#a8977b}.word.selected{background:#f5cf7e;border-color:#9a6d16;box-shadow:0 0 0 2px rgba(154,109,22,.18)}.word.correct{background:#e2f1e8;border:2px solid var(--ok)}.word.wrong{background:#fae4e3;border:2px solid var(--bad);text-decoration:line-through}.phrase-box,.source-box{font-family:Georgia,serif;font-size:1.45rem;background:#f3eee4;padding:18px;border-radius:14px;border-left:4px solid var(--gold);margin:18px 0;line-height:1.5}.source-box span{font-family:Inter,system-ui,sans-serif;color:var(--muted);font-size:.95rem}.choices,.translation-choices{display:grid;gap:10px;margin:14px 0 18px}.choices.inline{display:flex;flex-wrap:wrap}.choice,.translation-choice,.build-choice,.word-card,.built-token{border:1px solid #d4c9b6;background:white;border-radius:12px;padding:12px 14px;min-height:44px;cursor:pointer;color:var(--ink);text-align:left;line-height:1.4}.choice:hover,.translation-choice:hover,.build-choice:hover,.word-card:hover{border-color:#9ba9b6}.choice.selected,.translation-choice.selected,.build-choice.selected,.ghost.selected{border-color:var(--blue);box-shadow:0 0 0 2px rgba(30,58,95,.15);background:#edf2f7}.feedback{margin-top:14px;padding:13px 15px;border-radius:12px;background:#eef2f5;line-height:1.55}.feedback.ok{background:#e3f2e9;color:#1f684b;border-left:4px solid var(--ok)}.feedback.bad{background:#f8e3e1;color:#8d302d;border-left:4px solid var(--bad)}.answer-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}.question-block{padding:16px;background:#f8f4ec;border-radius:14px}.question-block p:first-child{margin-top:0}.vocab-help{margin-top:18px;border-top:1px solid #ebe4d8;padding-top:12px}.vocab-help summary{cursor:pointer;font-weight:800;color:var(--blue)}.vocab-help-content{display:flex;gap:7px;flex-wrap:wrap;margin-top:10px}.vocab-chip{font-size:.8rem;background:#eef2f5;padding:6px 9px;border-radius:999px}.trainer-actions{display:flex;justify-content:flex-end}.mark-tools,.error-tools,.assemble-actions{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin:10px 0 16px}.mark-tools span{color:var(--muted);font-size:.9rem}.build-target{min-height:70px;border:2px dashed #d2c5b1;border-radius:14px;padding:12px;display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin:15px 0;background:#fcfaf6}.placeholder{color:#8a8f98}.word-bank{display:flex;gap:10px;flex-wrap:wrap;padding:15px;background:#f4efe6;border-radius:14px}.word-card{font-family:Georgia,serif;font-size:1.15rem}.built-token{background:#e9eef4;border-color:#93a4b5;font-family:Georgia,serif}.error-sentence{justify-content:center}.result-card{text-align:center;padding:20px}.result-card .result-number{font-size:3rem;font-weight:900;color:var(--terra)}.result-actions{display:flex;justify-content:center;gap:10px;flex-wrap:wrap;margin-top:18px}.mistake-list{text-align:left;margin:24px auto 0;max-width:800px}.mistake-list h3{text-align:center}.mistake-row{display:grid;grid-template-columns:1.2fr 1fr;gap:12px;padding:12px;border-bottom:1px solid #e9e0d4}.mistake-row span{color:var(--muted)}.success-note{padding:12px;background:#e3f2e9;border-radius:12px}.hidden{display:none!important}.vocab-controls{display:flex;justify-content:space-between;gap:22px;align-items:end;margin-bottom:16px}.filters{display:flex;gap:10px;flex-wrap:wrap}.filters label{font-size:.8rem;font-weight:800;color:var(--muted);display:grid;gap:5px}.filters select,.filters input{border:1px solid #cfc3af;border-radius:10px;padding:10px;background:white;min-width:150px}.vocab-table-wrap{padding:0;overflow:hidden}.vocab-table{border-collapse:collapse;width:100%}.vocab-table th{background:var(--ink);color:white;text-align:left;padding:12px 14px;font-size:.82rem}.vocab-table td{padding:11px 14px;border-bottom:1px solid #ebe4d8;vertical-align:top}.vocab-table tbody tr:hover{background:#fbf5ea}.vocab-table td:nth-child(1){font-weight:900;color:var(--terra);width:45px}.vocab-table td:nth-child(2){font-family:Georgia,serif;font-weight:700;color:#5c2b20}.vocab-table td:nth-child(3){color:var(--muted);font-size:.86rem}.vocab-table td:nth-child(5){color:var(--muted);font-size:.85rem}.empty{padding:35px;text-align:center;color:var(--muted)}footer{text-align:center;padding:30px;color:#7b8290;font-size:.85rem}.mode-explain{margin-bottom:18px}.mode-strip{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin-top:14px}.mode-strip>div{display:grid;gap:6px;padding:15px;border-radius:14px;background:#f3eee4;border:1px solid #dfd2bd}.mode-strip b{font-family:Georgia,serif;font-size:1.05rem}.mode-strip span{color:var(--muted);font-size:.9rem;line-height:1.45}.word-wrap{display:inline-flex;align-items:flex-end;gap:1px}.punct{font-family:Georgia,serif;font-weight:800;align-self:center}.sentence .punct{margin-left:-5px}
@media(max-width:800px){.grid.two,.grid.three,.station-grid,.mode-grid,.answer-grid{grid-template-columns:1fr}.seal{display:none}.vocab-controls,.plan-head,.free-head{display:block}.plan-side{margin-top:16px;align-items:flex-end;justify-content:space-between}.filters{margin-top:15px}.vocab-table th:nth-child(3),.vocab-table td:nth-child(3),.vocab-table th:nth-child(5),.vocab-table td:nth-child(5){display:none}.card{padding:18px}.sentence{font-size:1.3rem}.tabs{justify-content:flex-start;overflow-x:auto}.tab{flex:0 0 auto;padding:9px 13px}.trainer-head{align-items:flex-start}.score{width:72px;height:72px}.plan-actions{flex-direction:column}.mode-strip{grid-template-columns:1fr}.mistake-row{grid-template-columns:1fr}.phrase-box,.source-box{font-size:1.25rem}}

.station.locked{opacity:.68;background:#f2efe9}.station.locked .station-num{background:#7e8791}.station.locked::after{display:none}
button:focus-visible,select:focus-visible,input:focus-visible,summary:focus-visible{outline:3px solid rgba(215,168,75,.75);outline-offset:2px}
@media(max-width:800px){.sentence{gap:10px}.word,.choice,.translation-choice,.word-card,.built-token,.primary,.secondary,.ghost{min-height:48px}.word{padding:11px 13px}}
