/* ===== doodle-jump · 涂鸦跳跃 ===== */

.dj-hero {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 32px 20px 28px;
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, #faf5ff 0%, #fdf4ff 60%, #fae8ff 100%);
    overflow: hidden;
    margin-bottom: 24px;
    border: 1px solid #e9d5ff;
}

.dj-glow {
    position: absolute;
    top: -120px;
    left: 50%;
    width: 460px;
    height: 460px;
    transform: translateX(-50%);
    border-radius: 50%;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.22) 0%, transparent 70%);
    pointer-events: none;
}

/* ---- HUD ---- */
.dj-hud {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 10px;
    width: 100%;
    max-width: 420px;
    margin-bottom: 14px;
    flex-wrap: wrap;
    justify-content: center;
}
.dj-hud-item {
    flex: 1;
    min-width: 120px;
    padding: 10px 14px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid #a5f3fc;
    text-align: center;
    box-shadow: 0 4px 12px rgba(6, 182, 212, 0.08);
}
.dj-hud-label {
    font-size: 11px;
    color: #0e7490;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 700;
}
.dj-hud-value {
    font-size: 22px;
    font-weight: 900;
    color: #155e75;
    margin-top: 2px;
    line-height: 1.2;
}

/* ---- Canvas ---- */
.dj-canvas-wrap {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 380px;
    aspect-ratio: 1 / 1.5;
    border-radius: 14px;
    overflow: hidden;
    background: linear-gradient(180deg, #fef9c3 0%, #fde68a 100%);
    box-shadow: 0 16px 40px rgba(6, 182, 212, 0.25);
    touch-action: none;
    user-select: none;
}
.dj-canvas-wrap canvas {
    width: 100%;
    height: 100%;
    display: block;
    touch-action: none;
}

/* ---- Overlay ---- */
.dj-overlay {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: grid;
    place-items: center;
    background: rgba(21, 94, 117, 0.55);
    backdrop-filter: blur(3px);
    animation: dj-fade 0.25s ease;
}
.dj-overlay[hidden] { display: none; }
@keyframes dj-fade { from { opacity: 0; } to { opacity: 1; } }

.dj-overlay-card {
    text-align: center;
    padding: 28px 24px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 14px 40px rgba(21, 94, 117, 0.3);
    max-width: 86%;
}
.dj-overlay-emoji { font-size: 48px; line-height: 1; margin-bottom: 10px; }
.dj-overlay-title { font-size: 26px; font-weight: 900; color: #155e75; letter-spacing: -0.02em; }
.dj-overlay-text { font-size: 14px; color: #0e7490; margin: 8px 0 18px; }
.dj-overlay-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

/* ---- Controls ---- */
.dj-controls {
    position: relative;
    z-index: 1;
    margin-top: 14px;
}
.dj-btn {
    padding: 9px 18px;
    border-radius: 10px;
    border: 1px solid #a5f3fc;
    background: #fff;
    color: #155e75;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
}
.dj-btn:hover { background: #ecfeff; transform: translateY(-1px); }
.dj-btn:active { transform: translateY(0); }
.dj-btn.primary {
    background: linear-gradient(135deg, #06b6d4, #0891b2);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 6px 14px rgba(6, 182, 212, 0.4);
}
.dj-btn.primary:hover { background: linear-gradient(135deg, #0891b2, #0e7490); }

/* ---- 移动端方向键 ---- */
.dj-dpad {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 20px;
    margin-top: 14px;
}
.dj-dpad-btn {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: 2px solid #a5f3fc;
    background: #fff;
    color: #155e75;
    font-size: 24px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(6, 182, 212, 0.15);
    transition: transform 0.08s ease, background 0.15s ease;
    user-select: none;
}
.dj-dpad-btn:active, .dj-dpad-btn.is-pressed {
    transform: scale(0.92);
    background: linear-gradient(135deg, #06b6d4, #0891b2);
    color: #fff;
    border-color: transparent;
}

.dj-hint {
    position: relative;
    z-index: 1;
    margin-top: 12px;
    font-size: 12.5px;
    color: #0e7490;
    font-weight: 500;
}
.dj-hint kbd {
    display: inline-block;
    padding: 2px 6px;
    margin: 0 1px;
    border-radius: 4px;
    background: #fff;
    border: 1px solid #a5f3fc;
    border-bottom-width: 2px;
    font-size: 11px;
    font-family: ui-monospace, monospace;
    color: #155e75;
}

/* ---- Info ---- */
.dj-info { margin-bottom: 28px; }

/* ---- Responsive ---- */
@media (max-width: 768px) {
    .dj-hero { padding: 24px 14px 20px; }
    .dj-hud-item { min-width: 100px; padding: 8px 12px; }
    .dj-hud-value { font-size: 19px; }
}

@media (prefers-reduced-motion: reduce) {
    .dj-overlay { animation: none; }
}
