/* Page-specific styles: products.html */

.products-section {
    margin-top: 0;
    padding: 4rem 0;
    background: linear-gradient(135deg, var(--very-light-blue) 0%, var(--light-blue) 100%);
    min-height: 100vh;
}

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

.offers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 3rem;
    margin-bottom: 4rem;
}

.offer-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-radius: 25px;
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(255, 215, 0, 0.15);
    transition: all 0.4s ease;
    position: relative;
    border: 3px solid #FFD700;
    animation: fadeInUp 0.8s ease-out;
}

.offer-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 25px 50px rgba(27, 40, 72, 0.25);
    border-color: var(--secondary-color);
}

.offer-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #1B2848;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    z-index: 10;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
}

.offer-image {
    position: relative;
    height: 250px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--light-blue) 0%, var(--very-light-blue) 100%);
    border-bottom: 2px solid #FFD700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.offer-image i {
    font-size: 4rem;
    color: var(--secondary-color);
    opacity: 0.7;
}

.offer-content {
    padding: 2rem;
}

.offer-content h3 {
    color: var(--secondary-color);
    font-size: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.offer-content p {
    color: var(--text-color);
    line-height: 1.6;
    margin-bottom: 1.5rem;
    font-size: 1rem;
}

.offer-features {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.offer-features span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(27, 155, 216, 0.1);
    color: var(--secondary-color);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

.offer-features i {
    color: #28a745;
}

.offer-btn {
    width: 100%;
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #1B2848;
    border: none;
    padding: 1rem 2rem;
    border-radius: 25px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 5px 15px rgba(255, 215, 0, 0.4);
}

.offer-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.6);
    background: linear-gradient(135deg, #FFA500 0%, #FF8C00 100%);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .products-section {
        padding: 1.5rem 0 3rem;
    }

    .offers-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .section-title {
        margin-bottom: 2rem;
    }

    .offer-content {
        padding: 1.5rem;
    }
}

.section-title {
    text-align: center;
    color: var(--secondary-color);
    margin-bottom: 4rem;
    font-size: 4rem;
    font-weight: 800;
    text-shadow: 3px 3px 6px rgba(59, 130, 246, 0.2);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--gold) 100%);
    border-radius: 2px;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.search-container {
    max-width: 700px;
    margin: 0 auto 4rem;
    position: relative;
}

.search-icon {
    position: absolute;
    right: 25px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--secondary-color);
    font-size: 1.4rem;
}

#searchInput {
    width: 100%;
    padding: 20px 60px 20px 25px;
    border: 3px solid var(--light-blue);
    border-radius: 30px;
    font-size: 1.2rem;
    background-color: white;
    transition: all 0.4s ease;
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.15);
}

#searchInput:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 5px rgba(251, 191, 36, 0.2);
    transform: scale(1.02);
}

/* الأقسام الرئيسية */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 3.5rem;
    margin-bottom: 4rem;
}

.category-card {
    background: linear-gradient(145deg, #1B2848 0%, #0f172a 100%) !important;
    /* Premium Dark Gradient */
    border: 1px solid rgba(255, 215, 0, 0.2);
    /* Thin Subtle Gold Border */
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3),
        inset 0 0 20px rgba(255, 255, 255, 0.02);
    /* Depth */
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    text-decoration: none;
    /* Remove underline */
}

.category-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5),
        0 0 15px rgba(255, 215, 0, 0.1);
    /* Gold Glow */
    border-color: rgba(255, 215, 0, 0.5);
}

.category-image {
    width: 100%;
    height: 60px;
    /* Minimal spacer since icon is gone */
    background: transparent;
    /* Seamless */
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    border-bottom: none;
    /* No separator */
}

.category-image::before {
    display: none;
}


.category-image i {
    display: none;
    /* Remove icons */
}



.category-content {
    padding: 1rem 3rem 3rem;
    /* Adjusted padding */
    text-align: center;
}

.category-content h3 {
    color: #FFD700;
    /* Gold title */
    margin-bottom: 2rem;
    font-size: 2.5rem;
    font-weight: 800;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.category-content p {
    color: #cbd5e1;
    /* Light grey text */
    line-height: 1.8;
    margin-bottom: 3rem;
    font-size: 1.3rem;
    font-weight: 500;
}

.category-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    padding: 1rem 2.5rem;
    background: rgba(255, 255, 255, 0.1);
    /* Glassy Transparent */
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: none;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.category-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.6s;
}

.category-link:hover::before {
    left: 100%;
}

.category-link:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 12px 25px rgba(255, 215, 0, 0.5);
    background: linear-gradient(to right, #FFA500, #FFD700);
}

.category-link i {
    margin-left: 0.8rem;
    font-size: 1.1rem;
}

