@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@300;400;500;700&display=swap');

:root {
    --primary-color: #006C35;
    /* Saudi Emerald */
    --primary-light: #00A350;
    --accent-color: #D4AF37;
    /* Royal Gold */
    --text-color: #212121;
    --light-gray: #F8F9FA;
    --white: #FFFFFF;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
}

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

body {
    font-family: 'Tajawal', sans-serif;
    direction: rtl;
    background: var(--light-gray);
    color: var(--text-color);
    line-height: 1.6;
}

/* Header & Navigation */
.topbar {
    background: var(--primary-color);
    color: var(--white);
    padding: 10px 0;
    font-size: 14px;
    border-bottom: 2px solid var(--accent-color);
}

.topbar-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
    padding: 12px 0;
    transition: var(--transition);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 55px;
    width: auto;
    transition: var(--transition);
}

.nav-links {
    display: flex;
    gap: 25px;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: #444;
    font-weight: 600;
    font-size: 15px;
    transition: var(--transition);
    position: relative;
    padding: 5px 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    transition: var(--transition);
}

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

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

.whatsapp-cta {
    background: #25D366;
    color: white !important;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
    text-decoration: none;
    font-size: 14px;
}

.whatsapp-cta:hover {
    background: #128C7E;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 3px;
    transition: var(--transition);
}

/* Hero Section */
.hero {
    position: relative;
    height: 450px;
    background: #000;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(45deg, rgba(0, 108, 53, 0.7), rgba(0, 0, 0, 0.4));
    z-index: 1;
}

.hero-image {
    position: absolute;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.8;
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 0 20px;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero p {
    font-size: 1.25rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* Product Cards */
.product-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    transition: var(--transition);
    border: 1px solid #eee;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-md);
    border-color: var(--accent-color);
}

.product-image-wrapper {
    position: relative;
    padding-top: 100%;
    overflow: hidden;
}

.product-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

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

.product-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--accent-color);
    color: white;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
}

.product-info {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-title {
    font-size: 1.1rem;
    font-weight: 500;
    margin-bottom: 12px;
    height: 2.8em;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-clamp: 2;
}

.product-price-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.price-current {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.price-old {
    text-decoration: line-through;
    color: #999;
    font-size: 1rem;
}

.buy-button {
    background: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    padding: 12px;
    border-radius: 8px;
    font-weight: bold;
    text-align: center;
    text-decoration: none;
    transition: var(--transition);
    margin-top: auto;
}

.buy-button:hover {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 5px 15px rgba(0, 108, 53, 0.3);
}

@keyframes pulse-gold {
    0% {
        box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.4);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(212, 175, 55, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(212, 175, 55, 0);
    }
}

.whatsapp-cta {
    animation: pulse-gold 2s infinite;
}

/* Footer Improvements */
footer {
    background: #111;
    color: #aaa;
    padding: 80px 0 30px;
    margin-top: 100px;
    border-top: 4px solid var(--primary-color);
}

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

.footer-section h3 {
    color: white;
    font-size: 1.3rem;
    margin-bottom: 30px;
    position: relative;
    padding-bottom: 12px;
}

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

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 15px;
}

.footer-links a {
    color: #999;
    text-decoration: none;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-links a:hover {
    color: var(--accent-color);
    padding-right: 10px;
}

.footer-links a::before {
    content: '←';
    font-size: 12px;
    opacity: 0;
    transition: var(--transition);
}

.footer-links a:hover::before {
    opacity: 1;
}

.footer-bottom {
    text-align: center;
    margin-top: 60px;
    padding-top: 30px;
    border-top: 1px solid #222;
    font-size: 14px;
}

.footer-bottom p {
    color: #666;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: white;
        flex-direction: column;
        padding: 100px 40px;
        transition: var(--transition);
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
        z-index: 1000;
        gap: 30px;
        align-items: flex-start;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        font-size: 1.2rem;
        width: 100%;
        border-bottom: 1px solid #eee;
        padding-bottom: 15px;
    }

    .whatsapp-cta {
        width: 100%;
        justify-content: center;
        margin-top: 20px;
    }

    .header-content {
        justify-content: space-between;
    }

    .hero h1 {
        font-size: 2.2rem;
    }

    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
}

/* Product Detail Page */
.product-container {
    max-width: 1200px;
    margin: 60px auto;
    padding: 0 20px;
}

.product-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: var(--shadow-md);
}

