:root {
    color-scheme: dark;
    --bg: #0b0e14;
    --bg-pure: #000000;
    --card: rgba(11, 14, 20, 0.92);
    --muted: #9ca3af;
    --text: #c8cdd6;
    --text-heading: #ffffff;
    --text-label: #b4bcc8;
    --brand-red: #d31a24;
    --brand-cyan: #d31a24;
    --accent: #d31a24;
    --accent-hover: #e82e38;
    --ui-hover: #d31a24;
    --ui-hover-soft: rgba(211, 26, 36, 0.14);
    --ui-hover-mid: rgba(211, 26, 36, 0.35);
    --ui-hover-ring: rgba(211, 26, 36, 0.45);
    --red-soft: rgba(211, 26, 36, 0.14);
    --red-mid: rgba(211, 26, 36, 0.45);
    --danger: #ff6b6b;
    --success: #52d38a;
    --border: rgba(255, 255, 255, 0.1);
    --border-accent: rgba(211, 26, 36, 0.45);
    --glass-bg: rgba(11, 14, 20, 0.8);
    --glass-blur: 12px;
    --font-family: 'JetBrains Mono', 'Inter', -apple-system, BlinkMacSystemFont, monospace;
    --font-sans: var(--font-family);
    --font-mono-display: var(--font-family);
    /* ~16.5px @ 1080h → ~18px @ 1440h; не уменьшаем ниже 16px на низких экранах */
    --font-size-root: clamp(16px, 10.5px + 0.55vh, 18px);
    --text-sm: 0.84375rem; /* 13.5px при базе 16px */
    --text-md: 0.90625rem; /* 14.5px при базе 16px */
    --binary-pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cstyle%3Etext%7Bfont-family:monospace;font-size:8px;fill:white;%7D%3C/style%3E%3Ctext x='0' y='10' opacity='0.2'%3E101011010010%3C/text%3E%3Ctext x='0' y='20' opacity='0.5'%3E011010101101%3C/text%3E%3Ctext x='0' y='30' opacity='0.1'%3E110111001010%3C/text%3E%3Ctext x='0' y='40' opacity='0.8'%3E001010110110%3C/text%3E%3Ctext x='0' y='50' opacity='0.3'%3E101101100101%3C/text%3E%3Ctext x='0' y='60' opacity='0.6'%3E010110101101%3C/text%3E%3Ctext x='0' y='70' opacity='0.1'%3E101010110110%3C/text%3E%3Ctext x='0' y='80' opacity='0.4'%3E110110101101%3C/text%3E%3Ctext x='0' y='90' opacity='0.2'%3E011011100101%3C/text%3E%3Ctext x='0' y='100' opacity='0.7'%3E101001011011%3C/text%3E%3Ctext x='0' y='110' opacity='0.1'%3E110110101101%3C/text%3E%3Ctext x='0' y='120' opacity='0.5'%3E011010110110%3C/text%3E%3C/svg%3E");
    --nav-control-height: 40px;
    --nav-text-btn-width: clamp(148px, 42vw, 200px);
    --account-drawer-panel-width: 540px;
}

* {
    box-sizing: border-box;
}

html {
    font-size: var(--font-size-root);
}

body {
    margin: 0;
    font-family: var(--font-sans);
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    padding: 0;
    line-height: 1.5;
    position: relative;
    isolation: isolate;
}

#matrix-canvas {
    position: fixed;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    background: var(--bg);
}

body::after {
    content: '';
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background:
        radial-gradient(1000px 520px at 12% -8%, rgba(211, 26, 36, 0.14), transparent 58%),
        radial-gradient(880px 480px at 92% 8%, rgba(0, 242, 255, 0.08), transparent 52%),
        radial-gradient(720px 420px at 72% 100%, rgba(211, 26, 36, 0.06), transparent 50%);
}

body > * {
    position: relative;
    z-index: 2;
}

@media (prefers-reduced-transparency: reduce) {
    body::after {
        opacity: 0.92;
    }
}

body.page-registration::after {
    background:
        radial-gradient(900px 480px at 10% -6%, rgba(211, 26, 36, 0.12), transparent 55%);
}

h1,
h2,
h3 {
    font-family: var(--font-mono-display);
    color: var(--text-heading);
    font-weight: 600;
}

.container {
    width: min(1120px, 92vw);
    margin: 0 auto;
    padding-left: clamp(12px, 2vw, 20px);
    padding-right: clamp(12px, 2vw, 20px);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 26px 0;
    flex-wrap: wrap;
    gap: 14px;
    min-width: 0;
}

.brand {
    font-weight: 700;
    letter-spacing: 0.3px;
}

/* PNG wordmark (assets/img/text_line.png); при ошибке загрузки — текст из перевода site.brand */
.brand--wordmark {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    flex-shrink: 0;
    max-width: min(100%, min(280px, 72vw));
}

.brand__wordmark-img {
    display: block;
    width: auto;
    height: clamp(34px, 5.5vw, 46px);
    max-width: 100%;
    object-fit: contain;
    object-position: left center;
}

.brand__wordmark-fallback {
    font-weight: 700;
    letter-spacing: 0.3px;
    line-height: 1.1;
    font-size: clamp(1.35rem, 3.2vw, 1.85rem);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 380px) {
    .brand__wordmark-img {
        height: clamp(30px, 8vw, 38px);
    }

    .brand__wordmark-fallback {
        font-size: clamp(1.15rem, 5vw, 1.45rem);
    }
}

.hero {
    display: block;
    padding: 22px 0 36px;
}

.hero .hero-card {
    width: 100%;
    max-width: none;
}

.profile-compact .section-title {
    margin-bottom: 8px;
    font-size: 18px;
}

.profile-compact-greet {
    font-size: var(--text-sm);
    color: var(--muted);
    margin: 0 0 10px;
    line-height: 1.45;
}

.profile-compact-hint {
    margin: 8px 0 0;
    font-size: var(--text-sm);
    line-height: 1.45;
    color: var(--muted);
}

.profile-compact-email {
    font-size: var(--text-md);
    color: var(--text-label);
    margin: 0 0 16px;
    word-break: break-all;
    line-height: 1.35;
}

.profile-compact-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.profile-compact-actions .btn {
    width: 100%;
    margin: 0;
}

.hero h1 {
    margin: 0 0 16px;
    font-size: clamp(28px, 4vw, 48px);
    line-height: 1.1;
    letter-spacing: 0.02em;
    font-family: var(--font-mono-display);
    color: var(--text-heading);
}

.hero p {
    margin: 0 0 18px;
    color: var(--muted);
    max-width: none;
}

.hero-card,
.card {
    position: relative;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--border-accent);
    border-radius: 18px;
    padding: 32px;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
    overflow: hidden;
}

.hero-card::after,
.card::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.06;
    background-image: var(--binary-pattern);
    background-size: 120px 120px;
    border-radius: inherit;
    z-index: 0;
}

.hero-card > *,
.card > * {
    position: relative;
    z-index: 1;
}

@media (prefers-reduced-transparency: reduce) {
    .hero-card,
    .card {
        background: rgba(11, 14, 20, 0.96);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
}

/* Hero: те же панели, что карточки тарифов (.plan): glass, тень, без бинарного слоя */
.hero .hero-card,
.hero .card {
    border-radius: 16px;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
}

.hero .hero-card::after,
.hero .card::after {
    display: none;
}

.hero-points {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    align-items: stretch;
    justify-content: center;
}

/* Hero chips: guest + authed (same look) */
.hero-point {
    border: 1px solid var(--border);
    color: var(--text-label);
    border-radius: 12px;
    padding: 10px 14px;
    font-size: var(--text-sm);
    background: rgba(255, 255, 255, 0.03);
}

@media (max-width: 640px) {
    .hero-points {
        gap: 8px 10px;
    }
}

@media (max-width: 400px) {
    .hero-points .hero-point--hint {
        flex: 1 1 100%;
        max-width: 100%;
        justify-content: flex-start;
        text-align: left;
    }
}

.hero-point--hint {
    cursor: pointer;
    outline: none;
}

button.hero-point--hint {
    margin: 0;
    box-sizing: border-box;
    font-family: var(--font-sans);
    font-size: var(--text-sm);
    font-weight: 400;
    line-height: 1.5;
    text-align: center;
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    word-break: break-word;
    hyphens: auto;
    border: 1px solid var(--border);
    color: var(--text-label);
    border-radius: 12px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.03);
}

.hero-points--authed .hero-point--hint {
    text-align: left;
    justify-content: flex-start;
}

.hero-point--hint.is-active {
    border: 1px solid var(--ui-hover-mid);
    color: var(--text-heading);
    background: var(--ui-hover-soft);
}

.hero-point--hint:focus-visible {
    box-shadow: 0 0 0 2px var(--ui-hover-ring);
    border-color: var(--ui-hover-mid);
}

/* tippy.js v6.3.7 base (dist/tippy.css) — required for popover layout/arrow */
.tippy-box[data-animation='fade'][data-state='hidden'] {
    opacity: 0;
}
[data-tippy-root] {
    max-width: calc(100vw - 16px);
}
.tippy-box {
    position: relative;
    background-color: #333;
    color: #fff;
    border-radius: 4px;
    font-size: var(--text-md);
    line-height: 1.4;
    white-space: normal;
    outline: 0;
    transition-property: transform, visibility, opacity;
}
.tippy-box[data-placement^='top'] > .tippy-arrow {
    bottom: 0;
}
.tippy-box[data-placement^='top'] > .tippy-arrow:before {
    bottom: -7px;
    left: 0;
    border-width: 8px 8px 0;
    border-top-color: initial;
    transform-origin: center top;
}
.tippy-box[data-placement^='bottom'] > .tippy-arrow {
    top: 0;
}
.tippy-box[data-placement^='bottom'] > .tippy-arrow:before {
    top: -7px;
    left: 0;
    border-width: 0 8px 8px;
    border-bottom-color: initial;
    transform-origin: center bottom;
}
.tippy-box[data-placement^='left'] > .tippy-arrow {
    right: 0;
}
.tippy-box[data-placement^='left'] > .tippy-arrow:before {
    border-width: 8px 0 8px 8px;
    border-left-color: initial;
    right: -7px;
    transform-origin: center left;
}
.tippy-box[data-placement^='right'] > .tippy-arrow {
    left: 0;
}
.tippy-box[data-placement^='right'] > .tippy-arrow:before {
    left: -7px;
    border-width: 8px 8px 8px 0;
    border-right-color: initial;
    transform-origin: center right;
}
.tippy-box[data-inertia][data-state='visible'] {
    transition-timing-function: cubic-bezier(0.54, 1.5, 0.38, 1.11);
}
.tippy-arrow {
    width: 16px;
    height: 16px;
    color: #333;
}
.tippy-arrow:before {
    content: '';
    position: absolute;
    border-color: transparent;
    border-style: solid;
}
.tippy-content {
    position: relative;
    padding: 5px 9px;
    z-index: 1;
}

