/* Куратор: фарфор, графит, вишня. Основа — утверждённый макет, ниже — части рабочего сайта. */
:root {
  --bg: #f3f0ee; --bg2: #ffffff; --bg3: #ece8e6; --ink: #1d191a; --mid: #4a4345; --dim: #8a8184; --line: rgba(38, 26, 24, .1);
  --red: #b3162e; --red-deep: #b3162e; --pink: #d1304a; --ok: #1f8a55; --btn: #b3162e; --btn-ink: #ffffff;
  --panel: #211d1f; --on-panel: #f6f2f3; --on-panel-dim: #a79ea1; --hot: #ff8b9c;
  --body: "Golos Text", system-ui, sans-serif; --wide: "Geologica", "Golos Text", sans-serif; --mono: "Golos Text", system-ui, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1); --spring: cubic-bezier(.3, 1.4, .4, 1);
}
:root[data-theme="dark"] {
  --bg: #141112; --bg2: #1e1a1b; --bg3: #2a2527; --ink: #f3eff0; --mid: #cfc7c9; --dim: #948b8e; --line: rgba(255, 240, 244, .1);
  --red: #e0304b; --red-deep: #c4203a; --pink: #ff6f86; --ok: #58c98c; --btn: #e0304b; --btn-ink: #ffffff; --panel: #1e1a1b;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--body); font-size: 16px; line-height: 1.45; -webkit-font-smoothing: antialiased; transition: background-color .5s, color .5s; overflow-x: hidden; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; text-align: left; }
button:focus-visible, textarea:focus-visible, input:focus-visible { outline: 2px solid var(--pink); outline-offset: 3px; }
.mono { font-family: var(--mono); font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); }
.app { max-width: 1120px; margin: 0 auto; min-height: 100%; display: grid; grid-template-columns: 220px 1fr; }

/* меню: только слова, красная черта переезжает к выбранному */
.side { position: sticky; top: 0; height: 100vh; padding: 28px 0 24px 28px; display: flex; flex-direction: column; border-right: 1px solid var(--line); }
.brand { font-family: var(--wide); font-weight: 700; font-size: 21px; letter-spacing: -.01em; margin-bottom: 44px; }
.brand span { color: var(--red); }
.nav { position: relative; display: flex; flex-direction: column; }
.nav .bar { position: absolute; left: -28px; top: 0; width: 3px; height: 52px; background: var(--red); transition: transform .5s var(--spring); }
.nav button { height: 52px; display: flex; align-items: center; gap: 14px; font-size: 17px; font-weight: 500; color: var(--dim); transition: color .3s, transform .35s var(--ease); }
.nav button i { display: none; }
.nav button:hover { color: var(--ink); transform: translateX(4px); }
.nav button.on { color: var(--ink); }
.nav button.on i { color: var(--red); }
.nav .cnt { font-size: 12px; font-weight: 600; color: #fff; background: var(--red); padding: 1px 8px; border-radius: 10px; margin-left: auto; margin-right: 22px; animation: beat 2.6s var(--ease) infinite; }
@keyframes beat { 0%, 100% { transform: scale(1); } 8% { transform: scale(1.18); } 16% { transform: scale(1); } }
.side .foot { margin-top: auto; display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.theme { display: inline-flex; align-items: center; gap: 10px; }
.theme b { width: 36px; height: 20px; border-radius: 10px; background: var(--bg3); position: relative; display: block; }
.theme b::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--ink); transition: transform .45s var(--spring); }
:root[data-theme="dark"] .theme b::after { transform: translateX(16px); }

.main { min-width: 0; padding: 28px 36px 120px; }
.view { display: none; }
.view.on { display: block; animation: viewIn .5s var(--ease) both; }
@keyframes viewIn { from { opacity: 0; transform: translateY(14px); } }
h1 { font-family: var(--wide); font-weight: 700; font-size: clamp(34px, 6vw, 54px); letter-spacing: -.035em; line-height: 1.02; margin: 6px 0 0; }
h1 em { font-style: normal; color: var(--red); }
.lead-in { color: var(--mid); margin: 14px 0 0; max-width: 46ch; }

