/* Souq Tanta - Modern E-Commerce Design */

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

:root {
    --primary: #e63946;
    --secondary: #ff6b35;
    --accent: #f7941e;
    --bg-light: #fefefe;
    --bg-cream: #fff5f0;
    --text-dark: #1a1a2e;
    --text-gray: #6b7280;
    --border: #ffe0d6;
}

body { 
    font-family: 'Tajawal', sans-serif; 
    background: var(--bg-light); 
    color: var(--text-dark); 
    line-height: 1.7; 
    overflow-x: hidden; 
}

/* Header */
header { 
    background: white; 
    border-bottom: 1px solid var(--border); 
    position: sticky; 
    top: 0; 
    z-index: 1000; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.03); 
}

.top-bar { 
    background: #d62828; 
    color: white; 
    padding: 8px 0; 
    font-size: 13px; 
}

.container { 
    max-width: 1280px; 
    margin: 0 auto; 
    padding: 0 20px; 
}

.top-bar .container { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
}

.top-bar-links a { 
    color: white; 
    text-decoration: none; 
    margin-left: 20px; 
    opacity: 0.9; 
    transition: opacity 0.3s; 
}

.top-bar-links a:hover { 
    opacity: 1; 
}

.main-header { 
    padding: 15px 0; 
}

.header-content { 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    gap: 30px; 
}

.logo img { 
    height: 65px; 
    width: auto; 
}

.search-bar { 
    flex: 1; 
    max-width: 600px; 
    position: relative; 
}

.search-bar input { 
    width: 100%; 
    padding: 14px 50px 14px 20px; 
    border: 2px solid var(--border); 
    border-radius: 50px; 
    font-size: 15px; 
    font-family: 'Tajawal', sans-serif; 
    transition: all 0.3s; 
}

.search-bar input:focus { 
    outline: none; 
    border-color: var(--secondary); 
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1); 
}

.search-bar button { 
    position: absolute; 
    left: 5px; 
    top: 50%; 
    transform: translateY(-50%); 
    background: var(--secondary); 
    border: none; 
    padding: 10px 20px; 
    border-radius: 50px; 
    color: white; 
    cursor: pointer; 
    transition: all 0.3s; 
}

.search-bar button:hover { 
    background: var(--primary); 
    transform: translateY(-50%) scale(1.05); 
}

.header-actions { 
    display: flex; 
    gap: 25px; 
    align-items: center; 
}

.header-btn { 
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    text-decoration: none; 
    color: var(--text-dark); 
    transition: all 0.3s; 
    position: relative; 
}

.header-btn:hover { 
    color: var(--secondary); 
    transform: translateY(-2px); 
}

.header-btn svg { 
    width: 28px; 
    height: 28px; 
    margin-bottom: 3px; 
}

.header-btn span { 
    font-size: 12px; 
    font-weight: 500; 
}

.cart-badge { 
    position: absolute; 
    top: -5px; 
    left: -8px; 
    background: var(--secondary); 
    color: white; 
    border-radius: 50%; 
    width: 20px; 
    height: 20px; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    font-size: 11px; 
    font-weight: 700; 
}

/* Navigation */
nav { 
    background: white; 
    border-bottom: 1px solid var(--border); 
}

.nav-links { 
    display: flex; 
    justify-content: center; 
    gap: 40px; 
    padding: 15px 0; 
    list-style: none; 
    flex-wrap: wrap; 
}

.nav-links a { 
    text-decoration: none; 
    color: var(--text-dark); 
    font-weight: 600; 
    font-size: 15px; 
    transition: all 0.3s; 
    position: relative; 
}

.nav-links a::after { 
    content: ''; 
    position: absolute; 
    bottom: -15px; 
    right: 0; 
    width: 0; 
    height: 3px; 
    background: var(--secondary); 
    transition: width 0.3s; 
}

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

.nav-links a:hover::after { 
    width: 100%; 
}

/* Hero Slider Section */
.hero-slider {
    position: relative;
    width: 100%;
    min-height: auto;
    overflow: hidden;
    background: #fff;
}

.hero-slider-track {
    position: relative;
    width: 100%;
    height: auto;
    min-height: auto;
}

.hero-slider .hero-slide {
    position: absolute;
    inset: 0;
    display: none !important;
    width: 100%;
    height: 100%;
    animation: fadeSlide 0.6s ease-in-out;
}

.hero-slider .hero-slide.active {
    position: relative;
    display: block !important;
    height: auto;
}