/* Veloxi theme for hero hints (glass + accent; chip fonts unchanged) */
.tippy-box[data-theme~='veloxi-hero-hint'] {
    background: rgba(11, 14, 20, 0.94);
    color: var(--text);
    border: 1px solid var(--border-accent);
    border-radius: 12px;
    font-size: 12px;
    line-height: 1.45;
    max-width: min(320px, calc(100vw - 16px));
    box-shadow:
        0 0 0 1px rgba(0, 0, 0, 0.35),
        0 22px 56px rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
}
.tippy-box[data-theme~='veloxi-hero-hint'] .tippy-content {
    padding: 0;
    max-height: min(260px, calc(100vh - 56px));
    overflow-x: hidden;
    overflow-y: auto;
}
.tippy-box[data-theme~='veloxi-hero-hint'] .tippy-arrow {
    color: rgba(11, 14, 20, 0.94);
}
@media (prefers-reduced-transparency: reduce) {
    .tippy-box[data-theme~='veloxi-hero-hint'] {
        background: rgba(11, 14, 20, 0.98);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
    .tippy-box[data-theme~='veloxi-hero-hint'] .tippy-arrow {
        color: rgba(11, 14, 20, 0.98);
    }
}

.veloxi-hero-hint-pop {
    position: relative;
    padding: 10px 38px 12px 12px;
    text-align: left;
}
.veloxi-hero-hint-pop__close {
    position: absolute;
    top: 6px;
    right: 6px;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    margin: 0;
    padding: 0;
    border: none;
    border-radius: 10px;
    color: var(--muted);
    background: transparent;
    cursor: pointer;
    transition:
        color 0.15s ease,
        background 0.15s ease;
}
.veloxi-hero-hint-pop__close:hover {
    color: var(--text-heading);
    background: rgba(255, 255, 255, 0.06);
}
.veloxi-hero-hint-pop__close:focus-visible {
    outline: none;
    box-shadow: 0 0 0 2px var(--ui-hover-ring);
}
.veloxi-hero-hint-pop__body {
    margin: 0;
    font-family: var(--font-sans);
    font-size: 10.5px;
    line-height: 1.5;
    color: var(--text);
}
@media (min-width: 480px) {
    .veloxi-hero-hint-pop__body {
        font-size: 11px;
    }
}
@media (prefers-reduced-motion: reduce) {
    .tippy-box {
        transition-property: opacity, visibility;
    }
    .veloxi-hero-hint-pop__close {
        transition: none;
    }
}

.hero-points--guest .hero-point {
    max-width: 100%;
}

@media (max-width: 400px) {
    .hero-points--guest .hero-point--hint {
        flex: 1 1 100%;
    }
}

.section-title {
    margin: 0 0 16px;
    font-size: 20px;
    letter-spacing: 0.04em;
    font-family: var(--font-mono-display);
    color: var(--text-heading);
    text-transform: none;
}

.auth-card .section-title {
    margin-bottom: 10px;
}

.auth-card .subtitle {
    margin-bottom: 16px;
}

.auth-container {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-top: 2px;
}

.tg-auth-block {
    width: 100%;
}

.small-label {
    margin: 0 0 8px;
    font-size: var(--text-sm);
    letter-spacing: 0.01em;
    color: var(--muted);
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 2px 0;
    color: var(--muted);
    font-size: var(--text-sm);
    user-select: none;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1 1 auto;
    height: 1px;
    background: var(--border);
}

.auth-divider span {
    flex-shrink: 0;
}

.tg-auth-fallback {
    width: 100%;
}

.tg-auth-fallback .btn-telegram {
    margin-top: 0;
}

.email-auth-form {
    width: 100%;
}

.email-auth-form .input-group--auth {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.auth-card .email-auth-form .input-group--auth input,
.auth-card .email-auth-flow .input-group--auth input {
    border-radius: 12px;
    min-height: 40px;
    padding: 10px 14px;
    background: rgba(0, 0, 0, 0.35);
    border-color: var(--border-accent);
}

.auth-card .email-auth-form .input-group--auth input::placeholder,
.auth-card .email-auth-flow .input-group--auth input::placeholder {
    color: rgba(156, 163, 175, 0.75);
}

.email-auth-form .btn-auth-main,
.email-auth-flow .btn-auth-main {
    width: 100%;
    margin-top: 12px;
}

.auth-forgot-wrap {
    margin-top: 14px;
    text-align: center;
}

.auth-forgot-link {
    font-size: var(--text-sm);
    color: var(--muted);
    text-decoration: underline;
    text-decoration-color: rgba(211, 26, 36, 0.35);
    text-underline-offset: 2px;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font-family: inherit;
    transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

.auth-forgot-link:hover,
.auth-forgot-link:focus-visible {
    color: var(--brand-red);
    text-decoration-color: var(--brand-red);
}

.email-auth-flow {
    width: 100%;
}

.email-auth-flow__title {
    margin: 0 0 8px;
    font-size: 1.1rem;
}

.email-auth-flow__intro {
    margin-bottom: 14px;
}

.email-auth-flow__form .input-group--auth {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-bottom: 0;
}

.email-auth-flow__form .email-auth-flow__field {
    margin-bottom: 18px;
}

.email-auth-flow__form .email-auth-flow__field-label {
    display: block;
}

.email-auth-flow__form .email-auth-flow__submit {
    margin-top: 20px;
}

.auth-tablist {
    display: flex;
    gap: 0;
    margin-bottom: 16px;
    border-radius: 12px;
    border: 1px solid var(--border);
    overflow: hidden;
    background: rgba(0, 0, 0, 0.25);
}

.auth-tablist__tab {
    flex: 1 1 50%;
    margin: 0;
    padding: 10px 12px;
    font-size: var(--text-md);
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: transparent;
    color: var(--muted);
    transition:
        background 0.22s ease,
        color 0.22s ease;
}

.auth-tablist__tab.is-active {
    background: rgba(211, 26, 36, 0.18);
    color: #fff;
}

.auth-tablist__tab:focus-visible {
    outline: 2px solid var(--brand-red);
    outline-offset: 2px;
}

.auth-tab-panel {
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    pointer-events: none;
    transition:
        opacity 0.22s ease,
        max-height 0.28s ease;
}

.auth-tab-panel.is-active {
    opacity: 1;
    max-height: 720px;
    overflow: visible;
    pointer-events: auto;
}

@media (prefers-reduced-motion: reduce) {
    .auth-tab-panel,
    .auth-tablist__tab {
        transition: none;
    }
}

.field-error-msg {
    margin: 0 0 8px;
    font-size: var(--text-sm);
    color: var(--brand-red, #d31a24);
    line-height: 1.35;
}

.email-auth-flow .field-error-msg--password-prominent {
    text-align: center;
    margin: 10px 0 14px;
    padding: 0 6px;
    font-size: var(--text-md);
    font-weight: 600;
    line-height: 1.45;
    color: var(--brand-red, #d31a24);
}

.field-error-msg--prominent {
    text-align: center;
    margin: 10px 0 14px;
    padding: 10px 12px;
    font-size: var(--text-md);
    font-weight: 600;
    line-height: 1.45;
    color: var(--brand-red, #d31a24);
    background: rgba(211, 26, 36, 0.12);
    border: 1px solid var(--brand-red, #d31a24);
    border-radius: 8px;
}

.email-auth-flow .input-group--auth.is-field-error input,
.auth-card .email-auth-flow .input-group--auth.is-field-error input {
    border-color: var(--brand-red, #d31a24);
    box-shadow: 0 0 0 1px var(--brand-red, #d31a24);
}

.alert--field-prominent {
    margin: 10px 0 12px;
    padding: 10px 12px;
    font-size: var(--text-md);
    font-weight: 600;
    line-height: 1.45;
    text-align: center;
    color: var(--brand-red, #d31a24);
    background: rgba(211, 26, 36, 0.12);
    border: 1px solid var(--brand-red, #d31a24);
    border-radius: 8px;
}

.field input.is-field-error,
.field textarea.is-field-error {
    border-color: var(--brand-red, #d31a24);
    box-shadow: 0 0 0 1px var(--brand-red, #d31a24);
}

.email-auth-flow__terms {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 12px 0 4px;
    font-size: var(--text-sm);
    color: var(--muted);
    cursor: pointer;
    line-height: 1.4;
}

.email-auth-flow__terms input {
    margin-top: 3px;
    flex-shrink: 0;
}

.email-auth-flow__terms-text a {
    color: var(--brand-red);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.email-auth-flow__submit:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    filter: grayscale(0.15);
}

.page-registration .btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    filter: grayscale(0.15);
}

.email-auth-flow__spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.25);
    border-top-color: rgba(255, 255, 255, 0.95);
    border-radius: 50%;
    flex-shrink: 0;
}

.email-auth-flow__spinner:not([hidden]) {
    display: inline-block;
    animation: email-auth-spin 0.65s linear infinite;
}

@media (prefers-reduced-motion: reduce) {
    .email-auth-flow__spinner:not([hidden]) {
        animation: none;
        border-top-color: rgba(255, 255, 255, 0.6);
    }
}

@keyframes email-auth-spin {
    to {
        transform: rotate(360deg);
    }
}

.modal-panel--guest-auth-flow .email-auth-flow__title {
    margin-top: 0;
}

.modal-panel--guest-auth-flow .email-auth-flow__submit.btn-block {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    position: relative;
}

#home-account-modal .email-auth-form .btn-auth-main,
#home-account-modal .email-auth-flow .btn-auth-main {
    position: relative;
    background: transparent;
    border: 1px solid var(--brand-red);
    color: #fff;
    box-shadow: none;
    font-size: var(--text-md);
    min-height: 40px;
    height: 40px;
    padding: 0 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition:
        background 0.2s,
        color 0.2s,
        box-shadow 0.2s,
        border-color 0.2s;
}

#home-account-modal .email-auth-form .btn-auth-main:hover,
#home-account-modal .email-auth-flow .btn-auth-main:hover {
    background: var(--brand-red);
    color: #fff;
    box-shadow:
        0 0 28px rgba(255, 255, 255, 0.2),
        0 0 48px rgba(211, 26, 36, 0.35);
    filter: none;
}

#home-account-modal .tg-auth-block .telegram-widget-wrap {
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid var(--ui-hover-mid);
    background: var(--ui-hover-soft);
    box-shadow: 0 4px 24px rgba(0, 242, 255, 0.12);
}

#home-account-modal .tg-auth-block .telegram-widget-wrap iframe {
    border-radius: 12px !important;
}

.hero:not(.hero--authed) .hero-point {
    opacity: 0.86;
}

.hero:not(.hero--authed) .hero-card > p {
    opacity: 0.93;
}

.btn-telegram {
    width: 100%;
    margin-top: 4px;
    border: 0;
    border-radius: 10px;
    padding: 12px 14px;
    background: #229ed9;
    color: #fff;
    font-weight: 600;
    font-size: var(--text-md);
    cursor: not-allowed;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    opacity: 0.72;
}

.btn-telegram:not(:disabled) {
    cursor: pointer;
    opacity: 1;
}

.btn-telegram:not(:disabled):hover {
    filter: brightness(1.06);
}

.telegram-widget-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.telegram-widget-wrap iframe {
    border-radius: 10px !important;
    vertical-align: middle;
}

.telegram-widget-wrap[data-tg-radius='0'] iframe {
    border-radius: 0 !important;
}

.telegram-widget-wrap--settings {
    margin-top: 10px;
}

.telegram-widget-wrap--skipped {
    display: none;
}

.telegram-callback-form {
    display: none;
}

.subtitle {
    margin: 0 0 22px;
    color: var(--muted);
    font-size: var(--text-md);
}

label {
    display: block;
    font-size: var(--text-sm);
    margin: 0 0 8px;
    color: var(--text-label);
}

input:not([type="checkbox"]):not([type="radio"]),
textarea {
    width: 100%;
    border: 1px solid var(--border);
    background: rgba(0, 0, 0, 0.45);
    color: var(--text-heading);
    border-radius: 10px;
    padding: 12px 14px;
    font-size: var(--text-md);
    outline: none;
    transition:
        border-color 0.15s,
        box-shadow 0.15s;
    font-family: inherit;
    line-height: 1.45;
    caret-color: var(--brand-red);
}

@supports (caret-shape: block) {
    input:not([type="checkbox"]):not([type="radio"]),
    textarea {
        caret-shape: block;
    }
}

input[type="checkbox"],
input[type="radio"] {
    width: auto;
    max-width: none;
    padding: 0;
    margin: 0;
    border: none;
    background: transparent;
    flex-shrink: 0;
    cursor: pointer;
    accent-color: var(--accent);
    vertical-align: top;
}

textarea {
    min-height: 140px;
    resize: vertical;
    vertical-align: top;
}

input:not([type="checkbox"]):not([type="radio"]):focus,
textarea:focus {
    border-color: var(--brand-red);
    box-shadow: 0 0 0 1px var(--brand-red);
}

/* Главная: форма входа (email / пароль) — красный акцент вместо циана */
.auth-card input:not([type="checkbox"]):not([type="radio"]):focus,
.auth-card textarea:focus {
    border-color: var(--brand-red);
    box-shadow: 0 0 0 1px var(--brand-red);
}

.field {
    margin-bottom: 20px;
}

.btn {
    width: 100%;
    border: 1px solid var(--brand-red);
    border-radius: 10px;
    padding: 12px 14px;
    background: transparent;
    color: #fff;
    font-weight: 600;
    font-size: var(--text-md);
    cursor: pointer;
    transition:
        background 0.2s,
        color 0.2s,
        box-shadow 0.2s,
        border-color 0.2s;
}

.btn:hover {
    background: var(--brand-red);
    color: #fff;
    box-shadow:
        0 0 28px rgba(255, 255, 255, 0.22),
        0 0 48px rgba(211, 26, 36, 0.35);
    border-color: var(--brand-red);
}

.btn-ghost {
    background: transparent;
    border: 1px solid var(--border-accent);
    color: var(--text-heading);
    cursor: pointer;
    width: auto;
}

.btn-ghost:hover {
    background: var(--brand-red);
    color: #fff;
    border-color: var(--brand-red);
    box-shadow:
        0 0 24px rgba(255, 255, 255, 0.18),
        0 0 40px rgba(211, 26, 36, 0.3);
}

.btn-secondary {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-heading);
}

.btn-secondary:hover {
    background: var(--brand-red);
    border-color: var(--brand-red);
    color: #fff;
    box-shadow:
        0 0 24px rgba(255, 255, 255, 0.18),
        0 0 40px rgba(211, 26, 36, 0.28);
}

/* Текущий тариф на плитке: как «Продлить», но неактивно */
.btn.btn-tariff-active:disabled {
    background: linear-gradient(180deg, #fde047 0%, #eab308 100%);
    border: 1px solid rgba(234, 179, 8, 0.85);
    color: #1c1504;
    opacity: 1;
    cursor: default;
    box-shadow: 0 4px 16px rgba(234, 179, 8, 0.28);
}

.btn.btn-tariff-active:disabled:hover {
    background: linear-gradient(180deg, #fde047 0%, #eab308 100%);
    filter: none;
}

.btn-danger {
    background: transparent;
    border: 1px solid var(--danger);
    color: var(--danger);
    font-weight: 600;
}

.btn-danger:hover {
    background: var(--danger);
    color: #fff;
    box-shadow:
        0 0 24px rgba(255, 255, 255, 0.2),
        0 0 36px rgba(255, 107, 107, 0.35);
    filter: none;
}

.btn-renew {
    background: linear-gradient(180deg, #fde047 0%, #eab308 100%);
    border: 1px solid rgba(234, 179, 8, 0.85);
    color: #1c1504;
    box-shadow:
        0 4px 16px rgba(234, 179, 8, 0.28),
        0 0 0 1px rgba(211, 26, 36, 0.15);
}

.btn-renew:hover {
    background: linear-gradient(180deg, #fef08a 0%, #facc15 100%);
    filter: brightness(1.02);
    box-shadow:
        0 6px 22px rgba(234, 179, 8, 0.35),
        0 0 0 1px rgba(211, 26, 36, 0.2);
}

.btn-ubl {
    background: linear-gradient(135deg, #5b4fc7 0%, #7c5fd4 100%);
    color: #fff;
    border: 1px solid rgba(124, 95, 212, 0.85);
    box-shadow: 0 4px 16px rgba(91, 79, 199, 0.28);
}

.btn-ubl:hover:not(:disabled) {
    filter: brightness(1.06);
}

.btn-ubl:disabled,
.btn-ubl[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
    filter: none;
    box-shadow: none;
}

.profile-section--danger-zone {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid rgba(255, 107, 107, 0.35);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    min-width: 0;
    flex-shrink: 1;
}

.nav-actions .nav-account-open-btn,
.nav-actions .logout-form .nav-logout-btn {
    flex-shrink: 0;
    width: var(--nav-text-btn-width);
    min-width: 0;
    max-width: 100%;
    height: var(--nav-control-height);
    min-height: var(--nav-control-height);
    padding: 0 10px;
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    font-size: var(--text-sm);
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-account-open-btn__icon {
    display: none;
    flex-shrink: 0;
}

.nav-contact-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var(--nav-control-height);
    height: var(--nav-control-height);
    padding: 0;
    margin: 0;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-accent);
    border-radius: 8px;
    color: var(--text-label);
    cursor: pointer;
    flex-shrink: 0;
    transition:
        background 0.2s,
        color 0.2s,
        border-color 0.2s,
        box-shadow 0.2s;
}

a.nav-contact-btn {
    text-decoration: none;
    box-sizing: border-box;
}

a.nav-contact-btn:visited {
    color: var(--text-label);
}

.nav-contact-btn:hover {
    background: var(--ui-hover-soft);
    border-color: var(--ui-hover);
    color: var(--ui-hover);
    box-shadow: 0 0 16px rgba(0, 242, 255, 0.2);
}

.logout-form {
    margin: 0;
    display: contents;
}

.nav-logout-btn {
    position: relative;
}

.nav-logout-btn__icon {
    display: none;
    flex-shrink: 0;
}

.profile-meta--tight {
    margin-top: 0;
}

.profile-email-row--label {
    margin-bottom: 6px;
}

.profile-email-row--value {
    margin-bottom: 12px;
    word-break: break-all;
}

.profile-email-row--spaced {
    margin-bottom: 18px;
}

.profile-email-row--login-line {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px 10px;
    margin-bottom: 18px;
}

.profile-email-row--login-line .profile-email-row__login-value {
    color: var(--text-heading);
    font-weight: 500;
    word-break: break-all;
}

.profile-badges-row {
    margin-bottom: 14px;
}

.badge-telegram {
    margin-left: 8px;
    border-color: var(--ui-hover-mid);
    color: var(--ui-hover);
}

.profile-section--first {
    margin-top: 0;
    padding-top: 16px;
}

.profile-section--flush {
    margin-top: 0;
    padding-top: 0;
    border: 0;
}

.profile-section--bordered {
    margin-top: 0;
    padding-top: 12px;
    border-top: 1px solid var(--border);
}

.btn-block {
    width: 100%;
}

/* Ссылки с классом .btn: как у <button>, иначе width и высота строки в карточках не совпадают */
a.btn,
a.btn:visited {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    text-decoration: none;
}

.form-stack {
    margin-top: 10px;
}

.form-stack--notify-channel .btn-block {
    margin-top: 4px;
}

.notify-channel-group {
    display: flex;
    gap: 10px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.notify-channel-segment {
    flex: 1;
    min-width: min(140px, 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 0 !important;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    cursor: pointer;
    transition:
        border-color 0.15s,
        background 0.15s,
        box-shadow 0.15s;
    font-size: var(--text-md);
    font-weight: 600;
    color: var(--text);
}

.notify-channel-segment input[type='radio'] {
    width: auto;
    margin: 0;
    flex-shrink: 0;
    accent-color: var(--accent);
}

.notify-channel-segment:has(input:checked):not(.notify-channel-segment--disabled) {
    border-color: var(--ui-hover);
    background: var(--ui-hover-soft);
    box-shadow: 0 0 0 1px var(--ui-hover-mid);
}

.notify-channel-segment:hover:not(.notify-channel-segment--disabled) {
    border-color: var(--ui-hover-mid);
    background: rgba(255, 255, 255, 0.05);
}

.notify-channel-segment--disabled {
    opacity: 0.52;
    cursor: not-allowed;
}

.notify-channel-segment--disabled input {
    cursor: not-allowed;
}

.notify-channel-hints {
    margin: 0 0 14px;
    font-size: 12px;
    line-height: 1.4;
    color: var(--muted);
}

.alert--field {
    margin-bottom: 12px;
}

.profile-meta--after-sub {
    margin-top: 14px;
    font-size: var(--text-sm);
}

.profile-meta--note {
    margin-bottom: 12px;
    font-size: 12px;
}

.profile-meta--block {
    margin-bottom: 12px;
}

.locale-switcher {
    display: inline-flex;
    align-items: stretch;
    height: var(--nav-control-height);
    flex-shrink: 0;
}

.locale-switcher__desktop {
    display: inline-flex;
    align-items: stretch;
    gap: 4px;
    height: 100%;
}

.locale-switcher__mobile {
    display: none;
    margin: 0;
    height: 100%;
}

.locale-switcher__desktop form {
    margin: 0;
    display: flex;
    align-items: stretch;
}

.locale-switcher__desktop .btn-lang {
    width: auto;
    min-width: 36px;
    height: 100%;
    min-height: var(--nav-control-height);
    padding: 0 10px;
    margin: 0;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: var(--text-sm);
    font-weight: 600;
    line-height: 1.2;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    color: var(--text-label);
    cursor: pointer;
    font-family: inherit;
    appearance: none;
    -webkit-appearance: none;
}

.locale-switcher__desktop span.btn-lang {
    cursor: default;
}

.locale-switcher__desktop .btn-lang:hover {
    background: var(--red-soft);
    border-color: var(--red-mid);
    color: var(--text-heading);
}

.locale-switcher__desktop .btn-lang.is-current {
    border-color: var(--brand-red);
    color: var(--text-heading);
    background: var(--red-soft);
    box-shadow: 0 0 14px rgba(211, 26, 36, 0.25);
}

.locale-switcher__select {
    height: var(--nav-control-height);
    min-height: var(--nav-control-height);
    margin: 0;
    padding: 0 28px 0 10px;
    box-sizing: border-box;
    font-size: 12px;
    font-weight: 600;
    font-family: inherit;
    line-height: 1.2;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    color: var(--text-label);
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239ca3af' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    max-width: 76px;
    min-width: 58px;
}

.locale-switcher__select:hover,
.locale-switcher__select:focus {
    background-color: var(--red-soft);
    border-color: var(--red-mid);
    color: var(--text-heading);
    outline: none;
}

@media (max-width: 767px) {
    .nav {
        flex-wrap: nowrap;
        gap: 8px;
        padding: 16px 0;
    }

    .brand--wordmark {
        max-width: min(150px, 36vw);
        min-width: 0;
    }

    .nav-actions {
        flex-wrap: nowrap;
        gap: 6px;
        flex-shrink: 1;
        justify-content: flex-end;
    }

    .nav-actions .nav-account-open-btn {
        width: auto;
        min-width: 0;
        max-width: min(118px, 30vw);
        padding: 0 8px;
        font-size: 12px;
    }

    .nav-actions .nav-account-open-btn--authed {
        position: relative;
        max-width: none;
        width: var(--nav-control-height);
        min-width: var(--nav-control-height);
        padding: 0;
    }

    .nav-actions .nav-account-open-btn--authed .nav-account-open-btn__text {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    .nav-actions .nav-account-open-btn--authed .nav-account-open-btn__icon {
        display: block;
    }

    .nav-actions .logout-form .nav-logout-btn {
        max-width: none;
        width: var(--nav-control-height);
        min-width: var(--nav-control-height);
        padding: 0;
    }

    .nav-logout-btn__text {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    .nav-logout-btn__icon {
        display: block;
    }

    .locale-switcher__desktop {
        display: none !important;
    }

    .locale-switcher__mobile {
        display: block;
    }

    .locale-switcher {
        flex-shrink: 0;
    }
}

.alert {
    border-radius: 10px;
    padding: 10px 12px;
    font-size: var(--text-sm);
    margin-bottom: 14px;
}

.alert-success {
    background: rgba(82, 211, 138, 0.12);
    color: var(--success);
    border: 1px solid rgba(82, 211, 138, 0.35);
}

.alert-error {
    background: rgba(255, 107, 107, 0.12);
    color: var(--danger);
    border: 1px solid rgba(255, 107, 107, 0.35);
}

.alert-info {
    border: 1px solid var(--ui-hover-mid);
    background: var(--ui-hover-soft);
    color: var(--text-label);
}

.profile-dash {
    text-align: left;
}

.profile-meta {
    font-size: var(--text-sm);
    color: var(--muted);
    margin: 0 0 16px;
    line-height: 1.5;
}

.profile-email-row {
    font-size: 15px;
    margin-bottom: 8px;
    word-break: break-all;
}

.profile-email-row strong {
    color: var(--text-label);
    font-weight: 600;
}

.badge-ok {
    display: inline-block;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 999px;
    border: 1px solid rgba(82, 211, 138, 0.4);
    color: var(--success);
    margin-left: 8px;
    vertical-align: middle;
}

.badge-warn {
    display: inline-block;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 999px;
    border: 1px solid rgba(230, 200, 108, 0.45);
    color: #e6c86c;
    margin-left: 8px;
    vertical-align: middle;
}

.profile-section {
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

.profile-section h3 {
    margin: 0 0 10px;
    font-size: var(--text-md);
    font-weight: 600;
    color: var(--text-label);
}

.btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
    align-items: center;
}

.btn-row .btn {
    width: auto;
    flex: 0 0 auto;
}

.modal-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 200;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.modal-backdrop.is-open {
    display: flex;
}

.modal-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--border-accent);
    border-radius: 18px;
    padding: 28px 28px 22px;
    max-width: min(440px, 92vw);
    width: 100%;
    max-height: min(88vh, 720px);
    overflow-y: auto;
    position: relative;
    box-shadow: 0 28px 88px rgba(0, 0, 0, 0.55);
}

@media (prefers-reduced-transparency: reduce) {
    .modal-panel {
        background: rgba(11, 14, 20, 0.98);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
}

.modal-panel--wide {
    max-width: min(600px, 92vw);
    /* Настройки: чуть выше, чтобы типовой контент без вертикальной прокрутки */
    max-height: min(94vh, 920px);
}

.modal-panel--profile {
    max-width: min(520px, 94vw);
    /* Выше базового .modal-panel (88vh / 720px), вровень с окном настроек */
    max-height: min(94vh, 920px);
}

.modal-panel--contact {
    max-width: min(520px, 94vw);
    max-height: min(94vh, 920px);
    min-width: 0;
    overflow-x: hidden;
}

.modal-panel--home-account {
    max-width: min(440px, 94vw);
}

.modal-panel--register-verify .register-verify-code-input,
.modal-panel--guest-auth-flow .register-verify-code-input {
    display: block;
    width: 100%;
    box-sizing: border-box;
    font-family: var(--font-mono-display);
    font-size: 1.45rem;
    letter-spacing: 0.28em;
    text-align: center;
    padding: 12px 14px;
}

.modal-panel--guest-auth-flow .guest-auth-flow-step > .form-stack {
    margin-top: 16px;
}

.modal-panel--guest-auth-flow #guest-auth-flow-email-form .input-group--auth {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.modal-panel--guest-auth-flow #guest-auth-flow-email-form > .btn-block {
    margin-top: 14px;
}

.modal-panel--guest-auth-flow #guest-auth-flow-verify-form > .btn-block {
    margin-top: 16px;
}

.modal-panel--guest-auth-flow .guest-auth-flow-step > .auth-forgot-wrap {
    margin-top: 16px;
}

.contact-privacy-label {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    width: 100%;
    max-width: 100%;
    font-size: var(--text-md);
    line-height: 1.45;
    color: var(--muted);
    cursor: pointer;
}

.contact-privacy-label > span {
    flex: 1 1 0%;
    min-width: 0;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.contact-privacy-label a {
    overflow-wrap: anywhere;
    word-break: break-word;
    font-size: inherit;
    line-height: inherit;
}

.contact-privacy-label input {
    margin-top: 4px;
    flex-shrink: 0;
}

.contact-privacy-field {
    margin-bottom: 14px;
}

.contact-status-actions {
    margin: 0 0 16px;
}

#contact-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* reCAPTCHA v3: плавающий значок скрыт; рядом с формой — текст со ссылками (требование Google). */
.grecaptcha-badge {
    visibility: hidden;
}

.contact-recaptcha-notice {
    margin: 12px 0 0;
    font-size: 12px;
    line-height: 1.45;
    color: var(--muted);
}

.contact-recaptcha-notice a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.modal-profile-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px 12px;
    margin-bottom: 14px;
    padding-right: 36px;
}

.modal-profile-header__name {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 100%;
    text-align: right;
    font-family: var(--font-mono-display);
    font-size: var(--text-sm);
    font-weight: 500;
    letter-spacing: 0.02em;
    color: var(--text-label);
    line-height: 1.35;
    word-break: break-all;
}

@media (max-width: 420px) {
    .modal-profile-header {
        flex-direction: column;
        align-items: stretch;
    }

    .modal-profile-header__name {
        text-align: left;
    }
}

.modal-panel h3 {
    margin: 0 0 12px;
    font-size: 18px;
}

.modal-panel .modal-profile-header h3 {
    margin-bottom: 0;
}

.modal-panel p {
    margin: 0 0 10px;
    font-size: var(--text-md);
    color: var(--muted);
    line-height: 1.5;
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 12px;
    border: 0;
    background: none;
    color: var(--muted);
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    padding: 4px 8px;
}

.modal-close:hover {
    color: var(--ui-hover);
}

.modal-close--soft {
    font-size: 0;
    padding: 8px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    transition:
        background 0.15s ease,
        color 0.15s ease;
}

.modal-close--soft:hover {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text);
}

.modal-close__glyph {
    position: relative;
    width: 14px;
    height: 14px;
    display: block;
}

.modal-close__glyph::before,
.modal-close__glyph::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 14px;
    height: 1.5px;
    background: currentColor;
    border-radius: 1px;
}

.modal-close__glyph::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.modal-close__glyph::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

.modal-panel--password-reset {
    max-width: 420px;
}

.password-reset-modal__feedback {
    margin: 0 0 14px;
    padding: 10px 12px;
    border-radius: 10px;
    font-size: var(--text-sm);
    line-height: 1.45;
}

.password-reset-modal__feedback--ok {
    background: rgba(82, 211, 138, 0.12);
    border: 1px solid rgba(82, 211, 138, 0.35);
    color: #86efac;
}

.password-reset-modal__feedback--err {
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.35);
    color: #fecaca;
}

.sub-kv {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: var(--text-sm);
    margin: 6px 0;
    color: var(--text-label);
}

.sub-kv span:first-child {
    color: var(--muted);
}

.profile-sub-add {
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}

.profile-sub-add__title {
    margin: 0 0 0.5rem;
    font-size: var(--text-md);
    font-weight: 600;
    color: var(--text);
}

.account-amnezia-wg-details {
    margin: 0;
}

.account-settings-accordions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.account-settings-details {
    margin: 0;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-elevated, rgba(255, 255, 255, 0.02));
}

.account-settings-details__summary {
    cursor: pointer;
    list-style: none;
    font-size: var(--text-md);
    font-weight: 600;
    color: var(--text);
    padding: 12px 14px;
}

.account-settings-details__summary::-webkit-details-marker {
    display: none;
}

.account-settings-details__body {
    padding: 0 14px 14px;
    border-top: 1px solid var(--border);
}

.account-settings-details__body > .profile-meta:first-child {
    margin-top: 12px;
}

.profile-meta--divider {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
}

.telegram-bind-link-panel {
    margin-top: 12px;
}

.telegram-bind-link-panel--hidden {
    display: none;
}

.telegram-bind-link-panel .js-telegram-bind-open {
    margin-top: 10px;
}

.account-amnezia-wg-details__summary {
    cursor: pointer;
    list-style: none;
    font-size: var(--text-md);
    font-weight: 600;
    color: var(--text);
    padding: 0.15rem 0;
}

.account-amnezia-wg-details__summary::-webkit-details-marker {
    display: none;
}

.account-amnezia-wg-details__intro {
    margin: 0.5rem 0 0.75rem;
}

.account-amnezia-wg-root {
    min-height: 0;
}

.amnezia-wg-node {
    padding-top: 0.75rem;
    margin-top: 0.75rem;
    border-top: 1px solid var(--border);
    text-align: center;
}

.amnezia-wg-node:first-child {
    border-top: none;
    padding-top: 0;
    margin-top: 0;
}

.amnezia-wg-node__title {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.5rem;
    word-break: break-word;
}

.amnezia-wg-node__actions {
    margin-bottom: 0.5rem;
    max-width: 280px;
    margin-left: auto;
    margin-right: auto;
}

.amnezia-wg-node__qr-wrap {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-top: 0.25rem;
}

.amnezia-wg-node__qr {
    display: block;
    width: 256px;
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    background: #fff;
    padding: 8px;
    box-sizing: border-box;
}

.amnezia-wg-node__qr-hint {
    margin: 0.25rem 0 0;
    text-align: center;
    max-width: 280px;
    margin-left: auto;
    margin-right: auto;
}

.profile-sub-add--checkout-cta {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
}

.profile-sub-add--checkout-cta > .btn {
    width: 100%;
    box-sizing: border-box;
}

.profile-checkout-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    width: 100%;
    align-items: stretch;
}

.profile-checkout-actions--single {
    grid-template-columns: 1fr;
}

.profile-checkout-actions > form.profile-checkout-actions__cell {
    display: block;
    width: 100%;
    margin: 0;
    min-width: 0;
}

.profile-checkout-actions__cell--stack {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.profile-checkout-actions__cell--stack > .form-stack {
    width: 100%;
}

/* Одна высота/ширина у «Продлить» и «Изменить тариф» (без flex-растягивания разной высоты) */
.profile-checkout-actions .btn.btn-renew,
.profile-checkout-actions > button.btn {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    margin: 0;
    min-height: 48px;
    padding: 12px 10px;
    font-size: var(--text-md);
    font-weight: 600;
    line-height: 1.2;
}

.profile-checkout-actions > button.btn.js-profile-go-tariffs {
    background: transparent;
    color: #fff;
    border: 1px solid var(--brand-red);
}

.profile-checkout-actions > button.btn.js-profile-go-tariffs:hover {
    background: var(--brand-red);
    border-color: var(--brand-red);
    box-shadow:
        0 0 28px rgba(255, 255, 255, 0.2),
        0 0 48px rgba(211, 26, 36, 0.35);
}

/* Модалка профиля: одна высота у «Просмотр», улучшить/заказать, активно, продлить */
#account-drawer .profile-sub-add--checkout-cta .btn,
#account-drawer .profile-sub-add--checkout-cta a.btn {
    min-height: 48px;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1.2;
}

#account-drawer .profile-sub-add--checkout-cta a.btn {
    width: 100%;
}

/* — Account drawer (личный кабинет) — */
.account-drawer {
    position: fixed;
    inset: 0;
    z-index: 210;
    pointer-events: none;
    visibility: hidden;
}

.account-drawer.is-open {
    pointer-events: auto;
    visibility: visible;
}

.account-drawer__overlay {
    position: absolute;
    inset: 0;
    z-index: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.account-drawer.is-open .account-drawer__overlay {
    opacity: 1;
}

.account-drawer__panel {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    width: min(var(--account-drawer-panel-width), 100%);
    max-width: 100%;
    height: 100%;
    max-height: 100dvh;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: var(--glass-bg);
    border-left: 1px solid var(--border-accent);
    border-radius: 18px 0 0 18px;
    box-shadow: -12px 0 48px rgba(0, 0, 0, 0.45);
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
}

@media (max-width: 560px) {
    .account-drawer__panel {
        width: 100%;
        border-radius: 0;
        border-left: none;
        box-shadow: -8px 0 32px rgba(0, 0, 0, 0.35);
    }

    .account-drawer__header {
        padding: max(16px, env(safe-area-inset-top, 0px)) 16px 10px;
    }

    .account-drawer__tabs {
        padding: 0 10px 8px;
    }

    .account-drawer__tab {
        padding: 10px 6px;
        font-size: var(--text-sm);
        line-height: 1.25;
    }

    .account-drawer__body {
        padding: 14px 16px 8px;
    }

    .account-drawer__footer {
        padding: 12px 16px max(20px, env(safe-area-inset-bottom, 0px));
    }
}

.account-drawer.is-open .account-drawer__panel {
    transform: translateX(0);
}

@media (prefers-reduced-motion: reduce) {
    .account-drawer__overlay,
    .account-drawer__panel {
        transition: none;
    }

    .account-drawer.is-open .account-drawer__overlay {
        opacity: 1;
    }

    .account-drawer.is-open .account-drawer__panel {
        transform: translateX(0);
    }
}

@media (prefers-reduced-transparency: reduce) {
    .account-drawer__overlay {
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
}

body.account-drawer-open {
    overflow: hidden;
}

.account-drawer__head {
    flex: 0 0 auto;
    position: sticky;
    top: 0;
    z-index: 3;
    background: var(--glass-bg);
    border-bottom: 1px solid var(--border);
}

.account-drawer__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 18px 10px;
}

.account-drawer__header-email {
    flex: 1;
    min-width: 0;
    font-family: var(--font-mono-display);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--text-label);
    word-break: break-all;
    line-height: 1.35;
}

.account-drawer__close {
    flex-shrink: 0;
    border: 0;
    background: none;
    color: var(--muted);
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    padding: 4px 8px;
    margin: -4px -8px -4px 0;
}

.account-drawer__close:hover {
    color: var(--ui-hover);
}

.account-drawer__tabs {
    display: flex;
    gap: 0;
    padding: 0 12px 8px;
}

.account-drawer__tab {
    flex: 1;
    min-width: 0;
    padding: 10px 12px;
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: var(--text-md);
    font-weight: 600;
    cursor: pointer;
    border-radius: 10px 10px 0 0;
    transition:
        color 0.15s ease,
        background 0.15s ease;
}

.account-drawer__tab:hover {
    color: var(--text);
}

.account-drawer__tab--active {
    color: var(--text);
    background: rgba(255, 255, 255, 0.06);
    box-shadow: inset 0 -2px 0 var(--brand-red);
}

.account-drawer__body {
    flex: 1 1 0;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 16px 18px 8px;
    -webkit-overflow-scrolling: touch;
}

.account-drawer__pane:not(.account-drawer__pane--active) {
    display: none;
}

.account-drawer__pane.account-drawer__pane--active {
    display: block;
}

.account-drawer__footer {
    flex: 0 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem 1.25rem;
    margin-top: auto;
    padding: 12px 18px 20px;
    border-top: 1px solid var(--border);
    text-align: center;
    background: var(--glass-bg);
}

.account-drawer__support-link {
    display: inline-block;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.38);
    text-decoration: none;
    padding-bottom: 4px;
}

.account-drawer__support-link:hover {
    color: rgba(255, 255, 255, 0.55);
}

.account-drawer__ajax-feedback {
    margin: 0 0 16px;
    padding: 10px 12px;
    border-radius: 10px;
    font-size: var(--text-sm);
    line-height: 1.45;
}

.account-drawer__ajax-feedback--ok {
    background: rgba(82, 211, 138, 0.12);
    border: 1px solid rgba(82, 211, 138, 0.35);
    color: #86efac;
}

.account-drawer__ajax-feedback--err {
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.35);
    color: #fecaca;
}

.account-drawer .profile-section--first {
    margin-top: 0;
}

.account-drawer .profile-section--first h3 {
    margin-top: 16px;
}

.account-drawer__logout-form {
    margin: 0;
}

.account-drawer .account-drawer__logout-btn.btn {
    width: 100%;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 500;
    background: transparent;
    color: var(--muted);
    border: 1px solid rgba(255, 255, 255, 0.14);
    padding: 10px 14px;
    border-radius: 12px;
    box-shadow: none;
    transition:
        color 0.15s ease,
        border-color 0.15s ease,
        background 0.15s ease;
}

.account-drawer .account-drawer__logout-btn.btn:hover {
    color: var(--text);
    border-color: rgba(255, 255, 255, 0.24);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: none;
}

.account-drawer__password-section .profile-meta {
    margin-bottom: 12px;
}

.account-drawer__password-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.account-drawer__password-toggle-chevron {
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.account-drawer__password-toggle--open .account-drawer__password-toggle-chevron {
    transform: rotate(180deg);
}

.account-drawer__password-panel {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.35s ease;
}

.account-drawer__password-panel.is-open {
    grid-template-rows: 1fr;
}

.account-drawer__password-panel-inner {
    overflow: hidden;
    min-height: 0;
}

.account-drawer__password-panel.is-open .account-drawer__password-panel-inner {
    padding-top: 14px;
}

.account-drawer__password-panel.is-open .account-drawer__password-form .field:last-of-type {
    margin-bottom: 14px;
}

@media (prefers-reduced-motion: reduce) {
    .account-drawer__password-panel {
        transition: none;
    }

    .account-drawer__password-toggle-chevron {
        transition: none;
    }
}

.account-drawer .account-drawer__danger-zone {
    margin-top: 0.35rem;
    padding-top: 0.65rem;
}

.account-drawer .account-drawer__danger-zone h3 {
    margin: 0 0 6px;
    font-size: 15px;
    line-height: 1.25;
}

.account-drawer .account-drawer__danger-zone .profile-meta--block {
    margin-bottom: 8px;
    line-height: 1.35;
    font-size: var(--text-sm);
}

.account-drawer-sub-card {
    border: 1px solid var(--border-accent);
    border-radius: 16px;
    padding: 18px 16px 16px;
    margin-bottom: 18px;
    background: rgba(255, 255, 255, 0.03);
}

.account-drawer-sub-card__tariff {
    font-size: 1.75rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    line-height: 1.15;
    margin: 0 0 14px;
    color: var(--text-heading);
}

.account-drawer-sub-card__row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    font-size: var(--text-sm);
    margin-bottom: 8px;
}

.account-drawer-sub-card__row--date {
    margin-bottom: 12px;
}

.account-drawer-sub-card__label {
    color: var(--muted);
}

.account-drawer-sub-card__status--ok {
    color: #4ade80;
    font-weight: 600;
}

.account-drawer-sub-card__status--off {
    color: var(--muted);
    font-weight: 600;
}

.account-drawer-sub-card__date {
    color: var(--brand-red);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.account-drawer-sub-card__traffic-label {
    font-size: 12px;
    color: var(--muted);
    margin-bottom: 8px;
}

.account-drawer-sub-card__traffic-label strong {
    color: var(--text-label);
    font-weight: 600;
}

.account-drawer-traffic-bar {
    height: 10px;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.08);
}

.account-drawer-traffic-bar--unlimited {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    background: linear-gradient(90deg, rgba(211, 26, 36, 0.35), rgba(211, 26, 36, 0.12));
    border: 1px solid rgba(211, 26, 36, 0.35);
}

.account-drawer-traffic-bar__infinity {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1;
    color: rgba(255, 255, 255, 0.92);
}

.account-drawer-traffic-bar--limited {
    position: relative;
}

.account-drawer-traffic-bar__fill {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--brand-red), #ff6b6b);
    min-width: 4px;
    transition: width 0.35s ease;
}

.device-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.device-row:last-child {
    border-bottom: 0;
}

.device-row__main {
    min-width: 0;
}

.device-row__name {
    font-size: var(--text-sm);
    color: var(--text-heading);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.device-row__activity {
    margin-top: 2px;
    font-size: 12px;
    color: var(--muted);
}

.device-row__delete-form {
    margin: 0;
    flex-shrink: 0;
}

.device-row__delete {
    border: 0;
    background: transparent;
    color: #ff5c6f;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    padding: 0 2px;
}

.device-row__delete:hover {
    color: #ff8693;
}

.grid {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(3, 1fr);
    margin-bottom: 28px;
}

.tile {
    border: 1px solid var(--border-accent);
    border-radius: 16px;
    padding: 20px;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.tile h3 {
    margin: 0 0 8px;
    font-size: 16px;
}

.tile p {
    margin: 0;
    color: var(--muted);
    font-size: var(--text-md);
}

.pricing-section {
    margin-bottom: 28px;
}

.tariff-period-toggle {
    display: inline-flex;
    align-items: stretch;
    gap: 4px;
    margin: 0 auto 22px;
    padding: 4px;
    border: 1px solid var(--border-accent);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.pricing-section .tariff-period-toggle {
    display: flex;
    width: fit-content;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
}

.tariff-period-toggle__btn {
    flex: 1 1 auto;
    min-width: 0;
    padding: 10px 18px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--muted);
    font: inherit;
    font-size: var(--text-sm);
    font-weight: 600;
    line-height: 1.3;
    text-align: center;
    cursor: pointer;
    transition: color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.tariff-period-toggle__btn:hover {
    color: var(--text);
}

.tariff-period-toggle__btn.is-active {
    color: var(--text-heading);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
}

.tariff-period-toggle__btn:focus-visible {
    outline: 2px solid var(--brand-red);
    outline-offset: 2px;
}

.pricing {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;
    margin-bottom: 0;
}

.plan {
    position: relative;
    z-index: 0;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 100%;
    border: 1px solid var(--border-accent);
    border-radius: 16px;
    padding: 22px 20px 18px;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
    transition:
        border-color 0.22s ease,
        box-shadow 0.22s ease;
    overflow: visible;
}

.plan:hover,
.plan:focus-within {
    z-index: 5;
    border-color: rgba(211, 26, 36, 0.55);
    box-shadow:
        0 18px 52px rgba(0, 0, 0, 0.38),
        0 0 0 1px rgba(211, 26, 36, 0.08);
}

.plan__grow {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.plan__cta {
    flex-shrink: 0;
    width: 100%;
    padding-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.plan h3 {
    flex-shrink: 0;
    margin: 0 0 10px;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.35;
}

.plan-price-stack {
    flex-shrink: 0;
    margin-bottom: 10px;
}

.plan-price-panel.is-hidden,
.plan-price-panel[hidden] {
    display: none !important;
}

.profile-renew-billing {
    margin-bottom: 12px;
}

.profile-renew-billing .tariff-period-toggle {
    display: flex;
    width: 100%;
    margin-bottom: 10px;
}

.profile-renew-billing__prices {
    margin-bottom: 10px;
}

.profile-renew-billing__price-panel {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.profile-renew-billing__price-panel[hidden],
.profile-renew-billing__price-panel.is-hidden {
    display: none !important;
}

.profile-renew-billing__price {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-heading);
}

.profile-renew-billing__hint {
    font-size: 11px;
    color: var(--muted);
}

.renew-page {
    display: flex;
    justify-content: center;
    padding: 48px 16px 64px;
    min-height: 60vh;
}

.renew-page__card {
    width: min(100%, 440px);
    padding: 28px 24px 24px;
    border: 1px solid var(--border-accent);
    border-radius: 16px;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
}

.renew-page__title {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--text-heading);
    text-align: center;
}

.renew-page__intro {
    margin: 0 0 20px;
    font-size: var(--text-md);
    line-height: 1.5;
    color: var(--muted);
    text-align: center;
}

.renew-page__error {
    margin: 0 0 14px;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid rgba(220, 38, 38, 0.35);
    background: rgba(220, 38, 38, 0.08);
    color: #fca5a5;
    font-size: var(--text-sm);
}

.renew-page__tariff-label {
    margin: 0 0 4px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
}

.renew-page__tariff-name {
    margin: 0 0 18px;
    font-size: 18px;
    font-weight: 700;
    color: var(--text-heading);
}

.renew-page__billing .tariff-period-toggle {
    display: flex;
    width: 100%;
    margin-bottom: 14px;
}

.renew-page__price-stack {
    margin-bottom: 16px;
}

.renew-page__price-panel[hidden],
.renew-page__price-panel.is-hidden {
    display: none !important;
}

.renew-page__price-hint {
    margin: 0 0 4px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
}

.renew-page__price-value {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: var(--text-heading);
}

.renew-page__price-note {
    margin: 4px 0 0;
    font-size: 12px;
    color: var(--muted);
}

.renew-page__form {
    margin-top: 4px;
}

.renew-page__foot {
    margin: 16px 0 0;
    text-align: center;
    font-size: var(--text-sm);
}

.renew-page__foot a {
    color: var(--muted);
}

.renew-page__foot a:hover {
    color: var(--text);
}

.plan-price-primary {
    flex-shrink: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.plan-price-primary__hint {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
}

.plan-price-three-month {
    margin: 0;
    font-size: var(--text-md);
    line-height: 1.45;
}

.plan-price-three-month__total {
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px;
}

.plan-price-three-month__label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
    width: 100%;
}

.plan-price-three-month__value {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-heading);
}

.plan-price-three-month__badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    color: #fff;
    background: var(--accent, #3d6ee8);
}

.plan-price-three-month__note {
    margin: 4px 0 0;
    font-size: 12px;
    color: var(--muted);
}

.plan-billing-period {
    margin: 0 0 10px;
    padding: 0;
    border: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.plan-billing-period__legend {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
    margin-bottom: 2px;
}

.plan-billing-period__option {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: var(--text-sm);
    cursor: pointer;
}

.plan-price-secondary-hint {
    margin: 0 0 6px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
}

.plan-crypto-block {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin-top: 8px;
    max-width: 100%;
}

.plan-crypto-block__trigger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 2px 0;
    cursor: help;
}

.plan-crypto-block__label {
    margin: 0;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--muted);
    transition: color 0.15s ease;
}

.plan-crypto-block:hover .plan-crypto-block__label,
.plan-crypto-block:focus-within .plan-crypto-block__label {
    color: var(--text);
}

.plan-crypto-tooltip {
    min-width: 240px;
    max-width: min(320px, 92vw);
}

@media (min-width: 981px) {
    .pricing .plan:nth-child(3n) .plan-crypto-tooltip {
        left: auto;
        right: 0;
    }
}

.plan-prices-footer .plan-crypto-block:last-child {
    margin-bottom: 2px;
}

.plan-price-primary__value {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-heading);
    font-variant-numeric: tabular-nums;
}

.plan-prices-footer {
    flex-shrink: 0;
    margin-top: auto;
    padding-top: 12px;
}

.tariff-price-value__note {
    display: block;
    font-size: 11px;
    color: var(--muted);
    font-weight: 400;
}

.tariff-price-row--primary .tariff-price-value {
    font-weight: 600;
    color: var(--text-heading);
}

/* Описание тарифа: спокойный «текстовый» ритм, отличается от блока цен */
.plan-desc {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-height: 0;
    padding-top: 2px;
}

.plan-desc:empty {
    display: none;
}

.plan-tagline,
.plan-features {
    font-family: var(--font-family);
    font-weight: 400;
    letter-spacing: 0.02em;
    color: var(--muted);
}

.plan-tagline {
    margin: 0;
    font-size: var(--text-sm);
    line-height: 1.55;
}

.plan-features {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 11px;
}

.plan-feature {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.plan-feature__icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    margin-top: 1px;
    color: rgba(255, 255, 255, 0.7);
    opacity: 0.68;
    filter:
        drop-shadow(0 0 4px rgba(211, 26, 36, 0.38))
        drop-shadow(0 0 10px rgba(211, 26, 36, 0.14));
    transition:
        opacity 0.22s ease,
        color 0.22s ease,
        filter 0.22s ease;
}

.plan-feature__check {
    display: block;
    width: 14px;
    height: 14px;
}

.plan:hover .plan-feature__icon {
    opacity: 1;
    color: #ffffff;
    filter:
        drop-shadow(0 0 8px rgba(211, 26, 36, 0.68))
        drop-shadow(0 0 16px rgba(211, 26, 36, 0.28));
}

@media (prefers-reduced-motion: reduce) {
    .plan,
    .plan-feature__icon {
        transition: none;
    }
}

.plan-feature__body {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px 8px;
}

.plan-feature__text {
    font-size: var(--text-sm);
    line-height: 1.6;
    color: var(--muted);
}

.plan-feature__text strong {
    font-weight: 600;
    color: var(--text-label);
}

.plan-feature__badge {
    position: relative;
    isolation: isolate;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px 8px;
    border-radius: 5px;
    background: rgba(11, 14, 20, 0.96);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.1em;
    line-height: 1.2;
    color: var(--text-heading);
    text-transform: uppercase;
    box-shadow: 0 0 12px rgba(211, 26, 36, 0.18);
}

.plan-feature__badge::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, #ff4d57 0%, rgba(255, 255, 255, 0.72) 52%, #d31a24 100%);
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
}

.plan-feature__badge--new::before {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.82) 0%, #ff4d57 55%, rgba(255, 255, 255, 0.45) 100%);
}

