/* «Чужий телефон» — вигляд вигаданої ОС «Вир»: нічна чорнильна палітра, бурштиновий акцент.
   На телефоні гра займає весь екран (порталова вкладка «AD» просто лягає на лівий край), на десктопі — макет телефона на тлі нічного тролейбуса. */
:root {
    --bg: #0c1016; --s1: #141b24; --s2: #1b2430; --s3: #263242; --line: rgba(255, 255, 255, .08); --line2: rgba(255, 255, 255, .14);
    --tx: #e9eef3; --dim: #98a5b5; --faint: #6c7886; --acc: #ffb454; --acc-ink: #2a1a00; --teal: #5fd4c4; --red: #ff6b6b; --green: #7bd88f;
    --spine: 0px; --adgap: 28px; --st: 30px; --nav: 54px; --sat: env(safe-area-inset-top, 0px); --sab: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { position: fixed; inset: 0; overflow: hidden; background: #07090d; color: var(--tx); font-family: 'Onest', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; font-size: 15px; line-height: 1.42; user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; touch-action: manipulation; text-align: inherit; }
button:disabled { cursor: default; }
a { color: inherit; text-decoration: none; }
svg { display: block; }
h1, h2, h3, h4, h5, p, dl, dd, ul { margin: 0; padding: 0; }
:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
::-webkit-scrollbar { width: 6px; } ::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .12); border-radius: 6px; }
* { scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .12) transparent; }

#stage { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
#backdrop { position: absolute; inset: 0; display: none; }
#backdrop svg { width: 100%; height: 100%; }
#sideL, #sideR { display: none; }
#device { position: absolute; inset: 0; }
#phone { position: absolute; inset: 0; overflow: hidden; background: var(--bg); font-size: 15px; }
#phone.big { font-size: 17px; }

