/*
 * Личный кабинет: витрина и корзина, домены, оплата, поддержка, профиль.
 * Только переменные и приёмы из app.css. Подключается на всех страницах — классы с префиксами разделов.
 */

[hidden] { display: none !important; }
.d-block { display: block; }
.only-sm { display: none; }
/* Form::checkbox: «.field > label» из app.css перебивает display:flex у .check — возвращаем отступ между галочкой и текстом. */
.field > label.check { display: flex; font-weight: 400; font-size: 14.5px; margin-bottom: 0; }

/* ---------------------------------------------------------------- витрина */

.plan .price small { font-family: var(--font-ui); font-size: 15px; font-weight: 500; color: var(--text-3); letter-spacing: 0; }
.plan .price small:first-child { margin-right: 2px; }
.plan-spacer { flex: 1 1 auto; min-height: 20px; }
.plan ul { margin-bottom: 0; }
.plan .btn.is-disabled { pointer-events: none; }

/* Переключатель периода и страны над тарифами. */
.showcase-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; margin: -4px 0 18px; }
.period-switch { display: inline-flex; gap: 2px; padding: 3px; border-radius: var(--radius-m); background: var(--muted-bg); max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.period-switch a { display: inline-flex; align-items: center; gap: 6px; padding: 6px 13px; border-radius: var(--radius-s); color: var(--text-2); font-size: 14px; font-weight: 500; white-space: nowrap; }
.period-switch a:hover { text-decoration: none; color: var(--text); }
.period-switch a.is-active { background: var(--surface); color: var(--text); box-shadow: 0 1px 2px rgba(13, 43, 38, .12), 0 0 0 1px var(--line); }
.period-switch .seg-save { font-size: 12px; font-weight: 600; color: var(--ok-ink); font-variant-numeric: tabular-nums; }
.country-filter { display: flex; flex-wrap: wrap; gap: 6px; }
.country-filter a { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px 5px 10px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--surface); color: var(--text-2); font-size: 13.5px; font-weight: 500; }
.country-filter a:hover { text-decoration: none; border-color: var(--text-3); color: var(--text); }
.country-filter a.is-active { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-ink); }
.country-filter a:first-child { padding-left: 12px; }
.showcase-empty { margin-top: 12px; }

/* Карточка тарифа. */
.plan { position: relative; }
.plan.is-featured { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.plan-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 22px; margin-bottom: 12px; color: var(--text-2); font-size: 13.5px; }
.plan-badge { display: inline-block; padding: 1px 9px; border-radius: 999px; background: var(--brand); color: #fff; font-family: var(--font-ui); font-size: 12px; font-weight: 600; line-height: 20px; white-space: nowrap; vertical-align: 2px; }
.plan { container-type: inline-size; }
.plan .plan-price .price { margin-top: 14px; white-space: nowrap; font-size: 28px; font-size: min(28px, 11.5cqi); }
.plan > .plan-top .plan-badge { position: absolute; top: -11px; right: 16px; box-shadow: 0 0 0 3px var(--bg); }
.plan-place { min-width: 0; }
.plan-place .place { max-width: 100%; }
.plan-place .place-name { overflow: hidden; text-overflow: ellipsis; }
.plan-price .per { color: var(--text-3); font-size: 13.5px; }
.plan-save { display: inline-block; margin-left: 4px; padding: 0 7px; border-radius: 999px; background: var(--ok-bg); color: var(--ok-ink); font-size: 12px; font-weight: 600; line-height: 19px; font-variant-numeric: tabular-nums; }
.plan-setup { display: block; }
.specs { margin: 16px 0 0; font-size: 14px; }
.specs > div { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; padding: 7px 0; border-top: 1px solid var(--line); }
.specs > div:last-child { border-bottom: 1px solid var(--line); }
.specs dt { color: var(--text-3); flex: none; }
.specs dd { margin: 0; text-align: right; color: var(--text); font-weight: 500; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.specs + ul { margin-top: 12px; }
.plan-config { display: flex; gap: 7px; align-items: flex-start; margin: 14px 0 0; color: var(--text-2); font-size: 13.5px; }
.plan-config .icon, .cfg-config .icon { width: 15px; height: 15px; flex: none; margin-top: 2px; color: var(--brand-ink); }
.plan-stock { margin: 0 0 8px; color: var(--warn-ink); font-size: 13px; font-weight: 500; }

/* Список конфигураций (выделенные серверы). */
.config-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-m); overflow-x: auto; }
.config-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.config-table thead th { padding: 10px 14px; background: var(--surface-2); border-bottom: 1px solid var(--line); color: var(--text-3); font-size: 12.5px; font-weight: 500; text-align: left; white-space: nowrap; }
.config-table thead th.num { text-align: right; }
.config-table tbody tr + tr { border-top: 1px solid var(--line); }
.config-table tbody th, .config-table tbody td { padding: 14px 12px; vertical-align: middle; text-align: left; font-weight: 400; }
.config-table tbody th { padding-left: 16px; }
.config-table thead th { padding-left: 12px; padding-right: 12px; }
.config-table thead th:first-child { padding-left: 16px; }
.config-table tr.is-featured > th { box-shadow: inset 3px 0 0 var(--brand); }
.cfg-name { width: 24%; min-width: 200px; }
.cfg-spec { min-width: 104px; }
.cfg-place { white-space: nowrap; }
.cfg-spec.is-short { white-space: nowrap; }
.cfg-title { display: block; color: var(--text); font-size: 15.5px; font-weight: 600; }
.cfg-desc { display: block; color: var(--text-2); font-size: 13.5px; margin-top: 2px; }
.cfg-extra { display: block; color: var(--text-3); font-size: 13px; margin-top: 4px; }
.cfg-config { display: flex; gap: 6px; margin-top: 6px; color: var(--text-2); font-size: 13px; }
.cfg-spec { font-variant-numeric: tabular-nums; color: var(--text); }
.cfg-price { text-align: right !important; white-space: nowrap; }
.cfg-price .price { font-family: var(--font-display); font-feature-settings: "tnum" 1, "lnum" 1; font-size: 20px; font-weight: 600; letter-spacing: -.01em; }
.cfg-price .price small { font-family: var(--font-ui); font-size: 13px; font-weight: 500; color: var(--text-3); letter-spacing: 0; }
.cfg-price .per { font-size: 12.5px; }
.cfg-action { text-align: right !important; white-space: nowrap; }
.cfg-action .plan-stock { display: block; margin: 6px 0 0; font-size: 12.5px; }

.cart-bar {
  display: flex; align-items: center; gap: 12px; padding: 11px 16px; margin-bottom: 20px;
  border: 1px solid var(--line); border-left: 3px solid var(--brand); border-radius: var(--radius-s);
  background: var(--surface); color: var(--text); font-size: 14.5px;
}
.cart-bar:hover { text-decoration: none; border-color: var(--line-strong); border-left-color: var(--brand); background: var(--surface-2); }
.cart-bar > .icon { color: var(--brand-ink); }
.cart-bar .go { display: inline-flex; align-items: center; gap: 6px; color: var(--brand-ink); font-weight: 500; white-space: nowrap; }
.cart-bar .go .icon { width: 16px; height: 16px; }

/* ---------------------------------------------------------------- конфигуратор */

