/* css/style.css */

:root {
    --color-sakura: #ffb7c5;
    --color-sakura-light: #ffe3e8;
    --color-sakura-dark: #e88d9f;
    --color-vermillion: #d14242;
    --color-vermillion-light: #e65c5c;
    --color-vermillion-dark: #b03030;
    --color-gold: #e5b53b;
    --color-gold-light: #ffd972;
    --color-gold-dark: #b88a1e;
    --color-sumi: #1a1a1a;
    --color-sumi-light: #2b2b2b;
    --color-sumi-dark: #0f0f0f;
    --color-sand: #fbf6ee;
    --color-macha: #687e53;
    
    --font-primary: 'Kosugi Maru', 'Outfit', sans-serif;
    --shadow-premium: 0 10px 30px rgba(0, 0, 0, 0.3);
    --blur-glass: blur(10px);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: var(--color-sumi-dark);
    font-family: var(--font-primary);
    color: var(--color-sand);
    display: flex;
    justify-content: center;
    align-items: center;
}

/* ゲームコンテナの比率固定 (超ワイド2.22:1 - 1200x540基準) */
#game-container {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 1200px;
    height: 540px;
    margin-left: -600px;
    margin-top: -270px;
    background-color: var(--color-sumi);
    box-shadow: var(--shadow-premium);
    overflow: hidden;
    border: 4px solid var(--color-gold);
    border-radius: 16px;
    transform-origin: center center;
}

/* 画面全体のレスポンシブスケール設定はJSで行う */

/* スクリーン管理 */
.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease-in-out;
    display: flex;
    flex-direction: column;
    z-index: 1;
}

.screen.active {
    opacity: 1;
    pointer-events: auto;
    z-index: 2;
}

/* 背景グラデーション */
.sky-gradient-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, #ffccb6 0%, #ffdfd3 40%, #fff6f2 100%);
    z-index: -2;
}

.sakura-bg-canvas-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

/* 戻るボタン */
.btn-back {
    position: absolute;
    top: 20px;
    left: 20px;
    background-color: rgba(0, 0, 0, 0.6);
    border: 2px solid var(--color-sand);
    color: var(--color-sand);
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    font-family: var(--font-primary);
    z-index: 10;
    transition: all 0.2s ease;
}

.btn-back:hover {
    background-color: var(--color-vermillion);
    border-color: var(--color-vermillion-light);
    transform: scale(1.05);
}

/* ボタンの共通スタイル */
.btn {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 30px;
    border: none;
    cursor: pointer;
    font-family: var(--font-primary);
    font-weight: bold;
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-vermillion-light) 0%, var(--color-vermillion) 100%);
    color: white;
    border: 3px solid #ff9e9e;
    box-shadow: 0 6px 15px rgba(209, 66, 66, 0.4);
}

.btn-primary:hover {
    transform: translateY(-4px) scale(1.03);
    box-shadow: 0 10px 20px rgba(209, 66, 66, 0.6);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: var(--blur-glass);
    color: var(--color-sumi-light);
    border: 2.5px solid var(--color-sumi-light);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.btn-secondary:hover {
    background: var(--color-sumi-light);
    color: var(--color-sand);
    transform: translateY(-2px);
}

.btn-danger {
    background: #c95d5d;
    color: white;
    border: 2px solid #ffaaaa;
}

.btn-danger:hover {
    background: #e67373;
}

.btn-large {
    padding: 16px 40px;
    font-size: 22px;
}

.btn-text {
    font-size: 20px;
    letter-spacing: 1.5px;
}

.btn-desc {
    font-size: 11px;
    opacity: 0.85;
    margin-top: 4px;
    font-weight: normal;
}

/* ==========================================
   TITLE SCREEN
   ========================================== */
#title-screen {
    justify-content: center;
    align-items: center;
    text-align: center;
}

.logo-container {
    margin-bottom: 20px;
}

.badge {
    display: inline-block;
    background-color: var(--color-gold);
    color: var(--color-sumi);
    padding: 4px 16px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 8px;
    border: 2px solid white;
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.game-title {
    font-size: 52px;
    color: var(--color-sumi);
    font-weight: 900;
    line-height: 1.15;
    text-shadow: 3px 3px 0 white, 6px 6px 0 rgba(0,0,0,0.1);
}

.title-accent {
    color: var(--color-vermillion);
    font-size: 64px;
    text-shadow: 3px 3px 0 white, -3px -3px 0 white, 3px -3px 0 white, -3px 3px 0 white, 6px 6px 0 rgba(0,0,0,0.15);
}

.menu-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
    width: 100%;
    max-width: 320px;
}

.menu-buttons .btn {
    width: 100%;
}

