/* デザインシステムと共通変数（シニア向け文字拡大・高コントラスト） */
:root {
    --bg-color: #FDFBF7; /* 共通ベージュ背景 */
    --panel-bg: #ffffff;
    --text-primary: #333333;
    --text-secondary: #555555;
    --accent-color: #E8834A; /* 共通メインオレンジ */
    --accent-hover: #d2723c;
    --correct-color: #5B9E6E;
    --error-color: #ef4444;
    --font-sans: 'Hiragino Maru Gothic ProN', 'BIZ UDPGothic', 'Meiryo', sans-serif;
    --shadow-premium: 0 6px 20px rgba(232, 131, 74, 0.1);
}

/* 全体設定 */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
    -webkit-user-drag: none;
}

body {
    font-family: var(--font-sans);
    background: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 共通固定ナビゲーションバー */
/* グローバルナビ（他ゲームと共通） */
.g-nav {
    position: fixed; top: 0; left: 0; right: 0; height: 52px;
    background: #E8834A; display: flex; align-items: center;
    padding: 0 16px; z-index: 100; gap: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.g-nav-arrow { color: white; font-size: 1.5rem; text-decoration: none; line-height: 1; }
.g-nav-title { color: white; font-size: 1rem; font-weight: bold; text-decoration: none;
    font-family: 'Hiragino Maru Gothic ProN', 'BIZ UDPGothic', 'Meiryo', sans-serif; }

/* アプリ容器 */
#app-container {
    flex: 1;
    margin-top: 52px; /* 固定ヘッダー分 */
    padding: 24px 16px;
    max-width: 600px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* カードスタイル */
.game-card {
    background: var(--panel-bg);
    border: 3.5px solid rgba(232, 131, 74, 0.25);
    border-radius: 20px;
    padding: 20px;
    box-shadow: var(--shadow-premium);
}

.header-panel {
    border-color: var(--accent-color);
    text-align: center;
}

.game-title {
    font-size: 1.8rem;
    color: var(--accent-color);
    margin-bottom: 6px;
    font-weight: bold;
}

.game-instruction {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* 影絵パネル */
.canvas-panel {
    border-color: var(--accent-color);
    background: #ffffff;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 16px;
}

.silhouette-display {
    font-size: 140px;
    line-height: 1.2;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    max-width: 320px;
    aspect-ratio: 1 / 1;
    background: transparent;
    transition: filter 0.5s ease-out, transform 0.3s;
}

/* 100%真っ黒のシルエットに変身させるフィルター */
.silhouette-display.blackout {
    filter: contrast(0) brightness(0);
}

/* 選択肢ボタン */
#choice-container {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.choice-btn {
    font-family: inherit;
    font-size: 1.45rem;
    font-weight: bold;
    color: var(--text-primary);
    background: #ffffff;
    border: 3.5px solid rgba(0,0,0,0.12);
    border-radius: 18px;
    padding: 18px 24px;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0,0,0,0.05);
    transition: all 0.2s;
}

.choice-btn:active {
    transform: scale(0.98);
}

.choice-btn.correct {
    background: #F4FAF5;
    border-color: var(--correct-color);
    color: var(--correct-color);
}

.choice-btn.incorrect {
    background: #FFF5F5;
    border-color: var(--error-color);
    color: var(--error-color);
    opacity: 0.7;
}

/* フッター */
#game-footer {
    display: flex;
    justify-content: center;
    margin-top: 10px;
}

.action-btn {
    font-size: 1.4rem;
    font-weight: bold;
    padding: 16px 40px;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transition: transform 0.1s;
    background: var(--accent-color);
    color: #ffffff;
}

.action-btn:active {
    transform: scale(0.97);
}

/* モーダル */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.4);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.modal-content {
    background: #ffffff;
    border: 4px solid var(--accent-color);
    border-radius: 24px;
    padding: 32px;
    width: 90%;
    max-width: 460px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}

.modal-title {
    font-size: 2.2rem;
    font-weight: bold;
    color: var(--correct-color);
    margin-bottom: 12px;
}

.modal-message {
    font-size: 1.3rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

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

.modal-btn {
    font-size: 1.3rem;
    font-weight: bold;
    padding: 14px;
    border: none;
    border-radius: 14px;
    cursor: pointer;
    background: var(--accent-color);
    color: #ffffff;
    text-decoration: none;
    text-align: center;
    box-shadow: 0 4px 10px rgba(232, 131, 74, 0.25);
}

.modal-btn.secondary-btn {
    background: #f0f0f0;
    color: #333333;
    box-shadow: none;
}

.hidden {
    display: none !important;
}
