/* ==========================================
   العامر - Alamer | Premium Design System
   ========================================== */

/* Variables & Design Tokens */
:root {
    --bg-main: #0b0b0d;
    --bg-surface: #121216;
    --bg-surface-hover: #1b1b22;
    --bg-glass: rgba(18, 18, 22, 0.75);
    
    --color-gold: #d4af37;
    --color-gold-hover: #e5c158;
    --color-gold-glow: rgba(212, 175, 55, 0.35);
    --color-gold-muted: rgba(212, 175, 55, 0.15);
    --color-gold-text: #f5d77f;
    
    --text-primary: #ffffff;
    --text-secondary: #a0a0ab;
    --text-muted: #6f6f78;
    
    --border-light: rgba(255, 255, 255, 0.06);
    --border-gold: rgba(212, 175, 55, 0.18);
    --border-gold-focus: rgba(212, 175, 55, 0.5);
    
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.8);
    --shadow-gold: 0 0 20px rgba(212, 175, 55, 0.15);
    
    --font-family: 'Tajawal', sans-serif;
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;
    
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: var(--font-family);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-fast);
}

button, input, select, textarea {
    font-family: inherit;
    font-size: inherit;
    color: inherit;
    background: none;
    border: none;
    outline: none;
}

/* Helper Utilities */
.limit-width {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.gold-text {
    color: var(--color-gold-text);
}

.gold-gradient {
    background: linear-gradient(135deg, #f5d77f 0%, #d4af37 50%, #aa7c11 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-main);
}

::-webkit-scrollbar-thumb {
    background: #2a2a35;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-gold);
}

/* Custom Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: var(--border-radius-md);
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.btn-primary {
    background: linear-gradient(135deg, #d4af37 0%, #b38f1d 100%);
    color: #000000;
    box-shadow: var(--shadow-gold);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px var(--color-gold-glow);
    background: linear-gradient(135deg, #e5c158 0%, #d4af37 100%);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--color-gold);
    color: var(--color-gold-text);
    transform: translateY(-2px);
}

/* ==========================================
   1. Header & Dynamic Navbar
   ========================================.navbar-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(9, 10, 15, 0.95); /* Deep dark luxury background */
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-light);
    transition: var(--transition-smooth);
}

.navbar-container.nav-hidden {
    transform: translateY(-100%);
    box-shadow: none;
}

.navbar-wrapper {
    display: flex;
    flex-direction: column;
    padding: 12px 24px;
    transition: var(--transition-smooth);
}

/* Row 1: Top Header Row */
.nav-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* Logo (placed on the right in RTL) */
.logo-wrapper {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.site-logo-img {
    height: 44px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.4));
    transition: var(--transition-fast);
}

.site-logo-img:hover {
    transform: scale(1.04);
}

.logo {
    display: inline-flex;
    align-items: center;
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.logo-gold {
    background: linear-gradient(135deg, #ffeaa7 0%, #d4af37 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo-divider {
    color: #3a3a4a;
    margin: 0 12px;
    font-weight: 300;
}

.logo-latin {
    font-size: 1.35rem;
    font-weight: 500;
    color: var(--text-primary);
}

/* Wide Search Container in Middle */
.search-container {
    position: relative;
    width: 45%; /* Grohe Style: wide search input */
    max-width: 550px;
    display: flex;
    align-items: center;
    transition: var(--transition-smooth);
}

.search-container input {
    width: 100%;
    padding: 10px 16px 10px 42px; /* Padding-left is large to leave space for the search icon on the left */
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 6px; /* Grohe Style: slightly squared edges */
    font-size: 0.9rem;
    color: var(--text-primary);
    transition: var(--transition-smooth);
}

.search-container input::placeholder {
    color: var(--text-muted);
}

.search-container input:focus {
    border-color: var(--color-gold);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 15px var(--color-gold-glow);
    width: 100%; /* Keeps it solid, no jumpy sizing on desktop */
}

/* Search icon on the left (RTL end / LTR start) */
.search-container .search-icon {
    position: absolute;
    left: 14px;
    width: 18px;
    height: 18px;
    color: var(--text-secondary);
    pointer-events: none;
    transition: var(--transition-fast);
}

.search-container input:focus + .search-icon {
    color: var(--color-gold-text);
}

/* Left Utilities Group */
.nav-utilities {
    display: flex;
    align-items: center;
    gap: 20px;
}

.utility-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-fast);
}

