:root {
    --primary-color: #D4AF37;
    --secondary-color: #000000;
    --light-bg: #ffffff; /* أبيض نقي للنهاري */
    --light-text: #333333; /* نص داكن للنهاري */
    --light-border: #ccc;
    --dark-bg: #1a1a1a;
    --dark-card: #2d2d2d;
    --dark-text: #fff;
    --dark-border: #555;
    --sidebar-width: 280px;
}

/* عامة */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Tajawal', sans-serif;
    background: var(--light-bg);
    color: var(--light-text);
    transition: all 0.3s ease;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* الوضع الليلي */
body.dark-mode {
    background: var(--dark-bg);
    color: var(--dark-text);
}

/* البحث */
.search-container {
    padding: 10px 20px;
    text-align: center;
}

.search-container input {
    width: 90%;
    max-width: 400px;
    padding: 10px;
    font-size: 14px;
    border: 1px solid var(--light-border);
    border-radius: 25px;
    outline: none;
    background-color: #fff;
    color: var(--light-text);
    transition: all 0.3s ease;
}

body.dark-mode .search-container input {
    background-color: #2a2a2a;
    color: var(--dark-text);
    border: 1px solid var(--dark-border);
}

/* عناوين الأقسام */
.container h2 {
    position: relative;
    text-align: center;
    color: var(--primary-color);
    font-weight: bold;
    margin: 40px 0 20px 0;
}

.container h2::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary-color);
}

/* أقسام مثل favorites */
.favorites-section {
    padding: 15px 20px;
    background-color: #fff;
    color: var(--light-text);
    border-radius: 10px;
    transition: background-color 0.3s, color 0.3s;
}

body.dark-mode .favorites-section {
    background-color: var(--dark-card);
    color: var(--dark-text);
}

/* البنرات */
.banner-wrapper {
    padding: 0 10px;
    overflow: hidden;
    box-sizing: border-box;
    margin-bottom: 20px;
    margin-top: 10px;
}

.banner-swiper {
    width: 100%;
    height: 200px;
    aspect-ratio: 16 / 5;
    border-radius: 12px;
    transition: height 0.3s ease;
}

.banner-swiper .swiper-slide img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    border-radius: 12px;
    display: block;
    transition: border-color 0.3s ease;
}

/* تنسيق بنر الأعلى شحن */
.monthly-king-slide {
    position: relative;
    text-align: center;
    cursor: pointer;
}

.monthly-king-info {
    position: absolute;
    top: 50.8%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    color: white;
    pointer-events: none;
}

.monthly-king-profile {
    width: 160px !important;
    height: 160px !important;
    object-fit: cover !important;
    border-radius: 50% !important;
    display: block !important;
    margin: 0 auto 6px auto !important;
}

.monthly-king-info h3 {
    font-size: 0.85rem;
    margin: 0;
    background: rgba(0, 0, 0, 0.7);
    padding: 4px 8px;
    border-radius: 4px;
}


body.dark-mode .banner-swiper .swiper-slide img {
    border: 2px solid #333;
}

/* المحتوى الرئيسي */
.main-content {
    flex-grow: 1;
    padding: 20px;
    margin-top: 5px;
    transition: margin-left 0.4s ease, background-color 0.3s ease;
    background-color: var(--light-bg);
}

body.dark-mode .main-content {
    background-color: #1e1e1e;
}

/* البطاقات */
.card {
    background: #fff;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.05);
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

body.dark-mode .card {
    background: var(--dark-card);
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
}

.card h2 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 20px;
}

/* الشريط الجانبي */
.sidebar {
    position: fixed;
    top: 0;
    left: -280px;
    width: var(--sidebar-width);
    height: 100vh;
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--dark-card) 100%);
    box-shadow: 2px 0 15px rgba(0,0,0,0.2);
    transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.sidebar.active {
    left: 0;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-header h3 {
    color: var(--primary-color);
    font-size: 20px;
}

.close-sidebar {
    font-size: 24px;
    cursor: pointer;
    color: #aaa;
    transition: all 0.3s;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close-sidebar:hover {
    color: white;
    background: rgba(255,255,255,0.1);
}

.user-info {
    padding: 20px;
    background: rgba(0,0,0,0.2);
    margin: 15px;
    border-radius: 10px;
    text-align: center;
    transition: background-color 0.3s ease;
}

body:not(.dark-mode) .user-info {
    background: rgba(212, 175, 55, 0.1);
}

.user-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin: 0 auto 15px;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: 3px solid rgba(255,255,255,0.2);
    overflow: hidden;
    color: white;
    font-weight: bold;
    font-size: 30px;
    transition: background-color 0.3s ease;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-initial {
    font-size: 36px;
    font-weight: bold;
    color: var(--primary-color);
}

.user-info h4 {
    margin: 10px 0 5px;
    font-size: 18px;
    color: var(--primary-color);
}

.user-email {
    font-size: 14px;
    margin: 5px 0;
    font-weight: bold;
    color: #444;
    transition: color 0.3s ease;
}

body.dark-mode .user-email {
    color: #fff;
}

.user-balance {
    color: #4CAF50;
    font-weight: bold;
    font-size: 16px;
    margin: 10px 0 0;
}

.sidebar-menu {
    list-style: none;
    padding: 0 15px;
    flex-grow: 1;
}

.sidebar-menu li {
    margin-bottom: 5px;
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    color: #eee;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s;
    font-size: 15px;
}

.sidebar-menu a:hover {
    background: rgba(212, 175, 55, 0.2);
    transform: translateX(5px);
    color: white;
}

.sidebar-menu i {
    margin-right: 12px;
    font-size: 18px;
    width: 24px;
    text-align: center;
    color: var(--primary-color);
}

.company-info {
    padding: 10px;
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.1);
    margin-top: auto;
}

.company-logo {
    height: 80px;
    margin-bottom: 10px;
}

.company-name {
    color: var(--primary-color);
    font-size: 16px;
    font-weight: bold;
}

/* تأثيرات عامة */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* استجابة الشاشات الصغيرة */
@media (max-width: 768px) {
    .banner-swiper {
        width: 100%;
        height: 120px;
    }
    .banner-swiper .swiper-slide img {
        width: 100%;
        height: 120px;
        object-fit: cover;
    }
    
    .sidebar {
        width: 260px;
        left: -260px;
    }
    
    .sidebar.active ~ .main-content {
        margin-left: 0;
    }
    
    .monthly-king-info {
    position: absolute;
    top: 53%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    color: white;
    pointer-events: none;
}

.monthly-king-profile {
    width: 98px !important;
    height: 98px !important;
    object-fit: cover !important;
    border-radius: 50% !important;
    display: block !important;
    margin: 0 auto 6px auto !important;
}
    
    
    
}