.plan-feature__badge--unlimited {
    letter-spacing: 0.04em;
    font-size: 11px;
    padding: 1px 8px;
    color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 0 14px rgba(211, 26, 36, 0.28);
}

.plan-feature__badge--unlimited::before {
    background: linear-gradient(
        135deg,
        #ff4d57 0%,
        rgba(255, 255, 255, 0.78) 38%,
        #ffffff 50%,
        rgba(255, 255, 255, 0.78) 62%,
        #d31a24 100%
    );
}

.plan-features .plan-feature-hint-wrap {
    display: inline-flex;
    vertical-align: middle;
    margin-left: 4px;
    position: relative;
}

.plan-feature-hint-tooltip {
    z-index: 50;
    min-width: 200px;
    max-width: min(280px, 88vw);
    text-align: left;
    line-height: 1.45;
}

@media (min-width: 981px) {
    /* Соло (1-я колонка): тултип раскрывается влево, не под соседнюю карточку */
    .pricing .plan:first-child .plan-feature-hint-tooltip {
        left: auto;
        right: 0;
    }

    .pricing .plan:nth-child(3n) .plan-feature-hint-tooltip {
        left: auto;
        right: 0;
    }
}

.plan .plan-prices-footer ul.tariff-prices {
    padding-left: 0;
}

