:root {
    --primary-color: #04cda3;
    --primary-dark: #039f7d;
    --secondary-color: #2c3e50;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --gray-color: #6c757d;
    --light-gray: #e9ecef;
    --box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}


/* Global Styles */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Cairo', sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
    background-color: #f5f5f5;
    overflow-x: hidden;
}


/* Header Styles - ثابت لجميع الصفحات */

.sticky-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background-color: white;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.logo-animate {
    height: 50px;
    transition: transform 0.3s ease;
}

.logo-animate:hover {
    transform: scale(1.05);
}

.search-container {
    display: flex;
    align-items: center;
    flex-grow: 1;
    margin: 0 2rem;
    position: relative;
}

#trackerCodeInput {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid var(--light-gray);
    border-radius: 30px;
    font-size: 1rem;
    transition: var(--transition);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

#trackerCodeInput:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(4, 205, 163, 0.2);
}

.search-btn {
    position: absolute;
    right: 10px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.search-btn:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

.links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.links a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 600;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.links a:hover {
    color: var(--primary-color);
}

.btn-login {
    padding: 0.5rem 1rem;
    border: 2px solid var(--primary-color);
    border-radius: 5px;
}

.btn-login:hover {
    background: var(--primary-color);
    color: white !important;
}

.btn-cart {
    position: relative;
    padding: 0.5rem 1rem;
}

.cart-text {
    display: inline-block;
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: bold;
}


/* Dropdown Menu for Mobile */

.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    cursor: pointer;
    z-index: 1001;
}

.hamburger span {
    display: block;
    height: 3px;
    width: 100%;
    background: var(--dark-color);
    border-radius: 3px;
    transition: var(--transition);
}

.hamburger.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

.dropDown {
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    background: white;
    padding: 1rem 2rem;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    transform: translateY(-150%);
    transition: transform 0.4s ease;
}

.dropDown.show {
    transform: translateY(0);
}


/* Hero Section - للصفحات الرئيسية */

.hero-section {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('https://via.placeholder.com/1920x600?text=WearHouse+Collection');
    background-size: cover;
    background-position: center;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    margin-bottom: 3rem;
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

.hero-content p {
    font-size: 1.5rem;
    margin-bottom: 2rem;
}


/* Container رئيسي لجميع الصفحات */

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}


/* Breadcrumb - ثابت لجميع الصفحات */

.breadcrumb {
    display: flex;
    list-style: none;
    padding: 1rem 0;
    margin-bottom: 2rem;
    background-color: #FFFFFF;
}

.breadcrumb li {
    margin-right: 0.5rem;
}

.breadcrumb li:after {
    content: '/';
    margin-left: 0.5rem;
    color: var(--gray-color);
}

.breadcrumb li:last-child:after {
    content: '';
}

.breadcrumb a {
    text-decoration: none;
    color: var(--gray-color);
    transition: var(--transition);
}

.breadcrumb a:hover {
    color: var(--primary-color);
}


/* نظام عرض المنتجات - موحد لجميع الصفحات */

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    position: relative;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.card-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--primary-color);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
    z-index: 1;
}

.card-image-container {
    position: relative;
    overflow: hidden;
    height: 0;
    padding-bottom: 100%;
    /* نسبة 1:1 */
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.card:hover .product-image {
    transform: scale(1.05);
}

.quick-view {
    position: absolute;
    bottom: -50px;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    text-align: center;
    padding: 0.8rem;
    font-weight: bold;
    transition: var(--transition);
    cursor: pointer;
}

.card:hover .quick-view {
    bottom: 0;
}

.card-content {
    padding: 1.5rem;
}

.price {
    display: block;
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.old-price {
    text-decoration: line-through;
    color: var(--gray-color);
    font-size: 0.9rem;
    margin-right: 0.5rem;
}

.title {
    font-size: 1.1rem;
    margin-bottom: 0.8rem;
    font-weight: 600;
    color: var(--secondary-color);
    height: 40px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.rating {
    color: #f1c40f;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.rating .far {
    color: #e0e0e0;
}

.reviews {
    color: var(--gray-color);
    font-size: 0.8rem;
    margin-left: 0.5rem;
}

.customize-btn {
    width: 100%;
    padding: 0.8rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 30px;
    font-weight: bold;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.customize-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(4, 205, 163, 0.3);
}

.customize-btn i {
    transition: transform 0.3s ease;
}

.customize-btn:hover i {
    transform: translateX(3px);
}


/* Footer - ثابت لجميع الصفحات */

.site-footer {
    background: var(--secondary-color);
    color: white;
    padding: 4rem 0 0;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-section h3 {
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.footer-section h3:after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 2px;
    background: var(--primary-color);
}

.footer-section p {
    margin-bottom: 1.5rem;
    color: #bdc3c7;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.8rem;
}

.footer-section ul li a {
    color: #bdc3c7;
    text-decoration: none;
    transition: var(--transition);
}

.footer-section ul li a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.social-icons {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    transition: var(--transition);
}

.social-icons a:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
}

.newsletter-form {
    display: flex;
    margin-top: 1.5rem;
}

.newsletter-form input {
    flex: 1;
    padding: 0.8rem;
    border: none;
    border-radius: 5px 0 0 5px;
}

.newsletter-form button {
    padding: 0 1.5rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 0 5px 5px 0;
    cursor: pointer;
    transition: var(--transition);
}

.newsletter-form button:hover {
    background: var(--primary-dark);
}

.footer-bottom {
    text-align: center;
    padding: 1.5rem 0;
    margin-top: 3rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #bdc3c7;
    font-size: 0.9rem;
}


/* Loader - موحد لجميع الصفحات */

.customize-loader {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.8);
    z-index: 9999;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.customize-loader.active {
    display: flex;
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

.loader-text {
    color: var(--secondary-color);
    font-size: 1.2rem;
    font-weight: 600;
    margin-top: 15px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}


/* Responsive Styles - يعمل على جميع الشاشات */

@media (max-width: 992px) {
    .links {
        display: none;
    }
    .hamburger {
        display: flex;
    }
    .search-container {
        margin: 0 1rem;
    }
    .hero-content h1 {
        font-size: 2.5rem;
    }
    .hero-content p {
        font-size: 1.2rem;
    }
}

@media (max-width: 768px) {
    header nav {
        padding: 1rem;
    }
    .hero-section {
        height: 300px;
    }
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
}

@media (max-width: 576px) {
    .hero-content h1 {
        font-size: 2rem;
    }
    .hero-content p {
        font-size: 1rem;
    }
    .search-container {
        margin: 0 0.5rem;
    }
    #trackerCodeInput {
        padding: 0.6rem 0.8rem;
    }
    .footer-content {
        grid-template-columns: 1fr;
    }
}