/* تفاصيل المنتجات - مخفية افتراضياً */
.products-section-details {
    margin: 4rem 0;
    padding: 3rem;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 25px;
    border: 2px solid var(--gold);
    box-shadow: 0 15px 35px rgba(59, 130, 246, 0.1);
    display: none;
    /* إخفاء التفاصيل افتراضياً */
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
    position: relative;
}

.products-section-details.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.details-title {
    text-align: center;
    color: var(--secondary-color);
    font-size: 2.5rem;
    margin-bottom: 3rem;
    font-weight: 800;
    position: relative;
}

.details-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--gold) 100%);
    border-radius: 2px;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.products-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
    margin-bottom: 2rem;
}

.product-item {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.1);
    transition: all 0.4s ease;
    border: 2px solid var(--light-blue);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.product-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.05), transparent);
    transition: left 0.6s;
}

.product-item:hover::before {
    left: 100%;
}

.product-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(27, 40, 72, 0.2);
    border-color: #1B2848;
}

.product-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, var(--light-blue) 0%, var(--very-light-blue) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    border-radius: 15px;
    overflow: hidden;
    position: relative;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.4s ease;
}

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

@media (max-width: 768px) {

    .product-image img,
    .fallback-logo {
        object-fit: cover;
        padding: 0;
    }
}

.product-item i {
    font-size: 3rem;
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
    display: block;
    transition: all 0.4s ease;
}

.fallback-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--light-blue) 0%, var(--very-light-blue) 100%);
    padding: 1rem;
}

.product-item:hover i {
    transform: scale(1.1) rotate(5deg);
    color: #1B2848;
}

.product-item h5 {
    color: var(--secondary-color);
    font-size: 1.4rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.product-item p {
    color: var(--text-color);
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.product-price {
    color: var(--secondary-color);
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    padding: 0.8rem;
    background: var(--light-blue);
    border-radius: 15px;
    display: inline-block;
    min-width: 120px;
}

.product-features {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.product-features li {
    color: var(--text-color);
    font-size: 1rem;
    margin-bottom: 0.8rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--light-blue);
    font-weight: 500;
}

.product-features li:last-child {
    border-bottom: none;
}

.product-features li::before {
    content: '✓';
    color: var(--secondary-color);
    margin-left: 0.8rem;
    font-weight: bold;
    font-size: 1.1rem;
}

.view-more-btn {
    display: inline-block;
    padding: 1rem 2rem;
    background: #1b9bd8;
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.4s ease;
    margin-top: 1.5rem;
    position: relative;
    overflow: hidden;
}

.view-more-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s;
}

.view-more-btn:hover::before {
    left: 100%;
}

.view-more-btn:hover {
    background: #1B2848;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(27, 40, 72, 0.3);
}

/* زر إغلاق التفاصيل */
.close-details {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #1b9bd8;
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-details:hover {
    background: #1B2848;
    transform: scale(1.1);
}

/* تأثير التمرير السلس */
html {
    scroll-behavior: smooth;
}

/* تحسينات للأجهزة المحمولة */
@media (max-width: 1200px) {
    .categories-grid {
        grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
        gap: 3rem;
    }
}

@media (max-width: 768px) {
    .categories-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .section-title {
        font-size: 3rem;
        margin-bottom: 3rem;
    }

    .products-list {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .category-content {
        padding: 2rem;
    }

    .products-section-details {
        padding: 2rem;
        margin: 2rem 0;
    }
}

@media (max-width: 480px) {
    .products-container {
        padding: 0 1rem;
    }

    .category-content h3 {
        font-size: 2rem;
    }

    .category-content p {
        font-size: 1.1rem;
    }

    .section-title {
        font-size: 2.5rem;
    }

    .search-container {
        margin-bottom: 3rem;
    }

    #searchInput {
        padding: 18px 50px 18px 20px;
        font-size: 1.1rem;
    }
}

/* Standard Product Action Buttons */
.details-btn {
    flex: 1;
    background: linear-gradient(to right, #3498db, #95d5ee);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.2);
    padding: 1rem 2rem;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 8px 20px rgba(52, 152, 219, 0.3);
}

.details-btn:hover {
    transform: translateY(-5px) scale(1.03);
    box-shadow: 0 12px 25px rgba(52, 152, 219, 0.5);
    background: linear-gradient(to right, #2980b9, #3498db);
}

.offer-btn {
    flex: 1;
    background: linear-gradient(to right, #f1c40f, #e67e22);
    color: #1B2848;
    border: 2px solid rgba(255, 255, 255, 0.2);
    padding: 1rem 2rem;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 8px 20px rgba(230, 126, 34, 0.3);
}

.offer-btn:hover {
    transform: translateY(-5px) scale(1.03);
    box-shadow: 0 12px 25px rgba(230, 126, 34, 0.5);
    background: linear-gradient(to right, #e67e22, #f39c12);
}