.utility-item:hover {
    color: var(--color-gold-text);
}

.utility-item i {
    width: 16px;
    height: 16px;
    color: var(--color-gold);
}

.cart-btn {
    position: relative;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-fast);
}

.cart-btn:hover {
    background: var(--color-gold-muted);
    border-color: var(--color-gold);
    color: var(--color-gold-text);
    transform: scale(1.05);
}

.cart-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--color-gold);
    color: #000;
    font-size: 0.72rem;
    font-weight: 900;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.5);
}

/* Row 2: Bottom Navigation Row */
.nav-bottom-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding-top: 10px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
    margin-left: auto; /* Aligns category links to the right (RTL logo side) */
}

.nav-links a {
    font-weight: 700;
    font-size: 0.92rem;
    color: var(--text-secondary);
    position: relative;
    padding: 6px 0;
    transition: var(--transition-fast);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--color-gold-text);
}

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

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

.menu-mobile-btn {
    display: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-fast);
}

.menu-mobile-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--color-gold-text);
}

/* ==========================================
   2. Luxury Hero Section
   ========================================== */
.hero-section {
    position: relative;
    padding-top: 180px;
    padding-bottom: 80px;
    min-height: 90vh;
    display: flex;
    align-items: center;
    background-image: url('hero-bg.jpg');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(11, 11, 13, 0.95) 0%, rgba(11, 11, 13, 0.75) 50%, rgba(11, 11, 13, 0.45) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
    max-width: 750px;
}

.hero-badge {
    background: var(--color-gold-muted);
    border: 1px solid var(--border-gold);
    color: var(--color-gold-text);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1.25;
}

.hero-content p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    gap: 16px;
    margin-top: 10px;
    width: 100%;
}

.quick-info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 50px;
    width: 100%;
}

.info-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-md);
    padding: 20px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    transition: var(--transition-smooth);
}

.info-card:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--border-gold);
    transform: translateY(-4px);
    box-shadow: var(--shadow-gold);
}

.info-card i {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
}

.info-card h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.info-card p, 
.info-card .map-link {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.info-card .map-link:hover {
    color: var(--color-gold-text);
    text-decoration: underline;
}

/* ==========================================
   3. Shop & Filters Section
   ========================================== */
.shop-container {
    padding-top: 80px;
    padding-bottom: 80px;
}

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

.section-header h2 {
    font-size: 2.25rem;
    font-weight: 900;
    margin-bottom: 8px;
}

.section-header p {
    color: var(--text-secondary);
}

.categories-filter-container {
    margin-top: 30px;
    display: flex;
    justify-content: center;
    width: 100%;
}

.categories-pills {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 6px;
    max-width: 100%;
    scrollbar-width: none; /* Firefox */
}

.categories-pills::-webkit-scrollbar {
    display: none; /* Safari and Chrome */
}

.pill {
    padding: 10px 24px;
    border-radius: 50px;
    background: var(--bg-surface);
    border: 1px solid var(--border-light);
    color: var(--text-secondary);
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.pill:hover {
    background: var(--bg-surface-hover);
    border-color: var(--color-gold);
    color: var(--text-primary);
}

.pill.active {
    background: linear-gradient(135deg, #d4af37 0%, #aa7c11 100%);
    color: #000000;
    border-color: var(--color-gold);
    box-shadow: var(--shadow-gold);
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    min-height: 400px;
}

/* Loading state */
.loading-state {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    color: var(--text-secondary);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.05);
    border-top-color: var(--color-gold);
    border-radius: 50%;
    animation: spin 1s infinite linear;
}

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

/* ==========================================
   4. Product Card Component
   ========================================== */
.product-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: var(--transition-smooth);
    content-visibility: auto;
    contain-intrinsic-size: 1px 360px;
}

.product-card:hover {
    transform: translateY(-8px);
    border-color: var(--border-gold);
    box-shadow: var(--shadow-lg), var(--shadow-gold);
    will-change: transform;
}

.product-img-wrapper {
    position: relative;
    width: 100%;
    height: 260px;
    background: linear-gradient(180deg, #181820 0%, #121216 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-bottom: 1px solid var(--border-light);
}

.product-img {
    max-width: 80%;
    max-height: 80%;
    object-fit: contain;
    transition: var(--transition-smooth);
}

.product-card:hover .product-img {
    transform: scale(1.08) rotate(2deg);
}

.product-img-file {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    transition: var(--transition-smooth);
}

.product-card:hover .product-img-file {
    transform: scale(1.06);
}

.product-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid var(--border-gold);
    color: var(--color-gold-text);
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    backdrop-filter: blur(4px);
}

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

.product-cat {
    font-size: 0.8rem;
    color: var(--color-gold);
    font-weight: 700;
    text-transform: uppercase;
}

.product-title {
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.4;
    color: var(--text-primary);
    min-height: 50px;
}

.product-price-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid var(--border-light);
}