.spec-strip { display: flex; flex-wrap: wrap; gap: 0; margin: 14px 0 0; border: 1px solid var(--line); border-radius: var(--radius-m); background: var(--surface); overflow: hidden; }
.spec-strip > div { padding: 9px 16px; border-right: 1px solid var(--line); min-width: 0; }
.spec-strip > div:last-child { border-right: 0; }
.spec-strip dt { color: var(--text-3); font-size: 12.5px; }
.spec-strip dd { margin: 1px 0 0; color: var(--text); font-size: 14.5px; font-weight: 500; font-variant-numeric: tabular-nums; }
.option-stack { display: grid; gap: 22px; }
.opt { border: 0; margin: 0; padding: 0; min-width: 0; }
.opt-name { display: block; padding: 0; margin: 0 0 2px; font-size: 15px; font-weight: 600; color: var(--text); }
.opt-desc { display: block; margin: 0 0 10px; color: var(--text-2); font-size: 13.5px; font-weight: 400; }
.opt-help { margin: 0; color: var(--text-3); font-size: 13px; }
.opt-current { margin: -14px 0 0; }
.summary .money-pos { color: var(--ok-ink); }
.opt > .error { margin-top: 6px; color: var(--danger-ink); font-size: 13.5px; }
.opt legend.opt-name + .choice-cards { margin-top: 10px; }
.choice-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; }
/* Подпись сверху, доплата под ней: длинные названия («2 × 3.84 TB NVMe Samsung PM9A3») не наезжают на цену. */
.choice-card { position: relative; display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: 3px; padding: 11px 14px 12px 40px; border: 1px solid var(--line-strong); border-radius: var(--radius-m); background: var(--surface); cursor: pointer; }
.choice-card:hover { border-color: var(--text-3); }
.choice-card input { position: absolute; left: 14px; top: 13px; width: 16px; height: 16px; margin: 0; accent-color: var(--brand); }
.choice-card:has(input:checked) { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); background: var(--brand-soft); }
.choice-card:has(input:focus-visible) { outline: 2px solid var(--focus); outline-offset: 2px; }
.choice-label { color: var(--text); font-size: 14.5px; font-weight: 500; line-height: 1.35; min-width: 0; max-width: 100%; overflow-wrap: break-word; }
.choice-label .opt-desc { margin: 2px 0 0; }
.choice-price { flex: none; color: var(--text); font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.choice-price.is-zero { color: var(--text-3); font-weight: 400; }
.choice-toggle { flex-direction: row; align-items: center; justify-content: space-between; gap: 12px; }
.choice-toggle input { top: 50%; margin-top: -8px; }
.opt-select { max-width: 520px; }
.opt > .opt-name + .opt-select, .opt > .opt-desc + .opt-select { margin-top: 8px; }

/* «В комплекте»: что входит в тариф без выбора — две колонки «название — значение». */
.kit-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 0 28px; margin: 0; }
.kit-list > div { display: flex; flex-direction: column; gap: 1px; padding: 8px 0 9px; border-bottom: 1px solid var(--line); min-width: 0; }
.kit-list dt { color: var(--text-3); font-size: 13px; }
.kit-list dd { margin: 0; color: var(--text); font-size: 14.5px; font-weight: 500; overflow-wrap: anywhere; }
.kit-extra { color: var(--text-2); font-size: 13px; font-weight: 400; white-space: nowrap; }
.opt-qty { display: flex; align-items: center; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; }
.opt-qty-text { min-width: 0; flex: 1 1 260px; }
.opt-qty .opt-desc { margin-bottom: 2px; }
.opt-qty > .error { flex-basis: 100%; margin-top: 0; }
.stepper { display: inline-flex; align-items: center; gap: 6px; }
.stepper .input { width: 76px; text-align: center; font-variant-numeric: tabular-nums; -moz-appearance: textfield; }
.stepper .input::-webkit-outer-spin-button, .stepper .input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.feature-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 16px; padding: 0; margin: 12px 0 0; color: var(--text-2); font-size: 14px; }
.feature-chips li { display: inline-flex; align-items: center; gap: 6px; }
.feature-chips .icon { width: 15px; height: 15px; color: var(--led-on); }
.period-cards { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
.period-cards .radio-card .meta strong { color: var(--text); font-weight: 600; }
.radio-card .saving {
  display: inline-block; margin-top: 6px; padding: 0 8px; border-radius: 999px; font-size: 12.5px; font-weight: 500; line-height: 21px;
  background: var(--ok-bg); color: var(--ok-ink); white-space: nowrap;
}
.radio-card.is-disabled { cursor: not-allowed; background: var(--surface-2); border-style: dashed; }
.radio-card.is-disabled .title { color: var(--text-2); }
.summary .line > span:first-child { min-width: 0; overflow-wrap: anywhere; }
.summary .line .money { flex: none; }
.summary-free { margin: 2px 0 10px; color: var(--text-3); font-size: 13px; line-height: 1.5; }
.summary-free > span { color: var(--text-2); }
.summary-free ul { display: inline; list-style: none; margin: 0; padding: 0; }
.summary-free li { display: inline; }
.summary-free li:not(:last-child)::after { content: ", "; }
.summary .textarea { min-height: 72px; }
.configure .form-grid > .field.span-2 { grid-column: 1 / -1; }

/* ---------------------------------------------------------------- подбор домена */

.domain-search { margin-bottom: 20px; max-width: 720px; }
.domain-search .input-group .input { height: 46px; font-size: 16px; }
.domain-search .input-group .btn { padding: 0 20px; }
.domain-search .help { color: var(--text-3); font-size: 13px; margin: 8px 0 0; }
.domain-list { list-style: none; margin: 0; padding: 0; }
.domain-row {
  display: grid; grid-template-columns: minmax(0, 1fr) 210px 320px; gap: 8px 22px; align-items: center;
  padding: 14px 18px; border-bottom: 1px solid var(--line);
}
.domain-row:last-child { border-bottom: 0; }
.domain-row:hover { background: var(--row-hover); }
.domain-name strong { font-size: 16px; font-weight: 600; overflow-wrap: anywhere; }
.domain-state { margin-top: 3px; }
.domain-state .status { font-size: 13.5px; color: var(--text-2); white-space: normal; }
.domain-price { text-align: right; font-size: 14px; }
.domain-price strong { font-size: 15px; }
.domain-row.is-taken .domain-name strong, .domain-row.is-taken .domain-price { color: var(--text-3); }
.domain-action { display: flex; justify-content: flex-end; }
.domain-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.domain-form .select { width: 172px; }
.domain-form .input { width: 190px; }
.panel-note { display: flex; gap: 10px; align-items: flex-start; padding: 12px 18px; border-bottom: 1px solid var(--line); background: var(--surface-2); font-size: 14px; color: var(--text-2); }
.panel-note .icon { color: var(--text-3); margin-top: 1px; }

/* ---------------------------------------------------------------- корзина */

.cart-list { list-style: none; margin: 0; padding: 0; }
.cart-item { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px 18px; align-items: start; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.cart-item:last-child { border-bottom: 0; }
.cart-item.has-error { background: color-mix(in srgb, var(--danger-bg) 45%, transparent); }
.cart-title { display: flex; gap: 10px; align-items: center; font-weight: 600; font-size: 15.5px; overflow-wrap: anywhere; }
.cart-title .icon { color: var(--text-3); }
.cart-meta { color: var(--text-2); font-size: 13.5px; margin-top: 4px; padding-left: 28px; }
.cart-meta.muted { color: var(--text-3); }
.cart-meta.cart-need { color: var(--warn-ink); display: flex; gap: 6px; align-items: baseline; flex-wrap: wrap; }
.cart-meta.cart-need .icon { width: 15px; height: 15px; align-self: center; }
.cart-price { font-weight: 600; font-size: 15.5px; padding-top: 1px; }
.cart-remove { margin-top: -5px; }
.cart-error { display: flex; gap: 8px; align-items: flex-start; margin: 8px 0 0 28px; color: var(--danger-ink); font-size: 13.5px; }
.cart-error .icon { width: 16px; height: 16px; margin-top: 2px; }
.cart-contact { margin: 10px 0 0 28px; }
.cart-contact label { display: block; margin-bottom: 4px; }
.cart-contact .select { width: auto; min-width: 220px; max-width: 100%; }

/* ---------------------------------------------------------------- счета и оплата */

.panel-accent { border-color: var(--info-line); }
.panel-accent > .panel-head { background: var(--info-bg); color: var(--info-ink); border-bottom-color: var(--info-line); border-radius: var(--radius-m) var(--radius-m) 0 0; }
.panel-accent > .panel-head h2 { color: var(--info-ink); display: flex; gap: 8px; align-items: center; }
.instructions p:last-child { margin-bottom: 0; }
.pay-amount { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.pay-amount strong { font-family: var(--font-display); font-feature-settings: "tnum" 1, "lnum" 1; font-size: 26px; font-weight: 600; }
/* Страница счёта: способы оплаты плитками (название и сумма в валюте способа), сводка выбранного способа справа */
.pay-tiles { grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 8px; }
.radio-card.pay-tile { display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 9px 14px 9px 40px; }
.radio-card.pay-tile input { top: calc(50% - 8px); }
.pay-tile .pay-method-icon { width: 40px; height: 30px; }
.pay-tile .pay-method-icon img { max-width: 32px; max-height: 24px; }
.pay-tile-title { flex: 1 1 auto; min-width: 0; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.pay-tile-sum { flex: none; font-feature-settings: "tnum" 1, "lnum" 1; font-weight: 600; color: var(--text-2); white-space: nowrap; }
.radio-card.pay-tile:has(input:checked) .pay-tile-sum { color: var(--text); }
.pay-summary .total .value { font-size: 26px; }
.pay-summary .pay-rate { color: var(--text-3); font-size: 13px; text-align: right; margin-top: 2px; }
.pay-summary .btn-block { margin-top: 16px; }
.pay-about { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 13px; color: var(--text-2); line-height: 1.5; }
.pay-about strong { display: block; color: var(--text); font-weight: 600; }
.pay-about p { margin: 2px 0 0; }
.topup-methods { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
/* Способ оплаты с иконкой (загруженной сотрудником) или встроенным значком */
.radio-card.pay-method { display: flex; align-items: flex-start; gap: 12px; }
.pay-method-icon { flex: 0 0 auto; width: 48px; height: 34px; display: flex; align-items: center; justify-content: center; border-radius: 8px; background: var(--surface-2); overflow: hidden; }
.pay-method-icon img { max-width: 40px; max-height: 28px; width: auto; height: auto; display: block; }
.pay-method-icon .icon { width: 22px; height: 22px; color: var(--text-2); }
.pay-method-text { min-width: 0; flex: 1 1 auto; }
.pay-jump { display: none !important; }
@media (max-width: 1100px) { .pay-jump { display: inline-flex !important; } }
.invoice-items tfoot td { border-bottom: 0; }
.invoice-items tfoot .tax-row td { font-weight: 400; font-size: 13.5px; color: var(--text-2); border-top: 0; padding-top: 0; }
.invoice-items tfoot tr:last-child td:first-child { border-bottom-left-radius: var(--radius-m); }
.invoice-items tfoot tr:last-child td:last-child { border-bottom-right-radius: var(--radius-m); }
.table tr.is-muted td { color: var(--text-3); }
.table tr.is-attention td:first-child { box-shadow: inset 3px 0 0 var(--led-on); }
.kv-aside { grid-template-columns: max-content minmax(0, 1fr); }
.kv-aside dd { text-align: right; }
.kv-aside .rel { display: block; color: var(--text-3); font-size: 12.5px; }
.kv-aside .rel.is-soon { color: var(--warn-ink); }
.kv-aside .rel.is-late { color: var(--danger-ink); }

.quick-amounts { display: flex; flex-wrap: wrap; gap: 8px; margin: -6px 0 6px; }
.chip { display: inline-flex; align-items: center; height: 30px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: 999px; color: var(--text-2); font-size: 13.5px; background: var(--surface); }
.chip:hover { text-decoration: none; border-color: var(--text-3); color: var(--text); }

/* Возврат из платёжной системы */
.pay-result { text-align: center; padding: 8px 0 4px; }
.pay-result h1 { font-family: var(--font-display); font-size: 28px; font-weight: 600; margin: 14px 0 8px; }
.pay-result > p { max-width: 52ch; margin-left: auto; margin-right: auto; }
.pay-result-icon { width: 56px; height: 56px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--muted-bg); color: var(--muted-ink); }
.pay-result-icon .icon { width: 28px; height: 28px; }
.pay-result-ok .pay-result-icon { background: var(--ok-bg); color: var(--ok-ink); }
.pay-result-wait .pay-result-icon { background: var(--warn-bg); color: var(--warn-ink); }
.pay-result-warn .pay-result-icon { background: var(--warn-bg); color: var(--warn-ink); }
.pay-result-bad .pay-result-icon { background: var(--danger-bg); color: var(--danger-ink); }
.pay-result-details { max-width: 420px; margin: 20px auto 8px; text-align: left; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius-m); background: var(--surface); }
.pay-result .form-actions { justify-content: center; margin-top: 18px; }

/* ---------------------------------------------------------------- домены */

.ns-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }

/* ---------------------------------------------------------------- поддержка */

.input-file { height: auto; padding: 8px 10px; font-size: 14px; }
.input-file::file-selector-button {
  margin-right: 12px; height: 30px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: 6px;
  background: var(--surface-2); color: var(--text); font: 500 13.5px var(--font-ui); cursor: pointer;
}
.field > label .icon { width: 15px; height: 15px; color: var(--text-3); vertical-align: -2px; }
.msg-head { flex-wrap: wrap; row-gap: 2px; }
.msg-head time { white-space: nowrap; }
.msg-files a:hover { text-decoration: none; border-color: var(--line-strong); color: var(--text); }

/* ---------------------------------------------------------------- профиль */

.link-list { list-style: none; margin: 0; padding: 0; }
.link-list li + li { border-top: 1px solid var(--line); }
.link-list a { display: flex; align-items: center; gap: 12px; padding: 14px 18px; color: var(--text); font-weight: 500; }
.link-list a:hover { background: var(--row-hover); text-decoration: none; }
.link-list a > .icon:first-child { color: var(--text-3); }
.link-list .count { font-size: 12px; font-weight: 600; background: var(--muted-bg); color: var(--muted-ink); padding: 1px 8px; border-radius: 999px; }
.link-list a:first-child { border-radius: var(--radius-m) var(--radius-m) 0 0; }
.link-list li:last-child a { border-radius: 0 0 var(--radius-m) var(--radius-m); }

/* ---------------------------------------------------------------- адаптив */

@media (max-width: 900px) {
  .domain-row { grid-template-columns: minmax(0, 1fr) auto; }
  .domain-action { grid-column: 1 / -1; justify-content: flex-start; }
  .domain-form { justify-content: flex-start; }
}
@media (max-width: 640px) {
  .only-sm { display: inline; }
  .cart-bar { flex-wrap: wrap; }
  .cart-bar .go { width: 100%; padding-left: 30px; }
  .domain-search .input-group .btn span { display: none; }
  .domain-row { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .domain-price { text-align: left; }
  .domain-form { width: 100%; }
  .domain-form .input { flex: 1 1 100%; width: 100%; min-width: 0; }
  .domain-form .select { flex: 1 1 150px; width: auto; min-width: 0; }
  .domain-form .btn { flex: 0 0 auto; }
  .cart-item { grid-template-columns: minmax(0, 1fr) auto; }
  .cart-remove { grid-column: 1 / -1; margin: 0 0 0 20px; }
  .cart-contact { margin-left: 0; }
  .cart-contact .select { min-width: 0; width: 100%; }
  .cart-meta, .cart-error { padding-left: 0; margin-left: 0; }
  .period-cards { grid-template-columns: minmax(0, 1fr); }
  .pay-result h1 { font-size: 24px; }
  .kv-aside { grid-template-columns: max-content minmax(0, 1fr); gap: 8px 12px; }
  .kv-aside dd { margin-bottom: 0; }
}

/* ---------------------------------------------------------------- VNC-консоль */
.console-page { display: flex; flex-direction: column; height: 100vh; background: var(--bg); }
.console-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 10px 16px; border-bottom: 1px solid var(--line); background: var(--surface); }
.console-title { display: flex; align-items: center; gap: 10px; min-width: 0; flex-wrap: wrap; }
.console-status { color: var(--text-2); font-size: 13.5px; }
.console-screen { flex: 1; min-height: 0; background: #0d1416; overflow: hidden; }
.console-page:fullscreen .console-screen { background: #000; }
.console-foot { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 8px 16px; font-size: 13px; border-top: 1px solid var(--line); background: var(--surface); }
.console-manual { padding: 24px 16px; max-width: 640px; width: 100%; margin: 0 auto; }
.pay-note { color: var(--brand-ink); }

/* Выбор «кто платит»: частное лицо / организация / ИП */
.segmented { display: flex; flex-wrap: wrap; gap: 6px; }
.segmented .check { border: 1px solid var(--line-strong); border-radius: 8px; padding: 6px 12px; margin: 0; cursor: pointer; }
.segmented .check:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
/* Подсказка автозаполнения по ИНН/БИК */
.lookup-hint { font-size: 13px; margin-top: 4px; color: var(--text-2); }
.lookup-hint.is-ok { color: var(--success-ink, var(--brand-ink)); }
.lookup-hint.is-warn { color: var(--danger-ink); }
.lookup-hint.is-busy::after { content: ' …'; }

@media (max-width: 860px) {
  .config-wrap { background: transparent; border: 0; overflow: visible; }
  .config-table, .config-table tbody { display: block; }
  .config-table thead { display: none; }
  .config-table tbody tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0 12px; padding: 16px; margin-bottom: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-m); }
  .config-table tbody tr + tr { border-top: 1px solid var(--line); }
  .config-table tr.is-featured { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
  .config-table tr.is-featured > th { box-shadow: none; }
  .config-table tbody th, .config-table tbody td { padding: 0; }
  .cfg-name { grid-column: 1 / -1; min-width: 0; margin-bottom: 10px; }
  .cfg-spec, .cfg-place { grid-column: 1 / -1; display: flex; justify-content: space-between; gap: 14px; padding: 7px 0 !important; border-top: 1px solid var(--line); }
  .cfg-spec::before, .cfg-place::before { content: attr(data-label); color: var(--text-3); }
  .cfg-spec { text-align: right !important; }
  .cfg-price { text-align: left !important; padding-top: 12px !important; border-top: 1px solid var(--line); }
  .cfg-action { display: flex; flex-direction: column; align-items: flex-end; justify-content: center; padding-top: 12px !important; border-top: 1px solid var(--line); }
}
@media (max-width: 640px) {
  .showcase-bar { flex-direction: column; align-items: stretch; }
  .period-switch { align-self: flex-start; }
}
@media (max-width: 640px) {
  .spec-strip { display: block; }
  .spec-strip > div { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; padding: 8px 14px; border-right: 0; border-bottom: 1px solid var(--line); }
  .spec-strip > div:last-child { border-bottom: 0; }
  .spec-strip dd { margin: 0; text-align: right; }
  .place-line { flex-wrap: wrap; gap: 4px 8px; }
}


/* ---------------------------------------------------------------- главная кабинета */

.dash { display: grid; grid-template-columns: minmax(0, 1fr) clamp(300px, 26vw, 400px); gap: 20px; align-items: start; }
.dash .stack > * + * { margin-top: 20px; }
.dash-promos { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.dash-promos:not(:has(> .promo:not([hidden]))) { display: none; }
.wallet { grid-template-columns: minmax(0, 1fr); padding: 22px 24px; }
.wallet.has-next { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 20px 32px; align-items: stretch; }
.wallet-main { display: flex; flex-direction: column; min-width: 0; }
.wallet-status { display: flex; gap: 8px; align-items: flex-start; margin-top: 12px; padding: 10px 12px; border-radius: var(--radius-s); font-size: 14px; line-height: 1.45; }
.wallet-status .icon { width: 17px; height: 17px; flex: none; margin-top: 1px; }
.wallet-status.is-ok { background: var(--ok-bg); color: var(--ok-ink); }
.wallet-status.is-warn { background: var(--warn-bg); color: var(--warn-ink); }
.wallet-status.is-calm { background: var(--surface-2); color: var(--text-2); }
.wallet-status strong { font-weight: 600; }
.wallet-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; padding-top: 16px; }
.wallet-next { min-width: 0; border-left: 1px solid var(--line); padding-left: 28px; }
.wallet-next-head { display: flex; justify-content: space-between; gap: 10px; font-weight: 600; font-size: 14.5px; margin-bottom: 6px; }
.wallet-next-head .muted { font-weight: 400; font-size: 13px; }
.wallet-next ul { list-style: none; margin: 0; padding: 0; }
.wallet-next li { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto 112px; gap: 10px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.wallet-next li:last-child { border-bottom: 0; }
.wn-date { color: var(--text-2); font-variant-numeric: tabular-nums; font-weight: 500; }
.wn-title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wn-title a { color: var(--text); }
.wn-title a:hover { color: var(--brand-ink); }
.wn-sum { font-variant-numeric: tabular-nums; text-align: right; font-weight: 500; }
.wn-state { display: inline-flex; align-items: center; justify-content: flex-end; gap: 5px; font-size: 12.5px; white-space: nowrap; }
.wn-state .icon { width: 14px; height: 14px; }
.is-covered .wn-state { color: var(--ok-ink); }
.is-uncovered .wn-state { color: var(--danger-ink); }
.wallet-next-more { color: var(--text-3); font-size: 13px; padding-top: 8px; }

/* Главная: баланс — в правой колонке (услуги — первыми в основной), ближайшие списания — под ним. */
.wallet.wallet-side { padding: 20px; gap: 0; }
.wallet-side .amount { font-size: 34px; }
.wallet-side .wallet-actions { gap: 4px; }
.wallet-side .wallet-actions .btn { flex: 1 1 100%; justify-content: center; }
.wallet-side .wallet-next { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); padding-top: 14px; margin-top: 18px; }
.wallet-side .wallet-next li { grid-template-columns: 40px minmax(0, 1fr) auto 16px; gap: 8px; }
.wallet-side .wn-state span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }

/* Новый клиент без услуг: три шага вместо пустого списка. */
.start-steps { list-style: none; margin: 0; padding: 20px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.start-steps li { display: flex; gap: 12px; align-items: flex-start; min-width: 0; }
.start-icon { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 12px; background: var(--brand-soft); color: var(--brand-ink); }
.start-icon .icon { width: 20px; height: 20px; }
.start-steps strong { display: block; font-weight: 600; }
.start-steps p { margin: 4px 0 0; color: var(--text-2); font-size: 14px; line-height: 1.5; }

.count-pill { display: inline-block; min-width: 20px; margin-left: 6px; padding: 0 6px; border-radius: 999px; background: var(--brand); color: #fff; font-size: 12px; font-weight: 600; line-height: 20px; text-align: center; vertical-align: 2px; }
.mini-list { list-style: none; margin: 0; padding: 0; }
.mini-list li { padding: 12px 20px; border-bottom: 1px solid var(--line); }
.mini-list li:last-child { border-bottom: 0; }
.mini-list li.is-new { box-shadow: inset 3px 0 0 var(--brand); background: color-mix(in srgb, var(--brand-soft) 45%, var(--surface)); }
.mini-title { display: block; font-weight: 500; color: var(--text); overflow-wrap: anywhere; }
.mini-title:hover { color: var(--brand-ink); }
.mini-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 4px; font-size: 13px; }
.news-mini .mini-meta { margin: 0 0 3px; font-size: 12.5px; }
.mini-text { color: var(--text-2); font-size: 13.5px; margin-top: 2px; }
.news-mini li.is-important { box-shadow: inset 3px 0 0 var(--warn-ink); }

/* Промо-карточка: заголовок, текст, кнопка; цвет — из «Новости и промо». */
.promo { position: relative; padding: 20px 22px 22px; border-radius: var(--radius-l); overflow: hidden; color: var(--promo-ink); background: var(--promo-bg); border: 1px solid var(--promo-line); }
.promo::after { content: ""; position: absolute; right: -40px; bottom: -60px; width: 180px; height: 180px; border-radius: 50%; background: var(--promo-glow); pointer-events: none; }
.promo > * { position: relative; z-index: 1; }
.promo-blue { --promo-bg: linear-gradient(135deg, #eaf1ff, #f5f8ff); --promo-ink: #10264f; --promo-line: #d3e1fd; --promo-accent: #1f66f2; --promo-glow: rgba(31, 102, 242, .12); }
.promo-green { --promo-bg: linear-gradient(135deg, #e5f6ec, #f4fbf7); --promo-ink: #0f3a24; --promo-line: #c6e8d4; --promo-accent: #16774a; --promo-glow: rgba(22, 119, 74, .12); }
.promo-violet { --promo-bg: linear-gradient(135deg, #efe9ff, #f8f5ff); --promo-ink: #2a1659; --promo-line: #ddd2fb; --promo-accent: #6a3fd8; --promo-glow: rgba(106, 63, 216, .13); }
.promo-amber { --promo-bg: linear-gradient(135deg, #fff2d6, #fffaf0); --promo-ink: #4a3000; --promo-line: #f4dfae; --promo-accent: #b26b00; --promo-glow: rgba(224, 155, 18, .16); }
.promo-dark { --promo-bg: linear-gradient(135deg, #152036, #1f2d4a); --promo-ink: #eef3ff; --promo-line: #26344f; --promo-accent: #6a9dff; --promo-glow: rgba(106, 157, 255, .18); }
.promo-icon { display: inline-flex; width: 40px; height: 40px; border-radius: 11px; align-items: center; justify-content: center; background: color-mix(in srgb, var(--promo-accent) 14%, transparent); color: var(--promo-accent); margin-bottom: 12px; }
.promo-icon .icon { width: 20px; height: 20px; }
.promo-badge { position: absolute; top: 18px; right: 52px; padding: 2px 10px; border-radius: 999px; background: var(--promo-accent); color: #fff; font-size: 12.5px; font-weight: 600; line-height: 20px; }
.promo-title { font-family: var(--font-display); font-size: 20px; font-weight: 600; letter-spacing: -.015em; line-height: 1.25; color: inherit; padding-right: 40px; }
.promo-text { margin: 8px 0 0; font-size: 14px; line-height: 1.5; opacity: .85; }
.promo-btn { margin-top: 16px; background: var(--promo-accent); color: #fff; }
.promo-btn:hover { filter: brightness(1.08); color: #fff; }
.promo-btn .icon { width: 16px; height: 16px; }
.promo-close { position: absolute; top: 12px; right: 12px; z-index: 2; width: 30px; height: 30px; border: 0; border-radius: 8px; background: transparent; color: inherit; opacity: .5; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.promo-close:hover { opacity: 1; background: color-mix(in srgb, var(--promo-accent) 12%, transparent); }
.promo-close .icon { width: 16px; height: 16px; }

/* Новости */
.news-list { list-style: none; margin: 0; padding: 0; }
.news-list li { border-bottom: 1px solid var(--line); }
.news-list li:last-child { border-bottom: 0; }
.news-list li.is-important { box-shadow: inset 3px 0 0 var(--warn-ink); }
.news-item { display: flex; flex-direction: column; gap: 4px; padding: 16px 20px; color: var(--text); }
.news-item:hover { background: var(--row-hover); text-decoration: none; }
.news-item:hover .news-title { color: var(--brand-ink); }
.news-date { color: var(--text-3); font-size: 13px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.news-title { font-weight: 600; font-size: 16px; }
.news-excerpt { color: var(--text-2); font-size: 14px; }
.news-article h1 { font-family: var(--font-display); font-size: 28px; font-weight: 600; letter-spacing: var(--display-tracking); margin: 8px 0 16px; line-height: 1.2; }
.news-body { font-size: 15.5px; line-height: 1.7; max-width: 70ch; overflow-wrap: anywhere; }

@media (max-width: 1100px) {
  /* Одна колонка: услуги, затем баланс, потом остальное. */
  .dash { display: flex; flex-direction: column; align-items: stretch; gap: 20px; }
  .dash-main, .dash-side { display: contents; }
  .dash .stack > * + * { margin-top: 0; }
  .dash-main > :first-child { order: -2; }
  .dash-side > .wallet { order: -1; }
  .start-steps { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .wallet.has-next { grid-template-columns: minmax(0, 1fr); }
  .wallet-next { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); padding-top: 14px; }
}
@media (min-width: 760px) and (max-width: 1100px) {
  .wallet-side:has(.wallet-next) { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 20px 32px; align-items: stretch; }
  .wallet-side .wallet-next { border-top: 0; padding-top: 0; margin-top: 0; border-left: 1px solid var(--line); padding-left: 28px; }
}
@media (max-width: 640px) {
  .wallet-next li { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .wallet-side .wallet-next li { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .wn-state span { display: none; }
  .wn-state { grid-column: 3; grid-row: 1; display: none; }
  .is-uncovered .wn-sum { color: var(--danger-ink); }
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .promo:not(.promo-dark) { --promo-bg: color-mix(in srgb, var(--promo-accent) 16%, var(--surface)); --promo-ink: var(--text); --promo-line: color-mix(in srgb, var(--promo-accent) 30%, var(--line)); }
}
:root[data-theme="dark"] .promo:not(.promo-dark) { --promo-bg: color-mix(in srgb, var(--promo-accent) 16%, var(--surface)); --promo-ink: var(--text); --promo-line: color-mix(in srgb, var(--promo-accent) 30%, var(--line)); }
/* Колонка «Ближайшие списания» — рядом с балансом, только если хватает места. */
.dash-main { container-type: inline-size; }
.promo-title { text-wrap: balance; }
@container (max-width: 860px) {
  .wallet.has-next { grid-template-columns: minmax(0, 1fr); }
  .wallet-next { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); padding-top: 14px; }
}

/* Корзина: скидки и промокод */
.cart-old { display: block; color: var(--text-3); font-size: 13px; font-weight: 400; }
.cart-discount { display: inline-block; margin-left: 6px; padding: 0 7px; border-radius: 999px; background: var(--ok-bg); color: var(--ok-ink); font-size: 12px; font-weight: 600; line-height: 19px; vertical-align: 1px; }
.cart-price { text-align: right; }
.cart-saved { color: var(--ok-ink); }
.promo-box { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line); }
.promo-form { margin-top: 8px; }
.promo-form .input-group .btn { height: 34px; }
.promo-applied { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.promo-chip { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; background: var(--ok-bg); color: var(--ok-ink); font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 13px; font-weight: 600; }
.promo-chip .icon { width: 13px; height: 13px; }
.hint.is-warn { background: var(--warn-bg); color: var(--warn-ink); }

/* Баланс и платежи (v23): карточка баланса с фактами, незавершённые платежи, компактное пополнение, последние операции */
.wallet.wallet-page { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px 32px; align-items: stretch; }
.wallet-facts { display: flex; flex-direction: column; justify-content: center; gap: 12px; border-left: 1px solid var(--line); padding-left: 28px; min-width: 0; }
.wallet-facts > div { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; font-size: 14px; }
.wallet-facts > div > .muted:first-child { flex: 1 1 100%; font-size: 13px; }
.wallet-facts strong { font-weight: 600; font-size: 15px; }
@media (max-width: 760px) {
  .wallet.wallet-page { grid-template-columns: minmax(0, 1fr); }
  .wallet-facts { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); padding-top: 16px; }
}
.pending-list { list-style: none; margin: 0; padding: 0 20px; }
.pending-list li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 20px; padding: 14px 0; border-top: 1px solid var(--line); }
.pending-list li:first-child { border-top: 0; }
.pending-text { min-width: 0; flex: 1 1 320px; font-size: 14.5px; }
.pending-text strong { font-size: 16px; }
.pending-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.pending-actions form { display: inline; }
.topup-form .topup-amount { max-width: 420px; }
.topup-form .topup-amount .field { margin-bottom: 8px; }
.topup-form .topup-amount .input { font-size: 20px; font-weight: 600; height: 48px; font-feature-settings: "tnum" 1; }
.topup-form .topup-amount .input-group .addon { font-size: 16px; }
.topup-form .quick-amounts { margin: 0 0 18px; }
.chip { cursor: pointer; font-family: inherit; }
.chip.chip-accent { border-color: var(--brand); color: var(--brand); }
.topup-methods-field { margin: 0 0 16px; }
.topup-methods-field > .label { display: block; margin-bottom: 8px; }
/* Карточки способов одного размера (по самой высокой), описание — целиком, без обрезки. */
.topup-methods { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); grid-auto-rows: 1fr; gap: 10px; }
.radio-card.pay-method { padding: 12px 14px 12px 40px; }
.pay-method .meta { font-size: 13px; }
.topup-submit { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.ops-list { list-style: none; margin: 0; padding: 0 20px; }
.ops-list li { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 11px 0; border-top: 1px solid var(--line); }
.ops-list li:first-child { border-top: 0; }
.ops-text { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ops-title { font-size: 14px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ops-sum { flex: none; font-weight: 600; font-feature-settings: "tnum" 1; white-space: nowrap; }
.ops-text .secondary { font-size: 12.5px; color: var(--text-3); line-height: 1.4; }
.ops-list + .panel-foot { display: flex; gap: 8px; flex-wrap: wrap; }

/* Переключатель языка в шапке */
.lang-menu summary { display: inline-flex; align-items: center; gap: 6px; }
.lang-menu summary .flag, .lang-menu .menu-pop .flag { width: 20px; height: 15px; border-radius: 2px; flex: none; }
.lang-menu .menu-pop a { display: flex; align-items: center; gap: 10px; }
.lang-menu .menu-pop a.is-active { font-weight: 600; }

/* Выбор языка на страницах входа и регистрации: строка ссылок под формой. */
.auth-langs { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-top: 34px; max-width: 400px; font-size: 14px; }
.auth-langs a { display: inline-flex; align-items: center; gap: 7px; color: var(--text-2); text-decoration: none; padding: 4px 0; border-bottom: 1px solid transparent; }
.auth-langs a:hover { color: var(--text); }
.auth-langs a.is-active { color: var(--text); font-weight: 600; cursor: default; }
.auth-langs .flag { width: 18px; height: 13px; border-radius: 2px; }

/* ---------- Страница услуги: карточка сервера ----------
 * Табличка сервера: светодиод питания и IP крупным моноширинным шрифтом — то, что клиент копирует чаще всего;
 * под ней система, ход текущего действия и полоса характеристик, как передняя панель стойки. */
/* Без overflow: hidden — иначе меню «Другие действия» обрезается краем карточки; углы скругляет последний блок. */
.srv { overflow: visible; }
.srv > .srv-specs:last-child { border-bottom-left-radius: calc(var(--radius-m) - 1px); border-bottom-right-radius: calc(var(--radius-m) - 1px); }
.srv-head { display: flex; align-items: center; justify-content: space-between; gap: 14px 20px; flex-wrap: wrap; padding: 18px 20px 12px; }
.srv-ident { display: flex; align-items: center; gap: 14px; min-width: 0; }
.srv-ident-text { min-width: 0; }
.srv-led { width: 12px; height: 12px; border-radius: 50%; flex: none; background: var(--led-idle); box-shadow: 0 0 0 4px color-mix(in srgb, var(--led-idle) 18%, transparent); }
.srv-led.led-on { background: var(--led-on); box-shadow: 0 0 0 4px color-mix(in srgb, var(--led-on) 18%, transparent), 0 0 14px color-mix(in srgb, var(--led-on) 60%, transparent); }
.srv-led.led-off { background: var(--led-off); box-shadow: 0 0 0 4px color-mix(in srgb, var(--led-off) 16%, transparent); }
.srv-led.led-wait { background: var(--led-wait); box-shadow: 0 0 0 4px color-mix(in srgb, var(--led-wait) 18%, transparent); }
.srv-state { font-size: 13.5px; font-weight: 500; color: var(--text-2); }
.srv-state a { margin-left: 4px; }
.srv-ip { display: flex; align-items: center; gap: 4px; margin-top: 1px; }
.srv-ip code { font: 600 22px/1.25 ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace; letter-spacing: -.02em; color: var(--text); background: none; padding: 0; border: 0; overflow-wrap: anywhere; }
.srv-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.srv-actions form { margin: 0; }
.srv-more > summary { list-style: none; }
.srv-more > summary::-webkit-details-marker { display: none; }
.srv-more .menu-pop { right: 0; left: auto; min-width: 250px; }
.srv-more .menu-pop form { margin: 0; }
.srv.is-busy [data-op-actions] { opacity: .5; pointer-events: none; }
.srv-meta { display: flex; align-items: center; gap: 7px; margin-top: 4px; color: var(--text-2); font-size: 14px; }
.srv-meta .icon { width: 15px; height: 15px; color: var(--text-3); flex: none; }
.srv-meta .srv-os-logo { width: 18px; height: 18px; object-fit: contain; flex: none; }
.srv-head { padding-bottom: 16px; }
.srv-error { margin: 0; padding: 0 20px 14px 46px; color: var(--text-2); font-size: 14px; }
.srv-lock { display: flex; gap: 12px; align-items: flex-start; margin: 2px 20px 16px; padding: 14px 16px; border-radius: var(--radius-s); background: var(--danger-bg); color: var(--danger-ink); font-size: 14.5px; }
.srv-lock > .icon { margin-top: 2px; flex: none; }
.srv-lock p { margin: 0 0 10px; }
.srv-lock .text-2 { color: inherit; opacity: .85; }

.srv-specs { display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); margin: 0; border-top: 1px solid var(--line); background: var(--surface-2); }
.srv-specs .spec { padding: 14px 20px 16px; border-left: 1px solid var(--line); min-width: 0; }
.srv-specs .spec:first-child { border-left: 0; }
.srv-specs dt { font-size: 12.5px; color: var(--text-3); margin-bottom: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.srv-specs dd { margin: 0; display: flex; align-items: baseline; gap: 5px; flex-wrap: wrap; }
.spec-num { font: 600 26px/1.1 var(--font-display); letter-spacing: var(--display-tracking); color: var(--text); font-variant-numeric: tabular-nums; }
.spec-unit { font-size: 13.5px; font-weight: 500; color: var(--text-2); }
.srv-specs-skeleton .spec i { display: block; height: 28px; width: 64%; border-radius: 6px; background: linear-gradient(90deg, var(--line) 0%, var(--surface) 50%, var(--line) 100%); background-size: 200% 100%; animation: srv-shimmer 1.4s ease-in-out infinite; }
.srv-rows { padding: 14px 20px; border-top: 1px solid var(--line); }
.srv-foot { display: flex; gap: 6px 12px; align-items: center; flex-wrap: wrap; padding: 12px 20px; border-top: 1px solid var(--line); }

/* Ход действия: синяя полоса с таймером и бегущей линией, итог — зелёный, жёлтый или красный. */
.srv-op { position: relative; display: flex; align-items: flex-start; gap: 10px; margin: 0 20px 16px; padding: 11px 14px 13px; border-radius: var(--radius-s); background: var(--info-bg); color: var(--info-ink); font-size: 14.5px; overflow: hidden; }
.srv-op[hidden] { display: none; }
.srv-op-text { flex: 1; min-width: 0; }
.srv-op-note { display: block; margin-top: 3px; font-size: 13px; opacity: .85; }
.srv-op-time { font-size: 13px; font-variant-numeric: tabular-nums; opacity: .8; padding-top: 1px; }
.srv-op-icon { position: relative; width: 16px; height: 16px; flex: none; margin-top: 2px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: srv-spin .8s linear infinite; }
.srv-op.is-done { background: var(--ok-bg); color: var(--ok-ink); }
.srv-op.is-failed { background: var(--danger-bg); color: var(--danger-ink); }
.srv-op.is-unconfirmed { background: var(--warn-bg); color: var(--warn-ink); }
.srv-op.is-done .srv-op-icon, .srv-op.is-failed .srv-op-icon, .srv-op.is-unconfirmed .srv-op-icon { animation: none; border: 0; border-radius: 0; }
.srv-op.is-done .srv-op-icon::after { content: ""; position: absolute; left: 5px; top: 1px; width: 5px; height: 10px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.srv-op.is-failed .srv-op-icon::before, .srv-op.is-failed .srv-op-icon::after { content: ""; position: absolute; left: 7px; top: 1px; width: 2px; height: 14px; background: currentColor; transform: rotate(45deg); }
.srv-op.is-failed .srv-op-icon::after { transform: rotate(-45deg); }
.srv-op.is-unconfirmed .srv-op-icon::after { content: "!"; position: absolute; inset: 0; font: 700 14px/16px var(--font-ui); text-align: center; }
.srv-op-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; overflow: hidden; }
.srv-op-bar i { position: absolute; top: 0; bottom: 0; left: -35%; width: 35%; border-radius: 2px; background: currentColor; opacity: .45; animation: srv-slide 1.6s ease-in-out infinite; }
@keyframes srv-spin { to { transform: rotate(360deg); } }
@keyframes srv-slide { from { left: -35%; } to { left: 100%; } }
@keyframes srv-shimmer { from { background-position: 100% 0; } to { background-position: -100% 0; } }
@media (prefers-reduced-motion: reduce) {
  .srv-op-icon { animation-duration: 2.4s; }
  .srv-op-bar i { animation: none; left: 0; width: 100%; opacity: .25; }
  .srv-specs-skeleton .spec i { animation: none; }
}

/* Доступ: команда SSH одной строкой, чтобы скопировать и вставить в терминал. */
.access code.cmd { font-size: 13.5px; padding: 3px 8px; }

/* Оплата: сумма крупно, полоса оплаченного периода — сколько осталось. */
.bill-price { display: flex; align-items: baseline; gap: 4px 8px; flex-wrap: wrap; margin-bottom: 14px; }
.bill-amount { font: 600 28px/1.1 var(--font-display); letter-spacing: var(--display-tracking); font-variant-numeric: tabular-nums; }
.bill-period { margin-bottom: 14px; }
.bill-period-row { display: flex; justify-content: space-between; align-items: baseline; gap: 4px 10px; flex-wrap: wrap; font-size: 14px; margin-bottom: 8px; }
.bill-period-row .warn { color: var(--warn-ink); font-weight: 500; }
.bill-meter { height: 6px; border-radius: 3px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.bill-meter i { display: block; height: 100%; border-radius: 3px; background: var(--brand); }
.bill-meter.is-low i { background: var(--led-wait); }
.bill-kv, .conf-kv { grid-template-columns: max-content minmax(0, 1fr); gap: 8px 14px; font-size: 14px; }
.bill-kv dd, .conf-kv dd { text-align: right; }
.conf-kv { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); }
.bill .panel-foot .led { vertical-align: 1px; margin-right: 2px; }

/* Последние действия с сервером. */
.svc-ops { list-style: none; margin: 0; padding: 2px 0 10px; }
.svc-ops li { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 7px 20px; font-size: 14px; }
.svc-ops-mark { display: inline-flex; }
.svc-ops-mark .icon { width: 15px; height: 15px; }
.svc-ops .is-done .svc-ops-mark { color: var(--led-on); }
.svc-ops .is-failed .svc-ops-mark { color: var(--led-off); }
.svc-ops .is-unconfirmed .svc-ops-mark { color: var(--led-wait); }
.svc-ops .is-progress .svc-ops-mark { color: var(--text-3); }
.svc-ops-when { color: var(--text-3); font-size: 13px; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Переустановка и отказ: строки с пояснением и кнопкой справа, форма раскрывается под строкой. */
.zone .panel-head { border-bottom: 0; }
.zone-row { border-top: 1px solid var(--line); }
.zone-row > summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px 18px; padding: 15px 20px; cursor: pointer; }
.zone-row > summary::-webkit-details-marker { display: none; }
.zone-row > summary:hover .btn { background: var(--surface-2); border-color: var(--text-3); }
.zone-row > summary:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.zone-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.zone-text strong { font-size: 14.5px; font-weight: 600; }
.zone-text span { color: var(--text-2); font-size: 13.5px; }
.zone-row > summary .btn { flex: none; pointer-events: none; }
.zone-row[open] > summary .btn { background: var(--surface-2); }
.zone-form { padding: 2px 20px 20px; }
/* Отказ от услуги: варианты — заголовок и пояснение отдельными строками, с воздухом; кнопка первого шага — красная, как итоговая. */
.cancel-options { gap: 12px; margin-bottom: 20px; }
.cancel-options .radio-card { padding: 14px 16px 14px 42px; }
.cancel-options .radio-card .title { display: block; margin-bottom: 4px; }
.cancel-options .radio-card .meta { display: block; line-height: 1.45; }
.zone-row > summary:hover .btn-danger, .zone-row[open] > summary .btn-danger { background: var(--danger-bg); border-color: var(--danger-line); }
@media (max-width: 720px) {
  .zone-row > summary { flex-direction: column; align-items: flex-start; }
  .srv-error { padding-left: 20px; }
  .srv-ip code { font-size: 19px; }
  .srv-specs .spec { padding: 12px 14px 14px; }
  .spec-num { font-size: 22px; }
  .srv-specs[data-n="4"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .srv-specs[data-n="4"] .spec:nth-child(3) { border-left: 0; }
  .srv-specs[data-n="4"] .spec:nth-child(n+3) { border-top: 1px solid var(--line); }
}
/* В админке ход действия — над содержимым блока «Сервер». */
#server:not(.srv) > .srv-op { margin: 14px 20px 0; }
.svc-ops-admin { padding: 6px 0 0; }
.svc-ops-admin li { padding: 6px 0; }
/* Пока идёт действие, светодиод мигает жёлтым: состояние в карточке может быть уже не тем. */
.srv.is-busy .srv-led { background: var(--led-wait); box-shadow: 0 0 0 4px color-mix(in srgb, var(--led-wait) 18%, transparent); animation: led-blink 1.4s ease-in-out infinite; }
.srv.is-busy .srv-state { opacity: .55; }
.bill .panel-foot form { flex-wrap: nowrap; }
.bill .panel-foot .grow { min-width: 0; }
.bill .panel-foot .btn { margin-left: auto; flex: none; }
@media (prefers-reduced-motion: reduce) { .srv.is-busy .srv-led { animation: none; } }

/* Пояснение под полем со ссылкой или кодом (партнёрская ссылка): отступ от поля, приглушённый цвет. */
.input-group + .help { margin: 10px 0 0; color: var(--text-2); font-size: 14px; line-height: 1.5; }

/* Блок статистики и следующий за ним блок не слипаются (страница «Партнёрам»). */
.stats + .panel, .stats + .grid-2 { margin-top: 20px; }
/* Подвал «Автопродление … / Выключить» в боковой колонке: текст переносится, кнопка остаётся справа. */
.panel-foot > form.gap { flex-wrap: nowrap; }
.panel-foot > form.gap .grow { min-width: 0; }
.panel-foot > form.gap > .btn { flex: none; margin-left: auto; }
/* Длинное значение в боковом списке (администратор домена — ФИО): подпись и значение на всю ширину, друг под другом. */
.kv-aside .kv-full { grid-column: 1 / -1; text-align: left; }
.kv-aside dt.kv-full { margin-bottom: -6px; }
.inv-what { font-size: 14px; color: var(--text); margin-top: 2px; }

/* Главная: «Требует внимания» — первым блоком под приветствием. Полоса слева — важность:
   красная (просрочено, не работает), жёлтая (скоро закончится), синяя (ответ поддержки, незавершённый платёж). */
.attn { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-m); margin-bottom: 20px; overflow: hidden; }
.attn-head { display: flex; align-items: center; gap: 8px; padding: 14px 20px 10px; }
.attn-head h2 { font-size: 16px; font-weight: 600; margin: 0; }
.attn-head .count { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; padding: 0 7px; border-radius: 999px; background: var(--danger-bg); color: var(--danger-ink); font-size: 12.5px; font-weight: 600; }
.attn ul { list-style: none; margin: 0; padding: 0; }
.attn-item { position: relative; display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px 20px; border-top: 1px solid var(--line); }
.attn-item::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 0 3px 3px 0; background: var(--info-ink); }
.attn-item.is-danger::before { background: var(--led-off); }
.attn-item.is-warn::before { background: var(--led-wait); }
.attn-icon { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 50%; background: var(--info-bg); color: var(--info-ink); }
.attn-item.is-danger .attn-icon { background: var(--danger-bg); color: var(--danger-ink); }
.attn-item.is-warn .attn-icon { background: var(--warn-bg); color: var(--warn-ink); }
.attn-icon .icon { width: 17px; height: 17px; }
.attn-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.attn-title { font-weight: 600; color: var(--text); font-size: 14.5px; }
.attn-title:hover { color: var(--brand-ink); }
.attn-text > span { color: var(--text-2); font-size: 13.5px; overflow-wrap: anywhere; }
.attn-more { padding: 10px 20px 12px 68px; border-top: 1px solid var(--line); color: var(--text-3); font-size: 13.5px; }
.attn-actions { display: flex; align-items: center; gap: 6px; }
.attn-actions form { margin: 0; }
.attn-actions .btn-ghost { color: var(--text-2); }
.attn-actions .btn-ghost:hover { color: var(--text); }
@media (max-width: 720px) {
  .attn-item { grid-template-columns: 30px minmax(0, 1fr); gap: 4px 12px; padding: 12px 16px; }
  .attn-icon { width: 30px; height: 30px; }
  .attn-item > .btn, .attn-actions { grid-column: 2; justify-self: start; margin-top: 6px; }
  .attn-actions { flex-direction: row-reverse; }
  .attn-head { padding: 14px 16px 10px; }
  .attn-more { padding-left: 58px; }
}

/* Нижняя полоса заказа: только когда «Ваш заказ» стоит под формой (≤ 1100px), прячется, когда он виден. */
.order-bar { display: none; }
@media (max-width: 1100px) {
  .order-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 12px;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -8px 24px -16px rgba(20, 32, 56, .35);
    transition: transform .2s ease; }
  .order-bar.is-hidden { transform: translateY(110%); }
  .order-bar-sum { display: flex; flex-direction: column; line-height: 1.2; }
  .order-bar-sum span { font-size: 12.5px; color: var(--text-3); }
  .order-bar-sum strong { font: 600 20px/1.2 var(--font-display); letter-spacing: var(--display-tracking); font-variant-numeric: tabular-nums; }
  form.configure { padding-bottom: 72px; }
}
@media (max-width: 1100px) and (prefers-reduced-motion: reduce) { .order-bar { transition: none; } }
/* Пользователи кабинета (субаккаунты) */
.form-narrow { max-width: 760px; }
.user-presets { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
.perm-list { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.perm-list li { display: flex; gap: 10px; align-items: flex-start; }
.perm-list li .icon { flex: none; width: 18px; height: 18px; margin-top: 2px; }
.perm-list li.is-on .icon { color: var(--success, #1a7f37); }
.perm-list li.is-off { color: var(--text-3); }
/* Письма клиенту */
.inbox-status { white-space: nowrap; }
.inbox-body { white-space: pre-wrap; word-break: break-word; font-size: 14.5px; line-height: 1.6; margin: 0; font-family: inherit; }
.form-narrow .checks { display: flex; flex-direction: column; gap: 10px; }

/* Смена тарифа: дата «без доплаты» у тарифа и выбор, как пересчитать. */
.radio-card .upgrade-time { color: var(--text-3); }
.upgrade-mode { border: 0; padding: 0; margin-left: 0; margin-right: 0; }
.upgrade-mode legend { margin-bottom: 8px; }
.upgrade-mode .radio-cards { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }

/* IPv6-подсеть сервера: строка под адресом, подробности (подсеть, префикс, шлюз) — при наведении или фокусе. */
.srv-ipv6 { flex-wrap: wrap; }
.srv-ipv6-label { font-size: 12px; font-weight: 600; color: var(--text-3); letter-spacing: .02em; }
.srv-ipv6 code { font-size: 13.5px; }
.tip { position: relative; display: inline-flex; align-items: center; cursor: help; border-bottom: 1px dashed var(--line-strong); }
.tip:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
.tip-pop { position: absolute; left: 0; top: calc(100% + 8px); z-index: 20; display: none; min-width: 290px; padding: 12px 14px;
  border: 1px solid var(--line); border-radius: var(--radius-m); background: var(--surface); box-shadow: 0 8px 24px rgba(0, 0, 0, .12); cursor: default; }
.tip:hover .tip-pop, .tip:focus .tip-pop, .tip:focus-within .tip-pop { display: grid; gap: 6px; }
.tip-row { display: flex; justify-content: space-between; gap: 18px; font-size: 13.5px; color: var(--text-2); }
.tip-row code { color: var(--text); }
.tip-note { margin-top: 4px; font-size: 12.5px; color: var(--text-3); line-height: 1.4; }
/* Карточка сервера обрезает содержимое по скруглению — пока открыта подсказка IPv6, не обрезаем. */
.srv:has(.tip:hover), .srv:has(.tip:focus-within) { overflow: visible; }