.product-gallery img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.product-details h1 {
    font-size: 2.2rem;
    color: var(--primary-color);
    margin-bottom: 20px;
    line-height: 1.4;
}

.product-price-box {
    background: rgba(0, 108, 53, 0.05);
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.whatsapp-order-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background: #25D366;
    color: white;
    text-decoration: none;
    padding: 20px;
    border-radius: 12px;
    font-size: 1.3rem;
    font-weight: bold;
    transition: var(--transition);
    box-shadow: 0 10px 20px rgba(37, 211, 102, 0.2);
    width: 100%;
}

.whatsapp-order-btn:hover {
    background: #128C7E;
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(37, 211, 102, 0.3);
}

.trust-badges {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: 40px;
}

.badge-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: #666;
}

@media (max-width: 768px) {
    .product-layout {
        grid-template-columns: 1fr;
        padding: 20px;
    }

    .product-details h1 {
        font-size: 1.6rem;
    }
}

/* Elite Search Bar */
.search-container {
    max-width: 800px;
    margin: 40px auto;
    position: relative;
    padding: 0 20px;
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input {
    width: 100%;
    padding: 18px 50px 18px 25px;
    border-radius: 50px;
    border: 2px solid #efefef;
    font-size: 1.1rem;
    font-family: inherit;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 10px 25px rgba(0, 108, 53, 0.1);
}

.search-icon {
    position: absolute;
    right: 20px;
    color: #999;
}

/* Breadcrumbs */
.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 30px;
    font-size: 0.9rem;
    color: #666;
}

.breadcrumbs a {
    color: #888;
    text-decoration: none;
    transition: var(--transition);
}

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

.breadcrumbs span.separator {
    color: #ccc;
    font-size: 10px;
}

/* Floating WhatsApp Widget */
.floating-whatsapp {
    position: fixed;
    bottom: 30px;
    left: 30px;
    background: #25D366;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px rgba(37, 211, 102, 0.4);
    z-index: 2000;
    transition: var(--transition);
    text-decoration: none;
}

.floating-whatsapp:hover {
    transform: scale(1.1) rotate(10deg);
    background: #128C7E;
}

.floating-whatsapp svg {
    width: 32px;
    height: 32px;
}

/* 404 Page Styling */
.error-page {
    min-height: 80vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 40px 20px;
}

.error-code {
    font-size: 8rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
    margin-bottom: 20px;
    opacity: 0.1;
}

.error-title {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.error-btn {
    margin-top: 30px;
    background: var(--primary-color);
    color: white;
    padding: 15px 40px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    transition: var(--transition);
}

.error-btn:hover {
    background: var(--primary-light);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 108, 53, 0.2);
}

/* Skeleton Loader Animation */
@keyframes shimmer {
    0% {
        background-position: -468px 0;
    }

    100% {
        background-position: 468px 0;
    }
}

.skeleton {
    background: #f6f7f8;
    background-image: linear-gradient(to right, #f6f7f8 0%, #edeef1 20%, #f6f7f8 40%, #f6f7f8 100%);
    background-repeat: no-repeat;
    background-size: 800px 100%;
    display: inline-block;
    position: relative;
    animation: shimmer 1s linear infinite forwards;
}

/* FAQ Section */
.product-faq {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid #eee;
}

.faq-title {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 30px;
    text-align: center;
}

.faq-item {
    background: white;
    border: 1px solid #eee;
    border-radius: 12px;
    margin-bottom: 15px;
    overflow: hidden;
    transition: var(--transition);
}

.faq-item:hover {
    border-color: var(--accent-color);
    box-shadow: var(--shadow-sm);
}

.faq-item summary {
    padding: 20px 25px;
    cursor: pointer;
    font-weight: 700;
    color: var(--text-color);
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    outline: none;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: '⊕';
    font-size: 1.2rem;
    color: var(--primary-color);
    transition: var(--transition);
}

.faq-item[open] summary::after {
    content: '⊖';
}

.faq-content {
    padding: 0 25px 20px;
    color: #666;
    line-height: 1.8;
}

/* Policy Buttons */
.policy-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: 30px;
}

.policy-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px;
    border-radius: 10px;
    background: #f8f9fa;
    color: var(--text-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    border: 1px solid #eee;
    transition: var(--transition);
}

.policy-btn:hover {
    background: white;
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.policy-btn svg {
    color: var(--accent-color);
}

@media (max-width: 768px) {
    .policy-buttons {
        grid-template-columns: 1fr;
    }
}