.price {
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--color-gold-text);
}

.currency {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-right: 4px;
}

.add-to-cart-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--bg-surface-hover);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.add-to-cart-btn:hover {
    background: var(--color-gold);
    border-color: var(--color-gold);
    color: #000;
    box-shadow: 0 0 15px var(--color-gold-glow);
    transform: scale(1.1);
}

/* ==========================================
   5. Cart Sidebar Component
   ========================================== */
.cart-sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    z-index: 1100;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition-smooth);
}

.cart-sidebar-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.cart-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    max-width: 450px;
    height: 100%;
    background: var(--bg-surface);
    border-left: 1px solid var(--border-light);
    z-index: 1200;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: var(--transition-smooth);
}

.cart-sidebar.active {
    transform: translateX(0);
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.6);
}

.cart-header {
    padding: 24px;
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.cart-header h2 {
    font-size: 1.5rem;
    font-weight: 900;
}

.close-cart-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-fast);
}

.close-cart-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--color-gold-text);
}

.cart-items-container {
    flex-grow: 1;
    overflow-y: auto;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.empty-cart-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    height: 100%;
    color: var(--text-secondary);
}

.empty-cart-state i {
    width: 64px;
    height: 64px;
    stroke-width: 1px;
    color: var(--text-muted);
}

/* Cart Item card */
.cart-item {
    display: flex;
    gap: 16px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-light);
}

.cart-item-img-wrapper {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cart-item-img-wrapper img {
    max-width: 80%;
    max-height: 80%;
    object-fit: contain;
}

.cart-item-details {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.cart-item-title {
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 4px;
}

.cart-item-price {
    font-size: 1.1rem;
    font-weight: 900;
    color: var(--color-gold-text);
}

.cart-item-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 8px;
}

.quantity-controls {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-light);
    border-radius: 50px;
    padding: 2px;
}

.qty-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-weight: bold;
    transition: var(--transition-fast);
}

.qty-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--color-gold);
}

.qty-num {
    padding: 0 12px;
    font-size: 0.9rem;
    font-weight: 700;
}

.remove-item-btn {
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition-fast);
}

.remove-item-btn:hover {
    color: #e84118;
}

.cart-footer {
    padding: 24px;
    border-top: 1px solid var(--border-light);
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.cart-summary-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.cart-summary-row.delivery {
    font-size: 0.85rem;
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 12px;
}

.cart-summary-row.total {
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--text-primary);
}

.checkout-btn {
    width: 100%;
    font-size: 1.1rem;
    padding: 16px;
}

