@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@300;400;500;700;900&display=swap');

/* ===== متغيرات الألوان ===== */
:root {
    --primary-color: #062d33;
    --accent-color: #0cf6a9;
    --secondary-color: #0c8a97;
    --text-color: #ffffff;
    --dark-bg: #021f23;
    --darker-bg: #01171a;
    --card-bg: rgba(12, 138, 151, 0.1);
    --border-color: rgba(12, 246, 169, 0.2);
    --hover-color: rgba(12, 246, 169, 0.05);
}
/* ===== شاشة التحميل ===== */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: #010c0e; /* خلفية أغمق من الخلفية الأساسية */
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
    overflow: hidden;
}

#loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

.loading-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
}

.loading-logo-container {
    position: relative;
    width: 180px;
    height: 180px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 30px;
}

.loading-logo {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    position: relative;
    z-index: 2;
    animation: pulse 2s infinite ease-in-out;
    object-fit: cover;
}

.loading-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 3px solid transparent;
    border-top: 3px solid var(--accent-color);
    border-right: 3px solid var(--accent-color);
    border-radius: 50%;
    animation: rotate 2s linear infinite;
    box-shadow: 0 0 20px rgba(12, 246, 169, 0.5);
}

.loading-text {
    color: var(--accent-color);
    font-size: 1.5rem;
    font-weight: 500;
    margin-bottom: 15px;
    text-align: center;
}

.loading-dots {
    display: flex;
    gap: 8px;
}

.loading-dots span {
    width: 10px;
    height: 10px;
    background-color: var(--accent-color);
    border-radius: 50%;
    display: inline-block;
    opacity: 0;
    animation: dots 1.4s infinite ease-in-out both;
}

.loading-dots span:nth-child(1) {
    animation-delay: 0s;
}

.loading-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.loading-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

.loading-glow {
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(12, 246, 169, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 1;
}

/* خلفية متحركة لشاشة التحميل */
.loading-bg-shape {
    position: absolute;
    background: linear-gradient(45deg, var(--accent-color), var(--secondary-color));
    opacity: 0.03;
    filter: blur(70px);
    z-index: 0;
}

.loading-shape1 {
    width: 400px;
    height: 400px;
    top: -150px;
    left: -150px;
    border-radius: 40%;
    animation: float 20s infinite ease-in-out;
}

.loading-shape2 {
    width: 500px;
    height: 500px;
    bottom: -200px;
    right: -150px;
    border-radius: 30%;
    animation: float 25s infinite ease-in-out reverse;
}

.loading-shape3 {
    width: 350px;
    height: 350px;
    bottom: 20%;
    left: 20%;
    border-radius: 50%;
    animation: float 18s infinite ease-in-out 5s;
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(0.95);
        opacity: 0.8;
    }
    50% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes dots {
    0%, 100% {
        opacity: 0.2;
        transform: scale(0.8);
    }
    50% {
        opacity: 1;
        transform: scale(1);
    }
}

/* منع التمرير أثناء التحميل */
body.loading {
    overflow: hidden;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(50px, 30px) rotate(5deg);
    }
    50% {
        transform: translate(20px, 60px) rotate(10deg);
    }
    75% {
        transform: translate(-30px, 40px) rotate(5deg);
    }
}
/* ===== إعدادات عامة ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Tajawal', sans-serif;
    scroll-behavior: smooth;
}

body {
    background-color: var(--dark-bg);
    color: var(--text-color);
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

/* ===== القائمة العلوية ===== */
.nav-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 0;
    z-index: 100;
    background: linear-gradient(to bottom, rgba(1, 23, 26, 0.9) 70%, transparent);
    backdrop-filter: blur(10px);
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.nav-logo {
    display: flex;
    align-items: center;
}

.nav-logo img {
    height: 40px;
    width: auto;
}