/* крупная цифра с прокруткой */
.hero { display: flex; align-items: flex-end; gap: 22px; margin: 26px 0 30px; padding: 26px 28px; border-radius: 22px; background: var(--panel); color: var(--on-panel); flex-wrap: wrap; position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; right: -60px; top: -90px; width: 260px; height: 260px; border-radius: 50%; border: 44px solid rgba(255, 255, 255, .035); animation: drift 14s ease-in-out infinite alternate; }
@keyframes drift { to { transform: translate(-30px, 26px) scale(1.08); } }
.hero > * { position: relative; }
.hero.plain { background: none; color: inherit; padding: 0; overflow: visible; } .hero.plain::before { display: none; }
.roll { font-family: var(--wide); font-weight: 500; font-size: clamp(64px, 13vw, 112px); line-height: .9; font-weight: 700; color: var(--hot); display: flex; height: .9em; overflow: hidden; }
.roll span { display: flex; flex-direction: column; transition: transform 1.4s var(--ease); }
.roll span b { height: .9em; font-weight: inherit; display: block; }
.hero p { margin: 0 0 6px; font-size: 19px; line-height: 1.25; }
.hero p small { display: block; color: var(--on-panel-dim); font-size: 14px; margin-top: 6px; }
.hero .cta { margin-left: auto; }

.btn { display: inline-flex; align-items: center; gap: 14px; background: var(--btn); color: var(--btn-ink); padding: 15px 22px; border-radius: 14px; font-weight: 600; transition: transform .3s var(--ease), box-shadow .3s; position: relative; overflow: hidden; }
.btn::after { content: ""; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 40%, rgba(255, 255, 255, .5) 50%, transparent 60%); transform: translateX(-120%); }
.btn:hover { transform: translateY(-2px); }
.btn:hover::after { transform: translateX(120%); transition: transform .7s var(--ease); }
.btn:active { transform: scale(.97); }
.btn.ghost { background: var(--bg2); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }
.btn.ghost::after { display: none; }
.btn.ghost:hover { box-shadow: inset 0 0 0 1px var(--ink); }
.arr { width: 18px; height: 12px; position: relative; flex: none; transition: transform .35s var(--ease); }
.arr::before { content: ""; position: absolute; left: 0; right: 1px; top: 5px; height: 1.6px; background: currentColor; transition: left .35s var(--ease); }
.arr::after { content: ""; position: absolute; right: 0; top: 1px; width: 8px; height: 8px; border-top: 1.6px solid currentColor; border-right: 1.6px solid currentColor; transform: rotate(45deg); }
.btn:hover .arr, .row:hover .arr { transform: translateX(5px); }

/* вкладки-слова с ездящей чертой */
.tabs { position: relative; display: flex; gap: 28px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.tabs button { padding: 12px 0 14px; color: var(--dim); font-weight: 500; transition: color .3s; display: flex; gap: 8px; align-items: baseline; }
.tabs button sup { font-size: 12px; font-weight: 600; color: var(--red); }
.tabs button.on, .tabs button:hover { color: var(--ink); }
.tabs .ul { position: absolute; bottom: -1px; left: 0; height: 2px; background: var(--red); transition: transform .5s var(--spring), width .5s var(--spring); }

/* строки вместо карточек */
.row { position: relative; display: grid; grid-template-columns: 42px 1fr auto; gap: 14px; align-items: center; width: 100%; padding: 20px 6px 20px 0; border-bottom: 1px solid var(--line); transition: padding .4s var(--ease), background-color .3s; }
.row::before { content: ""; position: absolute; left: 0; bottom: -1px; height: 1px; width: 100%; background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .55s var(--ease); }
.row:hover { padding-left: 12px; }
.row:hover::before { transform: scaleX(1); }
.row .n { font-family: var(--wide); font-weight: 600; font-size: 15px; color: var(--red); width: 42px; height: 42px; border-radius: 12px; background: color-mix(in srgb, var(--red) 9%, transparent); display: grid; place-items: center; transition: transform .45s var(--spring); }
.row:hover .n { transform: scale(1.08) rotate(-5deg); }
.row .nm { font-size: 18.5px; font-weight: 500; letter-spacing: -.01em; display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.row .nm .mono { font-size: 10.5px; padding: 2px 7px; border-radius: 6px; background: var(--bg3); letter-spacing: .04em; }
.row .nt { display: block; color: var(--dim); font-size: 14.5px; margin-top: 3px; }
.row .nt b { color: var(--mid); font-weight: 500; }
.row.hot .nt b { color: var(--pink); }
.row .r { display: flex; align-items: center; gap: 16px; color: var(--dim); font-size: 13.5px; }
.row .arr { color: var(--ink); opacity: 0; transition: opacity .3s, transform .35s var(--ease); }
.row:hover .arr { opacity: 1; }
.list { background: var(--bg2); border-radius: 20px; padding: 2px 20px; box-shadow: 0 0 0 1px var(--line); }
.list > :last-child { border-bottom: 0; }
.ava { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; font-family: var(--wide); font-weight: 600; font-size: 14px; transition: transform .45s var(--spring); }
.row:hover .ava { transform: scale(1.1) rotate(-6deg); }
.list .row { animation: rowIn .6s var(--ease) both; }
.list .row:nth-child(2) { animation-delay: .05s; } .list .row:nth-child(3) { animation-delay: .1s; } .list .row:nth-child(4) { animation-delay: .15s; } .list .row:nth-child(5) { animation-delay: .2s; } .list .row:nth-child(n+6) { animation-delay: .25s; }
@keyframes rowIn { from { opacity: 0; transform: translateY(16px); } }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--pink); box-shadow: 0 0 0 0 var(--pink); animation: ping 2s infinite; flex: none; }
@keyframes ping { to { box-shadow: 0 0 0 9px transparent; } }