.plan-prices-footer .tariff-price-value {
    white-space: normal;
    text-align: right;
}

.pricing .plan .form-stack,
.pricing .plan .plan__cta .form-stack {
    width: 100%;
    flex-shrink: 0;
    align-self: stretch;
}

.faq {
    display: grid;
    gap: 10px;
    margin-bottom: 28px;
}

.faq-item {
    border: 1px solid var(--border-accent);
    border-radius: 14px;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    overflow: hidden;
    transition:
        border-color 0.22s ease,
        box-shadow 0.22s ease;
}

.faq-item:hover {
    border-color: rgba(211, 26, 36, 0.4);
}

.faq-item[open] {
    border-color: rgba(211, 26, 36, 0.5);
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.22);
}

.faq-item__summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 16px 18px;
    cursor: pointer;
    list-style: none;
    user-select: none;
}

.faq-item__summary::-webkit-details-marker {
    display: none;
}

.faq-item__summary::marker {
    content: '';
}

.faq-item__question {
    flex: 1 1 auto;
    min-width: 0;
    font-weight: 600;
    font-size: var(--text-md);
    line-height: 1.45;
    color: var(--text-heading);
}

.faq-item__chevron {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.04);
    color: var(--muted);
    transition:
        transform 0.3s ease,
        color 0.3s ease,
        border-color 0.3s ease,
        background-color 0.3s ease;
}

