.vp-shell {
    --vp-cw: 96px;
    --vp-ch: 136px;
    --vp-gap: 9px;
    --vp-gold: #f4c95d;
    --vp-cab: #101a34;
    max-width: 980px;
    margin: 0 auto;
    padding: 0 0 26px;
    color: var(--cg-ink);
    font-family: Inter, Arial, sans-serif;
}

.vp-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.vp-stats {
    display: flex;
    gap: 8px;
    flex: 1 1 auto;
    min-width: 0;
}

.vp-stat {
    flex: 0 1 auto;
    min-width: 74px;
    padding: 7px 10px;
    border: 1px solid var(--cg-line);
    border-radius: 8px;
    background: var(--cg-panel);
    box-shadow: 0 8px 18px rgba(33, 43, 40, 0.07);
}

.vp-stat span {
    display: block;
    color: var(--cg-muted);
    font-size: 10px;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.vp-stat strong {
    display: block;
    margin-top: 2px;
    font-size: 18px;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.vp-stat:last-child strong {
    font-size: 14px;
    line-height: 1.28;
}

.vp-icons {
    display: flex;
    gap: 8px;
}

.vp-btn,
.vp-close {
    min-height: 44px;
    padding: 0 15px;
    border: 1px solid var(--cg-line);
    border-radius: 8px;
    background: var(--cg-panel);
    color: var(--cg-ink);
    font: inherit;
    font-size: 0.9rem;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 6px 14px rgba(33, 43, 40, 0.07);
    transition: transform 0.12s ease, border-color 0.12s ease, opacity 0.12s ease;
}

.vp-btn kbd {
    margin-left: 5px;
    padding: 1px 4px;
    border: 1px solid currentColor;
    border-radius: 4px;
    opacity: 0.5;
    font: inherit;
    font-size: 0.68rem;
}

.vp-btn:hover:not(:disabled),
.vp-close:hover {
    transform: translateY(-1px);
    border-color: var(--cg-teal);
}

.vp-btn:disabled {
    opacity: 0.42;
    cursor: not-allowed;
}

.vp-btn:focus-visible,
.vp-close:focus-visible,
.vp-slot:focus-visible,
.vp-screen:focus-visible {
    outline: 3px solid rgba(244, 201, 93, 0.7);
    outline-offset: 2px;
}

.vp-icon {
    width: 44px;
    min-width: 44px;
    padding: 0;
    display: inline-grid;
    place-items: center;
    font-size: 1.05rem;
}

.vp-icon svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.vp-primary {
    border-color: transparent;
    background: var(--cg-green);
    color: #fff;
}

.vp-primary:hover:not(:disabled) {
    border-color: transparent;
    filter: brightness(1.08);
}

.vp-cab {
    padding: 12px;
    border: 1px solid #06101f;
    border-radius: 16px;
    background:
        radial-gradient(120% 90% at 50% -10%, #26407a 0%, #16264a 46%, var(--vp-cab) 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16), inset 0 0 60px rgba(0, 0, 0, 0.36), var(--cg-shadow);
}

.vp-marquee {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 9px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(244, 201, 93, 0.28);
}

.vp-marquee b {
    color: var(--vp-gold);
    font-size: clamp(0.86rem, 2.5vw, 1.06rem);
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-shadow: 0 0 14px rgba(244, 201, 93, 0.35);
}

.vp-marquee em {
    font-style: normal;
    color: #fff;
    opacity: 0.75;
}

.vp-marquee span {
    color: rgba(198, 216, 255, 0.72);
    font-size: clamp(0.6rem, 1.9vw, 0.72rem);
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.vp-paywrap {
    overflow-x: auto;
    border: 1px solid rgba(244, 201, 93, 0.4);
    border-radius: 10px;
    background: linear-gradient(180deg, rgba(6, 14, 32, 0.86), rgba(10, 20, 44, 0.7));
}

.vp-pay {
    width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
    color: #e8f0ff;
    font-size: clamp(0.62rem, 1.85vw, 0.8rem);
    font-variant-numeric: tabular-nums;
}

.vp-pay th,
.vp-pay td {
    min-width: 0;
    width: 12.6%;
    padding: 3px 6px;
    text-align: right;
    white-space: nowrap;
}

.vp-pay th:first-child,
.vp-pay tbody th {
    width: 37%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.vp-pay thead th:first-child {
    text-align: left;
}

.vp-pay thead th {
    padding-top: 5px;
    color: rgba(198, 216, 255, 0.6);
    font-size: 0.86em;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.vp-pay tbody th {
    color: var(--vp-gold);
    text-align: left;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.vp-pay tbody tr + tr th,
.vp-pay tbody tr + tr td {
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.vp-pay .is-col {
    background: rgba(244, 201, 93, 0.14);
    color: #fff;
    font-weight: 900;
}

.vp-pay thead .is-col {
    color: var(--vp-gold);
}

.vp-pay tbody tr.is-hit {
    animation: vp-blink 0.5s steps(1) 4;
}

.vp-pay tbody tr.is-hit th,
.vp-pay tbody tr.is-hit td {
    background: rgba(244, 201, 93, 0.3);
    color: #fff;
}

.vp-pay tbody tr.is-hit .is-col {
    background: var(--vp-gold);
    color: #12203f;
}

@keyframes vp-blink {
    50% { opacity: 0.42; }
}

.vp-screen {
    margin-top: 10px;
    padding: 12px 10px 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    background: radial-gradient(120% 130% at 50% 0%, rgba(58, 92, 160, 0.42), rgba(4, 10, 24, 0.5));
    -webkit-user-select: none;
    user-select: none;
}

.vp-hand {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: var(--vp-gap);
    min-height: calc(var(--vp-ch) + 42px);
}

.vp-slot {
    position: relative;
    flex: 0 0 auto;
    width: var(--vp-cw);
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
}

.vp-slot:disabled {
    cursor: default;
}

.vp-holdtag {
    display: block;
    margin: 0 auto 5px;
    padding: 2px 0;
    width: 86%;
    border-radius: 4px;
    background: var(--vp-gold);
    color: #16264a;
    font-size: calc(var(--vp-cw) * 0.15);
    font-weight: 900;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    opacity: 0;
    transform: translateY(4px);
    transition: opacity 0.14s ease, transform 0.14s ease;
}

.vp-slot.is-held .vp-holdtag {
    opacity: 1;
    transform: none;
}

.vp-slot.is-held .vp-card {
    transform: translateY(-6px);
    filter: drop-shadow(0 8px 14px rgba(244, 201, 93, 0.4));
}

.vp-key {
    display: block;
    margin-top: 5px;
    color: rgba(198, 216, 255, 0.55);
    font-size: calc(var(--vp-cw) * 0.16);
    font-weight: 800;
}

.vp-card {
    position: relative;
    display: block;
    width: var(--vp-cw);
    height: var(--vp-ch);
    perspective: 780px;
    transition: transform 0.14s ease;
}

.vp-inner {
    position: absolute;
    inset: 0;
    transform-style: preserve-3d;
    transition: transform 0.4s cubic-bezier(0.3, 0.9, 0.4, 1);
}

.vp-down .vp-inner {
    transform: rotateY(180deg);
}

.vp-empty {
    border: 2px dashed rgba(255, 255, 255, 0.16);
    border-radius: calc(var(--vp-cw) * 0.09);
}

.vp-face,
.vp-back {
    position: absolute;
    inset: 0;
    overflow: hidden;
    border-radius: calc(var(--vp-cw) * 0.09);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.vp-face {
    background: linear-gradient(168deg, #ffffff 0%, #fbfaf4 62%, #f1efe4 100%);
    border: 1px solid #c9cdc2;
    box-shadow: 0 3px 8px rgba(2, 8, 22, 0.5);
    color: #23282b;
}

.vp-red .vp-face {
    color: #c0322b;
}

.vp-back {
    transform: rotateY(180deg);
    background:
        repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.09) 0 4px, transparent 4px 8px),
        repeating-linear-gradient(-45deg, rgba(255, 255, 255, 0.09) 0 4px, transparent 4px 8px),
        linear-gradient(160deg, #3a6fb0, #23497c 60%, #17325c);
    border: 1px solid #12294c;
    box-shadow: 0 3px 8px rgba(2, 8, 22, 0.5);
}

.vp-back::after {
    content: '';
    position: absolute;
    inset: 8%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: calc(var(--vp-cw) * 0.05);
}

.vp-ix {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 0.95;
}

.vp-tl {
    left: 6%;
    top: 3.5%;
}

.vp-br {
    right: 6%;
    bottom: 3.5%;
    transform: rotate(180deg);
}

.vp-ix b {
    font-size: calc(var(--vp-cw) * 0.3);
    font-weight: 800;
    letter-spacing: -0.03em;
}

.vp-ix i {
    margin-top: 1px;
    font-size: calc(var(--vp-cw) * 0.23);
    font-style: normal;
}

.vp-pips {
    position: absolute;
    left: 3%;
    right: 3%;
    top: 8%;
    bottom: 8%;
}

.vp-pip {
    position: absolute;
    font-size: calc(var(--vp-cw) * 0.22);
    font-style: normal;
    line-height: 1;
    transform: translate(-50%, -50%);
}

.vp-pip.vp-flip {
    transform: translate(-50%, -50%) rotate(180deg);
}

.vp-big {
    position: absolute;
    left: 50%;
    top: 50%;
    font-size: calc(var(--vp-cw) * 0.5);
    font-style: normal;
    line-height: 1;
    opacity: 0.92;
    transform: translate(-50%, -50%);
}

.vp-alt {
    display: none;
}

.vp-compact .vp-pips {
    display: none;
}

.vp-compact .vp-alt {
    display: block;
}

.vp-court {
    position: absolute;
    left: 20%;
    right: 20%;
    top: 19%;
    bottom: 19%;
    display: grid;
    place-items: center;
    border-radius: calc(var(--vp-cw) * 0.05);
    overflow: hidden;
}

.vp-court::before,
.vp-court::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
}

.vp-court::before {
    background: currentColor;
    opacity: 0.07;
}

.vp-court::after {
    border: 1px solid currentColor;
    opacity: 0.32;
}

.vp-court b {
    position: relative;
    z-index: 1;
    font-size: calc(var(--vp-cw) * 0.44);
    line-height: 1.05;
}

.vp-court i {
    position: absolute;
    z-index: 1;
    right: 6%;
    bottom: 2%;
    font-size: calc(var(--vp-cw) * 0.19);
    font-style: normal;
}

.vp-meter {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-top: 10px;
    padding: 7px 10px;
    border-radius: 8px;
    background: rgba(2, 8, 22, 0.55);
    color: rgba(198, 216, 255, 0.65);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.vp-meter b {
    margin-left: 6px;
    color: var(--vp-gold);
    font-size: 1.02rem;
    letter-spacing: 0;
    font-variant-numeric: tabular-nums;
}

.vp-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.vp-status {
    margin: 10px 2px 0;
    min-height: 20px;
    color: var(--cg-muted);
    font-size: 0.9rem;
    font-weight: 600;
}

.vp-result {
    margin-top: 10px;
    padding: 14px 16px;
    border: 1px solid #b9d6c9;
    border-left: 4px solid var(--cg-green);
    border-radius: 12px;
    background: linear-gradient(135deg, #eef8f3, #ffffff 62%);
    box-shadow: var(--cg-shadow);
    text-align: center;
    animation: vp-rise 0.22s ease;
}

.vp-result.is-bad {
    border-left-color: var(--cg-amber);
}

@keyframes vp-rise {
    from { opacity: 0; transform: translateY(7px); }
}

.vp-kicker {
    display: block;
    color: var(--cg-teal);
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.vp-result strong {
    display: block;
    margin: 3px 0 4px;
    font-size: 1.32rem;
    font-variant-numeric: tabular-nums;
}

.vp-hint {
    margin: 0 auto 10px;
    max-width: 62ch;
    color: var(--cg-muted);
    font-size: 0.86rem;
    line-height: 1.45;
}

.vp-res-actions {
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.vp-modal {
    position: fixed;
    inset: 0;
    z-index: 60;
    display: grid;
    place-items: center;
    padding: 16px;
    background: rgba(8, 16, 34, 0.6);
}

.vp-modal-card {
    position: relative;
    width: min(100%, 480px);
    max-height: 86vh;
    overflow-y: auto;
    padding: 22px;
    border: 1px solid var(--cg-line);
    border-radius: 12px;
    background: var(--cg-panel);
    box-shadow: 0 24px 70px rgba(8, 16, 34, 0.34);
}

.vp-modal-card h2 {
    margin: 0 44px 10px 0;
    font-size: 1.18rem;
}

.vp-modal-card p {
    margin: 0 0 10px;
    color: var(--cg-muted);
    font-size: 0.9rem;
    line-height: 1.48;
}

.vp-modal-card kbd,
.vp-shell kbd {
    font: inherit;
}

.vp-modal-card kbd {
    padding: 1px 5px;
    border: 1px solid var(--cg-line);
    border-radius: 4px;
    background: var(--cg-bg);
    font-size: 0.8rem;
    font-weight: 800;
}

.vp-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 40px;
    padding: 0;
    font-size: 22px;
    line-height: 1;
}

@media (prefers-reduced-motion: reduce) {
    .vp-inner { transition: none; }
    .vp-pay tbody tr.is-hit { animation: none; }
}

@media (max-width: 640px) {
    .vp-shell {
        padding-bottom: 18px;
    }

    .vp-stat {
        min-width: 0;
        flex: 1 1 0;
        padding: 6px 7px;
    }

    .vp-stat strong {
        font-size: 15px;
    }

    .vp-wide {
        display: none;
    }

    .vp-icons {
        gap: 6px;
    }

    .vp-btn,
    .vp-close {
        min-height: 42px;
        padding: 0 12px;
        font-size: 0.84rem;
    }

    .vp-btn kbd {
        display: none;
    }

    .vp-icon {
        width: 42px;
        min-width: 42px;
    }

    .vp-cab {
        padding: 8px;
        border-radius: 12px;
    }

    .vp-pay th,
    .vp-pay td {
        padding: 3px 4px;
    }

    .vp-screen {
        padding: 10px 6px 8px;
    }

    .vp-meter {
        font-size: 0.6rem;
        letter-spacing: 0.04em;
    }

    .vp-meter b {
        font-size: 0.92rem;
        margin-left: 4px;
    }

    .vp-controls {
        gap: 6px;
    }

    .vp-controls .vp-btn {
        flex: 1 1 0;
    }
}