/* раскрывающееся содержимое */
.fold { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .5s var(--ease); border-bottom: 0 solid var(--line); }
.fold > div { overflow: hidden; }
.fold.open { grid-template-rows: 1fr; border-bottom-width: 1px; }
.fold .in { padding: 6px 0 24px 56px; display: flex; flex-direction: column; gap: 14px; color: var(--mid); max-width: 640px; }
.plus { width: 14px; height: 14px; position: relative; flex: none; color: var(--ink); transition: transform .45s var(--spring); }
.plus::before, .plus::after { content: ""; position: absolute; background: currentColor; }
.plus::before { left: 0; right: 0; top: 6px; height: 1.6px; } .plus::after { top: 0; bottom: 0; left: 6px; width: 1.6px; transition: transform .45s var(--spring); }
.row.open .plus { transform: rotate(180deg); } .row.open .plus::after { transform: scaleY(0); }
.flows { display: flex; gap: 10px; flex-wrap: wrap; }
.flow { border: 1px solid var(--line); padding: 10px 14px; border-radius: 12px; background: var(--bg); transition: border-color .3s, transform .3s var(--ease); }
.flow:hover { border-color: var(--red); transform: translateY(-2px); }
.flow b { font-family: var(--wide); font-weight: 600; font-size: 15px; display: block; }
.flow span { font-size: 12.5px; color: var(--dim); }
.meter { height: 5px; border-radius: 3px; overflow: hidden; background: var(--bg3); width: 90px; position: relative; }
.meter i { position: absolute; inset: 0; background: var(--ok); transform-origin: left; animation: grow 1.2s var(--ease) both .3s; }
.meter.low i { background: var(--pink); }
@keyframes grow { from { transform: scaleX(0); } }
.plan { counter-reset: p; display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; list-style: none; }
.plan li { counter-increment: p; display: grid; grid-template-columns: 30px 1fr; color: var(--ink); }
.plan li::before { content: counter(p); font-family: var(--wide); font-weight: 600; color: var(--red); }
.step { display: flex; align-items: center; gap: 16px; }
.step .num { font-family: var(--wide); font-size: 34px; font-weight: 700; min-width: 2ch; text-align: center; display: inline-block; }
.step .num.bump { animation: bump .35s var(--spring); }
@keyframes bump { 40% { transform: translateY(-6px) scale(1.12); color: var(--red); } }
.step button { width: 38px; height: 38px; border: 1px solid var(--dim); border-radius: 10px; display: grid; place-items: center; font-size: 20px; line-height: 1; transition: border-color .25s, transform .25s var(--spring), background-color .25s; }
.step button:hover { border-color: var(--ink); } .step button:active { transform: scale(.88); background: var(--bg3); }
.step span { color: var(--dim); }

