:root {
  color-scheme:light;
  --bg:#f7f8fa; --panel:#fff; --text:#192032; --muted:#606a7c;
  --line:#dfe3ec; --soft:#edf0ff; --primary:#3d50df; --accent:#ef6337;
  --lavender:#ece8ff; --peach:#ffede3; --mint:#e6f2d7; --sky:#e6efff;
  --ok:#1b794c; --warn:#8b5b14; --bad:#ba3546;
  --shadow:0 20px 65px rgba(24,32,55,.07); --radius:24px;
}
:root[data-theme="dark"] {
  color-scheme:dark;
  --bg:#11141d; --panel:#1c2130; --text:#f0f2fa; --muted:#b0b8cd;
  --line:#363e53; --soft:#292f4c; --primary:#a8b1ff; --accent:#ffac87;
  --lavender:#302b4b; --peach:#3c2a26; --mint:#27382c; --sky:#25334b;
  --ok:#86dbad; --warn:#f5ca7e; --bad:#ffa3b1;
  --shadow:0 20px 65px rgba(0,0,0,.16);
}
* { box-sizing:border-box; }
html { scroll-behavior:smooth; scroll-padding-top:100px; }
body { margin:0; font-family:"Avenir Next", "Segoe UI", Arial, sans-serif; color:var(--text); background:var(--bg); line-height:1.55; }
button,input,select,textarea { font:inherit; }
button,a,input,select,textarea,summary { -webkit-tap-highlight-color:transparent; }
a { color:var(--primary); text-decoration:none; }
button { cursor:pointer; }
button:disabled { cursor:not-allowed; opacity:.55; }
a:focus-visible,button:focus-visible,summary:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible { outline:3px solid var(--accent); outline-offset:4px; }
h1,h2,h3,p { margin:0; }
h1,h2,h3 { line-height:1.12; letter-spacing:-.035em; }
p + p { margin-top:12px; }
img,svg,video { max-width:100%; }
section { min-width:0; }
[hidden],.hidden { display:none !important; }
.muted,.hint { color:var(--muted); }
.wrap { width:min(1240px,100% - 64px); margin-inline:auto; }
.logo { display:inline-flex; align-items:center; gap:9px; color:var(--text); font-size:24px; font-weight:850; letter-spacing:-1px; white-space:nowrap; }
.logo-mark { display:grid; place-items:center; width:34px; height:34px; border-radius:11px; color:#fff; background:#3d50df; font-size:21px; letter-spacing:-3px; padding-right:3px; }
.logo span:not(.logo-mark) { color:var(--primary); }
.eyebrow { display:flex; align-items:center; gap:9px; text-transform:uppercase; letter-spacing:.13em; font-size:11px; font-weight:800; color:var(--muted); margin-bottom:18px; }
.eyebrow::before { content:""; width:7px; height:7px; border-radius:50%; background:var(--accent); }
.btn { display:inline-flex; justify-content:center; align-items:center; gap:10px; min-height:46px; padding:12px 20px; border:1px solid transparent; border-radius:13px; font-weight:700; line-height:1.35; text-decoration:none; transition:transform .15s,background .15s; }
.btn:hover:not(:disabled) { transform:translateY(-2px); }
.btn.primary,.btn-primary { background:#3d50df; color:#fff; }
.btn.accent,.btn-accent { background:#be4520; color:#fff; }
.btn.ghost,.btn-ghost { background:var(--panel); color:var(--text); border-color:var(--line); }
.btn-sm { min-height:40px; padding:9px 15px; font-size:13px; }
.theme-toggle { display:inline-flex; align-items:center; justify-content:center; gap:9px; flex-shrink:0; min-height:40px; min-width:40px; padding:8px 11px; border:1px solid var(--line); background:var(--panel); color:var(--text); border-radius:12px; font-size:13px; }
.theme-symbol { font-size:19px; line-height:1; }
.row { display:flex; flex-wrap:wrap; align-items:center; gap:10px; }
.stack { display:grid; gap:16px; }
.chip,.pill { display:inline-flex; align-items:center; gap:6px; padding:5px 11px; border-radius:8px; background:var(--soft); color:var(--primary); font-size:12px; font-weight:700; }
.skip-link { position:fixed; top:-100px; left:16px; z-index:100; background:var(--panel); padding:12px; border:2px solid var(--primary); }
.skip-link:focus { top:12px; }
.site-header { position:sticky; top:0; z-index:20; background:var(--bg); border-bottom:1px solid var(--line); }
.public-nav { display:flex; align-items:center; gap:24px; min-height:82px; }
.nav-links { display:flex; gap:27px; margin-left:auto; font-size:13px; font-weight:650; }
.nav-links a { color:var(--text); }
.header-actions { display:flex; align-items:center; gap:10px; }
.public-menu { display:none; position:relative; }
.public-menu summary { cursor:pointer; list-style:none; padding:10px; font-size:14px; }
.public-menu nav { position:absolute; right:0; top:45px; width:220px; display:grid; gap:16px; padding:22px; border:1px solid var(--line); border-radius:16px; background:var(--panel); box-shadow:var(--shadow); }
.landing section { padding-block:68px; }
.landing .hero { display:grid; grid-template-columns:1.05fr 1fr; gap:48px; align-items:center; padding-top:62px; padding-bottom:46px; }
.hero h1 { font-size:clamp(44px,5.3vw,72px); letter-spacing:-.065em; line-height:1.02; margin-bottom:24px; }
.hero h1 em { font-style:normal; color:var(--primary); }
.lead { max-width:540px; font-size:17px; line-height:1.7; color:var(--muted); }
.hero-cta { display:flex; flex-wrap:wrap; gap:12px; margin-top:28px; }
.hero-note { max-width:440px; margin-top:18px; font-size:12px; color:var(--muted); }
.hero-tags { display:flex; flex-wrap:wrap; gap:8px; margin-bottom:23px; }
.hero-tags .pill { border:1px solid var(--line); background:var(--panel); color:var(--text); font-size:11px; }
.hero-visual { position:relative; padding:29px 16px 25px; }
.video-demo { border-radius:23px; overflow:hidden; background:#1d2335; color:#f5f6ff; box-shadow:0 24px 60px rgba(20,28,60,.19); transform:rotate(-2deg); }
.demo-toolbar { padding:17px 22px; display:flex; gap:9px; align-items:center; border-bottom:1px solid #39415a; font-size:10px; letter-spacing:.04em; }
.demo-dots { display:flex; gap:4px; margin-right:auto; }
.demo-dots i { width:6px; height:6px; background:#76819a; border-radius:50%; }
.demo-toolbar .pill { background:#363251; color:#d9ceff; padding:4px 8px; font-size:10px; }
.demo-board { padding:30px 30px 24px; background-image:radial-gradient(#53607955 .8px,transparent .8px); background-size:20px 20px; }
.board-label { color:#a8b5d1; font-size:10px; letter-spacing:.09em; text-transform:uppercase; }
.demo-board h3 { font-size:20px; margin:12px 0 27px; letter-spacing:-.025em; }
.board-equation { font-family:Georgia,serif; font-size:29px; color:#f1efdf; }
.board-step { display:flex; gap:12px; align-items:center; margin-top:18px; font-size:15px; }
.board-step span { display:grid; place-items:center; border:1px solid #69738e; border-radius:50%; width:23px; height:23px; font-size:10px; color:#bfc7dd; }
.board-step b { font-family:Georgia,serif; font-weight:400; color:#c8bcff; font-size:22px; }
.board-answer { display:inline-block; margin-top:24px; color:#dbefaa; border-bottom:2px solid #dbefaa; padding-bottom:6px; font-size:16px; }
.demo-controls { display:flex; align-items:center; gap:12px; padding:16px 22px; background:#171c2c; font-size:10px; color:#c0c9e0; }
.demo-controls i { height:3px; flex:1; background:#4b506a; border-radius:8px; position:relative; }
.demo-controls i::before { content:""; display:block; width:35%; height:100%; background:#b4a1ff; }
.demo-tag { position:absolute; right:0; top:8px; padding:10px 16px; background:#dcedae; color:#34422b; border-radius:12px; font-size:12px; font-weight:750; transform:rotate(5deg); }
.demo-caption { margin-top:20px; display:flex; justify-content:center; gap:8px; font-size:11px; color:var(--muted); }
.feature-strip { display:flex; justify-content:space-between; flex-wrap:wrap; gap:20px; border-block:1px solid var(--line); padding:22px 0; font-size:12px; font-weight:650; color:var(--muted); }
.feature-strip b { color:var(--text); }
.section-head { display:flex; justify-content:space-between; align-items:end; gap:28px; margin-bottom:32px; }
.section-head h2 { font-size:clamp(30px,3.5vw,46px); max-width:650px; }
.section-head p { max-width:330px; font-size:14px; color:var(--muted); }
.bento { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:18px; }
.feature-card { position:relative; padding:30px; border-radius:var(--radius); background:var(--panel); border:1px solid var(--line); min-width:0; display:flex; flex-direction:column; align-items:start; }
.feature-card h3 { font-size:24px; margin:20px 0 12px; }
.feature-card p { font-size:14px; color:var(--muted); margin-bottom:24px; }
.feature-card a { font-size:13px; font-weight:750; margin-top:auto; }
.feature-card.wide { grid-column:span 2; }
.lavender { background:var(--lavender); }
.peach { background:var(--peach); }
.mint { background:var(--mint); }
.sky { background:var(--sky); }
.feature-number { display:grid; place-items:center; width:40px; height:40px; border:1px solid currentColor; border-radius:13px; font-size:15px; color:var(--primary); }
.video-feature { display:grid; grid-template-columns:1fr 1fr; gap:30px; }
.video-feature .mini-board { align-self:center; border:1px solid var(--primary); border-radius:17px; padding:23px; transform:rotate(3deg); }
.mini-board .formula { font-family:Georgia,serif; font-size:28px; margin:15px 0; }
.mini-board small { display:block; color:var(--muted); }
.video-types { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:18px; margin-top:18px; }
.video-type { border-top:2px solid var(--line); padding:22px 0; }
.video-type h3 { font-size:18px; margin-bottom:10px; }
.video-type p { font-size:13px; color:var(--muted); }
.section-note { font-size:12px; color:var(--muted); margin-top:18px; }
.steps { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; }
.step { padding:30px; border:1px solid var(--line); border-radius:var(--radius); background:var(--panel); }
.step .step-no { font-size:46px; line-height:1; font-weight:800; color:var(--primary); opacity:.55; }
.step h3 { font-size:21px; margin:20px 0 12px; }
.step p { font-size:14px; color:var(--muted); }
.faq { display:grid; grid-template-columns:.75fr 1.25fr; gap:60px; }
.faq h2 { font-size:42px; }
details { min-width:0; }
.faq details { padding:21px 0; border-bottom:1px solid var(--line); }
.faq summary { cursor:pointer; font-size:16px; font-weight:700; }
.faq details p { font-size:14px; color:var(--muted); margin-top:14px; }
.cta-final { display:flex; justify-content:space-between; align-items:center; gap:28px; background:var(--lavender); border-radius:30px; padding:48px; }
.cta-final h2 { font-size:38px; margin-bottom:13px; }
.cta-final p { color:var(--muted); font-size:14px; max-width:580px; }
.site-footer { border-top:1px solid var(--line); padding:30px 0; font-size:12px; color:var(--muted); }
.site-footer .wrap { display:flex; justify-content:space-between; flex-wrap:wrap; gap:20px; }
/* Sign-in shares the product presentation, with the real VK ID action. */
.login-header { display:flex; justify-content:space-between; align-items:center; padding-block:28px; }
.login-layout { min-height:calc(100svh - 110px); display:grid; grid-template-columns:1.1fr 1fr; align-items:center; gap:90px; padding-block:35px 80px; }
.login-story h1 { font-size:clamp(40px,4.5vw,64px); letter-spacing:-.055em; margin-bottom:25px; }
.login-story .lead { max-width:450px; }
.login-points { display:grid; gap:18px; margin-top:36px; }
.login-points p { display:flex; align-items:center; gap:14px; font-size:14px; margin:0; }
.login-points span { width:37px; height:37px; display:grid; place-items:center; border-radius:11px; background:var(--lavender); color:var(--primary); }
.login-card { background:var(--panel); border:1px solid var(--line); border-radius:30px; padding:44px; box-shadow:var(--shadow); }
.login-card h2 { font-size:30px; margin-bottom:15px; }
.login-card > p { font-size:14px; color:var(--muted); margin-bottom:28px; }
.vk-login { display:flex; align-items:center; justify-content:center; gap:12px; min-height:52px; padding:14px; border-radius:13px; background:#0077ff; color:#fff; font-weight:700; }
.vk-mark { font-weight:900; }
.login-card .hint { margin-top:25px; font-size:12px; }
.dev-login { margin-top:25px; padding-top:20px; border-top:1px dashed var(--line); }
.dev-login p { font-size:12px; margin-bottom:10px; }
.dev-login input { max-width:60%; }
.dev-login button { padding:10px; border:0; border-radius:8px; background:#3d50df; color:#fff; }
.err { color:var(--bad); margin-bottom:18px; font-size:14px; }
/* Student cabinet; existing learning modules retain their controls and IDs. */
.cabinet-header { position:fixed; inset:0 0 auto 0; z-index:30; height:76px; background:var(--panel); border-bottom:1px solid var(--line); }
.cabinet-header .nav { height:100%; display:flex; align-items:center; gap:24px; padding:0 28px; }
.cabinet-header .logo { width:204px; }
.workspace-label { font-size:12px; color:var(--muted); }
.user { display:flex; align-items:center; gap:14px; margin-left:auto; font-size:13px; min-width:0; }
#user-name { max-width:140px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.logout { padding:8px; border:0; background:transparent; color:var(--muted); font-size:12px; }
.sidebar { position:fixed; left:0; top:76px; bottom:0; z-index:25; width:250px; padding:24px 18px; border-right:1px solid var(--line); background:var(--panel); overflow-y:auto; }
.sidebar-label { font-size:10px; text-transform:uppercase; letter-spacing:.12em; color:var(--muted); padding:4px 14px 12px; }
.tabs { display:grid; gap:5px; }
.tab { display:flex; align-items:center; gap:12px; width:100%; text-align:left; min-height:43px; border:0; border-radius:12px; padding:10px 13px; background:transparent; color:var(--muted); font-size:13px; }
.tab .nav-icon { display:inline-grid; place-items:center; width:23px; font-size:17px; }
.tab.active { color:var(--primary); background:var(--soft); font-weight:750; }
.tab[data-tab="videos"] { color:var(--primary); }
.nav-badge { margin-left:auto; font-size:9px; letter-spacing:.04em; padding:3px 5px; border-radius:5px; background:var(--lavender); color:var(--primary); }
.sidebar-note { margin-top:24px; padding:18px; border-radius:16px; background:var(--lavender); font-size:12px; }
.sidebar-note p { color:var(--muted); margin:9px 0 14px; }
.sidebar-note .btn { font-size:12px; width:100%; }
.cabinet-main { margin-left:250px; padding:110px 32px 60px; max-width:1600px; }
.mobile-menu-toggle { display:none; }
.page-title { display:flex; justify-content:space-between; align-items:end; gap:20px; margin-bottom:28px; }
.page-title h1 { font-size:36px; }
.page-title p { color:var(--muted); font-size:13px; margin-top:12px; }
.grid { display:grid; grid-template-columns:260px minmax(0,1fr); gap:22px; align-items:start; }
.panel { background:var(--panel); border:1px solid var(--line); border-radius:20px; padding:24px; min-width:0; }
.panel h1 { font-size:26px; margin-bottom:15px; }
.panel h2 { font-size:21px; margin-bottom:15px; }
.panel h3 { font-size:17px; margin-bottom:10px; }
.panel p { font-size:14px; }
.panel .stack > h2,.panel.stack > h2,.panel.stack > h3 { margin-bottom:0; }
#telegram-account { grid-template-columns:minmax(0,1fr); overflow-wrap:anywhere; }
#telegram-account > * { min-width:0; max-width:100%; }
#telegram-connect a { display:block; margin-bottom:8px; }
.overview-settings { min-width:0; }
.overview-hero { display:grid; grid-template-columns:1.1fr .9fr; gap:28px; border-radius:24px; padding:32px; background:var(--lavender); margin-bottom:22px; }
.overview-hero h2 { font-size:30px; margin:12px 0 14px; }
.overview-hero p { font-size:14px; color:var(--muted); max-width:490px; margin-bottom:22px; }
.overview-video-art { display:flex; flex-direction:column; justify-content:center; gap:14px; background:#23293d; color:#e6e3ff; border-radius:18px; padding:26px; transform:rotate(2deg); font-family:Georgia,serif; font-size:25px; }
.overview-video-art small { font:10px "Segoe UI",sans-serif; letter-spacing:.09em; color:#bac1db; }
.overview-video-art span:last-child { color:#dcedae; font-size:19px; }
.quick-actions { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin-bottom:25px; }
.quick-action { text-align:left; padding:19px; border:1px solid var(--line); border-radius:17px; color:var(--text); background:var(--panel); }
.quick-action b { display:block; font-size:14px; margin:12px 0 6px; }
.quick-action small { display:block; color:var(--muted); font-size:11px; }
.quick-action .action-symbol { color:var(--primary); font-size:22px; }
.overview-columns { display:grid; grid-template-columns:minmax(0,1fr) 280px; gap:22px; align-items:start; }
.stats { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; }
.stat { padding:14px; border-radius:14px; background:var(--soft); min-width:0; }
.stat b { display:block; font-size:28px; color:var(--primary); }
.stat span { display:block; font-size:11px; color:var(--muted); }
.topic-row { display:grid; grid-template-columns:minmax(130px,1fr) 120px 90px; gap:12px; align-items:center; padding:12px 0; border-bottom:1px solid var(--line); font-size:13px; }
#quotas .topic-row { grid-template-columns:minmax(0,1fr) auto; font-size:12px; }
#quotas .topic-row > span:nth-child(2) { display:none; }
.bar { height:7px; background:var(--soft); border-radius:10px; overflow:hidden; }
.bar i { display:block; height:100%; border-radius:10px; }
label { display:grid; gap:7px; color:var(--muted); font-size:13px; }
select,input[type=text],input[type=email],input[type=number],input[type=time],textarea { width:100%; min-width:0; color:var(--text); background:var(--panel); border:1px solid var(--line); border-radius:11px; padding:11px 12px; }
textarea { min-height:145px; resize:vertical; }
input[type=file] { max-width:100%; font-size:12px; }
.task-text,.theory-text { white-space:pre-wrap; overflow-wrap:anywhere; background:var(--soft); padding:18px; border-radius:14px; }
.task-img { display:block; max-width:100%; border:1px solid var(--line); border-radius:12px; margin:8px 0; background:#fff; }
.task-files { display:grid; gap:10px; padding:15px; background:var(--soft); border-radius:12px; }
.task-files a { padding:9px 12px; border:1px solid var(--line); border-radius:8px; background:var(--panel); }
.verdict { margin-top:15px; padding:20px; border:1px solid var(--line); border-radius:15px; }
.verdict.ok { background:var(--mint); border-color:var(--ok); }
.verdict.mid { background:var(--peach); border-color:var(--warn); }
.verdict.bad { background:var(--peach); border-color:var(--bad); }
.quote { border-left:3px solid var(--accent); padding-left:13px; margin:12px 0; color:var(--muted); }
.banner { padding:17px; border:1px solid var(--warn); background:var(--peach); border-radius:15px; margin-bottom:22px; font-size:14px; }
.empty { padding:30px; text-align:center; border:1px dashed var(--line); border-radius:16px; color:var(--muted); font-size:14px; }
.empty .btn { margin-top:17px; }
.subject-options { display:grid; gap:9px; }
.subject-option { display:flex; align-items:center; gap:9px; color:var(--text); }
.subject-option:has(input:disabled) { opacity:.55; }
#checkout-subjects { min-width:0; border:1px solid var(--line); border-radius:12px; padding:16px; }
.period-row { padding:14px 0; border-bottom:1px solid var(--line); }
.video-player { width:100%; max-height:520px; border-radius:16px; background:#0d1018; }
.video-condition { display:grid; gap:12px; margin-bottom:20px; min-width:0; }
.video-condition h4 { margin:0; }
.task-text,.theory-text { min-width:0; overflow-x:auto; }
.katex { white-space:normal; overflow-wrap:normal; }
.katex-display { max-width:100%; overflow-x:auto; overflow-y:hidden; padding:4px 0; }
.video-list { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:18px; }
.video-card { overflow:hidden; border:1px solid var(--line); border-radius:19px; background:var(--panel); }
.video-thumbnail { display:flex; flex-direction:column; align-items:start; justify-content:space-between; min-height:150px; padding:20px; background:var(--lavender); }
.video-thumbnail.personal { background:var(--peach); }
.video-thumbnail.own { background:var(--mint); }
.video-thumbnail b { font-size:26px; letter-spacing:-.04em; }
.video-card-body { display:grid; gap:12px; padding:20px; }
.video-failure { overflow-wrap:anywhere; }
.video-card-body h3 { font-size:16px; }
.video-card-body p { font-size:12px; color:var(--muted); }
.video-status { font-size:11px; color:var(--muted); }
.video-status.ready { color:var(--ok); }
.video-intro { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:15px; margin-bottom:25px; }
.video-intro article { border-radius:17px; padding:22px; background:var(--soft); }
.video-intro h2 { font-size:17px; margin-bottom:10px; }
.video-intro p { font-size:12px; color:var(--muted); }
.video-hint { font-size:12px; color:var(--muted); padding:12px 15px; background:var(--soft); border-radius:11px; }
.spinner { display:inline-block; width:16px; height:16px; border:2px solid var(--line); border-top-color:var(--primary); border-radius:50%; animation:spin .8s linear infinite; vertical-align:-3px; margin-right:6px; }
dialog { width:min(560px,calc(100% - 32px)); color:var(--text); background:var(--panel); border:1px solid var(--line); border-radius:22px; padding:28px; }
dialog::backdrop { background:#10152499; }
audio { width:100%; }
@keyframes spin { to { transform:rotate(360deg); } }
@media (min-width:1650px) { .cabinet-main { margin-right:auto; } }
@media (max-width:1150px) {
  .public-nav { gap:16px; }
  .nav-links { gap:17px; }
  .hero h1 { font-size:54px; }
  .landing .hero { gap:24px; }
  .sidebar { width:218px; padding-inline:12px; }
  .cabinet-header .logo { width:178px; }
  .cabinet-main { margin-left:218px; padding-inline:22px; }
  .overview-columns { grid-template-columns:1fr; }
  .overview-settings { display:grid; grid-template-columns:1fr 1fr; gap:20px; }
  .quick-actions { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .grid { grid-template-columns:220px minmax(0,1fr); }
  .video-list { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:850px) {
  .wrap { width:calc(100% - 36px); }
  .public-nav { min-height:70px; }
  .public-nav > .nav-links { display:none; }
  .header-actions { margin-left:auto; }
  .public-menu { display:block; }
  .hero h1 { font-size:54px; }
  .landing .hero { grid-template-columns:1fr; gap:28px; }
  .hero-visual { max-width:560px; width:100%; margin:auto; }
  .hero .lead { max-width:620px; }
  .landing section { padding-block:45px; }
  .section-head { display:block; }
  .section-head p { margin-top:18px; max-width:500px; }
  .bento { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .feature-card.wide { grid-column:span 2; }
  .steps { gap:12px; }
  .step { padding:23px; }
  .faq { gap:35px; }
  .cta-final { padding:32px; }
  .login-layout { gap:35px; }
  .login-card { padding:28px; }
  .cabinet-header { height:66px; }
  .cabinet-header .nav { padding-inline:16px; gap:12px; }
  .cabinet-header .logo { width:auto; font-size:21px; }
  .workspace-label,#user-name,.user form { display:none; }
  .user { gap:8px; }
  .user .chip { max-width:110px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
  .mobile-menu-toggle { display:inline-flex; }
  .sidebar { top:66px; width:260px; box-shadow:var(--shadow); transform:translateX(-105%); visibility:hidden; }
  .sidebar.is-open { transform:translateX(0); visibility:visible; }
  .cabinet-main { margin-left:0; padding:92px 18px 40px; }
  .grid { grid-template-columns:1fr; }
  .sidebar-logout { display:block; margin-top:14px; }
}
@media (min-width:851px) { .sidebar-logout { display:none; } }
@media (max-width:580px) {
  .logo { font-size:21px; }
  .public-nav { gap:8px; }
  .public-nav .btn-sm { padding:10px 12px; font-size:11px; }
  .theme-toggle { min-width:38px; min-height:38px; padding:8px; }
  .header-actions { gap:6px; }
  .hero h1 { font-size:45px; }
  .hero .lead { font-size:15px; }
  .hero-cta .btn { width:100%; }
  .hero-visual { padding-inline:9px; }
  .demo-board { padding:24px 22px; }
  .demo-board h3 { font-size:18px; }
  .board-equation { font-size:26px; }
  .feature-strip { display:grid; grid-template-columns:1fr 1fr; gap:16px; font-size:11px; }
  .bento,.steps,.video-types,.faq,.video-intro { grid-template-columns:1fr; }
  .feature-card.wide { grid-column:auto; }
  .video-feature { grid-template-columns:1fr; }
  .feature-card { padding:25px; }
  .video-feature .mini-board { display:none; }
  .video-type { padding-block:18px; }
  .section-head h2,.faq h2 { font-size:32px; }
  .cta-final { display:block; padding:28px; }
  .cta-final h2 { font-size:30px; }
  .cta-final .btn { margin-top:24px; width:100%; }
  .login-layout { grid-template-columns:1fr; padding-top:18px; gap:30px; }
  .login-story h1 { font-size:38px; }
  .login-points { display:none; }
  .login-story .lead { font-size:14px; }
  .login-card { padding:28px 24px; }
  .login-card h2 { font-size:26px; }
  .page-title h1 { font-size:29px; }
  .overview-hero { grid-template-columns:1fr; padding:25px; }
  .overview-hero h2 { font-size:26px; }
  .overview-video-art { display:none; }
  .quick-actions { gap:10px; }
  .quick-action { padding:15px; }
  .quick-action b { font-size:13px; }
  .overview-settings { display:block; }
  .overview-settings > * + * { margin-top:20px; }
  .panel { padding:20px; }
  .stats { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .topic-row { grid-template-columns:1fr; }
  .video-list { grid-template-columns:1fr; }
  .video-intro { gap:10px; }
  .video-intro article { padding:18px; }
  .user .chip { max-width:85px; font-size:10px; padding:6px 8px; }
  .cabinet-header .nav { gap:8px; }
  .cabinet-header .logo-mark { display:none; }
}
@media (prefers-reduced-motion:reduce) {
  html { scroll-behavior:auto; }
  *,*::before,*::after { animation:none !important; transition:none !important; }
}
