/* ═══════════════════════════════════════════════════════════════════════════
   Dip Desk — пульт спот-бота Bybit.
   Палитра взята из самого предмета: ночной торговый терминал, свечи,
   ленты ордеров, UTC-таймер интервала.
   ═══════════════════════════════════════════════════════════════════════════ */

:root {
    --ink: #05070E;
    --ink2: #080C16;
    --surface: #0C1220;
    --surface2: #111A2B;
    --raise: #16203A;
    --line: #1E2A42;
    --line-soft: #172136;
    --text: #E8EEF9;
    --muted: #8FA3BF;
    --dim: #5C6E8C;
    --cyan: #22D3EE;
    --violet: #8B5CF6;
    --lime: #3DF58B;
    --coral: #FF4D6D;
    --amber: #FFB020;
    --azure: #4C8DFF;
    --magenta: #FF3DBE;
    --gold: #F7C948;
    --ok-bg: rgba(61, 245, 139, .12);
    --bad-bg: rgba(255, 77, 109, .12);
    --warn-bg: rgba(255, 176, 32, .12);
    --info-bg: rgba(76, 141, 255, .12);
    --r: 16px;
    --r-sm: 11px;
    --nav-h: 66px;
    --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
    --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
    --shadow: 0 26px 60px -40px #000, inset 0 1px 0 rgba(255, 255, 255, .045);
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent
}

html,
body {
    margin: 0;
    padding: 0
}

html {
    -webkit-text-size-adjust: 100%
}

body {
    background: var(--ink);
    color: var(--text);
    font: 14px/1.5 var(--sans);
    overflow-x: hidden;
    min-height: 100vh;
    font-variant-numeric: tabular-nums;
}

.hidden {
    display: none !important
}

code {
    font-family: var(--mono);
    font-size: .88em;
    background: #0a1120;
    color: var(--cyan);
    padding: 1px 6px;
    border-radius: 6px;
    border: 1px solid var(--line-soft)
}

b,
strong {
    font-weight: 650
}

h1,
h2,
h3 {
    margin: 0 0 10px;
    font-weight: 650;
    letter-spacing: -.01em
}

h3 {
    font-size: 15px
}

p {
    margin: 0 0 10px
}

ul {
    margin: 0 0 12px;
    padding-left: 18px
}

li {
    margin-bottom: 6px
}

.mono {
    font-family: var(--mono)
}

.muted {
    color: var(--muted)
}

.dim {
    color: var(--dim)
}

.pos {
    color: var(--lime)
}

.neg {
    color: var(--coral)
}

.warnc {
    color: var(--amber)
}

.nowrap {
    white-space: nowrap
}


/* ── скроллбары в собственной палитре ───────────────────────────────────── */

* {
    scrollbar-width: thin;
    scrollbar-color: #1c4a5e var(--ink2)
}

::-webkit-scrollbar {
    width: 10px;
    height: 10px
}

::-webkit-scrollbar-track {
    background: var(--ink2);
    border-radius: 10px
}

::-webkit-scrollbar-thumb {
    border-radius: 10px;
    border: 2px solid var(--ink2);
    background: linear-gradient(180deg, var(--cyan), var(--violet));
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--lime), var(--cyan))
}

::-webkit-scrollbar-corner {
    background: var(--ink2)
}


/* ── фон: сетка градиентов + дрейф + зерно ──────────────────────────────── */

.bg {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    background: var(--ink)
}

.bg-mesh {
    position: absolute;
    inset: -20%;
    background: radial-gradient(46% 38% at 12% 6%, rgba(34, 211, 238, .20), transparent 62%), radial-gradient(42% 40% at 88% 10%, rgba(139, 92, 246, .20), transparent 64%), radial-gradient(50% 44% at 72% 92%, rgba(255, 61, 190, .13), transparent 66%), radial-gradient(44% 40% at 20% 88%, rgba(61, 245, 139, .10), transparent 64%), linear-gradient(180deg, #060911, #04060C);
}

.bg-drift {
    position: absolute;
    inset: -30%;
    background: radial-gradient(30% 26% at 30% 40%, rgba(34, 211, 238, .16), transparent 60%), radial-gradient(26% 24% at 70% 60%, rgba(255, 176, 32, .10), transparent 60%);
    filter: blur(30px);
    animation: drift 34s ease-in-out infinite alternate;
}

@keyframes drift {
    0% {
        transform: translate3d(-3%, -2%, 0) scale(1)
    }
    100% {
        transform: translate3d(4%, 3%, 0) scale(1.08)
    }
}

.bg-grain {
    position: absolute;
    inset: 0;
    opacity: .05;
    mix-blend-mode: overlay;
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}


/* ── вход ───────────────────────────────────────────────────────────────── */

.auth {
    min-height: 100vh;
    min-height: 100dvh;
    display: grid;
    place-items: center;
    padding: 22px
}

.auth-card {
    width: min(400px, 100%);
    background: linear-gradient(180deg, rgba(255, 255, 255, .045), transparent), var(--surface);
    border: 1px solid var(--line);
    border-radius: 22px;
    padding: 30px 24px;
    box-shadow: var(--shadow);
    animation: rise .5s cubic-bezier(.2, .8, .2, 1) both;
}

.auth-mark {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    margin-bottom: 16px;
    background: radial-gradient(120% 120% at 20% 0%, rgba(34, 211, 238, .22), rgba(139, 92, 246, .14));
    border: 1px solid var(--line)
}

.auth-card h1 {
    font-size: 27px;
    letter-spacing: -.02em
}

.auth-sub {
    color: var(--muted);
    font-size: 13px;
    margin-bottom: 20px
}

.auth-field {
    position: relative;
    margin-bottom: 14px
}

.auth-field input {
    padding-right: 46px
}

.eye {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    background: none;
    border: 0;
    color: var(--dim);
    cursor: pointer;
    border-radius: 9px
}

.eye:hover {
    color: var(--cyan);
    background: var(--raise)
}

.auth-err {
    color: var(--coral);
    font-size: 13px;
    min-height: 18px;
    margin-top: 10px
}

@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(14px)
    }
    to {
        opacity: 1;
        transform: none
    }
}