/* ==========================================
   6. Checkout Modal Component
   ========================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(12px);
    z-index: 1300;
    opacity: 0;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    transition: var(--transition-smooth);
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.checkout-modal {
    background: var(--bg-surface);
    border: 1px solid var(--border-gold);
    border-radius: var(--border-radius-lg);
    width: 100%;
    max-width: 650px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg), 0 0 50px rgba(212, 175, 55, 0.1);
    transform: scale(0.9) translateY(20px);
    transition: var(--transition-smooth);
}

.modal-overlay.active .checkout-modal {
    transform: scale(1) translateY(0);
}

.modal-header {
    padding: 24px 30px;
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h2 {
    font-size: 1.5rem;
    font-weight: 900;
}

.close-modal-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-fast);
}

.close-modal-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--color-gold-text);
}

.checkout-form {
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.form-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-section h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--color-gold-text);
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 8px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 700;
}

.form-group label .required {
    color: #ff4d4d;
}

.form-group input,
.form-group select {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-md);
    padding: 14px 18px;
    color: var(--text-primary);
    transition: var(--transition-fast);
}

.form-group select option {
    background: var(--bg-surface);
    color: var(--text-primary);
}

.form-group input:focus,
.form-group select:focus {
    border-color: var(--color-gold);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.15);
    background: rgba(255, 255, 255, 0.02);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Payment selection styling */
.payment-options {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.payment-card {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-md);
    padding: 20px;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.payment-card:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--color-gold-muted);
}

.payment-card input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-light);
    border-radius: 50%;
    margin-top: 2px;
    outline: none;
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
    transition: var(--transition-fast);
}

.payment-card input[type="radio"]:checked {
    border-color: var(--color-gold);
}

.payment-card input[type="radio"]:checked::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    background: var(--color-gold);
    border-radius: 50%;
}

.payment-card.selected {
    border-color: var(--color-gold);
    background: rgba(212, 175, 55, 0.03);
}

.payment-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.payment-title {
    font-weight: 700;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.payment-title i {
    width: 20px;
    height: 20px;
    color: var(--color-gold-text);
}

.payment-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Order Summary */
.order-summary-box {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-md);
    padding: 20px;
}

.order-summary-box h4 {
    margin-bottom: 12px;
    font-weight: 700;
    font-size: 1rem;
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 8px;
}

.modal-summary-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.modal-order-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.15rem;
    font-weight: 900;
    border-top: 1px solid var(--border-light);
    padding-top: 12px;
    margin-top: 12px;
}

.submit-order-btn {
    width: 100%;
    padding: 16px;
    font-size: 1.15rem;
}

/* ==========================================
   7. Sticky Social Floating Action Buttons
   ========================================== */
.whatsapp-sticky-btn {
    position: fixed;
    bottom: 30px;
    left: 30px;
    z-index: 900;
    background: #25d366;
    color: #fff;
    padding: 14px 22px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    box-shadow: 0 8px 24px rgba(37, 211, 102, 0.4);
    transition: var(--transition-smooth);
}

.whatsapp-sticky-btn:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 12px 30px rgba(37, 211, 102, 0.6);
}

.whatsapp-sticky-btn i {
    width: 22px;
    height: 22px;
}

/* ==========================================
   8. Footer Component
   ========================================== */
.footer-container {
    background: #08080a;
    border-top: 1px solid var(--border-light);
    padding-top: 60px;
}

.footer-wrapper {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    padding-bottom: 50px;
}

.footer-brand h3 {
    font-size: 1.5rem;
    font-weight: 900;
    background: linear-gradient(135deg, #fff 0%, var(--color-gold) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 16px;
}

.footer-brand p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

.footer-links h4,
.footer-contact h4 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--color-gold-text);
    position: relative;
    padding-bottom: 8px;
}

.footer-links h4::after,
.footer-contact h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 35px;
    height: 2px;
    background: var(--color-gold);
}

.footer-links ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.footer-links a:hover {
    color: var(--color-gold-text);
    padding-right: 6px;
}