.nav-logo span {
    font-weight: 700;
    font-size: 1.5rem;
    margin-right: 10px;
    background: linear-gradient(45deg, var(--accent-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-link {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    position: relative;
    padding: 5px 0;
    transition: color 0.3s;
}

.nav-link:hover {
    color: var(--accent-color);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(45deg, var(--accent-color), var(--secondary-color));
    transition: width 0.3s;
}

.nav-link:hover::after {
    width: 100%;
}

.cart-icon {
    position: relative;
    margin-left: 10px;
}

.cart-count {
    position: absolute;
    top: -8px;
    left: -8px;
    background: var(--accent-color);
    color: var(--dark-bg);
    font-size: 0.7rem;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== سلة التسوق ===== */
.page-container {
    margin-top: 120px;
    padding-bottom: 80px;
    min-height: calc(100vh - 200px);
    position: relative;
}

.page-header {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

.page-title {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 10px;
    position: relative;
    display: inline-block;
}

.page-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-color), var(--secondary-color));
}

.page-description {
    color: rgba(255, 255, 255, 0.7);
    max-width: 600px;
    margin: 0 auto;
    margin-top: 20px;
}

/* ===== جدول السلة ===== */
.cart-container {
    display: flex;
    flex-direction: column;
    gap: 30px;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    background-color: rgba(1, 23, 26, 0.7);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-color);
}

.cart-header {
    display: grid;
    grid-template-columns: 100px 3fr 1fr 1fr 80px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
    gap: 15px;
}

.cart-header-item {
    font-weight: 700;
    color: var(--accent-color);
    font-size: 1.1rem;
}

.cart-items {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.cart-item {
    display: grid;
    grid-template-columns: 100px 3fr 1fr 1fr 80px;
    padding: 15px 0;
    border-bottom: 1px solid rgba(12, 246, 169, 0.1);
    align-items: center;
    gap: 15px;
    transition: background-color 0.3s;
}

.cart-item:hover {
    background-color: var(--hover-color);
    border-radius: 8px;
}

.item-image {
    width: 80px;
    height: 80px;
    border-radius: 10px;
    overflow: hidden;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
}

.item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.item-details {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.item-name {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text-color);
}

.item-description {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

.item-license {
    display: inline-block;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 2px 8px;
    border-radius: 5px;
    font-size: 0.8rem;
    margin-top: 5px;
    width: fit-content;
    color: var(--accent-color);
}

.item-price {
    font-weight: 700;
    color: var(--accent-color);
}

.item-quantity {
    display: flex;
    align-items: center;
    gap: 10px;
}

.qty-btn {
    width: 25px;
    height: 25px;
    border-radius: 5px;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
}

.qty-btn:hover {
    background-color: var(--accent-color);
    color: var(--dark-bg);
}

.qty-value {
    font-weight: 700;
    width: 30px;
    text-align: center;
}

.item-remove {
    cursor: pointer;
    width: 35px;
    height: 35px;
    border-radius: 8px;
    background-color: rgba(255, 100, 100, 0.1);
    border: 1px solid rgba(255, 100, 100, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 100, 100, 0.8);
    transition: all 0.3s;
}

.item-remove:hover {
    background-color: rgba(255, 100, 100, 0.2);
    color: rgba(255, 100, 100, 1);
}

/* ===== ملخص السلة ===== */
.cart-summary {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 20px;
    background-color: var(--card-bg);
    border-radius: 10px;
    border: 1px solid var(--border-color);
    margin-top: 20px;
}

.summary-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--accent-color);
    margin-bottom: 10px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(12, 246, 169, 0.1);
}

.summary-row:last-child {
    border-bottom: none;
}

.summary-label {
    color: rgba(255, 255, 255, 0.7);
}

.summary-value {
    font-weight: 700;
}

.total-row {
    font-size: 1.2rem;
    color: var(--accent-color);
    padding-top: 10px;
    margin-top: 10px;
    border-top: 1px dashed var(--border-color);
}

/* ===== الأزرار ===== */
.cart-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
    gap: 20px;
}

.btn {
    display: inline-block;
    background: linear-gradient(45deg, var(--accent-color), var(--secondary-color));
    color: var(--dark-bg);
    font-weight: 700;
    padding: 12px 40px;
    border-radius: 50px;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 20px rgba(12, 246, 169, 0.6);
    font-size: 1.1rem;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    border: none;
    text-align: center;
}

.btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 25px rgba(12, 246, 169, 0.8);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--accent-color);
    color: var(--accent-color);
    box-shadow: none;
}

.btn-outline:hover {
    background-color: rgba(12, 246, 169, 0.1);
    box-shadow: 0 0 15px rgba(12, 246, 169, 0.3);
}

