/**
 * Main Stylesheet - Luxury Patisserie Store
 * تصميم فاخر واحترافي للمتجر
 */

/* ============================================
   VARIABLES & RESET
   ============================================ */

:root {
    --primary-color: #d4a373;
    --primary-dark: #b8884d;
    --secondary-color: #2c2c2c;
    --text-color: #333;
    --text-light: #666;
    --border-color: #e5e5e5;
    --bg-light: #f9f9f9;
    --white: #ffffff;
    --success: #28a745;
    --danger: #dc3545;
    --warning: #ffc107;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-lg: 0 5px 25px rgba(0,0,0,0.15);
    --transition: all 0.3s ease;
    --border-radius: 8px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', 'Tajawal', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

body.ar {
    font-family: 'Tajawal', 'Poppins', sans-serif;
    direction: rtl;
    text-align: right;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', 'Tajawal', serif;
    font-weight: 600;
    line-height: 1.3;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section-padding {
    padding: 80px 0;
}

.bg-light {
    background-color: var(--bg-light);
}

/* ============================================
   TOP BAR
   ============================================ */

.top-bar {
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 10px 0;
    font-size: 14px;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.contact-info a {
    color: var(--white);
    margin-right: 20px;
}

.ar .contact-info a {
    margin-right: 0;
    margin-left: 20px;
}

.contact-info i {
    margin-right: 5px;
}

.ar .contact-info i {
    margin-right: 0;
    margin-left: 5px;
}

.top-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.language-switcher a {
    color: var(--white);
    opacity: 0.8;
    font-size: 13px;
}

.language-switcher a.active {
    opacity: 1;
    font-weight: 600;
}

.social-media a {
    color: var(--white);
    margin-left: 10px;
    opacity: 0.8;
    transition: var(--transition);
}

.ar .social-media a {
    margin-left: 0;
    margin-right: 10px;
}

.social-media a:hover {
    opacity: 1;
    color: var(--primary-color);
}

/* ============================================
   MAIN HEADER
   ============================================ */

.main-header {
    background-color: var(--white);
    box-shadow: var(--shadow);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.logo h1 {
    color: var(--primary-color);
    font-size: 28px;
    margin: 0;
}

.search-bar {
    flex: 1;
    max-width: 500px;
}

.search-bar form {
    display: flex;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.search-bar input {
    flex: 1;
    border: none;
    padding: 12px 15px;
    font-size: 14px;
}

.search-bar button {
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 12px 20px;
    cursor: pointer;
    transition: var(--transition);
}

.search-bar button:hover {
    background-color: var(--primary-dark);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.account-link, .cart-link {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    transition: var(--transition);
}

.account-link:hover, .cart-link:hover {
    color: var(--primary-color);
}

.cart-link {
    position: relative;
}

.cart-count {
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 600;
}

.mobile-menu-toggle {
    display: none;
    font-size: 24px;
    cursor: pointer;
}

/* ============================================
   NAVIGATION
   ============================================ */

.main-nav {
    background-color: var(--secondary-color);
    color: var(--white);
}

.nav-menu {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.nav-menu li {
    position: relative;
}

.nav-menu > li > a {
    color: var(--white);
    padding: 15px 20px;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: var(--transition);
}

.nav-menu > li > a:hover {
    background-color: var(--primary-color);
}

.nav-menu i {
    font-size: 14px;
}

/* Dropdown Menu */
.has-dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--white);
    min-width: 200px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    z-index: 100;
}

.ar .dropdown-menu {
    left: auto;
    right: 0;
}

.has-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li a {
    color: var(--text-color);
    padding: 12px 20px;
    display: block;
    transition: var(--transition);
}

.dropdown-menu li a:hover {
    background-color: var(--bg-light);
    color: var(--primary-color);
    padding-left: 25px;
}

.ar .dropdown-menu li a:hover {
    padding-left: 20px;
    padding-right: 25px;
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -300px;
    width: 300px;
    height: 100vh;
    background-color: var(--white);
    box-shadow: var(--shadow-lg);
    z-index: 10000;
    transition: var(--transition);
    overflow-y: auto;
}

.ar .mobile-menu {
    right: auto;
    left: -300px;
}

.mobile-menu.active {
    right: 0;
}

.ar .mobile-menu.active {
    right: auto;
    left: 0;
}

.mobile-menu-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.close-mobile-menu {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
}

.mobile-nav-menu li a {
    padding: 15px 20px;
    display: block;
    color: var(--text-color);
    border-bottom: 1px solid var(--border-color);
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: rgba(0,0,0,0.5);
    opacity: 0;
    visibility: hidden;
    z-index: 9999;
    transition: var(--transition);
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ============================================
   FLASH MESSAGES
   ============================================ */

.flash-message {
    padding: 15px 0;
    margin-bottom: 20px;
}

.flash-message.success {
    background-color: #d4edda;
    color: #155724;
}

.flash-message.error {
    background-color: #f8d7da;
    color: #721c24;
}

.flash-message .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.close-flash {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    opacity: 0.5;
}

.close-flash:hover {
    opacity: 1;
}

/* ============================================
   HERO SLIDER
   ============================================ */

.hero-slider {
    position: relative;
    height: 600px;
    overflow: hidden;
}

.slider-container {
    position: relative;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease;
}

.slide.active {
    opacity: 1;
}

.slide-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0,0,0,0.7), rgba(212,163,115,0.3));
}

.slide-content {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    max-width: 600px;
}

.slide-title {
    font-size: 48px;
    color: var(--white);
    margin-bottom: 20px;
    animation: slideInLeft 1s ease;
}

.slide-subtitle {
    font-size: 20px;
    color: var(--white);
    margin-bottom: 30px;
    animation: slideInLeft 1s ease 0.2s backwards;
}

.slider-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(255,255,255,0.2);
    border: none;
    color: var(--white);
    font-size: 24px;
    padding: 15px 20px;
    cursor: pointer;
    transition: var(--transition);
    z-index: 3;
}

.slider-control:hover {
    background-color: var(--primary-color);
}

.slider-control.prev {
    left: 20px;
}

.slider-control.next {
    right: 20px;
}

.slider-dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 3;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: var(--transition);
}

.dot.active {
    background-color: var(--primary-color);
    width: 30px;
    border-radius: 6px;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ============================================
   SECTIONS
   ============================================ */

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 36px;
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.section-header p {
    color: var(--text-light);
    font-size: 16px;
}

.section-footer {
    text-align: center;
    margin-top: 50px;
}

/* ============================================
   BUTTONS
   ============================================ */

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: var(--border-radius);
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-outline {
    background-color: transparent;
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

.btn-light {
    background-color: var(--white);
    color: var(--text-color);
}

.btn-success {
    background-color: var(--success);
    color: var(--white);
}

.btn-danger {
    background-color: var(--danger);
    color: var(--white);
}

.btn-large {
    padding: 15px 40px;
    font-size: 16px;
}

.btn-small {
    padding: 8px 20px;
    font-size: 13px;
}

.btn-block {
    display: block;
    width: 100%;
}

.btn-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--white);
    color: var(--primary-color);
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.btn-icon:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* ============================================
   CATEGORIES
   ============================================ */

.categories-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.category-card {
    position: relative;
    height: 300px;
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: var(--transition);
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.category-image {
    height: 100%;
    position: relative;
}

.category-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, transparent, rgba(0,0,0,0.7));
}

.category-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 30px;
    color: var(--white);
    z-index: 2;
}