.footer-contact {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.footer-contact p {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.footer-contact i {
    width: 20px;
    height: 20px;
    color: var(--color-gold);
    flex-shrink: 0;
    margin-top: 2px;
}

.footer-contact a:hover {
    color: var(--color-gold-text);
    text-decoration: underline;
}

.footer-bottom {
    border-top: 1px solid var(--border-light);
    padding: 24px 0;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ==========================================
   Profile Modal Custom Styling
   ========================================== */
.profile-modal {
    background: var(--bg-surface);
    border: 1px solid var(--border-gold);
    border-radius: var(--border-radius-lg);
    width: 100%;
    max-width: 550px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg), 0 0 50px rgba(212, 175, 55, 0.1);
    transform: scale(0.9) translateY(20px);
    transition: var(--transition-smooth);
}

.modal-overlay.active .profile-modal {
    transform: scale(1) translateY(0);
}

.profile-modal-content {
    padding: 30px;
}

.profile-info-text {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.6;
}

.saved-profile-box {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-md);
    padding: 24px;
    margin-bottom: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    transition: var(--transition-smooth);
}

.profile-detail-row {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 1rem;
    color: var(--text-primary);
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    padding-bottom: 10px;
}

.profile-detail-row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.profile-detail-row i {
    width: 18px;
    height: 18px;
    color: var(--color-gold-text);
}

.profile-detail-row strong {
    font-weight: 500;
    color: var(--text-secondary);
    width: 100px;
    flex-shrink: 0;
}

.profile-detail-row span {
    font-weight: 700;
}

.no-profile-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 12px;
    color: var(--text-muted);
    padding: 10px 0;
}

.no-profile-state i {
    width: 48px;
    height: 48px;
    color: var(--text-muted);
    opacity: 0.5;
}

.profile-edit-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 10px;
}

/* ==========================================
   Luxury Success Modal Component
   ========================================== */
.success-modal {
    background: var(--bg-surface);
    border: 1px solid var(--border-gold);
    border-radius: var(--border-radius-lg);
    padding: 35px 25px;
    width: 90%;
    max-width: 460px;
    text-align: center;
    box-shadow: var(--shadow-lg), 0 0 50px rgba(37, 211, 102, 0.15);
    transform: scale(0.85);
    transition: var(--transition-smooth);
    position: relative;
}

.modal-overlay.active .success-modal {
    transform: scale(1);
}

.success-icon-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.success-icon-bg {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(37, 211, 102, 0.1);
    border: 2px solid #25d366;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(37, 211, 102, 0.3);
}

.success-icon-bg i {
    width: 36px;
    height: 36px;
    color: #25d366;
}

.success-modal h2 {
    font-size: 1.4rem;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.success-modal p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 20px;
}

.redirect-progress-bar {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 15px;
}

.redirect-progress-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #d4af37 0%, #25d366 100%);
    transition: width 1.4s linear;
}

/* ==========================================
   9. Media Queries (Responsive Styling)
   ========================================== */
@media (max-width: 992px) {
    html {
        font-size: 15px;
    }
    
    .hero-section {
        padding-top: 150px;
        min-height: auto;
    }
    
    .hero-content h1 {
        font-size: 2.8rem;
    }
    
    .quick-info-grid {
        grid-template-columns: 1fr;
        gap: 15px;
        margin-top: 40px;
    }
}

