:root{--ink:#29293d;--muted:#85838f;--purple:#7961ce;--line:#eeedf2;--paper:#fdfcfa}*{box-sizing:border-box}body{margin:0;background:var(--paper);color:var(--ink);font-family:ui-rounded,'Trebuchet MS',Arial,sans-serif;font-size:14px}button,a{-webkit-tap-highlight-color:transparent}button{font:inherit;cursor:pointer}button:focus-visible,a:focus-visible{outline:3px solid #a18be3;outline-offset:5px}button{color:inherit}button:disabled{cursor:default}.shell{display:flex;min-height:100vh}.sidebar{position:fixed;inset:0 auto 0 0;width:230px;background:#fff;border-right:1px solid var(--line);padding:36px 22px;display:flex;flex-direction:column}.brand{font-size:38px;font-weight:900;letter-spacing:-2px;color:var(--ink);text-decoration:none;display:flex;align-items:center;gap:9px}.brand-icon{color:var(--purple);font-size:42px}.brand-dot{color:var(--purple);margin-left:-9px}.tagline{font-size:9px;letter-spacing:2px;color:#94909e;margin:7px 0 48px 9px}nav{display:grid;gap:12px}.nav{border:0;background:transparent;text-align:left;padding:16px 13px;border-radius:12px;color:#7a7787;font-weight:700;display:flex;align-items:center;gap:13px}.nav span{font-size:23px;line-height:20px}.nav.active{background:#f0ebfc;color:#7b60c6}.nav:hover{background:#f6f3fc}.sidebar-bottom{margin-top:auto;padding:30px 8px 0}.local-dot{color:#75a786;font-size:12px}.local-dot span{color:#706c7c;margin-left:5px}.sidebar-bottom p{font-size:12px;line-height:1.8;color:#9994a2}.profile{border-top:1px solid var(--line);padding-top:22px;margin-top:24px;display:flex;align-items:center;gap:11px}.profile strong{font-size:12px}.profile small{display:block;font-size:10px;color:#97929f;margin-top:4px}.avatar{background:#f7e8ce;color:#92774b;width:39px;height:39px;display:grid;place-items:center;border-radius:14px;font-size:26px}.avatar.small{width:33px;height:33px;border-radius:50%;font-size:24px}.main-wrap{margin-left:230px;width:calc(100% - 230px)}.topbar{height:84px;border-bottom:1px solid var(--line);padding:0 45px;display:flex;align-items:center;justify-content:space-between;color:#8b8793;font-size:12px;background:#fff}.stats{display:flex;align-items:center;gap:26px;color:#9b7b45}.stats>span{display:flex;gap:6px;align-items:center}.stats>span:nth-child(2){color:var(--purple)}main{max-width:1210px;padding:38px 45px 15px;margin:auto}.heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:28px}.eyebrow{font-size:10px;letter-spacing:1.8px;color:#9b91ac;font-weight:700}h1{font-size:31px;letter-spacing:-1px;margin:12px 0 9px}p{line-height:1.65}.heading p{color:var(--muted);margin:0;font-size:13px}.date-pill{font-size:11px;border:1px solid #e8e4ee;border-radius:20px;padding:9px 13px;color:#89808f;white-space:nowrap}.hero{border:1px solid #e7ddf6;border-radius:21px;background:#f0e9fa;min-height:283px;padding:30px 35px;display:flex;justify-content:space-between;overflow:hidden;position:relative}.pill{font-size:9px;letter-spacing:1.3px;font-weight:700;color:#8670af}.hero h2{font-size:34px;line-height:1.15;letter-spacing:-1px;margin:16px 0 12px}.hero p{font-size:13px;color:#888095;margin:0 0 19px}.primary{background:var(--purple);border:0;border-bottom:4px solid #6249b4;border-radius:11px;color:white;padding:13px 24px;font-weight:700;display:inline-flex;align-items:center;justify-content:center;gap:28px}.primary:hover{background:#876edc}.primary:active{transform:translateY(2px);border-bottom-width:2px}.primary:disabled{background:#d0c9e2;border-color:#bbb3cb}.hero-art{width:330px;position:relative;align-self:stretch}.blob{position:absolute;width:149px;height:159px;border-radius:68% 60% 47% 49%;background:#b8a0e3;transform:rotate(10deg);left:93px;top:39px;box-shadow:inset -13px -9px 0 #ac90d9;animation:bob 5s ease-in-out infinite}.eyes{display:flex;gap:29px;position:absolute;left:45px;top:65px}.eyes i{width:9px;height:13px;background:#463352;border-radius:50%}.smile{position:absolute;left:65px;top:88px;width:20px;height:13px;border-bottom:3px solid #463352;border-radius:50%}.cheek{position:absolute;width:18px;height:8px;background:#dbacd6;border-radius:50%;top:86px}.c1{left:28px}.c2{right:25px}.book{position:absolute;left:63px;top:164px;width:179px;height:43px;border-radius:7px 7px 12px 12px;background:#ffda87;border-bottom:9px solid #e7bb64;color:#ae8548;text-align:center;font-size:28px;transform:rotate(-8deg)}.spark{position:absolute;color:#b695d9;font-size:40px}.s1{left:28px;top:76px}.s2{right:14px;top:142px;font-size:32px}.formula{position:absolute;right:9px;top:10px;color:#ab92c5;font-size:17px;transform:rotate(9deg)}.art-caption{position:absolute;bottom:0;left:91px;color:#95809f;font-size:11px;transform:rotate(-5deg)}.section-heading{display:flex;justify-content:space-between;align-items:center;margin:28px 0 16px}.section-heading h2{font-size:17px;margin:0;letter-spacing:-.3px}.section-heading>span{font-size:10px;color:#9b96a2}.subjects{display:grid;grid-template-columns:repeat(3,1fr);gap:17px}.subject{background:#fff;border:1px solid #e8e6ec;border-bottom:3px solid #e8e6ec;border-radius:15px;padding:19px;text-align:left;transition:transform .2s}.subject:hover{transform:translateY(-2px)}.subject.selected{border-color:#af96e3;background:#fbf9ff}.subject-top{display:flex;justify-content:space-between;align-items:center}.subject-icon{display:grid;place-items:center;width:39px;height:39px;border-radius:12px;font-size:25px;font-weight:700;background:#ece4fa;color:#8d71ca}.subject-check{color:#b4abbf;font-size:16px}.selected .subject-check{background:#8d71ca;color:#fff;border-radius:50%;width:19px;height:19px;display:grid;place-items:center;font-size:11px}.subject h3{font-size:17px;margin:15px 0 6px}.subject p{color:#8e8897;font-size:11px;margin:0 0 17px}.track{height:6px;border-radius:6px;background:#eeebf3;overflow:hidden}.track i{display:block;height:100%;background:#a18ad4;border-radius:6px;transition:width .3s}.subject small{color:#a19aa9;font-size:10px;display:block;margin-top:9px}.orange .subject-icon{background:#fff0df;color:#cb955d}.green .subject-icon{background:#e6f2e9;color:#6e9b80}.orange.selected{border-color:#deb98c;background:#fffcf8}.green.selected{border-color:#94b79f;background:#f9fdf9}.orange .track i{background:#deb98c}.green .track i{background:#94b79f}.lower{display:grid;grid-template-columns:minmax(0,1fr) 244px;gap:23px}.subtle{font-weight:400;color:#aaa0b5;margin-left:5px}.chapter-banner{background:#f2edf9;border-radius:12px;padding:17px;display:flex;align-items:center;gap:13px}.chapter-banner.orange{background:#fcf2e6}.chapter-banner.green{background:#edf5ed}.chapter-banner span:not(.subject-icon){font-size:9px;letter-spacing:1.4px;color:#9e8fb1}.chapter-banner h3{font-size:14px;margin:5px 0 0}.lesson-list{padding:0 4px}.lesson{width:100%;display:flex;align-items:center;gap:15px;padding:21px 0;background:none;border:0;border-bottom:1px solid var(--line);text-align:left}.step{flex-shrink:0;border:2px solid #ded5ed;color:#9580b5;background:#f7f3fc;border-radius:50%;width:43px;height:43px;display:grid;place-items:center;font-weight:700;box-shadow:0 3px 0 #e7e0f0}.step.done{color:#568165;background:#e8f5eb;border-color:#b3d3bb;box-shadow:0 3px 0 #d0e5d5}.lesson-copy strong{display:block;font-size:12px}.lesson-copy small{display:block;font-size:10px;color:#a29aaa;margin-top:6px}.lesson-action{margin-left:auto;font-size:10px;color:#9b86ba;white-space:nowrap}.lesson-action b{margin-left:10px}.lesson:hover .lesson-copy strong{color:var(--purple)}.coming{display:flex;align-items:center;gap:15px;color:#9990a2;padding:8px 10px}.coming>span{font-size:29px}.coming p{font-size:11px}.coming small{font-size:10px;color:#aaa2b0}.daily{border:1px solid #e9e5dd;background:#fffefa;border-radius:15px;padding:24px;margin-top:64px;align-self:start}.daily-icon{font-size:32px;color:#caac6d}.daily h3{font-size:15px;margin:12px 0 7px}.daily>p{font-size:11px;color:#a19888}.daily-row{display:flex;justify-content:space-between;margin:22px 0 11px;font-size:11px}.daily-row span{color:#d5b16c}.daily .track{background:#f0ebdf}.daily .track i{background:#d5b16c}.tip{display:flex;gap:12px;align-items:center;margin-top:20px;border-top:1px solid #f0ebe2;padding-top:10px}.tip>span{font-size:23px;color:#ceac68}.tip p{font-size:10px;color:#a89d8b}footer{max-width:1210px;margin:auto;padding:24px 45px 30px;color:#b1aab9;font-size:10px;text-align:center}footer span{margin:0 9px;color:#c4b2dd}.progress-summary{display:grid;grid-template-columns:repeat(3,1fr);gap:20px;margin:36px 0}.progress-summary>div{background:#f1ebfa;border:1px solid #e6dcf3;border-radius:18px;padding:25px}.progress-summary span{color:#9f85cc;font-size:24px}.progress-summary strong{display:block;font-size:35px;margin-top:12px}.progress-summary p{color:#9b8aa9;font-size:12px}.storage-note{padding:24px 0;color:#8a8097}.storage-note h3{color:var(--ink)}.secondary{padding:12px 18px;border:1px solid #ddd3ec;border-radius:10px;color:#8067a7;background:#f4effa}dialog{width:min(610px,calc(100% - 28px));max-height:90vh;overflow:auto;padding:32px;border:1px solid #e4daef;border-radius:22px;color:var(--ink);background:var(--paper);box-shadow:0 30px 90px #30264333}dialog::backdrop{background:#29203988;backdrop-filter:blur(5px)}.quiz-top{display:flex;align-items:center;justify-content:space-between;color:#9a8ba9;font-size:12px}.close{background:none;border:0;padding:8px;font-size:18px}.quiz-track{margin:18px 0 30px}dialog h2{font-size:24px;line-height:1.35;margin:16px 0 24px}.choices{display:grid;gap:11px;margin-bottom:24px}.choice{display:flex;align-items:center;gap:13px;text-align:left;background:#fff;border:2px solid #e8e3ed;border-bottom-width:4px;border-radius:12px;padding:14px;line-height:1.5}.choice>span{font-size:11px;color:#9385a2;border:1px solid #e6ddec;border-radius:5px;padding:3px 7px}.choice.chosen{border-color:#a68bdb;background:#f2ebfd}.choice.correct{border-color:#8bbf9a;background:#edf8f0}.choice.incorrect{border-color:#e0ae94;background:#fcf1e9}.feedback{padding:16px 18px;border-radius:12px;background:#f7eedf;margin:0 0 18px}.feedback.good{background:#eaf5ed}.feedback strong{font-size:14px}.feedback p{font-size:13px;margin:7px 0 0}dialog>.primary{width:100%}.result{text-align:center;padding:20px 0}.result-icon{font-size:64px;color:#b294dc;margin-bottom:20px}.result .eyebrow{display:block}.result>p{color:#998ca6}.result-stats{display:grid;grid-template-columns:1fr 1fr;gap:15px;margin:28px 0}.result-stats>div{padding:24px;background:#f2edf8;border-radius:14px}.result-stats strong{display:block;font-size:26px;color:#9376c0}.result-stats span{display:block;font-size:12px;margin-top:7px;color:#a395af}.text-button{display:block;margin:18px auto 0;border:0;background:none;color:#9784af}.result .primary{width:100%}#toast{position:fixed;bottom:24px;left:50%;transform:translateX(-50%);padding:14px 22px;border-radius:12px;background:#302b3d;color:white;display:none;z-index:10}#toast.visible{display:block}@keyframes bob{50%{transform:translateY(-8px) rotate(5deg)}}@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important}}@media(min-width:1500px){main{padding-top:50px}.hero{min-height:310px}}@media(max-width:1100px){.sidebar{width:200px;padding:30px 15px}.main-wrap{margin-left:200px;width:calc(100% - 200px)}main{padding:30px 25px}.topbar{padding:0 25px}.topbar>span{font-size:10px}.hero-art{width:255px}.hero-art .blob{left:55px}.book{left:35px}.s1{left:5px}.art-caption{left:50px}.lower{grid-template-columns:minmax(0,1fr) 210px;gap:16px}.subject{padding:15px}.subject p{min-height:36px}.heading .date-pill{display:none}}@media(max-width:800px){.sidebar{width:80px;padding:25px 10px;align-items:center}.brand{font-size:0;gap:0}.brand-icon{font-size:40px}.brand-dot,.tagline,.sidebar-bottom{display:none}nav{margin-top:40px}.nav{font-size:0;padding:16px;gap:0}.nav span{font-size:25px}.main-wrap{margin-left:80px;width:calc(100% - 80px)}.topbar>span{display:none}.topbar{justify-content:flex-end;height:68px}.hero{padding:25px}.hero h2{font-size:30px}.hero-art{width:220px}.lower{grid-template-columns:1fr}.daily{margin-top:0}.daily>p{display:inline-block}.daily-row{margin-top:12px}.tip{margin-top:12px}}@media(max-width:560px){.shell{display:block}.sidebar{inset:auto 0 0;width:100%;height:70px;background:#fff;z-index:5;border-top:1px solid var(--line);padding:0;display:block}.brand{display:none}nav{display:flex;justify-content:space-around;margin:0;height:100%;gap:0;align-items:center}.nav{flex-direction:column;gap:5px;font-size:9px;padding:9px 16px;border-radius:10px}.nav span{font-size:21px}.main-wrap{margin-left:0;width:100%;padding-bottom:70px}.topbar{height:58px;padding:0 20px}.topbar:before{content:'✳ MTB';color:var(--purple);font-size:23px;font-weight:900;margin-right:auto}.stats{gap:15px;font-size:11px}.stats .avatar{display:none}main{padding:25px 18px 10px}h1{font-size:27px}.eyebrow{font-size:8px}.heading p{font-size:12px}.hero{min-height:270px;padding:23px 20px}.hero h2{font-size:29px}.hero p{font-size:11px}.hero .pill{font-size:7px}.hero-art{position:absolute;right:-45px;top:49px;width:200px;height:225px;transform:scale(.7);transform-origin:center}.hero>div:first-child{position:relative;z-index:1}.hero .primary{padding:12px 18px;font-size:12px}.hero .art-caption{display:none}.section-heading h2{font-size:16px}.section-heading>span{font-size:9px}.subjects{gap:8px}.subject{padding:12px 9px;border-radius:12px}.subject-icon{width:33px;height:33px;font-size:23px}.subject h3{font-size:15px;margin-top:13px}.subject p{font-size:10px;min-height:49px;line-height:1.5}.subject small{font-size:8px}.subject-check{font-size:12px}.selected .subject-check{width:15px;height:15px;font-size:9px}.lesson{gap:10px}.lesson-action{font-size:9px}.lesson-action b{margin-left:2px}.lesson-copy strong{font-size:11px}.lesson-copy small{font-size:9px}.step{width:36px;height:36px}.chapter-banner h3{font-size:12px}.coming small{font-size:9px}footer{font-size:9px;padding:20px 20px}.progress-summary{gap:8px}.progress-summary>div{padding:15px 10px}.progress-summary strong{font-size:28px}.progress-summary p{font-size:10px}.progress-summary span{font-size:20px}dialog{padding:23px}dialog h2{font-size:21px}.choice{font-size:13px}.result-stats strong{font-size:22px}}
/* Téléphones, Safari et mode installé : zones tactiles et bords sûrs. */
html{-webkit-text-size-adjust:100%;text-size-adjust:100%;scroll-padding-bottom:100px}button,a{touch-action:manipulation}.close{min-width:44px;min-height:44px}.text-button{min-height:44px}.install-button{display:block;margin:12px auto 0;min-height:44px;padding:10px 16px;border:1px solid #ddd3ec;border-radius:10px;background:#f4effa;color:#735797;font-size:12px}.install-steps{padding-left:23px;line-height:1.7;font-size:15px}.install-steps li{padding:5px 0 9px}.offline-status{padding:16px;background:#f0eafa;border-radius:12px;color:#66527f;font-size:14px}.device-note{font-size:12px;color:#776c83}dialog{max-height:calc(100dvh - 32px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px));overscroll-behavior:contain}body:has(dialog[open]){overflow:hidden}#toast{bottom:calc(88px + env(safe-area-inset-bottom,0px));max-width:calc(100% - 32px);width:max-content}
@media(max-width:800px){.choice{min-height:54px}.lesson{min-height:75px}.primary,.secondary{min-height:48px}}
@media(max-width:560px){.sidebar{height:calc(70px + env(safe-area-inset-bottom,0px));padding-bottom:env(safe-area-inset-bottom,0px)}.main-wrap{padding-bottom:calc(70px + env(safe-area-inset-bottom,0px))}.topbar{height:calc(58px + env(safe-area-inset-top,0px));padding-top:env(safe-area-inset-top,0px);padding-left:max(20px,env(safe-area-inset-left,0px));padding-right:max(20px,env(safe-area-inset-right,0px))}main{padding-left:max(18px,env(safe-area-inset-left,0px));padding-right:max(18px,env(safe-area-inset-right,0px))}.subject p{font-size:11px;min-height:66px}.subject small{font-size:10px;line-height:1.5}.lesson-copy strong{font-size:13px}.lesson-copy small{font-size:11px;line-height:1.5}.lesson-action{font-size:11px}.choice{font-size:16px}.quiz-top{font-size:12px}.nav{min-width:88px}.heading p{font-size:13px}.hero-art{right:-62px}.result-stats>div{padding:20px 10px}}
@media(max-width:370px){.subjects{grid-template-columns:1fr}.subject{padding:15px;display:grid;grid-template-columns:45px 1fr;column-gap:12px}.subject-top{grid-row:1 / 5;align-items:start}.subject-check{display:none!important}.subject h3{margin:0 0 7px}.subject p{min-height:0;margin:0 0 12px}.subject small{margin-top:7px}.hero h2{font-size:25px}.hero-art{opacity:.5;right:-82px}.lesson-action{font-size:0}.lesson-action b{font-size:17px}.lesson{gap:8px}}
@media(orientation:landscape) and (max-height:500px){.topbar{padding-left:max(25px,env(safe-area-inset-left,0px));padding-right:max(25px,env(safe-area-inset-right,0px))}.sidebar{padding-left:max(10px,env(safe-area-inset-left,0px));width:100px}.main-wrap{margin-left:100px;width:calc(100% - 100px)}main{padding-right:max(25px,env(safe-area-inset-right,0px))}dialog{max-height:calc(100dvh - 16px);padding:18px 24px}}

/* MTB — thème noir, appliqué aussi aux exercices et à l’app installée. */
:root{color-scheme:dark;--ink:#f3f1f7;--muted:#b1acbc;--purple:#9675ed;--line:#2a2732;--paper:#0b0b0f}
body{background:var(--paper);color:var(--ink)}
.sidebar,.topbar{background:#101014;border-color:var(--line)}
.tagline,.sidebar-bottom p,.profile small,.topbar,.heading p{color:#ada7b9}
.nav{color:#b6b0c1}.nav.active{background:#292039;color:#c8b2ff}.nav:hover{background:#211b2e}
.local-dot{color:#8acda2}.local-dot span{color:#b1acbc}
.avatar{background:#34291c;color:#f2c47c}.brand-icon,.brand-dot{color:#b69af8}
.stats{color:#f0c78b}.stats>span:nth-child(2){color:#bca0ff}
.eyebrow{color:#b5a1d4}.date-pill{border-color:#383041;color:#c3b5d5}
.hero{background:linear-gradient(115deg,#211a30,#18131f);border-color:#3b2b50}
.pill{color:#c0a4ed}.hero p{color:#c1b4ce}.primary{background:#8054d5;border-bottom-color:#563390;color:#fff}.primary:hover{background:#9266e4}.primary:disabled{background:#302a3c;border-color:#24202c;color:#9d94aa}
.blob{background:#a486d2;box-shadow:inset -13px -9px 0 #8d6dbb}.spark{color:#b092db}.formula,.art-caption{color:#b69bce}
.section-heading>span{color:#ada4bb}.subtle{color:#aa9cb9}
.subject{background:#151419;border-color:#35313e}.subject.selected{background:#201a2b;border-color:#a48ad2}
.subject p,.subject small{color:#b8b0c2}.subject-check{color:#bbaeC7}.subject-icon{background:#322542;color:#cdb0ff}
.selected .subject-check{background:#9471cb;color:#fff}.track{background:#35303f}.track i{background:#b093ed}
.orange .subject-icon{background:#39291e;color:#efb97c}.green .subject-icon{background:#20372b;color:#9dd5af}
.orange.selected{background:#241c16;border-color:#c49767}.green.selected{background:#15221b;border-color:#83b997}
.orange .track i{background:#e5b17b}.green .track i{background:#91caa4}
.chapter-banner{background:#231b30}.chapter-banner.orange{background:#2b2118}.chapter-banner.green{background:#1a2b20}
.chapter-banner span:not(.subject-icon){color:#baabcf}.chapter-banner.orange span:not(.subject-icon){color:#ceb498}.chapter-banner.green span:not(.subject-icon){color:#9fc3aa}
.step{background:#251d31;border-color:#69527f;color:#d3bce9;box-shadow:0 3px 0 #151018}.step.done{background:#203a29;border-color:#609e74;color:#b9e9c7;box-shadow:0 3px 0 #15241a}
.lesson-copy small{color:#b2a8bf}.lesson-action{color:#c2a3f0}.lesson:hover .lesson-copy strong{color:#c9adfa}
.coming{color:#c2b2d1}.coming small{color:#a99ab7}
.daily{background:#1a1712;border-color:#393127}.daily-icon,.daily-row span{color:#e2b976}.daily>p{color:#c3b8a3}
.daily .track{background:#393024}.daily .track i{background:#e0ba79}.tip{border-color:#3a3123}.tip>span{color:#e2bf7c}.tip p{color:#c6b898}
footer{color:#b1a5bd}footer span{color:#b898da}.progress-summary>div{background:#211a2d;border-color:#443451}.progress-summary span{color:#c4a2ef}.progress-summary p{color:#c0afcd}
.storage-note{color:#bdb0ca}.secondary,.install-button{background:#251c33;border-color:#604873;color:#dac0fa}.secondary:hover,.install-button:hover{background:#322445}
dialog{background:#111015;border-color:#473451;box-shadow:0 30px 90px #0009}dialog::backdrop{background:#000b}.quiz-top{color:#c1aecf}
.choice{background:#1a171f;border-color:#514758}.choice>span{color:#c6b5d7;border-color:#64546f}.choice.chosen{border-color:#b18fe4;background:#2c203d}
.choice.correct{border-color:#88c19a;background:#1d3728}.choice.incorrect{border-color:#dda382;background:#39251d}.choice:disabled{color:var(--ink);opacity:1}
.feedback{background:#33291a;color:#f0dec0}.feedback.good{background:#1c3326;color:#d1efdb}
.result-icon{color:#c3a0ef}.result>p{color:#bcaccb}.result-stats>div{background:#251c31}.result-stats strong{color:#d0a8ff}.result-stats span{color:#c7b4d4}.text-button{color:#cfb2ed}
.offline-status{background:#281e35;color:#d7c3ec}.device-note{color:#b9aac6}#toast{background:#e4d5f6;color:#21172d}
@media(max-width:560px){.sidebar{background:#101014}.topbar:before{color:#b99af3}}
