/* Proposed UX fixes. All rules live in the isolated review copy. */
:root{--dock-safe-bottom:env(safe-area-inset-bottom,0px);--review-dock-clearance:calc(88px + env(safe-area-inset-bottom,0px));--review-text:#203451;--review-surface:#fff;--review-border:#d7e1ef;--review-muted:#64748b}
/* One document scrollport: an auto-overflow body with no scroll range was
   swallowing wheel gestures before they could reach the document on laptops. */
html{overflow-x:clip;overflow-y:auto}
html body{overflow-x:clip!important;overflow-y:visible!important}
/* Lock that same document scrollport while keeping each modal's own scrollable
   content usable. Separate owners also keep overlapping windows locked safely. */
html.ai-scroll-locked,html.medarena-scroll-locked,html.surface-scroll-locked{overflow:hidden!important;overscroll-behavior:none}
html:has(dialog:modal){overflow:hidden!important;overscroll-behavior:none}
#profileModal .profile-card{max-height:calc(100dvh - 36px);overflow-y:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
html[data-theme=dark]{--review-text:#e6efff;--review-surface:#18253c;--review-border:#354561;--review-muted:#acbed7}
[hidden]{display:none!important}button,a,summary,input,select,textarea{-webkit-tap-highlight-color:transparent}
button:focus-visible,a:focus-visible,summary:focus-visible{outline:3px solid #6399e9;outline-offset:4px}
header button,.header-tools button,#authUserBar button,.language-switch,#accountToggle{min-width:44px!important;min-height:44px!important;touch-action:manipulation}
header .header-tools{flex-direction:row!important;gap:6px!important;height:auto!important}header .header-tools button{width:auto!important;height:44px!important;padding:8px 10px!important;position:static!important;transform:none!important}header #streakBtn{min-height:44px!important}
html[data-theme] body>header .header-tools{display:flex!important;flex:0 0 auto!important;width:auto!important;height:44px!important;grid-template-rows:none!important}
html[data-theme] body>header .header-tools>.ai-head-btn,html[data-theme] body>header .header-tools>#themeToggle{width:44px!important;height:44px!important;min-width:44px!important;min-height:44px!important;padding:6px!important;font-size:11px!important;border-radius:12px!important}
.wrap{max-width:1160px!important;padding-bottom:36px!important}
html[lang=ar] .streak-btn:after{content:'السلسلة'}
.wrap>nav:not(.glass-dock){position:static!important;display:flex!important;overflow:visible!important;flex-wrap:wrap!important;gap:7px}
.wrap>nav .tab{min-height:44px;font-size:12px}
#quickDock{display:none!important}
#cloudSyncBar #accountToggle{display:none}
.language-switch{border:1px solid var(--review-border);border-radius:12px;background:var(--review-surface);color:var(--review-text);font:inherit;font-size:12px;font-weight:750;padding:8px 12px;cursor:pointer}
.study-card{padding:clamp(20px,4vw,36px)!important;min-height:320px!important;overflow:visible!important}
.study-card #q,.study-card #a{max-width:100%;overflow-wrap:anywhere;unicode-bidi:plaintext}
.study-card #q{font-size:clamp(22px,4.8vw,30px)!important;line-height:1.5!important}
.study-card #a{font-size:clamp(19px,4.3vw,24px)!important;line-height:1.65!important}
#studySource{font-size:11px!important;margin-bottom:18px!important}
#flip{min-height:52px;width:min(100%,400px);margin-top:24px!important}
#ratings{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px!important;width:min(100%,520px);margin:24px auto 0!important;order:4}
#ratings.hidden{display:none!important}
#ratings>button{display:flex;flex-direction:column;gap:5px;align-items:center;justify-content:center;min-height:68px!important;width:100%;min-width:0;padding:12px!important}
#ratings .rating-interval{font-size:12px;font-weight:600;opacity:.92}
#ratings .rating-label{font-size:15px;font-weight:800}
#studyActions{order:6;width:100%;justify-content:center!important;margin-top:20px!important}
#studyCardMenu{position:relative;font-size:12px;color:var(--review-muted)}
#studyCardMenu summary{list-style:none;padding:10px 18px;cursor:pointer;min-height:44px;border-radius:12px}
#studyCardMenu summary::-webkit-details-marker{display:none}
.study-menu-items{position:absolute;inset-inline-start:50%;bottom:100%;transform:translateX(-50%);min-width:190px;display:grid;gap:8px;padding:10px;border:1px solid var(--review-border);background:var(--review-surface);border-radius:16px;box-shadow:0 14px 50px #122b4e25;z-index:5}
html[dir=rtl] .study-menu-items{transform:translateX(50%)}
.study-menu-items>button{min-height:44px;font-size:13px}
#studyEmptyActions{max-width:460px;margin:14px auto;order:5}#studyEmptyActions .actions{justify-content:center}
#scheduleNote{order:5}.progress-difficulty{font-size:11px!important}
.progress-count{direction:ltr;unicode-bidi:isolate}
#reviewNotices{position:fixed;z-index:2147483647;top:18px;left:50%;transform:translateX(-50%);width:min(440px,calc(100% - 24px));display:grid;gap:10px;pointer-events:none}
.review-notice{display:flex;align-items:flex-start;gap:14px;padding:16px 18px;background:var(--review-surface);color:var(--review-text);border:1px solid var(--review-border);border-inline-start:4px solid #5079ce;border-radius:16px;box-shadow:0 15px 60px #112b4940;font-size:13px;line-height:1.65;white-space:pre-wrap;pointer-events:auto}
.review-notice>span{flex:1}.review-notice>button{background:none;border:0;color:inherit;cursor:pointer;font-size:22px;min-height:32px;min-width:32px}
.review-dialog,.recovery-dialog,#mobileMore{box-sizing:border-box;width:min(460px,calc(100% - 32px));max-height:calc(100dvh - 40px);overflow:auto;border:1px solid var(--review-border);border-radius:24px;padding:26px;background:var(--review-surface);color:var(--review-text);box-shadow:0 24px 90px #091b4555}
.review-dialog::backdrop,.recovery-dialog::backdrop,#mobileMore::backdrop{background:#0c1e3c80;backdrop-filter:blur(6px)}
.review-dialog h2,.recovery-dialog h2{font-size:21px;margin:0 0 12px;line-height:1.5}.review-dialog p,.recovery-dialog p{white-space:pre-wrap;font-size:14px;line-height:1.75;color:var(--review-muted);overflow-wrap:anywhere}
.review-dialog-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:22px}.review-dialog-actions button{min-height:44px}
.review-dialog input,.recovery-dialog input{color:var(--review-text);background:var(--review-surface);border:1px solid var(--review-border)}
html[data-theme] .review-dialog .review-dialog-actions>#reviewDialogConfirm.review-confirm-danger{background:#c62828!important;color:#fff!important;border:1px solid #b71c1c!important;box-shadow:none!important}
html[data-theme] .review-dialog .review-dialog-actions>#reviewDialogConfirm.review-confirm-danger:hover{background:#ad2020!important}
.recovery-codes{display:grid;gap:8px;padding:16px;background:#5174ae12;border-radius:14px;direction:ltr;text-align:center;font:14px/1.7 ui-monospace,Consolas,monospace;user-select:all}
.recovery-dialog label{font-size:13px;font-weight:750;display:block}.recovery-dialog .form-status{font-size:13px;color:#b64747;line-height:1.7}.recovery-dialog input{margin:7px 0 16px}
.recovery-settings{border-top:1px solid var(--review-border);margin-top:20px;padding-top:20px}.recovery-settings p{font-size:12px;color:var(--review-muted);line-height:1.7}
#mobileMore .more-pages{display:grid;gap:8px}#mobileMore h2{font-size:20px;margin:0 0 16px}#mobileMore .more-pages button{min-height:48px;text-align:start}
.auth-card{max-height:calc(100dvh - 26px);overflow:auto}.auth-card>.auth-link{display:block;margin:12px auto;color:inherit;text-decoration:none;text-align:center;font-size:12px}
#authGate .auth-card .language-switch{display:block;margin:0 auto 16px}html[data-theme] body.welcome-visible{background:#f6f7f2!important;overflow:auto!important;color:#193c34!important}
body.welcome-visible>header,body.welcome-visible>#cloudSyncBar,body.welcome-visible>.wrap,body.welcome-visible>#authGate,body.welcome-visible>#quickDock,body.welcome-visible>#studySessionFloat{display:none!important}
#welcome{--review-text:#193c34;--review-surface:#fefefa;--review-border:#cad6c3;--welcome-muted:#526752;color-scheme:light;background:#f6f7f2;color:#193c34;font:15px/1.65 -apple-system,BlinkMacSystemFont,"Segoe UI",Tahoma,sans-serif;min-height:100dvh}
#welcome [lang=ar],#welcome [lang=en]{display:initial}html[lang=en] #welcome [lang=ar],html[lang=ar] #welcome [lang=en]{display:none!important}
.welcome-top{display:flex;align-items:center;justify-content:space-between;max-width:1180px;margin:auto;padding:22px 36px;border-bottom:1px solid #dce3d9;gap:20px}
.welcome-brand{display:flex;align-items:center;gap:10px;font-size:21px;font-weight:850;text-decoration:none;color:inherit}.welcome-brand img{border-radius:10px}
.welcome-tools{display:flex;align-items:center;gap:20px}.welcome-tools a{text-decoration:none;font-size:12px;font-weight:750}.welcome-signup{padding:12px 16px;background:#214d3e;color:white;border-radius:9px;min-height:44px}
.welcome-content{max-width:1180px;margin:auto;padding:0 38px}
#welcome h1,#welcome h2{font-family:Georgia,"Times New Roman",serif;font-weight:400;line-height:1.1;letter-spacing:-.045em;margin:0}#welcome h1{font-size:clamp(48px,6.1vw,82px)}#welcome h2{font-size:clamp(34px,4.2vw,55px)}#welcome h3{margin:0;font-size:22px;font-weight:650}#welcome em{color:#52846a;font-weight:400}#welcome p{margin:0 0 16px}
html[lang=ar] #welcome h1,html[lang=ar] #welcome h2{font-family:Tahoma,sans-serif;line-height:1.45;letter-spacing:-.04em}
#welcome .hero{display:grid;grid-template-columns:1.2fr 1fr;gap:70px;align-items:center;padding-block:74px}
#welcome .eyebrow{font-size:10px;font-weight:750;letter-spacing:.12em;color:var(--welcome-muted);margin-bottom:24px}html[lang=ar] #welcome .eyebrow{letter-spacing:0;font-size:12px}
#welcome .lead{font-size:16px;line-height:1.85;color:var(--welcome-muted);max-width:490px;margin-top:25px}
#welcome .hero-actions{display:flex;align-items:center;flex-wrap:wrap;gap:24px;margin-top:30px}#welcome .button{display:inline-flex;align-items:center;gap:8px;justify-content:center;padding:14px 22px;border:1px solid #214d3e;border-radius:9px;background:#214d3e;color:white;text-decoration:none;min-height:48px;font-size:13px;font-weight:650}#welcome .button.secondary{background:transparent;color:#214d3e}
#welcome a{color:inherit}#welcome .button{color:white}#welcome .text-link{font-size:13px;font-weight:650;text-decoration:none}#welcome .fine{font-size:11px;color:var(--welcome-muted);margin-top:15px}
#welcome .demo{position:relative;background:#fefefa;border:1px solid #d6e0cd;border-radius:18px;padding:34px;box-shadow:12px 20px 0 #e4ebdc;transform:rotate(2deg);min-height:380px}
#welcome .demo-top,#welcome .demo-bottom{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:10px;color:var(--welcome-muted)}#welcome .demo-top{padding-bottom:22px;border-bottom:1px solid #e0e6d9}#welcome .demo-label{color:var(--welcome-muted);font-size:9px;letter-spacing:.12em;margin-top:32px}#welcome .demo-question{font:42px/1.15 Georgia,serif;margin:18px 0 24px;min-height:100px}#welcome .demo-answer{font-size:14px;color:var(--welcome-muted);line-height:1.7;margin-bottom:20px}#welcome .demo-button{width:100%}#welcome .demo-bottom{margin-top:22px;font-size:9px}
#welcome .proof-strip{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:24px 0;border-block:1px solid #dce3d9;font-size:12px;color:var(--welcome-muted)}#welcome .proof-strip i{font-style:normal;color:#b39b6f}
#welcome .section{padding-block:65px}#welcome .section-heading{display:grid;grid-template-columns:1.1fr 1fr;gap:70px;margin-bottom:40px;align-items:end}#welcome .section-heading>p{color:var(--welcome-muted);line-height:1.8;font-size:14px}#welcome .feature-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:25px}#welcome .feature{border-top:1px solid #bdcbb7;padding-top:24px}#welcome .feature .number{display:block;color:var(--welcome-muted);font-size:12px;margin-bottom:25px}#welcome .feature h3{font-size:19px;margin-bottom:14px}#welcome .feature p{font-size:12px;line-height:1.8;color:var(--welcome-muted)}#welcome .plan-notes{padding:26px;border:1px solid #cad6c3;border-radius:14px;font-size:14px;color:var(--welcome-muted);line-height:1.9}#welcome .contact{display:grid;grid-template-columns:1fr 1fr;gap:70px;background:#e5ecdf;padding:40px;border-radius:18px;margin-bottom:60px}#welcome .contact p{color:var(--welcome-muted);font-size:13px;line-height:1.9;margin-top:20px}#welcome .contact-address{display:flex;flex-direction:column;align-items:start;justify-content:center;gap:16px}#welcome .contact-address>a:first-child{font-size:24px}#welcome .contact-address>span{color:var(--welcome-muted);font-size:12px}
.welcome-footer{display:flex;justify-content:center;gap:30px;padding:26px;font-size:12px;border-top:1px solid #dce3d9}.welcome-footer a{color:inherit}
#welcome .welcome-signup{color:white}
html[dir=rtl] .folder-children{padding-left:0;padding-right:18px}html[dir=rtl] th,html[dir=rtl] td{text-align:right}html[dir=rtl] .deck-summary{text-align:right}html[dir=rtl] input[type=password],html[dir=rtl] #authUsername{direction:ltr;text-align:start}
@media(max-width:760px){
 body{padding-bottom:0!important}header{padding:9px 12px!important;min-height:66px!important;gap:8px!important}header h1{font-size:16px!important;white-space:nowrap}header h1 img{width:29px;height:29px}header .brand-subtitle{display:none!important}.header-right{gap:4px!important}header .header-tools{gap:4px!important}header .header-tools button{min-width:38px!important;padding:7px!important}header #dueBadge{min-width:36px!important;font-size:10px!important;padding:5px!important}header #streakBtn{min-width:40px!important;font-size:12px!important;padding:5px!important}
 #cloudSyncBar{margin:8px 12px 0!important;padding:5px 10px!important;gap:6px!important;min-height:49px!important;border-radius:14px!important;flex-wrap:wrap!important}#cloudSyncStatus{flex:1;min-width:0}#cloudSyncStatus .cloud-copy{gap:2px}#cloudSyncStatus .cloud-copy b{font-size:11px!important}#cloudSyncStatus .cloud-copy small{display:none!important}#cloudSyncBar.needs-attention #cloudSyncStatus .cloud-copy small{display:block!important}#cloudSyncBar #accountToggle{display:block;font:inherit;font-size:11px;border:0;border-radius:10px;background:transparent;color:var(--review-text);cursor:pointer;padding:5px 8px}#cloudSyncBar .language-switch{min-height:40px!important;padding:6px 8px;font-size:11px}
 #authUserBar{display:none!important}#cloudSyncBar.expanded #authUserBar{display:flex!important;width:100%;border-top:1px solid var(--review-border);padding-top:10px;gap:8px;flex-wrap:wrap;padding-bottom:6px}
 .wrap{padding:16px 12px var(--review-dock-clearance)!important}.wrap>nav:not(.glass-dock){display:none!important}
 #quickDock{display:flex!important;position:fixed!important;left:10px!important;right:10px!important;bottom:max(0px,calc(var(--dock-safe-bottom,0px) - 12px))!important;transform:none!important;width:auto!important;height:66px!important;min-height:66px!important;max-width:none!important;margin:0!important;padding:5px!important;gap:2px!important;z-index:1000!important;border-radius:24px!important}#quickDock .dock-btn{flex:1;min-width:0!important;min-height:54px!important;padding:4px 2px!important;border-radius:18px!important}#quickDock .dock-btn small{font-size:9px!important}#quickDock .dock-btn .dock-icon{height:25px!important;width:25px!important}#quickDock .dock-btn .dock-icon svg{width:25px!important;height:25px!important}
 body.auth-required #quickDock,body.ai-chat-open #quickDock,body.welcome-visible #quickDock{display:none!important}
 #studySessionFloat{bottom:calc(var(--review-dock-clearance) + 8px)!important}
 #study .row{gap:8px!important}#study .row select{margin:0!important;padding:10px!important;font-size:12px!important;min-height:44px!important}#study .study-progress{padding-top:4px;font-size:11px!important}#study .study-card{margin-top:12px!important;min-height:300px!important;padding:24px 18px!important}.study-card #a{margin-top:20px!important}#ratings{margin-top:22px!important}
 .welcome-top{padding:15px 18px;gap:12px;flex-wrap:wrap}.welcome-brand{font-size:18px}.welcome-tools{gap:10px}.welcome-tools .language-switch{min-height:40px}.welcome-tools .welcome-signin{font-size:11px}.welcome-signup{font-size:11px!important;padding:10px!important}.welcome-content{padding:0 22px}#welcome .hero{grid-template-columns:1fr;gap:44px;padding-block:45px 55px}#welcome h1{font-size:52px}#welcome .lead{font-size:14px}#welcome .demo{width:95%;margin:auto;padding:24px;min-height:340px}#welcome .demo-question{font-size:38px}#welcome .proof-strip{gap:8px;font-size:9px;text-align:center}#welcome .section{padding-block:45px}#welcome .section-heading{grid-template-columns:1fr;gap:20px;margin-bottom:28px}#welcome .section-heading h2{font-size:38px}#welcome .feature-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}#welcome .feature h3{font-size:17px}#welcome .feature p{font-size:11px}#welcome .plan-notes{padding:20px;font-size:12px}#welcome .contact{grid-template-columns:1fr;gap:20px;padding:26px 22px}#welcome .contact-address>a:first-child{font-size:20px}
}
@media(max-width:359px){header h1{font-size:14px!important}header h1 img{width:24px;height:24px}header .header-tools button{min-width:34px!important}header #dueBadge{display:none!important}.welcome-tools{width:100%;justify-content:space-between}.welcome-top{gap:10px}#welcome h1{font-size:44px}}
@media(prefers-reduced-motion:reduce){#welcome .demo{transform:none}*{scroll-behavior:auto!important}}
/* Approved revision: original dual navigation, morphing right rail in landscape. */
html .wrap>nav:not(.glass-dock){display:flex!important}
#quickDock{display:flex!important;position:fixed!important;z-index:1000!important;box-sizing:border-box!important;direction:ltr!important;gap:3px!important;padding:6px!important;margin:0!important;max-width:none!important;min-height:0!important;border-radius:24px!important}
html[data-dock-layout=bottom] body>nav#quickDock.glass-dock{left:50%!important;right:auto!important;top:auto!important;bottom:max(0px,calc(var(--dock-safe-bottom,0px) - 12px))!important;transform:translateX(-50%)!important;width:min(620px,calc(100% - 24px))!important;height:76px!important;flex-direction:row!important}
html[data-dock-layout=rail] body>nav#quickDock.glass-dock{left:auto!important;right:max(16px,env(safe-area-inset-right,0px))!important;top:var(--dock-rail-top,240px)!important;bottom:auto!important;transform:none!important;width:76px!important;height:var(--dock-rail-height,380px)!important;flex-direction:column!important;touch-action:pan-x pinch-zoom}
html #quickDock .dock-btn{flex:1 1 0!important;min-width:0!important;min-height:44px!important;max-height:none!important;width:auto!important;padding:4px!important;display:flex!important;flex-direction:column!important;gap:2px!important;align-items:center!important;justify-content:center!important;border-radius:17px!important}
html[data-dock-layout=rail] #quickDock .dock-btn{width:100%!important}
html #quickDock .dock-btn small{font-size:9px!important;line-height:1.25!important;white-space:nowrap!important}
html #quickDock .dock-btn .dock-icon,html #quickDock .dock-btn .dock-icon svg{width:25px!important;height:25px!important}
html[data-dock-layout=bottom] .wrap{padding-bottom:var(--review-dock-clearance)!important}
html[data-dock-layout=rail] .wrap{width:calc(100% - max(18px,calc((100vw - 1160px)/2)) - 108px)!important;max-width:1160px!important;margin-left:max(18px,calc((100vw - 1160px)/2))!important;margin-right:max(108px,calc((100vw - 1160px)/2))!important;padding-bottom:30px!important}
html[data-dock-layout=rail] #studySessionFloat{bottom:18px!important;right:112px!important}
body.auth-required #quickDock,body.ai-chat-open #quickDock,body.welcome-visible #quickDock{display:none!important}
#quickDock.dock-morphing{background:transparent!important;backdrop-filter:none!important;-webkit-backdrop-filter:none!important;box-shadow:none!important;border-color:transparent!important;pointer-events:none!important}
#quickDock.dock-morphing .glass-nav-lens{visibility:hidden!important}
.dock-morph-surface{position:fixed;z-index:999;pointer-events:none;box-sizing:border-box;background:linear-gradient(145deg,rgba(255,255,255,.7),rgba(222,235,255,.65));border:1px solid rgba(255,255,255,.8);box-shadow:0 12px 38px #22447025,inset 0 1px 1px #ffffffc0;backdrop-filter:blur(18px);-webkit-backdrop-filter:blur(18px);border-radius:24px}
#ratings{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:6px!important;width:min(100%,600px)!important}
#ratings>button{padding:10px 3px!important;min-height:64px!important;min-width:0!important}
#ratings .rating-label{font-size:clamp(10px,2.8vw,15px)!important;white-space:nowrap}
#ratings .rating-interval{font-size:clamp(9px,2.4vw,12px)!important;white-space:nowrap}
/* Keep the assistant inside the visual viewport, including the iOS keyboard. */
#aiModal:is(.open,.ai-expanded) .modal-box{left:var(--ai-left,8px)!important;top:var(--ai-top,8px)!important;right:auto!important;bottom:auto!important;width:var(--ai-width,calc(100vw - 16px))!important;height:var(--ai-height,600px)!important;max-width:none!important;max-height:none!important;min-height:0!important;box-sizing:border-box;display:flex;flex-direction:column;overflow:hidden}
#aiModal .ai-top,#aiModal .ai-chips,#aiModal .ai-form,#aiModal .ai-foot{flex:0 0 auto;box-sizing:border-box}
#aiModal .ai-top{gap:8px}#aiModal .ai-top h2{font-size:clamp(17px,4.2vw,24px);line-height:1.3}
#aiModal .ai-window-tools{flex-shrink:0}
#aiModal .ai-messages{flex:1 1 0!important;min-height:0!important;max-height:none!important;overflow-y:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;overflow-anchor:auto}
#aiModal .ai-form{margin:0;min-height:76px;padding:10px;align-items:stretch}
#aiModal .ai-form textarea{min-width:0;width:0;min-height:52px;height:52px;max-height:100px;margin:0;box-sizing:border-box;font-size:16px!important;line-height:1.4;touch-action:pan-y}
#aiModal #aiSend{min-width:56px;min-height:44px;flex-shrink:0;padding:10px}
#aiModal.ai-keyboard-open .ai-top{padding:10px 12px;align-items:center}
#aiModal.ai-keyboard-open .ai-top .muted,#aiModal.ai-keyboard-open .ai-drag-hint,#aiModal.ai-keyboard-open .ai-foot{display:none!important}
#aiModal.ai-keyboard-open .ai-chips{padding:6px 10px;gap:6px}
#aiModal.ai-keyboard-open .ai-chips button{padding:6px 9px;font-size:11px}
#aiModal.ai-keyboard-open .ai-messages{padding:10px}
body.ai-chat-open{overscroll-behavior:none}
@media(max-width:760px){
 header .brand-subtitle{display:block!important;font-size:9px!important;line-height:1.35;white-space:normal;max-width:172px;margin-top:3px!important}
 html[data-dock-layout=bottom] #quickDock .dock-btn small{font-size:clamp(9px,2.5vw,11px)!important}
 html[data-dock-layout=bottom] #quickDock .dock-icon,html[data-dock-layout=bottom] #quickDock .dock-icon svg{width:28px!important;height:28px!important}
}
@media(max-width:760px){html .wrap>nav:not(.glass-dock){flex-wrap:nowrap!important;overflow-x:auto!important;overflow-y:hidden!important;scrollbar-width:none;gap:6px!important;margin-bottom:14px!important;padding:7px!important}html .wrap>nav .tab{flex:0 0 auto!important;white-space:nowrap!important;min-height:40px!important;font-size:11px!important;padding:9px 11px!important}}

/* Review v2: account, readable AI replies and public link touch targets. */
#profileModal .profile-card{position:relative;padding-top:58px}
#profileModal .profile-close{position:absolute;inset-block-start:14px;inset-inline-end:14px;width:44px;height:44px;min-width:44px;padding:0;font-size:22px}
#profileModal .recovery-settings{padding:18px 0;border-top:1px solid var(--line,#dce4f4);margin-top:18px}
#profileModal #generateRecovery{min-height:44px;border:1px solid #cbd5e1;border-radius:12px;padding:11px 16px;font:inherit;cursor:pointer;background:var(--card,#eef3ff);color:inherit}
#welcome .welcome-tools>a,#welcome footer a,#welcome .footer-links a{display:inline-flex;align-items:center;min-height:44px;padding:10px 12px;box-sizing:border-box}
#welcome .welcome-tools{flex-wrap:wrap}
.ai-bubble p{margin:0 0 .65em}.ai-bubble p:last-child{margin-bottom:0}.ai-bubble h4{margin:.6em 0}.ai-bubble ul,.ai-bubble ol{margin:.4em 0;padding-inline-start:1.5em}.ai-bubble li{margin:.35em 0}.ai-bubble pre{white-space:pre-wrap;overflow-wrap:anywhere;background:#0001;padding:10px;border-radius:10px}.ai-bubble code{font-size:.9em;background:#0001;border-radius:4px;padding:1px 4px}

#welcome .text-link{display:inline-flex;align-items:center;min-height:44px;padding:9px 0;box-sizing:border-box}#welcome .welcome-footer{flex-wrap:wrap;gap:8px 20px}
