@layer components {
  .dock {
    display: grid;
    align-items: end;
    justify-items: center;
    padding: 0 12px 8px;
  }

  .dock__inner {
    position: relative;
    width: min(800px, 100%);
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    column-gap: 16px;
    padding: 7px 18px 9px;
    border-radius: 26px 26px 20px 20px;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0) 40%),
      radial-gradient(60% 130% at 50% 0%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%),
      linear-gradient(180deg, color-mix(in srgb, var(--deep) 45%, rgba(40, 26, 76, 0.86)), color-mix(in srgb, var(--deep) 55%, rgba(12, 8, 26, 0.94)));
    box-shadow:
      0 0 0 1px rgba(0, 0, 0, 0.6),
      0 0 0 3px rgba(240, 181, 52, 0.55),
      0 -10px 36px rgba(0, 0, 0, 0.32),
      0 16px 36px rgba(0, 0, 0, 0.48),
      inset 0 1px 0 rgba(255, 255, 255, 0.22);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    backdrop-filter: blur(14px) saturate(140%);
  }

  .dock__inner::before {
    content: '';
    position: absolute;
    left: 10%;
    right: 10%;
    top: -1px;
    height: 2px;
    border-radius: 99px;
    background: linear-gradient(90deg, transparent, #fff3c0, transparent);
    opacity: 0.8;
  }

  .dock__side {
    display: flex;
    align-items: center;
    min-width: 0;
  }

  .dock__side--left {
    justify-content: flex-end;
  }

  .dock__side--right {
    justify-content: flex-start;
  }

  .dock__center {
    display: grid;
    justify-items: center;
    gap: 7px;
    margin-top: -32px;
  }

  .spin {
    position: relative;
    display: grid;
    place-items: center;
  }

  .spin__lights {
    position: absolute;
    inset: -8px;
    border-radius: 36px;
    padding: 5px;
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
    opacity: 0;
    filter: drop-shadow(0 0 10px rgba(255, 210, 90, 0.8));
    transition: opacity 0.3s ease;
    pointer-events: none;
  }

  .spin__lights::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 116%;
    aspect-ratio: 1;
    margin: -58% 0 0 -58%;
    background: conic-gradient(#fff6c0, #ffd44a, #ff7a3d, #ff5a9e, #b28bff, #5de9ff, #5ee06a, #fff6c0);
  }

  .spin__btn {
    position: relative;
    width: 196px;
    height: 74px;
    border-radius: 28px;
    display: grid;
    place-content: center;
    justify-items: center;
    gap: 1px;
    overflow: hidden;
    isolation: isolate;
    color: #fff;
    background:
      radial-gradient(120% 70% at 50% -5%, rgba(214, 255, 170, 0.95) 0%, rgba(214, 255, 170, 0) 55%),
      linear-gradient(180deg, #74f36e 0%, #33cf45 46%, #17a02e 100%);
    box-shadow:
      0 0 0 3px #10330f,
      0 7px 0 0 #0d6b20,
      0 7px 0 3px #10330f,
      0 16px 28px rgba(0, 0, 0, 0.55),
      inset 0 3px 0 rgba(255, 255, 255, 0.7),
      inset 0 -8px 16px rgba(0, 70, 16, 0.35);
    transform: translateY(0);
    transition: transform 0.09s ease;
    -webkit-user-select: none;
    user-select: none;
    touch-action: none;
  }

  .spin__btn::before {
    content: '';
    position: absolute;
    inset: 5px 12px auto;
    height: 38%;
    border-radius: 20px 20px 60% 60%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0));
    z-index: -1;
  }

  .spin__shine {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 36%;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0));
    transform: translateX(-120%) skewX(-18deg);
    animation: shine-sweep 3.6s var(--ease-soft) 1.2s infinite;
    z-index: 1;
    pointer-events: none;
  }

  .spin__label {
    position: relative;
    z-index: 2;
    font-size: 33px;
    line-height: 1;
    font-weight: 900;
    letter-spacing: 0.05em;
    text-shadow: 0 3px 0 #0b5a1b, 0 0 14px rgba(255, 255, 255, 0.35);
  }

  .spin__hint {
    position: relative;
    z-index: 2;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.15em;
    color: rgba(255, 255, 255, 0.86);
    text-shadow: 0 1px 0 rgba(0, 60, 10, 0.8);
  }

  .spin.is-pressed .spin__btn {
    transform: translateY(5px);
    box-shadow:
      0 0 0 3px #10330f,
      0 2px 0 0 #0d6b20,
      0 2px 0 3px #10330f,
      0 7px 14px rgba(0, 0, 0, 0.5),
      inset 0 3px 0 rgba(255, 255, 255, 0.55),
      inset 0 -6px 12px rgba(0, 70, 16, 0.45);
  }

  .spin.is-flash::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 220px;
    height: 220px;
    margin: -110px 0 0 -110px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.85), rgba(255, 240, 160, 0.35) 35%, rgba(255, 240, 160, 0) 62%);
    animation: spin-flash 0.5s var(--ease-out) forwards;
    pointer-events: none;
  }

  .spin[data-mode='spinning'] .spin__hint,
  .spin[data-mode='busy'] .spin__hint {
    opacity: 0.7;
  }

  .spin[data-mode='auto'] .spin__btn {
    background:
      radial-gradient(120% 70% at 50% -5%, rgba(255, 246, 190, 0.95) 0%, rgba(255, 246, 190, 0) 55%),
      linear-gradient(180deg, #ffd84a 0%, #ffab1a 48%, #e27a00 100%);
    box-shadow:
      0 0 0 3px #3a1d00,
      0 7px 0 0 #9a4a00,
      0 7px 0 3px #3a1d00,
      0 16px 28px rgba(0, 0, 0, 0.55),
      0 0 30px rgba(255, 186, 40, 0.7),
      inset 0 3px 0 rgba(255, 255, 255, 0.75),
      inset 0 -8px 16px rgba(120, 50, 0, 0.35);
  }

  .spin[data-mode='auto'] .spin__btn::after,
  .spin.is-pressed .spin__btn::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: rgba(255, 255, 255, 0.22);
    animation: glow-breathe 0.9s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
  }

  .spin.is-pressed .spin__btn::after {
    background: rgba(255, 255, 255, 0.14);
    animation: none;
  }

  .spin[data-mode='auto'] .spin__label {
    text-shadow: 0 3px 0 #8a4200, 0 0 14px rgba(255, 255, 255, 0.45);
  }

  .spin[data-mode='auto'] .spin__hint {
    text-shadow: 0 1px 0 rgba(90, 40, 0, 0.9);
  }

  .spin[data-mode='auto'] .spin__lights,
  .spin.is-lit .spin__lights {
    opacity: 1;
  }

  .spin[data-mode='auto'] .spin__lights::before,
  .spin.is-lit .spin__lights::before {
    animation: ring-spin 1.1s linear infinite;
  }

  .spin[data-mode='empty'] .spin__btn {
    filter: saturate(0.35) brightness(0.8);
  }

  .energy {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    column-gap: 7px;
    width: 256px;
  }

  .energy__icon {
    width: 22px;
    height: 22px;
    filter: drop-shadow(0 0 6px rgba(255, 210, 80, 0.6));
  }

  .energy__bar {
    position: relative;
    height: 18px;
    border-radius: 99px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.5);
    box-shadow: inset 0 0 0 1px rgba(255, 228, 160, 0.3), inset 0 2px 4px rgba(0, 0, 0, 0.5);
  }

  .energy__fill {
    position: absolute;
    inset: 2px;
    border-radius: inherit;
    transform-origin: 0 50%;
    transform: scaleX(var(--fill, 1));
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.45), rgba(255, 255, 255, 0) 55%),
      linear-gradient(90deg, #ff9d00, #ffd23f 70%, #fff08a);
    box-shadow: 0 0 12px rgba(255, 190, 40, 0.55);
    transition: transform 0.45s var(--ease-out);
  }

  .energy[data-over='true'] .energy__fill {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.45), rgba(255, 255, 255, 0) 55%),
      linear-gradient(90deg, #36e3ff, #b28bff 60%, #ff7ae0);
  }

  .energy[data-low='true'] .energy__fill {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0) 55%),
      linear-gradient(90deg, #ff3d55, #ff8a3d);
  }

  .energy__text {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: 11px;
    font-weight: 900;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.9), 0 0 6px rgba(0, 0, 0, 0.6);
  }

  .energy__timer {
    min-width: 64px;
    font-size: 10.5px;
    font-weight: 800;
    color: var(--text-dim);
    white-space: nowrap;
  }

  .energy.is-bump .energy__fill {
    animation: glow-breathe 0.5s ease 2;
  }

  .bet {
    display: grid;
    grid-template-columns: auto auto auto;
    align-items: center;
    gap: 7px;
  }

  .bet__step {
    position: relative;
    width: 40px;
    height: 40px;
    border-radius: 13px;
    background:
      radial-gradient(120% 70% at 50% 0%, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 55%),
      linear-gradient(180deg, #b58cff, #7a4de0 55%, #5a33b8);
    box-shadow:
      0 0 0 2px #1b0c3a,
      0 4px 0 0 #3b2080,
      0 4px 0 2px #1b0c3a,
      0 8px 14px rgba(0, 0, 0, 0.45),
      inset 0 2px 0 rgba(255, 255, 255, 0.5);
    transition: transform 0.08s ease;
  }

  .bet__step::before,
  .bet__step::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 16px;
    height: 4.5px;
    margin: -2.25px 0 0 -8px;
    border-radius: 3px;
    background: #fff;
    box-shadow: 0 2px 0 rgba(40, 14, 90, 0.8);
  }

  .bet__step::after {
    display: none;
  }

  .bet__step--up::after {
    display: block;
    transform: rotate(90deg);
    box-shadow: 2px 0 0 rgba(40, 14, 90, 0.8);
  }

  .bet__step:active:not(:disabled) {
    transform: translateY(3px);
    box-shadow:
      0 0 0 2px #1b0c3a,
      0 1px 0 0 #3b2080,
      0 1px 0 2px #1b0c3a,
      0 4px 8px rgba(0, 0, 0, 0.45),
      inset 0 2px 0 rgba(255, 255, 255, 0.4);
  }

  .bet__step:disabled {
    filter: grayscale(0.85) brightness(0.65);
    cursor: var(--cursor-arrow, default);
  }

  .bet__display {
    min-width: 86px;
    padding: 4px 15px 5px 11px;
    display: grid;
    justify-items: center;
    border-radius: 12px;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.3));
    box-shadow: inset 0 0 0 1px rgba(255, 228, 160, 0.28), inset 0 2px 6px rgba(0, 0, 0, 0.6);
  }

  .bet__label {
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 0.2em;
    color: var(--text-faint);
  }

  .bet__value {
    font-size: 21px;
    line-height: 1.05;
    font-weight: 900;
  }

  .bet__value.is-bump {
    animation: value-bump 0.35s var(--ease-spring);
  }

  .bet__cost {
    font-size: 9px;
    font-weight: 800;
    color: var(--text-dim);
    white-space: nowrap;
  }

  .auto {
    position: relative;
    height: 50px;
    padding: 0 15px 0 8px;
    display: grid;
    grid-template-columns: auto auto;
    align-items: center;
    column-gap: 7px;
    border-radius: 16px;
    background:
      radial-gradient(120% 70% at 50% 0%, rgba(255, 255, 255, 0.45), rgba(255, 255, 255, 0) 55%),
      linear-gradient(180deg, #3a2a6e, #231648 60%, #180e34);
    box-shadow:
      0 0 0 2px #0c0620,
      0 4px 0 0 #120a2c,
      0 4px 0 2px #0c0620,
      0 8px 14px rgba(0, 0, 0, 0.45),
      inset 0 2px 0 rgba(255, 255, 255, 0.25),
      inset 0 0 0 1px rgba(255, 228, 160, 0.25);
    transition: transform 0.08s ease;
  }

  .auto:active {
    transform: translateY(3px);
  }

  .auto__icon {
    width: 32px;
    height: 32px;
    transition: transform 0.4s var(--ease-spring);
  }

  .auto__label {
    font-size: 13.5px;
    font-weight: 900;
    letter-spacing: 0.08em;
  }

  .auto__count {
    position: absolute;
    top: -9px;
    right: -9px;
    min-width: 24px;
    height: 24px;
    padding: 0 6px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    font-size: 11.5px;
    font-weight: 900;
    color: #1a0c02;
    background: linear-gradient(180deg, #fff3b0, #ffc53d);
    box-shadow: 0 0 0 2px #1a0c02, 0 3px 8px rgba(0, 0, 0, 0.5);
  }

  .auto__count:empty {
    display: none;
  }

  .auto[aria-pressed='true'] {
    box-shadow:
      0 0 0 2px #0c0620,
      0 4px 0 0 #120a2c,
      0 4px 0 2px #0c0620,
      0 0 24px rgba(94, 224, 106, 0.6),
      inset 0 2px 0 rgba(255, 255, 255, 0.25),
      inset 0 0 0 2px rgba(94, 224, 106, 0.8);
  }

  .auto[aria-pressed='true'] .auto__icon {
    animation: spin-slow 1.4s linear infinite;
  }

  .auto__lock {
    position: absolute;
    inset: 0;
    display: none;
    place-items: center;
    align-content: center;
    grid-auto-flow: column;
    gap: 4px;
    border-radius: inherit;
    font-size: 12px;
    font-weight: 900;
    color: var(--gold);
    background: rgba(5, 3, 12, 0.55);
  }

  .auto__lock img {
    width: 18px;
    height: 18px;
  }

  .auto[data-locked='true'] .auto__icon,
  .auto[data-locked='true'] .auto__label {
    filter: grayscale(1) brightness(0.5);
  }

  .auto[data-locked='true'] .auto__lock {
    display: grid;
  }

  .auto-picker {
    position: absolute;
    bottom: calc(100% + 14px);
    right: 0;
    z-index: 5;
    display: grid;
    grid-template-columns: repeat(5, auto);
    gap: 6px;
    padding: 8px;
    border-radius: 18px;
    transform-origin: 80% 100%;
    animation: picker-in 0.28s var(--ease-spring);
  }

  .auto-picker button {
    min-width: 50px;
    height: 44px;
    padding: 0 10px;
    border-radius: 13px;
    font-size: 16px;
    font-weight: 900;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.04));
    box-shadow: inset 0 0 0 1px rgba(255, 228, 160, 0.3);
    transition: background 0.15s ease, transform 0.1s ease;
  }

  .auto-picker button:hover {
    background: linear-gradient(180deg, #ffe07a, #f0a91d);
    color: #1a0c02;
  }

  .auto-picker button:active {
    transform: scale(0.94);
  }

  .dock__right-wrap {
    position: relative;
  }

  .dock__left-wrap {
    position: relative;
  }

  .bet__display {
    position: relative;
    border: 0;
    cursor: var(--cursor-hand, pointer);
    transition: transform 0.08s ease;
  }

  .bet__display:hover:not(:disabled) {
    box-shadow: inset 0 0 0 1px rgba(255, 228, 160, 0.7), inset 0 2px 6px rgba(0, 0, 0, 0.6);
  }

  .bet__display:active:not(:disabled) {
    transform: scale(0.96);
  }

  .bet__display:disabled {
    cursor: var(--cursor-arrow, default);
  }

  .bet__caret {
    position: absolute;
    right: 5px;
    top: 50%;
    width: 0;
    height: 0;
    margin-top: -2px;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid rgba(255, 228, 160, 0.75);
  }

  .bet__display[aria-expanded='true'] .bet__caret {
    rotate: 180deg;
  }

  .bet-picker {
    position: absolute;
    bottom: calc(100% + 14px);
    left: 0;
    z-index: 5;
    width: min(320px, calc(100vw - 28px));
    padding: 10px;
    border-radius: 18px;
    transform-origin: 20% 100%;
    animation: picker-in 0.28s var(--ease-spring);
  }

  .bet-picker__head {
    display: grid;
    gap: 2px;
    padding: 0 2px 8px;
    text-align: center;
  }

  .bet-picker__head b {
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.16em;
    color: var(--gold, #ffd44a);
  }

  .bet-picker__note {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--text-faint);
  }

  .bet-picker__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    max-height: min(46vh, 260px);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 2px;
  }

  .bet-picker__grid button {
    display: grid;
    gap: 1px;
    height: 42px;
    padding: 0 4px;
    border-radius: 12px;
    place-content: center;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.04));
    box-shadow: inset 0 0 0 1px rgba(255, 228, 160, 0.3);
    transition: background 0.15s ease, transform 0.1s ease;
  }

  .bet-picker__split {
    grid-column: 1 / -1;
    margin-top: 4px;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 9.5px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-align: center;
    color: #2a0a00;
    background: linear-gradient(90deg, #ffb13d, #ff5f7a);
  }

  .bet-picker__grid button[data-high='true'] {
    background: linear-gradient(180deg, rgba(255, 120, 90, 0.32), rgba(255, 60, 90, 0.12));
    box-shadow: inset 0 0 0 1px rgba(255, 150, 110, 0.7);
  }

  .bet-picker__grid button b {
    font-size: 14px;
    font-weight: 900;
    line-height: 1;
  }

  .bet-picker__grid button small {
    font-size: 8.5px;
    font-weight: 800;
    letter-spacing: 0.06em;
    color: var(--text-faint);
  }

  .bet-picker__grid button:hover:not(:disabled) {
    background: linear-gradient(180deg, #ffe07a, #f0a91d);
    color: #1a0c02;
  }

  .bet-picker__grid button:hover:not(:disabled) small {
    color: rgba(26, 12, 2, 0.7);
  }

  .bet-picker__grid button:active:not(:disabled) {
    transform: scale(0.94);
  }

  .bet-picker__grid button.is-on {
    background: linear-gradient(180deg, #b58cff, #7a4de0);
    box-shadow: inset 0 0 0 1.5px #ffe9a0;
    color: #fff;
  }

  .bet-picker__grid button:disabled {
    opacity: 0.4;
    cursor: var(--cursor-arrow, default);
  }

  .bet-picker__foot {
    padding-top: 8px;
  }

  .bet-picker__max {
    width: 100%;
    height: 38px;
    border-radius: 13px;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 0.1em;
    color: #1a0c02;
    background: linear-gradient(180deg, #ffe07a, #f0a91d);
    box-shadow: inset 0 0 0 1.5px rgba(26, 12, 2, 0.5);
    transition: transform 0.1s ease, filter 0.15s ease;
  }

  .bet-picker__max:active:not(:disabled) {
    transform: scale(0.97);
  }

  .bet-picker__max:disabled {
    filter: grayscale(0.7) brightness(0.7);
    cursor: var(--cursor-arrow, default);
  }

  @media (max-width: 760px) {
    .dock {
      padding: 0 8px 6px;
    }

    .dock__inner {
      grid-template-areas:
        'left spin right'
        'energy energy energy';
      column-gap: 8px;
      row-gap: 6px;
      padding: 6px 10px 7px;
      border-radius: 22px 22px 18px 18px;
    }

    .dock__side--left {
      grid-area: left;
    }

    .dock__side--right {
      grid-area: right;
    }

    .dock__center {
      display: contents;
    }

    .spin {
      grid-area: spin;
      margin-top: -12px;
    }

    .spin__btn {
      width: 160px;
      height: 62px;
      border-radius: 24px;
    }

    .spin__lights {
      border-radius: 32px;
    }

    .spin__label {
      font-size: 29px;
    }

    .spin__hint {
      font-size: 9px;
      letter-spacing: 0.12em;
    }

    .energy {
      grid-area: energy;
      width: 100%;
    }

    .energy__icon {
      width: 18px;
      height: 18px;
    }

    .energy__bar {
      height: 16px;
    }

    .energy__timer {
      min-width: 0;
      font-size: 10px;
    }

    .bet {
      grid-template-columns: auto auto;
      grid-template-areas:
        'display display'
        'down up';
      justify-items: center;
      gap: 3px 4px;
    }

    .bet__display {
      grid-area: display;
      min-width: 0;
      width: 100%;
      padding: 2px 6px 3px;
      border-radius: 10px;
    }

    .bet__label {
      font-size: 9px;
      letter-spacing: 0.16em;
    }

    .bet__value {
      font-size: 16px;
    }

    .bet__cost {
      display: none;
    }

    .bet__step--down {
      grid-area: down;
    }

    .bet__step--up {
      grid-area: up;
    }

    .bet__step {
      width: 30px;
      height: 24px;
      border-radius: 9px;
      box-shadow:
        0 0 0 2px #1b0c3a,
        0 3px 0 0 #3b2080,
        0 3px 0 2px #1b0c3a,
        0 6px 10px rgba(0, 0, 0, 0.4),
        inset 0 2px 0 rgba(255, 255, 255, 0.5);
    }

    .bet__step::before,
    .bet__step::after {
      width: 12px;
      height: 3.5px;
      margin: -1.75px 0 0 -6px;
    }

    .auto {
      height: 46px;
      padding: 0 11px 0 8px;
      grid-template-columns: auto;
      justify-items: center;
      row-gap: 0;
      border-radius: 15px;
    }

    .auto__icon {
      width: 26px;
      height: 26px;
    }

    .auto__label {
      font-size: 10px;
    }

    .auto-picker {
      grid-template-columns: repeat(5, auto);
      right: -4px;
    }

    .auto-picker button {
      min-width: 42px;
      height: 40px;
      font-size: 14px;
    }
  }

  @media (orientation: portrait) and (max-aspect-ratio: 4/5) and (max-height: 800px) {
    .dock {
      padding-bottom: 5px;
    }

    .dock__inner {
      row-gap: 5px;
      padding: 5px 10px 6px;
    }

    .spin {
      margin-top: -10px;
    }

    .spin__btn {
      width: 150px;
      height: 56px;
      border-radius: 22px;
    }

    .spin__label {
      font-size: 27px;
    }

    .energy__bar {
      height: 15px;
    }

    .auto {
      height: 44px;
    }
  }

  @media (orientation: portrait) and (max-aspect-ratio: 4/5) and (max-height: 620px) {
    .spin {
      margin-top: -8px;
    }

    .spin__btn {
      width: 140px;
      height: 50px;
      border-radius: 20px;
    }

    .spin__label {
      font-size: 24px;
    }

    .spin__hint {
      display: none;
    }

    .bet__step {
      height: 22px;
    }

    .bet__value {
      font-size: 15px;
    }

    .auto {
      height: 40px;
    }
  }

  @media (orientation: portrait) and (max-width: 360px) {
    .dock__inner {
      column-gap: 6px;
      padding-inline: 8px;
    }

    .spin__btn {
      width: 132px;
    }

    .spin__label {
      font-size: 25px;
    }

    .bet__step {
      width: 27px;
    }
  }

  @media (max-height: 540px) and (orientation: landscape) {
    .dock {
      padding-bottom: 5px;
    }

    .dock__inner {
      width: min(700px, 100%);
      grid-template-areas: none;
      padding: 4px 12px;
      column-gap: 10px;
      row-gap: 0;
    }

    .dock__side--left,
    .dock__side--right {
      grid-area: auto;
    }

    .dock__center {
      display: grid;
      margin-top: -10px;
      gap: 4px;
      grid-template-columns: auto auto;
      align-items: center;
      column-gap: 12px;
    }

    .spin {
      grid-area: auto;
      margin-top: 0;
    }

    .spin__btn {
      width: 124px;
      height: 50px;
      border-radius: 20px;
    }

    .spin__lights {
      border-radius: 28px;
    }

    .spin__label {
      font-size: 24px;
    }

    .spin__hint {
      display: none;
    }

    .energy {
      grid-area: auto;
      width: 160px;
    }

    .energy__icon {
      width: 20px;
      height: 20px;
    }

    .energy__bar {
      height: 16px;
    }

    .energy__timer {
      display: none;
    }

    .bet {
      grid-template-columns: auto auto auto;
      grid-template-areas: none;
      grid-template-rows: none;
      gap: 6px;
    }

    .bet__display,
    .bet__step--up,
    .bet__step--down {
      grid-area: auto;
      order: 0;
    }

    .bet__step {
      width: 34px;
      height: 34px;
      border-radius: 11px;
    }

    .bet__step::before,
    .bet__step::after {
      width: 14px;
      height: 4px;
      margin: -2px 0 0 -7px;
    }

    .bet__display {
      width: auto;
      min-width: 62px;
      padding: 2px 7px 3px;
    }

    .bet__value {
      font-size: 18px;
    }

    .bet__cost {
      display: none;
    }

    .auto {
      height: 42px;
    }
  }

  @media (max-height: 540px) and (orientation: landscape) and (max-width: 900px) {
    .dock {
      padding: 0 6px 5px;
    }

    .dock__inner {
      grid-template-columns: auto auto auto;
      justify-content: space-between;
      padding: 3px 8px;
      column-gap: 6px;
      border-radius: 18px 18px 14px 14px;
    }

    .dock__center {
      margin-top: -8px;
      column-gap: 8px;
    }

    .spin__btn {
      width: 100px;
      height: 44px;
      border-radius: 17px;
    }

    .spin__lights {
      border-radius: 24px;
    }

    .spin__label {
      font-size: 21px;
    }

    .energy {
      width: clamp(88px, calc(100vw - 540px), 164px);
      column-gap: 5px;
    }

    .energy__icon {
      width: 18px;
      height: 18px;
    }

    .bet {
      gap: 5px;
    }

    .bet__step {
      width: 30px;
      height: 30px;
      border-radius: 10px;
    }

    .bet__display {
      min-width: 50px;
      padding: 2px 6px 3px;
    }

    .bet__value {
      font-size: 16px;
    }

    .bet__label {
      font-size: 9px;
    }

    .auto {
      height: 38px;
      padding: 0 6px;
      column-gap: 0;
    }

    .auto__icon {
      width: 28px;
      height: 28px;
    }

    .auto__label {
      display: none;
    }
  }

  @media (max-height: 540px) and (orientation: landscape) and (max-width: 600px) {
    .spin__btn {
      width: 90px;
      height: 40px;
    }

    .spin__label {
      font-size: 19px;
    }

    .energy {
      width: 64px;
    }

    .energy__icon {
      display: none;
    }

    .bet__step {
      width: 26px;
      height: 26px;
    }

    .bet__display {
      min-width: 44px;
    }

    .auto {
      height: 36px;
      padding: 0 4px;
    }

    .auto__icon {
      width: 24px;
      height: 24px;
    }
  }
}

@layer fx {
  @keyframes ring-spin {
    from {
      rotate: 0deg;
    }

    to {
      rotate: 360deg;
    }
  }

  @keyframes spin-flash {
    from {
      opacity: 1;
      transform: scale(0.4);
    }

    to {
      opacity: 0;
      transform: scale(1.35);
    }
  }

  @keyframes picker-in {
    from {
      opacity: 0;
      transform: translateY(10px) scale(0.85);
    }

    to {
      opacity: 1;
      transform: none;
    }
  }
}

@layer components {
  .spin__free {
    position: absolute;
    top: -12px;
    right: -10px;
    z-index: 3;
    padding: 3px 8px;
    border-radius: 99px;
    font-size: 11.5px;
    font-weight: 900;
    letter-spacing: 0.06em;
    color: #0a2a0e;
    background: linear-gradient(180deg, #d6ffb8, #45d45e);
    box-shadow: 0 0 0 2px #10330f, 0 4px 10px rgba(0, 0, 0, 0.45), 0 0 14px rgba(94, 224, 106, 0.6);
    animation: badge-in 0.4s var(--ease-spring);
    pointer-events: none;
  }
}
