body {
    background-color: #1a1a2e;
    /* მუქი, სასიამოვნო ფონი */
    color: white;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
}

.header-container {
    text-align: center;
    margin-top: 20px;
}

h1 {
    color: #f1c40f;
    margin-bottom: 5px;
}

h2 {
    color: #bdc3c7;
    font-size: 1.1rem;
    font-weight: normal;
}

#game-board {
    display: grid;
    /* მობილურზე ავტომატურად ჩაეტევა 4 სვეტად */
    grid-template-columns: repeat(4, 80px);
    gap: 12px;
    justify-content: center;
    margin: 20px auto;
    padding: 10px;
}

/* ეკრანის ზომის მიხედვით ბარათების გაზრდა */
@media (min-width: 500px) {
    #game-board {
        grid-template-columns: repeat(4, 100px);
        gap: 15px;
    }

    .card {
        width: 100px !important;
        height: 100px !important;
    }
}

.card {
    width: 80px;
    height: 80px;
    background-color: #16213e;
    border: 2px solid #0f3460;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    cursor: pointer;
    border-radius: 12px;
    transition: transform 0.4s, background-color 0.3s, box-shadow 0.3s;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    user-select: none;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.4);
    background-color: #1f4068;
}

.card.flipped {
    background-color: #4455bb;
    /* უფრო რბილი, ხილს უხდება */
    border-color: #5566cc;
    transform: rotateY(180deg);
}

#win-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
}

.win-content {
    background: #16213e;
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    border: 3px solid #f1c40f;
    box-shadow: 0 0 30px rgba(241, 196, 15, 0.3);
}

.hidden {
    display: none !important;
}

#restart-btn {
    padding: 12px 25px;
    font-size: 1rem;
    background-color: #e94560;
    color: white;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: 0.3s;
    font-weight: bold;
    box-shadow: 0 4px 10px rgba(233, 69, 96, 0.3);
}

#restart-btn:hover {
    background-color: #ff2e63;
    transform: scale(1.05);
}

#stats {
    font-size: 1.2rem;
    margin: 10px 0;
    color: #f1c40f;
}

#new-record {
    color: #2ecc71;
    font-weight: bold;
    animation: blink 1s infinite;
}

@keyframes blink {
    50% {
        opacity: 0;
    }
}

#splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #1a1a2e;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.splash-content {
    text-align: center;
    background: #16213e;
    padding: 50px;
    border-radius: 20px;
    border: 4px solid #f1c40f;
}

#start-game-btn {
    padding: 15px 40px;
    font-size: 1.5rem;
    background-color: #2ecc71;
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    margin-top: 20px;
    transition: 0.3s;
    font-weight: bold;
}

#start-game-btn:hover {
    background-color: #27ae60;
    transform: scale(1.1);
}

.game-footer {
    margin-top: 30px;
    padding: 20px;
    width: 100%;
    max-width: 500px;
    background: rgba(22, 33, 62, 0.8);
    border-radius: 15px;
    text-align: center;
    border: 1px solid rgba(241, 196, 15, 0.2);
}

.creator-info {
    font-size: 0.9rem;
    color: #bdc3c7;
    margin-bottom: 15px;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
}

.social-links a {
    text-decoration: none;
    color: white;
    font-weight: bold;
    font-size: 0.8rem;
    background: #0f3460;
    padding: 8px 12px;
    border-radius: 8px;
    transition: 0.3s;
}

.social-links a:hover {
    background: #f1c40f;
    color: #1a1a2e;
    transform: translateY(-3px);
}

.coffee-btn {
    display: inline-block;
    text-decoration: none;
    background: #ffdd00;
    color: black;
    padding: 10px 20px;
    border-radius: 10px;
    font-weight: bold;
    font-size: 0.9rem;
    transition: 0.3s;
}

.coffee-btn:hover {
    background: #ffffff;
    box-shadow: 0 0 15px rgba(255, 221, 0, 0.5);
}

.creator-info strong {
    color: #f1c40f;
    letter-spacing: 1px;
    text-transform: uppercase;
}