/* ── каркас ─────────────────────────────────────────────────────────────── */

.shell {
    min-height: 100vh
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 40;
    background: linear-gradient(180deg, rgba(6, 9, 17, .96), rgba(6, 9, 17, .86));
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
    padding: 10px 16px 10px;
    padding-top: calc(10px + env(safe-area-inset-top));
}

.topbar-row {
    display: flex;
    align-items: center;
    gap: 10px
}

.topbar-actions {
    margin-top: 9px;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 2px
}

.topbar-actions::-webkit-scrollbar {
    display: none
}

.topbar-actions .btn {
    flex: 0 0 auto
}

.brand {
    display: flex;
    align-items: center;
    gap: 9px;
    flex: 0 0 auto
}

.brand-name {
    font-size: 16px;
    letter-spacing: -.02em;
    color: var(--muted)
}

.brand-name b {
    color: var(--text)
}

.brand-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--lime);
    box-shadow: 0 0 0 0 rgba(61, 245, 139, .6);
    animation: pulse 2.4s infinite
}

.brand-dot.off {
    background: var(--coral);
    animation: none;
    box-shadow: 0 0 10px rgba(255, 77, 109, .7)
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(61, 245, 139, .55)
    }
    70% {
        box-shadow: 0 0 0 9px rgba(61, 245, 139, 0)
    }
    100% {
        box-shadow: 0 0 0 0 rgba(61, 245, 139, 0)
    }
}

.badges {
    display: flex;
    gap: 6px;
    flex: 1 1 auto;
    overflow-x: auto;
    scrollbar-width: none
}

.badges::-webkit-scrollbar {
    display: none
}

.badge {
    flex: 0 0 auto;
    font-size: 10.5px;
    font-weight: 650;
    letter-spacing: .06em;
    text-transform: uppercase;
    padding: 4px 9px;
    border-radius: 999px;
    border: 1px solid var(--line);
    color: var(--muted);
    background: #0a1020
}

.badge.live {
    color: var(--magenta);
    border-color: rgba(255, 61, 190, .45);
    background: rgba(255, 61, 190, .10)
}

.badge.demo {
    color: var(--lime);
    border-color: rgba(61, 245, 139, .4);
    background: var(--ok-bg)
}

.badge.dry {
    color: var(--amber);
    border-color: rgba(255, 176, 32, .45);
    background: var(--warn-bg)
}

.badge.pause {
    color: var(--amber);
    border-color: rgba(255, 176, 32, .45);
    background: var(--warn-bg)
}

.badge.bad {
    color: var(--coral);
    border-color: rgba(255, 77, 109, .45);
    background: var(--bad-bg)
}

.badge.info {
    color: var(--azure);
    border-color: rgba(76, 141, 255, .45);
    background: var(--info-bg)
}

.main {
    max-width: 1440px;
    margin: 0 auto;
    padding: 14px 16px 30px
}

.panel {
    background: linear-gradient(180deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, 0)), var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r);
    padding: 15px;
    box-shadow: var(--shadow);
    margin-bottom: 14px;
}

.foot {
    color: var(--dim);
    font-size: 11.5px;
    font-family: var(--mono);
    padding: 4px 2px 10px;
    text-align: center
}


/* ── кнопки и поля ──────────────────────────────────────────────────────── */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 42px;
    padding: 0 14px;
    border-radius: 12px;
    cursor: pointer;
    font: 600 13px/1 var(--sans);
    color: var(--text);
    background: var(--raise);
    border: 1px solid var(--line);
    transition: transform .12s ease, border-color .18s, background .18s, box-shadow .18s;
}

.btn:hover {
    border-color: var(--cyan);
    box-shadow: 0 0 0 3px rgba(34, 211, 238, .10)
}

.btn:active {
    transform: scale(.965)
}

.btn:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px
}

.btn[disabled] {
    opacity: .45;
    pointer-events: none
}

.btn-block {
    width: 100%
}

.btn-primary {
    background: linear-gradient(120deg, var(--cyan), var(--azure) 55%, var(--violet));
    color: #04121a;
    border-color: transparent;
    font-weight: 750
}

.btn-primary:hover {
    box-shadow: 0 8px 26px -10px rgba(34, 211, 238, .7)
}

.btn-ok {
    color: var(--lime);
    border-color: rgba(61, 245, 139, .4);
    background: var(--ok-bg)
}

.btn-warn {
    color: var(--amber);
    border-color: rgba(255, 176, 32, .4);
    background: var(--warn-bg)
}

.btn-danger {
    color: var(--coral);
    border-color: rgba(255, 77, 109, .42);
    background: var(--bad-bg)
}

.btn-ghost {
    background: transparent;
    color: var(--muted)
}

.btn-sm {
    min-height: 36px;
    padding: 0 11px;
    font-size: 12px;
    border-radius: 10px
}