.category-content h3 {
    font-size: 24px;
    margin-bottom: 10px;
}

.category-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--primary-color);
    font-weight: 500;
}

/* ============================================
   PRODUCTS
   ============================================ */

.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.product-card {
    background-color: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.product-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
}

.product-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    color: var(--white);
    z-index: 2;
}

.ar .badge {
    right: auto;
    left: 10px;
}

.badge-sale {
    background-color: var(--danger);
}

.badge-featured {
    background-color: var(--primary-color);
    top: 45px;
}

.badge-bestseller {
    background-color: var(--success);
}

.product-actions {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    gap: 10px;
    opacity: 0;
    transition: var(--transition);
}

.product-card:hover .product-actions {
    opacity: 1;
}

.product-info {
    padding: 20px;
}

.product-category {
    font-size: 12px;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.product-title {
    font-size: 16px;
    margin: 10px 0;
    min-height: 50px;
}

.product-title a:hover {
    color: var(--primary-color);
}

.product-price {
    display: flex;
    align-items: center;
    gap: 10px;
}

.price {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary-color);
}

.old-price {
    font-size: 16px;
    color: var(--text-light);
    text-decoration: line-through;
}

/* ============================================
   FEATURES
   ============================================ */

.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.feature-card {
    text-align: center;
    padding: 40px 20px;
    background-color: var(--white);
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.feature-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--bg-light);
    border-radius: 50%;
    color: var(--primary-color);
    font-size: 32px;
}

