:root {
    --bg: #1a3c2e;
    --bg-field: #2d5a45;
    --panel: #1f4533;
    --accent: #e5a52f;
    --text: #fff;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;
    /* cursor: none только в игре, на остальных экранах — обычный курсор (меняется в showScreen) */
}

.screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.game-container {
    max-width: 500px;
    width: 100%;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 15px;
    background: var(--panel);
    border-radius: 12px;
}

.header h1 {
    font-size: 1.5rem;
}

.back-btn {
    background: rgba(255,255,255,0.1);
    border: none;
    color: var(--text);
    font-size: 1.5rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none;
}

.subtitle {
    text-align: center;
    font-size: 1.1rem;
    margin-bottom: 30px;
    opacity: 0.8;
}

.mode-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.mode-btn {
    background: var(--panel);
    border: 3px solid var(--accent);
    border-radius: 15px;
    padding: 30px;
    width: 100%;
    max-width: 300px;
    cursor: pointer;
    transition: transform 0.2s;
    color: var(--text);
}

.mode-btn:hover {
    transform: scale(1.05);
    background: var(--bg-field);
}

.mode-icon {
    font-size: 4rem;
    margin-bottom: 15px;
}

.mode-title {
    font-size: 1.3rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.mode-desc {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Game Field */
.field {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    background: var(--bg-field);
    padding: 20px;
    border-radius: 15px;
}

.hole {
    aspect-ratio: 1;
    background: rgba(0,0,0,0.3);
    border-radius: 50%;
    position: relative;
    overflow: hidden;
}

.creature {
    width: 80%;
    height: 80%;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    position: absolute;
    bottom: -100%;
    left: 10%;
    transition: bottom 0.3s;
    cursor: pointer;
}

.hole.active .creature {
    bottom: 10%;
}

.creature.hit {
    animation: hitEffect 0.3s;
}

.creature.miss {
    animation: shakeEffect 0.3s;
}

@keyframes hitEffect {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

@keyframes shakeEffect {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

/* Score Display */
.score-display {
    display: flex;
    gap: 15px;
    font-size: 1.5rem;
    font-weight: bold;
}

#score {
    color: var(--accent);
}

#timer {
    color: #ff6b6b;
}

/* End Screen */
.final-score {
    font-size: 4rem;
    text-align: center;
    color: var(--accent);
    margin: 30px 0;
    font-weight: bold;
}

.final-stats {
    text-align: center;
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.restart-btn {
    width: 100%;
    padding: 20px;
    font-size: 1.3rem;
    background: var(--accent);
    color: var(--bg);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: bold;
    transition: transform 0.2s;
}

.restart-btn:hover {
    transform: scale(1.05);
}

.restart-btn-outline {
    margin-top: 10px;
    background: transparent;
    color: var(--accent);
    border: 2px solid var(--accent);
}

.restart-btn-outline:hover {
    background: rgba(229, 165, 47, 0.15);
}

/* Shop */
.shop-coins {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--accent);
}

.shop-hint {
    text-align: center;
    font-size: 0.95rem;
    opacity: 0.9;
    margin: -8px 0 12px 0;
}

.shop-section-title {
    font-size: 1rem;
    opacity: 0.9;
    margin: 1rem 0 0.5rem;
}

.shop-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.shop-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: var(--panel);
    border-radius: 12px;
    border: 2px solid transparent;
}

.shop-item.selected {
    border-color: var(--accent);
}

.shop-item-icon {
    width: 56px;
    height: 56px;
    font-size: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.2);
    border-radius: 10px;
}

.shop-item-info {
    flex: 1;
}

.shop-item-name {
    font-weight: bold;
    font-size: 1.1rem;
}

.shop-item-price {
    font-size: 0.9rem;
    opacity: 0.85;
}

.shop-item-mult {
    font-size: 0.85rem;
    opacity: 0.9;
    color: var(--accent);
    margin-top: 2px;
}

.shop-item-btn {
    padding: 10px 18px;
    border-radius: 10px;
    border: none;
    font-weight: bold;
    cursor: pointer;
    background: var(--accent);
    color: var(--bg);
}

.shop-item-btn:disabled {
    opacity: 0.7;
    cursor: default;
}

.shop-item-btn.buy {
    background: var(--bg-field);
    color: var(--text);
    border: 2px solid var(--accent);
}

.coins-earned {
    margin-top: 8px;
    color: var(--accent);
    font-size: 1rem;
}

/* Hammer Cursor Effect */
.hammer {
    position: absolute;
    width: 95px;
    height: 95px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%) rotate(-45deg);
    transition: transform 0.08s ease-out;
}

.hammer--punch {
    transform: translate(-50%, -50%) scale(0.6);
}