.icon-btn {
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: var(--raise);
    border: 1px solid var(--line);
    color: var(--muted);
    cursor: pointer
}

.icon-btn:hover {
    color: var(--cyan);
    border-color: var(--cyan)
}

.icon-btn.spin svg {
    animation: spin .8s linear infinite
}

@keyframes spin {
    to {
        transform: rotate(360deg)
    }
}

input,
select,
textarea {
    width: 100%;
    min-height: 44px;
    background: #080E1A;
    color: var(--text);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 10px 12px;
    font: 14px/1.4 var(--sans);
    transition: border-color .18s, box-shadow .18s;
}

input[type=number] {
    font-family: var(--mono)
}

textarea {
    min-height: 88px;
    font-family: var(--mono);
    font-size: 13px;
    resize: vertical
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--cyan);
    box-shadow: 0 0 0 3px rgba(34, 211, 238, .13)
}

select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%238FA3BF' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 13px center;
    padding-right: 34px
}

label {
    display: block;
    font-size: 12px;
    color: var(--muted);
    margin-bottom: 6px;
    font-weight: 600
}

.hint {
    font-size: 11px;
    color: var(--dim);
    margin-top: 5px;
    line-height: 1.4
}

input[type=range] {
    -webkit-appearance: none;
    appearance: none;
    min-height: 26px;
    height: 26px;
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
    cursor: pointer;
}

input[type=range]::-webkit-slider-runnable-track {
    height: 6px;
    border-radius: 6px;
    background: linear-gradient(90deg, var(--cyan), var(--violet));
    opacity: .85
}

input[type=range]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    margin-top: -8px;
    border-radius: 50%;
    background: #0A1120;
    border: 2px solid var(--cyan);
    box-shadow: 0 0 0 4px rgba(34, 211, 238, .16), 0 4px 12px -4px #000
}

input[type=range]::-moz-range-track {
    height: 6px;
    border-radius: 6px;
    background: linear-gradient(90deg, var(--cyan), var(--violet))
}

input[type=range]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #0A1120;
    border: 2px solid var(--cyan);
    box-shadow: 0 0 0 4px rgba(34, 211, 238, .16)
}

input[type=range]:focus {
    box-shadow: none
}

.switch {
    display: flex;
    align-items: center;
    gap: 11px;
    min-height: 44px;
    cursor: pointer;
    user-select: none
}

.switch input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0
}

.switch-track {
    width: 50px;
    height: 28px;
    border-radius: 999px;
    background: #101a2c;
    border: 1px solid var(--line);
    position: relative;
    flex: 0 0 auto;
    transition: background .2s, border-color .2s
}

.switch-track::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--dim);
    transition: transform .2s cubic-bezier(.2, .8, .2, 1), background .2s
}

.switch input:checked+.switch-track {
    background: rgba(61, 245, 139, .2);
    border-color: rgba(61, 245, 139, .5)
}

.switch input:checked+.switch-track::after {
    transform: translateX(22px);
    background: var(--lime)
}

.switch input:focus-visible+.switch-track {
    box-shadow: 0 0 0 3px rgba(34, 211, 238, .25)
}

.switch-label {
    font-size: 13px;
    font-weight: 600
}


/* ── KPI ────────────────────────────────────────────────────────────────── */

.kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(178px, 1fr));
    gap: 11px;
    margin-bottom: 14px
}

.kpi {
    background: linear-gradient(180deg, rgba(255, 255, 255, .04), transparent), var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r);
    padding: 13px 14px;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow)
}

.kpi::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--cyan);
    opacity: .8
}

.kpi.k-gold::before {
    background: linear-gradient(180deg, var(--gold), var(--amber))
}

.kpi.k-lime::before {
    background: linear-gradient(180deg, var(--lime), var(--cyan))
}

.kpi.k-coral::before {
    background: linear-gradient(180deg, var(--coral), var(--magenta))
}

.kpi.k-violet::before {
    background: linear-gradient(180deg, var(--violet), var(--azure))
}

.kpi.k-amber::before {
    background: linear-gradient(180deg, var(--amber), var(--gold))
}

.kpi-label {
    font-size: 11px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: .055em;
    font-weight: 650
}

.kpi-val {
    font: 650 22px/1.2 var(--mono);
    margin-top: 7px;
    letter-spacing: -.02em;
    word-break: break-all
}

.kpi-sub {
    font-size: 11px;
    color: var(--dim);
    margin-top: 4px
}

.kpi.k-gold .kpi-val {
    color: var(--gold)
}


/* ── панель интервала ───────────────────────────────────────────────────── */

.clock-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px 12px;
    margin-bottom: 12px
}

.clock-key {
    font: 650 15px/1 var(--mono);
    color: var(--text)
}

.phase {
    font-size: 11px;
    font-weight: 750;
    letter-spacing: .06em;
    text-transform: uppercase;
    padding: 5px 10px;
    border-radius: 999px;
    border: 1px solid
}

.phase.buy {
    color: var(--lime);
    border-color: rgba(61, 245, 139, .45);
    background: var(--ok-bg)
}

.phase.hold {
    color: var(--azure);
    border-color: rgba(76, 141, 255, .45);
    background: var(--info-bg)
}

.phase.flat {
    color: var(--amber);
    border-color: rgba(255, 176, 32, .45);
    background: var(--warn-bg)
}

