:root {
    --primary-color: #227446;
    --secondary-color: #1b5e3a;
    --accent-color: #e4d9b2;
    --text-color: #ddd;
    --card-bg: #fff;
    --card-border: #ccc;
}

body {
    font-family: 'Arial', sans-serif;
    background-color: var(--primary-color);
    color: var(--text-color);
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
}

.header {
    width: 100%;
    background-color: var(--secondary-color);
    padding: 20px 0;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

h1 {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-color);
}

.game-container {
    width: 90%;
    max-width: 900px;
    margin: 20px auto;
    padding: 20px;
    background-color: var(--secondary-color);
    border-radius: 10px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3);
}

.settings {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 5px;
}

.count-display {
    font-size: 18px;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 5px;
    display: flex;
    align-items: center;
}

.count-label {
    margin-right: 10px;
    font-weight: bold;
}

.count-value {
    font-size: 22px;
    color: var(--accent-color);
}

.controls {
    margin-bottom: 20px;
    text-align: center;
}

button {
    background-color: var(--accent-color);
    color: #333;
    border: none;
    padding: 10px 20px;
    margin: 0 5px;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
}

button:hover {
    background-color: #d9ca94;
    transform: translateY(-2px);
}

button:disabled {
    background-color: #888;
    cursor: not-allowed;
    transform: none;
}

.betting-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 15px 0;
    flex-wrap: wrap;
}

.chip {
    width: 60px;
    height: 60px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    margin: 0 5px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
}

.chip:hover {
    transform: scale(1.1);
}

.chip-5 {
    background: linear-gradient(#e63946, #c1121f);
    border: 3px dashed white;
}

.chip-10 {
    background: linear-gradient(#2a9d8f, #1d7268);
    border: 3px dashed white;
}

.chip-25 {
    background: linear-gradient(#457b9d, #2c5282);
    border: 3px dashed white;
}

.chip-100 {
    background: linear-gradient(#6a0dad, #4b006f);
    border: 3px dashed white;
}

.players {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.player {
    padding: 15px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
}

.player-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.player-name {
    font-size: 18px;
    font-weight: bold;
}

.player-score {
    font-size: 20px;
    font-weight: bold;
    color: var(--accent-color);
}

.cards-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.card {
    width: 80px;
    height: 120px;
    background-color: var(--card-bg);
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 5px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    position: relative;
    color: black;
}

.card.red {
    color: red;
}

.card-value {
    font-size: 20px;
    font-weight: bold;
}

.card-tl {
    text-align: left;
}

.card-br {
    text-align: right;
    transform: rotate(180deg);
}

.card-suit {
    font-size: 24px;
    text-align: center;
    flex-grow: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.stats {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 5px;
}

.chip-count, .bet-amount {
    font-size: 18px;
}

.value {
    font-weight: bold;
    color: var(--accent-color);
}

.deck-selector {
    display: flex;
    align-items: center;
}

.deck-selector label {
    margin-right: 10px;
}

select {
    padding: 5px 10px;
    border-radius: 5px;
    background-color: var(--accent-color);
    border: none;
}

.message {
    text-align: center;
    font-size: 20px;
    margin: 15px 0;
    min-height: 30px;
    color: var(--accent-color);
    font-weight: bold;
}

.hidden-card {
    background-color: #227446;
    background-image: linear-gradient(45deg, #1d5e3a 25%, transparent 25%, transparent 75%, #1d5e3a 75%, #1d5e3a), 
                      linear-gradient(45deg, #1d5e3a 25%, transparent 25%, transparent 75%, #1d5e3a 75%, #1d5e3a);
    background-size: 20px 20px;
    background-position: 0 0, 10px 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}

@media (max-width: 600px) {
    .settings {
        flex-direction: column;
        gap: 10px;
    }
    .card {
        width: 60px;
        height: 90px;
    }
    .chip {
        width: 50px;
        height: 50px;
        font-size: 14px;
    }
}