.hero-slider .hero-slide img {
    display: block;
    width: 100%;
    height: auto;
    min-height: 0;
    max-height: none;
    object-fit: contain;
}

.hero-slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: rgba(0, 0, 0, 0.35);
    color: #fff;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 5;
    font-size: 22px;
    line-height: 44px;
    text-align: center;
    transition: all 0.25s ease;
}

.hero-slider-btn:hover {
    background: rgba(0, 0, 0, 0.55);
}

.hero-slider-btn.prev {
    right: 14px;
}

.hero-slider-btn.next {
    left: 14px;
}

.hero-slider-dots {
    position: absolute;
    bottom: 14px;
    right: 50%;
    transform: translateX(50%);
    display: flex;
    gap: 8px;
    z-index: 5;
}

.hero-slider-dots .dot {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    transition: all 0.25s ease;
}

.hero-slider-dots .dot.active {
    background: #ff6b35;
    transform: scale(1.15);
}

@keyframes fadeSlide {
    from { opacity: 0.2; }
    to { opacity: 1; }
}

.btn { 
    padding: 15px 35px; 
    border-radius: 50px; 
    font-size: 16px; 
    font-weight: 700; 
    text-decoration: none; 
    transition: all 0.3s; 
    border: none; 
    cursor: pointer; 
    font-family: 'Tajawal', sans-serif; 
    display: inline-block; 
}

.btn-primary { 
    background: var(--secondary); 
    color: white; 
}

.btn-primary:hover { 
    background: var(--accent); 
    transform: translateY(-3px); 
    box-shadow: 0 10px 25px rgba(255, 107, 53, 0.3); 
}

.btn-outline { 
    background: transparent; 
    color: white; 
    border: 2px solid white; 
}

.btn-outline:hover { 
    background: white; 
    color: var(--primary); 
}

/* Categories */
.categories { 
    padding: 80px 0; 
    background: var(--bg-cream); 
}

.section-header { 
    text-align: center; 
    margin-bottom: 60px; 
}

.section-header h2 { 
    font-family: 'Cairo', sans-serif; 
    font-size: 42px; 
    font-weight: 800; 
    color: var(--text-dark); 
    margin-bottom: 15px; 
}

.section-header p { 
    font-size: 18px; 
    color: var(--text-gray); 
}

.category-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); 
    gap: 25px; 
}

.category-card { 
    background: white; 
    border-radius: 20px; 
    padding: 35px 20px; 
    text-align: center; 
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1); 
    border: 2px solid transparent; 
    cursor: pointer; 
    position: relative; 
    overflow: hidden; 
}

.category-card::before { 
    content: ''; 
    position: absolute; 
    top: 0; 
    left: 0; 
    right: 0; 
    bottom: 0; 
    background: linear-gradient(135deg, var(--secondary) 0%, var(--accent) 100%); 
    opacity: 0; 
    transition: opacity 0.4s; 
    z-index: 0; 
}

.category-card:hover { 
    transform: translateY(-10px); 
    box-shadow: 0 20px 40px rgba(0,0,0,0.12); 
    border-color: var(--secondary); 
}

.category-card:hover::before { 
    opacity: 0.05; 
}

.category-card .icon { 
    font-size: 48px; 
    margin-bottom: 15px; 
    position: relative; 
    z-index: 1; 
}

.category-card h3 { 
    font-size: 20px; 
    font-weight: 700; 
    color: var(--text-dark); 
    margin-bottom: 8px; 
    position: relative; 
    z-index: 1; 
}

.category-card p { 
    font-size: 14px; 
    color: var(--text-gray); 
    position: relative; 
    z-index: 1; 
}

/* Products Section */
.products { 
    padding: 80px 0; 
    background: white; 
}

.product-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); 
    gap: 30px; 
}

.product-card { 
    background: white; 
    border-radius: 20px; 
    overflow: hidden; 
    border: 2px solid var(--border); 
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1); 
    cursor: pointer; 
    position: relative; 
}

.product-card:hover { 
    transform: translateY(-8px); 
    box-shadow: 0 20px 40px rgba(0,0,0,0.1); 
    border-color: var(--secondary); 
}

.product-badge { 
    position: absolute; 
    top: 15px; 
    right: 15px; 
    background: var(--secondary); 
    color: white; 
    padding: 6px 12px; 
    border-radius: 20px; 
    font-size: 12px; 
    font-weight: 700; 
    z-index: 2; 
}

.product-image { 
    height: 280px; 
    background: #f9fafb; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    overflow: hidden; 
    position: relative; 
}

.product-image img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    transition: transform 0.5s; 
}

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