.rail {
    position: relative;
    height: 12px;
    border-radius: 8px;
    background: #080E1A;
    border: 1px solid var(--line-soft);
    overflow: hidden;
    margin: 6px 0 4px
}

.rail-fill {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    background: linear-gradient(90deg, var(--cyan), var(--violet) 60%, var(--magenta));
    box-shadow: 0 0 18px rgba(34, 211, 238, .45);
    transition: width 1s linear
}

.rail-mark {
    position: absolute;
    top: -3px;
    bottom: -3px;
    width: 2px;
    background: var(--amber);
    opacity: .9
}

.rail-mark.end {
    background: var(--coral)
}

.rail-legend {
    display: flex;
    justify-content: space-between;
    font-size: 10.5px;
    color: var(--dim);
    font-family: var(--mono);
    margin-bottom: 12px
}

.clocks {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 10px
}

.clock-cell {
    background: #0A1020;
    border: 1px solid var(--line-soft);
    border-radius: var(--r-sm);
    padding: 11px 12px
}

.clock-cell .t {
    font-size: 11px;
    color: var(--muted);
    font-weight: 600
}

.clock-cell .v {
    font: 650 19px/1.25 var(--mono);
    margin-top: 5px
}

.clock-cell .d {
    font-size: 10.5px;
    color: var(--dim);
    font-family: var(--mono);
    margin-top: 3px
}

.clock-cell.c-buy .v {
    color: var(--lime)
}

.clock-cell.c-flat .v {
    color: var(--amber)
}

.clock-cell.c-end .v {
    color: var(--cyan)
}


/* ── баннеры ────────────────────────────────────────────────────────────── */

.banner {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 11px 14px;
    border-radius: var(--r-sm);
    border: 1px solid rgba(255, 176, 32, .4);
    background: var(--warn-bg);
    color: #FFD98A;
    font-size: 12.5px;
    margin-bottom: 11px;
    line-height: 1.45
}

.banner.bad {
    border-color: rgba(255, 77, 109, .45);
    background: var(--bad-bg);
    color: #FFB6C4
}

.banner.info {
    border-color: rgba(76, 141, 255, .4);
    background: var(--info-bg);
    color: #BBD3FF
}

.banner svg {
    flex: 0 0 auto;
    margin-top: 1px
}


/* ── навигация ──────────────────────────────────────────────────────────── */

.nav {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    margin-bottom: 14px;
    padding-bottom: 3px;
    scrollbar-width: none
}

.nav::-webkit-scrollbar {
    display: none
}

.nav button {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 15px;
    border-radius: 12px;
    background: var(--surface);
    border: 1px solid var(--line);
    color: var(--muted);
    font: 600 13px/1 var(--sans);
    cursor: pointer;
    transition: .18s
}

.nav button:hover {
    color: var(--text);
    border-color: var(--cyan)
}

.nav button.active {
    color: #04121a;
    border-color: transparent;
    font-weight: 750;
    background: linear-gradient(120deg, var(--cyan), var(--azure));
    box-shadow: 0 8px 22px -12px rgba(34, 211, 238, .8)
}

.nav .nav-ico {
    display: grid;
    place-items: center
}

.nav .nav-short {
    display: none
}


/* ── тулбары ────────────────────────────────────────────────────────────── */

.toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    align-items: center;
    margin-bottom: 13px
}

.chips {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 2px
}

.chips::-webkit-scrollbar {
    display: none
}

.chip {
    flex: 0 0 auto;
    min-height: 36px;
    padding: 0 12px;
    border-radius: 999px;
    background: #0A1020;
    border: 1px solid var(--line);
    color: var(--muted);
    font: 600 12px/1 var(--sans);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px
}

.chip:hover {
    border-color: var(--cyan);
    color: var(--text)
}

.chip.on {
    background: linear-gradient(120deg, rgba(34, 211, 238, .22), rgba(139, 92, 246, .22));
    border-color: var(--cyan);
    color: var(--text)
}

.chip .cnt {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--dim)
}

.chip.on .cnt {
    color: var(--cyan)
}

.search {
    flex: 1 1 190px;
    min-width: 150px;
    position: relative
}

.search input {
    min-height: 40px;
    padding-left: 36px
}

.search svg {
    position: absolute;
    left: 11px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--dim)
}

.toolbar select {
    width: auto;
    min-width: 150px;
    min-height: 40px
}


/* ── таблица (десктоп) ──────────────────────────────────────────────────── */

.tbl-wrap {
    overflow-x: auto;
    border-radius: var(--r-sm);
    border: 1px solid var(--line-soft)
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12.5px
}

th,
td {
    padding: 10px 11px;
    text-align: right;
    white-space: nowrap;
    border-bottom: 1px solid var(--line-soft)
}

th:first-child,
td:first-child {
    text-align: left;
    position: sticky;
    left: 0;
    background: var(--surface);
    z-index: 2
}

th {
    color: var(--muted);
    font-weight: 650;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .045em;
    background: #0A1020;
    position: sticky;
    top: 0;
    z-index: 3
}

th:first-child {
    z-index: 4;
    background: #0A1020
}

tbody tr {
    cursor: pointer;
    transition: background .14s
}

tbody tr:hover td {
    background: #101a2c
}

tbody tr:hover td:first-child {
    background: #101a2c
}

tbody tr:last-child td {
    border-bottom: 0
}

td.num {
    font-family: var(--mono)
}

.sym {
    font-weight: 700;
    letter-spacing: -.01em
}