.audio-control-panel {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: var(--blur-glass);
    padding: 6px 12px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.btn-mute {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 16px;
}

.volume-slider {
    width: 80px;
    accent-color: var(--color-vermillion);
}

.instructions {
    margin-top: 20px;
    font-size: 12px;
    color: var(--color-sumi-light);
    font-weight: bold;
    background: rgba(255,255,255,0.3);
    padding: 4px 12px;
    border-radius: 10px;
}

footer {
    position: absolute;
    bottom: 10px;
    font-size: 10px;
    color: rgba(0,0,0,0.4);
}

/* ==========================================
   STAGE SELECT SCREEN
   ========================================== */
#select-screen {
    background: linear-gradient(135deg, #f4e8c1 0%, #e8d5a2 100%);
    padding: 40px 20px 20px 20px;
    align-items: center;
}

.screen-title {
    font-size: 28px;
    color: var(--color-sumi);
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 8px;
    text-shadow: 1px 1px 0 white;
}

.screen-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 25%;
    width: 50%;
    height: 3px;
    background-color: var(--color-vermillion);
    border-radius: 2px;
}

.stage-grid-wrapper {
    width: 100%;
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.stage-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
    max-width: 800px;
    margin: 0 auto;
}

.stage-card {
    background: rgba(255, 255, 255, 0.7);
    border: 2px solid rgba(0, 0, 0, 0.15);
    border-radius: 16px;
    padding: 15px 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    height: 110px;
    position: relative;
}

.stage-card:hover:not(.locked) {
    transform: translateY(-4px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
    background: white;
    border-color: var(--color-gold);
}

.stage-card.locked {
    background: rgba(0, 0, 0, 0.05);
    border-color: rgba(0, 0, 0, 0.1);
    color: rgba(0, 0, 0, 0.4);
    cursor: not-allowed;
}

.stage-card .stage-num {
    font-size: 14px;
    color: var(--color-sumi-light);
    font-weight: bold;
}

.stage-card .stage-name {
    font-size: 16px;
    font-weight: bold;
    color: var(--color-sumi);
    margin: 4px 0;
}

.stage-card.locked .stage-name {
    color: rgba(0, 0, 0, 0.4);
}

.stage-card .stage-score {
    font-size: 11px;
    color: var(--color-macha);
    font-weight: bold;
}

.stage-card .lock-icon {
    font-size: 24px;
    margin-top: 10px;
}

/* ==========================================
   SHOP SCREEN
   ========================================== */
#shop-screen {
    background: linear-gradient(135deg, #eaf2e3 0%, #cce3bb 100%);
    padding: 40px 20px 20px 20px;
}

.shop-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 800px;
    margin: 0 auto 20px auto;
    padding: 0 10px;
}

