:root {
  color-scheme: light;
  --navy-950: #121e2b;
  --navy-900: #172635;
  --navy-800: #25313e;
  --cyan: #d1b478;
  --cyan-soft: #f3ead7;
  --blue: #775b29;
  --surface: #f5f5f1;
  --card: #ffffff;
  --ink: #202a35;
  --muted: #5c6570;
  --line: #dce0de;
  --danger: #c43d51;
  --warning: #947029;
  --radius: 7px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; min-width: 0; min-height: 100svh; background: var(--surface); color: var(--ink); }
button, input, textarea, select { font: inherit; }
input, textarea, select { font-size: max(16px, 1rem); min-width: 0; max-width: 100%; scroll-margin-block: 16px; }
button, a { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 3px solid #947029; outline-offset: 4px; }
[hidden] { display: none !important; }

.app-shell { min-height: 100svh; max-width: 100%; }
.topbar { height: 78px; padding: 0 max(20px, env(safe-area-inset-left)); display: flex; align-items: center; justify-content: space-between; background: var(--navy-950); color: white; border-bottom: 1px solid #34404a; }
.brand { color: white; display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; letter-spacing: .08em; }
.brand-mark { width: 36px; height: 36px; fill: none; stroke: var(--cyan); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.icon-button, .avatar { width: 42px; height: 42px; border-radius: 5px; display: grid; place-items: center; border: 1px solid #52606b; background: rgba(255,255,255,.04); color: white; cursor: pointer; }
.icon-button svg { width: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.avatar { background: var(--cyan); color: var(--navy-950); border: none; font-weight: 800; }

.auth-view { min-height: calc(100svh - 78px); background: var(--navy-950); color: white; display: grid; align-content: start; }
.auth-intro { padding: 48px 24px 36px; position: relative; overflow: hidden; }
.auth-intro::after { content: ""; position: absolute; width: 300px; height: 300px; border: 1px solid rgba(209,180,120,.35); transform: rotate(12deg); right: -185px; top: -110px; }
.eyebrow, .card-label { margin: 0 0 8px; text-transform: uppercase; letter-spacing: .13em; font-size: .78rem; font-weight: 800; color: #788b9d; }
.auth-intro .eyebrow { color: var(--cyan); }
.auth-intro h1 { margin: 0; max-width: 560px; font-size: clamp(2.25rem, 10vw, 4.8rem); line-height: .98; letter-spacing: -.055em; }
.auth-intro > p:last-child { margin: 20px 0 0; max-width: 390px; color: #9fb0be; line-height: 1.6; }
.signal-orbit { width: 58px; height: 58px; margin-bottom: 28px; position: relative; border: 1px solid rgba(209,180,120,.4); border-radius: 5px; }
.signal-orbit span { position: absolute; inset: 8px; border: 2px solid transparent; border-top-color: var(--cyan); border-radius: 50%; transform: rotate(35deg); }
.signal-orbit span:nth-child(2) { inset: 16px; }
.signal-orbit span:nth-child(3) { inset: 24px; background: var(--cyan); border: 0; box-shadow: 0 0 20px var(--cyan); }
.auth-card { background: white; color: var(--ink); padding: 30px 24px max(32px, env(safe-area-inset-bottom)); border-radius: 14px 14px 0 0; min-height: 430px; }
.auth-card form { max-width: 420px; margin: 0 auto; }
.auth-card h2 { margin: 0; font-size: 1.6rem; }
.form-note { color: var(--muted); margin: 8px 0 24px; }
label { display: grid; gap: 8px; color: #435465; font-size: .88rem; font-weight: 700; margin-top: 16px; }
input { width: 100%; border: 1px solid var(--line); border-radius: 5px; padding: 14px 16px; min-height: 52px; color: var(--ink); background: #fbfbf8; }
input:focus { border-color: #947029; background: white; }
.form-error { color: var(--danger); font-size: .9rem; margin: 14px 0 0; }
.auth-recovery-link, .auth-back-link { display: inline-block; color: var(--blue); font-weight: 800; text-decoration: underline; text-underline-offset: 3px; }
.auth-recovery-link { margin-top: 14px; }
.auth-back-link { margin-top: 20px; }
.reset-state { max-width: 420px; margin: 0 auto; }
.reset-state .button { display: grid; place-items: center; text-decoration: none; }
.telegram-hint { max-width: 420px; margin: 24px auto 0; padding-top: 20px; border-top: 1px solid var(--line); }
.telegram-hint span { font-weight: 800; }
.telegram-hint p { color: var(--muted); line-height: 1.5; margin: 5px 0 0; font-size: .9rem; }
.telegram-progress { max-width: 420px; margin: 0 auto; min-height: 160px; align-items: center; justify-content: center; gap: 16px; }
.telegram-progress:not([hidden]) { display: flex; }
.telegram-progress div { display: grid; gap: 4px; }
.telegram-progress small { color: var(--muted); }
.spinner { width: 34px; height: 34px; border: 3px solid var(--line); border-top-color: var(--blue); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.onboarding-view { min-height: calc(100svh - 78px); padding: 24px 18px max(36px, env(safe-area-inset-bottom)); display: grid; place-items: start center; background: linear-gradient(145deg, rgba(209,180,120,.12), transparent 35%), var(--navy-950); }
.onboarding-card { width: min(480px, 100%); margin-top: 12px; padding: 28px 22px; border-radius: var(--radius); background: white; border: 1px solid var(--line); box-shadow: 0 24px 70px rgba(0,0,0,.2); }
.onboarding-mark { width: 52px; height: 52px; margin-bottom: 22px; display: grid; place-items: center; border-radius: 5px; background: var(--cyan-soft); color: #775b29; font-size: 1.35rem; font-weight: 900; }
.onboarding-card h1 { margin: 0; font-size: clamp(1.8rem, 8vw, 2.35rem); letter-spacing: -.045em; line-height: 1.05; }
.onboarding-copy { margin: 14px 0 24px; color: var(--muted); line-height: 1.55; }
.stage-note { margin: 0 0 18px; color: var(--muted); line-height: 1.5; }
.stage-note strong { color: var(--ink); overflow-wrap: anywhere; }
.code-input { font-size: 1.35rem; font-weight: 800; letter-spacing: .26em; text-align: center; }
.stage-links { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px; margin-top: 20px; }
.verified-banner { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; padding: 14px; border-radius: 5px; background: var(--cyan-soft); color: #665024; }
.verified-banner > span { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; background: #775b29; color: white; font-weight: 900; }
.verified-banner div { min-width: 0; display: grid; gap: 3px; }
.verified-banner small { overflow-wrap: anywhere; }
.checkout-note { margin: 24px 0 0; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: .82rem; line-height: 1.45; }
.onboarding-logout { margin-top: 18px; color: var(--muted); }

.button { min-height: 48px; padding: 13px 18px; border-radius: 5px; border: 1px solid transparent; font-weight: 700; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; transition: transform .18s, background .18s, border-color .18s; }
.button:hover { transform: translateY(-2px); }
.button.primary { background: var(--cyan); color: #16202b; box-shadow: none; }
.button.primary:hover { background: #e0c48f; }
.button.secondary { background: var(--navy-950); color: white; }
.button.quiet { background: #f1eadb; color: #775b29; }
.button.danger { background: #fff0f2; color: #a9293d; }
.button.light { background: white; color: var(--navy-950); }
.button.outline { color: white; background: transparent; border: 1px solid #52606b; }
.button.wide { width: 100%; margin-top: 20px; }
.button:disabled { opacity: .58; cursor: wait; }
.text-button, .panel-link { border: 0; background: none; padding: 0; color: var(--blue); font-weight: 800; cursor: pointer; }
.danger-text { color: #a9293d; }

.dashboard { width: min(1120px, 100%); margin: 0 auto; padding: 30px 18px 110px; }
.welcome-row { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.welcome-row h1 { font-size: clamp(1.75rem, 5vw, 2.7rem); letter-spacing: -.045em; margin: 0; }
.subscription-card { color: white; background: linear-gradient(135deg, rgba(209,180,120,.12), transparent 45%), var(--navy-900); border: 1px solid #34404a; border-top: 3px solid var(--cyan); border-radius: var(--radius); padding: 24px; box-shadow: 0 18px 45px rgba(18,30,43,.13); }
.subscription-top, .panel-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.subscription-card .card-label { color: #8fa4b5; }
.subscription-card h2, .panel h2 { margin: 0; font-size: 1.45rem; letter-spacing: -.025em; }
.plan-summary { color: #b8c8d3; font-size: .9rem; margin: 6px 0 0; }
.status-badge, .count-pill { white-space: nowrap; border-radius: 999px; padding: 7px 10px; font-weight: 800; font-size: .78rem; }
.status-badge.active { background: rgba(209,180,120,.16); color: #e0c48f; }
.status-badge.expiring { background: rgba(255,184,77,.15); color: #ffbd58; }
.status-badge.expired { background: rgba(255,105,105,.16); color: #ffaaaa; }
.status-badge.disabled, .status-badge.none { background: rgba(255,255,255,.1); color: #c9d5de; }
.subscription-metrics { display: grid; gap: 18px; margin: 28px 0; }
.subscription-metrics > div { display: grid; gap: 5px; }
.subscription-metrics span { color: #9fb0be; font-size: .82rem; }
.subscription-metrics strong { font-size: 1.08rem; }
.progress-track { height: 5px; background: rgba(255,255,255,.13); border-radius: 5px; margin-top: 7px; overflow: hidden; }
.progress-track span { display: block; width: 0; height: 100%; background: var(--cyan); border-radius: inherit; }
.empty-copy { color: #b5c3cd; line-height: 1.55; margin: 22px 0; max-width: 580px; }
.primary-actions { display: grid; gap: 10px; }
.dashboard-grid { display: grid; gap: 14px; margin-top: 14px; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.count-pill { background: var(--cyan-soft); color: #665024; min-width: 34px; text-align: center; }
.panel-icon { width: 34px; height: 34px; padding: 7px; border-radius: 5px; background: #f3ead7; fill: none; stroke: #775b29; stroke-width: 1.8; }
.empty-panel { color: var(--muted); line-height: 1.5; margin: 24px 0; }
.panel-link { width: 100%; display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); padding-top: 17px; text-align: left; }
.panel-link:disabled { color: var(--muted); cursor: not-allowed; }
.device-panel-actions { display: grid; gap: 16px; }
.device-panel-actions .danger-text { justify-self: start; font-size: .84rem; }
.device-panel-actions .refresh-devices { justify-self: start; }
.device-list { display: grid; gap: 11px; margin: 20px 0; }
.device { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.device-icon { width: 40px; height: 40px; border-radius: 5px; display: grid; place-items: center; background: #f3ead7; color: #775b29; font-weight: 900; }
.device strong, .device small { display: block; }
.device small { color: var(--muted); margin-top: 2px; }
.device-connect { min-height: 38px; border: 0; border-radius: 5px; padding: 8px 11px; background: #f3ead7; color: #775b29; font-weight: 800; cursor: pointer; }
.payment-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 15px 0; border-bottom: 1px solid var(--line); }
.payment-item:first-child { margin-top: 8px; }
.payment-item:last-child { border-bottom: 0; padding-bottom: 0; }
.payment-item strong, .payment-item small { display: block; }
.payment-item small { color: var(--muted); margin-top: 4px; line-height: 1.35; }
.payment-amount { display: grid; justify-items: end; gap: 6px; white-space: nowrap; }
.payment-status { border-radius: 999px; padding: 4px 8px; font-size: .72rem; font-weight: 800; background: #f1eadb; color: #775b29; }
.payment-status.succeeded { background: #e7efe9; color: #3f6656; }
.payment-status.canceled, .payment-status.expired { background: #fff0f2; color: var(--danger); }
.help-panel { background: #f3ead7; border-color: #e2d2ae; display: grid; gap: 22px; }
.help-panel p:not(.card-label) { color: #5d5548; margin: 8px 0 0; line-height: 1.5; }
.support-actions { display: grid; gap: 10px; width: 100%; }
.verified-icon { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: #e7efe9; color: #3f6656; font-weight: 900; }
.verified-state { display: grid; gap: 4px; margin: 22px 0 10px; }
.verified-state strong { color: #3f6656; }
.verified-state span { color: var(--muted); overflow-wrap: anywhere; }
.account-panel > p { margin: 0; color: var(--muted); line-height: 1.5; }
.notice { padding: 16px; border-radius: 7px; margin-bottom: 16px; display: grid; gap: 5px; }
.notice.error { background: #fff0f2; color: #7a1f2e; }

.setup-page { background: var(--navy-950); }
.setup-topbar { position: relative; z-index: 2; }
.setup-logo { width: 38px; height: 38px; border-radius: 7px; }
.setup-main { min-height: calc(100svh - 78px); padding: 48px 18px max(56px, env(safe-area-inset-bottom)); background: linear-gradient(145deg, rgba(209,180,120,.14), transparent 32%), var(--surface); }
.setup-hero, .setup-grid, .setup-help { width: min(1040px, 100%); margin-inline: auto; }
.setup-hero { max-width: 760px; margin-bottom: 34px; text-align: center; }
.setup-hero h1 { margin: 0; color: var(--navy-950); font-size: clamp(2.2rem, 9vw, 4.6rem); line-height: 1; letter-spacing: -.055em; }
.setup-hero > p:not(.eyebrow) { margin: 20px auto 24px; max-width: 680px; color: var(--muted); line-height: 1.65; }
.setup-grid { display: grid; gap: 14px; }
.setup-card { padding: 24px; border: 1px solid var(--line); border-top: 3px solid var(--cyan); border-radius: var(--radius); background: white; }
.setup-card h2, .setup-help h2 { margin: 0; color: var(--navy-950); font-size: 1.4rem; }
.setup-card ol { margin: 18px 0 0; padding-left: 1.25rem; color: var(--muted); line-height: 1.55; }
.setup-card li + li { margin-top: 9px; }
.setup-card code { font-size: .83em; overflow-wrap: anywhere; }
.setup-help { margin-top: 14px; padding: 24px; display: grid; gap: 20px; align-items: center; border-radius: var(--radius); background: var(--cyan-soft); border: 1px solid #e2d2ae; }
.setup-help p:not(.card-label) { margin: 9px 0 0; max-width: 660px; color: #5d5548; line-height: 1.55; }

@media (min-width: 760px) {
  .setup-main { padding-top: 72px; }
  .setup-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .setup-help { grid-template-columns: minmax(0, 1fr) auto; }
}

.bottom-nav { position: fixed; z-index: 20; left: 0; right: 0; bottom: 0; min-height: 72px; padding: 8px max(12px, env(safe-area-inset-right)) max(8px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left)); background: rgba(255,255,255,.96); border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(4, 1fr); backdrop-filter: blur(18px); }
.bottom-nav a { display: grid; justify-items: center; align-content: center; gap: 4px; color: #778492; font-size: .7rem; font-weight: 700; text-decoration: none; }
.bottom-nav a.active { color: var(--blue); }
.bottom-nav svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }

.modal-backdrop { position: fixed; z-index: 50; top: var(--visible-top, 0px); left: 0; right: 0; height: var(--visible-height, 100dvh); background: rgba(3,11,20,.64); display: grid; align-items: end; }
.modal { position: relative; width: 100%; min-width: 0; max-width: 100%; background: white; border-radius: 14px 14px 0 0; padding: 30px 24px max(28px, env(safe-area-inset-bottom)); max-height: 100%; max-height: min(90dvh, 100%); overflow-y: auto; overscroll-behavior: contain; overflow-wrap: anywhere; }
.keyboard-open .bottom-nav { display: none; }
.keyboard-open .modal { max-height: 100%; }
.delivery-status { margin: 0; font-size: .9rem; overflow-wrap: anywhere; }
.modal h2 { font-size: 1.55rem; margin: 16px 0 8px; }
.modal p { color: var(--muted); line-height: 1.55; }
.modal-close { position: absolute; right: 18px; top: 18px; width: 38px; height: 38px; border-radius: 50%; border: 0; background: var(--surface); color: var(--ink); font-size: 1.5rem; cursor: pointer; }
.modal-icon { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 5px; background: var(--cyan-soft); color: #775b29; font-weight: 900; font-size: 1.3rem; }
.modal-actions { display: grid; gap: 10px; margin-top: 22px; }
.checkout-offer { display: grid; gap: 12px; padding: 15px; border: 1px solid var(--line); border-radius: 7px; }
.checkout-offer strong, .checkout-offer small { display: block; }
.checkout-offer small { color: var(--muted); margin-top: 4px; }
.checkout-offer .button { width: 100%; }
.spinner.small { width: 24px; height: 24px; border-width: 2px; }
.connection-actions { margin-top: 18px; }
.connection-choices { display: grid; gap: 12px; margin-top: 20px; }
.connection-choice { position: relative; width: 100%; padding: 18px; display: grid; gap: 6px; text-align: left; border: 1px solid var(--line); border-radius: 7px; background: white; color: var(--ink); cursor: pointer; }
.connection-choice:hover, .connection-choice:focus-visible { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(119,91,41,.1); }
.connection-choice.recommended { padding-top: 36px; border-color: #cbb886; background: #fffdf8; }
.connection-choice > span { position: absolute; top: 11px; left: 18px; color: var(--blue); text-transform: uppercase; letter-spacing: .1em; font-size: .67rem; font-weight: 900; }
.connection-choice strong, .connection-choice small { display: block; }
.connection-choice strong { font-size: 1.05rem; }
.connection-choice small { color: var(--muted); line-height: 1.45; }
.connection-steps { display: grid; gap: 10px; margin: 18px 0; padding-left: 22px; color: var(--ink); }
.connection-steps li { padding-left: 4px; line-height: 1.5; }
.primary-connection-note { margin-top: 14px; text-align: left; }
.connection-loading { min-height: 150px; display: grid; place-items: center; align-content: center; gap: 8px; }
.connection-loading p { margin: 0; }
.auto-mode { display: grid; gap: 5px; margin: 18px 0; padding: 15px 16px; border-radius: 7px; background: var(--cyan-soft); color: #5d5548; }
.auto-mode strong { color: #665024; }
.auto-mode span { font-size: .9rem; line-height: 1.45; }
.credential-note { display: grid; gap: 5px; margin: 16px 0; padding: 14px 15px; border-radius: 7px; background: #f5f5f1; color: #4e5761; }
.credential-note strong { color: var(--ink); }
.credential-note span { font-size: .87rem; line-height: 1.45; }
.connection-qr { display: block; width: min(248px, 100%); height: auto; margin: 18px auto 8px; border: 1px solid var(--line); border-radius: 7px; }
.connection-qr.compact { width: min(216px, 100%); }
.secret-note { display: block; color: var(--muted); text-align: center; line-height: 1.4; }
.separate-configuration { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); }
.separate-configuration > strong { display: block; font-size: 1.05rem; }
.separate-configuration .button { width: 100%; }
.compatibility-note { margin-top: 16px; padding: 14px; border-radius: 7px; background: #f2f2ed; font-size: .86rem; }
.compatibility-note strong { display: block; }
.compatibility-note p { margin: 5px 0 12px; }
.offer-list { display: grid; gap: 10px; margin-top: 18px; }
.offer { border: 1px solid var(--line); border-radius: 7px; padding: 14px; }
.offer strong { display: block; }
.offer small { display: block; color: var(--muted); margin-top: 4px; }
.toast { position: fixed; z-index: 80; left: 18px; right: 18px; bottom: calc(90px + env(safe-area-inset-bottom)); background: var(--navy-950); color: white; border: 1px solid #34404a; border-radius: 7px; padding: 14px 16px; text-align: center; box-shadow: 0 16px 50px rgba(3,11,20,.28); }

.requisites-page { background: linear-gradient(145deg, rgba(209,180,120,.1), transparent 30%), var(--surface); }
.requisites-topbar { position: relative; z-index: 1; }
.requisites-home-link { color: #dce8ef; font-size: .82rem; font-weight: 800; text-decoration: none; }
.requisites-home-link:hover { color: #e0c48f; }
.requisites-main { width: min(820px, 100%); margin: 0 auto; padding: 34px 18px max(48px, env(safe-area-inset-bottom)); }
.requisites-hero { padding: 18px 6px 26px; }
.requisites-hero .eyebrow { color: #775b29; }
.requisites-hero h1 { margin: 0; font-size: clamp(2rem, 10vw, 3.7rem); line-height: 1; letter-spacing: -.05em; }
.requisites-hero > p:last-child { max-width: 520px; margin: 16px 0 0; color: var(--muted); line-height: 1.55; }
.requisites-card { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); box-shadow: 0 18px 45px rgba(18,30,43,.08); }
.requisites-list { margin: 0; }
.requisites-list > div { display: grid; gap: 6px; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.requisites-list > div:last-child { border-bottom: 0; }
.requisites-list dt { color: var(--muted); font-size: .78rem; font-weight: 800; letter-spacing: .02em; }
.requisites-list dd { margin: 0; color: var(--ink); font-size: .98rem; font-weight: 750; line-height: 1.45; overflow-wrap: anywhere; }
.requisites-list a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.site-footer { display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center; justify-content: center; padding: 22px 18px max(30px, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); font-size: .78rem; }
.site-footer a { color: var(--muted); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.site-footer a:hover { color: var(--blue); }
@media (max-width: 759px) {
  body:has(.bottom-nav:not([hidden])) .site-footer { padding-bottom: calc(98px + env(safe-area-inset-bottom)); }
}
.legal-page { background: var(--surface); }
.legal-main { width: min(820px, 100%); margin: 0 auto; padding: 34px 18px 56px; }
.legal-article { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 5vw, 48px); box-shadow: 0 18px 45px rgba(18,30,43,.08); }
.legal-article h1 { margin: 8px 0 14px; font-size: clamp(2rem, 8vw, 3.3rem); line-height: 1.06; letter-spacing: -.045em; }
.legal-article h2 { margin: 32px 0 10px; font-size: 1.18rem; }
.legal-article p, .legal-article li { color: var(--muted); line-height: 1.68; }
.legal-article ul { padding-left: 22px; }
.legal-article li + li { margin-top: 6px; }
.legal-article a { color: var(--blue); overflow-wrap: anywhere; }
.legal-updated { font-size: .8rem; }

@media (min-width: 760px) {
  .topbar { padding-inline: 5vw; }
  .auth-view { grid-template-columns: minmax(0, 1.15fr) minmax(380px, .85fr); align-items: stretch; }
  .auth-intro { padding: 10vh 7vw; display: flex; flex-direction: column; justify-content: center; }
  .auth-card { border-radius: 7px 0 0 7px; display: flex; flex-direction: column; justify-content: center; padding: 56px; }
  .onboarding-view { place-items: center; padding: 48px 24px; }
  .onboarding-card { margin-top: 0; padding: 40px; }
  .dashboard { padding: 50px 28px 70px; }
  .subscription-card { padding: 34px; }
  .subscription-metrics { grid-template-columns: 1fr 1fr; }
  .primary-actions { display: flex; }
  .dashboard-grid { grid-template-columns: 1fr 1fr; }
  .help-panel { grid-column: 1 / -1; grid-template-columns: 1fr auto; align-items: center; }
  .support-actions { width: 260px; }
  .bottom-nav { display: none !important; }
  .modal-backdrop { align-items: center; justify-items: center; padding: 24px; }
  .modal { width: min(520px, 100%); border-radius: 7px; }
  .legal-main { padding: 58px 28px 80px; }
  .requisites-main { padding: 58px 28px 80px; }
  .requisites-hero { padding: 20px 8px 34px; }
  .requisites-list > div { grid-template-columns: minmax(180px, .65fr) minmax(0, 1.35fr); gap: 28px; padding: 20px 28px; }
}

@media (max-width: 380px) {
  .device { grid-template-columns: 40px minmax(0, 1fr); }
  .device-connect { grid-column: 2; justify-self: start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .spinner { animation: none; }
}
.plan-device-choice { display: flex; align-items: center; gap: 12px; margin: 0; padding: 12px 0; overflow-wrap: anywhere; }
.plan-device-choice input { width: 20px; height: 20px; min-height: 20px; padding: 0; margin: 0; flex: 0 0 20px; }
[hidden] { display: none !important; }
.referral-actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 16px 0; }
.referral-qr { display: block; max-width: 100%; height: auto; border-radius: 12px; }
.setup-steps { padding-left: 22px; line-height: 1.7; }
#setupGuide, #how-to-connect-incy, #how-to-connect-happ { scroll-margin-top: 94px; }
.client-guide { border-top: 1px solid var(--line); padding: 16px 0; }
.client-guide summary { cursor: pointer; color: var(--ink); font-size: 1.05rem; font-weight: 800; line-height: 1.4; }
.client-guide summary:focus-visible { outline: 3px solid #947029; outline-offset: 4px; }
.client-guide .connection-steps { margin-bottom: 0; }
.client-guide-link { display: inline-block; margin: 0 0 4px; color: var(--blue); font-weight: 800; text-decoration: underline; text-underline-offset: 3px; }
#registerForm { display: grid; gap: 16px; }
#telegramWidget { margin-top: 16px; }
.telegram-link-banner { display: grid; gap: 14px; padding: 20px; margin-bottom: 22px; background: #fff8e7; border: 1px solid #cbb886; border-radius: 7px; }
.telegram-link-banner h2 { font-size: 1.12rem; margin: 0 0 8px; }
.telegram-link-banner p { margin: 0; line-height: 1.5; }
.telegram-link-banner .button { justify-self: start; }
.app-downloads { display: grid; gap: 8px; margin: 10px 0; }
.app-downloads .button { font-size: .85rem; }
.connection-actions .delivery-status { order: 5; }

.promo-form { display: grid; gap: 8px; margin: 16px 0; }
.promo-fields { display: flex; gap: 8px; }
.promo-fields input { min-width: 0; flex: 1; }
.promo-form small { line-height: 1.5; }