.subnote {
    font-size: 10.5px;
    color: var(--dim);
    white-space: normal;
    max-width: 230px;
    margin-top: 3px
}

.state {
    display: inline-block;
    font-size: 11px;
    font-weight: 650;
    padding: 4px 9px;
    border-radius: 999px;
    border: 1px solid var(--line);
    color: var(--muted);
    background: #0A1020
}

.state.s-hold {
    color: var(--cyan);
    border-color: rgba(34, 211, 238, .45);
    background: rgba(34, 211, 238, .12)
}

.state.s-wait {
    color: var(--muted)
}

.state.s-win {
    color: var(--lime);
    border-color: rgba(61, 245, 139, .4);
    background: var(--ok-bg)
}

.state.s-loss {
    color: var(--coral);
    border-color: rgba(255, 77, 109, .4);
    background: var(--bad-bg)
}

.state.s-time {
    color: var(--amber);
    border-color: rgba(255, 176, 32, .4);
    background: var(--warn-bg)
}

.state.s-dust {
    color: var(--violet);
    border-color: rgba(139, 92, 246, .45);
    background: rgba(139, 92, 246, .13)
}

.state.s-off {
    color: var(--dim)
}

.flash-up {
    animation: flashUp .9s ease-out
}

.flash-down {
    animation: flashDown .9s ease-out
}

@keyframes flashUp {
    0% {
        color: var(--lime);
        text-shadow: 0 0 14px rgba(61, 245, 139, .75)
    }
    100% {}
}

@keyframes flashDown {
    0% {
        color: var(--coral);
        text-shadow: 0 0 14px rgba(255, 77, 109, .7)
    }
    100% {}
}


/* ── карточки монет (мобильные) ─────────────────────────────────────────── */

.cards {
    display: flex;
    flex-direction: column;
    gap: 11px
}

.coin-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, .035), transparent), var(--surface2);
    border: 1px solid var(--line);
    border-radius: var(--r);
    padding: 13px;
    position: relative;
    overflow: hidden
}

.coin-card.held {
    border-color: rgba(34, 211, 238, .38);
    box-shadow: 0 0 0 1px rgba(34, 211, 238, .08), var(--shadow)
}

.cc-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 9px
}

.cc-price {
    display: flex;
    align-items: baseline;
    gap: 10px;
    flex-wrap: wrap
}

.cc-last {
    font: 650 21px/1 var(--mono);
    letter-spacing: -.02em
}

.cc-delta {
    font: 650 13px/1 var(--mono)
}

.cc-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-top: 11px
}

.cc-cell {
    background: #0A1020;
    border: 1px solid var(--line-soft);
    border-radius: 10px;
    padding: 8px 10px
}

.cc-cell .t {
    font-size: 10px;
    color: var(--dim);
    text-transform: uppercase;
    letter-spacing: .05em;
    font-weight: 650
}

.cc-cell .v {
    font: 600 13px/1.3 var(--mono);
    margin-top: 3px;
    word-break: break-all
}

.cc-actions {
    display: flex;
    gap: 8px;
    margin-top: 11px
}

.cc-actions .btn {
    flex: 1 1 auto
}


/* ── шкала уровней монеты ───────────────────────────────────────────────── */

.lv {
    margin-top: 12px
}

.lv-track {
    position: relative;
    height: 10px;
    border-radius: 7px;
    overflow: hidden;
    background: #080E1A;
    border: 1px solid var(--line-soft);
    display: flex
}

.lv-seg {
    height: 100%
}

.lv-seg.z-bad {
    background: linear-gradient(90deg, rgba(255, 77, 109, .75), rgba(255, 77, 109, .35))
}

.lv-seg.z-warn {
    background: linear-gradient(90deg, rgba(255, 176, 32, .5), rgba(255, 176, 32, .3))
}

.lv-seg.z-ok {
    background: linear-gradient(90deg, rgba(61, 245, 139, .35), rgba(61, 245, 139, .7))
}

.lv-dot {
    position: absolute;
    top: 50%;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    background: #05070E;
    border: 2.5px solid var(--cyan);
    box-shadow: 0 0 12px rgba(34, 211, 238, .9);
    z-index: 2
}

.lv-dot.in-bad {
    border-color: var(--coral);
    box-shadow: 0 0 12px rgba(255, 77, 109, .9)
}

.lv-dot.in-ok {
    border-color: var(--lime);
    box-shadow: 0 0 12px rgba(61, 245, 139, .9)
}

.lv-dot.in-warn {
    border-color: var(--amber);
    box-shadow: 0 0 12px rgba(255, 176, 32, .9)
}

.lv-labels {
    display: flex;
    justify-content: space-between;
    font-size: 10px;
    color: var(--dim);
    font-family: var(--mono);
    margin-top: 6px;
    gap: 6px
}

.lv-labels span {
    white-space: nowrap
}

.lv-cap {
    display: flex;
    justify-content: space-between;
    font-size: 10px;
    color: var(--muted);
    margin-bottom: 5px;
    font-weight: 650;
    letter-spacing: .04em;
    text-transform: uppercase
}


/* ── списки: сделки / события / логи ────────────────────────────────────── */

.feed {
    display: flex;
    flex-direction: column;
    gap: 9px
}

.feed-item {
    background: var(--surface2);
    border: 1px solid var(--line-soft);
    border-radius: var(--r-sm);
    padding: 11px 12px;
    border-left: 3px solid var(--line)
}

.feed-item.f-buy {
    border-left-color: var(--cyan)
}