.feature-card h3 {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.feature-card p {
    color: var(--text-light);
    font-size: 14px;
}

/* ============================================
   TESTIMONIALS
   ============================================ */

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.testimonial-card {
    background-color: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.testimonial-rating {
    color: #ffc107;
    margin-bottom: 15px;
}

.testimonial-text {
    font-style: italic;
    color: var(--text-light);
    margin-bottom: 20px;
    line-height: 1.8;
}

.testimonial-author h4 {
    font-size: 16px;
    color: var(--secondary-color);
}

/* ============================================
   CTA SECTION
   ============================================ */

.cta-section {
    position: relative;
    background-image: url('../images/cta-bg.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    padding: 100px 0;
    text-align: center;
}

.cta-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(44, 44, 44, 0.85);
}

.cta-content {
    position: relative;
    z-index: 2;
}

.cta-content h2 {
    font-size: 40px;
    color: var(--white);
    margin-bottom: 20px;
}

.cta-content p {
    font-size: 18px;
    color: var(--white);
    margin-bottom: 30px;
    opacity: 0.9;
}

/* ============================================
   FOOTER
   ============================================ */

.main-footer {
    background-color: var(--secondary-color);
    color: var(--white);
}

.footer-top {
    padding: 60px 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
}

.footer-col h3 {
    font-size: 18px;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.footer-col p {
    color: rgba(255,255,255,0.8);
    line-height: 1.8;
}

.social-media-footer {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-media-footer a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.social-media-footer a:hover {
    background-color: var(--primary-color);
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255,255,255,0.8);
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.ar .footer-links a:hover {
    padding-left: 0;
    padding-right: 5px;
}

.footer-contact li {
    display: flex;
    align-items: start;
    gap: 10px;
    margin-bottom: 15px;
    color: rgba(255,255,255,0.8);
}

.footer-contact i {
    color: var(--primary-color);
    margin-top: 3px;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 20px 0;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.payment-methods {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255,255,255,0.8);
}

/* ============================================
   WHATSAPP & SCROLL BUTTONS
   ============================================ */

.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background-color: #25d366;
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    box-shadow: var(--shadow-lg);
    z-index: 999;
    animation: pulse 2s infinite;
}

.ar .whatsapp-float {
    right: auto;
    left: 30px;
}

.scroll-to-top {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
}

.ar .scroll-to-top {
    left: auto;
    right: 30px;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* Page Header */
.page-header {
    background-color: var(--bg-light);
    padding: 40px 0;
    text-align: center;
}

.page-header h1 {
    font-size: 36px;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.breadcrumb {
    display: flex;
    justify-content: center;
    gap: 10px;
    font-size: 14px;
    color: var(--text-light);
}

.breadcrumb a:hover {
    color: var(--primary-color);
}

/* Continue in next part... */