.faq-item__chevron-icon {
    display: block;
    width: 16px;
    height: 16px;
}

.faq-item[open] .faq-item__chevron {
    transform: rotate(180deg);
    color: var(--text-heading);
    border-color: var(--red-mid);
    background: var(--ui-hover-soft);
}

.faq-item__panel {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.3s ease;
}

.faq-item[open] .faq-item__panel {
    grid-template-rows: 1fr;
}

.faq-item__panel-inner {
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.faq-item[open] .faq-item__panel-inner {
    opacity: 1;
}

.faq-item__answer {
    margin: 0;
    padding: 0 18px 16px;
    color: var(--muted);
    font-size: var(--text-md);
    line-height: 1.6;
}

.faq-item__answer strong {
    font-weight: 600;
    color: var(--text-label);
}

.faq-item__summary:focus-visible {
    outline: 2px solid var(--brand-red);
    outline-offset: -2px;
    border-radius: 14px;
}

@media (prefers-reduced-motion: reduce) {
    .faq-item,
    .faq-item__chevron,
    .faq-item__panel,
    .faq-item__panel-inner {
        transition: none;
    }
}

.countries-section {
    margin-bottom: 22px;
}

.countries-section .section-title {
    text-align: center;
}

.section-lead {
    margin: -8px auto 18px;
    color: var(--muted);
    font-size: var(--text-md);
    line-height: 1.5;
    max-width: 640px;
}

.section-lead--center {
    text-align: center;
}

.locations-table-wrap {
    overflow-x: auto;
    width: 100%;
    border: 1px solid var(--border-accent);
    border-radius: 16px;
    background: var(--bg);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
}

.locations-table {
    width: 100%;
    border-collapse: collapse;
    font-size: var(--text-md);
    border: 0;
    border-radius: 0;
    overflow: hidden;
    background: var(--bg);
}

.locations-table th,
.locations-table td {
    padding: 12px 14px;
    text-align: left;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}

.locations-table tbody tr:last-child td {
    border-bottom: 0;
}

.locations-table th {
    background: #131821;
    color: var(--text);
    font-weight: 600;
}

.locations-table tbody td {
    background: var(--bg);
}

.locations-table td:first-child {
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
}

.locations-table td:last-child {
    color: var(--muted);
}

.tariff-prices {
    margin: 0;
    padding: 12px 0 0;
    list-style: none;
    font-size: var(--text-md);
    border-top: 1px solid var(--border);
    font-family: var(--font-family);
    font-variant-numeric: tabular-nums;
}

.tariff-prices li {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    padding: 6px 0;
    border-top: 1px solid var(--border);
}

.tariff-prices li:first-child {
    border-top: 0;
    padding-top: 0;
}

.tariff-price-label {
    color: var(--muted);
    flex-shrink: 0;
    font-size: 12px;
    font-weight: 500;
    font-family: var(--font-family);
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.tariff-price-value {
    color: var(--brand-red);
    font-weight: 600;
    font-size: var(--text-md);
    text-align: right;
    white-space: nowrap;
}

.tariff-price-row--crypto .tariff-price-label--crypto {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-transform: none;
    letter-spacing: normal;
    font-weight: 600;
    color: var(--text);
}

.crypto-hint-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.crypto-hint-btn {
    width: 18px;
    height: 18px;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    cursor: help;
    flex-shrink: 0;
}

.crypto-hint-btn:hover,
.crypto-hint-btn:focus-visible {
    color: var(--brand-red);
    border-color: var(--red-mid);
    outline: none;
}

.crypto-hint-tooltip {
    display: none;
    position: absolute;
    z-index: 40;
    left: 0;
    bottom: calc(100% + 8px);
    min-width: 220px;
    max-width: min(320px, 92vw);
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: var(--surface, #1a1d26);
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
    font-size: 12px;
    font-weight: 400;
    font-family: var(--font-family);
    text-transform: none;
    letter-spacing: normal;
    color: var(--text);
}

.crypto-hint-tooltip-title {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text);
}

.crypto-hint-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.crypto-hint-list li.crypto-hint-row {
    display: grid;
    grid-template-columns: 24px 1fr auto;
    align-items: center;
    gap: 8px 10px;
    padding: 6px 0;
    border-top: 1px solid var(--border);
    font-variant-numeric: tabular-nums;
}

.crypto-hint-list li.crypto-hint-row:first-child {
    border-top: 0;
    padding-top: 0;
}

.crypto-hint-icon {
    width: 22px;
    height: 22px;
    object-fit: contain;
    display: block;
}

.crypto-hint-icon-spacer {
    width: 22px;
    height: 22px;
    display: block;
}

.crypto-hint-name {
    font-family: var(--font-family);
    font-size: 12px;
    color: var(--text);
    min-width: 0;
}

.crypto-hint-row .crypto-hint-amt {
    font-family: var(--font-family);
    font-size: 12px;
    color: var(--brand-red);
    font-weight: 600;
    white-space: nowrap;
}

.crypto-hint-foot {
    margin: 8px 0 0;
    padding-top: 8px;
    border-top: 1px solid var(--border);
    font-size: 11px;
    color: var(--muted);
    line-height: 1.35;
}

.crypto-hint-foot--fee {
    margin-top: 6px;
    padding-top: 0;
    border-top: 0;
}

.crypto-hint-wrap:hover .crypto-hint-tooltip,
.crypto-hint-wrap:focus-within .crypto-hint-tooltip {
    display: block;
}

@media (hover: none) {
    .crypto-hint-tooltip {
        left: auto;
        right: 0;
    }
}

/* --- Nodes map (Leaflet) --- */
.nodes-map-section {
    margin-bottom: 28px;
}

.nodes-map-section .section-title {
    text-align: center;
    margin-bottom: 14px;
}

.veloxi-nodes-map {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    height: min(420px, 62vh);
    min-height: 280px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border);
    background: #0d1118;
    z-index: 1;
    position: relative;
}

.veloxi-nodes-map .leaflet-container {
    font-family: var(--font-sans);
    background: #0d1118;
    color: var(--text);
}

.veloxi-nodes-map .leaflet-bar a {
    background: rgba(13, 17, 24, 0.92);
    color: var(--text);
    border-color: var(--border);
}

.veloxi-nodes-map .leaflet-bar a:hover {
    background: var(--ui-hover-soft);
    border-color: var(--border-accent);
    color: var(--accent-hover);
}

.veloxi-map-marker-wrap {
    background: transparent !important;
    border: none !important;
}

.veloxi-map-marker-pulse {
    display: block;
    width: 14px;
    height: 14px;
    margin: 7px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #ff5c66, #d31a24 45%, #7a0f15 100%);
    box-shadow:
        0 0 0 0 rgba(211, 26, 36, 0.55),
        0 0 12px 2px rgba(255, 60, 80, 0.45),
        0 0 22px 4px rgba(211, 26, 36, 0.25);
    animation: veloxi-map-pulse 2s ease-out infinite;
}

.veloxi-map-marker-pulse--static {
    animation: none;
    box-shadow:
        0 0 10px 2px rgba(255, 60, 80, 0.4),
        0 0 18px 3px rgba(211, 26, 36, 0.2);
}

@keyframes veloxi-map-pulse {
    0% {
        box-shadow:
            0 0 0 0 rgba(211, 26, 36, 0.5),
            0 0 12px 2px rgba(255, 60, 80, 0.45),
            0 0 22px 4px rgba(211, 26, 36, 0.25);
        transform: scale(1);
    }
    55% {
        box-shadow:
            0 0 0 10px rgba(211, 26, 36, 0),
            0 0 16px 3px rgba(255, 60, 80, 0.35),
            0 0 28px 6px rgba(211, 26, 36, 0.12);
        transform: scale(1.05);
    }
    100% {
        box-shadow:
            0 0 0 0 rgba(211, 26, 36, 0),
            0 0 12px 2px rgba(255, 60, 80, 0.45),
            0 0 22px 4px rgba(211, 26, 36, 0.25);
        transform: scale(1);
    }
}

@media (prefers-reduced-motion: reduce) {
    .veloxi-map-marker-pulse {
        animation: none;
        box-shadow:
            0 0 10px 2px rgba(255, 60, 80, 0.4),
            0 0 18px 3px rgba(211, 26, 36, 0.2);
    }
}

.veloxi-map-tooltip {
    background: rgba(11, 14, 20, 0.95) !important;
    border: 1px solid var(--border-accent) !important;
    border-radius: 8px !important;
    color: var(--text) !important;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45) !important;
    padding: 0 !important;
}

.veloxi-map-tooltip::before {
    border-top-color: rgba(11, 14, 20, 0.95) !important;
}

.veloxi-map-tooltip-inner {
    padding: 10px 12px;
    font-size: 12px;
    line-height: 1.45;
    min-width: 140px;
}

.veloxi-map-tooltip__title {
    font-family: var(--font-mono-display);
    font-weight: 600;
    font-size: var(--text-sm);
    color: var(--text-heading);
    margin-bottom: 8px;
    letter-spacing: 0.04em;
}

.veloxi-map-tooltip__row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 4px;
    color: var(--text-label);
}

.veloxi-map-tooltip__row strong {
    color: var(--text-heading);
    font-weight: 600;
}

.veloxi-map-tooltip__err {
    color: var(--danger);
    font-size: 11px;
    margin-top: 4px;
}

/* Карта — от 768px; полоса «Скорость узлов» — до 767px */
@media (max-width: 767px) {
    .nodes-map-section {
        display: none !important;
    }
}

@media (min-width: 768px) {
    .speed-section--strip > .section-title,
    .speed-section--strip > .speed-strip,
    .speed-section--strip > .speed-strip-empty {
        display: none !important;
    }

    .speed-section--strip .speed-ping-disclaimer {
        margin-top: 8px;
    }
}

.speed-section {
    margin-bottom: 22px;
}

.speed-ping-disclaimer {
    margin: 12px auto 0;
    max-width: 720px;
    padding: 0 6px;
    text-align: center;
    font-size: 11px;
    line-height: 1.45;
    color: var(--muted);
}

.speed-section .section-title {
    text-align: center;
}

.speed-section--strip {
    margin-bottom: 18px;
}

.speed-section--strip .section-title {
    font-size: 18px;
    margin-bottom: 12px;
}

.speed-strip {
    position: relative;
    margin: 0 -8px;
    padding: 0 8px;
}

.speed-strip__viewport {
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 4px;
    outline: none;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
}

.speed-strip__viewport.speed-strip__viewport--dragging {
    cursor: grabbing;
    scroll-snap-type: none;
    scroll-behavior: auto;
}

.speed-strip__viewport::-webkit-scrollbar {
    display: none;
    width: 0;
    height: 0;
}

.speed-strip__viewport:focus-visible {
    box-shadow: 0 0 0 2px var(--ui-hover-ring);
    border-radius: 12px;
}

.speed-strip__track {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 10px;
    width: max-content;
    padding: 2px 0;
}

.speed-strip__chunk {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: flex-start;
    gap: 10px;
}

.speed-strip__card {
    flex: 0 0 auto;
    scroll-snap-align: start;
    width: 170px;
    min-width: 170px;
    max-width: 170px;
}

.speed-strip__card-inner {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    border: 1px solid rgba(211, 26, 36, 0.25);
    border-radius: 14px;
    padding: 8px 12px 9px;
    background: rgba(11, 14, 20, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-sizing: border-box;
    gap: 0;
}

.speed-strip__head {
    flex: 0 0 auto;
    margin: 0;
    padding: 0;
}

.speed-strip__head-row {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 6px;
    min-width: 0;
}

.speed-strip__code {
    margin-top: 0;
    padding-top: 1px;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--muted);
    font-family: var(--font-family);
    line-height: 1.15;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.speed-strip__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
}

.speed-strip__dot--ok {
    background: #34d399;
    box-shadow: 0 0 10px rgba(52, 211, 153, 0.85);
}

.speed-strip__dot--warn {
    background: #fbbf24;
    box-shadow: 0 0 8px rgba(251, 191, 36, 0.65);
}

.speed-strip__dot--bad {
    background: #f87171;
    box-shadow: 0 0 8px rgba(248, 113, 113, 0.55);
}

.speed-strip__flag {
    font-size: 16px;
    line-height: 1;
    flex-shrink: 0;
}

.speed-strip__name {
    font-size: var(--text-md);
    font-weight: 700;
    letter-spacing: 0.01em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.speed-strip__metrics {
    margin-top: 2px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 0;
    border: 0;
}

.speed-strip__metric {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    font-size: 10px;
    line-height: 1.2;
    color: var(--muted);
}

.speed-strip__metric-ico {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    opacity: 0.95;
}

.speed-strip__svg {
    display: block;
    width: 15px;
    height: 15px;
}

.speed-strip__metric:nth-child(1) .speed-strip__metric-ico {
    color: var(--ui-hover);
}

.speed-strip__metric:nth-child(2) .speed-strip__metric-ico {
    color: #7ec8a4;
}

.speed-strip__metric:nth-child(3) .speed-strip__metric-ico {
    color: #e6c86c;
}

.speed-strip__metric-nums {
    font-variant-numeric: tabular-nums;
    text-align: right;
    min-width: 0;
}

.speed-strip__metric-val {
    font-weight: 600;
    color: var(--text-label);
}

.speed-strip-empty {
    text-align: center;
    color: var(--muted);
    font-size: var(--text-md);
    margin: 0 0 8px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

footer {
    color: var(--muted);
    font-size: var(--text-sm);
    padding: 22px 0 36px;
    text-align: center;
}

.site-footer__legal {
    margin-top: 8px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 4px 6px;
}

.site-footer__legal--contact {
    margin-top: 8px;
}

.site-footer__privacy-link,
.site-footer__legal-link {
    font-size: 10px;
    line-height: 1.35;
    color: var(--muted);
    text-decoration: none;
    opacity: 0.88;
}

.site-footer__privacy-link:hover,
.site-footer__legal-link:hover {
    color: var(--ui-hover);
    opacity: 1;
}

.site-footer__legal-sep {
    font-size: 10px;
    color: var(--muted);
    opacity: 0.55;
    user-select: none;
}

body.privacy-page,
body.terms-page {
    overflow: hidden;
    min-height: 100vh;
    min-height: 100dvh;
}

body.privacy-page #privacy-modal.modal-backdrop,
body.terms-page #terms-modal.modal-backdrop {
    z-index: 400;
    padding:
        max(10px, env(safe-area-inset-top, 0px))
        max(14px, env(safe-area-inset-right, 0px))
        max(10px, env(safe-area-inset-bottom, 0px))
        max(14px, env(safe-area-inset-left, 0px));
}

.modal-panel--privacy {
    max-width: min(680px, 94vw);
    width: 100%;
    max-height: min(88vh, 900px);
    padding: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.privacy-modal__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 20px 22px 16px;
    border-bottom: 1px solid var(--border-accent);
    flex-shrink: 0;
    background: rgba(11, 14, 20, 0.95);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
}

.privacy-modal__title {
    margin: 0;
    font-size: clamp(15px, 3.6vw, 20px);
    font-weight: 600;
    font-family: var(--font-mono-display);
    letter-spacing: 0.03em;
    line-height: 1.3;
    color: var(--text-heading);
}

.privacy-modal__close-x.modal-close {
    position: relative;
    top: auto;
    right: auto;
    flex-shrink: 0;
    margin: -4px -6px 0 0;
    padding: 6px 10px;
}

.privacy-modal__body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 16px 20px 8px;
}

.privacy-modal__actions {
    flex-shrink: 0;
    padding: 14px 22px max(20px, calc(14px + env(safe-area-inset-bottom, 0px)));
    border-top: 1px solid var(--border-accent);
    background: rgba(0, 0, 0, 0.35);
}