@media (max-width: 768px) {
    .navbar-wrapper {
        height: auto;
        padding: 10px 16px;
    }
    
    .nav-top-row {
        flex-wrap: wrap;
        gap: 8px;
        padding-bottom: 6px;
        border-bottom: none;
    }
    
    .logo {
        order: 1 !important; /* Logo on the RIGHT in RTL */
        font-size: 1.3rem !important;
    }
    
    .logo-latin,
    .logo-divider {
        display: inline-block !important;
    }
    
    .nav-utilities {
        order: 2 !important; /* Utilities on the LEFT in RTL */
        gap: 12px;
    }
    
    .utility-item span {
        display: none; /* Hide text, keep icons only for mobile utility items */
    }
    
    .search-container {
        order: 3; /* Full width search bar in second row */
        width: 100%;
        max-width: none;
        margin-top: 4px;
    }
    
    .search-container input:focus {
        width: 100%; /* Prevent stretching past mobile screen width */
    }
    
    .nav-bottom-row {
        padding-top: 0;
    }
    
    .menu-mobile-btn {
        display: flex; /* Mobile menu toggler is shown on mobile */
    }
    
    .nav-links {
        position: fixed;
        top: 114px; /* Shifted down to match mobile header height (row 1 + row 2) */
        right: -100%;
        width: 100%;
        height: calc(100vh - 114px);
        background: var(--bg-surface);
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        padding-top: 40px;
        gap: 24px;
        transition: var(--transition-smooth);
        border-top: 1px solid var(--border-light);
        margin: 0;
        z-index: 999;
        overflow-y: auto;
    }
    
    .nav-links.active {
        right: 0;
    }
    
@media (max-width: 850px) {
    .limit-width {
        padding: 0 12px !important;
    }

    .hero-section {
        padding-top: 135px !important;
        padding-bottom: 20px !important;
    }
    
    .hero-content h1 {
        font-size: 1.8rem !important;
        margin-bottom: 8px !important;
    }

    .hero-content p {
        font-size: 0.9rem !important;
        margin-bottom: 12px !important;
    }

    .hero-actions {
        flex-direction: row !important;
        gap: 8px !important;
    }

    .hero-actions .btn {
        padding: 10px 14px !important;
        font-size: 0.85rem !important;
        flex: 1;
        justify-content: center;
    }

    .quick-info-grid {
        display: none !important; /* Hide secondary info cards on mobile to bring products to top immediately */
    }

    .shop-container {
        padding-top: 15px !important;
    }

    /* Mobile 2-Column Amazon-Style Dense Grid */
    .products-grid {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 6px !important;
        min-height: auto !important;
    }
    
    .product-card {
        border-radius: 8px !important;
        contain-intrinsic-size: 1px 160px !important;
        background: var(--bg-surface) !important;
        border: 1px solid var(--border-light) !important;
    }

    .product-img-wrapper {
        height: 125px !important; /* Larger & clearer image container on mobile */
        padding: 4px !important;
    }

    .product-img-file, .product-img {
        max-height: 94% !important;
        max-width: 94% !important;
        object-fit: contain !important;
    }

    .product-badge {
        font-size: 0.55rem !important;
        padding: 1px 4px !important;
        top: 3px !important;
        right: 3px !important;
        border-radius: 3px !important;
    }

    .product-info {
        padding: 6px !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
    }

    .product-cat {
        font-size: 0.6rem !important;
        margin-bottom: 2px !important;
        color: var(--color-gold-text) !important;
    }

    .product-title {
        font-size: 0.72rem !important;
        line-height: 1.2 !important;
        min-height: 26px !important;
        margin-bottom: 2px !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
        color: var(--text-primary) !important;
    }

    .product-info p {
        display: none !important; /* Hide long paragraph on mobile */
    }

    .product-price-box {
        margin-top: 2px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
    }

    .product-price-box .price {
        font-size: 0.82rem !important;
        font-weight: 800 !important;
        color: var(--color-gold-text) !important;
    }

    .product-price-box .currency {
        font-size: 0.6rem !important;
    }

    .add-to-cart-btn {
        width: 26px !important;
        height: 26px !important;
        border-radius: 5px !important;
        padding: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }

    .add-to-cart-btn i {
        width: 14px !important;
        height: 14px !important;
    }
    /* Mobile Footer Optimization & Spacing */
    .footer-container {
        padding-top: 35px !important;
        padding-bottom: 80px !important; /* Clearance for floating green button */
    }

    .footer-wrapper {
        display: flex !important;
        flex-direction: column !important;
        gap: 20px !important;
        padding-bottom: 25px !important;
        text-align: right !important;
    }

    .footer-brand, .footer-links, .footer-contact {
        align-items: flex-start !important;
        text-align: right !important;
    }

    .footer-links h4, .footer-contact h4 {
        margin-bottom: 10px !important;
        font-size: 1rem !important;
    }

    .footer-bottom {
        padding: 16px 12px 40px 12px !important;
    }

    .whatsapp-sticky-btn {
        bottom: 16px !important;
        left: 14px !important;
        padding: 10px 16px !important;
        font-size: 0.85rem !important;
        z-index: 9999 !important;
    }

    .whatsapp-sticky-btn i {
        width: 18px !important;
        height: 18px !important;
    }
}

@media (max-width: 480px) {
    .navbar-wrapper {
        padding: 8px 10px !important;
    }

    .logo {
        font-size: 1.2rem !important;
    }

    .product-img-wrapper {
        height: 88px !important;
    }

    .product-title {
        font-size: 0.7rem !important;
    }
}