/* ---------- десктоп: макет телефона ---------- */
@media (min-width: 700px) and (min-height: 560px) {
    :root { --adgap: 0px; --sat: 0px; --sab: 0px; --dh: min(calc(100vh - 34px), 880px); --dw: max(356px, calc(var(--dh) * .489)); }
    #backdrop { display: block; }
    #device { position: relative; inset: auto; height: var(--dh); width: var(--dw); padding: 11px; border-radius: 46px; background: linear-gradient(150deg, #353c48, #151920 38%, #0a0c10); box-shadow: 0 0 0 1.5px #000, 0 40px 90px rgba(0, 0, 0, .7), 0 0 120px rgba(255, 180, 84, .07), inset 0 0 0 1.5px rgba(255, 255, 255, .09); }
    #device:before { content: ''; position: absolute; right: -4px; top: 22%; width: 4px; height: 64px; border-radius: 0 3px 3px 0; background: #1c2129; }
    #device:after { content: ''; position: absolute; left: -4px; top: 18%; width: 4px; height: 38px; border-radius: 3px 0 0 3px; background: #1c2129; box-shadow: 0 52px 0 #1c2129; }
    #phone { position: relative; inset: auto; width: 100%; height: 100%; border-radius: 36px; }
    #sideL, #sideR { display: block; position: absolute; top: 50%; transform: translateY(-50%); width: min(26vw, 300px); color: rgba(233, 238, 243, .78); pointer-events: none; }
    #sideL { right: calc(50% + var(--dw) / 2 + 44px); text-align: right; }
    #sideR { left: calc(50% + var(--dw) / 2 + 44px); }
    #sideL b { display: block; font-family: 'Unbounded', 'Onest', system-ui, sans-serif; font-size: clamp(22px, 2.6vw, 38px); line-height: 1.1; letter-spacing: .04em; color: #fff; text-shadow: 0 2px 30px rgba(0, 0, 0, .8); }
    #sideL span { display: block; margin-top: 14px; font-size: 14px; line-height: 1.5; color: rgba(233, 238, 243, .6); }
    #sideR ul { list-style: none; font-size: 13px; line-height: 1.5; color: rgba(233, 238, 243, .55); }
    #sideR li { margin: 6px 0; } #sideR kbd { display: inline-block; min-width: 26px; padding: 1px 7px; margin-right: 8px; border: 1px solid rgba(255, 255, 255, .22); border-radius: 6px; font: 600 12px 'Onest', system-ui, sans-serif; text-align: center; color: rgba(233, 238, 243, .8); }
}
@media (min-width: 700px) and (min-height: 560px) and (max-width: 1020px) { #sideL, #sideR { display: none; } }
.ct-drift { animation: ctDrift 70s linear infinite; } .ct-drift.b { animation-duration: 110s; }
@keyframes ctDrift { from { transform: translateX(0); } to { transform: translateX(-1600px); } }

/* ---------- рамка ОС ---------- */
#wallLock, #wallHome { position: absolute; inset: 0; opacity: 0; transition: opacity .35s; }
#wallLock svg, #wallHome svg { width: 100%; height: 100%; }
#phone[data-mode="lock"] #wallLock, #phone[data-mode="home"] #wallHome { opacity: 1; }
#status { position: absolute; left: 0; right: 0; top: 0; height: calc(var(--st) + var(--sat)); padding: var(--sat) 14px 0 14px; display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 600; color: var(--tx); z-index: 5; }
#stTime { font-variant-numeric: tabular-nums; letter-spacing: .02em; }
#status .sp { flex: 1; }
#stNet { font-size: 10.5px; color: var(--dim); letter-spacing: .08em; }
#stBeacon { display: flex; align-items: center; gap: 4px; color: var(--red); font-size: 10.5px; letter-spacing: .04em; }
#stBeacon i { width: 7px; height: 7px; border-radius: 50%; background: var(--red); animation: blink 1.4s infinite; }
#stBeacon.off { display: none; }
@keyframes blink { 50% { opacity: .25; } }
#stBars { display: flex; align-items: flex-end; gap: 2px; height: 11px; } #stBars i { width: 3px; background: var(--tx); border-radius: 1px; } #stBars i:nth-child(1) { height: 4px; } #stBars i:nth-child(2) { height: 6px; } #stBars i:nth-child(3) { height: 8px; } #stBars i:nth-child(4) { height: 11px; opacity: .3; }
#stBattW { display: flex; align-items: center; gap: 4px; font-size: 11.5px; }
#views { position: absolute; left: var(--spine); right: 0; top: calc(var(--st) + var(--sat)); bottom: calc(var(--nav) + var(--sab)); overflow: hidden; z-index: 3; }
#nav { position: absolute; left: 0; right: 0; bottom: 0; height: calc(var(--nav) + var(--sab)); padding: 0 12px var(--sab) 12px; display: flex; align-items: center; justify-content: space-around; z-index: 6; background: rgba(9, 12, 17, .72); border-top: 1px solid var(--line); }
#phone[data-mode="app"] #nav { background: #0a0d12; }
.nb { position: relative; width: 76px; height: 44px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 19px; color: var(--tx); transition: background .15s, opacity .2s, transform .1s; }
.nb:active { transform: scale(.92); background: rgba(255, 255, 255, .08); }
.nb:disabled { opacity: .28; }
@media (hover: hover) { .nb:not(:disabled):hover { background: rgba(255, 255, 255, .07); } }
#navCase { color: var(--acc); gap: 6px; width: auto; padding: 0 14px; font-size: 18px; }
#navCase:after { content: 'Зачіпки'; font-size: 12px; font-weight: 700; letter-spacing: .04em; }
#navCase.dot:before { content: attr(data-n); position: absolute; right: -10px; top: -3px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--teal); color: #062521; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; box-shadow: 0 0 0 2px #0a0d12; }
#navCase.bump { animation: bump .7s ease-out; } @keyframes bump { 20% { transform: translateY(-5px) scale(1.08); background: rgba(95, 212, 196, .22); } 60% { transform: none; }  }

/* ---------- екрани й переходи ---------- */
.view { position: absolute; inset: 0; display: flex; flex-direction: column; background: var(--bg); will-change: transform, opacity; }
.view.clear { background: transparent; }
.view.dark { background: #06080b; }
.ab { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
.pad16 { padding: 14px 14px 22px; }
.in-open { animation: vOpen .27s cubic-bezier(.2, .85, .25, 1); } @keyframes vOpen { from { transform: scale(.12); opacity: 0; border-radius: 60px; } }
.out-open { animation: vDim .27s forwards; } @keyframes vDim { to { transform: scale(1.08); opacity: 0; } }
.out-close { animation: vClose .27s cubic-bezier(.5, 0, .9, .4) forwards; } @keyframes vClose { to { transform: scale(.1); opacity: 0; border-radius: 60px; } }
.in-close { animation: vUndim .27s; } @keyframes vUndim { from { transform: scale(1.08); opacity: 0; } }
.in-push { animation: vPush .25s cubic-bezier(.2, .8, .3, 1); } @keyframes vPush { from { transform: translateX(34%); opacity: 0; } }
.out-push { animation: vPushO .25s forwards; } @keyframes vPushO { to { transform: translateX(-14%); opacity: 0; } }
.in-pop { animation: vPop .25s; } @keyframes vPop { from { transform: translateX(-14%); opacity: 0; } }
.out-pop { animation: vPopO .25s forwards; } @keyframes vPopO { to { transform: translateX(34%); opacity: 0; } }
.in-fade { animation: vFade .25s; } @keyframes vFade { from { opacity: 0; } }
.out-fade { animation: vFadeO .25s forwards; } @keyframes vFadeO { to { opacity: 0; } }
#phone.wake #views, #phone.wake #wallLock, #phone.wake #wallHome { animation: wake .9s ease-out; } @keyframes wake { from { filter: brightness(0); } 40% { filter: brightness(1.25); } }

/* ---------- спільні елементи ---------- */
.aic { --c: #fff; position: relative; width: 54px; height: 54px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex: none; font-size: 24px; color: var(--c); background: radial-gradient(circle at 30% 25%, color-mix(in srgb, var(--c) 30%, #141b24), #121820 72%); box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--c) 55%, transparent), 0 6px 16px rgba(0, 0, 0, .35); }
.aic.sm { width: 32px; height: 32px; font-size: 15px; box-shadow: inset 0 0 0 1.2px color-mix(in srgb, var(--c) 55%, transparent); }
.av { --c: #888; width: 44px; height: 44px; border-radius: 50%; flex: none; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 16px; color: #10151c; background: var(--c); }
.av.sm { width: 34px; height: 34px; font-size: 13.5px; } .av.big { width: 84px; height: 84px; font-size: 26px; }
.ah { flex: none; display: flex; align-items: center; gap: 10px; min-height: 54px; padding: 6px 12px 6px 4px; border-bottom: 1px solid var(--line); background: var(--bg); }
.ah-b { width: 42px; height: 42px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 20px; color: var(--dim); flex: none; }
.ah-b:active { background: rgba(255, 255, 255, .08); }
.ah-app { flex: none; padding: 3px 9px; border-radius: 9px; font-size: 10.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--c, var(--dim)); background: color-mix(in srgb, var(--c, #888) 13%, transparent); }
.ah-t { min-width: 0; flex: 1; } .ah-t b { display: block; font-size: 1.07em; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .ah-t small { display: block; font-size: .8em; color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 18px; border-radius: 14px; background: var(--s2); border: 1px solid var(--line2); font-weight: 600; font-size: 15px; text-align: center; transition: transform .1s, background .15s; }
.btn:active { transform: scale(.97); }
.btn.pri { background: var(--acc); color: var(--acc-ink); border-color: transparent; }
.btn.dan { background: rgba(255, 107, 107, .12); border-color: rgba(255, 107, 107, .5); color: #ff9c9c; }
.btn.sm { min-height: 40px; padding: 8px 14px; font-size: 14px; border-radius: 12px; }
.btn.wide { width: 100%; }
.btn:disabled { opacity: .4; }
.btn2 { display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 8px 14px; margin-top: 8px; border-radius: 12px; background: rgba(255, 180, 84, .12); border: 1px solid rgba(255, 180, 84, .45); color: var(--acc); font-weight: 600; font-size: 14px; }
.bdg { position: absolute; right: -4px; top: -4px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: var(--red); color: #fff; font-size: 11.5px; font-weight: 700; display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 2px #10161d; }
.bdg.in { position: static; box-shadow: none; flex: none; background: var(--teal); color: #062521; }
.bdg.live { min-width: 12px; width: 12px; height: 12px; padding: 0; right: 0; top: 0; animation: blink 1.4s infinite; }
.tag { display: inline-block; margin-left: 7px; padding: 1px 6px; border-radius: 6px; background: var(--s3); color: var(--dim); font-size: 10px; font-weight: 700; font-style: normal; letter-spacing: .05em; vertical-align: 1px; }
.tag.red { margin: 0 7px 0 0; background: rgba(255, 107, 107, .16); color: #ff9c9c; }
.sw { width: 40px; height: 24px; border-radius: 12px; background: var(--s3); position: relative; flex: none; transition: background .2s; } .sw:after { content: ''; position: absolute; left: 3px; top: 3px; width: 18px; height: 18px; border-radius: 50%; background: #8e99a8; transition: transform .2s, background .2s; } .sw.on { background: rgba(95, 212, 196, .35); } .sw.on:after { transform: translateX(16px); background: var(--teal); }
.sec { margin: 18px 0 8px; font-size: 11.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--faint); } .sec:first-child { margin-top: 2px; } .list > .sec { padding: 0 14px; margin-top: 16px; }
.empty { padding: 40px 20px; text-align: center; color: var(--faint); } .empty.big { font-size: 1.1em; line-height: 2; } .empty.big .adi { --adi-size: 44px; margin: 0 auto; }
.shake { animation: shake .4s; } @keyframes shake { 20% { transform: translateX(-9px); } 40% { transform: translateX(8px); } 60% { transform: translateX(-6px); } 80% { transform: translateX(4px); } }

/* ---------- заблокований екран ---------- */
.lk { flex: 1; min-height: 0; display: flex; flex-direction: column; padding: 0 12px 12px; }
.lk-top { flex: none; text-align: center; padding: 3.2vh 0 2.2vh; text-shadow: 0 2px 18px rgba(0, 0, 0, .7); }
.lk-time { font-family: 'Unbounded', 'Onest', system-ui, sans-serif; font-weight: 600; font-size: clamp(50px, 16vmin, 68px); line-height: 1; letter-spacing: .01em; font-variant-numeric: tabular-nums; }
.lk-date { margin-top: 8px; font-size: 15px; color: rgba(255, 255, 255, .85); }
.lk-own { margin-top: 10px; display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; letter-spacing: .06em; color: rgba(255, 255, 255, .6); }
.lk-n { display: flex; flex-direction: column; gap: 7px; padding: 2px; }
.ntf { display: flex; gap: 10px; align-items: flex-start; width: 100%; padding: 10px 12px; border-radius: 16px; background: rgba(16, 22, 30, .78); border: 1px solid rgba(255, 255, 255, .08); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); flex: none; }
.ntf-t { min-width: 0; flex: 1; } .ntf-t b { display: flex; justify-content: space-between; gap: 8px; font-size: 13.5px; } .ntf-t time { font-weight: 500; font-size: 12px; color: var(--dim); flex: none; } .ntf-t > span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 14.5px; color: #d5dce5; }
.lk-bot { flex: none; display: flex; gap: 8px; padding-top: 10px; }
.lk-b { flex: 1; min-height: 50px; display: flex; align-items: center; justify-content: center; gap: 8px; border-radius: 16px; background: rgba(16, 22, 30, .78); border: 1px solid rgba(255, 255, 255, .12); font-weight: 600; font-size: 14px; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.lk-b.pri { background: var(--acc); color: var(--acc-ink); border-color: transparent; }
.med { flex: 1; display: flex; flex-direction: column; } .med .ah { background: transparent; border-color: transparent; }
.med-c { margin: 10px 14px; padding: 16px; border-radius: 20px; background: rgba(16, 22, 30, .86); border: 1px solid rgba(255, 107, 107, .35); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.med-h { display: flex; align-items: center; gap: 10px; color: #ff9c9c; font-weight: 700; margin-bottom: 12px; } .med-h .adi { --adi-size: 22px; }
.med dl, .kv { display: grid; grid-template-columns: 1fr; gap: 2px; } .med dt, .kv dt { font-size: 12px; color: var(--dim); margin-top: 9px; } .med dd, .kv dd { font-size: 16px; font-weight: 600; }
.med-n { margin-top: 16px; font-size: 12px; color: var(--faint); }
.kv dd.warn { color: var(--red); }

/* ---------- замки ---------- */
.pad { flex: 1; min-height: 0; display: flex; flex-direction: column; align-items: center; position: relative; padding: 8px 14px 14px; }
.pad-x { position: absolute; left: 4px; top: 6px; }
.pad-top { flex: 1; min-height: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 0 30px; }
.pad-ic { font-size: 26px; color: var(--acc); margin-bottom: 8px; }
.pad h2 { font-size: 20px; font-weight: 700; } .pad-top > p { font-size: 13.5px; color: var(--dim); margin-top: 4px; }
.pad-dots { display: flex; gap: 14px; margin: 20px 0 6px; } .pad-dots i { width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .5); transition: background .1s; } .pad-dots i.on { background: var(--acc); border-color: var(--acc); }
.pad-top > p.pad-msg { min-height: 2.9em; font-size: 14px; color: var(--acc); margin-top: 8px; } .pad-top > p.pad-msg.err { color: #ff9c9c; }
.pad-keys { flex: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px 22px; width: min(280px, 100%); padding-bottom: 6px; }
.pk { height: clamp(50px, 8.2vh, 64px); border-radius: 32px; background: rgba(255, 255, 255, .08); font-size: 24px; font-weight: 500; display: flex; align-items: center; justify-content: center; text-align: center; transition: background .1s, transform .1s; }
.pk:active { background: rgba(255, 180, 84, .35); transform: scale(.95); } .pk.fn { background: transparent; color: var(--dim); font-size: 22px; }
.view.clear .pad { background: rgba(6, 9, 14, .5); } .view.clear .pad h2, .view.clear .pad-top > p { text-shadow: 0 2px 14px rgba(0, 0, 0, .8); } .view.clear .pk { background: rgba(16, 22, 30, .66); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); } .view.clear .pk.fn { background: transparent; backdrop-filter: none; }
.pat-g { flex: none; width: min(270px, 78%); touch-action: none; margin: 4px 0 6px; cursor: pointer; }
.pat-d .o { fill: rgba(255, 255, 255, .05); stroke: rgba(255, 255, 255, .28); stroke-width: 1.5; transition: fill .15s; } .pat-d .c { fill: #cfd6de; }
.pat-d.on .o { fill: rgba(255, 180, 84, .22); stroke: var(--acc); } .pat-d.on .c { fill: var(--acc); }
.pat-l { fill: none; stroke: var(--acc); stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; opacity: .85; }
.pat-g.bad .pat-l { stroke: var(--red); } .pat-g.bad .pat-d.on .o { stroke: var(--red); fill: rgba(255, 107, 107, .2); } .pat-g.bad .pat-d.on .c { fill: var(--red); }
.pat-f { flex: none; font-size: 12px; color: var(--faint); text-align: center; padding-bottom: 8px; }
.pass-f { display: flex; align-items: center; justify-content: center; min-width: 210px; min-height: 50px; margin-top: 18px; padding: 8px 18px; border-radius: 14px; background: var(--s1); border: 1.5px solid rgba(183, 156, 255, .55); font-size: 21px; font-weight: 600; letter-spacing: .06em; } .pass-f em { font-style: normal; font-weight: 400; color: var(--faint); letter-spacing: 0; font-size: 16px; } .pass-f i { width: 2px; height: 24px; margin-left: 3px; background: #b79cff; animation: blink 1s steps(1) infinite; }
.kb { flex: none; width: 100%; display: flex; flex-direction: column; gap: 6px; padding: 8px 0 2px var(--adgap); }   /* ліворуч — місце під порталову вкладку «AD» */
.kb-r { display: flex; justify-content: center; gap: 3.5px; }
.kk { flex: 1 1 0; max-width: 34px; min-width: 0; height: 44px; border-radius: 8px; background: var(--s2); border-bottom: 2px solid #0a0e13; font-size: 17px; font-weight: 500; display: flex; align-items: center; justify-content: center; text-align: center; }
.kk:active { background: rgba(183, 156, 255, .4); } .kk.fn { max-width: 46px; flex: 1.5 1 0; background: var(--s3); font-size: 19px; }
.kk.go { max-width: none; gap: 8px; background: #b79cff; color: #1b1033; font-weight: 700; font-size: 15px; height: 46px; border-radius: 12px; border: 0; margin-top: 2px; }

/* ---------- головний екран ---------- */
.home { padding: 6px 12px 14px 18px; }
.hw { padding: 2.2vh 8px 2.4vh; text-shadow: 0 2px 14px rgba(0, 0, 0, .6); }
.hw-t { font-family: 'Unbounded', 'Onest', system-ui, sans-serif; font-weight: 600; font-size: 40px; line-height: 1; font-variant-numeric: tabular-nums; }
.hw-d { margin-top: 6px; font-size: 14px; color: rgba(255, 255, 255, .8); }
.hw-n { display: flex; align-items: center; gap: 8px; margin-top: 12px; padding: 9px 12px; border-radius: 12px; background: rgba(16, 22, 30, .72); border: 1px solid rgba(255, 159, 107, .35); font-size: 13.5px; color: #ffd9c2; text-shadow: none; max-width: 100%; } .hw-n span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px 2px; }
.app { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 4px 0; min-width: 0; transition: transform .12s; }
.app:active { transform: scale(.9); }
.app .bdg { right: calc(50% - 32px); top: 0; }
.an { max-width: 100%; font-size: 11.5px; font-weight: 500; color: #dfe6ee; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 1px 6px rgba(0, 0, 0, .8); }
#phone.big .an { font-size: 12px; }

/* ---------- списки ---------- */
.list { padding: 6px 0 16px; }
.crow, .lrow { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 14px; min-height: 64px; }
.crow:active, button.lrow:active, .mrow:active { background: rgba(255, 255, 255, .05); }
.crow-t, .lrow-t { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.crow-t b, .lrow-t b { display: flex; align-items: baseline; font-size: 1em; font-weight: 600; white-space: nowrap; overflow: hidden; } .crow-t b time { margin-left: auto; padding-left: 8px; font-weight: 500; font-size: .78em; color: var(--faint); }
.crow-t > span, .lrow-t > span { font-size: .92em; color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crow.un .crow-t > span { color: var(--tx); } .crow.un .crow-t b time { color: var(--teal); }
.lockrow { border-bottom: 1px solid var(--line); } .lockrow .av { background: rgba(255, 209, 102, .16); color: #ffd166; font-size: 19px; }
.lic { --c: var(--dim); width: 40px; height: 40px; border-radius: 12px; flex: none; display: flex; align-items: center; justify-content: center; font-size: 19px; color: var(--c); background: color-mix(in srgb, var(--c) 14%, transparent); }
.lic.k { background: var(--s1); color: var(--dim); }
.lrow.st { min-height: 54px; padding-left: 0; padding-right: 0; } .list > .lrow.st { padding: 8px 14px; } .lrow.st .lrow-t > span { white-space: normal; }
.lrow.miss .lic.k { color: var(--red); } .lrow.miss b { color: #ffb0b0; } .lrow em { font-style: normal; font-weight: 500; color: var(--dim); margin-left: 5px; }
.lrow > .adi { color: var(--faint); flex: none; } .lrow.un .lrow-t b:after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--teal); margin-left: 8px; flex: none; align-self: center; }

/* ---------- чат ---------- */
.chat { padding: 10px 10px 14px; display: flex; flex-direction: column; gap: 5px; }
.day { align-self: center; margin: 10px 0 6px; padding: 3px 12px; border-radius: 10px; background: var(--s1); font-size: 12px; color: var(--dim); }
.msg { display: flex; flex-direction: column; align-items: flex-start; max-width: 100%; } .msg.o { align-items: flex-end; }
.who { font-size: 12px; font-weight: 700; color: #9fb6d8; margin: 4px 0 2px 12px; }
.bub { position: relative; max-width: 84%; padding: 8px 12px 7px; border-radius: 6px 18px 18px 18px; background: var(--s2); font-size: 1em; line-height: 1.4; overflow-wrap: anywhere; user-select: text; -webkit-user-select: text; }
.msg.o .bub { border-radius: 18px 6px 18px 18px; background: #1f4a4a; color: #e8fffb; }
.bub time { display: block; margin-top: 2px; font-size: .72em; text-align: right; color: rgba(255, 255, 255, .45); }
.msg.new .bub { animation: pop .22s ease-out; } @keyframes pop { from { transform: translateY(8px) scale(.96); opacity: 0; } }
.bub.pic { padding: 4px 4px 6px; width: 62%; } .bub.pic svg { width: 100%; aspect-ratio: 1; border-radius: 4px 14px 14px 14px; } .bub.pic time { padding-right: 6px; }
.typing { display: inline-flex; gap: 4px; align-items: center; min-height: 34px; padding: 10px 14px; } .typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--dim); animation: ty 1.1s infinite; } .typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; } @keyframes ty { 0%, 60%, 100% { transform: none; opacity: .4; } 30% { transform: translateY(-4px); opacity: 1; } }
.pinbar { flex: none; display: flex; gap: 8px; align-items: flex-start; padding: 8px 12px; background: var(--s1); border-bottom: 1px solid var(--line); font-size: .87em; color: #cfd8e3; } .pinbar .adi { color: var(--acc); margin-top: 2px; }
.reply { flex: none; display: flex; flex-direction: column; gap: 7px; padding: 10px 10px 12px; background: #0f151c; border-top: 1px solid var(--line2); max-height: 56%; overflow-y: auto; }
.reply-h { display: flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--teal); }
.ch { width: 100%; min-height: 44px; padding: 9px 13px; border-radius: 14px; background: rgba(95, 212, 196, .09); border: 1px solid rgba(95, 212, 196, .42); font-size: .97em; line-height: 1.35; text-align: left; animation: pop .25s ease-out backwards; }
.ch:nth-child(3) { animation-delay: .05s; } .ch:nth-child(4) { animation-delay: .1s; } .ch:nth-child(5) { animation-delay: .15s; }
.ch:active { background: rgba(95, 212, 196, .25); } .ch.sil { background: transparent; border: 1px dashed var(--line2); color: var(--dim); font-style: italic; }
.reply.none { padding: 9px 10px 10px; } .fake-in { display: block; padding: 10px 14px; border-radius: 20px; background: var(--s1); color: var(--faint); font-size: .9em; }

/* ---------- дзвінок ---------- */
#ring { position: absolute; inset: 0; z-index: 25; display: none; background: radial-gradient(120% 70% at 50% 20%, #1c2a3d, #090c11 70%); }
#ring.on { display: flex; animation: vFade .3s; }
.rg-in { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 30px 30px calc(30px + var(--sab)); text-align: center; }
.rg-rings { position: relative; width: 84px; height: 84px; margin-bottom: 26px; } .rg-rings i { position: absolute; inset: 0; border-radius: 50%; border: 2px solid rgba(143, 163, 200, .6); animation: ringp 2.1s infinite; } .rg-rings i:nth-child(2) { animation-delay: .7s; } .rg-rings i:nth-child(3) { animation-delay: 1.4s; } .rg-rings .av { position: relative; }
@keyframes ringp { from { transform: scale(1); opacity: .8; } to { transform: scale(2.3); opacity: 0; } }
.rg-n { font-size: 23px; font-weight: 700; } .rg-s { color: var(--dim); }
.rg-b { display: flex; gap: 56px; margin-top: 9vh; } .rg-btn { display: flex; flex-direction: column; align-items: center; gap: 8px; font-size: 13px; color: var(--dim); } .rg-btn .adi { box-sizing: content-box; padding: 20px; width: 28px; height: 28px; border-radius: 50%; color: #fff; }
.rg-btn.no .adi { background: #e5484d; } .rg-btn.yes .adi { background: #2fb96a; animation: bob 1s infinite; } @keyframes bob { 50% { transform: translateY(-5px); } }
.rg-h { margin-top: 5vh; font-size: 12px; color: var(--faint); }
.callv { background: radial-gradient(120% 60% at 50% 0, #17222f, var(--bg) 70%); }
.cv-h { flex: none; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 16px 14px 12px; border-bottom: 1px solid var(--line); } .cv-h .av.big { width: 56px; height: 56px; font-size: 18px; margin-bottom: 4px; } .cv-h small { color: var(--green); font-size: 12.5px; }
.cv-b { padding: 12px 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.cl { display: grid; grid-template-columns: 44px 1fr; gap: 6px; font-size: 1em; line-height: 1.45; animation: pop .22s; } .cl b { font-size: .78em; color: #9fb6d8; padding-top: 3px; } .cl.o b { color: var(--teal); } .cl.o span { color: #c9f4ee; } .cl .typing { justify-self: start; padding: 6px 10px; background: var(--s2); border-radius: 12px; }

/* ---------- пошта ---------- */
.tabs { flex: none; display: flex; gap: 6px; padding: 8px 12px; border-bottom: 1px solid var(--line); }
.tabs button { flex: 1; min-height: 40px; border-radius: 12px; font-size: 13.5px; font-weight: 600; color: var(--dim); text-align: center; } .tabs button.on { background: var(--s2); color: var(--tx); } .tabs em { font-style: normal; margin-left: 6px; padding: 0 6px; border-radius: 8px; background: var(--teal); color: #062521; font-size: 11.5px; }
.mrow { display: block; width: 100%; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.mrow b { display: flex; align-items: baseline; font-weight: 500; color: var(--dim); font-size: .92em; } .mrow b time { margin-left: auto; padding-left: 8px; font-size: .84em; color: var(--faint); white-space: nowrap; }
.mrow .ms { display: block; margin-top: 2px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .mrow .mp { display: block; margin-top: 2px; font-size: .88em; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mrow.un b { color: var(--tx); font-weight: 700; } .mrow.un b:before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: #6ea8ff; margin-right: 8px; flex: none; align-self: center; }
.mail h3, .note h3 { font-size: 1.25em; line-height: 1.25; margin-bottom: 12px; }
.mail-m { display: flex; align-items: center; gap: 10px; padding-bottom: 12px; border-bottom: 1px solid var(--line); } .mail-m b { display: block; font-size: .95em; } .mail-m small { color: var(--dim); font-size: .8em; overflow-wrap: anywhere; }
.mail-b, .note-b { padding: 14px 0 6px; font-size: 1.02em; line-height: 1.55; user-select: text; -webkit-user-select: text; overflow-wrap: anywhere; }
.caret { display: inline-block; width: 2px; height: 1.1em; margin-left: 2px; vertical-align: -3px; background: #6ea8ff; animation: blink 1s steps(1) infinite; }
.mail-s { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line2); font-size: .82em; color: var(--dim); line-height: 1.5; }
.mail-att { margin-top: 16px; padding: 12px; border-radius: 14px; background: var(--s1); } .mail-att h5 { font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); margin-bottom: 8px; }
.noatt { display: flex; align-items: center; gap: 8px; color: #ff9c9c; font-size: .93em; } .atts { display: flex; flex-direction: column; gap: 6px; } .att { display: flex; align-items: center; gap: 8px; font-size: .88em; overflow-wrap: anywhere; } .att .adi { color: #b79cff; }
.mail-act { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.sentok { display: flex; align-items: center; gap: 8px; margin-top: 14px; color: var(--green); font-weight: 600; font-size: .93em; }

/* ---------- галерея ---------- */
.albums { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; } .alb { display: flex; flex-direction: column; gap: 2px; } .alb b { margin-top: 8px; } .alb small { color: var(--dim); font-size: .85em; }
.alb-c { display: flex; align-items: center; justify-content: center; aspect-ratio: 1; border-radius: 18px; overflow: hidden; background: var(--s1); border: 1px solid var(--line2); } .alb-c svg.ph { width: 100%; height: 100%; } .alb-c.lockd > svg.adi { --adi-size: 34px; color: var(--acc); }
.thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; padding: 3px; } .th { aspect-ratio: 1; overflow: hidden; border-radius: 4px; } .th svg { width: 100%; height: 100%; } .th:active { opacity: .7; }
.pv { display: flex; flex-direction: column; justify-content: center; padding: 10px 0 18px; } .pv-i { width: 100%; aspect-ratio: 4 / 3; flex: none; } .pv-i.sq { aspect-ratio: 1; padding: 0 8%; } .pv-i svg { width: 100%; height: 100%; }
.pv-c { padding: 14px 16px 4px; font-size: 1em; line-height: 1.45; color: #dfe6ee; } .pv-n { display: flex; justify-content: center; gap: 14px; padding-top: 12px; }

/* ---------- нотатки ---------- */
.ncards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ncard { display: flex; flex-direction: column; gap: 6px; min-height: 124px; padding: 12px; border-radius: 16px; background: #1d1b14; border: 1px solid rgba(255, 209, 102, .22); } .ncard:active { transform: scale(.97); }
.ncard b { display: flex; gap: 6px; align-items: flex-start; color: #ffe2a0; font-size: .95em; line-height: 1.25; } .ncard b .adi { flex: none; margin-top: 1px; } .ncard span { flex: 1; font-size: .82em; color: #b9b29d; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; } .ncard small { font-size: .74em; color: #8a8471; }
.ncard.lk { background: #151b24; border-color: var(--line2); border-style: dashed; } .ncard.lk b { color: var(--tx); } .ncard.lk span { color: var(--faint); }
.note h3 { color: #ffe2a0; }
.chk { list-style: none; display: flex; flex-direction: column; gap: 10px; } .chk li { display: flex; gap: 10px; align-items: flex-start; font-size: 1.02em; } .chk i { width: 22px; height: 22px; flex: none; border-radius: 7px; border: 1.5px solid var(--faint); display: flex; align-items: center; justify-content: center; font-size: 13px; margin-top: 1px; } .chk li.on i { background: rgba(255, 209, 102, .2); border-color: #ffd166; color: #ffd166; } .chk li.on span { color: var(--dim); }

/* ---------- календар, годинник ---------- */
.cal-h { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; } .cal-h b { font-size: 1.1em; }
.cal-w, .cal-g { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; text-align: center; } .cal-w span { font-size: 11px; color: var(--faint); padding: 4px 0; }
.cd { position: relative; aspect-ratio: 1; max-height: 44px; border-radius: 12px; font-size: 14.5px; display: flex; align-items: center; justify-content: center; text-align: center; color: var(--dim); } .cd.ev { color: var(--tx); font-weight: 600; } .cd.ev:after { content: ''; position: absolute; bottom: 5px; left: 50%; margin-left: -2.5px; width: 5px; height: 5px; border-radius: 50%; background: #ff9f6b; }
.cd.today { background: #ff9f6b; color: #2a1200; font-weight: 700; } .cd.today:after { background: #2a1200; } .cd.sel { box-shadow: inset 0 0 0 2px var(--tx); }
.agenda { margin-top: 16px; display: flex; flex-direction: column; gap: 6px; } .ag { display: flex; gap: 12px; padding: 10px 12px; border-radius: 14px; background: var(--s1); border: 1px solid transparent; } .ag.sel { border-color: var(--line2); background: var(--s2); } .ag.today { border-color: rgba(255, 159, 107, .6); }
.ag b { width: 30px; flex: none; text-align: center; font-size: 1.15em; line-height: 1.1; } .ag b small { display: block; font-size: 11px; font-weight: 500; color: var(--faint); } .ag span { display: flex; flex-direction: column; gap: 4px; } .ag i { font-style: normal; font-size: .95em; }
.clk { text-align: center; padding: 10px 0 6px; font-family: 'Unbounded', 'Onest', system-ui, sans-serif; font-size: 48px; font-weight: 600; font-variant-numeric: tabular-nums; } .clk small { display: block; font-family: 'Onest', system-ui, sans-serif; font-size: 13px; font-weight: 400; color: var(--dim); }
.alarm { display: flex; align-items: center; gap: 12px; padding: 12px; margin-bottom: 6px; border-radius: 14px; background: var(--s1); opacity: .55; } .alarm.on { opacity: 1; } .alarm b { font-size: 1.6em; font-weight: 600; font-variant-numeric: tabular-nums; } .alarm span { flex: 1; min-width: 0; } .alarm em { display: block; font-style: normal; font-weight: 600; } .alarm small { color: var(--dim); font-size: .82em; } .alarm.wt b { font-size: 1.25em; }

/* ---------- мапа, таксі ---------- */
.mapw { border-bottom: 1px solid var(--line); } .mapsvg { width: 100%; height: auto; }
.ct-pulse { animation: pulse 2s infinite; transform-box: fill-box; transform-origin: center; } @keyframes pulse { from { transform: scale(.5); opacity: .5; } to { transform: scale(1.6); opacity: 0; } }
.ct-spin { animation: spin 9s linear infinite; transform-box: fill-box; transform-origin: center; } @keyframes spin { to { transform: rotate(360deg); } }
.trip { padding: 12px; margin-bottom: 8px; border-radius: 14px; background: var(--s1); } .trip small { display: flex; justify-content: space-between; color: var(--dim); font-size: .82em; margin-bottom: 8px; } .trip small b { color: #f4d35e; }
.rt { display: flex; gap: 10px; align-items: flex-start; font-size: .95em; padding: 2px 0; } .rt i { width: 9px; height: 9px; margin-top: 6px; border-radius: 50%; border: 2px solid var(--teal); flex: none; } .rt.b i { border-color: #f4d35e; background: #f4d35e; border-radius: 2px; }
.trip p { margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line2); font-size: .88em; color: #cfd8e3; font-style: italic; }

/* ---------- голосова пошта, диктофон ---------- */
.vm { padding: 14px; border-radius: 18px; background: var(--s1); } .vm-h { display: flex; align-items: center; gap: 12px; } .vm-h b { display: block; } .vm-h small { color: var(--dim); font-size: .85em; }
.wave { display: flex; align-items: center; gap: 2.5px; height: 46px; margin: 14px 0 10px; overflow: hidden; } .wave i { flex: 1; min-width: 2px; border-radius: 2px; background: #4c5b6e; } .wave.play i { background: #ffab76; animation: wv .5s infinite alternate; } .wave.play i:nth-child(3n) { animation-delay: .15s; } .wave.play i:nth-child(3n+1) { animation-delay: .3s; } @keyframes wv { to { transform: scaleY(.4); } }
.vm h5 { margin-top: 12px; font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); } .tr { margin-top: 6px; font-size: 1.02em; line-height: 1.55; user-select: text; -webkit-user-select: text; }
.moved { display: flex; align-items: center; gap: 8px; margin-top: 14px; color: #b79cff; }

/* ---------- скриня: документи ---------- */
.trs p { margin-bottom: 10px; font-size: 1.01em; line-height: 1.5; user-select: text; -webkit-user-select: text; } .trs b { display: inline-block; min-width: 26px; margin-right: 4px; } .trs .d b { color: #8fa3c8; } .trs .t b { color: #c98a5b; } .trs .sys { color: var(--dim); font-style: italic; font-size: .92em; }
.paper { position: relative; padding: 18px 16px 16px; border-radius: 4px; background: #eee7d6; color: #26262b; font-size: .95em; line-height: 1.45; box-shadow: 0 10px 30px rgba(0, 0, 0, .5); transform: rotate(-.6deg); margin: 6px 2px 10px; }
.paper h5 { font-size: 1em; text-align: center; letter-spacing: .03em; } .paper .stamp + h5 { margin-top: 20px; } .paper p { margin-top: 9px; } .paper .pc { text-align: center; font-size: .86em; color: #5b5a55; } .paper u { text-decoration-color: #b8322a; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.stamp { position: absolute; right: 8px; top: 6px; padding: 2px 10px; border: 2px solid rgba(60, 80, 160, .55); color: rgba(60, 80, 160, .7); font-weight: 800; font-size: 12px; letter-spacing: .2em; transform: rotate(9deg); border-radius: 4px; }
.hand { font-family: 'Caveat', 'Segoe Script', 'Comic Sans MS', cursive; font-size: 1.4em; line-height: 1.25; color: #26346a; } .hand.red { color: #b8322a; font-size: 1.3em; } .hand.big { font-size: 1.9em; text-align: center; }
.paper.lined { background: repeating-linear-gradient(#f4efe2 0 29px, #c9d3e6 29px 30px); padding-top: 12px; } .paper.lined p { margin-top: 0; line-height: 30px; } .sig { float: right; font-size: 1.25em; transform: rotate(-4deg); display: inline-block; }
.paper table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: .86em; } .paper th, .paper td { border: 1px solid #8f8a7c; padding: 5px 5px; text-align: left; vertical-align: top; } .paper th { background: #ddd5c0; } .paper tr.hl td { background: #f6e27a; }

/* ---------- маячок ---------- */
.bcn { text-align: center; } .bcn h3 { font-size: 1.3em; margin-top: 14px; color: #ff9c9c; } .bc.off .bcn h3 { color: var(--dim); } .bc-s { color: var(--dim); font-size: .93em; margin-top: 4px; } .bcn .kv { text-align: left; margin: 14px 0 18px; padding: 4px 14px 14px; border-radius: 16px; background: var(--s1); } .bc-n { margin-top: 10px; font-size: .82em; color: var(--faint); } .bcn .sentok { justify-content: center; }
.radar { position: relative; width: 118px; height: 118px; margin: 12px auto 0; display: flex; align-items: center; justify-content: center; } .radar i { position: absolute; inset: 0; border-radius: 50%; border: 2px solid rgba(255, 107, 107, .55); animation: radarp 2.4s infinite; opacity: 0; } @keyframes radarp { from { transform: scale(.5); opacity: .9; } to { transform: scale(1.1); opacity: 0; } } .radar i:nth-child(2) { animation-delay: .8s; } .radar i:nth-child(3) { animation-delay: 1.6s; }
.radar span { width: 62px; height: 62px; border-radius: 50%; background: rgba(255, 107, 107, .16); color: var(--red); font-size: 30px; display: flex; align-items: center; justify-content: center; } .radar.off i { display: none; } .radar.off span { background: var(--s2); color: var(--faint); }
.rows { display: flex; flex-direction: column; gap: 6px; } .row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 50px; padding: 8px 14px; border-radius: 14px; background: var(--s1); font-weight: 500; } .row > .adi { color: var(--dim); font-size: 18px; } .row span { flex: 1; } .row em { font-style: normal; color: var(--acc); font-weight: 700; } .row:active { background: var(--s2); }

/* ---------- банер, тост ---------- */
#banner { position: absolute; left: calc(var(--spine) + 8px); right: 8px; top: calc(var(--sat) + 6px); z-index: 28; display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 18px; background: rgba(27, 36, 48, .97); border: 1px solid var(--line2); box-shadow: 0 14px 34px rgba(0, 0, 0, .55); transform: translateY(-140%); opacity: 0; transition: transform .3s cubic-bezier(.2, .9, .3, 1.1), opacity .25s; cursor: pointer; }
#banner.on { transform: none; opacity: 1; }
.bn-t { min-width: 0; flex: 1; display: flex; flex-direction: column; } .bn-t b { font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .bn-t span { font-size: 14px; color: #d5dce5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
#toast { position: absolute; left: 50%; bottom: calc(var(--nav) + var(--sab) + 12px); z-index: 60; transform: translate(-50%, 16px); opacity: 0; pointer-events: none; display: flex; align-items: center; gap: 9px; max-width: calc(100% - var(--spine) - 24px); padding: 9px 15px; border-radius: 14px; background: #202b39; border: 1px solid var(--line2); box-shadow: 0 10px 28px rgba(0, 0, 0, .5); font-size: 13.5px; font-weight: 600; white-space: nowrap; transition: transform .25s, opacity .25s; }
#toast.on { transform: translate(-50%, 0); opacity: 1; } #toast .adi { color: var(--teal); flex: none; } #toast span { overflow: hidden; text-overflow: ellipsis; }
#toast.ach { border-color: rgba(255, 180, 84, .6); } #toast.ach .adi { color: var(--acc); --adi-size: 24px; } #toast.ach small { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--acc); }

/* ---------- шторка «Справа» ---------- */
#sheet { position: absolute; inset: 0; z-index: 30; display: none; background: rgba(4, 6, 9, .6); }
#sheet.on { display: block; animation: vFade .2s; }
.sh-in { position: absolute; left: var(--spine); right: 0; bottom: 0; top: calc(var(--sat) + 44px); display: flex; flex-direction: column; border-radius: 22px 22px 0 0; background: #171410; border: 1px solid rgba(255, 180, 84, .28); border-bottom: 0; box-shadow: 0 -20px 50px rgba(0, 0, 0, .5); animation: shUp .28s cubic-bezier(.2, .85, .3, 1); padding-bottom: var(--sab); }
@keyframes shUp { from { transform: translateY(40%); opacity: 0; } }
.sh-h { flex: none; display: flex; align-items: center; gap: 6px; padding: 10px 8px 8px 10px; border-bottom: 1px solid rgba(255, 180, 84, .16); }
.sh-tabs { flex: 1; display: flex; gap: 4px; min-width: 0; } .sh-tabs button { flex: 1 1 auto; min-width: 0; min-height: 42px; padding: 0 6px; display: flex; align-items: center; justify-content: center; gap: 5px; border-radius: 12px; font-size: 13px; font-weight: 600; color: #a89c88; } .sh-tabs button span { white-space: nowrap; } .sh-tabs button .adi { --adi-size: 15px; } .sh-tabs button.on { background: rgba(255, 180, 84, .16); color: var(--acc); }
.sh-x { width: 42px; height: 42px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #a89c88; font-size: 18px; flex: none; }
.sh-b { flex: 1; min-height: 0; overflow-y: auto; padding: 14px 14px 20px; user-select: text; -webkit-user-select: text; }
.sh-note { font-size: 13px; color: #a89c88; line-height: 1.45; margin-bottom: 12px; } .sh-empty { padding: 26px 10px; text-align: center; color: #8a7f6c; }
.sh-b h4 { margin: 16px 0 8px; font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--acc); }
.facts { list-style: none; display: flex; flex-direction: column; gap: 6px; } .facts li { position: relative; padding: 9px 12px 9px 14px; border-radius: 12px; background: #201c16; border-left: 3px solid #4a3f2d; font-size: 14.5px; line-height: 1.42; } .facts li.new { border-left-color: var(--teal); background: #1c221f; } .facts b { color: var(--acc); letter-spacing: .04em; }
.goal { margin-bottom: 8px; border-radius: 14px; background: #201c16; border: 1px solid transparent; } .goal.open { border-color: rgba(255, 180, 84, .35); }
.goal-h { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 48px; padding: 8px 12px; font-weight: 600; font-size: 14.5px; } .goal-h span { flex: 1; } .goal-h em { font-style: normal; font-size: 12px; color: #a89c88; } .goal-h .adi { color: #a89c88; }
.goal-b { padding: 0 12px 12px; } .hint { margin-top: 6px; padding: 9px 12px; border-radius: 10px; background: #2a241a; font-size: 14.5px; line-height: 1.42; } .hint b { display: block; font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--acc); margin-bottom: 2px; }
.sh-done { margin-top: 14px; display: flex; flex-direction: column; gap: 5px; font-size: 13px; color: #8a7f6c; } .sh-done span { display: flex; gap: 7px; align-items: center; } .sh-done .adi { color: var(--green); }
#sheet .row { background: #201c16; }

/* ---------- модальне вікно ---------- */
#modal { position: absolute; inset: 0; z-index: 50; display: none; align-items: center; justify-content: center; padding: 20px 20px 20px calc(var(--spine) + 14px); background: rgba(4, 6, 9, .72); }
#modal.on { display: flex; animation: vFade .18s; }
.md { width: 100%; max-width: 380px; max-height: 100%; display: flex; flex-direction: column; border-radius: 22px; background: var(--s2); border: 1px solid var(--line2); box-shadow: 0 24px 60px rgba(0, 0, 0, .6); animation: pop .22s; }
.md h3 { flex: none; padding: 16px 18px 4px; font-size: 18px; } .md-b { flex: 1; min-height: 0; overflow-y: auto; padding: 6px 18px 4px; font-size: 14.5px; line-height: 1.48; color: #d5dce5; } .md-b p { margin-bottom: 8px; }
.md-f { flex: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 14px 14px; } .md-f .btn { flex: 1 1 auto; }
.achs { display: flex; flex-direction: column; gap: 6px; } .ach { display: flex; gap: 12px; align-items: center; padding: 9px 10px; border-radius: 12px; background: rgba(0, 0, 0, .22); opacity: .55; } .ach.got { opacity: 1; background: rgba(255, 180, 84, .1); }
.ach-i { width: 36px; height: 36px; border-radius: 50%; flex: none; display: flex; align-items: center; justify-content: center; background: var(--s3); color: var(--dim); font-size: 17px; } .ach.got .ach-i { background: var(--acc); color: var(--acc-ink); } .ach b { display: block; font-size: 14.5px; } .ach small { display: block; font-size: 12.5px; color: var(--dim); line-height: 1.35; }
.howto { list-style: none; display: flex; flex-direction: column; gap: 10px; } .howto li { display: flex; gap: 12px; align-items: flex-start; } .howto .adi { color: var(--acc); font-size: 19px; margin-top: 2px; }

/* ---------- титул, вступ, кінцівки ---------- */
#power { position: absolute; inset: 0; z-index: 40; display: none; background: #05070a; }
#power.on { display: flex; animation: vFade .5s; }
#power.end.first { animation: vFade 1.8s; }
.tt { position: relative; flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: calc(24px + var(--sat)) 34px calc(20px + var(--sab)); text-align: center; overflow: hidden; }
.tt-glow { position: absolute; left: 50%; top: 20%; width: 150%; aspect-ratio: 1; transform: translate(-50%, -50%); background: radial-gradient(closest-side, rgba(255, 180, 84, .16), rgba(95, 212, 196, .05) 55%, transparent); pointer-events: none; animation: glow 5s ease-in-out infinite alternate; } @keyframes glow { to { opacity: .55; } }
.tt-logo { position: relative; font-size: 34px; color: var(--acc); margin-bottom: 18px; animation: glow 2.4s ease-in-out infinite alternate; }
.tt h1 { position: relative; font-family: 'Unbounded', 'Onest', system-ui, sans-serif; font-weight: 700; font-size: clamp(31px, 10.5vmin, 44px); line-height: 1.08; letter-spacing: .05em; }
.tt-sub { position: relative; margin-top: 12px; color: var(--dim); font-size: 14.5px; }
.tt-btns { position: relative; display: flex; flex-direction: column; gap: 10px; width: min(290px, 100%); margin-top: 5vh; } .tt-row { display: flex; gap: 8px; } .tt-row .btn { flex: 1 1 auto; min-width: 0; padding-left: 9px; padding-right: 9px; white-space: nowrap; font-size: 13.5px; gap: 6px; }
.tt-home { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; color: var(--dim); font-size: 14px; }
.tt-foot { position: relative; margin-top: 3vh; font-size: 12px; color: var(--faint); }
.in-w { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 30px; padding: calc(30px + var(--sat)) 36px calc(30px + var(--sab)) 40px; text-align: center; cursor: pointer; }
.in-t { max-width: 420px; font-size: 18.5px; line-height: 1.6; color: #e3e8ee; animation: inT .8s ease-out; } @keyframes inT { from { opacity: 0; transform: translateY(10px); } }
.in-b { min-width: 150px; } .in-d { display: flex; gap: 7px; } .in-d i { width: 7px; height: 7px; border-radius: 50%; background: #2c3745; } .in-d i.on { background: var(--acc); }
#power.end.bad { background: radial-gradient(120% 80% at 50% 100%, #2a1014, #05070a 70%); } #power.end.good { background: radial-gradient(120% 80% at 50% 100%, #10261f, #05070a 70%); } #power.end.neutral { background: radial-gradient(120% 80% at 50% 100%, #1b2029, #05070a 70%); }
.en { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: calc(24px + var(--sat)) 24px calc(20px + var(--sab)) 30px; text-align: center; }
.en > small { font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--dim); } .en h2 { margin-top: 8px; font-family: 'Unbounded', 'Onest', system-ui, sans-serif; font-size: clamp(25px, 8vmin, 34px); line-height: 1.15; }
.bad .en h2 { color: #ff9c9c; } .good .en h2 { color: #8fe3c0; } .neutral .en h2 { color: #c8d2de; }
.en-st { display: flex; gap: 22px; margin-top: 22px; } .en-st span { display: flex; flex-direction: column; font-size: 12px; color: var(--dim); } .en-st b { font-size: 21px; color: var(--tx); }
.en-n { margin-top: 16px; font-size: 13.5px; color: var(--dim); } .en .tt-btns { margin-top: 3.5vh; }

@media (max-height: 640px) {
    .lk-top { padding: 1.4vh 0 1.4vh; } .lk-time { font-size: 46px; } .pad-keys { gap: 7px 22px; } .pk { height: 46px; } .pad-ic { display: none; } .pad-dots { margin-top: 12px; }
    .kk { height: 38px; } .hw { padding: 1vh 8px 1.6vh; } .hw-t { font-size: 32px; } .grid { gap: 10px 2px; } .aic { width: 48px; height: 48px; font-size: 21px; } .tt-btns { margin-top: 3vh; } .tt-logo { display: none; }
    .pat-g { width: min(220px, 62%); } .rg-b { margin-top: 5vh; }
}
@media (prefers-reduced-motion: reduce) {
    *, *:before, *:after { animation-duration: .001s !important; animation-iteration-count: 1 !important; transition-duration: .001s !important; }
    .ct-drift { animation: none !important; }
}