.feed-item.f-sell {
    border-left-color: var(--violet)
}

.feed-item.f-ok {
    border-left-color: var(--lime)
}

.feed-item.f-warn {
    border-left-color: var(--amber)
}

.feed-item.f-err {
    border-left-color: var(--coral)
}

.fi-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px
}

.fi-time {
    font: 11px/1 var(--mono);
    color: var(--dim);
    white-space: nowrap
}

.fi-msg {
    font-size: 12.5px;
    line-height: 1.5;
    word-break: break-word
}

.fi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(104px, 1fr));
    gap: 7px;
    margin-top: 8px
}

.fi-cell {
    background: #0A1020;
    border-radius: 8px;
    padding: 6px 8px
}

.fi-cell .t {
    font-size: 9.5px;
    color: var(--dim);
    text-transform: uppercase;
    letter-spacing: .05em;
    font-weight: 650
}

.fi-cell .v {
    font: 600 12px/1.3 var(--mono);
    margin-top: 2px;
    word-break: break-all
}

.tag {
    font-size: 10px;
    font-weight: 700;
    padding: 3px 7px;
    border-radius: 6px;
    letter-spacing: .04em;
    text-transform: uppercase
}

.tag.buy {
    color: var(--cyan);
    background: rgba(34, 211, 238, .14)
}

.tag.sell {
    color: var(--violet);
    background: rgba(139, 92, 246, .16)
}

.tag.paper {
    color: var(--amber);
    background: var(--warn-bg)
}

.tag.real {
    color: var(--magenta);
    background: rgba(255, 61, 190, .14)
}

pre.logs {
    margin: 0;
    max-height: 60vh;
    overflow: auto;
    background: #060B14;
    border: 1px solid var(--line-soft);
    border-radius: var(--r-sm);
    padding: 12px;
    font: 11.5px/1.65 var(--mono);
    color: #B9C9E2;
    white-space: pre-wrap;
    word-break: break-word
}

pre.logs .l-err {
    color: var(--coral)
}

pre.logs .l-warn {
    color: var(--amber)
}

.empty {
    text-align: center;
    padding: 34px 16px;
    color: var(--dim)
}

.empty svg {
    opacity: .5;
    margin-bottom: 10px
}

.empty b {
    display: block;
    color: var(--muted);
    font-size: 14px;
    margin-bottom: 5px
}


/* ── графики ────────────────────────────────────────────────────────────── */

.chart {
    width: 100%;
    height: 150px;
    display: block;
    overflow: visible
}

.chart-meta {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    font: 11px/1 var(--mono);
    color: var(--dim);
    margin-top: 8px
}

.bars {
    display: flex;
    align-items: flex-end;
    gap: 5px;
    height: 132px;
    padding-top: 16px;
    overflow-x: auto
}

.bar-col {
    flex: 1 0 34px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    height: 100%
}

.bar-slot {
    flex: 1 1 auto;
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    position: relative
}

.bar {
    width: 70%;
    min-height: 2px;
    border-radius: 4px 4px 0 0;
    position: relative
}

.bar.up {
    background: linear-gradient(180deg, var(--lime), rgba(61, 245, 139, .35))
}

.bar.down {
    background: linear-gradient(0deg, var(--coral), rgba(255, 77, 109, .35));
    border-radius: 0 0 4px 4px
}

.bar-val {
    font: 600 9.5px/1 var(--mono);
    color: var(--muted);
    white-space: nowrap
}

.bar-lbl {
    font: 9.5px/1 var(--mono);
    color: var(--dim);
    white-space: nowrap
}

.legend {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin-top: 12px
}

.leg-row {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 12px
}

.leg-sw {
    width: 12px;
    height: 12px;
    border-radius: 4px;
    flex: 0 0 auto
}

.leg-name {
    flex: 1 1 auto;
    color: var(--muted)
}

.leg-val {
    font-family: var(--mono);
    font-weight: 650
}

.stack {
    display: flex;
    height: 14px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--line-soft);
    margin-top: 6px
}

.stack i {
    display: block;
    height: 100%
}


/* ── калькулятор риска ──────────────────────────────────────────────────── */

.calc {
    background: linear-gradient(140deg, rgba(34, 211, 238, .09), rgba(139, 92, 246, .07)), var(--surface2);
    border: 1px solid var(--line);
    border-radius: var(--r);
    padding: 14px;
    margin-bottom: 14px
}

.calc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
    gap: 9px;
    margin-top: 11px
}

.calc-cell {
    background: #0A1020;
    border: 1px solid var(--line-soft);
    border-radius: 10px;
    padding: 10px
}

.calc-cell .t {
    font-size: 10px;
    color: var(--dim);
    text-transform: uppercase;
    letter-spacing: .05em;
    font-weight: 650
}

.calc-cell .v {
    font: 650 17px/1.2 var(--mono);
    margin-top: 4px
}

.calc-bar {
    display: flex;
    height: 12px;
    border-radius: 7px;
    overflow: hidden;
    margin-top: 12px;
    border: 1px solid var(--line-soft)
}

.calc-bar i {
    display: block;
    height: 100%
}

.verdict {
    margin-top: 11px;
    font-size: 12.5px;
    line-height: 1.5;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid rgba(255, 176, 32, .4);
    background: var(--warn-bg);
    color: #FFD98A
}

.verdict.good {
    border-color: rgba(61, 245, 139, .4);
    background: var(--ok-bg);
    color: #B6F5D2
}


/* ── форма настроек ─────────────────────────────────────────────────────── */

