/* Overlays: account modals (log-in, registration, password reset), the deposit
 * limit dialog, the age gate and the cookie preference centre, the mobile menu.
 * Panels from fig-spec: 460/580/440/520/500 wide on 1440; 358/342 wide on 390. */

/* ── shared modal parts ───────────────────────────────────────────────── */
.modal { position: relative; display: flex; flex-direction: column; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .102), var(--shadow-card); }
.modal__head { display: flex; justify-content: space-between; align-items: flex-start; }
.modal__titles { display: flex; flex-direction: column; gap: var(--space-6); }
.modal__kicker { font-size: 11px; line-height: 12px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: var(--color-muted-light); }
.modal__title { font-family: var(--font-display); font-weight: 900; font-size: 28px; line-height: 35px; color: var(--color-ink); }
.modal__title--sm { font-size: 26px; line-height: 32px; }
.modal__title--gap { margin: 6px 0 8px; }
.modal__sub { font-size: 14px; line-height: 15px; color: var(--color-text-dark-3); }
.modal__sub--lead { line-height: 21px; }
.modal__body { font-size: 14px; line-height: 22px; color: var(--color-text-dark-3); }
.modal__close {
  width: 24px; height: 24px; padding: 0; border: 0; background: none; cursor: pointer; flex-shrink: 0;
  color: var(--color-muted-light); transition: color var(--dur-fast) var(--ease);
}
.modal__close::after { content: ""; position: absolute; inset: -10px; }
.modal__close { position: relative; }
.modal__close:hover { color: var(--color-ink); }
.modal__close .icon { width: 14px; height: 14px; margin: 5px; }
.modal__close--corner { position: absolute; top: 24px; right: 24px; }
.modal__close--x { top: 20px; right: 20px; font-family: var(--font-body); font-size: 20px; line-height: 22px; }
.modal__form { display: flex; flex-direction: column; }
.modal__link { padding: 0; border: 0; background: none; cursor: pointer; font-size: 13px; line-height: 14px; font-weight: 600; color: var(--color-brand-ink); transition: color var(--dur-fast) var(--ease); }
.modal__link:hover { text-decoration: underline; }
.modal__link--strong { font-weight: 800; }
.modal__submit { min-height: 50px; font-size: 14px; line-height: 15px; font-weight: 700; color: #fff; }
.modal__rule { height: 0; margin: 20px 0 16px; border: 0; border-top: 1px solid var(--color-line-light); }
.modal__foot { display: flex; justify-content: center; gap: var(--space-6); font-size: 13px; line-height: 14px; color: var(--color-muted-light); }
.modal__foot--pad { padding-top: 16px; }
.modal__actions { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.modal__actions .modal__submit { width: 100%; }
.modal__done { display: flex; flex-direction: column; }
.modal__note { display: flex; flex-direction: column; gap: var(--space-4); margin: 24px 0; padding: 20px; border-radius: var(--radius-md); background: var(--color-light-2); }
.modal__note-title { font-size: 13px; line-height: 14px; font-weight: 700; color: var(--color-ink); }
.modal__note-text { font-size: 13px; line-height: 20px; color: var(--color-text-dark-3); }

/* fields inside modals: label 11/12 ExtraBold ink, input 48 on #e3e1ff */
.field--modal { gap: var(--space-6); }
.field--modal .field__label { font-size: 11px; line-height: 12px; letter-spacing: 0; text-transform: uppercase; color: var(--color-ink); }
.field--modal input:not(.visually-hidden):not([type="checkbox"]):not([type="radio"]), .field--modal select { min-height: 48px; background: var(--color-light-2); }
.field--compact input:not(.visually-hidden):not([type="checkbox"]):not([type="radio"]), .field--compact select { min-height: 46px; padding-inline: 14px; font-size: 14px; line-height: 15px; }
.field--compact .field__label { text-transform: uppercase; }   /* registration frame: labels drawn with case UPPER */
.field--modal .field__hint { font-size: 11px; line-height: 12px; color: #9ca3af; }
.field--modal input::placeholder { color: #9ca3af; }

/* ── log in (460 × 500) ───────────────────────────────────────────────── */
.modal--login { width: min(100%, 460px); padding: 36px 40px 32px; }
.modal--login .modal__form { margin-top: 24px; gap: var(--space-16); }
.modal--login .modal__head { height: 74px; }
.modal--login .field--modal { padding-bottom: 20px; }   /* the mockup keeps a 20px validation slot under each field */
.modal--login .field--modal:has(.field__error:not([hidden])) { padding-bottom: 0; }
.modal__forgot { display: flex; justify-content: flex-end; margin-top: -16px; }
.modal--login .modal__submit { margin-top: 20px; }

/* ── registration (580 × 1042) ────────────────────────────────────────── */
.overlay--tall { align-items: start; }
.modal--register { width: min(100%, 580px); padding: 36px 40px 32px; margin-block: 32px; }
.modal--register .modal__form { margin-top: 24px; gap: var(--space-20); }
.modal__group { display: flex; flex-direction: column; gap: var(--space-12); padding: 0; margin: 0; border: 0; min-width: 0; }
.modal__legend { padding: 0; font-size: 10px; line-height: 11px; font-weight: 700; color: #9ca3af; }
.modal__group > .modal__legend + * { margin-top: 0; }
.modal__row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-16); }
.modal__row--3 { grid-template-columns: 1fr 1fr 1fr; }
.modal__consent { display: flex; flex-direction: column; gap: var(--space-12); padding: 20px 0; margin-top: 0; box-shadow: inset 0 1px 0 #e0ddd7; }
.modal--register .modal__submit { margin-top: -4px; }
.modal__consent .field--check .field__label { font-size: 13px; line-height: 18px; color: var(--color-text-dark-3); }
.modal__consent .field--check input[type="checkbox"] { background: var(--color-light-2); border-color: var(--color-light-2); }

/* ── password reset (440 × 394) ───────────────────────────────────────── */
.modal--reset { width: min(100%, 440px); padding: 36px 40px 32px; }
.modal--reset .modal__form { gap: 0; }
.modal--reset .field--modal { margin: 24px 0; }
.modal--reset .modal__actions { margin-top: 0; }

/* ── deposit limit ────────────────────────────────────────────────────── */
.modal--limits { width: min(100%, 460px); padding: 36px 40px 32px; }
.modal--limits .modal__form { gap: var(--space-16); }
.limits__current { margin: 20px 0 4px; padding: 14px 16px; border-radius: var(--radius-md); background: var(--color-light-2); font-size: 13px; line-height: 18px; color: var(--color-text-dark-3); }
.limits__current strong { color: var(--color-ink); }
.limits__periods { display: flex; gap: var(--space-8); }
.limits__period { flex: 1; }
.limits__period input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.limits__period span {
  display: grid; place-items: center; height: 44px; border-radius: var(--radius-md); background: var(--color-light-2);
  box-shadow: inset 0 0 0 1px var(--color-line-light); font-size: 13px; line-height: 14px; font-weight: 700; color: var(--color-ink); cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
}
.limits__period input:checked + span { background: var(--color-brand); color: #fff; box-shadow: none; }
.limits__period input:focus-visible + span { box-shadow: var(--focus-ring); }

/* ── age gate (520 × 532) ─────────────────────────────────────────────── */
.overlay--gate { background: rgba(0, 0, 0, .749); }
.gate { display: flex; flex-direction: column; align-items: center; width: min(100%, 520px); padding: 40px 48px; border-radius: var(--radius-3xl); background: var(--color-light); text-align: center; box-shadow: var(--shadow-modal); }
.gate__eyebrow { width: 100%; font-size: 11px; line-height: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .09em; color: var(--color-muted-light); }
.gate__badge { display: inline-grid; place-items: center; width: 48px; height: 28px; margin-top: 28px; border-radius: var(--radius-sm); background: var(--color-brand); font-family: var(--font-display); font-weight: 900; font-size: 11px; line-height: 14px; color: #fff; }
.gate__title { margin-top: 28px; font-family: var(--font-display); font-weight: 900; font-size: 30px; line-height: 37px; color: var(--color-ink); }
.gate__body { width: 400px; max-width: 100%; margin-top: 28px; font-size: 15px; line-height: 23px; color: var(--color-text-dark); }
.gate__actions { display: flex; flex-direction: column; align-items: center; gap: var(--space-20); width: 100%; margin-top: 28px; }
.gate__yes { width: 100%; min-height: 48px; border-radius: var(--radius-md); font-size: 15px; line-height: 16px; font-weight: 700; color: #fff; }
.gate__no { font-size: 14px; line-height: 15px; font-weight: 600; color: var(--color-muted-light); text-decoration: none; }
.gate__no:hover { color: var(--color-ink); text-decoration: underline; }
.gate__rule { width: 100%; height: 0; margin: 28px 0 0; border: 0; border-top: 1px solid var(--color-line-light); }
.gate__rg { display: flex; flex-direction: column; gap: var(--space-8); width: 100%; margin-top: 28px; font-size: 12px; line-height: 13px; color: var(--color-muted-light); }

/* ── cookie preference centre (500 × 670, right-aligned on 1440) ──────── */
.overlay--cookie { justify-items: end; padding-right: 120px; }
.cookie { position: relative; display: flex; flex-direction: column; gap: var(--space-24); width: min(100%, 500px); padding: 32px 36px; border-radius: var(--radius-xl); background: var(--color-light); box-shadow: 0 16px 32px -12px rgba(0, 0, 0, .251); }
.cookie__head { display: flex; flex-direction: column; gap: var(--space-6); }
.cookie__title { font-family: var(--font-display); font-weight: 900; font-size: 24px; line-height: 30px; color: var(--color-bg); }
@media (min-width: 1200px) { .cookie__title { white-space: nowrap; } }   /* the mockup box is 435px in a 428px panel */
.cookie__body { font-size: 14px; line-height: 20px; color: var(--color-text-dark-3); }
.cookie__body a { color: var(--color-brand-ink); }
.cookie__form { display: flex; flex-direction: column; gap: var(--space-24); }
.cookie__list { display: flex; flex-direction: column; gap: 10px; }
.cookie__row { display: flex; justify-content: space-between; align-items: center; padding: 16px; border-radius: var(--radius-md); box-shadow: inset 0 0 0 1px var(--color-line-light); }
.cookie__text { display: flex; flex-direction: column; gap: var(--space-4); }
.cookie__row--tall .cookie__text { width: 263px; }
.cookie__row:not(.cookie__row--tall) .cookie__text { width: 320px; }
.cookie__name { font-size: 13px; line-height: 14px; font-weight: 700; color: var(--color-bg); }
.cookie__desc { font-size: 13px; line-height: 18px; color: var(--color-muted-light); }
.cookie__always { font-size: 11px; line-height: 12px; font-weight: 700; color: var(--color-muted-light); }
.switch { position: relative; display: inline-block; width: 40px; height: 22px; flex-shrink: 0; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch__track { position: absolute; inset: 0; border-radius: 11px; background: var(--color-light-2); transition: background-color var(--dur-fast) var(--ease); }
.switch__track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .2); transition: transform var(--dur-fast) var(--ease); }
.switch input:checked + .switch__track { background: var(--color-brand); }
.switch input:checked + .switch__track::after { transform: translateX(18px); }
.switch input:focus-visible + .switch__track { box-shadow: var(--focus-ring); }
.cookie__actions { display: flex; flex-direction: column; gap: 10px; }
.cookie__btn { min-height: 44px; border-radius: var(--radius-md); font-size: 14px; line-height: 15px; font-weight: 700; color: #fff; }
.btn--outline-ink { color: var(--color-bg); box-shadow: inset 0 0 0 1px var(--color-bg); }
.btn--outline-ink:hover { background: var(--color-bg); color: var(--color-text); }
.cookie__reject { align-self: center; padding: 4px 0; border: 0; background: none; cursor: pointer; font-size: 13px; line-height: 14px; font-weight: 600; color: var(--color-muted-light); }
.cookie__reject:hover { color: var(--color-ink); text-decoration: underline; }
.site-footer__cookies { padding: 0; margin-left: 12px; border: 0; background: none; cursor: pointer; font: inherit; color: inherit; text-decoration: underline; }
.site-footer__cookies:hover { color: var(--color-text); }

/* ── mobile menu (390 sheet) ──────────────────────────────────────────── */
.overlay--menu { display: block; padding: 0; background: var(--color-bg); }
.menu { width: 100%; min-height: 100%; padding: 0; border-radius: 0; background: var(--color-bg); color: var(--color-text); box-shadow: none; transform: translateX(24px); }
.overlay--menu.is-open .menu { transform: none; }
.menu__header { display: flex; justify-content: space-between; align-items: center; height: 56px; padding: 0 20px; background: var(--color-surface); }
.menu__brand { font-family: var(--font-display); font-weight: 900; font-size: 16px; line-height: 20px; color: var(--color-text); text-decoration: none; }
.menu__close { display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 0; background: none; color: var(--color-text); cursor: pointer; }
.menu__close-icon { width: 24px; height: 24px; }
.menu__nav { padding: 32px 20px; }
.menu__item--sep { box-shadow: inset 0 1px 0 var(--color-ink); }
.menu__link { display: flex; justify-content: space-between; align-items: center; height: 56px; font-size: 18px; line-height: 20px; font-weight: 600; color: var(--color-text); text-decoration: none; box-shadow: inset 0 -1px 0 var(--color-ink); transition: color var(--dur-fast) var(--ease), padding var(--dur-fast) var(--ease); }
.menu__link.is-current { padding-inline: 12px; color: var(--color-brand); box-shadow: inset 3px 0 0 var(--color-brand); }
.menu__link:hover { color: var(--color-brand); }
.menu__arrow { font-size: 16px; color: var(--color-muted); }
.menu__link.is-current .menu__arrow { display: none; }
.menu__actions { display: flex; flex-direction: column; gap: var(--space-12); padding: 32px 20px; }
.menu__rg { display: flex; flex-direction: column; gap: var(--space-16); padding: 20px; box-shadow: inset 0 1px 0 var(--color-ink); }
.menu__rg-top { display: flex; flex-direction: column; gap: var(--space-8); align-items: flex-start; }
.menu__rg-think { font-size: 12px; line-height: 13px; color: var(--color-muted); }
.menu__rg-help { display: flex; flex-direction: column; gap: var(--space-4); }
.menu__rg-label { font-size: 13px; line-height: 14px; color: var(--color-text); }
.menu__rg-phone { font-size: 15px; line-height: 16px; font-weight: 700; color: var(--color-text); text-decoration: none; }
.menu__rg-betstop { display: inline-flex; gap: var(--space-6); font-size: 13px; line-height: 14px; font-weight: 700; color: var(--color-brand); text-decoration: none; }

/* ── mobile (390 frames) ──────────────────────────────────────────────── */
@media (max-width: 1199px) {
  .overlay { padding: 16px; }
  .overlay--tall { padding: 12px; }
  .modal--login { padding: 24px; }
  .modal--login .modal__form { margin-top: 24px; }
  .modal--register { margin-block: 0; padding: 24px 20px; }
  .modal--register .modal__form { margin-top: 24px; }
  .modal__row, .modal__row--3 { grid-template-columns: 1fr; }
  .modal--reset { padding: 24px; }
  .modal--limits { padding: 24px; }
  .overlay--gate { padding: 24px; }
  .gate { padding: 32px 28px 28px; }
  .gate__body { width: auto; }
  .overlay--cookie { justify-items: center; padding: 16px; }
  .cookie { padding: 20px; gap: var(--space-18, 18px); }
  .cookie__row--tall .cookie__text, .cookie__row:not(.cookie__row--tall) .cookie__text { width: auto; flex: 1; padding-right: 12px; }
}

/* drawn with the text style "case: UPPER" in the mockup */
.menu__join, .modal__submit--upper { text-transform: uppercase; }