.product-info { 
    padding: 20px; 
}

.product-category { 
    font-size: 13px; 
    color: var(--secondary); 
    font-weight: 600; 
    margin-bottom: 8px; 
    text-transform: uppercase; 
}

.product-title { 
    font-size: 17px; 
    font-weight: 700; 
    color: var(--text-dark); 
    margin-bottom: 10px; 
    line-height: 1.4; 
}

.product-rating { 
    display: flex; 
    align-items: center; 
    gap: 5px; 
    margin-bottom: 12px; 
}

.stars { 
    color: #fbbf24; 
    font-size: 14px; 
}

.rating-count { 
    font-size: 13px; 
    color: var(--text-gray); 
}

.product-footer { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    margin-top: 15px; 
    padding-top: 15px; 
    border-top: 1px solid var(--border); 
}

.product-price { 
    font-size: 24px; 
    font-weight: 800; 
    color: var(--primary); 
}

.product-price span { 
    font-size: 16px; 
    font-weight: 600; 
}

.add-to-cart { 
    background: var(--secondary); 
    color: white; 
    border: none; 
    padding: 10px 20px; 
    border-radius: 50px; 
    font-weight: 600; 
    cursor: pointer; 
    transition: all 0.3s; 
    font-family: 'Tajawal', sans-serif; 
}

.add-to-cart:hover { 
    background: var(--primary); 
    transform: scale(1.05); 
}

/* Features */
.features { 
    padding: 80px 0; 
    background: var(--bg-cream); 
}

.features-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); 
    gap: 40px; 
    margin-top: 50px; 
}

.feature-card { 
    text-align: center; 
    padding: 30px; 
}

.feature-icon { 
    width: 80px; 
    height: 80px; 
    background: linear-gradient(135deg, var(--secondary) 0%, var(--accent) 100%); 
    border-radius: 50%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    margin: 0 auto 25px; 
    font-size: 36px; 
}

.feature-card h3 { 
    font-size: 22px; 
    font-weight: 700; 
    color: var(--text-dark); 
    margin-bottom: 12px; 
}

.feature-card p { 
    font-size: 15px; 
    color: var(--text-gray); 
    line-height: 1.6; 
}

/* Footer */
footer { 
    background: #d62828; 
    color: white; 
    padding: 60px 0 20px; 
}

.footer-content { 
    display: grid; 
    grid-template-columns: 2fr 1fr 1fr 1fr; 
    gap: 50px; 
    margin-bottom: 40px; 
}

.footer-about h3 { 
    font-family: 'Cairo', sans-serif; 
    font-size: 28px; 
    font-weight: 800; 
    margin-bottom: 20px; 
}

.footer-about p { 
    color: rgba(255,255,255,0.8); 
    line-height: 1.8; 
    margin-bottom: 20px; 
}

.social-links { 
    display: flex; 
    gap: 12px; 
}

.social-links a { 
    width: 45px; 
    height: 45px; 
    background: rgba(255,255,255,0.1); 
    border-radius: 50%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    color: white; 
    text-decoration: none; 
    transition: all 0.3s; 
    font-size: 20px; 
}

.social-links a:hover { 
    background: var(--secondary); 
    transform: translateY(-3px); 
}

.footer-section h4 { 
    font-size: 18px; 
    font-weight: 700; 
    margin-bottom: 20px; 
}

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

.footer-section ul li { 
    margin-bottom: 12px; 
}

.footer-section ul li a { 
    color: rgba(255,255,255,0.8); 
    text-decoration: none; 
    transition: all 0.3s; 
}

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

.footer-bottom { 
    text-align: center; 
    padding-top: 30px; 
    border-top: 1px solid rgba(255,255,255,0.1); 
    color: rgba(255,255,255,0.7); 
}

/* Responsive */
@media (max-width: 968px) {
    .footer-content { grid-template-columns: 1fr 1fr; }
    .nav-links { gap: 20px; }
    .hero-slide img { max-height: 420px; }
}

@media (max-width: 768px) {
    .header-content { flex-wrap: wrap; }
    .search-bar { order: 3; width: 100%; max-width: 100%; }
    .category-grid { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
    .footer-content { grid-template-columns: 1fr; }

    .hero-slider .hero-slide img {
        min-height: 0;
        max-height: none;
        object-fit: contain;
        background: #fff;
    }

    .hero-slider-btn {
        width: 36px;
        height: 36px;
        font-size: 18px;
        line-height: 36px;
    }

    .hero-slider-dots {
        bottom: 8px;
    }
}