.cfg-group {
    margin-bottom: 18px
}

.cfg-title {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 12px;
    font-weight: 750;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: .07em;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--line-soft)
}

.cfg-title i {
    width: 8px;
    height: 8px;
    border-radius: 3px;
    display: block
}

.cfg-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(268px, 1fr));
    gap: 14px
}

.field {
    background: #0A1020;
    border: 1px solid var(--line-soft);
    border-radius: var(--r-sm);
    padding: 12px
}

.field.dirty {
    border-color: rgba(255, 176, 32, .5);
    box-shadow: 0 0 0 1px rgba(255, 176, 32, .12)
}

.field-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px
}

.field-head label {
    margin: 0
}

.badge-when {
    font-size: 9.5px;
    font-weight: 750;
    letter-spacing: .05em;
    padding: 3px 7px;
    border-radius: 6px;
    text-transform: uppercase;
    white-space: nowrap
}

.badge-when.now {
    color: var(--lime);
    background: var(--ok-bg)
}

.badge-when.next {
    color: var(--azure);
    background: var(--info-bg)
}

.range-row {
    display: flex;
    align-items: center;
    gap: 11px
}

.range-row input[type=range] {
    flex: 1 1 auto
}

.range-row input[type=number] {
    width: 96px;
    flex: 0 0 auto;
    text-align: right;
    min-height: 40px
}

.cfg-save {
    position: sticky;
    bottom: 0;
    z-index: 20;
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    align-items: center;
    padding: 12px;
    margin: 0 -15px -15px;
    border-top: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(12, 18, 32, .9), rgba(12, 18, 32, .99));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 0 0 var(--r) var(--r)
}

.cfg-msg {
    flex: 1 1 160px;
    font-size: 12px;
    min-height: 16px
}

.cfg-msg.err {
    color: var(--coral);
    white-space: pre-wrap
}

.cfg-msg.ok {
    color: var(--lime)
}


/* ── drawer ─────────────────────────────────────────────────────────────── */

.drawer {
    position: fixed;
    inset: 0;
    z-index: 70
}

.drawer-scrim {
    position: absolute;
    inset: 0;
    background: rgba(3, 5, 10, .72);
    backdrop-filter: blur(4px);
    animation: fade .22s ease both
}

.drawer-body {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: min(460px, 100%);
    overflow-y: auto;
    background: linear-gradient(180deg, rgba(255, 255, 255, .04), transparent), var(--surface);
    border-left: 1px solid var(--line);
    padding: 20px;
    box-shadow: -30px 0 70px -40px #000;
    animation: slideIn .3s cubic-bezier(.2, .85, .25, 1) both;
    padding-bottom: calc(20px + env(safe-area-inset-bottom))
}

.drawer-grip {
    display: none
}

@keyframes slideIn {
    from {
        transform: translateX(30px);
        opacity: 0
    }
    to {
        transform: none;
        opacity: 1
    }
}

@keyframes fade {
    from {
        opacity: 0
    }
    to {
        opacity: 1
    }
}

.dr-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px
}

.dr-title {
    font: 700 22px/1.1 var(--mono);
    letter-spacing: -.02em
}

.dr-price {
    font: 650 30px/1 var(--mono);
    margin: 12px 0 4px;
    letter-spacing: -.03em
}

.dr-rows {
    display: flex;
    flex-direction: column;
    gap: 1px;
    background: var(--line-soft);
    border-radius: var(--r-sm);
    overflow: hidden;
    margin-top: 14px;
    border: 1px solid var(--line-soft)
}

.dr-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    background: #0A1020;
    font-size: 12.5px
}

.dr-row .k {
    color: var(--muted)
}

.dr-row .v {
    font-family: var(--mono);
    font-weight: 600;
    text-align: right;
    word-break: break-all
}


/* ── модалка ────────────────────────────────────────────────────────────── */

.modal {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: grid;
    place-items: center;
    padding: 20px
}

.modal-scrim {
    position: absolute;
    inset: 0;
    background: rgba(3, 5, 10, .78);
    backdrop-filter: blur(5px);
    animation: fade .2s both
}

.modal-card {
    position: relative;
    width: min(420px, 100%);
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 22px;
    box-shadow: 0 40px 80px -40px #000;
    animation: rise .26s cubic-bezier(.2, .8, .2, 1) both
}

.modal-card h3 {
    font-size: 17px
}

.modal-card p {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.55
}

.modal-actions {
    display: flex;
    gap: 9px;
    margin-top: 18px
}

.modal-actions .btn {
    flex: 1 1 auto
}


/* ── тосты ──────────────────────────────────────────────────────────────── */

.toasts {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    bottom: calc(18px + env(safe-area-inset-bottom));
    z-index: 100;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: min(440px, calc(100% - 28px));
    pointer-events: none
}

.toast {
    background: var(--raise);
    border: 1px solid var(--line);
    border-left: 3px solid var(--cyan);
    border-radius: 12px;
    padding: 11px 14px;
    font-size: 12.5px;
    box-shadow: 0 20px 40px -22px #000;
    animation: toastIn .26s cubic-bezier(.2, .8, .2, 1) both;
    line-height: 1.45
}

.toast.ok {
    border-left-color: var(--lime)
}

.toast.err {
    border-left-color: var(--coral)
}

.toast.warn {
    border-left-color: var(--amber)
}

.toast.out {
    animation: toastOut .24s ease forwards
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateY(14px)
    }
    to {
        opacity: 1;
        transform: none
    }
}

