:root {
  --ink:#17172b; --muted:#6e7187; --paper:#f5f5ff; --white:#fff; --violet:#6550df;
  --violet-dark:#3c318d; --lime:#d9ff62; --line:#e2e3ee; --green:#2a8c61; --red:#b23e56;
  --shadow:0 22px 70px rgba(40,36,86,.12); --radius:28px;
}
* { box-sizing:border-box; }
html { min-height:100%; scroll-behavior:smooth; scroll-padding-top:105px; }
body { margin:0; min-height:100%; background:var(--paper); color:var(--ink); font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; -webkit-font-smoothing:antialiased; }
a { color:inherit; text-decoration:none; }
button,input,select { font:inherit; }
button,a { -webkit-tap-highlight-color:transparent; }
button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible { outline:3px solid rgba(101,80,223,.28); outline-offset:3px; }
.app-header { position:sticky; z-index:40; top:0; border-bottom:1px solid var(--line); background:rgba(247,247,255,.94); backdrop-filter:blur(18px); }
.header-inner { width:min(1450px,100%); min-height:86px; margin:auto; padding:12px clamp(18px,4vw,60px); display:flex; align-items:center; gap:clamp(25px,5vw,70px); }
.brand { flex:none; display:flex; align-items:center; gap:12px; }
.brand img { width:52px; height:52px; border-radius:17px; box-shadow:0 10px 24px rgba(23,23,43,.15); }
.brand span { display:grid; gap:3px; }
.brand b { font-size:21px; letter-spacing:-.04em; }
.brand small { color:#73758a; font-size:9px; font-weight:850; letter-spacing:.13em; text-transform:uppercase; }
.main-nav { display:flex; align-items:center; gap:30px; margin-left:auto; }
.main-nav a { position:relative; padding:12px 0; color:#65687c; font-size:13px; font-weight:800; }
.main-nav a.active { color:var(--ink); }
.main-nav a.active::after { content:""; position:absolute; right:0; bottom:4px; left:0; height:3px; border-radius:9px; background:var(--lime); }
.mobile-nav { display:none; }
.account-menu { display:flex; align-items:center; gap:10px; margin-left:auto; }
.account-menu > span { padding:9px 13px; border:1px solid #dcdeeb; border-radius:999px; background:#fff; color:#5d6074; font-size:11px; font-weight:850; }
.account-menu form { margin:0; }
.account-menu button { padding:9px 12px; border:0; background:transparent; color:#777a8d; font-size:11px; font-weight:800; cursor:pointer; }
.app-shell { width:min(1450px,100%); min-height:calc(100vh - 87px); margin:auto; padding:clamp(28px,5vw,68px) clamp(18px,4vw,60px) 80px; }
.with-toolkit { transition:padding .2s; }
body.has-toolkit { padding-right:86px; }
.eyebrow,.panel > span,.setup-card > span,.task-kicker,.card-heading > span { display:block; color:#6653d5; font-size:10px; font-weight:900; letter-spacing:.15em; text-transform:uppercase; }
h1,h2,h3,p { margin-top:0; }
h1 { margin-bottom:18px; font-size:clamp(40px,5.8vw,82px); line-height:.98; letter-spacing:-.065em; font-weight:620; }
h1 em { color:#6550d9; font-style:normal; }
h2 { letter-spacing:-.035em; }
p { color:var(--muted); line-height:1.65; }
.primary { min-height:52px; padding:0 20px; display:inline-flex; align-items:center; justify-content:space-between; gap:18px; border:0; border-radius:15px; background:var(--ink); color:#fff; font-size:13px; font-weight:900; cursor:pointer; box-shadow:0 12px 24px rgba(23,23,43,.14); }
.primary:hover { transform:translateY(-1px); }
.primary:disabled { opacity:.55; cursor:not-allowed; transform:none; }
.button-link { min-width:210px; }
.alert { max-width:900px; margin:0 auto 18px; padding:14px 18px; border-radius:15px; font-size:12px; font-weight:760; line-height:1.45; }
.alert.error { border:1px solid #f1b9c4; background:#fff0f3; color:#92344a; }
.alert.success { border:1px solid #bce5d1; background:#ecfff5; color:#246d4d; }

/* Авторизация */
.auth-grid { width:min(1220px,100%); min-height:calc(100vh - 220px); margin:auto; display:grid; grid-template-columns:minmax(0,1fr) minmax(390px,520px); align-items:center; gap:clamp(40px,8vw,120px); }
.auth-story { padding:30px 0; }
.auth-story h1 { margin-top:16px; }
.auth-story > p { max-width:620px; font-size:15px; }
.auth-story ul { margin:26px 0 0; padding:0; display:grid; gap:12px; list-style:none; }
.auth-story li { position:relative; padding-left:28px; color:#53566a; font-size:13px; font-weight:760; }
.auth-story li::before { content:"✓"; position:absolute; left:0; width:19px; height:19px; display:grid; place-items:center; border-radius:7px; background:var(--lime); color:#30324a; font-size:11px; }
.auth-card,.setup-card { padding:clamp(26px,4vw,46px); border:1px solid #e0e1ec; border-radius:32px; background:#fff; box-shadow:var(--shadow); }
.card-heading h2 { margin:10px 0 8px; font-size:clamp(27px,3.4vw,40px); }
.card-heading p { margin-bottom:25px; font-size:12px; }
.stack-form { display:grid; gap:15px; }
.stack-form label:not(.check):not(.choice) { display:grid; gap:7px; }
.stack-form label > span { color:#45485c; font-size:11px; font-weight:850; }
.stack-form input,.stack-form select { width:100%; min-height:52px; padding:0 15px; border:1px solid #d9dae7; border-radius:14px; background:#fafaff; color:var(--ink); font-size:15px; }
.stack-form input:focus,.stack-form select:focus { border-color:#7b68e1; background:#fff; }
.stack-form small { color:#85879a; font-size:9px; line-height:1.45; }
.stack-form .primary { margin-top:5px; }
.check { display:grid; grid-template-columns:18px 1fr; align-items:start; gap:10px; color:#6e7185; font-size:10px; line-height:1.55; }
.check input { width:18px!important; min-height:18px!important; margin:1px 0 0; accent-color:#6550df; }
.auth-links { margin-top:22px; padding-top:18px; display:flex; justify-content:space-between; gap:15px; border-top:1px solid #ececf2; }
.auth-links a { color:#5c4bc7; font-size:10px; font-weight:850; }
fieldset { margin:0; padding:0; border:0; }
fieldset legend { margin-bottom:9px; color:#45485c; font-size:11px; font-weight:850; }
.choice { margin-bottom:8px; padding:12px; display:flex; align-items:center; gap:11px; border:1px solid #ddddea; border-radius:14px; cursor:pointer; }
.choice input { width:18px!important; min-height:18px!important; accent-color:#6550df; }
.choice span { display:grid; gap:2px; }.choice b { font-size:12px; }.choice small { font-size:9px; }

/* Кабинет */
.role-switcher { max-width:620px; margin:0 0 16px auto; padding:7px 7px 7px 13px; display:flex; align-items:end; gap:8px; border:1px solid #dedfeb; border-radius:16px; background:#fff; }
.role-switcher label { flex:1; display:grid; gap:3px; }.role-switcher label span { color:#85879a; font-size:8px; font-weight:800; text-transform:uppercase; }
.role-switcher select { min-height:34px; border:0; background:transparent; color:var(--ink); font-size:11px; font-weight:850; }
.role-switcher button { min-height:38px; padding:0 13px; border:0; border-radius:11px; background:#ece9ff; color:#4c3ba8; font-size:10px; font-weight:900; cursor:pointer; }
.trial-banner { margin-bottom:20px; padding:15px 20px; display:flex; align-items:center; justify-content:space-between; gap:20px; border-radius:19px; background:linear-gradient(115deg,#25233f,#373166); color:#fff; box-shadow:0 16px 35px rgba(36,33,71,.12); }
.trial-banner div { display:grid; gap:4px; }.trial-banner div span { color:var(--lime); font-size:9px; font-weight:900; letter-spacing:.12em; text-transform:uppercase; }.trial-banner div b { font-size:18px; }
.trial-banner > small { color:rgba(255,255,255,.65); font-size:10px; }
.trial-banner a { padding:10px 14px; border-radius:12px; background:var(--lime); color:#272842; font-size:10px; font-weight:900; }
.trial-banner.ended { background:#3c2a36; }
.hero-dashboard { min-height:430px; padding:clamp(38px,6vw,80px); display:grid; grid-template-columns:minmax(0,1.35fr) minmax(280px,.65fr); align-items:center; gap:clamp(35px,8vw,100px); overflow:hidden; border-radius:35px; background:var(--ink); color:#fff; }
.hero-dashboard h1 { margin:15px 0 20px; font-size:clamp(48px,6vw,88px); }
.hero-dashboard p { max-width:680px; color:rgba(255,255,255,.62); }
.hero-dashboard .eyebrow { color:var(--lime); }
.hero-dashboard > aside { padding:28px; display:grid; gap:12px; border:1px solid rgba(255,255,255,.12); border-radius:25px; background:rgba(255,255,255,.07); }
.hero-dashboard > aside small { color:rgba(255,255,255,.55); font-size:9px; font-weight:850; text-transform:uppercase; }
.hero-dashboard > aside strong { font-size:clamp(56px,7vw,90px); letter-spacing:-.06em; }
.hero-dashboard > aside strong span { margin-left:5px; color:rgba(255,255,255,.35); font-size:20px; letter-spacing:-.03em; }
.hero-dashboard > aside p { margin:0; font-size:10px; }
.meter { height:8px; overflow:hidden; border-radius:999px; background:rgba(255,255,255,.12); }.meter i { display:block; height:100%; border-radius:inherit; background:var(--lime); }
.parent-hero { background:linear-gradient(140deg,#201e3a,#3d2f7f); }.teacher-hero { background:linear-gradient(140deg,#192e36,#244c55); }.admin-hero { background:linear-gradient(140deg,#241e38,#442c58); }
.status-ok { color:var(--lime); font-size:55px!important; }
.dashboard-grid { margin-top:20px; display:grid; grid-template-columns:1.35fr .8fr .8fr; gap:16px; }
.panel { padding:26px; border:1px solid var(--line); border-radius:24px; background:#fff; box-shadow:0 10px 35px rgba(50,45,100,.05); }
.panel h2 { margin:10px 0 9px; font-size:clamp(22px,2.5vw,34px); }.panel p { margin-bottom:0; font-size:11px; }
.panel.featured { background:#eae7ff; border-color:#d7d0ff; }.panel.featured a { display:inline-block; margin-top:20px; color:#4b39ac; font-size:11px; font-weight:900; }
.two-column { margin-top:20px; display:grid; grid-template-columns:minmax(0,1.1fr) minmax(340px,.9fr); gap:18px; align-items:start; }
.people-list { margin:20px 0 0; padding:0; display:grid; gap:9px; list-style:none; }
.people-list li { padding:14px; display:flex; align-items:center; justify-content:space-between; gap:14px; border-radius:15px; background:#f5f5fb; }
.people-list li div { display:grid; gap:3px; }.people-list li b { font-size:12px; }.people-list li small,.people-list li > span { color:#7c7e91; font-size:9px; }.people-list .empty { align-items:flex-start; flex-direction:column; }
.launch-steps { margin-top:18px; display:grid; grid-template-columns:repeat(4,1fr); gap:12px; }
.launch-steps article { min-height:130px; padding:20px; display:flex; align-items:flex-start; gap:14px; border:1px solid #dedfeb; border-radius:20px; background:#fff; }
.launch-steps article > b { width:31px; height:31px; flex:none; display:grid; place-items:center; border-radius:10px; background:#eeeefa; color:#77798c; font-size:11px; }.launch-steps article.done > b { background:var(--lime); color:#25263c; }
.launch-steps article div { display:grid; gap:7px; }.launch-steps strong { font-size:12px; }.launch-steps span { color:#7a7c8f; font-size:9px; line-height:1.5; }
.onboarding { display:grid; grid-template-columns:minmax(0,1.1fr) minmax(390px,.9fr); align-items:center; gap:clamp(35px,7vw,90px); }
.onboarding-copy h1 { margin-top:15px; }
.onboarding-copy ol { margin:28px 0 0; padding:0; display:grid; gap:11px; list-style:none; }
.onboarding-copy li { padding:12px; display:grid; grid-template-columns:38px 1fr; gap:12px; border:1px solid #e1e2ee; border-radius:16px; background:rgba(255,255,255,.72); }
.onboarding-copy li > b { width:38px; height:38px; display:grid; place-items:center; border-radius:12px; background:#e8e7f4; font-size:11px; }.onboarding-copy li.done > b { background:var(--lime); }
.onboarding-copy li span { display:grid; gap:3px; }.onboarding-copy li strong { font-size:12px; }.onboarding-copy li small { color:#7a7d90; font-size:9px; line-height:1.5; }
.setup-card { display:grid; gap:19px; }.setup-card h2 { margin:-8px 0 0; font-size:30px; }
.segmented { display:grid; grid-template-columns:repeat(3,1fr); gap:7px; }.segmented.compact { grid-template-columns:repeat(5,1fr); }
.segmented label { cursor:pointer; }.segmented input { position:absolute; opacity:0; pointer-events:none; }.segmented span { min-height:48px; padding:7px; display:grid; place-items:center; border:1px solid #dedfeb; border-radius:12px; background:#f8f8fd; color:#626579; font-size:10px; font-weight:850; text-align:center; }.segmented input:checked + span { border-color:#6c57dd; background:#ebe7ff; color:#4937a4; box-shadow:inset 0 0 0 1px #6c57dd; }
.narrow { max-width:760px; margin:50px auto; }.narrow h1 { margin-top:15px; font-size:clamp(38px,6vw,62px); }

/* Занятие */
.lesson-head { padding:20px 0 35px; display:grid; grid-template-columns:1fr 190px; gap:40px; align-items:end; }
.lesson-head a { color:#6553d1; font-size:10px; font-weight:850; }.lesson-head div > span { display:block; margin:25px 0 10px; color:#8175c9; font-size:9px; font-weight:900; text-transform:uppercase; }.lesson-head h1 { margin:0 0 13px; }.lesson-head p { max-width:760px; margin:0; font-size:12px; }
.lesson-head aside { padding:20px; display:grid; gap:6px; border-radius:20px; background:#eae7ff; }.lesson-head aside small { color:#7064ad; font-size:9px; text-transform:uppercase; }.lesson-head aside strong { font-size:29px; }.lesson-head aside span { color:#716f85; font-size:9px; }
.task-card { max-width:990px; padding:clamp(28px,5vw,55px); border:1px solid #dfe0eb; border-radius:30px; background:#fff; box-shadow:var(--shadow); }
.task-card h2 { margin:15px 0; font-size:clamp(27px,4vw,45px); }.task-card > p { font-size:12px; }
.protected-content { position:relative; isolation:isolate; overflow:hidden; -webkit-user-select:none; user-select:none; -webkit-touch-callout:none; }
.task-content { position:relative; z-index:2; }
.protected-content input,.protected-content button { -webkit-user-select:text; user-select:text; }
.content-watermark { position:absolute; z-index:1; inset:-8%; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); align-content:space-around; justify-items:center; gap:32px; pointer-events:none; overflow:hidden; color:#3f347f; opacity:.065; transform:rotate(-18deg) scale(1.12); }
.content-watermark span { white-space:nowrap; font-size:10px; font-weight:950; letter-spacing:.08em; }
.content-protection-note { margin:18px 0 0; display:flex; align-items:center; gap:7px; color:#88899a; font-size:8px; line-height:1.5; }
.content-protection-note span { color:#6552d8; font-size:12px; }
.answer-form { margin-top:30px; display:flex; align-items:end; gap:12px; }.answer-form label { flex:1; display:grid; gap:7px; }.answer-form label span { color:#55586b; font-size:10px; font-weight:850; }.answer-form input { min-height:54px; padding:0 15px; border:1px solid #d9dae7; border-radius:15px; background:#f9f9fd; font-size:18px; }
.answer-feedback { margin-top:18px; padding:16px 18px; border-radius:15px; font-size:11px; line-height:1.55; }.answer-feedback.correct { background:#e8fff3; color:#246c4d; }.answer-feedback.incorrect { background:#fff3de; color:#805a17; }
.protection-toast { position:fixed; z-index:140; left:50%; bottom:22px; max-width:min(520px,calc(100vw - 28px)); padding:12px 17px; border:1px solid rgba(255,255,255,.16); border-radius:14px; background:#202037; color:#fff; font-size:10px; font-weight:800; line-height:1.45; text-align:center; transform:translateX(-50%); box-shadow:0 16px 45px rgba(20,18,48,.28); }
.protection-toast[hidden] { display:none; }

/* PWA */
.install-card { position:fixed; z-index:55; right:110px; bottom:22px; width:min(520px,calc(100vw - 140px)); padding:12px; display:grid; grid-template-columns:44px 1fr auto 30px; align-items:center; gap:11px; border:1px solid #d6d7e6; border-radius:20px; background:#fff; box-shadow:0 18px 50px rgba(32,29,70,.18); }
.install-card[hidden] { display:none; }.install-card img { width:44px; height:44px; border-radius:13px; }.install-card div { display:grid; gap:3px; }.install-card b { font-size:11px; }.install-card span { color:#77798c; font-size:8px; line-height:1.4; }.install-card > button:not(.icon-close) { min-height:38px; padding:0 12px; border:0; border-radius:11px; background:var(--ink); color:#fff; font-size:9px; font-weight:900; cursor:pointer; }.icon-close { width:30px; height:30px; border:0; background:transparent; color:#8b8d9e; font-size:20px; cursor:pointer; }

/* Набор химика: рабочая область зарезервирована, кнопки не закрывают текст */
.chem-dock { position:fixed; z-index:50; top:0; right:0; bottom:0; width:86px; padding:100px 8px 18px; display:flex; flex-direction:column; justify-content:center; gap:8px; border-left:1px solid #dcddea; background:rgba(245,245,255,.97); box-shadow:-10px 0 30px rgba(40,36,84,.05); }
.chem-dock > strong { margin-bottom:5px; display:grid; color:#85879a; font-size:7px; line-height:1.2; letter-spacing:.12em; text-align:center; text-transform:uppercase; }
.chem-dock button { min-height:70px; padding:7px 3px; display:grid; place-items:center; align-content:center; gap:5px; border:1px solid #dfe0eb; border-radius:17px; background:#fff; color:#5d6074; cursor:pointer; }
.chem-dock button i { width:30px; height:30px; display:grid; place-items:center; border-radius:10px; background:#eae7ff; color:#4b3ba7; font:800 13px Georgia,serif; }
.chem-dock button span { font-size:7px; font-weight:850; line-height:1.1; }
.chem-dock button:hover { border-color:#8274df; transform:translateX(-2px); }
.tool-modal { position:fixed; z-index:100; inset:0; padding:20px; display:grid; place-items:center; background:rgba(18,17,35,.64); backdrop-filter:blur(9px); }
.tool-modal[hidden] { display:none; }.modal-open { overflow:hidden; }
.tool-dialog { width:min(1280px,100%); height:min(880px,calc(100vh - 40px)); display:grid; grid-template-rows:auto auto 1fr; overflow:hidden; border:1px solid rgba(255,255,255,.25); border-radius:30px; background:#f7f7fc; box-shadow:0 35px 100px rgba(12,11,30,.4); }
.tool-dialog > header { min-height:88px; padding:17px 21px 14px 28px; display:flex; align-items:center; justify-content:space-between; gap:20px; background:var(--ink); color:#fff; }.tool-dialog > header div { display:grid; gap:4px; }.tool-dialog > header small { color:var(--lime); font-size:8px; font-weight:900; text-transform:uppercase; letter-spacing:.15em; }.tool-dialog > header h2 { margin:0; font-size:26px; }.tool-dialog > header button { width:46px; height:46px; border:1px solid rgba(255,255,255,.18); border-radius:15px; background:rgba(255,255,255,.08); color:#fff; font-size:30px; cursor:pointer; }
.tool-tabs { padding:9px 16px; display:flex; gap:7px; overflow:auto; border-bottom:1px solid #dedfeb; background:#fff; }.tool-tabs button { min-height:40px; padding:0 16px; flex:none; border:1px solid #dedfeb; border-radius:12px; background:#f7f7fb; color:#696b7e; font-size:9px; font-weight:850; cursor:pointer; }.tool-tabs button.active { border-color:#6854d8; background:#eae7ff; color:#4939a1; }
.tool-content { min-height:0; overflow:auto; padding:18px; }
.reference-toolbar { padding:12px 15px; display:grid; grid-template-columns:minmax(250px,.8fr) minmax(250px,1.2fr); align-items:end; gap:18px; border:1px solid #dedfeb; border-radius:17px; background:#fff; }.reference-toolbar label { display:grid; gap:6px; }.reference-toolbar label span { color:#686b7e; font-size:8px; font-weight:850; text-transform:uppercase; }.reference-toolbar input { min-height:43px; padding:0 12px; border:1px solid #d9dae7; border-radius:12px; }.reference-toolbar p { margin:0; font-size:9px; }
.element-detail { margin:12px 0; padding:11px 14px; display:grid; grid-template-columns:38px 52px minmax(130px,1fr) auto; align-items:center; gap:11px; border:1px solid #dedfeb; border-radius:17px; background:#fff; }.element-detail > strong { color:#808294; font-size:12px; text-align:center; }.element-detail > span { width:50px; height:50px; display:grid; place-items:center; border-radius:13px; background:#eae7ff; color:#4939a1; font:700 22px Georgia,serif; }.element-detail p { margin:0; display:grid; gap:3px; }.element-detail p b { font-size:13px; }.element-detail p small { color:#7b7d90; font-size:8px; }.element-detail dl { margin:0; display:flex; gap:7px; }.element-detail dl div { min-width:75px; padding:8px; border-radius:10px; background:#f1f1f7; }.element-detail dt { color:#828496; font-size:7px; }.element-detail dd { margin:3px 0 0; font-size:11px; font-weight:900; }
.periodic-scroll,.solubility-scroll { overflow:auto; border:1px solid #dcdeea; border-radius:18px; background:#fff; scrollbar-color:#b9b4e5 transparent; }
.periodic-grid { width:1040px; padding:9px; display:grid; grid-template-columns:repeat(18,54px); grid-template-rows:20px repeat(7,67px); gap:3px; }.periodic-grid > i { display:grid; place-items:center; color:#9294a5; font-size:7px; font-style:normal; }
.fblock { width:880px; margin:10px 0 10px 130px; display:grid; grid-template-columns:repeat(14,59px); gap:3px; }
.element { min-width:0; height:67px; padding:5px; display:grid; grid-template-columns:1fr auto; grid-template-rows:auto 1fr auto; border:1px solid #dedbea; border-radius:9px; background:#f0efff; color:#42349a; text-align:left; cursor:pointer; }.element small { font-size:6px; opacity:.7; }.element b { grid-column:1/-1; place-self:center; font:700 18px Georgia,serif; }.element span { min-width:0; overflow:hidden; color:#55576b; font-size:6px; text-overflow:ellipsis; white-space:nowrap; }.element em { color:#77798b; font-size:6px; font-style:normal; }.element.selected { border:2px solid #5f4ed0; box-shadow:0 5px 12px rgba(77,60,184,.18); }.element.dimmed { opacity:.13; }.category-noble{background:#e5f7ff!important;color:#176e97!important}.category-halogen{background:#fff0d9!important;color:#9a5a12!important}.category-alkali{background:#ffe8ef!important;color:#a44467!important}.category-alkaline{background:#fff6c9!important;color:#7c6712!important}.category-transition{background:#eaf4ff!important;color:#35638e!important}.category-nonmetal{background:#e8faee!important;color:#287148!important}.category-lanthanide{background:#f1eaff!important;color:#6945a4!important}.category-actinide{background:#fce9f5!important;color:#91466f!important}
.solubility-detail { min-height:70px; margin:12px 0; padding:11px 15px; display:grid; grid-template-columns:auto 48px minmax(180px,1fr); align-items:center; gap:12px; border:1px solid #dedfeb; border-radius:17px; background:#fff; }.solubility-detail > div { display:flex; align-items:center; gap:7px; }.solubility-detail > div span { min-height:38px; padding:0 10px; display:grid; place-items:center; border-radius:10px; background:#f0efff; font:700 15px Georgia,serif; }.solubility-detail i { color:#8a8c9d; font-style:normal; }.solubility-detail > strong { width:44px; height:44px; display:grid; place-items:center; border-radius:12px; }.solubility-detail p { margin:0; display:grid; gap:3px; }.solubility-detail p b { font-size:12px; }.solubility-detail p small { color:#7b7d90; font-size:8px; }
.solubility-scroll table { width:1060px; border-collapse:separate; border-spacing:0; table-layout:fixed; }.solubility-scroll th,.solubility-scroll td { height:50px; padding:4px; border-right:1px solid #ececf2; border-bottom:1px solid #ececf2; text-align:center; }.solubility-scroll thead th { position:sticky; z-index:2; top:0; background:#f2f1fa; }.solubility-scroll th:first-child { position:sticky; z-index:3; left:0; width:120px; background:#f6f5fb; }.solubility-scroll th b { display:block; font:700 13px Georgia,serif; }.solubility-scroll th small { display:block; margin-top:2px; color:#7d7f91; font-size:6px; }.solubility-scroll tbody th { padding-left:10px; text-align:left; }.mark { width:35px; height:35px; border:1px solid transparent; border-radius:10px; font-size:11px; font-weight:900; cursor:pointer; }.mark.selected { border:2px solid #5142ba; box-shadow:0 0 0 3px rgba(81,66,186,.13); transform:scale(1.08); }.mark-Р{background:#dff6e8!important;color:#1e7248!important}.mark-М{background:#fff0c9!important;color:#8b6310!important}.mark-Н{background:#ffe1e7!important;color:#9d3e58!important}.mark-—{background:#ececf1!important;color:#666979!important}.legend { margin-top:10px; display:flex; flex-wrap:wrap; gap:6px; }.legend span { padding:7px 10px; border-radius:10px; font-size:8px; }.legend b { margin-right:5px; }
.calculator-view { min-height:100%; display:grid; grid-template-columns:minmax(300px,430px) minmax(260px,400px); align-items:center; justify-content:center; gap:clamp(35px,7vw,90px); }.calculator { padding:18px; border-radius:28px; background:linear-gradient(155deg,#22233b,#151626); color:#fff; box-shadow:0 24px 55px rgba(29,29,60,.25); }.calculator header { padding:0 4px 12px; display:flex; justify-content:space-between; align-items:center; }.calculator header b { color:var(--lime); font-size:10px; }.calculator header span { color:rgba(255,255,255,.5); font-size:8px; }.calc-screen { min-height:100px; padding:15px; display:grid; justify-items:end; align-content:space-between; border-radius:17px; background:#eaf4e6; color:#17211a; }.calc-screen small { color:#647166; font-size:9px; }.calc-screen output { max-width:100%; overflow:hidden; font:700 42px ui-monospace,monospace; letter-spacing:-.05em; text-overflow:ellipsis; }.calc-keys { margin-top:12px; display:grid; grid-template-columns:repeat(4,1fr); gap:7px; }.calc-keys button { min-height:52px; border:1px solid rgba(255,255,255,.06); border-radius:13px; background:#343650; color:#fff; font-size:15px; font-weight:850; box-shadow:0 4px 0 #10111e; cursor:pointer; }.calc-keys .utility{background:#4a4d64}.calc-keys .operator{background:#6754df}.calc-keys .equals{background:var(--lime);color:#242638}.calculator-view aside { padding:25px; border:1px solid #dfe0eb; border-radius:23px; background:#fff; }.calculator-view aside h3 { font-size:20px; }.calculator-view aside ul { margin:16px 0 0; padding-left:18px; display:grid; gap:10px; color:#6e7185; font-size:10px; line-height:1.5; }

/* Правовые страницы и сквозные ссылки */
.check a { color:#5140b6; text-decoration:underline; text-decoration-thickness:1px; text-underline-offset:2px; }
.app-legal-footer { width:min(1450px,100%); margin:0 auto; padding:26px clamp(18px,4vw,60px) 34px; display:grid; grid-template-columns:minmax(190px,1fr) auto auto; align-items:center; gap:24px; border-top:1px solid var(--line); color:#73768a; }
.app-legal-footer > div { display:grid; gap:4px; }.app-legal-footer > div b { color:var(--ink); font-size:13px; }.app-legal-footer > div span { font-size:9px; }
.app-legal-footer nav,.app-legal-footer .legal-nav { display:flex; flex-wrap:wrap; justify-content:center; gap:8px 16px; }
.app-legal-footer a { color:#5b4bc0; font-size:9px; font-weight:820; line-height:1.4; }
.legal-page { background:#f7f7ff; }
.legal-header { position:relative; border-bottom:1px solid var(--line); background:#fff; }
.legal-header > div { width:min(1280px,100%); min-height:86px; margin:auto; padding:12px clamp(18px,4vw,54px); display:flex; align-items:center; justify-content:space-between; gap:24px; }
.legal-home { min-height:42px; padding:0 16px; display:grid; place-items:center; border:1px solid #dedfeb; border-radius:13px; background:#fafaff; color:#5545b7; font-size:10px; font-weight:900; }
.legal-shell { width:min(1280px,100%); margin:auto; padding:clamp(44px,7vw,92px) clamp(18px,4vw,54px) 80px; }
.legal-hero { max-width:970px; margin-bottom:48px; }.legal-hero h1 { max-width:900px; margin:14px 0 18px; font-size:clamp(43px,6vw,76px); }.legal-hero > p:not(.document-meta) { max-width:760px; font-size:15px; }
.document-meta { margin:20px 0 0; color:#8176bd; font-size:10px; font-weight:850; letter-spacing:.04em; }
.legal-grid { display:grid; grid-template-columns:230px minmax(0,860px); align-items:start; gap:clamp(28px,6vw,80px); }
.legal-grid > aside { position:sticky; top:24px; }
.legal-nav { display:grid; gap:7px; }.legal-nav a { padding:10px 12px; border:1px solid #e1e1ed; border-radius:11px; background:#fff; color:#5e6074; font-size:10px; font-weight:820; line-height:1.35; }.legal-nav a:hover { border-color:#8b7cdf; color:#4938a6; }
.legal-document { min-width:0; }
.legal-document section { margin-bottom:16px; padding:clamp(22px,4vw,36px); border:1px solid #e0e1ed; border-radius:24px; background:#fff; box-shadow:0 10px 34px rgba(46,41,93,.045); }
.legal-document h2 { margin:0 0 14px; font-size:clamp(23px,3vw,34px); line-height:1.08; }.legal-document h3 { margin:22px 0 10px; font-size:18px; }
.legal-document p,.legal-document li { color:#626579; font-size:12px; line-height:1.72; }.legal-document p:last-child { margin-bottom:0; }.legal-document li + li { margin-top:7px; }
.legal-document a { color:#5040b3; font-weight:760; text-decoration:underline; text-decoration-thickness:1px; text-underline-offset:2px; }
.legal-document ul,.legal-document ol { margin:14px 0 0; padding-left:21px; }
.status-pill { width:max-content; margin-bottom:18px; padding:8px 11px; display:block; border-radius:999px; background:#ece8ff; color:#4a39a5; font-size:9px; font-weight:900; letter-spacing:.08em; text-transform:uppercase; }
.legal-alert { margin:0 0 16px; padding:16px 18px; border:1px solid #e7cb86; border-radius:16px; background:#fff8e7; color:#70551b; font-size:11px; line-height:1.6; }.legal-alert b { display:block; margin-bottom:3px; color:#5e4513; }
.legal-details { margin:14px 0 0; display:grid; border:1px solid #e3e3ee; border-radius:16px; overflow:hidden; }
.legal-details > div { padding:13px 15px; display:grid; grid-template-columns:minmax(180px,.75fr) minmax(0,1.25fr); gap:18px; background:#fafaff; }.legal-details > div + div { border-top:1px solid #e3e3ee; }
.legal-details dt { color:#858799; font-size:9px; font-weight:850; text-transform:uppercase; }.legal-details dd { margin:0; color:#3f4255; font-size:11px; font-weight:720; line-height:1.55; overflow-wrap:anywhere; }
.table-scroll { width:100%; margin:14px 0 0; overflow:auto; border:1px solid #e1e2ec; border-radius:16px; }
.legal-document table { width:100%; min-width:620px; border-collapse:collapse; background:#fff; }.legal-document th,.legal-document td { padding:13px 14px; border-bottom:1px solid #e7e7ef; color:#575a6d; font-size:10px; line-height:1.5; text-align:left; vertical-align:top; }.legal-document th { background:#f0effa; color:#37394d; font-weight:900; }.legal-document tr:last-child td { border-bottom:0; }

@media (max-width:1050px) {
  .main-nav { display:none; }
  html { scroll-padding-top:142px; }
  .mobile-nav { min-height:48px; padding:0 clamp(14px,4vw,42px) 8px; display:flex; align-items:center; justify-content:center; gap:8px; overflow-x:auto; scrollbar-width:none; }
  .mobile-nav::-webkit-scrollbar { display:none; }
  .mobile-nav a { min-width:96px; min-height:40px; padding:0 14px; display:grid; place-items:center; flex:none; border:1px solid #dedfeb; border-radius:12px; background:#fff; color:#66697d; font-size:10px; font-weight:850; }
  .mobile-nav a.active { border-color:#d8d0ff; background:#ebe8ff; color:#4938a5; }
  .hero-dashboard { grid-template-columns:1fr minmax(230px,.55fr); }
  .dashboard-grid { grid-template-columns:1fr 1fr; }.dashboard-grid article:first-child { grid-column:1/-1; }
  .launch-steps { grid-template-columns:1fr 1fr; }
  .onboarding { grid-template-columns:1fr; }.setup-card { max-width:650px; }
  .app-legal-footer { grid-template-columns:1fr auto; }.app-legal-footer nav,.app-legal-footer .legal-nav { grid-column:1/-1; grid-row:2; justify-content:flex-start; }
  .legal-grid { grid-template-columns:1fr; }.legal-grid > aside { position:static; }.legal-grid > aside .legal-nav { grid-template-columns:repeat(3,1fr); }
}
@media (max-width:760px) {
  body.has-toolkit { padding-right:0; padding-bottom:84px; }
  .header-inner { min-height:72px; padding:10px 14px; }.brand img { width:43px; height:43px; border-radius:14px; }.brand b { font-size:18px; }.brand small { display:none; }
  .mobile-nav { padding:0 10px 7px; justify-content:stretch; }.mobile-nav a { min-width:0; min-height:39px; padding:0 8px; flex:1; }
  .account-menu { gap:2px; }.account-menu > span { padding:7px 9px; font-size:9px; }.account-menu button { padding:7px; font-size:9px; }
  .app-shell { min-height:calc(100vh - 73px); padding:22px 13px 105px; }
  .auth-grid { min-height:auto; grid-template-columns:1fr; gap:20px; }.auth-story { padding:12px 5px 0; }.auth-story h1 { font-size:45px; }.auth-story > p,.auth-story ul { display:none; }.auth-card { padding:24px 19px; border-radius:24px; }
  .role-switcher { margin-bottom:12px; }.role-switcher label span { display:none; }
  .trial-banner { padding:13px 14px; flex-wrap:wrap; }.trial-banner div b { font-size:14px; }.trial-banner > small { display:none; }
  .hero-dashboard { min-height:0; padding:30px 21px; grid-template-columns:1fr; gap:22px; border-radius:27px; }.hero-dashboard h1 { font-size:48px; }.hero-dashboard > aside { padding:20px; }.hero-dashboard > aside strong { font-size:58px; }
  .dashboard-grid,.two-column,.launch-steps { grid-template-columns:1fr; }.dashboard-grid article:first-child { grid-column:auto; }.panel { padding:21px; border-radius:20px; }.two-column { gap:12px; }
  .onboarding { gap:25px; }.onboarding-copy h1 { font-size:48px; }.onboarding-copy ol { gap:7px; }.setup-card { padding:22px 17px; border-radius:24px; }.segmented { grid-template-columns:1fr; }.segmented.compact { grid-template-columns:repeat(5,1fr); }.segmented span { min-height:44px; font-size:9px; }
  .lesson-head { grid-template-columns:1fr; gap:15px; }.lesson-head h1 { font-size:48px; }.lesson-head aside { grid-template-columns:1fr auto; align-items:center; }.lesson-head aside span { grid-column:1/-1; }
  .task-card { padding:23px 18px; border-radius:23px; }.answer-form { align-items:stretch; flex-direction:column; }
  .content-watermark { grid-template-columns:1fr; gap:18px; opacity:.055; }.content-watermark span:nth-child(even) { display:none; }
  .protection-toast { bottom:96px; }
  .install-card { right:9px; bottom:92px; left:9px; width:auto; grid-template-columns:39px 1fr auto 27px; border-radius:17px; }.install-card img { width:39px; height:39px; }.install-card span { display:none; }
  .chem-dock { top:auto; right:0; bottom:0; left:0; width:100%; height:84px; padding:8px max(8px,env(safe-area-inset-right)) calc(8px + env(safe-area-inset-bottom)) max(8px,env(safe-area-inset-left)); flex-direction:row; border-top:1px solid #dcddea; border-left:0; box-shadow:0 -10px 30px rgba(40,36,84,.08); }.chem-dock > strong { width:46px; margin:0; align-self:center; }.chem-dock button { min-height:60px; flex:1; grid-template-columns:27px auto; align-content:center; gap:4px; border-radius:15px; }.chem-dock button i { width:27px; height:27px; }.chem-dock button span { font-size:7px; }.chem-dock button:hover { transform:none; }
  .tool-modal { padding:0; }.tool-dialog { width:100%; height:100%; border:0; border-radius:0; }.tool-dialog > header { min-height:76px; padding:calc(10px + env(safe-area-inset-top)) 13px 10px 17px; }.tool-dialog > header h2 { font-size:21px; }.tool-dialog > header button { width:42px; height:42px; }.tool-tabs { padding:7px 9px; }.tool-tabs button { min-height:42px; padding:0 12px; }.tool-content { padding:11px 9px calc(15px + env(safe-area-inset-bottom)); }
  .reference-toolbar { grid-template-columns:1fr; gap:8px; }.reference-toolbar p { font-size:8px; }.element-detail { grid-template-columns:31px 47px 1fr; }.element-detail > span { width:45px; height:45px; }.element-detail dl { grid-column:1/-1; }.periodic-scroll,.solubility-scroll { border-radius:14px; }
  .solubility-detail { grid-template-columns:1fr 43px; }.solubility-detail p { grid-column:1/-1; }.calculator-view { grid-template-columns:1fr; align-items:start; gap:14px; }.calculator { max-width:430px; width:100%; justify-self:center; padding:13px; border-radius:22px; }.calc-screen { min-height:82px; }.calc-screen output { font-size:34px; }.calc-keys button { min-height:47px; }.calculator-view aside { padding:17px; }
  .app-legal-footer { padding:24px 14px 104px; grid-template-columns:1fr; gap:15px; }.app-legal-footer nav,.app-legal-footer .legal-nav { grid-column:auto; grid-row:auto; display:grid; grid-template-columns:1fr 1fr; justify-content:stretch; }
  .legal-header > div { min-height:72px; padding:10px 14px; }.legal-home { min-height:38px; padding:0 11px; }.legal-shell { padding:38px 13px 60px; }.legal-hero { margin-bottom:28px; }.legal-hero h1 { font-size:44px; }.legal-grid { gap:18px; }.legal-grid > aside .legal-nav { grid-template-columns:1fr 1fr; }.legal-nav a { padding:9px; }.legal-document section { padding:21px 17px; border-radius:19px; }.legal-details > div { grid-template-columns:1fr; gap:5px; }.legal-document table { min-width:560px; }
}
@media (max-width:390px) {
  .auth-story h1,.hero-dashboard h1,.onboarding-copy h1,.lesson-head h1 { font-size:40px; }
  .brand span { display:none; }.role-switcher { margin-left:0; }.segmented.compact span { padding:3px; }
  .chem-dock > strong { display:none; }.chem-dock button span { font-size:6px; }
  .install-card { grid-template-columns:36px 1fr auto 24px; }.install-card > button:not(.icon-close) { padding:0 9px; }
}
@media (prefers-reduced-motion:reduce) { * { scroll-behavior:auto!important; transition:none!important; animation:none!important; } }
@media (forced-colors:active) { .primary,.hero-dashboard,.chem-dock button,.tool-dialog,.element,.mark { border:1px solid CanvasText; box-shadow:none; } }
@media print {
  .protected-content { min-height:220px!important; border:2px solid #666!important; box-shadow:none!important; }
  .protected-content .task-content,.protected-content .content-watermark { display:none!important; }
  .protected-content::after { content:"Учебные задания ХимЯсно доступны только в защищённом личном кабинете."; position:absolute; inset:0; display:grid; place-items:center; padding:30px; color:#222; font:700 18px/1.5 system-ui,sans-serif; text-align:center; }
  .chem-dock,.install-card,.protection-toast { display:none!important; }
  .legal-header,.legal-grid > aside,.app-legal-footer { display:none!important; }.legal-shell { width:100%; padding:0; }.legal-grid { display:block; }.legal-document section { break-inside:avoid; border:0; box-shadow:none; }
}
