﻿/* ===== استایل بازی‌گونه ===== */
@import url('https://fonts.googleapis.com/css2?family=Lalezar&display=swap');

* {
    box-sizing: border-box;
}

body {
    font-family: 'Lalezar', 'Tahoma', sans-serif;
    background: linear-gradient(135deg, #0f0c29, #302b63, #24243e);
    color: #fff;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    overflow-x: hidden;
}

    /* ستاره‌های پس‌زمینه */
    body::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-image: radial-gradient(2px 2px at 20px 30px, #fff, transparent), radial-gradient(2px 2px at 60px 70px, #fff, transparent), radial-gradient(1px 1px at 90px 40px, #fff, transparent), radial-gradient(1px 1px at 130px 80px, #fff, transparent), radial-gradient(2px 2px at 160px 120px, #fff, transparent);
        background-size: 200px 200px;
        animation: stars 100s linear infinite;
        z-index: -1;
        opacity: 0.5;
    }

@keyframes stars {
    from {
        background-position: 0 0;
    }

    to {
        background-position: -1000px 1000px;
    }
}

.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 20px;
}

/* هدر بازی */
.game-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 25px;
    box-shadow: 0 10px 40px rgba(102, 126, 234, 0.4);
    position: relative;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

    .game-header::before {
        content: '';
        position: absolute;
        top: -50%;
        left: -50%;
        width: 200%;
        height: 200%;
        background: linear-gradient(45deg, transparent, rgba(255,255,255,0.1), transparent);
        animation: shine 3s infinite;
    }

@keyframes shine {
    0% {
        transform: translateX(-100%) translateY(-100%) rotate(45deg);
    }

    100% {
        transform: translateX(100%) translateY(100%) rotate(45deg);
    }
}

.game-header h1 {
    margin: 0;
    font-size: 36px;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.5);
    position: relative;
    z-index: 1;
}

/* نوار وضعیت بازیکن */
.player-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-bottom: 25px;
}