.privacy-modal__close-btn {
    width: 100%;
}

.privacy-prose {
    font-size: var(--text-sm);
    line-height: 1.55;
    color: var(--muted);
}

.privacy-prose__h {
    margin: 1.15rem 0 0.45rem;
    font-size: var(--text-md);
    font-weight: 600;
    font-family: var(--font-mono-display);
    color: var(--text-heading);
}

.privacy-prose__h:first-child {
    margin-top: 0;
}

.privacy-prose p {
    margin: 0 0 0.65rem;
}

.privacy-prose ul {
    margin: 0 0 0.75rem;
    padding-left: 1.15em;
}

.privacy-prose li {
    margin-bottom: 0.35rem;
}

.privacy-prose__a {
    color: var(--ui-hover);
    text-decoration: none;
    word-break: break-all;
}

.privacy-prose__a:hover {
    text-decoration: underline;
    color: var(--text-heading);
}

.privacy-prose__updated {
    font-size: 12px;
    color: var(--muted);
    margin-bottom: 1rem !important;
    opacity: 0.92;
}

.privacy-prose__url-line {
    margin-top: 1rem;
    margin-bottom: 0 !important;
    font-size: 12px;
    line-height: 1.45;
    color: var(--muted);
}

.site-footer-privacy {
    color: var(--muted);
    font-size: var(--text-sm);
    padding: 14px 0 28px;
    text-align: center;
}

.site-footer-privacy__link {
    font-size: 10px;
    line-height: 1.35;
    color: var(--muted);
    text-decoration: none;
    opacity: 0.88;
}

.site-footer-privacy__link:hover {
    color: var(--ui-hover);
    opacity: 1;
}

.site-footer-privacy__link-wrap {
    margin: 8px 0 0;
}

.site-footer-privacy__link-wrap--row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 4px 6px;
}

.site-footer-privacy__sep {
    font-size: 10px;
    color: var(--muted);
    opacity: 0.55;
    user-select: none;
}

.site-footer-privacy__copy {
    margin: 0;
}

@media (max-width: 980px) {
    .grid,
    .pricing {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 640px) {
    .tariff-period-toggle {
        flex-direction: column;
        width: 100%;
        border-radius: 14px;
    }

    .tariff-period-toggle__btn {
        border-radius: 10px;
    }
}

@media (max-width: 520px) {
    .locations-table td:first-child {
        white-space: normal;
    }
}

/* Toast notifications (flash messages) */
.toast-stack {
    position: fixed;
    z-index: 250;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
    max-width: min(400px, calc(100vw - 24px));
}

.toast-stack .toast {
    pointer-events: auto;
}

.toast {
    position: relative;
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 14px 40px 14px 16px;
    border-radius: 14px;
    font-size: var(--text-sm);
    line-height: 1.45;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
    border: 1px solid var(--border-accent);
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    color: var(--text);
    animation: toast-in 0.35s ease-out both;
}

.toast--out {
    animation: toast-out 0.28s ease-in forwards;
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateY(8px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes toast-out {
    to {
        opacity: 0;
        transform: translateY(6px);
    }
}

.toast-body {
    flex: 1;
    min-width: 0;
    word-break: break-word;
}

.toast-dismiss {
    position: absolute;
    top: 6px;
    right: 8px;
    width: 28px;
    height: 28px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    color: var(--muted);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toast-dismiss:hover {
    background: rgba(255, 255, 255, 0.12);
    color: var(--text);
}

.toast--success {
    border-color: rgba(82, 211, 138, 0.45);
    background: rgba(12, 42, 28, 0.96);
}

.toast--success .toast-body {
    color: #b8f0d0;
}

.toast--error {
    border-color: rgba(255, 107, 107, 0.45);
    background: rgba(48, 18, 22, 0.96);
}

.toast--error .toast-body {
    color: #ffc4c4;
}

.toast--info {
    border-color: var(--ui-hover-mid);
    background: rgba(11, 14, 20, 0.92);
}

.toast--info .toast-body {
    color: var(--text-label);
}

/* Desktop: bottom-right stack */
@media (min-width: 769px) {
    .toast-stack {
        right: 24px;
        bottom: 24px;
        top: auto;
        left: auto;
        align-items: flex-end;
    }
}

/* Mobile: full-width strip under nav — avoids thumb zone and cookie bar at bottom */
@media (max-width: 768px) {
    .toast-stack {
        left: max(12px, env(safe-area-inset-left));
        right: max(12px, env(safe-area-inset-right));
        top: calc(64px + env(safe-area-inset-top, 0px));
        bottom: auto;
        max-width: none;
        align-items: stretch;
    }
}

/* Cookie consent */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 300;
    padding: 18px 20px;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border-top: 1px solid var(--border-accent);
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 14px 18px;
}

.cookie-banner.is-hidden {
    display: none;
}

.cookie-banner p {
    margin: 0;
    max-width: 640px;
    font-size: var(--text-sm);
    color: var(--text-label);
    line-height: 1.45;
    text-align: center;
}

.cookie-banner .btn-cookie {
    width: auto;
    padding: 8px 18px;
    font-size: var(--text-sm);
    flex-shrink: 0;
}

/* Scroll to top (left); body > * sets position:relative — override for fixed */
body > .veloxi-scroll-top {
    position: fixed;
    z-index: 280;
    left: max(14px, env(safe-area-inset-left, 0px));
    bottom: calc(22px + env(safe-area-inset-bottom, 0px));
    width: 48px;
    height: 48px;
    padding: 0;
    margin: 0;
    border: 1px solid var(--border-accent);
    border-radius: 14px;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    color: var(--text-heading);
    cursor: pointer;
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease,
        background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

body > .veloxi-scroll-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

body > .veloxi-scroll-top:hover {
    border-color: var(--ui-hover-mid);
    color: var(--accent-hover);
}

body > .veloxi-scroll-top:active {
    transform: translateY(1px);
}

body > .veloxi-scroll-top.is-visible:active {
    transform: translateY(1px);
}

body > .veloxi-scroll-top:focus {
    outline: none;
}

body > .veloxi-scroll-top:focus-visible {
    outline: 2px solid var(--ui-hover-ring);
    outline-offset: 3px;
}

/* Above cookie strip when consent banner is open */
body.veloxi-cookie-bar-visible > .veloxi-scroll-top {
    bottom: calc(76px + env(safe-area-inset-bottom, 0px));
}

@media (max-width: 768px) {
    body > .veloxi-scroll-top {
        left: max(12px, env(safe-area-inset-left, 0px));
        bottom: calc(18px + env(safe-area-inset-bottom, 0px));
        width: 52px;
        height: 52px;
        border-radius: 16px;
    }

    body.veloxi-cookie-bar-visible > .veloxi-scroll-top {
        bottom: calc(112px + env(safe-area-inset-bottom, 0px));
    }
}

@media (prefers-reduced-motion: reduce) {
    body > .veloxi-scroll-top {
        transition: none;
    }
}

.veloxi-swal-popup {
    background: var(--glass-bg) !important;
    backdrop-filter: blur(var(--glass-blur)) !important;
    -webkit-backdrop-filter: blur(var(--glass-blur)) !important;
    border: 1px solid var(--border-accent) !important;
    border-radius: 18px !important;
    color: var(--text-heading) !important;
    box-shadow: 0 24px 72px rgba(0, 0, 0, 0.5) !important;
    font-family: var(--font-family) !important;
}

.veloxi-swal-title {
    color: var(--text-heading) !important;
    font-family: var(--font-mono-display) !important;
    font-size: 22px !important;
    letter-spacing: 0.03em !important;
}

.veloxi-swal-text {
    color: var(--text-label) !important;
    font-size: var(--text-md) !important;
    line-height: 1.5 !important;
}

.veloxi-swal-popup .swal2-actions {
    display: flex !important;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 14px 18px;
    width: 100%;
    max-width: 100%;
    margin: 1.5em auto 0.35em !important;
    padding: 0 0.5rem;
    box-sizing: border-box;
}

.veloxi-swal-popup .swal2-actions .swal2-styled {
    margin: 0 !important;
}

.veloxi-swal-btn {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 10px 16px;
    font-weight: 600;
    font-size: var(--text-md);
    cursor: pointer;
    transition: all 0.18s ease;
}

.veloxi-swal-btn--danger {
    background: transparent;
    border-color: var(--danger);
    color: var(--danger);
}

.veloxi-swal-btn--danger:hover {
    background: var(--danger) !important;
    color: #fff !important;
    box-shadow: 0 0 28px rgba(255, 255, 255, 0.15), 0 0 40px rgba(255, 107, 107, 0.35) !important;
    filter: none;
}

.veloxi-swal-btn--ghost {
    background: transparent;
    color: var(--text-label);
    border-color: var(--border);
}

.veloxi-swal-btn--ghost:hover {
    background: var(--ui-hover-soft);
    border-color: var(--ui-hover-mid);
    color: var(--ui-hover);
}

.veloxi-swal-btn--accent {
    background: transparent;
    border-color: var(--brand-red);
    color: #fff;
}

.veloxi-swal-btn--accent:hover {
    background: var(--brand-red) !important;
    color: #fff !important;
    box-shadow:
        0 0 28px rgba(255, 255, 255, 0.2),
        0 0 48px rgba(211, 26, 36, 0.35) !important;
    filter: none;
}

.veloxi-swal-popup .swal2-icon.swal2-info {
    border-color: var(--ui-hover-mid) !important;
    color: var(--ui-hover) !important;
}

/* Registration page */
.page-registration .container-narrow {
    width: min(480px, 92vw);
    margin: 0 auto;
    padding: 32px 0;
}

.page-registration .back {
    margin-bottom: 20px;
}

.page-registration .back a {
    color: var(--ui-hover);
    text-decoration: none;
    font-size: var(--text-md);
}

.page-registration .back a:hover {
    color: var(--text-heading);
    text-shadow: 0 0 12px rgba(0, 242, 255, 0.35);
}

.page-registration .form-stack > .btn {
    margin-top: 18px;
}

.page-registration .form-stack .email-auth-flow__terms {
    margin-top: 10px;
}

/* Support tickets */
.support-page {
    width: min(720px, 92vw);
    margin: 0 auto;
    padding: 32px 16px 64px;
}

.support-page__head {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 48px;
    margin-bottom: 24px;
    padding: 0 2px;
}

.support-page__back {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin: 0;
    border-radius: 10px;
    color: var(--accent);
    text-decoration: none;
    font-size: 24px;
    line-height: 1;
    transition:
        background 0.15s,
        color 0.15s;
    z-index: 1;
}

.support-page__back:hover {
    background: var(--ui-hover-soft);
    color: var(--ui-hover);
    box-shadow: 0 0 14px rgba(0, 242, 255, 0.12);
}

.support-page__back-icon {
    display: block;
    transform: translateX(-1px);
}

.support-page__title {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    margin: 0;
    max-width: min(420px, calc(100vw - 120px));
    font-size: clamp(18px, 4.2vw, 24px);
    font-weight: 700;
    font-family: var(--font-mono-display);
    letter-spacing: 0.03em;
    color: var(--text-heading);
    text-align: center;
    line-height: 1.2;
    z-index: 0;
}

.support-page__head-right {
    flex: 0 0 auto;
    min-width: 44px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    z-index: 1;
}

.support-page__new-ticket {
    width: auto;
    white-space: nowrap;
}

.support-page__home {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin: 0;
    border-radius: 10px;
    color: var(--accent);
    text-decoration: none;
    transition:
        background 0.15s,
        color 0.15s;
}

.support-page__home:hover {
    background: var(--ui-hover-soft);
    color: var(--ui-hover);
    box-shadow: 0 0 14px rgba(0, 242, 255, 0.12);
}

.support-page__home-icon {
    display: block;
    width: 22px;
    height: 22px;
}

.support-page__status--ticket {
    margin: -8px 0 24px;
    text-align: center;
}

.support-page__ticket-ref {
    margin: -16px 0 22px;
    text-align: center;
    font-size: 12px;
    line-height: 1.45;
    color: var(--muted);
    word-break: break-all;
}

.support-page__ticket-ref code {
    font-size: 11px;
    font-family: var(--font-family);
    color: var(--text);
    background: rgba(0, 0, 0, 0.25);
    padding: 4px 8px;
    border-radius: 6px;
}

.support-page__close {
    margin-bottom: 1.25rem;
}

.support-page__empty {
    margin: 8px 0 20px;
    text-align: center;
    color: var(--muted);
    font-size: 15px;
    line-height: 1.5;
}

.support-page__cta {
    display: flex;
    justify-content: center;
    margin-top: 8px;
}

.support-page__cta .btn {
    width: auto;
    min-width: min(280px, 100%);
}

/* Тикеты: форма создания / ответа — без прозрачности у полей, dropzone и кнопок */
.support-form input:not([type="checkbox"]):not([type="radio"]),
.support-form textarea {
    background: #111a36;
}

.support-form .support-dropzone {
    background: #111a36;
}

.support-form .support-dropzone.support-dropzone--hover,
.support-form .support-dropzone--hover {
    background: #161f3d;
    border-color: var(--accent);
}

.support-form .support-user-attachments .support-btn-add-image {
    background: #111a36;
}

.support-form button[type="submit"].btn-block {
    background: var(--brand-red);
    border-color: var(--brand-red);
    color: #fff;
}

.support-form button[type="submit"].btn-block:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    color: #fff;
    box-shadow:
        0 0 28px rgba(255, 255, 255, 0.22),
        0 0 48px rgba(211, 26, 36, 0.35);
}

.support-ticket-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.support-ticket-list__item {
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 10px;
    background: rgba(17, 26, 54, 0.65);
}

.support-ticket-list__link {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 14px 16px;
    color: inherit;
    text-decoration: none;
}

.support-ticket-list__link:hover {
    background: rgba(0, 242, 255, 0.08);
}

.support-ticket-list__subject {
    font-weight: 600;
}

.support-ticket-list__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    font-size: var(--text-sm);
    color: var(--muted);
}

.support-ticket-list__badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    background: rgba(0, 242, 255, 0.15);
    color: var(--text);
    font-size: 12px;
}

.support-dropzone {
    position: relative;
    border: 1px dashed var(--border);
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    background: rgba(7, 11, 26, 0.5);
    transition: border-color 0.15s ease, background 0.15s ease;
}

.support-dropzone__hit-area {
    position: relative;
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.support-dropzone--hover {
    border-color: var(--accent);
    background: rgba(0, 242, 255, 0.06);
}

.support-dropzone__input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    z-index: 1;
}

.support-dropzone__hint {
    margin: 0;
    font-size: var(--text-md);
    color: var(--muted);
    pointer-events: none;
    position: relative;
    z-index: 0;
}

.support-dropzone__previews {
    text-align: left;
    margin: 12px 0 0;
    padding-left: 18px;
    font-size: var(--text-sm);
    color: var(--muted);
}

.support-user-attachments .support-btn-add-image {
    display: block;
    width: 100%;
    margin-top: 12px;
}

.support-file-input-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.support-dropzone__previews-inner {
    position: relative;
    z-index: 2;
    margin-top: 4px;
}

.support-thumb-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
    gap: 10px;
    margin-top: 14px;
    text-align: left;
}

.support-thumb {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--border);
    aspect-ratio: 1;
    background: rgba(0, 0, 0, 0.25);
}

.support-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.support-thumb__remove {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 26px;
    height: 26px;
    padding: 0;
    border: none;
    border-radius: 8px;
    background: rgba(10, 14, 28, 0.85);
    color: var(--text);
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
}

.support-thumb__remove--text {
    position: static;
    width: auto;
    height: auto;
    padding: 2px 8px;
    font-size: var(--text-md);
}

.support-dropzone__other-list {
    list-style: none;
    margin: 12px 0 0;
    padding: 0;
    text-align: left;
    font-size: var(--text-sm);
    color: var(--muted);
}

.support-dropzone__other-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 6px 0;
    border-bottom: 1px solid var(--border);
}

.support-dropzone__other-list li:last-child {
    border-bottom: none;
}

