/* ============================================================
   ПЕРЕМЕННЫЕ
   ============================================================ */
   :root {
    --cloud: #f7fbff;
    --night: #101827;
    --bg: var(--cloud);
    --fg: var(--night);
  
    --surface: var(--bg);
    --surface-2: color-mix(in srgb, var(--fg) 10%, var(--bg));
    --muted: color-mix(in srgb, var(--fg) 60%, var(--bg));
  
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  
    --font-family: 'Rubik', sans-serif;
    --font-weight-normal: 600;
    --font-weight-bold: 900;
    --letter-spacing: -0.02em;
    --letter-spacing-tight: -0.04em;
    --letter-spasing-header: 0.02em;
  
    --radius-switch: 999px;
    --radius-switch-inner: 999px;
    --radius-card: 20px;
    --radius-input: 20px;
    --radius-button: 999px;
  
    --transition: 0.2s ease;
    --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  
    color-scheme: light;
  }
  
  :root[data-theme='dark'] {
    --bg: var(--night);
    --fg: var(--cloud);
    color-scheme: dark;
  }
  
  /* ============================================================
     БАЗОВЫЕ СТИЛИ
     ============================================================ */
  * {
    box-sizing: border-box;
  }
  
  body {
    width: 100vw;
    height: 100vh;
    margin: 0;
    background: var(--bg);
    color: var(--fg);
    font-family: var(--font-family);
    display: flex;
    justify-content: center;
    overflow-x: hidden;
  }
  
  button,
  input,
  select,
  summary {
    font: inherit;
    color: inherit;
  }
  
  button,
  select,
  summary {
    cursor: pointer;
  }
  
  button:disabled {
    cursor: not-allowed;
    opacity: 0.42;
  }
  
  input,
  select,
  button {
    border: 0;
    outline: 0;
  }
  
  button:focus-visible,
  input:focus-visible,
  select:focus-visible,
  summary:focus-visible {
    outline: 0;
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--fg) 22%, transparent);
  }
  
  /* ============================================================
     СТРУКТУРА СТРАНИЦЫ
     ============================================================ */
  .page {
    position: fixed;
    width: 100vw;
    height: 100%;
    max-width: 500px;
    display: flex;
    flex-direction: column;
  }
  
  .page__header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  
  .page__title {
    font-size: 26px;
    line-height: 0.65;
    letter-spacing: var(--letter-spasing-header);
    font-weight: var(--font-weight-bold);
  }
  
  .mode-switch {
    width: 90%;
    display: flex;
    justify-content: center;
    border-radius: var(--radius-switch);
    background: var(--surface-2);
  }
  
  .mode-switch__button {
    flex: 1 1 0;
    min-height: 30px;
    border-radius: var(--radius-switch);
    background: transparent;
    font-size: 14px;
    font-weight: var(--font-weight-normal);
  }
  
  .mode-switch__button.is-active {
    background: var(--fg);
    color: var(--bg);
    box-shadow: 0 16px 42px color-mix(in srgb, var(--fg) 18%, transparent);
  }
  
  .page__main {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
  }
  
  /* ============================================================
     ГЕРО (ГЕНЕРАЦИЯ)
     ============================================================ */
  
  .hero {
    width: 100%;
    min-height: 32dvh;
    margin: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
  }
  
  .hero__result-box {
    position: relative;
    width: min(100%, 620px);
    height: clamp(150px, 30dvh, 226px);
    display: grid;
    place-items: center;
    container-type: size;
    overflow: hidden;
  }
  
  .hero__intro {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 26px;
    text-align: center;
    transition: opacity 180ms ease, visibility 180ms ease, transform 180ms ease;
  }
  
  .hero__intro-kicker,
  .hero__intro-text {
    margin: 0;
  }
  
  .hero__intro-kicker {
    font-size: clamp(15px, 5.2vw, 19px);
    font-weight: var(--font-weight-bold);
    letter-spacing: 0.035em;
    text-transform: uppercase;
    opacity: 0.8;
  }
  
  .hero__intro-text {
    max-width: 520px;
    margin: 0 5px;
    font-size: clamp(16px, 4.2vw, 19px);
    line-height: 1.5;
    font-weight: var(--font-weight-normal);
    opacity: 0.76;
  }
  
  .hero__result {
    position: absolute;
    inset: 0;
    z-index: 2;
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    overflow: hidden;
    color: var(--fg);
    font-size: clamp(86px, min(31cqw, 84cqh), 202px);
    letter-spacing: var(--letter-spacing-tight);
    font-weight: var(--font-weight-bold);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    transition: opacity 160ms ease, transform 160ms ease, filter 160ms ease;
    box-sizing: border-box;
    text-overflow: ellipsis;
  }
  
  .hero__result[data-empty='true'] {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }
  
  .hero__result[data-empty='false'] ~ .hero__intro {
    opacity: 0;
    visibility: hidden;
    transform: scale(0.985);
    pointer-events: none;
  }
  
  .hero__result--rolling {
    transform: scale(0.985);
    filter: blur(0.2px);
  }
  
  .generate-button {
    width: 90%;
    min-height: 86px;
    border-radius: var(--radius-button);
    background: var(--fg);
    color: var(--bg);
    font-size: clamp(22px, 9vw, 32px);
    font-weight: var(--font-weight-bold);
    letter-spacing: var(--letter-spacing-header);
    box-shadow: 0 26px 90px color-mix(in srgb, var(--fg) 22%, transparent);
    transition: transform 160ms ease, box-shadow 160ms ease, opacity 160ms ease;
  }
  
  .generate-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 34px 110px color-mix(in srgb, var(--fg) 28%, transparent);
  }
  
  .generate-button:active:not(:disabled) {
    transform: translateY(1px) scale(0.99);
  }
  
  .generate-button:disabled {
    cursor: wait;
    opacity: 0.72;
  }
  
  .generate-button.is-exhausted {
    background: color-mix(in srgb, var(--fg) 40%, var(--bg));
    color: var(--bg);
    box-shadow: 0 26px 90px color-mix(in srgb, var(--fg) 10%, transparent);
    cursor: default;
    opacity: 0.7;
    pointer-events: none;
  }
  
  /* ── Статус / история в hero ─────────────────────────── */
  .hero__status {
    --hero-history-index-color: color-mix(in srgb, var(--fg) 54%, #8f7cff);
    width: 100%;
    min-height: 52px;
    flex: 0 0 auto;
    margin: 0;
    padding: 0 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    /* ИСПРАВЛЕНИЕ: overflow hidden убран, чтобы прокрутка работала везде */
    overflow: visible;
    color: var(--fg);
    font-size: 13px;
    line-height: 1.35;
    text-align: center;
    opacity: 0.9;
  }
  
  .hero__history-list {
    width: 100%;
    min-height: 52px;
    max-height: 52px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 18px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0 2px;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    cursor: grab;
  }
  
  .hero__history-list::before,
  .hero__history-list::after {
    content: '';
    min-width: 0;
    flex: 1 0 0;
  }
  
  .hero__history-list::-webkit-scrollbar {
    display: none;
  }
  
  .hero__history-list.is-dragging {
    cursor: grabbing;
    scroll-snap-type: none;
  }
  
  .hero__history-group {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-width: 0;
    white-space: nowrap;
    scroll-snap-align: center;
  }
  
  .hero__history-entry,
  .hero__history-item {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: baseline;
    justify-content: center;
    gap: 5px;
    white-space: nowrap;
  }
  
  .hero__history-index {
    flex: 0 0 auto;
    color: var(--hero-history-index-color);
    font-size: clamp(12px, 3.2vw, 14px);
    line-height: 1;
    font-weight: var(--font-weight-bold);
    letter-spacing: 0.01em;
    font-variant-numeric: tabular-nums;
    opacity: 0.9;
  }
  
  .hero__history-number {
    appearance: none;
    -webkit-appearance: none;
    border: 0;
    background: transparent;
    color: var(--fg);
    margin: 0;
    padding: 5px 1px 7px;
    border-radius: 4px;
    font: inherit;
    font-size: clamp(13px, 3.4vw, 15px);
    line-height: 1;
    font-weight: var(--font-weight-bold);
    letter-spacing: var(--letter-spacing);
    font-variant-numeric: tabular-nums;
    opacity: 0.68;
    text-decoration-line: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 5px;
    text-decoration-color: color-mix(in srgb, var(--fg) 24%, transparent);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: opacity 140ms ease, text-decoration-color 140ms ease;
  }
  
  .hero__history-number:hover {
    opacity: 0.9;
    text-decoration-color: color-mix(in srgb, var(--fg) 56%, transparent);
  }
  
  .hero__history-number:active {
    opacity: 1;
  }
  
  .hero__history-number[data-latest='true'] {
    opacity: 0.9;
    text-decoration-color: color-mix(in srgb, var(--fg) 48%, transparent);
  }
  
  .hero__history-number:focus-visible {
    outline: 2px solid color-mix(in srgb, var(--fg) 28%, transparent);
    outline-offset: 4px;
  }
  
  .hero__history-divider {
    width: 100%;
    height: 1px;
    flex: 0 0 auto;
    margin: 0 calc(50% - 50vw);
    border: 0;
    background: color-mix(in srgb, var(--fg) 12%, transparent);
    opacity: 0.65;
  }
  
  @media (max-width: 420px) {
    .hero__history-list {
      gap: 14px;
    }
  
    .hero__history-group {
      gap: 10px;
    }
  
    .hero__history-index {
      font-size: clamp(12px, 3.2vw, 13px);
    }
  
    .hero__history-number {
      font-size: clamp(12px, 3.35vw, 14px);
      text-underline-offset: 5px;
    }
  }
  
  /* ============================================================
     НАСТРОЙКИ (ДИАПАЗОН, ПОБЕДИТЕЛИ)
     ============================================================ */
  
  .settings {
    display: flex;
    flex-direction: column;
    gap: 12px;
  }
  
  .section-head__title {
    margin: 0;
    font-size: 13px;
    font-weight: var(--font-weight-bold);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    opacity: 0.66;
  }
  
  .settings-row--range,
  .winners-field {
    width: 90%;
    margin: auto;
  }
  
  .settings-row--range {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px;
    align-items: center;
  }
  
  .range-field,
  .winners-field {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--fg);
    font-size: 13px;
    line-height: 1;
    font-weight: var(--font-weight-bold);
    opacity: 0.78;
  }
  
  .range-field span,
  .winners-field span {
    flex: 0 0 auto;
    white-space: nowrap;
  }
  
  .range-field input,
  .winners-field input,
  .broadcast__input,
  .footer-menu__panel button,
  .footer-menu__panel select {
    width: 100%;
    min-width: 0;
    min-height: 42px;
    padding: 0 4px;
    border: 0;
    border-bottom: 1px solid color-mix(in srgb, var(--fg) 22%, transparent);
    border-radius: 0;
    background: transparent;
    color: var(--fg);
    box-shadow: none;
    font-weight: var(--font-weight-bold);
    outline: none;
  }
  
  .range-field input,
  .winners-field input {
    max-width: 100%;
    text-align: center;
    font-size: clamp(17px, 5vw, 22px);
    letter-spacing: var(--letter-spacing-tight);
    font-variant-numeric: tabular-nums;
    opacity: 0.92;
    transition: border-color 140ms ease, opacity 140ms ease, transform 140ms ease;
  }
  
  .winners-field {
    justify-content: space-between;
    gap: 12px;
  }
  
  /* ИСПРАВЛЕНИЕ: активное состояние winners-field */
  .winners-field.is-active {
    opacity: 1;
  }
  
  .winners-field input {
    flex: 0 1 120px;
  }
  
  .range-field input:hover,
  .winners-field input:hover {
    border-bottom-color: color-mix(in srgb, var(--fg) 34%, transparent);
    opacity: 1;
  }
  
  .range-field input:focus-visible,
  .winners-field input:focus-visible {
    border-bottom-color: var(--fg);
    opacity: 1;
  }
  
  .range-field input[type='number'],
  .winners-field input[type='number'] {
    appearance: textfield;
    -moz-appearance: textfield;
  }
  
  .range-field input[type='number']::-webkit-outer-spin-button,
  .range-field input[type='number']::-webkit-inner-spin-button,
  .winners-field input[type='number']::-webkit-outer-spin-button,
  .winners-field input[type='number']::-webkit-inner-spin-button {
    margin: 0;
    -webkit-appearance: none;
  }
  
  /* ── Чекбоксы ─────────────────────────────────────────── */
  .checkboxes-row {
    display: flex;
    justify-content: center;
    gap: 16px;
    width: 90%;
    margin: 0 auto;
  }
  
  .checkbox-line {
    display: inline-flex;
    width: fit-content;
    align-items: center;
    gap: 8px;
    color: var(--fg);
    font-size: 12px;
    line-height: 1.25;
    font-weight: var(--font-weight-bold);
    opacity: 0.62;
    user-select: none;
    transition: opacity 140ms ease, transform 140ms ease;
  }
  
  .checkbox-line:hover {
    opacity: 0.82;
  }
  
  .checkbox-line input {
    width: 15px;
    height: 15px;
    flex: 0 0 auto;
    accent-color: var(--fg);
  }
  
  .checkbox-line input:not(:disabled),
  .checkbox-line input:not(:disabled) + span {
    cursor: pointer;
  }
  
  .checkbox-line input:focus-visible {
    outline: 2px solid color-mix(in srgb, var(--fg) 58%, transparent);
    outline-offset: 3px;
  }
  
  .checkbox-line--draw-all {
    margin-top: -4px;
  }
  
  .checkbox-line.is-disabled {
    opacity: 0.34;
    cursor: not-allowed;
  }
  
  .checkbox-line.is-disabled input,
  .checkbox-line.is-disabled span {
    cursor: not-allowed;
  }
  
  /* ИСПРАВЛЕНИЕ: активный чекбокс «Выдать всех» копирует стиль соседнего */
  .checkbox-line--draw-all.is-active {
    opacity: 0.62;
    cursor: pointer;
  }
  
  .checkbox-line--draw-all.is-active:hover {
    opacity: 0.82;
  }
  
  .checkbox-line--draw-all.is-active input,
  .checkbox-line--draw-all.is-active span {
    cursor: pointer;
  }
  
  .draw-all-one-shot {
    animation: drawAllOneShot 560ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
  }
  
  @keyframes drawAllOneShot {
    0% {
      transform: translate3d(0, 0, 0) scale(0.96);
      opacity: 0.42;
      filter: blur(2px);
    }
    45% {
      transform: translate3d(0, -2px, 0) scale(1.045);
      opacity: 1;
      filter: blur(0);
    }
    100% {
      transform: translate3d(0, 0, 0) scale(1);
      opacity: 1;
      filter: blur(0);
    }
  }
  
  /* ── Кнопка сброса в настройках ──────────────────────── */
  .settings-reset-row {
    margin: 0 auto;
    display: flex;
    justify-content: flex-start;
  }
  
  .settings-reset-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: transparent;
    border: 0;
    padding: 6px 0;
    color: var(--fg);
    font-size: 22px;
    font-weight: var(--font-weight-bold);
    cursor: pointer;
  }
  
  .settings-reset-btn:hover {
    opacity: 0.82;
  }
  
  .settings-reset-btn:active {
    opacity: 1;
  }
  
  .settings-reset-btn__icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
  }
  
  /* ============================================================
     ИСТОРИЯ
     ============================================================ */
  .history-section {
    display: none;
    flex-direction: column;
    gap: 12px;
  }
  
  .section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }
  
  .history-count {
    font-size: 13px;
    font-weight: var(--font-weight-bold);
    opacity: 0.62;
  }
  
  .history-list {
    max-height: min(28dvh, 230px);
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: var(--fg) transparent;
  }
  
  .history-list::-webkit-scrollbar {
    width: 8px;
  }
  
  .history-list::-webkit-scrollbar-thumb {
    border-radius: var(--radius-switch);
    background: color-mix(in srgb, var(--fg) 34%, transparent);
  }
  
  .history-list__item,
  .history-list__empty {
    min-height: 42px;
    padding: 12px 16px;
    border-radius: var(--radius-card);
    background: var(--surface-2);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 15px;
    font-weight: var(--font-weight-bold);
    font-variant-numeric: tabular-nums;
  }
  
  .history-list__item.is-latest {
    background: color-mix(in srgb, var(--fg) 13%, var(--bg));
  }
  
  .history-list__empty {
    justify-content: center;
    opacity: 0.58;
  }
  
  /* ============================================================
     ТРАНСЛЯЦИЯ (ССЫЛКА)
     ============================================================ */
  
  .broadcast {
    width: 90%;
    margin: auto;
  }
  
  .broadcast__row {
    width: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 48px 48px;
    gap: 10px;
    align-items: center;
  }
  
  .broadcast__input {
    width: 100%;
    min-width: 0;
    height: 48px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--fg);
    box-shadow: none;
    outline: none;
    font: inherit;
    font-size: clamp(12px, 3.2vw, 14px);
    line-height: 1;
    font-weight: var(--font-weight-normal);
    letter-spacing: 0.01em;
    opacity: 0.68;
    text-decoration-line: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 5px;
    text-decoration-color: color-mix(in srgb, var(--fg) 26%, transparent);
    text-overflow: ellipsis;
    cursor: pointer;
    transition: opacity 140ms ease, text-decoration-color 140ms ease;
  }
  
  .broadcast__input:hover,
  .broadcast__input:focus-visible {
    opacity: 0.92;
    text-decoration-color: color-mix(in srgb, var(--fg) 58%, transparent);
  }
  
  .broadcast__input::selection {
    background: color-mix(in srgb, var(--fg) 18%, transparent);
    color: var(--fg);
  }
  
  .broadcast__action {
    position: relative;
    width: 48px;
    min-width: 48px;
    height: 48px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--fg);
    box-shadow: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0.72;
    -webkit-tap-highlight-color: transparent;
    transition: opacity 140ms ease, transform 140ms ease;
  }
  
  .broadcast__action:hover {
    opacity: 0.96;
    transform: translateY(-1px);
  }
  
  .broadcast__action:active {
    opacity: 1;
    transform: translateY(1px) scale(0.96);
  }
  
  .broadcast__action:focus-visible {
    outline: 2px solid color-mix(in srgb, var(--fg) 30%, transparent);
    outline-offset: 3px;
  }
  
  .icon-svg {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
    display: block;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.85;
    stroke-linecap: round;
    stroke-linejoin: round;
  }
  
  .copy-button__icon,
  .copy-button__check {
    position: absolute;
    inset: 50% auto auto 50%;
    transform: translate(-50%, -50%);
    transition: opacity 140ms ease, transform 140ms ease;
  }
  
  .copy-button__check {
    color: #22c55e;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.72);
  }
  
  .copy-button.is-copying .copy-button__icon {
    animation: broadcastCopyIconTap 260ms ease both;
  }
  
  .copy-button.is-copied .copy-button__icon {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.72);
  }
  
  .copy-button.is-copied .copy-button__check {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    animation: broadcastCheckPop 360ms cubic-bezier(0.2, 0.9, 0.25, 1.25) both;
  }
  
  @keyframes broadcastCopyIconTap {
    0% { transform: translate(-50%, -50%) scale(1); }
    45% { transform: translate(-50%, -50%) scale(0.84) rotate(-5deg); }
    100% { transform: translate(-50%, -50%) scale(1) rotate(0deg); }
  }
  
  @keyframes broadcastCheckPop {
    0% { opacity: 0; transform: translate(-50%, -50%) scale(0.62); }
    70% { opacity: 1; transform: translate(-50%, -50%) scale(1.12); }
    100% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  }
  
  @media (max-width: 420px) {
    .broadcast__row {
      grid-template-columns: minmax(0, 1fr) 44px 44px;
      gap: 8px;
    }
  
    .broadcast__action {
      width: 44px;
      min-width: 44px;
      height: 44px;
    }
  
    /* .icon-svg {
      width: 28px;
      height: 28px;
    } */
  }
  
  /* ============================================================
     ФУТЕР (прижат к низу)
     ============================================================ */


     .footer {
      position: relative;
      width: 100%;
      bottom: 0;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
    }
    
    .footer--burger {
      justify-content: center;
    }
    
    body.menu-open .footer--burger {
      position: relative;
      z-index: 1002;
    }
    
    .footer__item {
      margin: 7px auto;
      min-width: 0;
      display: flex;
      justify-content: center;
      align-items: center;
    }
    
    .footer__center-divider {
      position: absolute;
      left: 50%;
      top: 50%;
      z-index: 0;
      width: 100%;
      height: 1px;
      margin: 0;
      border: 0;
      background: color-mix(in srgb, var(--fg) 13%, transparent);
      opacity: 0.72;
      transform: translate(-50%, -50%);
      pointer-events: none;
    }
    
    .footer-menu {
      position: relative;
      z-index: 2;
    }
    
    body.menu-open .footer-menu,
    .footer-menu[open] {
      z-index: 1003;
    }
    
    /* ============================================================
       BURGER BUTTON
       Кнопка остаётся поверх меню и превращается в крестик только при open
       ============================================================ */
    
       .footer {
        position: relative;
        width: 100%;
        bottom: 0;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 10px;
      }
      
      .footer--burger {
        justify-content: center;
      }
      
      body.menu-open .footer--burger {
        position: relative;
        z-index: 1002;
      }
      
      .footer__item {
        margin: 7px auto;
        min-width: 0;
        display: flex;
        justify-content: center;
        align-items: center;
      }
      
      .footer__center-divider {
        position: absolute;
        left: 50%;
        top: 50%;
        z-index: 0;
        width: 100%;
        height: 1px;
        margin: 0;
        border: 0;
        background: color-mix(in srgb, var(--fg) 13%, transparent);
        opacity: 0.72;
        transform: translate(-50%, -50%);
        pointer-events: none;
      }
      
      .footer-menu {
        position: relative;
        z-index: 2;
      }
      
      body.menu-open .footer-menu,
      .footer-menu[open] {
        z-index: 1003;
      }
      
      /* ============================================================
         BURGER BUTTON
         ============================================================ */
      
      .footer-burger-summary,
      .menuButton {
        --burger-size: 3.5em;
        --burger-radius: 0.5em;
        --burger-line-width: 30px;
        --burger-line-height: 4px;
        --burger-line-offset: 10px;
        --burger-cross-width: 40px;
        --burger-bg: color-mix(in srgb, var(--fg) 7%, var(--bg));
        --burger-border: color-mix(in srgb, var(--fg) 10%, transparent);
        --burger-line: var(--fg);
        --burger-shadow-dark: color-mix(in srgb, #000 16%, transparent);
        --burger-shadow-light: color-mix(in srgb, #fff 72%, transparent);
      }
      
      .footer-burger-summary {
        position: relative;
        z-index: 1004;
        width: var(--burger-size);
        height: var(--burger-size);
        min-width: var(--burger-size);
        min-height: var(--burger-size);
        padding: 0;
        border: 1px solid var(--burger-border);
        border-radius: var(--burger-radius);
        background: var(--burger-bg);
        color: var(--burger-line);
        box-shadow: 6px 6px 12px var(--burger-shadow-dark), -6px -6px 12px var(--burger-shadow-light);
        display: grid;
        place-items: center;
        list-style: none;
        outline: none;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
        transition: border-color 0.3s ease, box-shadow 0.3s ease, color 0.3s ease, background 0.3s ease, transform 0.2s ease;
      }
      
      .footer-burger-summary::-webkit-details-marker {
        display: none;
      }
      
      .footer-burger-summary:hover {
        border-color: color-mix(in srgb, var(--fg) 20%, transparent);
      }
      
      .footer-burger-summary:active {
        color: color-mix(in srgb, var(--fg) 72%, transparent);
        transform: scale(0.98);
        box-shadow: inset 4px 4px 12px var(--burger-shadow-dark), inset -4px -4px 12px var(--burger-shadow-light);
      }
      
      .footer-burger-summary:focus-visible {
        outline: 2px solid color-mix(in srgb, var(--fg) 30%, transparent);
        outline-offset: 6px;
      }
      
      .footer-menu[open] > .footer-burger-summary {
        position: relative;
        z-index: 1004;
        color: var(--burger-line);
        border-color: color-mix(in srgb, var(--fg) 20%, transparent);
        box-shadow: inset 4px 4px 12px var(--burger-shadow-dark), inset -4px -4px 12px var(--burger-shadow-light);
      }
      
      .footer-burger-summary span.top,
      .footer-burger-summary span.mid,
      .footer-burger-summary span.bot {
        position: absolute;
        left: 50%;
        width: var(--burger-line-width);
        height: var(--burger-line-height);
        background: currentColor;
        border-radius: 100px;
        transform: translateX(-50%);
        transform-origin: center;
        transition: transform 0.3s ease, opacity 0.3s ease, width 0.3s ease, box-shadow 0.3s ease;
      }
      
      .footer-burger-summary span.top {
        transform: translateX(-50%) translateY(calc(var(--burger-line-offset) * -1));
      }
      
      .footer-burger-summary span.mid {
        transform: translateX(-50%) translateY(0);
      }
      
      .footer-burger-summary span.bot {
        transform: translateX(-50%) translateY(var(--burger-line-offset));
      }
      
      .footer-burger-summary:hover span.top {
        transform: translateX(-50%) translateY(calc(var(--burger-line-offset) * -1));
      }
      
      .footer-burger-summary:hover span.mid {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
      }
      
      .footer-burger-summary:hover span.bot {
        transform: translateX(-50%) translateY(var(--burger-line-offset));
      }
      
      .footer-menu[open] > .footer-burger-summary span.top {
        width: var(--burger-cross-width);
        transform: translateX(-50%) translateY(0) rotate(45deg);
      }
      
      .footer-menu[open] > .footer-burger-summary span.mid {
        opacity: 0;
        transform: translateX(calc(-50% - 20px)) translateY(0);
      }
      
      .footer-menu[open] > .footer-burger-summary span.bot {
        width: var(--burger-cross-width);
        transform: translateX(-50%) translateY(0) rotate(-45deg);
        box-shadow: 0 0 10px color-mix(in srgb, var(--fg) 20%, transparent);
      }
      
      [data-theme='dark'] .footer-burger-summary,
      [data-theme='dark'] .menuButton {
        --burger-bg: color-mix(in srgb, var(--fg) 8%, var(--bg));
        --burger-border: color-mix(in srgb, var(--fg) 14%, transparent);
        --burger-line: var(--fg);
        --burger-shadow-dark: color-mix(in srgb, #000 42%, transparent);
        --burger-shadow-light: color-mix(in srgb, #fff 7%, transparent);
      }
      
      /* ============================================================
         MENU PANEL
         ============================================================ */
      
      .footer .footer-menu__panel {
        position: fixed;
        inset: 0;
        z-index: 1000;
        display: none;
        align-items: center;
        justify-content: center;
        padding: 22px;
        border: 0;
        border-radius: 0;
        background: color-mix(in srgb, var(--bg) 90%, transparent);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        cursor: pointer;
        overflow-y: auto;
      }
      
      .footer .footer-menu[open] .footer-menu__panel {
        display: flex;
      }
      
      .footer-menu__sheet {
        position: relative;
        width: min(100%, 460px);
        max-height: calc(100dvh - 44px);
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 18px;
        padding: 26px;
        border-radius: 34px;
        background: color-mix(in srgb, var(--bg) 94%, var(--fg) 6%);
        box-shadow: 0 36px 110px color-mix(in srgb, #000 18%, transparent);
        cursor: default;
        overflow-y: auto;
        scrollbar-width: none;
      }
      
      .footer-menu__sheet::-webkit-scrollbar {
        display: none;
      }
      
      .footer-menu__divider {
        width: 100%;
        height: 1px;
        margin: 2px 0;
        border: 0;
        background: color-mix(in srgb, var(--fg) 13%, transparent);
      }
      
      /* ============================================================
         AVATAR
         ============================================================ */
      
         .menu-avatar {
          display: flex;
          flex-direction: column;
          align-items: center;
          gap: 10px;
          text-align: center;
        }
        
        .menu-avatar__stage {
          width: min(100%, 370px);
          display: grid;
          grid-template-columns: 52px minmax(0, 1fr) 52px;
          gap: 12px;
          align-items: center;
          justify-items: center;
        }
        
        .menu-avatar__center {
          min-width: 0;
          display: flex;
          flex-direction: column;
          align-items: center;
          gap: 9px;
        }
        
        .menu-avatar__size-column {
          display: flex;
          flex-direction: column;
          gap: 8px;
          align-items: center;
          justify-content: center;
        }
        
        .menu-avatar__circle {
          --avatar-circle-size: 138px;
          width: var(--avatar-circle-size);
          height: var(--avatar-circle-size);
          padding: 14px;
          border-radius: 50%;
          background: var(--avatar-bg);
          box-shadow:
            inset 0 0 0 1px color-mix(in srgb, var(--avatar-accent-color) 18%, transparent),
            inset 0 -14px 30px color-mix(in srgb, var(--avatar-accent-color) 8%, transparent),
            0 18px 52px color-mix(in srgb, #000 10%, transparent); 
          display: grid;
          place-items: center;
          overflow: hidden;
        }
        
        .menu-avatar__picture {
          --avatar-cols: 8;
          --avatar-rows: 8;
          --avatar-gap: 1.85px;
          width: 100%;
          height: 100%;
          display: grid;
          grid-template-columns: repeat(var(--avatar-cols), 1fr);
          grid-template-rows: repeat(var(--avatar-rows), 1fr);
          gap: var(--avatar-gap);
          image-rendering: pixelated;
          border-radius: 50%;
        }
        
        .menu-avatar__pixel {
          width: 100%;
          height: 100%;
          border-radius: 1.5px;
          background: transparent;
        }
        
        .menu-avatar__pixel.is-active {
          background: var(--pixel-color, var(--fg));
          opacity: var(--pixel-opacity, 1);
        }
        
        .menu-avatar__pixel.is-soft {
          opacity: 0.72;
        }
        
        .menu-avatar__action-band {
          display: grid;
          grid-template-columns: 1fr auto 1fr;
          gap: 8px;
          align-items: center;
          width: min(100%, 240px);
        }
        
        .menu-avatar__actions {
          display: inline-flex;
          align-items: center;
          justify-content: center;
          gap: 8px;
        }
        
        .menu-avatar__mini-button,
        .menu-avatar__mode-button,
        .menu-avatar__size-button {
          border: 1px solid color-mix(in srgb, var(--fg) 13%, transparent);
          background: transparent;
          color: var(--fg);
          cursor: pointer;
          -webkit-tap-highlight-color: transparent;
          transition: opacity 140ms ease, transform 140ms ease, border-color 140ms ease, background 140ms ease, color 140ms ease;
        }
        
        .menu-avatar__mini-button {
          width: 34px;
          height: 34px;
          padding: 0;
          border-radius: 50%;
          display: grid;
          place-items: center;
          opacity: 0.76;
        }
        
        .menu-avatar__mini-button .icon-svg {
          width: 18px;
          height: 18px;
          stroke: currentColor;
          stroke-width: 1.9;
          stroke-linecap: round;
          stroke-linejoin: round;
        }
        
        .menu-avatar__mode-button,
        .menu-avatar__size-button {
          min-height: 30px;
          padding: 0 8px;
          border-radius: 999px;
          font: inherit;
          font-size: 11px;
          line-height: 1;
          font-weight: var(--font-weight-bold);
          opacity: 0.66;
        }
        
        .menu-avatar__size-button {
          width: 48px;
          padding-inline: 4px;
        }
        
        .menu-avatar__mode-button {
          min-width: 66px;
        }
        
        .menu-avatar__mini-button:hover,
        .menu-avatar__mode-button:hover,
        .menu-avatar__size-button:hover {
          opacity: 0.94;
          border-color: color-mix(in srgb, var(--fg) 26%, transparent);
        }
        
        .menu-avatar__mini-button:active,
        .menu-avatar__mode-button:active,
        .menu-avatar__size-button:active {
          transform: translateY(1px) scale(0.96);
        }
        
        .menu-avatar__mini-button:focus-visible,
        .menu-avatar__mode-button:focus-visible,
        .menu-avatar__size-button:focus-visible {
          outline: 2px solid color-mix(in srgb, var(--fg) 30%, transparent);
          outline-offset: 4px;
        }
        
        .menu-avatar__mode-button.is-active,
        .menu-avatar__size-button.is-active {
          opacity: 1;
          border-color: color-mix(in srgb, var(--fg) 30%, transparent);
          background: color-mix(in srgb, var(--fg) 8%, transparent);
        }
        
        .menu-avatar__mini-button.is-success {
          color: #22c55e;
          border-color: color-mix(in srgb, #22c55e 44%, transparent);
          opacity: 1;
        }
        
        /* [data-theme='dark'] .menu-avatar__circle {
          box-shadow:
            inset 0 0 0 1px color-mix(in srgb, var(--avatar-accent-color) 18%, transparent),
            inset 0 -14px 30px color-mix(in srgb, #000 18%, transparent),
            0 18px 52px color-mix(in srgb, #000 24%, transparent);
        } */
        
        @media (max-width: 420px) {
          .menu-avatar__stage {
            width: min(100%, 326px);
            grid-template-columns: 46px minmax(0, 1fr) 46px;
            gap: 8px;
          }
        
          .menu-avatar__circle {
            --avatar-circle-size: 122px;
            padding: 12px;
          }
        
          /* .menu-avatar__picture {
            width: 80%;
            height: 80%;
          } */
        
          .menu-avatar__size-button {
            width: 42px;
            min-height: 29px;
            font-size: 10px;
          }
        
          .menu-avatar__action-band {
            width: min(100%, 218px);
            gap: 6px;
          }
        
          .menu-avatar__mode-button {
            min-width: 60px;
            min-height: 29px;
            padding-inline: 6px;
            font-size: 10px;
          }
        
          .menu-avatar__mini-button {
            width: 32px;
            height: 32px;
          }
        }







      /* ============================================================
         SETTINGS
         ============================================================ */
      
      .footer-menu__controls {
        width: 100%;
        display: flex;
        flex-direction: column;
        gap: 12px;
      }




      
      .menu-setting,
      .menu-select-row,
      .menu-info {
        width: 100%;
        /* border: 1px solid color-mix(in srgb, var(--fg) 10%, transparent); */
        /* border-radius: 22px; */
        /* background: color-mix(in srgb, var(--fg) 4%, transparent); */
        color: var(--fg);
      }
      
      /* .menu-setting {
        padding: 14px; 
      } */
      
      .menu-setting--checkbox {
        display: flex;
        align-items: flex-start;
        gap: 10px;
        cursor: pointer;
      }
      
      .menu-setting--checkbox input,
      .menu-setting__inline input {
        width: 17px;
        height: 17px;
        margin: 1px 0 0;
        flex: 0 0 auto;
        accent-color: var(--fg);
      }
      
      .menu-setting__content {
        min-width: 0;
        display: flex;
        flex-direction: column;
        gap: 5px;
      }
      
      .menu-setting__title {
        color: var(--fg);
        font-size: 14px;
        line-height: 1.2;
        font-weight: var(--font-weight-bold);
      }
      
      .menu-setting__description {
        color: var(--fg);
        font-size: 12px;
        line-height: 1.35;
        opacity: 0.56;
      }
      
      .menu-setting__description--full {
        margin: 0;
        grid-column: 1 / -1;
      }
      
      .menu-setting--remember {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 10px;
        align-items: center;
      }
      
      .menu-setting__inline {
        display: inline-flex;
        align-items: center;
        gap: 10px;
        cursor: pointer;
      }





      
      .menu-number-field {
        display: inline-flex;
        align-items: center;
        gap: 7px;
        color: var(--fg);
        font-size: 13px;
        font-weight: var(--font-weight-bold);
      }
      
      .menu-number-field input {
        width: 62px;
        min-height: 38px;
        border: 1px solid color-mix(in srgb, var(--fg) 12%, transparent);
        border-radius: 14px;
        background: transparent;
        color: var(--fg);
        text-align: center;
        font: inherit;
        font-weight: var(--font-weight-bold);
        outline: none;
      }
      
      .menu-select-row {
        min-height: 54px;
        padding: 0 14px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 14px;
        font-size: 14px;
        line-height: 1;
        font-weight: var(--font-weight-bold);
      }
      
      .menu-select-row--compact {
        min-height: 48px;
        margin-bottom: 12px;
      }
      
      .menu-select-row select {
        width: auto;
        min-width: 132px;
        min-height: 38px;
        padding: 0 12px;
        border: 1px solid color-mix(in srgb, var(--fg) 12%, transparent);
        border-radius: 14px;
        background: transparent;
        color: var(--fg);
        text-align: center;
        font: inherit;
        font-size: 13px;
        font-weight: var(--font-weight-bold);
        outline: none;
        cursor: pointer;
      }
      
      .footer .footer-menu__action {
        width: 100%;
        min-height: 52px;
        padding: 0 18px;
        border: 1px solid color-mix(in srgb, var(--fg) 12%, transparent);
        border-radius: 999px;
        background: transparent;
        color: var(--fg);
        box-shadow: none;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 9px;
        font-size: 15px;
        line-height: 1;
        font-weight: var(--font-weight-bold);
        outline: none;
        cursor: pointer;
        transition: opacity 140ms ease, border-color 140ms ease, transform 140ms ease;
      }
      
      .footer .footer-menu__action:hover,
      .menu-select-row select:hover,
      .menu-number-field input:hover {
        opacity: 0.88;
        border-color: color-mix(in srgb, var(--fg) 24%, transparent);
      }
      
      .footer .footer-menu__action:active {
        transform: translateY(1px) scale(0.98);
      }
      
      .footer .footer-menu__action:focus-visible,
      .menu-select-row select:focus-visible,
      .menu-number-field input:focus-visible,
      .menu-avatar__refresh:focus-visible {
        outline: 2px solid color-mix(in srgb, var(--fg) 30%, transparent);
        outline-offset: 4px;
      }
      
      .footer-menu__action .icon-svg {
        width: 22px;
        height: 22px;
        stroke: currentColor;
        stroke-width: 1.9;
        stroke-linecap: round;
        stroke-linejoin: round;
      }
      
      .reset-button {
        background: var(--fg) !important;
        color: var(--bg) !important;
      }
      
      .menu-info {
        padding: 15px;
      }
      
      .menu-info__title {
        margin: 0 0 7px;
        font-size: 14px;
        line-height: 1.1;
        font-weight: var(--font-weight-bold);
      }
      
      .menu-info__text {
        margin: 0;
        font-size: 12px;
        line-height: 1.45;
        opacity: 0.58;
      }
      
      /* ============================================================
         HISTORY MODAL INSIDE MENU MODAL
         ============================================================ */
      
      .footer-history-modal[hidden] {
        display: none;
      }
      
      .footer-history-modal {
        position: absolute;
        inset: 0;
        z-index: 4;
        display: grid;
        place-items: center;
        padding: 18px;
        border-radius: 34px;
        background: color-mix(in srgb, var(--bg) 74%, transparent);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
      }
      
      .footer-history-modal__panel {
        width: 100%;
        max-height: min(520px, calc(100dvh - 94px));
        padding: 18px;
        border-radius: 26px;
        background: color-mix(in srgb, var(--bg) 96%, var(--fg) 4%);
        box-shadow: 0 28px 90px color-mix(in srgb, #000 18%, transparent);
        overflow: hidden;
        display: flex;
        flex-direction: column;
      }
      
      .footer-history-modal__head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        margin-bottom: 12px;
      }
      
      .footer-history-modal__title {
        margin: 0;
        font-size: 20px;
        line-height: 1;
        font-weight: var(--font-weight-bold);
      }
      
      .footer-history-modal__close {
        width: 38px;
        height: 38px;
        border: 1px solid color-mix(in srgb, var(--fg) 12%, transparent);
        border-radius: 50%;
        background: transparent;
        color: var(--fg);
        font-size: 24px;
        line-height: 1;
        cursor: pointer;
      }
      
      .footer-history-modal__list {
        min-height: 120px;
        overflow-y: auto;
        display: flex;
        flex-direction: column;
        gap: 8px;
        scrollbar-width: none;
      }
      
      .footer-history-modal__list::-webkit-scrollbar {
        display: none;
      }
      
      .footer-history-item {
        padding: 12px;
        border: 1px solid color-mix(in srgb, var(--fg) 9%, transparent);
        border-radius: 18px;
        background: color-mix(in srgb, var(--fg) 3%, transparent);
      }
      
      .footer-history-item__date {
        margin: 0 0 8px;
        font-size: 11px;
        line-height: 1;
        opacity: 0.5;
      }
      
      .footer-history-item__numbers {
        display: flex;
        flex-wrap: wrap;
        gap: 7px;
      }
      
      .footer-history-item__number {
        font-size: 13px;
        font-weight: var(--font-weight-bold);
        font-variant-numeric: tabular-nums;
      }
      
      .footer-history-empty {
        margin: auto;
        color: var(--fg);
        font-size: 13px;
        line-height: 1.4;
        text-align: center;
        opacity: 0.55;
      }
      
      /* ============================================================
         THEME LEGACY SWITCH COMPATIBILITY
         ============================================================ */
      
      .theme-switch__input.visually-hidden {
        pointer-events: none;
      }
      
      .visually-hidden {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
        border: 0;
      }
      
      body.menu-open,
      body.footer-history-open {
        overflow: hidden;
      }
      
      /* ============================================================
         MOBILE
         ============================================================ */
      
      @media (max-width: 420px) {
        .footer-burger-summary,
        .menuButton {
          --burger-size: 3.12em;
          --burger-radius: 0.48em;
          --burger-line-width: 26px;
          --burger-line-height: 3px;
          --burger-line-offset: 8.5px;
          --burger-cross-width: 34px;
        }
      
        .footer__item {
          margin: 6px auto;
        }
      
        .footer-menu__sheet {
          width: min(100%, 360px);
          max-height: calc(100dvh - 36px);
          padding: 20px;
          border-radius: 28px;
        }
      
        .menu-avatar__picture {
          --avatar-size: 112px;
          --avatar-gap: 3px;
        }
      
        .menu-setting--remember {
          grid-template-columns: 1fr;
        }
      
        .menu-select-row {
          min-height: 50px;
        }
      
        .menu-select-row select {
          min-width: 118px;
        }
      
        .footer-history-modal {
          border-radius: 28px;
          padding: 12px;
        }
      }

  
  /* ============================================================
     МОДАЛЬНОЕ ОКНО ПОДТВЕРЖДЕНИЯ СБРОСА
     ============================================================ */
  .confirm-modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
  }
  
  .confirm-modal[hidden] {
    display: none;
  }
  
  .confirm-modal__backdrop {
    position: absolute;
    inset: 0;
    background: color-mix(in srgb, var(--bg) 80%, transparent);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    cursor: pointer;
  }
  
  .confirm-modal__sheet {
    position: relative;
    z-index: 1;
    width: min(100%, 360px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    padding: 32px 28px 28px;
    border-radius: 28px;
    background: color-mix(in srgb, var(--bg) 96%, var(--fg) 4%);
    box-shadow: 0 28px 80px color-mix(in srgb, #000 22%, transparent);
    animation: confirmModalIn 200ms cubic-bezier(0.2, 0.9, 0.3, 1) both;
  }
  
  @keyframes confirmModalIn {
    from { transform: scale(0.92) translateY(10px); opacity: 0; }
    to   { transform: scale(1) translateY(0); opacity: 1; }
  }
  
  .confirm-modal__icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
  }
  
  .confirm-modal__icon svg {
    width: 100%;
    height: 100%;
    stroke: var(--fg);
    stroke-width: 1.85;
    stroke-linecap: round;
    stroke-linejoin: round;
    fill: none;
  }
  
  .confirm-modal__title {
    margin: 0;
    font-size: clamp(20px, 5.5vw, 26px);
    font-weight: var(--font-weight-bold);
    letter-spacing: var(--letter-spacing-tight);
    text-align: center;
    color: var(--fg);
  }
  
  .confirm-modal__desc {
    margin: 0;
    font-size: 14px;
    font-weight: var(--font-weight-normal);
    line-height: 1.55;
    text-align: center;
    color: var(--fg);
    opacity: 0.7;
  }
  
  .confirm-modal__actions {
    display: flex;
    gap: 10px;
    width: 100%;
  }
  
  .confirm-modal__btn {
    flex: 1;
    min-height: 48px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: var(--font-weight-bold);
    border: 1px solid color-mix(in srgb, var(--fg) 14%, transparent);
    cursor: pointer;
    transition: opacity 140ms ease, transform 100ms ease;
    -webkit-tap-highlight-color: transparent;
  }
  
  .confirm-modal__btn:active {
    transform: scale(0.97);
  }
  
  .confirm-modal__btn--cancel {
    background: transparent;
    color: var(--fg);
    opacity: 0.72;
  }
  
  .confirm-modal__btn--cancel:hover {
    opacity: 1;
    border-color: color-mix(in srgb, var(--fg) 24%, transparent);
  }
  
  .confirm-modal__btn--confirm {
    background: var(--fg);
    color: var(--bg);
    border-color: transparent;
    opacity: 0.9;
  }
  
  .confirm-modal__btn--confirm:hover {
    opacity: 1;
  }
  
  /* ============================================================
     МЕДИА-ЗАПРОСЫ
     ============================================================ */
  @media (max-width: 767px) {
    .history-section {
      display: none;
    }
  
    .broadcast__row {
      grid-template-columns: minmax(0, 1fr) 44px 44px;
      gap: 7px;
    }
   
    .broadcast__action {
      width: 44px;
      min-width: 44px;
      height: 44px;
      border-radius: calc(var(--radius-input) - 2px);
    }
  
    .footer {
      gap: 8px;
    }
  
    .footer__control {
      gap: 5px;
    }
  
    .footer-menu__panel {
      padding: 16px;
    }
  
    .footer-menu__sheet {
      padding: 20px 20px 24px;
      padding-top: 64px;
      border-radius: 28px;
      min-height: auto;
      gap: 18px;
    }
  
    .footer-menu__label {
      max-width: 100%;
    }
  
    .reset-button {
      max-width: 100%;
    }
  
    .confirm-modal__sheet {
      padding: 28px 20px 24px;
      gap: 14px;
    }
  }
  
  @media (min-width: 520px) {
    .page {
      padding-inline: 22px;
    }
  
    .hero {
      min-height: 36dvh;
    }
  }

 