.stat-card {
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

    .stat-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 30px rgba(102, 126, 234, 0.5);
    }

    .stat-card .icon {
        font-size: 40px;
        margin-bottom: 10px;
        display: block;
        animation: bounce 2s infinite;
    }

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.stat-card .value {
    font-size: 32px;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.stat-card .label {
    color: #aaa;
    font-size: 14px;
    margin-top: 5px;
}

/* کارت سکه */
.coin-display {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    border-radius: 50px;
    padding: 15px 30px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: bold;
    box-shadow: 0 5px 20px rgba(245, 87, 108, 0.5);
    position: relative;
    cursor: pointer;
    transition: all 0.3s;
}

    .coin-display:hover {
        transform: scale(1.05);
    }

.coin-icon {
    width: 40px;
    height: 40px;
    background: radial-gradient(circle at 30% 30%, #ffd700, #ff9500);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: inset -2px -2px 5px rgba(0,0,0,0.3), 0 0 15px rgba(255, 215, 0, 0.8);
    animation: coinSpin 3s linear infinite;
}

@keyframes coinSpin {
    0% {
        transform: rotateY(0deg);
    }

    100% {
        transform: rotateY(360deg);
    }
}

/* منوی بازی */
.game-menu {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 15px;
    margin-bottom: 25px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    border: 1px solid rgba(255,255,255,0.2);
}

    .game-menu a {
        background: linear-gradient(135deg, #667eea, #764ba2);
        color: white;
        padding: 12px 25px;
        border-radius: 10px;
        text-decoration: none;
        font-weight: bold;
        transition: all 0.3s;
        border: 2px solid transparent;
        display: inline-flex;
        align-items: center;
        gap: 8px;
    }

        .game-menu a:hover {
            transform: translateY(-3px);
            box-shadow: 0 5px 20px rgba(102, 126, 234, 0.6);
            border-color: #ffd700;
        }

        .game-menu a.active {
            background: linear-gradient(135deg, #ffd700, #ff9500);
            color: #000;
        }

/* جداول بازی */
.game-table {
    width: 100%;
    background: rgba(255,255,255,0.05);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.1);
    border-collapse: separate;
    border-spacing: 0;
}

    .game-table th {
        background: linear-gradient(135deg, #667eea, #764ba2);
        color: white;
        padding: 15px;
        text-align: right;
        font-size: 16px;
    }

    .game-table td {
        padding: 12px 15px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        text-align: right;
    }

    .game-table tr:hover {
        background: rgba(255,255,255,0.1);
    }

    .game-table tr:nth-child(even) {
        background: rgba(255,255,255,0.03);
    }

/* کارت فرم */
.game-form {
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 25px;
    border: 1px solid rgba(255,255,255,0.2);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

    .game-form h2 {
        margin-top: 0;
        color: #ffd700;
        font-size: 28px;
        text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
    }

.form-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #ffd700;
    font-weight: bold;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    background: rgba(0,0,0,0.3);
    border: 2px solid rgba(255,255,255,0.2);
    border-radius: 10px;
    color: white;
    font-family: inherit;
    font-size: 15px;
    transition: all 0.3s;
}

    .form-group input:focus,
    .form-group select:focus {
        outline: none;
        border-color: #ffd700;
        box-shadow: 0 0 15px rgba(255, 215, 0, 0.3);
    }

/* دکمه‌های بازی */
.game-btn {
    background: linear-gradient(135deg, #ffd700, #ff9500);
    color: #000;
    padding: 15px 35px;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 20px rgba(255, 215, 0, 0.4);
    font-family: inherit;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

    .game-btn:hover {
        transform: translateY(-3px);
        box-shadow: 0 8px 25px rgba(255, 215, 0, 0.6);
    }

    .game-btn:active {
        transform: translateY(0);
    }

    .game-btn.btn-success {
        background: linear-gradient(135deg, #11998e, #38ef7d);
        color: white;
    }

    .game-btn.btn-danger {
        background: linear-gradient(135deg, #eb3349, #f45c43);
        color: white;
    }

    .game-btn.btn-info {
        background: linear-gradient(135deg, #2193b0, #6dd5ed);
        color: white;
    }

/* نوار پیشرفت */
.xp-bar {
    background: rgba(0,0,0,0.3);
    border-radius: 20px;
    height: 30px;
    overflow: hidden;
    position: relative;
    border: 2px solid rgba(255,255,255,0.2);
    margin: 15px 0;
}

.xp-fill {
    background: linear-gradient(90deg, #11998e, #38ef7d, #ffd700);
    height: 100%;
    border-radius: 20px;
    transition: width 1s ease;
    position: relative;
    overflow: hidden;
}

    .xp-fill::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
        animation: shimmer 2s infinite;
    }

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(100%);
    }
}

.xp-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
    z-index: 2;
}

/* نشان‌ها */
.badge-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

.badge-card {
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 215, 0, 0.3);
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

    .badge-card:hover {
        transform: translateY(-10px) rotate(5deg);
        border-color: #ffd700;
        box-shadow: 0 15px 40px rgba(255, 215, 0, 0.4);
    }

.badge-icon {
    font-size: 60px;
    margin-bottom: 10px;
    display: block;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

/* لیدربورد */
.leaderboard-item {
    background: rgba(255,255,255,0.05);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.3s;
    border: 2px solid transparent;
}

    .leaderboard-item:hover {
        background: rgba(255,255,255,0.1);
        transform: translateX(-10px);
    }

    .leaderboard-item.rank-1 {
        background: linear-gradient(135deg, rgba(255,215,0,0.2), rgba(255,140,0,0.1));
        border-color: #ffd700;
        box-shadow: 0 5px 20px rgba(255, 215, 0, 0.3);
    }

    .leaderboard-item.rank-2 {
        background: linear-gradient(135deg, rgba(192,192,192,0.2), rgba(169,169,169,0.1));
        border-color: #c0c0c0;
    }

    .leaderboard-item.rank-3 {
        background: linear-gradient(135deg, rgba(205,127,50,0.2), rgba(184,115,51,0.1));
        border-color: #cd7f32;
    }

.rank-badge {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    font-weight: bold;
    background: linear-gradient(135deg, #667eea, #764ba2);
    flex-shrink: 0;
}

.rank-1 .rank-badge {
    background: linear-gradient(135deg, #ffd700, #ff9500);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(255, 215, 0, 0.7);
    }

    50% {
        box-shadow: 0 0 0 15px rgba(255, 215, 0, 0);
    }
}

/* پیام‌ها */
.game-message {
    padding: 15px 25px;
    border-radius: 10px;
    margin: 15px 0;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideIn 0.5s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.game-message.success {
    background: linear-gradient(135deg, rgba(17,153,142,0.3), rgba(56,239,125,0.2));
    border: 2px solid #38ef7d;
    color: #38ef7d;
}

.game-message.error {
    background: linear-gradient(135deg, rgba(235,51,73,0.3), rgba(244,92,67,0.2));
    border: 2px solid #f45c43;
    color: #f45c43;
}

.game-message.coin-reward {
    background: linear-gradient(135deg, rgba(255,215,0,0.3), rgba(255,140,0,0.2));
    border: 2px solid #ffd700;
    color: #ffd700;
    font-size: 20px;
}

/* انیمیشن سکه‌های پرنده */
.flying-coin {
    position: fixed;
    width: 40px;
    height: 40px;
    background: radial-gradient(circle at 30% 30%, #ffd700, #ff9500);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: bold;
    color: #000;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.8);
    pointer-events: none;
    z-index: 9999;
    animation: flyToCounter 1.5s ease-in forwards;
}

@keyframes flyToCounter {
    0% {
        transform: scale(0) rotate(0deg);
        opacity: 1;
    }

    50% {
        transform: scale(1.5) rotate(360deg);
        opacity: 1;
    }

    100% {
        transform: scale(0.5) rotate(720deg);
        opacity: 0;
    }
}

/* پنجره پاپ‌آپ دریافت سکه */
.coin-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    background: linear-gradient(135deg, #ffd700, #ff9500);
    color: #000;
    padding: 40px 60px;
    border-radius: 20px;
    font-size: 32px;
    font-weight: bold;
    z-index: 10000;
    box-shadow: 0 0 50px rgba(255, 215, 0, 0.8);
    text-align: center;
    animation: popIn 0.5s ease forwards;
}

@keyframes popIn {
    0% {
        transform: translate(-50%, -50%) scale(0) rotate(-180deg);
    }

    50% {
        transform: translate(-50%, -50%) scale(1.2) rotate(10deg);
    }

    100% {
        transform: translate(-50%, -50%) scale(1) rotate(0deg);
    }
}

.coin-popup.hide {
    animation: popOut 0.5s ease forwards;
}

@keyframes popOut {
    to {
        transform: translate(-50%, -50%) scale(0) rotate(180deg);
        opacity: 0;
    }
}

/* فروشگاه */
.shop-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.shop-item {
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255,255,255,0.2);
    border-radius: 20px;
    padding: 25px;
    text-align: center;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

    .shop-item:hover {
        transform: translateY(-10px);
        border-color: #ffd700;
        box-shadow: 0 15px 40px rgba(255, 215, 0, 0.3);
    }

    .shop-item .item-icon {
        font-size: 70px;
        margin-bottom: 15px;
        display: block;
    }

    .shop-item .item-name {
        font-size: 20px;
        font-weight: bold;
        color: #ffd700;
        margin-bottom: 10px;
    }

    .shop-item .item-price {
        background: linear-gradient(135deg, #ffd700, #ff9500);
        color: #000;
        padding: 8px 20px;
        border-radius: 20px;
        display: inline-block;
        font-weight: bold;
        margin: 10px 0;
    }

    .shop-item .buy-btn {
        background: linear-gradient(135deg, #11998e, #38ef7d);
        color: white;
        border: none;
        padding: 10px 25px;
        border-radius: 20px;
        cursor: pointer;
        font-weight: bold;
        margin-top: 10px;
        transition: all 0.3s;
        font-family: inherit;
    }

        .shop-item .buy-btn:hover {
            transform: scale(1.05);
        }

        .shop-item .buy-btn:disabled {
            background: #666;
            cursor: not-allowed;
        }

/* سطح بازیکن */
.level-display {
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 20px;
    border: 2px solid rgba(255, 215, 0, 0.3);
}

.level-badge {
    display: inline-block;
    padding: 10px 25px;
    border-radius: 50px;
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 15px;
}

.level-1 {
    background: linear-gradient(135deg, #94a3b8, #64748b);
}

.level-2 {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

.level-3 {
    background: linear-gradient(135deg, #10b981, #047857);
}

.level-4 {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.level-5 {
    background: linear-gradient(135deg, #ef4444, #b91c1c);
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.5);
}

/* ریسپانسیو */
@media (max-width: 768px) {
    .player-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .game-header h1 {
        font-size: 24px;
    }
}


/* ===== صفحه لاگین و ثبت‌نام ===== */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-box {
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(20px);
    border: 2px solid rgba(255,255,255,0.2);
    border-radius: 25px;
    padding: 40px;
    width: 100%;
    max-width: 450px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    animation: slideUp 0.6s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.auth-box h1 {
    text-align: center;
    color: #ffd700;
    font-size: 32px;
    margin-bottom: 10px;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

.auth-box .subtitle {
    text-align: center;
    color: #aaa;
    margin-bottom: 30px;
    font-size: 16px;
}

.auth-box .logo {
    text-align: center;
    font-size: 80px;
    margin-bottom: 20px;
    animation: float 3s ease-in-out infinite;
}

.auth-box .form-group {
    margin-bottom: 20px;
}

    .auth-box .form-group label {
        display: block;
        color: #ffd700;
        margin-bottom: 8px;
        font-weight: bold;
    }

    .auth-box .form-group input {
        width: 100%;
        padding: 14px;
        background: rgba(0,0,0,0.3);
        border: 2px solid rgba(255,255,255,0.2);
        border-radius: 10px;
        color: white;
        font-size: 15px;
        font-family: inherit;
        transition: all 0.3s;
    }

        .auth-box .form-group input:focus {
            outline: none;
            border-color: #ffd700;
            box-shadow: 0 0 15px rgba(255, 215, 0, 0.3);
        }

.auth-box .game-btn {
    width: 100%;
    padding: 15px;
    font-size: 18px;
    margin-top: 10px;
}

.auth-links {
    text-align: center;
    margin-top: 25px;
    color: #aaa;
}

    .auth-links a {
        color: #ffd700;
        text-decoration: none;
        font-weight: bold;
        transition: all 0.3s;
    }

        .auth-links a:hover {
            color: #ff9500;
            text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
        }

/* نوار کاربر در هدر */
.user-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0,0,0,0.3);
    padding: 10px 20px;
    border-radius: 15px;
    margin-bottom: 20px;
    border: 1px solid rgba(255,255,255,0.1);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-avatar {
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, #ffd700, #ff9500);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: bold;
    color: #000;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.5);
}

.user-name {
    font-weight: bold;
    color: #ffd700;
    font-size: 16px;
}

.user-role {
    color: #aaa;
    font-size: 13px;
}

.logout-btn {
    background: linear-gradient(135deg, #eb3349, #f45c43);
    color: white;
    padding: 10px 25px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 14px;
}

    .logout-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 5px 20px rgba(235, 51, 73, 0.5);
    }


/* ===== استایل‌های بازی حافظه ===== */
.memory-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255,255,255,0.05);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.memory-stats {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.memory-stat {
    text-align: center;
    background: rgba(0,0,0,0.2);
    padding: 10px 20px;
    border-radius: 10px;
}

    .memory-stat .value {
        font-size: 28px;
        font-weight: bold;
        color: #ffd700;
    }

    .memory-stat .label {
        color: #aaa;
        font-size: 12px;
        margin-top: 5px;
    }

.memory-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
}

.memory-card {
    aspect-ratio: 1;
    min-height: 100px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 50px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    transform-style: preserve-3d;
    user-select: none;
}

    .memory-card:hover {
        transform: scale(1.05);
        box-shadow: 0 5px 20px rgba(102, 126, 234, 0.5);
    }

    .memory-card.flipped {
        background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
        border: 2px solid #ffd700;
        transform: rotateY(180deg);
    }

    .memory-card.matched {
        background: linear-gradient(135deg, #11998e, #38ef7d);
        animation: matchPulse 0.5s;
        cursor: default;
    }

@keyframes matchPulse {
    0%, 100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

.memory-card .card-front {
    display: none;
    transform: rotateY(180deg);
}

.memory-card.flipped .card-front,
.memory-card.matched .card-front {
    display: block;
}

.memory-card .card-back {
    font-size: 40px;
    color: rgba(255,255,255,0.5);
}

.memory-card.flipped .card-back,
.memory-card.matched .card-back {
    display: none;
}

/* ریسپانسیو برای موبایل */
@media (max-width: 600px) {
    .memory-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
        padding: 10px;
    }

    .memory-card {
        min-height: 70px;
        font-size: 30px;
    }

        .memory-card .card-back {
            font-size: 25px;
        }

    .memory-header {
        flex-direction: column;
        text-align: center;
    }

    .memory-stats {
        justify-content: center;
    }
}

.result-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.result-box {
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
    border: 2px solid #ffd700;
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    max-width: 500px;
    width: 100%;
    animation: slideUp 0.5s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}