.shop-wallet {
    background: var(--color-sumi-light);
    border: 2px solid var(--color-gold);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 18px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.wallet-unit {
    font-size: 12px;
    opacity: 0.8;
}

.shop-content {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.shop-upgrades {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.shop-item {
    background: rgba(255, 255, 255, 0.85);
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 16px;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.shop-item:hover {
    background: white;
    box-shadow: 0 6px 12px rgba(0,0,0,0.1);
}

.item-icon {
    font-size: 36px;
    background: rgba(0, 0, 0, 0.05);
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

.item-details {
    flex: 1;
    color: var(--color-sumi);
}

.item-details h3 {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 4px;
}

.item-desc {
    font-size: 12px;
    opacity: 0.8;
    margin-bottom: 8px;
}

.upgrade-levels {
    display: flex;
    gap: 6px;
}

.upgrade-levels .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #ddd;
    border: 1px solid rgba(0,0,0,0.1);
}

.upgrade-levels .dot.active {
    background-color: var(--color-gold);
    box-shadow: 0 0 6px var(--color-gold);
}

.btn-buy {
    background: linear-gradient(135deg, var(--color-gold-light) 0%, var(--color-gold) 100%);
    border: 2px solid white;
    color: var(--color-sumi);
    padding: 10px 20px;
    border-radius: 20px;
    font-weight: bold;
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: all 0.2s ease;
}

.btn-buy:hover:not(:disabled) {
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

.btn-buy:disabled {
    background: #ccc;
    color: #888;
    cursor: not-allowed;
    border-color: #ddd;
    box-shadow: none;
}

.color-options {
    display: flex;
    gap: 12px;
    margin-top: 8px;
}

.btn-color-select {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 3px solid white;
    cursor: pointer;
    position: relative;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    transition: transform 0.2s ease;
}

.btn-color-select:hover {
    transform: scale(1.15);
}

.btn-color-select.active::after {
    content: '✓';
    color: white;
    font-weight: bold;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-shadow: 0 1px 2px rgba(0,0,0,0.6);
}

.btn-color-select.locked::after {
    content: '🔒';
    font-size: 14px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* ==========================================
   GAMEPLAY SCREEN
   ========================================== */
#play-screen {
    position: relative;
    background-color: #111;
}

#game-canvas {
    display: block;
    width: 100%;
    height: 100%;
}

/* HUD */
#game-hud {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    pointer-events: none;
    z-index: 5;
}

.hud-top-left, .hud-top-right, .hud-top-center {
    display: flex;
    flex-direction: column;
    gap: 6px;
    pointer-events: auto;
}

.hud-hearts {
    font-size: 24px;
    letter-spacing: 2px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.6));
    animation: pulse 1s infinite alternate;
}

.hud-level-info {
    background: rgba(0, 0, 0, 0.6);
    border: 1.5px solid var(--color-gold);
    color: var(--color-sand);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: bold;
    width: fit-content;
}

.hud-top-center {
    align-items: center;
}

.hud-ash-bar-container {
    background: rgba(0, 0, 0, 0.65);
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    border-radius: 14px;
    padding: 6px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 240px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.hud-ash-bar-label {
    font-size: 10px;
    font-weight: bold;
    color: var(--color-sakura-light);
    margin-bottom: 4px;
    letter-spacing: 1px;
}

.hud-ash-bar-bg {
    width: 100%;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid rgba(0,0,0,0.3);
}

.hud-ash-bar-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #ff9eaf 0%, #ff6b8b 100%);
    border-radius: 6px;
    transition: width 0.1s ease;
    box-shadow: 0 0 8px rgba(255, 107, 139, 0.8);
}

.hud-ash-ready {
    font-size: 11px;
    color: var(--color-gold-light);
    font-weight: bold;
    margin-top: 4px;
    text-shadow: 0 0 6px var(--color-gold);
    animation: flash 0.6s infinite alternate;
}

.hud-ash-ready.hidden {
    display: none;
}

.hud-item-ratio {
    background: rgba(0, 0, 0, 0.6);
    border: 1.5px solid var(--color-sand);
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 18px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--color-gold-light);
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

.hud-wagashi-count {
    font-size: 11px;
    color: var(--color-sand);
    opacity: 0.8;
}

.hud-timer {
    background: rgba(0, 0, 0, 0.6);
    color: var(--color-sand);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: bold;
    width: fit-content;
    align-self: flex-end;
}

/* モバイルタッチ操作用ゾーン */
#mobile-touch-zones {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    pointer-events: none;
    z-index: 4;
}

.touch-zone {
    flex: 1;
    height: 100%;
    pointer-events: auto;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 20px;
    font-size: 16px;
    color: rgba(255, 255, 255, 0.15);
    font-weight: bold;
    box-sizing: border-box;
}

#zone-jump {
    background: linear-gradient(to right, rgba(255,255,255,0.01) 0%, transparent 100%);
    border-right: 1px dashed rgba(255, 255, 255, 0.05);
}

#zone-slow {
    background: linear-gradient(to left, rgba(255,255,255,0.01) 0%, transparent 100%);
}

.btn-pause {
    position: absolute;
    top: 75px;
    right: 20px;
    background: rgba(0, 0, 0, 0.5);
    border: 1.5px solid rgba(255, 255, 255, 0.3);
    color: white;
    font-size: 16px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 6;
}

.btn-pause:hover {
    background: rgba(209, 66, 66, 0.8);
}

/* ポーズモーダル */
.modal {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.65);
    backdrop-filter: var(--blur-glass);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 20;
    transition: opacity 0.3s ease;
}

.modal.hidden {
    opacity: 0;
    pointer-events: none;
}

.modal-content {
    background: linear-gradient(135deg, #2b2b2b 0%, #1a1a1a 100%);
    border: 3px solid var(--color-gold);
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    width: 320px;
    box-shadow: var(--shadow-premium);
}

.modal-content h3 {
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--color-gold-light);
}

.modal-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.modal-buttons .btn {
    width: 100%;
    padding: 12px 20px;
}

/* ==========================================
   STAGE CLEAR SCREEN
   ========================================== */