@keyframes toastOut {
    to {
        opacity: 0;
        transform: translateY(10px)
    }
}

.noscript {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
    background: var(--ink);
    color: var(--coral);
    padding: 24px;
    text-align: center
}

.skel {
    background: linear-gradient(90deg, #0C1220, #16203A, #0C1220);
    background-size: 200% 100%;
    animation: sk 1.3s linear infinite;
    border-radius: 10px;
    height: 74px
}

@keyframes sk {
    to {
        background-position: -200% 0
    }
}


/* ═══════════ ПЛАНШЕТ ═══════════ */

@media (max-width:1100px) {
    .kpis {
        grid-template-columns: repeat(auto-fit, minmax(154px, 1fr))
    }
    .kpi-val {
        font-size: 19px
    }
}


/* ═══════════ СМАРТФОН ═══════════ */

@media (max-width:860px) {
    body {
        font-size: 14px
    }
    .main {
        padding: 12px 12px calc(var(--nav-h) + 26px + env(safe-area-inset-bottom))
    }
    .topbar {
        padding-left: 12px;
        padding-right: 12px
    }
    .panel {
        padding: 13px;
        border-radius: 14px
    }
    .kpis {
        grid-template-columns: repeat(2, 1fr);
        gap: 9px
    }
    .kpi {
        padding: 11px 12px
    }
    .kpi-val {
        font-size: 18px
    }
    .kpi.k-wide {
        grid-column: span 2
    }
    .kpi-label {
        font-size: 10px
    }
    .clocks {
        grid-template-columns: 1fr;
        gap: 8px
    }
    .clock-cell {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px
    }
    .clock-cell .v {
        margin-top: 0;
        font-size: 17px
    }
    .clock-cell .d {
        display: none
    }
    .clock-cell .t {
        font-size: 11.5px
    }
    /* навигация уезжает вниз — под большой палец */
    .nav {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 60;
        margin: 0;
        gap: 0;
        display: grid;
        grid-template-columns: repeat(7, 1fr);
        overflow: visible;
        background: linear-gradient(180deg, rgba(8, 12, 22, .92), rgba(5, 7, 14, .99));
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border-top: 1px solid var(--line);
        padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
    }
    .nav button {
        flex: none;
        flex-direction: column;
        gap: 3px;
        min-height: 52px;
        padding: 5px 2px;
        border-radius: 11px;
        background: transparent;
        border: 1px solid transparent;
        font-size: 9.5px;
        font-weight: 650;
        letter-spacing: 0;
    }
    .nav button:hover {
        border-color: transparent
    }
    .nav button.active {
        background: rgba(34, 211, 238, .14);
        border-color: rgba(34, 211, 238, .35);
        color: var(--cyan);
        box-shadow: none
    }
    .nav .nav-full {
        display: none
    }
    .nav .nav-short {
        display: block
    }
    .nav .nav-ico svg {
        width: 20px;
        height: 20px
    }
    .toolbar {
        gap: 8px
    }
    .toolbar select {
        flex: 1 1 100%;
        width: 100%
    }
    .search {
        flex: 1 1 100%
    }
    .tbl-wrap {
        display: none
    }
    .cards {
        display: flex
    }
    .cfg-grid {
        grid-template-columns: 1fr;
        gap: 11px
    }
    .cfg-save {
        margin: 0 -13px -13px;
        padding: 11px 13px calc(11px + env(safe-area-inset-bottom))
    }
    .cfg-save .btn {
        flex: 1 1 calc(50% - 5px)
    }
    .cfg-msg {
        flex: 1 1 100%;
        order: -1
    }
    .calc-grid {
        grid-template-columns: repeat(2, 1fr)
    }
    /* drawer превращается в нижний лист */
    .drawer-body {
        right: 0;
        left: 0;
        top: auto;
        bottom: 0;
        width: 100%;
        max-height: 88vh;
        border-left: 0;
        border-top: 1px solid var(--line);
        border-radius: 22px 22px 0 0;
        padding: 8px 16px 20px;
        animation: sheetUp .3s cubic-bezier(.2, .85, .25, 1) both
    }
    .drawer-grip {
        display: block;
        width: 44px;
        height: 5px;
        border-radius: 3px;
        background: var(--line);
        margin: 8px auto 14px;
        cursor: pointer
    }
    @keyframes sheetUp {
        from {
            transform: translateY(40px);
            opacity: 0
        }
        to {
            transform: none;
            opacity: 1
        }
    }
    .dr-price {
        font-size: 26px
    }
    .toasts {
        bottom: calc(var(--nav-h) + 14px + env(safe-area-inset-bottom))
    }
    pre.logs {
        max-height: 52vh;
        font-size: 11px
    }
    .modal-actions {
        flex-direction: column-reverse
    }
}

@media (max-width:400px) {
    .kpi-val {
        font-size: 16px
    }
    .cc-last {
        font-size: 19px
    }
    .nav button {
        font-size: 8.5px
    }
    .brand-name {
        font-size: 14px
    }
    .topbar-actions .btn span {
        display: none
    }
    .topbar-actions .btn {
        padding: 0 13px
    }
}

@media (prefers-reduced-motion:reduce) {
    *,
    *::before,
    *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .001ms !important
    }
    .bg-drift {
        animation: none
    }
}

@media (prefers-contrast:more) {
     :root {
        --muted: #B6C6DE;
        --dim: #8FA3BF;
        --line: #31435F
    }
}