@font-face{font-family:Figtree;src:url('assets/figtree_variable_font_wght.ttf') format('truetype');font-weight:100 900;font-display:swap}
@font-face{font-family:Figtree;src:url('assets/figtree_italic_variable_font_wght.ttf') format('truetype');font-weight:100 900;font-style:italic;font-display:swap}
@font-face{font-family:Garamond;src:url('assets/eb_garamond_variable_font_wght.ttf') format('truetype');font-weight:100 900;font-display:swap}
:root{--lumen:#ffffeb;--pulse:#7f1c34;--dawn:#f0d7ff;--vast:#1a1a1a;--vivid:#b689ff;--wvivid:#b282ff;--pink:#eaddff;--gray:#49454f;--n50:#faf9fa;--n100:#eeeef0;--n200:#b0abb2;--n400:#c9c4cf;--n500:#7f7b81;--n600:#656067;--n800:#312d37;--n850:#1d1b20;--p200:#f8f6fe;--p300:#f7ebff;--p400:#f4e1ff;--p800:#6c358c;--line:#e5e1e8;--shadow:0 12px 40px #312d3710;--r:22.5px;--small-r:14px}
*{box-sizing:border-box}html,body{margin:0;min-height:100%;font-family:Figtree,sans-serif;color:var(--n850);background:#efedf2}button,input,select,textarea{font:inherit}button{cursor:pointer}button:disabled{cursor:default;opacity:.45}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:3px solid #b689ff66;outline-offset:3px}a{color:var(--p800);text-decoration:none}h1,h2,h3,p{margin-top:0}h1{font-family:Garamond,serif;font-weight:550;font-size:36px;line-height:1.08;letter-spacing:-.02em}h2{font-size:23px;line-height:1.2}h3{font-size:16px}p{line-height:1.45}small,.muted{color:var(--n600)}[hidden],.hidden{display:none!important}
#app{display:grid;grid-template-columns:300px minmax(0,1fr);min-height:100dvh}#tone-sidebar{position:sticky;top:0;height:100dvh;overflow:auto;background:var(--vast);color:#f5f2f7;padding:26px 20px;display:flex;flex-direction:column;gap:18px}.brand{display:grid;grid-template-columns:38px 1fr;align-items:center;gap:10px}.brand small{grid-column:2;color:#bcb4c2}.logo{display:flex;align-items:center;justify-content:center;gap:3px;width:34px;height:34px;background:#f4e1ff;border-radius:10px}.logo i{display:block;width:3px;background:var(--vast);border-radius:2px}.logo i:nth-child(1){height:8px}.logo i:nth-child(2){height:16px}.logo i:nth-child(3){height:11px}.logo i:nth-child(4){height:19px}.sidebar-actions{display:flex;gap:6px}.sidebar-actions button,.map-step{color:#ddd4e5;background:#ffffff0c;border:1px solid #ffffff12;border-radius:9px;padding:8px 10px}.sidebar-actions button:hover,.map-step:hover{background:#ffffff18}.map-step{display:block;width:100%;text-align:left;font-size:12px;margin:4px 0}.map-step.active{background:var(--p800);color:#fff;border-color:var(--p800)}#tone-map{overflow:auto;display:flex;flex-direction:column;gap:2px;padding-right:4px}.oem-picker{display:grid;gap:7px;font-size:12px;color:#c8becf}.oem-picker select{background:#ffffff10;color:#fff;border:1px solid #ffffff1c;border-radius:10px;padding:10px}.oem-picker option{color:var(--vast)}#oem-note{font-size:12px;line-height:1.45;color:#bcb2c4;border-top:1px solid #ffffff14;padding-top:14px}
#phone{position:relative;width:min(100%,480px);min-height:100dvh;margin:auto;background:var(--n50);display:flex;flex-direction:column;box-shadow:0 0 80px #1a1a1a1a;overflow:hidden}#phone-status{height:40px;display:flex;align-items:center;justify-content:space-between;padding:8px 20px 0;font-size:11px;color:var(--n600);z-index:2}.recording-pill{display:flex;align-items:center;gap:5px;background:#eee9f2;border-radius:20px;padding:4px 8px}.recording-pill span{width:6px;height:6px;border-radius:50%;background:#ef5da8}.status-icons{letter-spacing:3px;font-size:7px}#progress{display:flex;gap:6px;margin:6px 20px 0}#progress span{flex:1;height:4px;background:#edeaf0;border-radius:4px;overflow:hidden}#progress i{display:block;height:100%;background:var(--p800);border-radius:4px;transition:width .35s ease}#screen{flex:1;display:flex;flex-direction:column;padding:26px 24px 24px;animation:screenIn .28s ease}#bottom-nav{display:flex;justify-content:space-around;border-top:1px solid var(--line);padding:10px 8px calc(10px + env(safe-area-inset-bottom));background:#fff}#bottom-nav button{display:grid;place-items:center;gap:1px;border:0;background:none;color:var(--n500);font-size:10px}#bottom-nav button span{font-size:20px;font-weight:700}#bottom-nav button.active{color:var(--p800)}
.headline{margin:14px 0 18px}.subtitle{color:var(--n600);font-size:15px;margin-bottom:22px}.center{text-align:center}.left{text-align:left}.spacer{flex:1;min-height:16px}.actions{display:grid;gap:10px;margin-top:20px}.btn{border:1px solid transparent;border-radius:12px;padding:14px 18px;min-height:50px;font-weight:600;transition:transform .1s,background .2s,box-shadow .2s}.btn:active{transform:scale(.985)}.btn.primary{background:var(--pink);color:var(--vast)}.btn.primary:hover{background:var(--dawn)}.btn.dark{background:var(--vast);color:#fff}.btn.secondary{background:#fff;border-color:#d8d3dc;color:var(--vast)}.btn.ghost{background:transparent;color:var(--n600)}.btn.danger{background:#ffe4e7;color:#a51e43}.btn.small{padding:8px 12px;min-height:36px;font-size:13px;border-radius:9px}.btn.icon{padding:10px 12px;min-height:40px}.link-btn{border:0;background:none;color:var(--p800);padding:6px;font-weight:600}.text-row{display:flex;align-items:center;justify-content:space-between;gap:12px}.top-row{display:flex;align-items:center;justify-content:space-between;margin-bottom:16px}.top-row h1,.top-row h2{margin:0}.back{border:0;background:transparent;font-size:24px;color:var(--n800);padding:4px 8px}.cancel{font-size:14px;color:var(--n600)}
.video-card{position:relative;overflow:hidden;border-radius:var(--r);background:#111;box-shadow:var(--shadow);margin:10px 0 22px}.video-card video{width:100%;display:block;aspect-ratio:9/16;object-fit:cover}.video-card.overlay-text::after{content:attr(data-caption);position:absolute;left:22px;right:22px;bottom:22px;color:#fff;font-family:Garamond,serif;font-size:29px;line-height:1.1;text-shadow:0 2px 20px #000}.dots{display:flex;justify-content:center;gap:7px;margin:14px}.dots i{width:5px;height:5px;border-radius:50%;background:#d2cbd7}.dots i.active{background:var(--p800)}.loading-circle{width:34px;height:34px;border:3px solid #ddd4e7;border-top-color:var(--p800);border-radius:50%;margin:26px auto;animation:spin .8s linear infinite}.shimmer{border-radius:12px;background:linear-gradient(90deg,#e5e2e8 20%,#f8f6fa 50%,#e5e2e8 80%);background-size:220% 100%;animation:shimmer .8s ease-in-out infinite alternate}.skeleton{height:52px;margin:10px 0}.spoked{position:relative;width:90px;height:90px;margin:28px auto}.spoked .logo{position:absolute;inset:24px}.spoked i{position:absolute;width:8px;height:8px;background:#e9b949;clip-path:polygon(50% 0,63% 35%,100% 50%,63% 65%,50% 100%,37% 65%,0 50%,37% 35%);animation:spoke 1.8s ease-in-out infinite}.spoked i:nth-child(1){left:41px;top:0}.spoked i:nth-child(2){right:8px;top:14px;animation-delay:.2s}.spoked i:nth-child(3){right:0;top:42px;animation-delay:.4s}.spoked i:nth-child(4){right:12px;bottom:8px;animation-delay:.6s}.spoked i:nth-child(5){left:12px;bottom:8px;animation-delay:.8s}.spoked i:nth-child(6){left:0;top:42px;animation-delay:1s}.spoked i:nth-child(7){left:8px;top:14px;animation-delay:1.2s}.spoked i:nth-child(8){left:41px;top:41px;animation-delay:1.4s}
.card{display:block;width:100%;text-align:left;background:#fff;border:1px solid var(--line);border-radius:var(--small-r);padding:16px;margin:10px 0;box-shadow:0 2px 8px #312d3704}.card.selected{border:2px solid var(--vast);padding:15px}.card h3{margin-bottom:6px}.card p{margin:0;color:var(--n600);font-size:14px}.card .check{float:right;width:22px;height:22px;border:1px solid #aaa0b0;border-radius:50%;display:grid;place-items:center;color:var(--p800)}.card.selected .check{border-color:var(--p800);box-shadow:inset 0 0 0 4px #fff;background:var(--p800);color:#fff}.cards{display:grid;gap:10px}.cards.two{grid-template-columns:repeat(2,1fr)}.app-preview{border:1px solid #d9d4dc;border-radius:18px;padding:15px;background:#fff}.app-preview .app-title{display:flex;align-items:center;gap:8px;font-weight:650;margin-bottom:14px}.app-icon{display:inline-grid;place-items:center;width:28px;height:28px;border-radius:8px;background:#e9e3f0;font-size:16px}.mock-input{min-height:150px;border:1px solid #ddd7e0;border-radius:14px;padding:16px;background:#fff;color:var(--n800);white-space:pre-wrap}.mock-input.focused{border-color:var(--p800);box-shadow:0 0 0 3px #b689ff22}.hint{color:var(--n500);font-size:14px;margin:12px 0}.bubble{display:inline-flex;align-items:center;justify-content:center;gap:5px;background:var(--n800);color:#fff;border-radius:14px;padding:11px 14px;box-shadow:0 7px 18px #312d3733;animation:bubbleIn .1s ease-out;font-size:13px}.bubble::before{content:'|||';font-weight:800;letter-spacing:1px}.bubble.recording{background:var(--p800)}.bubble.processing{background:#5c4b68}.bubble.offline{background:var(--n500)}.bubble.dot{padding:9px;border-radius:50%;font-size:0}.bubble.small{font-size:10px;padding:8px 10px}.bubble-row{display:flex;justify-content:flex-end;align-items:center;gap:10px;margin:14px 0}.wave{display:flex;align-items:center;gap:3px;height:20px}.wave i{width:3px;background:#fff;border-radius:3px;animation:wave .7s ease-in-out infinite alternate}.wave i:nth-child(1){height:8px}.wave i:nth-child(2){height:17px;animation-delay:.15s}.wave i:nth-child(3){height:11px;animation-delay:.3s}.wave i:nth-child(4){height:15px;animation-delay:.45s}
.field{display:grid;gap:6px;margin:12px 0}.field label{font-size:13px;color:var(--n600)}.field input,.field textarea,.field select{width:100%;border:1px solid #d6d0da;border-radius:10px;background:#fff;padding:12px;color:var(--vast)}.field textarea{min-height:100px;resize:vertical}.search{display:flex;gap:8px;align-items:center}.search input{flex:1}.chips{display:flex;flex-wrap:wrap;gap:8px}.chip{border:1px solid #d8d2dd;border-radius:20px;padding:8px 12px;background:#fff}.chip.selected{background:#fff7d6;border-color:#bda44a}.tabs{display:flex;gap:6px;overflow:auto;padding-bottom:6px;margin-bottom:16px}.tab{border:0;background:transparent;padding:9px 12px;border-radius:10px;color:var(--n600);white-space:nowrap}.tab.active{background:#eee8f4;color:var(--p800);font-weight:650}.list{display:grid;gap:8px}.list-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 2px;border-bottom:1px solid var(--line)}.list-row:last-child{border:0}.list-row .main{display:flex;align-items:center;gap:12px}.list-row .content{flex:1}.list-row small{display:block}.chevron{color:var(--n400);font-size:22px}.toggle{position:relative;width:44px;height:26px;border:0;border-radius:20px;background:#d8d4dc;padding:0;transition:background .2s;flex:none}.toggle::after{content:'';position:absolute;width:20px;height:20px;left:3px;top:3px;border-radius:50%;background:#fff;box-shadow:0 1px 4px #0003;transition:transform .2s}.toggle.on{background:var(--p800)}.toggle.on::after{transform:translateX(18px)}.range{width:100%;accent-color:var(--p800)}.range-labels{display:flex;justify-content:space-between;color:var(--n500);font-size:12px}.notice{border-radius:12px;padding:14px;background:#fff6df;border:1px solid #ead49b;font-size:14px}.notice.error{background:#ffe4e7;border-color:#f3bdc6}.notice.success{background:#e7f8ef;border-color:#a6dfc0}.legal{max-height:48dvh;overflow:auto;border:1px solid var(--line);border-radius:14px;padding:16px;background:#fff;font-size:14px}.legal p{color:var(--n600)}.fab{position:absolute;right:28px;bottom:84px;width:52px;height:52px;border:0;border-radius:50%;background:var(--vast);color:#fff;font-size:28px;box-shadow:0 8px 24px #1a1a1a44}.empty{display:grid;place-items:center;text-align:center;padding:40px 20px;color:var(--n500)}.empty .logo{margin-bottom:14px}.dialog-backdrop{position:fixed;inset:0;background:#1a1a1a88;display:grid;place-items:center;padding:24px;z-index:20;animation:fade .18s ease}.dialog{width:min(100%,390px);background:#fff;border-radius:20px;padding:20px;box-shadow:0 20px 70px #0005;animation:dialogIn .22s ease}.dialog.dark{background:#29262d;color:#fff}.dialog h2{margin-bottom:10px}.dialog p{color:var(--n600)}.dialog.dark p{color:#d2cad8}.dialog-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:18px}.dialog-actions .btn{flex:1}.toast{position:fixed;left:50%;bottom:24px;transform:translateX(-50%);background:var(--vast);color:#fff;padding:11px 18px;border-radius:22px;z-index:30;font-size:14px;box-shadow:0 8px 30px #0004;animation:toastIn .2s ease}#toast:empty{display:none}.black{background:#000;color:#999;align-items:center;justify-content:center;text-align:center}.black .logo{background:#222}.black .logo i{background:#aaa}.app-black{background:#000}.code-badge{display:inline-block;border-radius:7px;background:#eee9f3;color:var(--p800);padding:4px 8px;font-size:11px;font-weight:650;margin:3px}.feature-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:10px}.feature-grid .card{margin:0}.stat{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.stat .card{text-align:center;margin:0}.stat strong{display:block;font-size:24px;color:var(--p800)}
.guide{margin:0 0 8px;padding-left:22px;display:grid;gap:14px}.guide li p{margin:0 0 8px}.demo-chip{display:inline-flex;align-items:center;gap:14px;background:#fff;border:1px solid var(--line);border-radius:10px;padding:8px 12px;font-size:13px;box-shadow:0 2px 8px #312d3710}.demo-chip .toggle{width:34px;height:20px}.demo-chip .toggle::after{width:14px;height:14px}.demo-chip .toggle.on::after{transform:translateX(14px)}button.list-row{width:100%;background:none;border:0;border-bottom:1px solid var(--line);text-align:left;color:inherit}.status{font-size:14px;color:var(--n600);margin:14px 0 0}.status.ok{color:#1d7a4a;font-weight:600}
@keyframes screenIn{from{opacity:0;transform:translateX(8px)}to{opacity:1;transform:none}}@keyframes fade{from{opacity:0}to{opacity:1}}@keyframes dialogIn{from{opacity:0;transform:translateY(18px) scale(.98)}to{opacity:1;transform:none}}@keyframes toastIn{from{opacity:0;transform:translate(-50%,8px)}to{opacity:1;transform:translate(-50%,0)}}@keyframes spin{to{transform:rotate(360deg)}}@keyframes shimmer{from{background-position:120% 0}to{background-position:-120% 0}}@keyframes bubbleIn{from{opacity:0;transform:scale(.85)}to{opacity:1;transform:scale(1)}}@keyframes wave{from{transform:scaleY(.55)}to{transform:scaleY(1.15)}}@keyframes spoke{0%,100%{opacity:.2;transform:scale(.7) rotate(0)}50%{opacity:1;transform:scale(1.25) rotate(90deg)}}
@media(max-width:900px){#app{display:block}#tone-sidebar{display:none}#phone{width:100%;box-shadow:none}#screen{padding:22px 20px}}
@media(min-width:901px){#phone{margin:24px auto;min-height:calc(100dvh - 48px);border-radius:28px;overflow:hidden}#phone-status{padding-top:12px}.fab{bottom:100px}}
.license{border:1px solid var(--line);border-radius:14px;background:#fff;margin:10px 0;padding:0 14px}.license summary{display:flex;flex-direction:column;gap:2px;padding:14px 0;cursor:pointer;list-style:none}.license summary small{color:var(--n500)}.license-text{white-space:pre-wrap;word-break:break-word;font-size:11px;line-height:1.45;max-height:50dvh;overflow:auto;margin:0 0 14px;color:var(--n700,#555)}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}
body.native #tone-sidebar,body.native #phone-status,body.native .video-card video,body.native .video-card:not(.overlay-text),body.native .dots{display:none}body.native #app{display:block}body.native #phone{width:100%;margin:0;min-height:100dvh;border-radius:0;box-shadow:none}body.native #progress{margin-top:14px}body.native .video-card.overlay-text{background:none;box-shadow:none}body.native .video-card.overlay-text::after{position:static;display:block;color:var(--n850);text-shadow:none;font-size:36px}

/* ===================================================================================
 * Video-style layer (2026-11-05, decision 21, own code). Overrides the base rules above.
 * Flat, as in the reference recording (replica/design/video-style.md): no glass, no blur,
 * no gradients; lavender primary with a dark outline, white cards with a hairline,
 * 5 thin progress stripes, purple toggles. Motion: 150–250 ms ease-out fades only.
 * =================================================================================== */
:root{--line:#e0dde0;--line-strong:#c9c6cc;--ink:#302c37;--work:#efeef1;--work-2:#dcdadf;--warm:#fff8d6;--warm-line:#e2c98a;--cream:#fefde9;--sample:#f6f5fc;--r:16px;--small-r:12px;--ease-out:cubic-bezier(.2,0,0,1);--dur:200ms}
html,body{background:var(--n50);-webkit-font-smoothing:antialiased}
#phone{background:var(--n50)}
/* Main app (bottom nav visible): the grey workspace tint behind white blocks */
#phone:has(>#bottom-nav:not([hidden])){background:var(--work)}

/* Type */
h1{font-weight:400;font-size:34px;line-height:1.12;letter-spacing:-.01em;color:var(--n850)}
h2{font-weight:600;font-size:20px}
.headline{margin:22px 0 12px}
.subtitle{color:var(--gray);font-size:16px;line-height:1.45;margin-bottom:24px}
small,.muted{color:var(--n600)}
.hint,.range-labels,.empty,.license summary small{color:var(--n600)}
.top-row{margin-bottom:8px;min-height:40px}
.back{font-size:28px;line-height:1;color:var(--n850)}
.cancel{font-size:15px;font-weight:500;color:var(--n850)}
.link-btn{color:var(--p800)}

/* Progress: 5 thin flat stripes */
#progress{gap:6px;margin:12px 16px 0}
#progress span{height:3px;border-radius:0;background:var(--line)}
#progress i{border-radius:0;background:var(--p800);transition:width 250ms var(--ease-out)}

/* Buttons: full width, ~52px, radius 8, dark outline on lavender / white */
.actions{gap:12px;margin-top:20px}
.btn{border:1.5px solid transparent;border-radius:8px;min-height:52px;padding:13px 18px;font-size:16px;font-weight:600;line-height:1.2;box-shadow:none;transition:background-color 150ms var(--ease-out),opacity 150ms var(--ease-out)}
.btn:active:not(:disabled){transform:none;opacity:.82}
.btn.primary{background:var(--pink);border-color:var(--ink);color:var(--ink)}
.btn.primary:hover{background:#e3d2ff}
.btn.dark{background:var(--vast);border-color:var(--vast);color:#fff}
.btn.secondary{background:#fff;border-color:var(--ink);color:var(--ink)}
.btn.ghost{background:transparent;color:var(--n600);font-weight:500}
.btn.danger{background:#ffe4e7;border-color:#c62f45;color:#a32938}
.btn.small{min-height:36px;padding:7px 12px;font-size:13px;border-radius:8px;border-width:1px}
button:disabled{opacity:.45}

/* Cards and options: white, hairline, radius 12; selected = dark 1.5px border + purple radio */
.card{background:#fff;border:1px solid var(--line);border-radius:var(--small-r);padding:16px;margin:10px 0;box-shadow:none;transition:border-color 150ms var(--ease-out),background-color 150ms var(--ease-out)}
.card.selected{border:1.5px solid var(--n850);padding:15.5px}
.card h3{font-size:16px;font-weight:650;margin-bottom:6px;color:var(--n850)}
.card h3:only-child{margin:0;font-weight:500;font-size:15px}
.card p{color:var(--gray);font-size:14px;line-height:1.45}
.card .check{width:22px;height:22px;border:1.5px solid var(--gray);border-radius:50%;color:transparent;font-size:0;margin-left:12px}
.card.selected .check{border:2px solid var(--p800);background:var(--p800);box-shadow:inset 0 0 0 3.5px #fff;color:transparent}
/* Data choice: the chosen card is the warm notice, as in the recording */
.card.selected[data-action="privacy"]{background:var(--warm)}
.cards{gap:12px}
.cards>.card{margin:0}
.list>.card{margin:0}
.list:has(>.card){gap:10px}

/* Notices: warm cream with a darker hairline */
.notice{background:var(--warm);border:1px solid var(--warm-line);border-radius:var(--small-r);padding:14px 16px;font-size:14px;color:var(--n850)}
.notice p{margin:4px 0 0;color:var(--gray)}
.notice.error{background:#ffe4e7;border-color:#f0b4bf}
.notice.success{background:#e7f8ef;border-color:#a6dfc0}

/* Settings lists: each row its own white block; section labels small uppercase */
.list:has(>.list-row){gap:8px}
.list-row,button.list-row{background:#fff;border:0;border-radius:var(--small-r);padding:16px}
.list-row:last-child,button.list-row:last-child{border:0}
button.list-row{transition:background-color 150ms var(--ease-out)}
button.list-row:active{background:#f4f2f6}
.list-row strong{font-size:16px;font-weight:600;color:var(--n850)}
.list-row small{margin-top:3px;font-size:14px;line-height:1.4;color:var(--n600)}
.chevron{color:var(--n850);font-size:24px;line-height:1}
h3.muted{font-size:13px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--n600);margin:26px 4px 10px!important}
.app-preview{background:#fff;border:1px solid var(--line);border-radius:var(--small-r);box-shadow:none}
.app-preview>p{background:var(--sample);border-radius:10px;padding:12px 14px;margin:0;color:var(--n850)}
.legal,.license{background:#fff;border:1px solid var(--line);border-radius:var(--small-r)}

/* Toggles: purple on, light grey off, lavender when disabled */
.toggle{width:52px;height:32px;border-radius:16px;background:#d6d3d9;transition:background-color 200ms var(--ease-out)}
.toggle::after{width:24px;height:24px;left:4px;top:4px;box-shadow:0 1px 2px #0002;transition:transform 200ms var(--ease-out)}
.toggle.on{background:var(--p800)}
.toggle.on::after{transform:translateX(20px)}
.toggle:disabled{opacity:1;background:#f3e8fb}
.demo-chip{background:#fff;border:1px solid var(--line);border-radius:8px;box-shadow:none;padding:10px 14px;font-weight:500}

/* Range: thick purple fill, grey rest, slim vertical thumb */
.range{-webkit-appearance:none;appearance:none;height:40px;background:transparent;margin:6px 0}
.range::-webkit-slider-runnable-track{height:14px;border-radius:7px;background:linear-gradient(var(--p800),var(--p800)) 0 0/var(--fill,50%) 100% no-repeat,#d6d6d8}
.range::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;width:5px;height:40px;margin-top:-13px;border-radius:3px;background:var(--p800);border:0}
.range::-moz-range-track{height:14px;border-radius:7px;background:#d6d6d8}
.range::-moz-range-progress{height:14px;border-radius:7px;background:var(--p800)}
.range::-moz-range-thumb{width:5px;height:40px;border:0;border-radius:3px;background:var(--p800)}
.range-labels{align-items:baseline;font-size:14px}
.range-labels span:first-child{font-size:13px}.range-labels span:last-child{font-size:22px}
.range-labels strong{color:var(--n850)}

/* The Tone bubble: small lavender rounded square, dark glyph */
.bubble{background:var(--pink);color:var(--n850);border-radius:12px;min-width:44px;min-height:44px;padding:10px 14px;box-shadow:0 4px 14px #312d371a}
.bubble.recording{background:var(--p800);color:#fff}
.bubble.processing{background:#5c4b68;color:#fff}
.bubble.offline{background:var(--n600);color:#fff}
.bubble.dot{min-width:0;min-height:0;padding:9px;border-radius:50%}

/* Tabs: one segmented control */
.tabs{gap:0;padding:0;border:1px solid var(--work-2);border-radius:24px;background:var(--work);overflow:auto}
.tab{flex:1;border-radius:0;padding:10px 12px;color:var(--n850);font-weight:500;border-right:1px solid var(--work-2)}
.tab:last-child{border-right:0}
.tab.active{background:var(--work-2);color:var(--n850);font-weight:600}

/* Chips (languages): white; selected = cream with a dark outline and ✓ */
.chip{background:#fff;border:1px solid var(--line-strong);border-radius:8px;padding:10px 14px;color:var(--n850)}
.chip.selected{background:var(--cream);border:1.5px solid var(--n850);padding:9.5px 13.5px;font-weight:500}

/* Fields */
.field input,.field textarea,.field select{background:#fff;border:1px solid var(--line-strong);border-radius:8px;padding:14px;color:var(--n850)}
.field input:focus,.field textarea:focus,.field select:focus{border-color:var(--p800);outline:0}
.mock-input{border:1px solid var(--line-strong);border-radius:var(--small-r)}
.mock-input.focused{border-color:var(--p800);box-shadow:none}
.code-badge{background:var(--p400);border-radius:6px}

/* Hero (value cards, native): a soft lavender panel with the serif line */
body.native .video-card.overlay-text{flex:1;min-height:54dvh;margin:4px 0 16px;padding:32px 24px;border-radius:var(--r);background:var(--dawn);box-shadow:none}
body.native .video-card.overlay-text::after{font-size:34px;line-height:1.15;font-weight:400}
.video-card{box-shadow:none;border-radius:var(--r)}

/* Bottom nav: flat on the workspace tint; active icon in a grey pill */
#bottom-nav{background:var(--work);border-top:0;padding:6px 8px calc(10px + env(safe-area-inset-bottom))}
#bottom-nav button{gap:4px;color:var(--n600);font-size:12px;font-weight:500;min-width:64px}
#bottom-nav button span{display:grid;place-items:center;width:56px;height:30px;border-radius:15px;font-size:19px;transition:background-color 150ms var(--ease-out)}
#bottom-nav button.active{color:var(--n850);font-weight:600}
#bottom-nav button.active span{background:var(--work-2)}

/* Dialog, toast, FAB */
.dialog-backdrop{background:#1a1a1a73}
.dialog{border-radius:16px;box-shadow:0 12px 40px #312d3726;animation:fade 200ms var(--ease-out)}
.dialog-actions .btn{min-height:48px}
.toast{border-radius:10px;animation:fade 200ms var(--ease-out)}
.fab{background:var(--vast);box-shadow:0 6px 18px #1a1a1a33}

/* Motion: one quick fade/slide per screen change, a short fade-up for its blocks */
@keyframes screenEnter{from{opacity:0;transform:translateX(12px)}to{opacity:1;transform:none}}
@keyframes screenBack{from{opacity:0;transform:translateX(-12px)}to{opacity:1;transform:none}}
@keyframes rise{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}
#screen{animation:none}
#screen.enter{animation:screenEnter 220ms var(--ease-out) both}
#screen.enter.back{animation-name:screenBack}
#screen.enter:not(.settled)>*{animation:rise 200ms var(--ease-out) both;animation-delay:calc(var(--i,0) * 30ms)}
#screen.enter>:nth-child(2){--i:1}#screen.enter>:nth-child(3){--i:2}#screen.enter>:nth-child(n+4){--i:3}
#screen.enter .spacer{animation:none!important}
@media(prefers-reduced-motion:reduce){
  #screen.enter,#screen.enter *,.dialog,.toast{animation:none!important}
  #progress i,.toggle,.toggle::after,.btn,.card,button.list-row{transition:none!important}
}

/* Main-app sub-screens (Settings, bubble size/opacity…): a compact bar with ←, a centred title and Reset on the right */
.back{font-size:0}.back::before{content:'←';font-size:24px;line-height:1}
#phone:has(>#bottom-nav:not([hidden])) .top-row:has(>.back) .cancel{display:none}
#phone:has(>#bottom-nav:not([hidden])) .top-row:has(>.back)+.headline{margin:-48px 56px 18px;font:600 20px/40px Figtree,sans-serif;letter-spacing:0;text-align:center;pointer-events:none;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#phone:has(>#bottom-nav:not([hidden])) .headline+.top-row:has(>.link-btn:only-child){justify-content:flex-end;margin:-58px 0 18px;pointer-events:none}
#phone:has(>#bottom-nav:not([hidden])) .headline+.top-row>.link-btn:only-child{pointer-events:auto}
#phone:has(>#bottom-nav:not([hidden])) .top-row:has(>.back)+.headline:has(+.top-row>.link-btn:only-child){margin-inline:84px;font-size:18px}

/* ===================================================================================
 * Demo fixes (2026-11-05, own code): Tone "T" mark, one active tab, wrapping sub-screen titles,
 * value cards with page dots, static "How it works" drawing, left-aligned "All set", side drawer.
 * =================================================================================== */
/* Tone's mark: the "T" glyph on a lavender rounded square (replaces the 4-bar mark) */
.logo{display:inline-grid;place-items:center;flex:none;width:34px;height:34px;border-radius:10px;background:var(--pink);border:1px solid #d9c8f5;gap:0}
.logo svg{width:62%;height:62%;fill:var(--n850)}
.logo.xl{width:96px;height:96px;border-radius:26px}
.black .logo{background:var(--pink)}.black .logo svg{fill:var(--n850)}
#tone-sidebar .logo{background:var(--pink)}
.splash-name{font:400 34px/1.1 Garamond,serif;margin:18px 0 0;color:var(--n850)}
/* The dot preview: a 44px lavender square with the glyph; recording states keep their label */
.bubble::before{content:'';width:16px;height:16px;flex:none;background:currentColor;-webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='10 10.5 28 28'%3E%3Cpath d='M12 13h24v5h-9.5v18h-5V18H12z'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='10 10.5 28 28'%3E%3Cpath d='M12 13h24v5h-9.5v18h-5V18H12z'/%3E%3C/svg%3E") center/contain no-repeat}
.bubble.idle{width:44px;height:44px;min-width:44px;padding:0;border:1px solid #d9c8f5}
.bubble.idle::before{width:22px;height:22px}
.bubble.idle.dot{width:22px;height:22px;min-width:0;min-height:0;border-radius:50%}
.bubble.idle.dot::before{display:none}
.bubble.recording::before,.bubble.processing::before{display:none}

/* Sub-screen titles in the compact bar wrap instead of being cut («Размер точки T…») */
#phone:has(>#bottom-nav:not([hidden])) .top-row:has(>.back)+.headline{white-space:normal;overflow:visible;text-overflow:clip;display:flex;align-items:center;justify-content:center;min-height:40px;line-height:1.15}

/* App bar: ☰ on the left, then the mark and the name (as in the reference) */
.app-bar{justify-content:flex-start;gap:10px}
.app-bar strong{font-size:17px}
.menu-btn{border:0;background:none;font-size:22px;line-height:1;padding:8px 6px;color:var(--n850)}
.usage-card{display:grid;gap:2px;background:#fff;border:1px solid var(--line);border-radius:var(--small-r);padding:14px 16px}
.usage-card strong{font:400 28px/1.15 Garamond,serif;color:var(--n850)}

/* Value cards: three lavender cards in a snap row, page dots under them */
.vp-track{display:flex;gap:12px;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none;margin:6px -20px 0;padding:0 20px;scroll-padding:0 20px}
.vp-track::-webkit-scrollbar{display:none}
.vp-card{flex:0 0 100%;scroll-snap-align:start;display:flex;flex-direction:column;justify-content:space-between;gap:24px;min-height:min(56dvh,480px);background:var(--dawn);border-radius:var(--r);padding:30px 24px}
.vp-caption{order:-1;margin:0;font:400 34px/1.15 Garamond,serif;color:var(--n850)}
.vp-art .art{width:100%;height:auto;display:block}
.vp-dots{display:flex;justify-content:center;gap:8px;margin:16px 0 0}
.vp-dots i{width:6px;height:6px;border-radius:50%;background:var(--line-strong);transition:background-color 150ms var(--ease-out)}
.vp-dots i.active{background:var(--p800)}

/* "How it works": a static drawing of the dot beside a chat's message field */
.how-art{background:#fff;border:1px solid var(--line);border-radius:var(--r);padding:14px}
.how-art .art{width:100%;height:auto;display:block}
.how-legend{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}
.how-legend span{background:var(--p300);border-radius:8px;padding:7px 10px;font-size:13px;color:var(--n850)}

/* "All set": left aligned, a numbered list and the keyboard drawing */
.keyboard-art{display:block;width:100%;max-width:340px;height:auto;margin:8px 0 4px}

/* Side drawer menu (from the left), flat */
.drawer-backdrop{position:fixed;inset:0;background:#1a1a1a59;z-index:20;animation:fade 200ms var(--ease-out)}
.drawer{position:fixed;top:0;bottom:0;left:0;z-index:21;width:min(84vw,320px);overflow:auto;background:var(--n50);display:flex;flex-direction:column;gap:12px;padding:calc(18px + env(safe-area-inset-top)) 16px calc(18px + env(safe-area-inset-bottom));box-shadow:0 12px 40px #312d3726;animation:drawerIn 220ms var(--ease-out)}
.drawer-head{display:flex;align-items:center;gap:10px;min-height:44px}
.drawer-head strong{font-size:17px}
.drawer-close{margin-left:auto;border:0;background:none;font-size:26px;line-height:1;padding:6px 8px;color:var(--n850)}
.drawer-list{display:grid;gap:8px}
.drawer-row{display:grid;gap:3px;width:100%;text-align:left;background:#fff;border:1px solid var(--line);border-radius:var(--small-r);padding:14px 16px;color:inherit}
.drawer-row strong{font-size:16px;font-weight:600;color:var(--n850)}
.drawer-row small{font-size:13px;color:var(--n600)}
.drawer-row:active{background:#f4f2f6}
@keyframes drawerIn{from{transform:translateX(-24px);opacity:0}to{transform:none;opacity:1}}
@media(prefers-reduced-motion:reduce){.drawer,.drawer-backdrop{animation:none!important}.vp-track{scroll-behavior:auto}}
/* With «Сбросить» on the right, the centred title keeps a gap to it and wraps (Прозрачность точки) */
#phone:has(>#bottom-nav:not([hidden])) .top-row:has(>.back)+.headline:has(+.top-row>.link-btn:only-child){margin-inline:96px;font-size:17px}

/* Decision 24: the dot is the mascot image (assets/mascot_<state>.png), no lavender square or glyph behind it. */
.bubble.mascot-dot{width:52px;height:52px;min-width:48px;min-height:48px;padding:0;background:none;border:0;border-radius:0;box-shadow:none}
.bubble.mascot-dot::before{display:none}
.bubble.mascot-dot.dot{width:28px;height:28px;min-width:0;min-height:0}
.mascot{display:block;width:100%;height:100%;object-fit:contain;user-select:none;-webkit-user-drag:none}
.mascot.legend{display:inline-block;width:22px;height:22px;vertical-align:-6px;margin-right:6px}
.mascot.row-icon{width:36px;height:36px;flex:none}

/* Decision 23: «Агент настроит остальное» — a flat picture of the setup's floating pills (video-style.md). */
.setup-preview{display:grid;justify-items:end;gap:8px;background:#efeef1;border-radius:16px;padding:18px 14px;margin:0 0 20px}
.setup-q{display:flex;align-items:flex-end;gap:6px;max-width:100%}
.setup-q p{margin:0;background:#fff;border:1px solid var(--line);border-radius:18px;padding:10px 14px;font:400 18px/1.15 Garamond,serif;color:var(--n850);max-width:220px}
.mascot.setup-mascot{width:44px;height:44px;flex:none}
.setup-opts{display:flex;gap:8px}
.setup-pill{display:inline-flex;align-items:center;min-height:38px;padding:0 16px;border-radius:999px;background:#fff;border:1px solid var(--line);font-weight:700;font-size:13px;color:var(--n850)}
.setup-pill.primary{background:var(--pink);border-color:#d9c8f5;color:var(--n800)}
.setup-step{display:inline-flex;align-items:center;gap:10px;background:#fff;border:1px solid var(--line);border-radius:999px;padding:4px 4px 4px 14px;font-size:13px;color:var(--n850)}
.setup-stop{background:#c62f45;color:#fff;border-radius:999px;padding:7px 14px;font-weight:700}
.mascot.done-mascot{width:120px;height:120px;margin:0 auto}
/* W2 (2026-11-06): Telegram sign-in, mandatory setup, feature tour, practice, insights (video style: flat, hairlines). */
.mascot.hero-mascot{width:112px;height:112px;margin:0 auto 6px}
.mascot.row-mascot{width:64px;height:64px;margin:0 auto}
.tour-stage{animation:fade 220ms var(--ease-out)}
.tour-phone{position:relative;background:#fff;border:1px solid var(--line);border-radius:20px;height:340px;overflow:hidden;padding:12px 14px}
.tour-head{display:flex;align-items:center;gap:10px;border-bottom:1px solid var(--line);padding-bottom:10px;font-size:15px}
.tour-avatar{width:30px;height:30px;border-radius:50%;background:var(--dawn)}
.tour-msgs{display:grid;gap:8px;padding-top:12px}
.msg{margin:0;max-width:72%;padding:9px 12px;border-radius:14px;font-size:14px;line-height:1.3}
.msg.in{background:#efeef1;justify-self:start}
.msg.out{background:var(--pink);justify-self:end}
.tour-composer{position:absolute;left:12px;right:12px;bottom:12px;display:flex;align-items:center;justify-content:space-between;border:1px solid var(--line);border-radius:999px;padding:10px 14px;font-size:14px;color:var(--n600);background:#fff;transition:border-color 200ms var(--ease-out)}
.tour-composer.filled{color:var(--n850);border-color:var(--p800)}
.tour-composer b{color:var(--n500)}
.tour-composer b.send-hint{color:var(--p800);animation:pulseHint 1s var(--ease-out) 2}
.tour-mascot{position:absolute;right:14px;bottom:66px;width:58px;height:58px}
.tour-mascot.tap::after{content:'';position:absolute;inset:-8px;border-radius:50%;border:2px solid var(--p800);opacity:0;animation:tapRing 1.2s var(--ease-out) 2}
.tour-mascot.rec::after{content:'● 0:03';position:absolute;right:66px;top:16px;white-space:nowrap;background:var(--vast);color:#fff;border-radius:999px;padding:6px 12px;font-size:12px}
.tour-float{position:absolute;right:80px;bottom:64px;display:grid;justify-items:end;gap:8px;animation:fade 200ms var(--ease-out)}
.tour-float .setup-q p{max-width:190px;font-size:17px}
.tour-step{position:absolute;left:14px;top:56px}
.reply-pill{display:block;max-width:220px;background:var(--pink);border:1px solid #d9c8f5;border-radius:16px;padding:9px 13px;font-size:13px;color:var(--n800)}
.reply-pill.picked{background:var(--p800);border-color:var(--p800);color:#fff}
.input-pill{display:inline-flex;align-items:center;gap:6px;background:#fff;border:1px solid var(--line);border-radius:999px;padding:9px 16px;font-size:14px}
.input-pill i{width:1.5px;height:16px;background:var(--p800);animation:blink 1s steps(1) infinite}
.tour-cap{font:400 22px/1.2 Garamond,serif;color:var(--n850);text-align:center;margin:16px 0 0;min-height:54px}
.persona-card{display:flex;align-items:center;gap:14px}
.persona-avatar{flex:none;width:48px;height:48px;border-radius:50%;background:var(--dawn);display:grid;place-items:center;font:400 24px Garamond,serif;color:var(--p800)}
.insight-list .list-row{padding:12px 16px}
.source{display:inline-block!important;margin-top:6px!important;font-size:12px!important;color:var(--p800)!important;background:var(--p300);border-radius:999px;padding:2px 8px}
.chip.selected{background:var(--p800);border-color:var(--p800);color:#fff}
@keyframes tapRing{0%{opacity:.8;transform:scale(.7)}100%{opacity:0;transform:scale(1.25)}}
@keyframes pulseHint{50%{transform:scale(1.25)}}
@keyframes blink{50%{opacity:0}}
@media(prefers-reduced-motion:reduce){.tour-mascot.tap::after,.tour-composer b.send-hint,.input-pill i{animation:none}}

/* ===================================================================================
 * C7 (2026-11-06, own code): video-style polish, mascot states, empty/loading/error states,
 * people memory («Изученные чаты» + person), the «Что агент узнал» showcase.
 * =================================================================================== */
/* Buttons radius 10 (video-style.md: 10–12); back target ≥44px */
.btn{border-radius:10px}.btn.small{border-radius:8px}
.back{min-width:44px;min-height:44px;display:inline-grid;place-items:center;padding:0;margin-left:-10px}
/* Consent: one scroll (the page), no box scrolling inside the page */
.legal{max-height:none;overflow:visible}
/* Mascot placements */
.mascot.side-mascot{width:72px;height:72px;margin:6px 0 -6px -6px}
.notice.with-mascot{display:flex;align-items:center;gap:12px}
.notice.with-mascot p{margin:0}
.mascot.note-mascot{width:44px;height:44px;flex:none}
/* Shared empty / loading / error block */
.state-block{display:grid;justify-items:center;text-align:center;gap:4px;padding:28px 12px 8px}
.state-block.compact{padding:12px 8px}
.state-block .muted{max-width:300px;margin:4px 0 0;font-size:15px;line-height:1.45}
.state-block .actions{width:100%;margin-top:18px}
.state-title{font:400 26px/1.15 Garamond,serif;margin:6px 0 0;color:var(--n850)}
.empty .row-mascot{margin-bottom:8px}
.skeleton-list{display:grid;gap:8px}
.skeleton-row{display:flex;align-items:center;gap:14px;background:#fff;border-radius:var(--small-r);padding:16px}
.skeleton-row i{width:44px;height:44px;border-radius:50%;background:var(--work)}
.skeleton-row span{flex:1;display:grid;gap:8px}
.skeleton-row b{display:block;height:12px;border-radius:6px;background:var(--work);width:40%}
.skeleton-row b+b{width:75%}
/* People list */
.person-row{display:flex;align-items:center;gap:14px;width:100%;text-align:left;background:#fff;border:0;border-radius:var(--small-r);padding:14px 16px;color:inherit;min-height:72px;transition:background-color 150ms var(--ease-out)}
.person-row:active{background:#f4f2f6}
.person-row .content{flex:1;display:grid;gap:2px;min-width:0}
.person-row strong{font-size:16px;font-weight:600}
.person-row small{font-size:13px;color:var(--n600)}
.persona-avatar{width:44px;height:44px}
.mini-chips{display:flex;flex-wrap:wrap;gap:6px;margin-top:6px}
.mini-chips span{background:var(--p300);color:var(--n800);border-radius:999px;padding:3px 9px;font-size:12px;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
/* Facts as chips with their source */
.fact-chips{display:flex;flex-wrap:wrap;gap:8px}
.fact-chip{display:grid;gap:4px;background:#fff;border:1px solid var(--line);border-radius:var(--small-r);padding:10px 12px;font-size:15px;line-height:1.3;color:var(--n850);max-width:100%}
.fact-chip.like{background:var(--p300);border-color:#e3cdf5}
.fact-chip .source{margin:0!important;justify-self:start}
.source{background:var(--work)!important;color:var(--n800)!important}
.source.profile{background:var(--pink)!important;color:var(--p800)!important}
.insight-list .list-row{align-items:flex-start;gap:12px}
.num{flex:none;width:24px;height:24px;border-radius:50%;background:var(--p800);color:#fff;display:grid;place-items:center;font-size:13px;font-weight:700}
.quote-list{display:grid;gap:8px}
.quote{margin:0;background:#fff;border:1px solid var(--line);border-radius:16px 16px 16px 4px;padding:12px 14px;font-size:15px;color:var(--n850)}
.quote small{display:block;margin-top:4px;font-size:12px}
/* «Что агент узнал» hero: the lavender panel of the reference with the serif line */
.insight-hero{position:relative;background:var(--dawn);border-radius:var(--r);padding:22px 20px 20px;margin:4px 0 6px}
.insight-hero .hero-mascot{position:absolute;right:12px;top:10px;width:96px;height:96px;margin:0}
.insight-hero .eyebrow{margin:0 104px 0 0;font-size:13px;font-weight:600;letter-spacing:.04em;text-transform:uppercase;color:var(--p800)}
.insight-hero .headline{margin:8px 104px 10px 0}
.insight-hero .subtitle{margin:0 0 12px;font-size:15px;color:var(--n800)}
.goal-pill{display:inline-block;margin:0 0 12px;background:#fff;border-radius:999px;padding:6px 12px;font-size:13px;font-weight:600;color:var(--n800)}
.warmth{background:#fff;border-radius:var(--small-r);padding:12px 14px}
.warmth-head{display:flex;justify-content:space-between;align-items:baseline;font-size:13px;color:var(--n600);margin-bottom:8px}
.warmth-head strong{font:400 20px/1 Garamond,serif;color:var(--p800)}
.warmth-track{height:6px;border-radius:3px;background:var(--work);overflow:hidden}
.warmth-track i{display:block;height:100%;border-radius:3px;background:var(--p800)}
/* Onboarding v3: «О вас» option rows (video style: white rows with a hairline, radio on the right, Next below). */
.card.option{display:flex;align-items:center;gap:12px;padding:14px 16px;min-height:52px}
.card.option.selected{padding:13.5px 15.5px}
.card.option h3{order:1;margin:0;font-weight:500;font-size:15px}
.card.option .check{order:2;float:none;margin-left:auto;flex:none}
.btn:disabled{opacity:.45;pointer-events:none}
/* Decision 31 «Мой стиль» (video style: white card with a hairline, lavender icon tile) */
.style-icon{width:36px;height:36px;flex:none;display:grid;place-items:center;border-radius:10px;background:var(--pink,#eaddff);color:var(--p800,#6c358c);font-size:20px}
.style-card{display:grid;gap:12px;text-align:left;cursor:default}
.style-card p{margin:0;color:var(--n850)}
.style-card .style-extra{color:var(--gray)}
.style-card .style-summary{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.style-more{display:grid;gap:10px}.style-more>summary{list-style:none;display:flex;align-items:center;gap:6px;min-height:44px;cursor:pointer;font-size:14px;font-weight:600;color:var(--n800)}
.style-more>summary::-webkit-details-marker{display:none}.style-more>summary .chevron{transition:transform var(--dur) var(--ease-out)}.style-more[open]>summary .chevron{transform:rotate(90deg)}
@media (prefers-reduced-motion: reduce){.style-more>summary .chevron{transition:none}}

/* Decision 33: «Войти через Telegram» styled like Telegram's own login button (third_party/telegram-login/origin.json):
   #119AF5, pressed #1090E5, white paper-plane mark; height and radius follow our buttons (pill). */
.btn.tg-login{display:flex;align-items:center;justify-content:center;gap:8px;background:#119AF5;border-color:#119AF5;color:#fff;border-radius:26px}
.btn.tg-login:active:not(:disabled){background:#1090E5;border-color:#1090E5;opacity:1}
.btn.tg-login::before{content:"";width:22px;height:22px;flex:none;background:no-repeat center/22px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 22 22' fill='none'%3E%3Cpath d='M2.81376 10.5943C7.36914 8.61002 10.406 7.30175 11.9245 6.66971C16.265 4.86489 17.1658 4.55143 17.7542 4.54094C17.8836 4.53874 18.1716 4.57072 18.3596 4.72281C18.5158 4.85097 18.5598 5.0243 18.5818 5.14588C18.6013 5.26745 18.6282 5.54454 18.6062 5.76083C18.3719 8.23138 17.3539 14.2266 16.8363 16.9938C16.619 18.1647 16.1869 18.5572 15.7695 18.5955C14.8613 18.679 14.1728 17.996 13.294 17.42C11.9196 16.5185 11.1433 15.9575 9.80793 15.0779C8.26505 14.0613 9.26594 13.5025 10.1448 12.5895C10.3743 12.3505 14.373 8.71426 14.4487 8.38445C14.4585 8.34319 14.4683 8.18939 14.3755 8.10834C14.2852 8.02705 14.1508 8.05488 14.0532 8.07685C13.914 8.1081 11.7193 9.56015 7.4618 12.4328C6.83928 12.861 6.27536 13.0697 5.76758 13.0587C5.21097 13.0468 4.13689 12.7433 3.3386 12.484C2.3621 12.166 1.5833 11.9977 1.65166 11.4575C1.68583 11.1763 2.07406 10.8884 2.81376 10.5943Z' fill='white'/%3E%3C/svg%3E")}
.btn.tg-bot{min-height:40px;font-size:14px}
/* Run 18 UX review: the agent status next to the Tone logo on Home (flat, hairline, video-style.md). */
.agent-badge{margin-left:auto;display:inline-flex;align-items:center;gap:6px;min-height:32px;padding:4px 10px;border:1px solid var(--line);border-radius:16px;background:#fff;color:var(--n600);font-size:13px;font-weight:500;white-space:nowrap}
.agent-badge i{width:8px;height:8px;border-radius:50%;background:#1d9a5a;flex:none}
.agent-badge.off{color:var(--n850);cursor:pointer}.agent-badge.off i{background:#c62f45}
.agent-badge .chevron{font-size:16px;line-height:1;margin-left:-2px}
button.agent-badge{min-height:36px}
/* Run 18 UX review: the practice insights' sent replies, folded under «Отправленные ответы (N)». */
.sent-replies{margin-top:20px;border-top:1px solid var(--line);padding-top:4px}
.sent-replies summary{list-style:none;display:flex;align-items:center;justify-content:space-between;min-height:48px;cursor:pointer;font-size:15px;font-weight:600;color:var(--n800)}
.sent-replies summary::-webkit-details-marker{display:none}
.sent-replies summary .chevron{transition:transform var(--dur) var(--ease-out)}
.sent-replies[open] summary .chevron{transform:rotate(90deg)}
.sent-replies .quote-list{padding-bottom:8px}
@media (prefers-reduced-motion: reduce){.sent-replies summary .chevron{transition:none}}

/* Spec 2026-11-07 §3 «Библиотека стиля»: flat white rows with a hairline, lavender accents (replica/design/video-style.md) */
.lib-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:26px 0 10px;scroll-margin-top:16px}
.lib-head h3.muted{margin:0 4px!important}
.lib-add{min-height:36px}
.lib-list{gap:8px}
.lib-row{display:flex;align-items:flex-start;gap:12px;background:#fff;border:1px solid var(--line);border-radius:var(--small-r);padding:12px 8px 12px 16px}
.lib-row .content{flex:1;min-width:0}
.lib-row p{margin:0}
.lib-term{display:flex;flex-wrap:wrap;align-items:center;gap:8px;font-size:17px;color:var(--n850)}
.lib-meaning{color:var(--gray);font-size:15px;line-height:1.35;margin-top:2px!important}
.lib-meaning span{color:var(--p800)}
.lib-example{color:var(--n600);font-size:14px;font-style:italic;margin-top:4px!important;overflow-wrap:anywhere}
.lib-badge{display:inline-block;background:var(--warm);border:1px solid var(--warm-line);color:#6b5520;border-radius:999px;padding:1px 8px;font-size:12px;font-weight:600}
.lib-fact{font-size:15px;line-height:1.35;color:var(--n850);overflow-wrap:anywhere}
.lib-meta{font-size:12px;color:var(--n600);margin-top:4px!important}
.lib-source{background:var(--work);color:var(--n800);border-radius:999px;padding:1px 8px}
.lib-source.mira{background:var(--pink);color:var(--p800)}
.lib-actions{display:flex;align-items:center;gap:2px;flex:none}
.lib-actions .link-btn{background:none;border:0;min-height:44px;padding:0 8px;font-size:14px;font-weight:600}
.icon-btn{width:44px;height:44px;display:grid;place-items:center;border:0;border-radius:10px;background:none;color:var(--n600);font-size:20px}
.icon-btn:active{background:var(--work)}
.lib-none{margin:4px 4px 0;font-size:14px}
.lib-note{color:var(--n600);font-size:14px;margin:0 4px 10px}
.mira-card{display:flex;align-items:center;gap:14px;background:var(--p300);border-color:#e3cdf5;margin:0}
.mira-card .row-mascot{width:52px;height:52px;margin:0;flex:none}
.mira-card p{margin:0}
.mira-actions{margin-top:12px}
.mira-btn{display:flex;align-items:center;justify-content:center;gap:8px}
.lib-empty{padding-top:12px}
.lib-empty .state-title{max-width:320px}
.lib-form-error{color:#a32938!important;font-size:13px;min-height:18px;margin:4px 0 0}

/* Bottom nav pinned: the screen scrolls, the nav stays on screen (user request 2026-11-07). */
#bottom-nav:not([hidden]){position:sticky;bottom:0;z-index:5}
#phone:has(>#bottom-nav:not([hidden])){height:100dvh;min-height:0}
#phone:has(>#bottom-nav:not([hidden])) #screen{overflow-y:auto;min-height:0;-webkit-overflow-scrolling:touch}
@media(min-width:901px){#phone:has(>#bottom-nav:not([hidden])){height:calc(100dvh - 48px)}}
/* ---- App IA (spec 2026-11-07): Сегодня · Чаты · Стиль · Ещё. Video style: flat, white rows on the workspace tint,
   lavender primary, hairlines. §7 accessibility: text >= 14px (body 16), touch targets >= 44px, contrast >= 4.5:1. ---- */
#bottom-nav button{position:relative;font-size:14px;min-height:56px;min-width:72px}
#bottom-nav button span{position:relative}
#bottom-nav .nav-dot{position:absolute;top:3px;right:14px;width:9px;height:9px;border-radius:50%;background:#c62f45;box-shadow:0 0 0 2px var(--work)}
#bottom-nav .nav-count{position:absolute;top:-3px;right:6px;min-width:20px;height:20px;padding:0 6px;border-radius:10px;background:var(--p800);color:#fff;font:700 13px/20px Figtree,sans-serif;text-align:center;box-shadow:0 0 0 2px var(--work)}
.btn.small{min-height:44px;font-size:14px;padding:9px 14px}
.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.section-head{margin:22px 0 10px;font-size:14px;letter-spacing:.04em}
.sub-head{margin:16px 0 8px;font-size:14px;font-weight:600}
.today-head{display:flex;align-items:center;justify-content:space-between;gap:12px}
.today-head .headline{margin-bottom:14px}
.today-banner{display:grid;gap:10px;margin:0 0 16px}
.today-banner p{margin:0;font-size:16px;font-weight:600}
.today-banner .banner-actions{display:flex;gap:8px;flex-wrap:wrap}
.today-banner.update,.today-banner.budget{background:#fff;border-color:var(--line)}
.wait-list,.chat-list{display:grid;gap:8px}
.wait-row,.chat-row{position:relative;display:flex;align-items:center;gap:4px;background:#fff;border-radius:var(--small-r);padding-right:4px;flex-wrap:wrap}
.wait-main,.chat-main{flex:1;min-width:0;display:flex;align-items:center;gap:14px;border:0;background:none;text-align:left;color:inherit;padding:14px 8px 14px 16px;min-height:72px;font-size:16px}
.wait-main .content,.chat-main .content{flex:1;min-width:0;display:grid;gap:4px}
.wait-main small,.chat-main small{font-size:14px;color:var(--n600)}
.wait-top,.chat-top{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.stage-dots{display:inline-flex;gap:4px;align-items:center}
.stage-dots i{width:8px;height:8px;border-radius:50%;border:1.5px solid var(--p800)}
.stage-dots i.done,.stage-dots i.current{background:var(--p800)}
.stage-dots i.current{box-shadow:0 0 0 3px #6c358c33}
.all-chats{margin:10px 0 0;min-height:44px;font-size:15px;font-weight:600}
.mira-today{display:flex;align-items:center;gap:12px;margin-top:20px;padding:12px 12px 12px 14px;background:var(--p300);border:0;box-shadow:none}
.mira-today .content{flex:1;display:grid;gap:2px}
.mira-today .mira-main{text-align:left;font-size:16px;font-weight:600;color:var(--n850);min-height:44px;padding:0}
.mira-today small{font-size:14px}
.week-strip{margin:18px 2px 0;font-size:14px;color:var(--n600)}
.first-run .state-title{max-width:300px}
.offline-note{display:flex;align-items:center;gap:8px;margin:0 0 12px;padding:8px 12px;border-radius:10px;background:var(--work);color:var(--n850);font-size:14px}
.inline-error{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 12px;padding:10px 12px;border-radius:10px;background:#fff;border:1px solid var(--line);font-size:15px;color:var(--n850)}
.inline-error .link-btn{min-height:44px;font-weight:600}
.search-field{margin:0 0 12px}
.search-field input{min-height:48px;font-size:16px}
.filter-chips{margin:0 0 14px;flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;flex:none}
#phone:has(>#bottom-nav:not([hidden])) #screen>*{flex-shrink:0}
.filter-chips .chip{min-height:44px;white-space:nowrap;font-size:15px}
.chip-count{display:inline-block;min-width:20px;padding:0 6px;border-radius:10px;background:var(--work);font-size:13px;font-weight:600;color:var(--n850)}
.chip.selected .chip-count{background:#fff}
.app-chip{display:inline-flex;align-items:center;gap:4px;font-size:14px;color:var(--n600)}
.app-chip .ti{font-size:14px}
.chat-goal{display:flex;align-items:center;gap:8px;font-size:15px;color:var(--n850);min-width:0}
.chat-goal .stage-dots{flex:none}
.chat-goal span:last-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.wait-tag{font-weight:600;color:var(--p800)}
.optout-tag{color:var(--n600)}
.muted-row .chat-main strong,.muted-row .chat-goal{color:var(--n600)}
.row-more{font-size:22px;font-weight:700;letter-spacing:1px}
.row-actions{flex-basis:100%;display:flex;gap:8px;padding:0 12px 12px 16px;flex-wrap:wrap}
.chat-row.swiped{box-shadow:inset 3px 0 0 var(--p800)}
.swipe-hint{margin-top:10px}
.person-head{display:flex;align-items:center;gap:14px;padding:16px;margin:0}
.person-head h2{margin:0;font-size:22px}
.person-head p{margin:2px 0 0}
.plan-card{display:grid;gap:10px;padding:16px;margin:0}
.plan-card.empty p{margin:0}
.plan-goal{margin:0;font-size:17px;font-weight:600}
.stages{list-style:none;margin:4px 0 0;padding:0;display:grid;gap:0}
.stage{display:flex;gap:12px;position:relative;padding:0 0 14px}
.stage:not(:last-child)::before{content:'';position:absolute;left:6px;top:16px;bottom:0;width:2px;background:var(--line)}
.stage-dot{flex:none;width:14px;height:14px;margin-top:3px;border-radius:50%;border:2px solid var(--p800);background:#fff}
.stage.done .stage-dot,.stage.current .stage-dot{background:var(--p800)}
.stage.current .stage-dot{box-shadow:0 0 0 4px #6c358c33}
.stage div{display:grid;gap:2px}
.stage strong{font-size:16px}
.stage small{font-size:14px;color:var(--n600)}
.stage .stage-status{font-weight:600;color:var(--n600)}
.stage.current .stage-status{color:var(--p800)}
.actions.row{display:flex;gap:8px;flex-wrap:wrap;margin-top:6px}
.why{margin:0}
.person-fact{cursor:default;user-select:none;-webkit-user-select:none;-webkit-touch-callout:none}
.person-fact:focus-visible{outline:3px solid #b689ff66}
.fact-chip .source{font-size:13px}
.dialog-list{display:grid;gap:8px}
.dialog-item{background:#fff;border-radius:var(--small-r);padding:10px 14px}
.dialog-item.mine{background:var(--p300)}
.dialog-item small{font-size:14px;color:var(--n600)}
.dialog-item p{margin:2px 0 0;font-size:15px}
.danger-zone{margin-top:28px}
.perm-row{display:flex;align-items:center;gap:12px}
.perm-state{flex:none;width:28px;height:28px;border-radius:50%;display:grid;place-items:center;font-size:16px}
.perm-state.on{background:#e3f4e8;color:#1d6b38}
.perm-state.off{background:#fde8eb;color:#a1253a}
.lib-row .link-btn,.icon-btn{min-height:44px;min-width:44px}
@media(prefers-reduced-motion:reduce){.stage-dots i,.chat-row{transition:none!important}}
body:has(#bottom-nav:not([hidden])) .toast{bottom:calc(96px + env(safe-area-inset-bottom))}
/* Plan 2026-11-07 P1 #5: the update offer on onboarding screens, small and non-blocking. P1 #8: the sign-in stall offer. */
.onboarding-update{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 0 12px;padding:10px 12px}
.onboarding-update p{margin:0;font-size:14px;font-weight:600;color:var(--n850)}
.onboarding-update .banner-actions,.signin-stall .banner-actions{display:flex;gap:6px;flex:none}
.signin-stall{display:grid;gap:8px;margin:12px 0 0}
/* Journey 2026-11-13 §5.7: the next-step card on «Сегодня» (after the banners), like the Мира card */
.step-card{display:flex;align-items:center;gap:12px;margin-top:16px;padding:12px 12px 12px 14px;background:var(--p300);border:0;box-shadow:none}
.step-card .row-mascot{width:48px;height:48px;margin:0;flex:none}
.step-card .content{flex:1;display:grid;gap:2px}
.step-card p{margin:0;font-size:16px;color:var(--n850)}
.step-card small{font-size:14px}
