/* إعدادات أساسية للصفحة */
body {
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background: linear-gradient(to bottom,  #1a1a2e, #16213e);
    font-family: 'Arial', sans-serif;
    position: relative;
    overflow: hidden;
}

.tiktok-handle {
    font-size: 20px;
    font-weight: bold;
    color: #ff0050;
}
.footer {
    position: absolute;
    bottom: 20px;
    left: 20px;
    font-size: 18px;
    font-weight: bold;
    color: white;
    background: linear-gradient(135deg, rgba(0,0,0,0.7), rgba(50,50,50,0.7));
    padding: 12px 18px;
    border-radius: 12px;
    box-shadow: 3px 3px 10px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer p {
    margin: 0;
}

.footer a {
    color: #ff0050;
    text-decoration: none;
    font-weight: bold;
    transition: 0.3s;
}

.footer a:hover {
    text-shadow: 0px 0px 8px rgba(255, 0, 80, 0.8);
    transform: scale(1.1);
}

/* تنسيق الحاوية الرئيسية */
.container {
    text-align: center;
    color: white;
    position: relative;
    z-index: 2;
    max-width: 80%;
    padding: 30px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* تنسيق العنوان الرئيسي */
h1 {
    font-size: 3rem;
    font-weight: bold;
    font-family: 'Pacifico', cursive;
    background: linear-gradient(to right, #ffde59, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* تنسيق الفقرات */
p {
    font-size: 1.2rem;
    line-height: 1.6;
    margin: 20px 0;
    padding: 15px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
}

/* زر التشغيل */
.play-button {
    display: inline-block;
    margin-top: 20px;
    padding: 15px 30px;
    font-size: 1.2rem;
    background-color: #ffde59;
    color: black;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    box-shadow: 2px 4px 6px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s ease-in-out;
}

.play-button:hover {
    background-color: #ffd700;
}

/* شكل القمر */
.moon {
    position: absolute;
    top: 5%;
    left: 5%;
    width: 140px;
    height: 140px;
    background-color: #c7b052;
    border-radius: 50%;
}

.moon::before {
    content: '';
    position: absolute;
    width: 110px;
    height: 110px;
    background-color: #1a1a2e;
    border-radius: 50%;
    top: 20px;
    left: 35px;
}

/* شكل النجوم */
.star {
    position: absolute;
    width: 25px;
    height: 25px;
    background-color: white;
    clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
    box-shadow: 0 0 10px white;
    animation: twinkle 1.5s infinite alternate;
}

@keyframes twinkle {
    from { opacity: 0.5; }
    to { opacity: 1; }
}

/* الغيوم */
.cloud, .cloud2 {
    position: absolute;
    top: 30%;
    width: 150px;
    height: 60px;
    background: white;
    border-radius: 50px;
    opacity: 0.8;
}

.cloud::before, .cloud::after, .cloud2::before, .cloud2::after {
    content: '';
    position: absolute;
    background: white;
    border-radius: 50%;
    opacity: 0.9;
}

.cloud::before, .cloud2::before {
    width: 80px;
    height: 80px;
    top: -30px;
    left: 20px;
}

.cloud::after, .cloud2::after {
    width: 100px;
    height: 100px;
    top: -40px;
    right: 20px;
}

.cloud {
    right: 10%;
}

.cloud2 {
    left: 10%;
}

/* الجبال */
.mountains {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 30%;
    background: linear-gradient(to top, #4b0082, transparent);
    border-radius: 50% 50% 0 0;
}
/* تنسيق الحاوية الأساسية لصفحة تسجيل الدخول */
.login-container {
    background: rgba(255, 255, 255, 0.2);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    max-width: 350px;
    margin: auto;
}

/* تنسيق العنوان */
h2 {
    font-size: 2.5rem;
    font-weight: bold;
    background: linear-gradient(to right, #ffde59, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* تنسيق مدخلات النموذج */
input {
    width: 85%;
    padding: 12px;
    margin: 10px 0;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1rem;
}

/* تنسيق زر تسجيل الدخول */
.login-button {
    display: block;
    width: 90%;
    padding: 12px;
    font-size: 1.2rem;
    font-weight: bold;
    text-align: center;
    background: linear-gradient(to right, #ffde59, #ff8c00);
    color: black;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    margin-top: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.login-button:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
    background: linear-gradient(to right, #ffd700, #ff4500);
}

/* تنسيق الرسالة الخطأ */
.error {
    color: red;
    font-size: 1rem;
    margin-bottom: 10px;
}
/* تنسيق لوحة تحكم الأدمن */
.admin-panel {
    background: rgba(255, 255, 255, 0.2);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    max-width: 450px;
    margin: auto;
}

/* تنسيق عنوان لوحة التحكم */
h2 {
    font-size: 2.5rem;
    font-weight: bold;
    background: linear-gradient(to right, #ffde59, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* تنسيق مدخلات النموذج */
input, select {
    width: 85%;
    padding: 12px;
    margin: 10px 0;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1rem;
}

/* تنسيق الأزرار */
.button {
    display: block;
    width: 90%;
    padding: 12px;
    font-size: 1.2rem;
    font-weight: bold;
    text-align: center;
    background: linear-gradient(to right, #ffde59, #ff8c00);
    color: black;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    margin-top: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.button:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
    background: linear-gradient(to right, #ffd700, #ff4500);
}

/* زر الحذف */
.delete-button {
    background: red;
    color: white;
}

.delete-button:hover {
    background: darkred;
}

/* زر تسجيل الخروج */
.logout {
    background: darkblue;
    color: white;
}

.logout:hover {
    background: navy;
}

/* تنسيق قائمة المستخدمين */
.user-list {
    background: rgba(255, 255, 255, 0.2);
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    max-width: 500px;
    margin: auto;
}

.user-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

/* تم نقل أنماط game-container و category و question-button إلى ملف game.html مباشرة لتنظيم أفضل */

/* تأثير دخول ناعم */
@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

/* تكبير حجم السؤال */
.question-title {
    font-size: 3rem;
    font-weight: bold;
    color: #ffde59;
    text-shadow: 4px 4px 8px rgba(0, 0, 0, 0.6);
    margin-bottom: 40px;
}

/* تحسين تخطيط الأزرار */
.options-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
}

/* تكبير أزرار الخيارات */
.option-button {
    width: 100%;
    max-width: 550px;
    padding: 22px;
    font-size: 2rem;
    font-weight: bold;
    text-align: center;
    background: linear-gradient(135deg, #ffde59, #ff8c00);
    color: black;
    border: none;
    border-radius: 35px;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.4);
    position: relative;
    overflow: hidden;
}

/* تأثير متحرك عند تمرير الماوس */
.option-button:hover {
    transform: scale(1.08);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
    background: linear-gradient(135deg, #ffd700, #ff4500);
}

/* تأثير الإجابة الصحيحة */
.correct {
    background: #28a745 !important;
    color: white;
    box-shadow: 0 0 20px rgba(40, 167, 69, 0.8);
    animation: correctEffect 0.5s ease-in-out;
}

/* تأثير الإجابة الخاطئة */
.wrong {
    background: #dc3545 !important;
    color: white;
    box-shadow: 0 0 20px rgba(220, 53, 69, 0.8);
    animation: wrongEffect 0.5s ease-in-out;
}

/* تأثير اهتزاز عند الخطأ */
@keyframes wrongEffect {
    0% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    50% { transform: translateX(10px); }
    75% { transform: translateX(-10px); }
    100% { transform: translateX(0); }
}

/* تأثير تكبير عند الصح */
@keyframes correctEffect {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* زر الفريق التالي */
.next-button {
    display: block;
    margin: 40px auto;
    padding: 22px 50px;
    font-size: 2rem;
    font-weight: bold;
    text-align: center;
    background: #007bff;
    color: white;
    border-radius: 35px;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.4);
    opacity: 0;
    visibility: hidden;
    transform: scale(0.8);
    transition: opacity 0.5s ease-in-out, transform 0.3s ease-in-out;
}

.next-button.show {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}

.next-button:hover {
    transform: scale(1.1);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
    background: #0056b3;
}
/* تصميم صفحة الفائز */
.winner-container {
    width: 90%;
    max-width: 900px;
    background: rgba(0, 0, 0, 0.85);
    padding: 50px;
    border-radius: 25px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
    text-align: center;
    backdrop-filter: blur(10px);
    animation: fadeIn 0.8s ease-in-out;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* تأثير دخول ناعم */
@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

/* عنوان الفائز */
.winner-title {
    font-size: 3rem;
    font-weight: bold;
    color: #ffde59;
    text-shadow: 5px 5px 10px rgba(0, 0, 0, 0.7);
    margin-bottom: 30px;
    animation: bounce 1s infinite alternate;
}

/* تأثير تحرك النص */
@keyframes bounce {
    from { transform: translateY(0); }
    to { transform: translateY(-10px); }
}

/* صندوق الفريق الفائز */
.winner-box {
    background: linear-gradient(135deg, #ffde59, #ff8c00);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
    margin-bottom: 30px;
    width: 100%;
    max-width: 700px;
}

/* اسم الفريق الفائز */
.winner-name {
    font-size: 2.8rem;
    font-weight: bold;
    color: black;
    text-transform: uppercase;
}

/* النقاط */
.winner-score {
    font-size: 2.2rem;
    font-weight: bold;
    color: white;
    margin-top: 10px;
}

/* قائمة الترتيب */
.ranking-list {
    list-style: none;
    padding: 0;
    margin: 0;
    width: 100%;
    max-width: 700px;
}

/* تصميم كل عنصر في القائمة */
.ranking-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.15);
    padding: 18px;
    border-radius: 12px;
    margin-bottom: 12px;
    font-size: 1.6rem;
    color: white;
    transition: transform 0.3s ease-in-out;
}

.ranking-item:hover {
    transform: scale(1.05);
    background: rgba(255, 255, 255, 0.25);
}

/* زر إعادة اللعب */
.restart-button {
    display: block;
    margin: 40px auto;
    padding: 20px 50px;
    font-size: 2rem;
    font-weight: bold;
    text-align: center;
    background: #ff4d4d;
    color: white;
    border: none;
    border-radius: 35px;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.4);
}

.restart-button:hover {
    transform: scale(1.1);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
    background: #cc0000;
}

.team-points {
    font-size: 1.8rem;
    font-weight: bold;
    color: #ffde59;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.6);
    margin-top: 0; /* إزالة أي هامش علوي زائد */
}
.logout-container {
    position: absolute;
    top: 20px;
    left: 20px;
}
.logout-button {
    background-color: red;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
}
.logout-button:hover {
    background-color: darkred;
}