.support-chat {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.support-chat__msg {
    display: flex;
}

.support-chat__msg--user {
    justify-content: flex-end;
}

.support-chat__msg--staff {
    justify-content: flex-start;
}

.support-chat__bubble {
    width: min(640px, 100%);
    max-width: 640px;
    min-height: 56px;
    min-width: min(100%, 280px);
    box-sizing: border-box;
    padding: 12px 16px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: rgba(17, 26, 54, 0.85);
}

.support-chat__msg--user .support-chat__bubble {
    background: rgba(0, 242, 255, 0.12);
    border-color: rgba(0, 242, 255, 0.35);
}

.support-chat__body {
    margin: 0 0 8px;
    white-space: pre-wrap;
    word-break: break-word;
}

.support-chat__files {
    margin: 0 0 8px;
    padding: 0;
    list-style: none;
    font-size: var(--text-sm);
}

.support-chat__file {
    margin-bottom: 10px;
}

.support-chat__file:last-child {
    margin-bottom: 0;
}

.support-chat__file--image .support-chat__img-open {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 100%;
    margin: 0 0 8px;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: rgba(0, 0, 0, 0.22);
    color: var(--text);
    font-size: var(--text-md);
    text-align: left;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    transition:
        background 0.15s ease,
        border-color 0.15s ease;
}

.support-chat__file--image .support-chat__img-open:hover {
    background: rgba(0, 242, 255, 0.1);
    border-color: rgba(0, 242, 255, 0.35);
}

.support-chat__img-open-icon {
    flex: 0 0 auto;
    display: flex;
    color: var(--accent);
}

.support-chat__img-open-label {
    flex: 1 1 auto;
    min-width: 0;
    font-weight: 500;
}

html.support-lightbox-open,
html.support-lightbox-open body {
    overflow: hidden;
    overscroll-behavior: none;
}

.support-img-lightbox {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
    padding: 0;
    box-sizing: border-box;
}

.support-img-lightbox[hidden] {
    display: none !important;
}

.support-img-lightbox__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(5, 8, 18, 0.92);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.support-img-lightbox__inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 100%;
    min-height: 100dvh;
    padding: max(12px, env(safe-area-inset-top, 0px)) max(12px, env(safe-area-inset-right, 0px))
        max(12px, env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px));
    box-sizing: border-box;
    pointer-events: none;
}

.support-img-lightbox__inner > * {
    pointer-events: auto;
}

.support-img-lightbox__close {
    position: absolute;
    top: max(8px, env(safe-area-inset-top, 0px));
    right: max(8px, env(safe-area-inset-right, 0px));
    z-index: 2;
    width: 48px;
    height: 48px;
    padding: 0;
    border: none;
    border-radius: 12px;
    background: rgba(20, 28, 48, 0.92);
    color: var(--text);
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
}

.support-img-lightbox__close:hover {
    background: rgba(0, 242, 255, 0.25);
}

.support-img-lightbox__frame {
    width: 100%;
    max-width: min(96vw, 960px);
    max-height: calc(100dvh - max(24px, env(safe-area-inset-top)) - max(24px, env(safe-area-inset-bottom)));
    overflow: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    display: flex;
    align-items: center;
    justify-content: center;
}

.support-img-lightbox__img {
    display: block;
    max-width: 100%;
    width: auto;
    height: auto;
    max-height: calc(100dvh - max(32px, env(safe-area-inset-top)) - max(32px, env(safe-area-inset-bottom)));
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45);
    touch-action: manipulation;
}

.support-chat__file-name {
    display: inline-block;
    font-size: var(--text-sm);
    word-break: break-all;
}

.support-chat__file:not(.support-chat__file--image) {
    padding-left: 0;
}

.support-chat__time {
    font-size: 11px;
    color: var(--muted);
}

.support-chat__size {
    display: inline-block;
    margin-left: 8px;
    font-size: 11px;
    color: var(--muted);
}

.field-label {
    display: block;
    margin-bottom: 6px;
    font-size: var(--text-md);
    color: var(--muted);
}

/* Admin — в одной стилистике с витриной (тёмный фон, акцент --accent, карточки .card) */
.admin-body {
    margin: 0;
    min-height: 100vh;
}

.admin-body--login {
    min-height: 100vh;
}

.admin-login-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.admin-login-top {
    padding: 20px 0 10px;
    border-bottom: 1px solid var(--border-accent);
    background: linear-gradient(180deg, rgba(11, 14, 20, 0.95), rgba(11, 14, 20, 0.4));
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.admin-login-top__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.admin-login-top__meta {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.admin-login-center {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 0 48px;
}

.admin-login-card {
    width: min(420px, 100%);
    margin: 0 auto;
}

.admin-login-card.card {
    padding: 32px 28px;
}

.admin-login-card__title {
    margin: 0 0 8px;
    font-size: clamp(22px, 3.2vw, 28px);
    font-family: var(--font-mono-display);
    letter-spacing: 0.03em;
    line-height: 1.15;
}

.admin-login-card__subtitle {
    margin: 0 0 20px;
}

.admin-login-submit {
    margin-top: 4px;
    background: transparent;
    border: 1px solid var(--brand-red);
    color: #fff;
    box-shadow: none;
}

.admin-login-submit:hover {
    background: var(--brand-red);
    box-shadow:
        0 0 28px rgba(255, 255, 255, 0.2),
        0 0 48px rgba(211, 26, 36, 0.35);
    filter: none;
}

.admin-text-link {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--ui-hover);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition:
        color 0.15s,
        border-color 0.15s;
}

.admin-text-link:hover {
    color: var(--text-heading);
    border-bottom-color: var(--ui-hover-mid);
}

.admin-shell {
    display: grid;
    grid-template-columns: minmax(220px, 260px) 1fr;
    min-height: 100vh;
}

@media (max-width: 720px) {
    .admin-shell {
        grid-template-columns: 1fr;
    }
}

.admin-nav {
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: 0;
    border-right: 1px solid var(--border-accent);
    background:
        linear-gradient(165deg, rgba(211, 26, 36, 0.1) 0%, transparent 42%),
        linear-gradient(180deg, rgba(11, 14, 20, 0.98), rgba(0, 0, 0, 0.92));
    box-shadow: 4px 0 32px rgba(0, 0, 0, 0.35);
}

.admin-nav__head {
    padding: 20px 18px 16px;
    border-bottom: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: flex-start;
}

.admin-nav__badge {
    align-self: flex-start;
}

.admin-nav__links {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 14px 12px;
    flex: 1;
}

.admin-nav__link {
    display: block;
    padding: 10px 14px;
    border-radius: 10px;
    font-size: var(--text-md);
    font-weight: 600;
    color: var(--text-label);
    text-decoration: none;
    border: 1px solid transparent;
    background: transparent;
    transition:
        background 0.15s,
        border-color 0.15s,
        color 0.15s;
}

.admin-nav__link:hover {
    color: var(--ui-hover);
    background: var(--ui-hover-soft);
    border-color: var(--ui-hover-mid);
}

.admin-nav__link.is-active {
    color: #fff;
    background: var(--red-soft);
    border-color: var(--border-accent);
    box-shadow: 0 0 0 1px rgba(211, 26, 36, 0.2);
}

.admin-nav__foot {
    margin-top: auto;
    padding: 16px 14px 20px;
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.admin-nav__site-link {
    text-align: center;
}

.admin-nav__logout {
    margin: 0;
}

.admin-nav__logout .btn {
    margin: 0;
}

@media (max-width: 720px) {
    .admin-nav {
        border-right: none;
        border-bottom: 1px solid var(--border);
        box-shadow: none;
    }

    .admin-nav__links {
        flex-direction: row;
        flex-wrap: wrap;
        padding-bottom: 8px;
    }

    .admin-nav__link {
        flex: 1 1 auto;
        min-width: min(140px, 100%);
        text-align: center;
    }

    .admin-nav__foot {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
    }

    .admin-nav__site-link {
        text-align: left;
    }

    .admin-nav__logout {
        flex: 1 1 160px;
    }
}

.admin-main {
    padding: 28px 0 56px;
}

.admin-main__inner {
    max-width: min(1120px, 92vw);
}

.admin-main h1 {
    margin: 0 0 16px;
    font-size: clamp(22px, 2.8vw, 30px);
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.admin-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--border-accent);
    border-radius: 18px;
    padding: 28px 26px;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.4);
    margin-bottom: 22px;
}

.admin-stats {
    list-style: none;
    padding: 0;
    margin: 0 0 24px;
}

.admin-stats li {
    margin-bottom: 8px;
    font-size: 15px;
}

.admin-filter {
    margin-bottom: 24px;
    max-width: 520px;
}

.admin-filter--inline {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px 16px;
    max-width: none;
}

.admin-filter--inline .field {
    margin-bottom: 0;
    flex: 1 1 140px;
    min-width: min(100%, 140px);
}

.admin-filter--inline .btn {
    flex: 0 0 auto;
    margin-bottom: 2px;
}

.admin-ticket-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.admin-ticket-list li {
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    align-items: baseline;
}

.admin-ticket-list li:last-child {
    border-bottom: none;
}

.admin-ticket-ref {
    margin: 0 0 12px;
    font-size: 12px;
    word-break: break-all;
}

.admin-ticket-ref code {
    font-size: 11px;
    font-family: var(--font-family);
}

.admin-ticket-list__uuid {
    font-size: 11px;
    font-family: var(--font-family);
    word-break: break-all;
}

.admin-ticket-list .muted {
    color: var(--muted);
    font-size: var(--text-sm);
}

.admin-inquiries-total {
    margin-bottom: 16px;
    font-size: var(--text-md);
}

.admin-inquiry-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.admin-inquiry-list__item {
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
}

.admin-inquiry-list__item:last-child {
    border-bottom: none;
}

.admin-inquiry-list__link {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px 12px;
    text-decoration: none;
    color: var(--accent);
    font-weight: 600;
}

.admin-inquiry-list__id {
    color: var(--muted);
    font-weight: 500;
}

.admin-inquiry-list__email {
    font-size: 12px;
}

.admin-inquiry-list__time {
    display: block;
    font-size: 12px;
    margin-top: 4px;
    color: var(--muted);
}

.admin-inquiry-list__preview {
    margin: 8px 0 0;
    font-size: var(--text-sm);
    color: var(--muted);
    line-height: 1.45;
}

.admin-inquiry-body {
    margin-top: 20px;
}

.admin-inquiry-body h2 {
    font-size: 15px;
    margin: 0 0 10px;
}

.admin-inquiry-body__text {
    white-space: pre-wrap;
    word-break: break-word;
    font-family: inherit;
    font-size: var(--text-md);
    line-height: 1.55;
    margin: 0;
    padding: 14px 16px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    border: 1px solid var(--border);
}

.admin-main select,
.admin-main textarea,
.admin-login-card select {
    width: 100%;
    border: 1px solid var(--border);
    background: rgba(0, 0, 0, 0.45);
    color: var(--text-heading);
    border-radius: 10px;
    padding: 12px 14px;
    font-size: var(--text-md);
    outline: none;
    transition:
        border-color 0.15s,
        box-shadow 0.15s;
    font-family: inherit;
    caret-color: var(--brand-red);
}

@supports (caret-shape: block) {
    .admin-main select,
    .admin-main textarea,
    .admin-login-card select {
        caret-shape: block;
    }
}

.admin-main select:focus,
.admin-main textarea:focus,
.admin-login-card select:focus {
    border-color: var(--ui-hover);
    box-shadow: 0 0 0 1px var(--ui-hover);
}

.admin-main .admin-ticket-list a {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
}

.admin-main .admin-ticket-list a:hover {
    text-decoration: underline;
    color: var(--ui-hover);
}

.admin-main h2 {
    margin: 20px 0 12px;
    font-size: 17px;
    color: var(--text-label);
    font-weight: 600;
    font-family: var(--font-mono-display);
}

/* Veloxi Pro / UBL (account drawer) */
.ubl-amount {
    display: flex;
    align-items: baseline;
    gap: 0.35rem;
    flex-wrap: wrap;
    color: var(--text-heading);
}

.ubl-amount--hero {
    font-size: 1.75rem;
    font-weight: 700;
    margin: 0.35rem 0 0.75rem;
}

.ubl-amount__symbol {
    font-size: 1.25em;
    line-height: 1;
}

.ubl-amount__value {
    font-family: var(--font-mono-display);
    letter-spacing: 0.02em;
}

.ubl-amount__label {
    font-size: 0.85em;
    color: var(--text-muted, var(--text));
    font-weight: 500;
}

.referral-disclaimer {
    font-size: 0.8125rem;
    line-height: 1.45;
    color: var(--text-muted, rgba(200, 205, 214, 0.85));
    margin: 0.25rem 0 0;
}

.referral-disclaimer--ubl-rate {
    border-left: 2px solid var(--border-accent, rgba(211, 26, 36, 0.45));
    padding-left: 0.65rem;
}

.referral-disclaimer--withdraw-usdt {
    margin-bottom: 0.75rem;
}

.referral-subheading {
    margin: 0 0 0.5rem;
    font-size: 0.9375rem;
    color: var(--text-label);
    font-weight: 600;
}

.referral-rank-progress {
    height: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
    margin: 0.5rem 0;
}

.referral-rank-progress__bar {
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--accent), #ff6b6b);
    transition: width 0.25s ease;
}

.referral-invite-input {
    font-family: var(--font-mono-display);
    font-size: 0.8125rem;
    min-width: 0;
}

.referral-invite-row__controls {
    display: flex;
    align-items: stretch;
    gap: 8px;
}

.referral-invite-row__controls .referral-invite-input {
    flex: 1 1 auto;
}

.referral-invite-row__actions {
    display: flex;
    flex: 0 0 auto;
    gap: 6px;
}

.referral-invite-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    min-width: 40px;
    height: 40px;
    padding: 0;
    border: 1px solid var(--border-accent);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-label);
    font-family: inherit;
    cursor: pointer;
    transition:
        color 0.15s ease,
        background 0.15s ease,
        border-color 0.15s ease;
}

.referral-invite-btn:hover {
    color: var(--text);
    background: var(--ui-hover-soft);
    border-color: var(--ui-hover-mid);
}

.referral-invite-btn:focus-visible {
    outline: 2px solid var(--ui-hover-ring);
    outline-offset: 2px;
}

.referral-invite-btn__icon {
    flex-shrink: 0;
    display: block;
}

.referral-invite-btn--copied {
    border-color: rgba(82, 211, 138, 0.45);
    background: rgba(82, 211, 138, 0.1);
}

.referral-invite-btn__icon--ok {
    stroke: var(--success);
}

.referral-invite-btn--share[hidden] {
    display: none !important;
}

.referral-invite-btn--share {
    color: #93c5fd;
    border-color: rgba(59, 130, 246, 0.35);
}

.referral-invite-btn--share:hover {
    color: #bfdbfe;
    background: rgba(59, 130, 246, 0.12);
    border-color: rgba(59, 130, 246, 0.5);
}

@media (max-width: 420px) {
    .referral-invite-row__controls {
        flex-direction: column;
        align-items: stretch;
    }

    .referral-invite-row__actions {
        width: 100%;
        justify-content: flex-end;
    }
}

.referral-friends-panel {
    margin-top: 0.75rem;
}

.referral-friends-table-wrap {
    overflow-x: auto;
    margin-top: 0.5rem;
}

.referral-friends-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}

.referral-friends-table th,
.referral-friends-table td {
    padding: 0.5rem 0.4rem;
    border-bottom: 1px solid var(--border);
    text-align: left;
    vertical-align: top;
}