/* переписка */
.back { display: flex; width: max-content; align-items: center; gap: 12px; color: var(--dim); margin-bottom: 18px; transition: color .3s; }
.back .arr { transform: rotate(180deg); }
.back:hover { color: var(--ink); } .back:hover .arr { transform: rotate(180deg) translateX(5px); }
.note-ai { border-radius: 16px; background: color-mix(in srgb, var(--red) 7%, var(--bg2)); padding: 14px 18px; margin: 22px 0 26px; max-width: 640px; }
.note-ai p { margin: 6px 0 0; font-size: 17px; }
.note-ai p b { font-weight: 500; color: var(--pink); }
.msgs { display: flex; flex-direction: column; gap: 10px; max-width: 640px; }
.msg { max-width: 82%; padding: 11px 15px; border-radius: 16px 16px 16px 5px; background: var(--bg2); box-shadow: 0 0 0 1px var(--line); align-self: flex-start; animation: msgIn .5s var(--spring) both; }
.msg.out { align-self: flex-end; background: color-mix(in srgb, var(--red) 10%, var(--bg2)); border-radius: 14px 14px 3px 14px; box-shadow: inset 0 0 0 1px var(--line); }
.msg small { display: block; margin-top: 4px; font-size: 11.5px; color: var(--dim); text-align: right; }
.msg.pic { padding: 8px; } .msg.pic div { width: 190px; height: 120px; border-radius: 9px; background: repeating-linear-gradient(0deg, var(--bg3) 0 9px, transparent 9px 18px), var(--bg); box-shadow: inset 0 0 0 1px var(--line); }
@keyframes msgIn { from { opacity: 0; transform: translateY(12px) scale(.96); } }
.typing { display: flex; gap: 5px; padding: 16px; } .typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--dim); animation: bl 1.1s infinite; } .typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes bl { 0%, 70%, 100% { opacity: .25; transform: translateY(0); } 35% { opacity: 1; transform: translateY(-4px); } }
.composer { display: flex; gap: 10px; align-items: flex-end; margin-top: 26px; max-width: 640px; border-bottom: 1px solid var(--dim); transition: border-color .3s; }
.composer:focus-within { border-color: var(--red); }
.composer textarea { flex: 1; background: none; border: 0; outline: 0; color: var(--ink); font: inherit; resize: none; padding: 14px 0; min-height: 52px; }
.composer textarea::placeholder { color: var(--dim); }
.send { width: 46px; height: 46px; margin-bottom: 4px; border-radius: 50%; background: var(--red-deep); color: #fff; display: grid; place-items: center; overflow: hidden; transition: transform .3s var(--spring), background-color .3s; }
.send:hover { background: var(--red); transform: translateY(-2px); }
.send .arr { transform: rotate(-90deg); }
.send.fly .arr { animation: fly .55s var(--ease); }
@keyframes fly { 45% { transform: rotate(-90deg) translateX(30px); opacity: 0; } 46% { transform: rotate(-90deg) translateX(-30px); opacity: 0; } 100% { transform: rotate(-90deg); opacity: 1; } }

.cap { display: flex; justify-content: space-between; align-items: center; margin: 30px 2px 12px; }
.cap button { display: inline-flex; align-items: center; gap: 10px; color: var(--red); font-weight: 600; font-size: 14.5px; }
.cap button:hover .arr { transform: translateX(5px); }
.soon { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.soon-i { background: var(--bg2); border-radius: 18px; padding: 16px 18px; box-shadow: 0 0 0 1px var(--line); display: flex; flex-direction: column; gap: 2px; transition: transform .35s var(--ease), box-shadow .35s; }
.soon-i:hover { transform: translateY(-4px); box-shadow: 0 0 0 1px var(--line), 0 16px 30px -18px rgba(40, 14, 20, .4); }
.soon-i b { font-family: var(--wide); font-weight: 700; font-size: 26px; letter-spacing: -.02em; color: var(--red); }
.soon-i span { font-weight: 600; } .soon-i small { color: var(--dim); font-size: 13px; }
.ring { width: 42px; height: 42px; transform: rotate(-90deg); transition: transform .5s var(--spring); }
.ring circle { fill: none; stroke-width: 4; stroke-linecap: round; }
.ring .tr { stroke: var(--bg3); } .ring .pr { stroke: var(--ok); stroke-dasharray: 106.8; stroke-dashoffset: calc(106.8px * (1 - var(--p))); animation: ringIn 1.3s var(--ease) both .2s; }
.ring.part .pr { stroke: var(--red); }
@keyframes ringIn { from { stroke-dashoffset: 106.8px; } }
.row:hover .ring { transform: rotate(-90deg) scale(1.1); }
.row.off .nm, .row.off .nt { opacity: .5; } .row.off .ring .pr { stroke: var(--dim); }
.row.bare { grid-template-columns: 1fr auto; } .row.bare + .fold .in { padding-left: 0; }
.miss { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.miss b { font-weight: 600; color: var(--ink); }
.chip { font-size: 13.5px; font-weight: 500; padding: 5px 12px; border-radius: 9px; background: color-mix(in srgb, var(--pink) 12%, transparent); color: var(--pink); transition: transform .3s var(--spring), background-color .25s; }
button.chip:hover { transform: translateY(-2px); background: color-mix(in srgb, var(--pink) 20%, transparent); }
.chip.ok { background: color-mix(in srgb, var(--ok) 13%, transparent); color: var(--ok); }
.onoff { display: flex; align-items: center; gap: 12px; color: var(--ink); }
.sw { width: 46px; height: 26px; border-radius: 13px; background: var(--bg3); position: relative; flex: none; transition: background-color .3s; }
.sw::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, .25); transition: transform .45s var(--spring); }
.sw.on { background: var(--ok); } .sw.on::after { transform: translateX(20px); }
.pays { display: flex; flex-direction: column; gap: 8px; }
.pay { display: grid; grid-template-columns: 110px 1fr; gap: 12px; align-items: baseline; padding: 12px 14px; border-radius: 12px; background: var(--bg); border: 1px solid var(--line); transition: border-color .3s, transform .3s var(--ease); }
.pay:hover { border-color: var(--red); transform: translateX(4px); }
.pay b { font-weight: 600; color: var(--ink); } .pay span { font-size: 14.5px; color: var(--mid); }
.pay.add { border-style: dashed; } .pay.add b { color: var(--red); white-space: nowrap; }
@media (max-width: 820px) { .pay { grid-template-columns: 1fr; gap: 2px; } }
.acts { display: flex; gap: 10px; flex-wrap: wrap; }
.addbox { display: flex; flex-direction: column; gap: 14px; background: var(--bg2); border-radius: 20px; padding: 20px; margin-bottom: 18px; box-shadow: 0 0 0 1px var(--line); }
#addfold { border: 0; }
.addbox textarea { width: 100%; background: var(--bg); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; font: inherit; color: var(--ink); resize: vertical; outline: 0; transition: border-color .3s, box-shadow .3s; }
.addbox textarea:focus { border-color: var(--red); box-shadow: 0 0 0 4px color-mix(in srgb, var(--red) 10%, transparent); }
.addrow { display: flex; gap: 10px; flex-wrap: wrap; }
.found { display: flex; flex-wrap: wrap; gap: 8px; }
.found .chip { animation: chipIn .5s var(--spring) both; }
@keyframes chipIn { from { opacity: 0; transform: translateY(8px) scale(.9); } }
.ask { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.ask label { display: grid; grid-template-columns: 150px 1fr; gap: 12px; align-items: center; font-weight: 500; animation: chipIn .5s var(--spring) both; }
.ask input { background: var(--bg); border: 1px solid var(--line); border-radius: 11px; padding: 10px 13px; font: inherit; color: var(--ink); outline: 0; min-width: 0; }
.ask input:focus { border-color: var(--red); }
#addbtn .plus { color: #fff; } #addbtn.open .plus { transform: rotate(135deg); }
@media (max-width: 820px) { .ask label { grid-template-columns: 1fr; gap: 4px; } }
.tag { font-size: 12px; font-weight: 600; padding: 2px 9px; border-radius: 7px; background: color-mix(in srgb, var(--pink) 14%, transparent); color: var(--pink); }
.hint { position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); background: var(--bg3); color: var(--mid); font-size: 13px; padding: 9px 16px; border-radius: 11px; box-shadow: 0 0 0 1px var(--line); z-index: 9; white-space: nowrap; }

@media (max-width: 820px) {
  .app { display: block; }
  .side { position: fixed; z-index: 8; left: 0; right: 0; bottom: 0; top: auto; height: auto; padding: 0 12px calc(8px + env(safe-area-inset-bottom, 0px)); border-right: 0; border-top: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
  .brand, .side .foot .mono { display: none; }
  .nav { flex-direction: row; }
  .nav button { flex: 1; justify-content: center; font-size: 14px; gap: 6px; }
  .nav button:hover { transform: none; }
  .nav .bar { left: 0; top: -1px; height: 3px; width: calc(100% / 4); }
  .nav .cnt { margin: 0 0 0 2px; }
  .side .foot { display: none; }
  .main { padding: 22px 18px 110px; }
  .row { grid-template-columns: 42px 1fr auto; padding: 16px 0; } .list { padding: 2px 14px; border-radius: 18px; }
  .row .r time, .row .meter { display: none; }
  .fold .in { padding-left: 0; }
  .hero .cta { margin-left: 0; width: 100%; } .hero .cta .btn { width: 100%; justify-content: space-between; }
  .hint { bottom: 76px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---- рабочий сайт: то, чего не было в макете ---- */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #141112; --bg2: #1e1a1b; --bg3: #2a2527; --ink: #f3eff0; --mid: #cfc7c9; --dim: #948b8e; --line: rgba(255, 240, 244, .1);
    --red: #e0304b; --red-deep: #c4203a; --pink: #ff6f86; --ok: #58c98c; --btn: #e0304b; --btn-ink: #ffffff; --panel: #1e1a1b; color-scheme: dark;
  }
}
input, textarea, select { font: inherit; color: var(--ink); }
a { color: var(--red); }
.nav .bar { transition: transform .5s var(--spring); }
.nav.n4 .bar { width: auto; }
.side .foot button.out { color: var(--dim); font-size: 14px; transition: color .3s; }
.side .foot button.out:hover { color: var(--ink); }
.row[disabled] { opacity: .5; }
.warn { display: flex; gap: 14px; align-items: center; justify-content: space-between; flex-wrap: wrap; border-radius: 16px; padding: 14px 18px; margin-top: 14px; background: color-mix(in srgb, #c98a12 13%, var(--bg2)); color: var(--ink); font-size: 15px; }
.warn b { font-weight: 600; }
.warn button { color: var(--red); font-weight: 600; white-space: nowrap; }
.empty { padding: 34px 0; text-align: center; color: var(--dim); }
.search { display: flex; align-items: center; gap: 10px; background: var(--bg2); border-radius: 14px; padding: 0 16px; margin: 18px 0 4px; box-shadow: 0 0 0 1px var(--line); transition: box-shadow .3s; }
.search:focus-within { box-shadow: 0 0 0 1px var(--red), 0 0 0 4px color-mix(in srgb, var(--red) 10%, transparent); }
.search input { flex: 1; border: 0; background: none; outline: 0; padding: 13px 0; min-width: 0; }
.search i { width: 14px; height: 14px; border: 1.8px solid var(--dim); border-radius: 50%; position: relative; flex: none; }
.search i::after { content: ""; position: absolute; width: 6px; height: 1.8px; background: var(--dim); right: -5px; bottom: -2px; transform: rotate(45deg); }
.headrow { display: flex; align-items: flex-end; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.btn.sm { padding: 10px 16px; border-radius: 11px; font-size: 14.5px; gap: 10px; }
.btn.ok { background: var(--ok); color: #fff; }
.btn[disabled] { opacity: .55; pointer-events: none; }
.btn .spin { width: 16px; height: 16px; border-radius: 50%; border: 2px solid color-mix(in srgb, currentColor 35%, transparent); border-top-color: currentColor; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.row .nt.hot b, .row.hot .nt b { color: var(--pink); }
.row .nt { overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.row.sel { background: color-mix(in srgb, var(--red) 5%, transparent); }

/* переписка */
.chat-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 14px; }
.pill { display: inline-flex; align-items: center; gap: 7px; font-size: 13.5px; font-weight: 500; padding: 6px 12px; border-radius: 9px; background: var(--bg2); box-shadow: 0 0 0 1px var(--line); transition: transform .3s var(--spring), box-shadow .3s; }
button.pill:hover { transform: translateY(-2px); box-shadow: 0 0 0 1px var(--dim); }
.pill i { width: 7px; height: 7px; border-radius: 50%; background: var(--dim); }
.pill.st-talk i { background: #2c69ad; } .pill.st-thinking i { background: #c98a12; } .pill.st-pay i { background: var(--red); } .pill.st-paid i { background: var(--ok); } .pill.st-call i { background: #6a52c0; }
.note-ai small { display: block; margin-top: 8px; color: var(--dim); font-size: 13.5px; }
.need { border-radius: 16px; padding: 14px 18px; margin: 0 0 22px; max-width: 640px; background: var(--panel); color: var(--on-panel); display: flex; flex-direction: column; gap: 12px; animation: rowIn .5s var(--ease) both; }
.need p { margin: 0; font-size: 16px; } .need p span { display: block; font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--on-panel-dim); margin-bottom: 3px; }
.need .acts .btn.ghost { background: rgba(255, 255, 255, .08); color: var(--on-panel); box-shadow: none; }
.need .acts .btn.ghost:hover { background: rgba(255, 255, 255, .14); }
.msg { white-space: pre-wrap; word-wrap: break-word; }
.msg.old { animation: none; }
.msg img { display: block; max-width: 260px; max-height: 320px; border-radius: 10px; cursor: zoom-in; }
.msg .att { color: var(--dim); font-style: italic; }
.msg.out small b { color: var(--red); font-weight: 600; }
.sysline { align-self: center; max-width: 92%; text-align: center; font-size: 13px; color: var(--dim); padding: 4px 12px; }
.sysline.warnline { color: var(--pink); font-weight: 500; }
.dayline { align-self: center; font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); margin: 10px 0 2px; }
.composer.test { border-bottom-style: dashed; }
.tools { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; max-width: 640px; }
.zoom { position: fixed; inset: 0; z-index: 40; background: rgba(10, 6, 7, .86); display: grid; place-items: center; cursor: zoom-out; animation: fade .25s both; }
.zoom img { max-width: 94vw; max-height: 94vh; border-radius: 12px; }
@keyframes fade { from { opacity: 0; } }

/* формы и окна */
.field { width: 100%; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; outline: 0; transition: border-color .3s, box-shadow .3s; }
.field:hover { border-color: color-mix(in srgb, var(--ink) 22%, transparent); }
.field:focus { border-color: var(--red); box-shadow: 0 0 0 4px color-mix(in srgb, var(--red) 10%, transparent); }
textarea.field { resize: vertical; min-height: 96px; line-height: 1.45; }
select.field { appearance: none; padding-right: 34px; background-image: linear-gradient(45deg, transparent 50%, var(--dim) 50%), linear-gradient(135deg, var(--dim) 50%, transparent 50%); background-position: calc(100% - 19px) 55%, calc(100% - 13px) 55%; background-size: 6px 6px; background-repeat: no-repeat; }
.lab { display: block; font-size: 13px; font-weight: 600; color: var(--dim); margin-bottom: 6px; }
.lab em { font-style: normal; font-weight: 400; }
.form { display: flex; flex-direction: column; gap: 14px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.scrim { position: fixed; inset: 0; z-index: 30; background: rgba(18, 8, 11, .46); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 18px; animation: fade .25s both; }
.scrim.out { animation: fade .2s reverse both; }
.sheet { width: 100%; max-width: 620px; max-height: 90vh; overflow-y: auto; background: var(--bg2); border-radius: 22px; padding: 24px; display: flex; flex-direction: column; gap: 16px; box-shadow: 0 30px 70px -30px rgba(20, 6, 10, .6); animation: sheetIn .45s var(--spring) both; }
@keyframes sheetIn { from { opacity: 0; transform: translateY(26px) scale(.97); } }
.sheet h3 { font-family: var(--wide); font-weight: 700; font-size: 24px; letter-spacing: -.02em; margin: 0; }
.sheet .sh { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; }
.sheet .x { width: 34px; height: 34px; border-radius: 50%; background: var(--bg3); display: grid; place-items: center; flex: none; transition: transform .4s var(--spring), background-color .3s, color .3s; }
.sheet .x:hover { transform: rotate(90deg); background: color-mix(in srgb, var(--red) 14%, transparent); color: var(--red); }
.sheet .x .plus { transform: rotate(45deg); }
.sheet .hint2 { color: var(--dim); font-size: 14px; margin: -8px 0 0; }
.opts { display: flex; flex-direction: column; gap: 4px; }
.opt { display: flex; align-items: center; gap: 12px; padding: 13px 14px; border-radius: 12px; font-weight: 500; transition: background-color .25s, transform .3s var(--ease); }
.opt:hover { background: var(--bg); transform: translateX(4px); }
.opt.on { background: color-mix(in srgb, var(--red) 9%, transparent); color: var(--red); }
.opt i { width: 8px; height: 8px; border-radius: 50%; background: var(--dim); flex: none; }
@media (max-width: 820px) { .scrim { align-items: flex-end; padding: 0; } .sheet { border-radius: 22px 22px 0 0; max-height: 92vh; padding: 20px 18px calc(20px + env(safe-area-inset-bottom, 0px)); animation-name: sheetUp; } .two { grid-template-columns: 1fr; } }
@keyframes sheetUp { from { transform: translateY(100%); } }
.toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 50; background: var(--panel); color: var(--on-panel); padding: 12px 18px; border-radius: 12px; font-size: 14.5px; font-weight: 500; max-width: calc(100% - 32px); box-shadow: 0 16px 40px -18px rgba(0, 0, 0, .6); animation: toastIn .45s var(--spring) both; }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 16px) scale(.96); } }
@media (max-width: 820px) { .toast { bottom: 84px; } }
.offline { position: fixed; top: 10px; left: 50%; transform: translateX(-50%); z-index: 60; background: var(--panel); color: var(--on-panel); padding: 8px 14px; border-radius: 11px; font-size: 13.5px; }

/* курс и школа */
.kf { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: start; width: 100%; padding: 12px 0; border-bottom: 1px solid var(--line); transition: padding .35s var(--ease); }
.kf:last-child { border-bottom: 0; }
.kf:hover { padding-left: 8px; }
.kf b { display: block; font-weight: 600; color: var(--ink); }
.kf span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 14.5px; color: var(--mid); margin-top: 2px; }
.kf.none > span > span { color: var(--dim); font-style: italic; }
.kf em { font-style: normal; font-size: 13px; font-weight: 600; color: var(--red); white-space: nowrap; padding-top: 2px; }
.kf.req.none b::after { content: " · не заполнено"; color: var(--pink); font-weight: 500; font-size: 13px; }
.flow { display: flex; align-items: center; gap: 12px; }
.flow.full b { text-decoration: line-through; opacity: .6; }
.flow button.rm { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: var(--dim); transition: color .25s, transform .3s var(--spring); }
.flow button.rm:hover { color: var(--red); transform: rotate(90deg); }
.flow button.rm .plus { transform: rotate(45deg); width: 11px; height: 11px; } .flow button.rm .plus::before { top: 4.7px; } .flow button.rm .plus::after { left: 4.7px; }
.flow.add { border-style: dashed; color: var(--red); font-weight: 600; cursor: pointer; }
.paybox { display: flex; flex-direction: column; gap: 8px; }
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.login-card { width: 100%; max-width: 400px; display: flex; flex-direction: column; gap: 14px; animation: viewIn .6s var(--ease) both; }
.login-card h1 { font-size: 40px; }
.login-card p { margin: -4px 0 8px; color: var(--mid); }
.check { display: flex; align-items: center; gap: 10px; font-size: 15px; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--red); }
.err { color: var(--pink); font-size: 14.5px; font-weight: 500; }
.okline { color: var(--ok); font-weight: 600; font-size: 14.5px; }
.usage { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; font-size: 15px; }
.usage b { font-family: var(--wide); font-weight: 600; }
.sandbox { display: flex; flex-direction: column; gap: 8px; max-height: 44vh; overflow-y: auto; padding: 4px 2px; }
@media (max-width: 820px) {
  .nav.n4 button { font-size: 13.5px; }
  .headrow .btn { width: 100%; justify-content: space-between; }
  .msg img { max-width: 200px; }
}
.kf .okline { color: var(--ok); } .kf .err { color: var(--pink); }
.kf > span > span > span { display: inline; margin: 0; }
