body {
    background: #e0f7fa;
    font-family: 'Zen Maru Gothic', sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    padding: 20px;
    color: #333;
}

.game-container {
    background: white;
    padding: 20px;
    border-radius: 20px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 640px;
    text-align: center;
    box-sizing: border-box;
}

h1 {
    font-size: 1.5rem;
    color: #d84315;
    margin: 0 0 5px 0;
}

.badge-new {
    display: inline-block;
    background: #ffd54f;
    color: #7a4a00;
    font-size: 0.65rem;
    font-weight: bold;
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: 6px;
    vertical-align: middle;
}

p {
    font-size: 0.9rem;
    color: #666;
    margin-top: 0;
    margin-bottom: 15px;
    white-space: pre-line;
}

.seo-text-box {
    margin-top: 50px;
    background-color: #fff;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    max-width: 600px;
    width: 85%;
    color: #555;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 30px;
}
.seo-text-box h2 {
    font-size: 1.2rem;
    color: #333;
    margin-top: 0;
    margin-bottom: 12px;
    border-bottom: 2px solid #eee;
    padding-bottom: 8px;
}
.seo-text-box ul {
    padding-left: 20px;
    margin: 10px 0;
}

canvas {
    background: linear-gradient(to bottom, #87ceeb, #e0f8ff 70%, #a8e6cf 70%);
    border-radius: 12px;
    width: 100%;
    max-width: 600px;
    height: auto;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.1);
    display: block;
    margin: 0 auto 12px auto;
}

/* ★パワーゲージ */
.gauge-wrap {
    max-width: 400px;
    margin: 0 auto 12px auto;
}
.gauge-wrap.hidden { display: none; }
.gauge-label {
    font-size: 0.75rem;
    color: #888;
    margin-bottom: 3px;
    font-weight: bold;
}
.gauge-track {
    position: relative;
    height: 16px;
    background: #eee;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.15);
}
.gauge-fill {
    height: 100%;
    width: 0%;
    background: #90a4ae;
    transition: background 0.1s;
}
.gauge-zone-good {
    position: absolute;
    top: 0; bottom: 0;
    left: 60%; right: 15%;
    background: rgba(165,214,167,0.35);
    pointer-events: none;
}
.gauge-zone-perfect {
    position: absolute;
    top: 0; bottom: 0;
    left: 85%; right: 0;
    background: rgba(255,213,79,0.45);
    pointer-events: none;
}

/* ★風インジケーター */
.wind-indicator {
    font-size: 0.85rem;
    font-weight: bold;
    margin-bottom: 8px;
}
.wind-indicator.hidden { display: none; }

/* ★コンボ表示 */
.combo-text {
    font-size: 0.85rem;
    font-weight: bold;
    color: #f57f17;
    margin-bottom: 8px;
    transition: opacity 0.3s;
}
.combo-text.hidden { display: none; }

/* ランキング表示エリア */
.ranking-container {
    background: #fff3e0;
    border: 2px dashed #ffb74d;
    border-radius: 12px;
    padding: 10px 20px;
    margin-bottom: 15px;
    text-align: left;
    max-width: 300px;
    margin-left: auto;
    margin-right: auto;
}
.ranking-container.hidden { display: none; }
.ranking-container h3 {
    font-size: 0.95rem;
    color: #e65100;
    margin: 0 0 5px 0;
    text-align: center;
}
.ranking-container ol {
    margin: 0;
    padding-left: 25px;
    font-size: 0.9rem;
    color: #444;
    font-weight: bold;
}

/* リザルト用ボタンエリア */
.result-area {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 300px;
    margin-left: auto;
    margin-right: auto;
}
.result-area.hidden { display: none; }

.controls-area {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.main-btn {
    width: 100%;
    padding: 15px;
    font-size: 1.1rem;
    font-family: inherit;
    font-weight: bold;
    color: white;
    border: none;
    border-radius: 15px;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    transition: transform 0.1s, background 0.2s;
}
.main-btn:active { transform: scale(0.95); }

.swing-color { background: #ff7043; }
.swing-color:active { background: #f4511e; }

.jump-color { background: #43a047; }
.jump-color:active { background: #2e7d32; }

.restart-color {
    background: #ab47bc;
}
.restart-color:active { background: #8e24aa; }

.share-color {
    background: #1da1f2;
}
.share-color:active { background: #0d8ddb; }

.back-btn {
    align-self: flex-start;
    margin-bottom: 15px;
    text-decoration: none;
    color: #555;
    font-weight: bold;
    background: white;
    padding: 8px 16px;
    border-radius: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

/* ★コインHUD */
.hud {
    display: flex;
    justify-content: center;
    margin-bottom: 8px;
}
#coin-hud {
    background: #fff3e0;
    border: 2px solid #ffb74d;
    border-radius: 20px;
    padding: 4px 16px;
    font-weight: bold;
    color: #e65100;
    font-size: 0.95rem;
}

.shop-color { background: #fb8c00; }
.shop-color:active { background: #ef6c00; }

/* ★ショップ画面 */
.shop-area {
    background: #fff8e1;
    border: 2px solid #ffd54f;
    border-radius: 16px;
    padding: 16px;
    max-width: 460px;
    margin: 0 auto 15px auto;
    text-align: left;
}
.shop-area.hidden { display: none; }
.shop-area h3 {
    text-align: center;
    color: #e65100;
    margin: 0 0 6px 0;
}
.shop-coin {
    text-align: center;
    font-weight: bold;
    color: #e65100;
    margin-bottom: 12px;
}
.shop-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: white;
    border-radius: 12px;
    padding: 10px 12px;
    margin-bottom: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.06);
}
.shop-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.shop-name { font-weight: bold; font-size: 0.95rem; }
.shop-desc { font-size: 0.72rem; color: #888; }
.shop-level { font-size: 0.75rem; color: #fb8c00; font-weight: bold; }
.shop-buy-btn {
    flex-shrink: 0;
    background: #43a047;
    color: white;
    border: none;
    border-radius: 10px;
    padding: 10px 12px;
    font-family: inherit;
    font-weight: bold;
    font-size: 0.8rem;
    cursor: pointer;
    white-space: nowrap;
}
.shop-buy-btn:disabled { background: #bdbdbd; cursor: not-allowed; }
#shop-close-btn { background: #78909c; margin-top: 4px; }
