html, body {
    height: 100%;
    height: 100dvh;
    overscroll-behavior: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

#gameViewport {
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
    box-sizing: border-box;
}

@media (hover: none) and (pointer: coarse) {
    body,
    body * {
        cursor: auto !important;
    }
}

.mobile-pause-btn {
    position: absolute;
    top: 18px;
    left: 18px;
    z-index: 90050;
    width: 48px;
    height: 48px;
    padding: 0;
    border: 2px solid rgba(201, 180, 138, 0.55);
    border-radius: 8px;
    background: rgba(12, 10, 8, 0.72);
    color: rgba(232, 226, 214, 0.95);
    font-size: 14px;
    letter-spacing: 1px;
    line-height: 1;
    backdrop-filter: blur(4px);
}

.mobile-pause-btn:active {
    transform: scale(0.96);
    background: rgba(30, 24, 18, 0.9);
}

.demo-end-text {
    max-width: 720px;
    padding: 24px;
}

.demo-end-kicker {
    margin: 0 0 8px;
    font-family: Cinzel, "Palatino Linotype", serif;
    font-size: 14px;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: rgba(210, 175, 110, 0.8);
}

.demo-end-text h2 {
    margin: 0 0 16px;
}

.demo-end-text p {
    margin: 0 0 28px;
    line-height: 1.45;
}

.demo-end-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
}

.rotate-hint {
    display: none;
}

@media (orientation: portrait) and (max-width: 900px) {
    .rotate-hint {
        position: fixed;
        inset: 0;
        z-index: 999999;
        display: flex;
        align-items: center;
        justify-content: center;
        background: #07060c;
        color: #e8e2d6;
        text-align: center;
        padding: 24px;
    }

    .rotate-hint-card {
        max-width: 280px;
    }

    .rotate-hint-phone {
        width: 42px;
        height: 72px;
        margin: 0 auto 18px;
        border: 3px solid #c9b48a;
        border-radius: 8px;
        animation: rotateHintSpin 1.6s ease-in-out infinite;
    }

    .rotate-hint p {
        margin: 0;
        font-family: Cinzel, "Palatino Linotype", serif;
        font-size: 18px;
        letter-spacing: 0.04em;
        line-height: 1.4;
    }
}

@keyframes rotateHintSpin {
    0%, 20% { transform: rotate(0deg); }
    50%, 70% { transform: rotate(90deg); }
    100% { transform: rotate(0deg); }
}

@media (max-width: 900px) {
    .skip-btn,
    .choice-btn,
    .main-btn,
    .settings-button,
    .menu-item {
        min-height: 44px;
    }

    .mobile-pause-btn {
        top: 12px;
        left: 12px;
    }
}