.referral-friends-table th {
    color: var(--text-label);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.referral-friends-table__status--active {
    color: #6ee7a0;
}

.referral-friends-table__status--inactive {
    color: var(--text-muted, rgba(200, 205, 214, 0.75));
}

.referral-friends-pager {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 0.75rem;
}

.referral-friends-pager__label {
    font-size: 0.8125rem;
    color: var(--text-muted, var(--text));
}

.referral-withdraw-confirm {
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
    font-size: 0.8125rem;
    line-height: 1.4;
    margin: 0.5rem 0 0.75rem;
    cursor: pointer;
}

.referral-withdraw-confirm input {
    margin-top: 0.2rem;
    flex-shrink: 0;
}

.referral-withdraw-section .field {
    margin-bottom: 0.75rem;
}

/* Veloxi Pro referral dashboard (/account/referral) */
.nav-referral-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.5rem;
    padding: 0 0.85rem;
    border-radius: 999px;
    border: 1px solid rgba(211, 26, 36, 0.45);
    background: rgba(211, 26, 36, 0.08);
    color: var(--text, #e8eaef);
    font-size: 0.8125rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    white-space: nowrap;
}

.nav-referral-btn:hover {
    background: rgba(211, 26, 36, 0.18);
    border-color: rgba(255, 90, 100, 0.65);
    box-shadow: 0 0 18px rgba(211, 26, 36, 0.25);
}

@media (max-width: 640px) {
    .nav-referral-btn__label {
        font-size: 0.75rem;
    }
}

.referral-page {
    max-width: 1120px;
    margin: 0 auto;
    padding: 1.25rem 1rem 3rem;
}

.referral-page__head {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.referral-page__back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-muted, #a8adb8);
    text-decoration: none;
    transition: border-color 0.2s, color 0.2s;
}

.referral-page__back:hover {
    border-color: rgba(211, 26, 36, 0.5);
    color: var(--text, #fff);
}

.referral-page__title {
    margin: 0;
    font-size: clamp(1.25rem, 3vw, 1.75rem);
    font-weight: 700;
}

.referral-page__alert {
    margin-bottom: 1rem;
}

.referral-site-notice {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem 1rem;
}

.referral-site-notice__text {
    margin: 0;
    flex: 1 1 12rem;
}

.referral-site-notice__dismiss {
    margin: 0;
    flex: 0 0 auto;
}

.referral-dashboard {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.referral-dashboard__row {
    display: grid;
    gap: 1rem;
}

.referral-dashboard__row--top {
    grid-template-columns: 1fr 1fr 1.2fr;
}

.referral-dashboard__row--middle {
    grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.38fr);
}

.referral-card {
    position: relative;
    padding: 1.25rem 1.35rem;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(12, 14, 20, 0.72);
    backdrop-filter: blur(8px);
    overflow: hidden;
}

.referral-card__glow {
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
    filter: blur(48px);
    opacity: 0.35;
}

.referral-card__glow--balance {
    width: 140px;
    height: 140px;
    top: -40px;
    right: -20px;
    background: rgba(120, 200, 255, 0.55);
}

.referral-card__glow--rank {
    width: 120px;
    height: 120px;
    bottom: -30px;
    left: -20px;
    background: rgba(211, 26, 36, 0.45);
}

.referral-card__label {
    margin: 0 0 0.75rem;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted, rgba(200, 205, 214, 0.85));
}

.referral-card__label--section {
    font-size: 1rem;
    text-transform: none;
    letter-spacing: normal;
}

.referral-card__action {
    margin-top: 1rem;
}

.ubl-amount--neon .ubl-amount__value {
    font-size: clamp(2rem, 5vw, 2.5rem);
    font-weight: 800;
    text-shadow: 0 0 24px rgba(120, 200, 255, 0.45);
}

.referral-rank-name {
    margin: 0 0 0.35rem;
    font-size: 1.375rem;
    font-weight: 700;
}

.referral-rank-name--muted {
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 500;
}

.referral-rank-cashback {
    margin: 0 0 0.75rem;
    color: var(--text-muted);
    font-size: 0.9375rem;
}

.referral-rank-counters {
    margin: 0.75rem 0 0;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.referral-rank-progress--lg {
    height: 8px;
    margin: 0.65rem 0;
}

.referral-rank-card--scout {
    border-color: rgba(100, 180, 255, 0.35);
    box-shadow: inset 0 0 0 1px rgba(100, 180, 255, 0.08);
}

.referral-rank-card--partner {
    border-color: rgba(180, 120, 255, 0.4);
    box-shadow: inset 0 0 0 1px rgba(180, 120, 255, 0.1);
}

.referral-rank-card--ambassador {
    border-color: rgba(255, 180, 80, 0.45);
    box-shadow: 0 0 28px rgba(255, 160, 60, 0.12);
}

.referral-rank-card--ambassador .referral-rank-name {
    color: #ffc86a;
}

.referral-card--share .referral-invite-row {
    margin-top: 0.75rem;
}

.referral-withdraw-submit {
    border: 1px solid rgba(211, 26, 36, 0.65);
    background: transparent;
    color: var(--text, #fff);
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.referral-withdraw-submit--disabled,
.referral-withdraw-submit:disabled {
    opacity: 0.42;
    cursor: not-allowed;
    border-color: rgba(211, 26, 36, 0.25);
    box-shadow: none;
}

.referral-withdraw-submit--ready:not(:disabled) {
    opacity: 1;
    border-color: rgba(211, 26, 36, 0.9);
    box-shadow: 0 0 18px rgba(211, 26, 36, 0.35), inset 0 0 0 1px rgba(255, 120, 120, 0.15);
    font-weight: 600;
}

.referral-withdraw-submit:hover:not(:disabled) {
    background: rgba(211, 26, 36, 0.85);
    border-color: rgba(211, 26, 36, 0.95);
}

.referral-withdraw-widget .referral-wd-field {
    margin-bottom: 1rem;
}

.referral-withdraw-widget .referral-wd-field > label,
.referral-withdraw-widget .referral-wd-field-label {
    display: block;
    margin-bottom: 0.45rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-muted, rgba(200, 205, 214, 0.9));
}

.referral-wd-amount-wrap {
    position: relative;
    display: flex;
    align-items: stretch;
}

.referral-wd-input {
    width: 100%;
    padding: 0.72rem 0.85rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.35);
    color: var(--text, #fff);
    font-size: 1rem;
    font-weight: 600;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.referral-wd-input:focus {
    outline: none;
    border-color: rgba(211, 26, 36, 0.55);
    box-shadow: 0 0 0 3px rgba(211, 26, 36, 0.12);
}

.referral-wd-input--amount {
    padding-right: 4.25rem;
    -moz-appearance: textfield;
}

.referral-wd-input--amount::-webkit-outer-spin-button,
.referral-wd-input--amount::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.referral-wd-max-btn {
    position: absolute;
    top: 50%;
    right: 0.45rem;
    transform: translateY(-50%);
    padding: 0.28rem 0.55rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 200, 200, 0.95);
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.referral-wd-max-btn:hover {
    background: rgba(211, 26, 36, 0.22);
    border-color: rgba(211, 26, 36, 0.45);
}

.referral-wd-hint {
    margin: 0.4rem 0 0;
    font-size: 0.75rem;
    line-height: 1.4;
    color: var(--text-muted, rgba(160, 168, 180, 0.85));
}

.referral-wd-field-msg-slot {
    min-height: 2.75rem;
    margin-top: 0.35rem;
}

.referral-wd-field-msg {
    display: block;
    margin: 0;
    font-size: 0.75rem;
    line-height: 1.35;
}

.referral-wd-field-msg--hint {
    color: var(--text-muted, rgba(160, 168, 180, 0.85));
}

.referral-wd-field-msg--error {
    color: var(--brand-red, #d31a24);
    font-weight: 500;
}

.referral-withdraw-widget .referral-wd-input.is-field-error {
    border-color: var(--brand-red, #d31a24);
    box-shadow: 0 0 0 1px var(--brand-red, #d31a24);
}

.referral-wd-network-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.55rem;
}

.referral-wd-network-tab {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    padding: 0.65rem 0.75rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.28);
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.referral-wd-network-tab input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.referral-wd-network-tab__label {
    font-size: 0.9375rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.referral-wd-network-tab__hint {
    font-size: 0.6875rem;
    color: var(--text-muted, rgba(160, 168, 180, 0.8));
}

.referral-wd-network-tab:hover {
    border-color: rgba(255, 255, 255, 0.18);
}

.referral-wd-network-tab.is-active {
    border-color: rgba(211, 26, 36, 0.85);
    background: rgba(211, 26, 36, 0.1);
    box-shadow: 0 0 16px rgba(211, 26, 36, 0.28), inset 0 0 0 1px rgba(255, 100, 100, 0.12);
}

.referral-wd-payout-preview {
    margin: 0.25rem 0 1rem;
    padding: 0.75rem 0.85rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(255, 255, 255, 0.03);
}

.referral-wd-payout-preview__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.referral-wd-payout-preview__row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.35rem 0;
    font-size: 0.8125rem;
    color: var(--text-muted, rgba(180, 188, 200, 0.9));
}

.referral-wd-payout-preview__row--usdt {
    margin-top: 0.15rem;
    padding-top: 0.55rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.referral-wd-payout-preview__usdt {
    color: #fff;
    font-weight: 600;
    font-size: 0.9375rem;
}

.referral-wd-confirm {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    margin: 0.25rem 0 1rem;
    padding: 0.65rem 0.75rem;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.22);
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.referral-wd-confirm:hover {
    border-color: rgba(255, 255, 255, 0.14);
    background: rgba(0, 0, 0, 0.3);
}

.referral-wd-confirm__input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
    opacity: 0;
}

.referral-wd-confirm__box {
    flex-shrink: 0;
    width: 1.125rem;
    height: 1.125rem;
    margin-top: 0.1rem;
    border-radius: 4px;
    border: 2px solid rgba(255, 255, 255, 0.35);
    background-color: rgba(0, 0, 0, 0.4);
    transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.referral-wd-confirm__input:checked + .referral-wd-confirm__box {
    border-color: rgba(211, 26, 36, 0.9);
    background-color: rgba(211, 26, 36, 0.85);
    box-shadow: 0 0 10px rgba(211, 26, 36, 0.35);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 10' fill='none'%3E%3Cpath d='M1 5.2L4.2 8.4L11 1.4' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 0.65rem;
}

.referral-wd-confirm__input:focus-visible + .referral-wd-confirm__box {
    outline: 2px solid rgba(211, 26, 36, 0.65);
    outline-offset: 2px;
}

.referral-wd-confirm__text {
    font-size: 0.8125rem;
    line-height: 1.45;
    color: rgba(220, 226, 235, 0.95);
}

.referral-info-panel {
    display: flex;
    gap: 0.85rem;
    align-items: flex-start;
}

.referral-info-panel__icon {
    flex-shrink: 0;
    width: 2.25rem;
    height: 2.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(100, 160, 255, 0.12);
    color: rgba(140, 190, 255, 0.95);
}

.referral-info-panel__title {
    margin: 0 0 0.5rem;
    font-size: 0.9375rem;
    font-weight: 600;
}

.referral-info-panel__text {
    margin: 0 0 0.65rem;
    font-size: 0.8125rem;
    line-height: 1.5;
    color: var(--text-muted);
}

.referral-info-panel__text:last-child {
    margin-bottom: 0;
}

.referral-card--info-wide .referral-info-panel__body {
    max-width: none;
}

.referral-card--debits {
    min-height: 0;
    min-width: 0;
}

.referral-card--withdraw {
    min-width: 0;
}

.referral-card--debits .referral-wd-table th,
.referral-card--debits .referral-wd-table td {
    padding: 0.45rem 0.4rem;
}

.referral-card--debits .referral-wd-table {
    font-size: 0.78125rem;
}

.referral-card--debits .referral-debit-type {
    font-size: 0.625rem;
    padding: 0.12rem 0.38rem;
}

.referral-debit-type {
    display: inline-block;
    padding: 0.15rem 0.45rem;
    border-radius: 999px;
    font-size: 0.6875rem;
    font-weight: 600;
    line-height: 1.35;
    white-space: nowrap;
}

.referral-debit-type--withdrawal {
    color: rgba(255, 180, 120, 0.95);
    background: rgba(255, 140, 60, 0.15);
}

.referral-debit-type--tariff {
    color: rgba(140, 190, 255, 0.95);
    background: rgba(80, 140, 220, 0.15);
}

.referral-debit-details {
    font-size: 0.78125rem;
    line-height: 1.4;
    max-width: none;
}

.referral-wd-table__status--tariff {
    color: rgba(120, 230, 160, 0.95);
    background: rgba(60, 180, 110, 0.18);
}

.referral-card--withdraw-history {
    min-height: 0;
}

.referral-wd-table-wrap {
    overflow-x: auto;
}

.referral-wd-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}

.referral-wd-table th,
.referral-wd-table td {
    padding: 0.55rem 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    text-align: left;
    vertical-align: top;
}

.referral-wd-table th {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted, rgba(200, 205, 214, 0.85));
}

.referral-wd-table__amount {
    white-space: nowrap;
    color: rgba(255, 140, 140, 0.95);
}

.referral-wd-table__status {
    display: inline-block;
    font-size: 0.75rem;
    padding: 0.15rem 0.45rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
}

.referral-wd-table__status--pending {
    color: rgba(255, 200, 120, 0.95);
    background: rgba(255, 160, 60, 0.15);
}

.referral-wd-table__status--completed {
    color: rgba(120, 230, 160, 0.95);
    background: rgba(60, 180, 110, 0.18);
}

.referral-wd-table__status--rejected {
    color: rgba(255, 140, 140, 0.95);
    background: rgba(211, 26, 36, 0.18);
}

.referral-wd-table__reason {
    margin: 0.35rem 0 0;
    font-size: 0.75rem;
    line-height: 1.45;
    color: rgba(255, 170, 170, 0.9);
}

.referral-card--friends {
    padding-bottom: 1rem;
}

.referral-status-badge {
    display: inline-block;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.35;
}

.referral-status-badge--active {
    color: rgba(120, 230, 160, 0.95);
    background: rgba(60, 180, 110, 0.18);
}

.referral-status-badge--inactive {
    color: rgba(180, 186, 198, 0.9);
    background: rgba(255, 255, 255, 0.06);
}

.referral-friends-table th,
.referral-friends-table td {
    padding: 0.65rem 0.75rem;
}

.referral-tx-table-wrap {
    overflow-x: auto;
}

.referral-tx-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.referral-tx-table th,
.referral-tx-table td {
    padding: 0.55rem 0.65rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    text-align: left;
}

.referral-tx-table__amount--credit {
    color: rgba(120, 230, 160, 0.95);
}

.referral-tx-table__amount--debit {
    color: rgba(255, 140, 140, 0.95);
}

.referral-tx-table__status {
    font-size: 0.75rem;
    padding: 0.15rem 0.45rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
}

.referral-modal {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.referral-modal[hidden] {
    display: none !important;
}

.referral-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
}

.referral-modal__panel {
    position: relative;
    width: min(640px, 100%);
    max-height: min(80vh, 720px);
    overflow: auto;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(14, 16, 22, 0.96);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
}

.referral-modal__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.15rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.referral-modal__title {
    margin: 0;
    font-size: 1.0625rem;
}

.referral-modal__close {
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}

.referral-modal__body {
    padding: 1rem 1.15rem 1.25rem;
}

body.referral-modal-open {
    overflow: hidden;
}

.referral-withdraw-modal__panel {
    width: min(520px, 100%);
}

.referral-withdraw-modal__warn {
    margin: 0 0 1rem;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    border: 1px solid rgba(255, 90, 100, 0.45);
    background: rgba(211, 26, 36, 0.12);
    color: #ffd4d8;
    font-size: 0.875rem;
    line-height: 1.5;
}

.referral-withdraw-modal__recap {
    margin: 0 0 1rem;
    padding: 0;
}

.referral-withdraw-modal__recap-row {
    display: grid;
    grid-template-columns: minmax(0, 9rem) minmax(0, 1fr);
    gap: 0.35rem 0.75rem;
    margin-bottom: 0.65rem;
}

.referral-withdraw-modal__recap-row dt {
    margin: 0;
    font-size: 0.8125rem;
    color: var(--text-muted, #a8adb8);
}

.referral-withdraw-modal__recap-row dd {
    margin: 0;
    font-size: 0.9375rem;
    word-break: break-word;
}

.referral-withdraw-modal__recap-row--address {
    grid-template-columns: 1fr;
}

.referral-withdraw-modal__recap-row--address dt {
    margin-bottom: 0.15rem;
}

.referral-withdraw-modal__recap-row--address dd {
    grid-column: auto;
}

.referral-withdraw-modal__address {
    display: block;
    margin-top: 0.35rem;
    padding: 0.5rem 0.65rem;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.35);
    font-size: 0.8125rem;
    line-height: 1.45;
    word-break: break-all;
    white-space: normal;
}

.referral-withdraw-modal__ack {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    margin: 0 0 1.25rem;
    font-size: 0.875rem;
    line-height: 1.45;
    cursor: pointer;
}

.referral-withdraw-modal__ack input {
    margin-top: 0.2rem;
    flex-shrink: 0;
}

.referral-withdraw-modal__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    justify-content: flex-end;
}

@media (max-width: 960px) {
    .referral-dashboard__row--top {
        grid-template-columns: 1fr 1fr;
    }

    .referral-dashboard__row--top .referral-card--share {
        grid-column: 1 / -1;
    }

    .referral-dashboard__row--middle {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .referral-dashboard__row--top {
        grid-template-columns: 1fr;
    }

    .referral-page {
        padding-inline: 0.75rem;
    }

    .referral-friends-table-wrap {
        margin-inline: -0.35rem;
    }

    .nav-referral-btn {
        padding-inline: 0.55rem;
    }
}