/* ===== تذييل الصفحة ===== */
.footer {
    background-color: var(--darker-bg);
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid rgba(12, 246, 169, 0.1);
}

.footer-logo {
    margin-bottom: 20px;
}

.footer-logo img {
    height: 50px;
    width: auto;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.footer-link {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-link:hover {
    color: var(--accent-color);
}

.footer-text {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
}

/* ===== نافذة تأكيد الحذف ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(1, 23, 26, 0.9);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-container {
    background-color: var(--darker-bg);
    border-radius: 15px;
    padding: 30px;
    max-width: 400px;
    width: 90%;
    border: 1px solid var(--border-color);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
    transform: translateY(30px);
    transition: transform 0.3s;
}

.modal-overlay.active .modal-container {
    transform: translateY(0);
}

.modal-title {
    font-size: 1.5rem;
    color: var(--text-color);
    margin-bottom: 15px;
    text-align: center;
}

.modal-message {
    margin-bottom: 25px;
    color: rgba(255, 255, 255, 0.7);
    text-align: center;
}

.modal-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.modal-btn {
    padding: 10px 25px;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
}

.btn-confirm {
    background-color: rgba(255, 100, 100, 0.2);
    color: rgba(255, 100, 100, 1);
    border: 1px solid rgba(255, 100, 100, 0.3);
}

.btn-confirm:hover {
    background-color: rgba(255, 100, 100, 0.3);
}

.btn-cancel {
    background-color: var(--card-bg);
    color: var(--text-color);
    border: 1px solid var(--border-color);
}

.btn-cancel:hover {
    background-color: rgba(12, 246, 169, 0.1);
}

/* ===== سلة فارغة ===== */
.empty-cart {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 20px;
    margin: 50px auto;
    padding: 40px;
}

.empty-cart-icon {
    font-size: 5rem;
    color: var(--border-color);
    margin-bottom: 20px;
}

.empty-cart-title {
    font-size: 1.8rem;
    color: var(--text-color);
    margin-bottom: 10px;
}

.empty-cart-message {
    color: rgba(255, 255, 255, 0.7);
    max-width: 400px;
    margin-bottom: 30px;
}

/* ===== الأشكال الخلفية ===== */
.bg-shape {
    position: absolute;
    background: linear-gradient(45deg, var(--accent-color), var(--secondary-color));
    opacity: 0.03;
    filter: blur(50px);
    z-index: 0;
}

.shape1 {
    width: 300px;
    height: 300px;
    top: -50px;
    left: -50px;
    border-radius: 40%;
    animation: float 20s infinite ease-in-out;
}

.shape2 {
    width: 400px;
    height: 400px;
    bottom: -100px;
    right: -100px;
    border-radius: 30%;
    animation: float 25s infinite ease-in-out reverse;
}

.shape3 {
    width: 250px;
    height: 250px;
    top: 60%;
    left: 10%;
    border-radius: 50%;
    animation: float 18s infinite ease-in-out 5s;
}

/* ===== التحريكات ===== */
@keyframes float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(50px, 30px) rotate(5deg);
    }
    50% {
        transform: translate(20px, 60px) rotate(10deg);
    }
    75% {
        transform: translate(-30px, 40px) rotate(5deg);
    }
}

/* ===== تنسيقات الشاشات المختلفة ===== */
@media (max-width: 991px) {
    .cart-header {
        grid-template-columns: 80px 2fr 1fr 80px;
    }
    
    .cart-header-item:nth-child(4) {
        display: none;
    }
    
    .cart-item {
        grid-template-columns: 80px 2fr 1fr 80px;
    }
    
    .cart-item .item-price {
        display: none;
    }
    
    .nav-links {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
}

@media (max-width: 767px) {
    .page-title {
        font-size: 2rem;
    }
    
    .cart-container {
        padding: 20px 15px;
    }
    
    .cart-header {
        display: none;
    }
    
    .cart-item {
        grid-template-columns: 70px 1fr;
        gap: 15px;
        padding: 15px;
        background-color: var(--card-bg);
        border-radius: 10px;
        border: 1px solid var(--border-color);
    }
    
    .item-details {
        grid-column: span 1;
    }
    
    .item-meta {
        grid-column: span 2;
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-top: 15px;
    }
    
    .cart-actions {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
}