#clear-screen {
    background: linear-gradient(180deg, #ffe5ec 0%, #ffeef2 100%);
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.clear-bg {
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: -2;
}

#clear-sakura-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.clear-panel {
    background: rgba(255, 255, 255, 0.85);
    border: 3px solid var(--color-sakura-dark);
    box-shadow: 0 10px 40px rgba(232, 141, 159, 0.4);
    backdrop-filter: var(--blur-glass);
    border-radius: 24px;
    width: 90%;
    max-width: 600px;
    padding: 24px 30px;
    text-align: center;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.clear-title-wrapper {
    color: var(--color-sumi);
}

.clear-text-jp {
    font-size: 22px;
    color: var(--color-vermillion);
    font-weight: bold;
    letter-spacing: 2px;
}

.clear-stage-name {
    font-size: 32px;
    font-weight: 900;
    color: var(--color-sumi);
    margin-top: 4px;
    text-shadow: 1px 1px 0 white;
}

.clear-stats {
    background: rgba(255, 255, 255, 0.6);
    border: 1.5px dashed var(--color-sakura-dark);
    border-radius: 16px;
    padding: 10px 20px;
    width: 100%;
    max-width: 440px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 15px;
    font-weight: bold;
    color: var(--color-sumi-light);
}

.stat-value {
    font-size: 18px;
    color: var(--color-sumi);
}

.stat-value.highlight {
    font-size: 24px;
    color: var(--color-vermillion);
    font-family: 'Outfit', sans-serif;
    font-weight: 900;
}

.highlight-bloom {
    color: var(--color-macha);
    font-size: 16px;
}

.tree-display-container {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: -10px 0 -45px 0; /* 下マージンをマイナスにして、木の根元がボタンの背後に回り込むように設定 */
    z-index: 1;
}

.canvas-tree-wrapper {
    background-color: transparent; /* 背景白枠を完全に透明化 */
    border: none; /* ボーダーの撤廃 */
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
    width: 480px;
    height: 260px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#result-tree-canvas {
    width: 480px;
    height: 260px;
}

.clear-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    width: 100%;
    z-index: 2; /* 木（z-index: 1）の手前にボタンが配置されるように指定 */
    position: relative;
}

.clear-actions .btn {
    flex: 1;
}

/* ==========================================
   GAME OVER SCREEN
   ========================================== */
#gameover-screen {
    background: linear-gradient(180deg, #2a1b1b 0%, #150e0e 100%);
    justify-content: center;
    align-items: center;
}

.gameover-panel {
    background: rgba(43, 30, 30, 0.85);
    border: 3px solid var(--color-vermillion);
    box-shadow: 0 10px 40px rgba(209, 66, 66, 0.4);
    backdrop-filter: var(--blur-glass);
    border-radius: 24px;
    width: 90%;
    max-width: 480px;
    padding: 30px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.gameover-text-jp {
    font-size: 36px;
    color: var(--color-vermillion-light);
    font-weight: 900;
}

.gameover-sub {
    font-size: 14px;
    opacity: 0.8;
}

.gameover-stats {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 15px 25px;
    width: 100%;
    font-size: 16px;
}

.gameover-stats p {
    margin: 8px 0;
}

.gameover-stats .highlight {
    font-weight: bold;
    color: var(--color-gold-light);
    font-size: 20px;
}

.gameover-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.gameover-actions .btn {
    width: 100%;
}

/* ==========================================
   ANIMATIONS & KEYFRAMES
   ========================================== */
@keyframes pulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.08); }
}

@keyframes flash {
    0% { opacity: 0.3; }
    100% { opacity: 1; }
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.animate-bounce {
    animation: bounce 2s infinite ease-in-out;
}

/* ==========================================
   MOBILE & RESPONSIVE FIT DESIGN
   ========================================== */

/* 縦画面（Portrait）時の横向き推奨警告 */
#orientation-warning {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #0f0f0f;
    z-index: 9999999;
    color: #fbf6ee;
    font-family: var(--font-primary);
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 30px;
    box-sizing: border-box;
}

/* スマートフォンの縦画面のみオーバーレイを有効化 */
@media screen and (max-aspect-ratio: 13/9) and (max-width: 1024px) {
    #orientation-warning {
        display: flex;
    }
}

.warning-content {
    max-width: 420px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid var(--color-gold);
    border-radius: 16px;
    padding: 30px 20px;
    box-shadow: var(--shadow-premium);
}

.warning-content h2 {
    color: var(--color-gold-light);
    font-size: 22px;
    margin-bottom: 12px;
}

.warning-content p {
    font-size: 13px;
    line-height: 1.6;
    opacity: 0.9;
}

.phone-icon-rotate {
    font-size: 72px;
    margin-bottom: 15px;
    display: inline-block;
    animation: rotatePhone 2.2s infinite ease-in-out;
}

@keyframes rotatePhone {
    0% { transform: rotate(0deg); }
    40% { transform: rotate(-90deg); }
    70% { transform: rotate(-90deg); }
    100% { transform: rotate(0deg); }
}

/* モバイルの横画面時、ブラウザのスクロールバーなどの干渉を防ぐためのリセット */
@media screen and (max-width: 1024px) {
    html, body {
        position: fixed;
        width: 100%;
        height: 100%;
        overflow: hidden;
        margin: 0;
        padding: 0;
        touch-action: none; /* ダブルタップズーム等の誤動作防止 */
    }
    
    #game-container {
        /* スマホで全画面に比率を保ちながら綺麗に広がるように、ボーダーとシャドウを少しマイルドに調整 */
        border-width: 2px;
        border-radius: 8px;
    }
}
