/* Common Styles for All Pages */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Cairo', sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background: linear-gradient(135deg, #faf8f5 0%, #f5f0e8 25%, #ede6d8 50%, #f0e9dc 75%, #faf6f0 100%);
    background-attachment: fixed;
    overflow-x: hidden;
}

.navbar {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
}

.navbar-brand {
    color: var(--gold) !important;
    font-weight: 800;
}

.nav-link {
    color: var(--black) !important;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-link:hover, .nav-link.active {
    color: var(--gold) !important;
}

.gold-text {
    color: var(--gold);
    font-weight: 700;
}


/* User Menu Dropdown */
.user-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    min-width: 200px;
    display: none;
    z-index: 1000;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.user-menu.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.user-menu a {
    padding: 12px 20px;
    display: block;
    color: #333;
    text-decoration: none;
    transition: all 0.3s ease;
    border-radius: 8px;
}

.user-menu a:hover {
    background: #f8f9fa;
    color: #D4AF37;
}

/* Cart Icon Styling */
.cart-icon-container {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1000;
}

.cart-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #D4AF37 0%, #B8860B 100%);
    color: white;
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.5rem;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
    transition: all 0.3s ease;
    position: relative;
}

.cart-icon:hover {
    background: linear-gradient(135deg, #B8860B 0%, #9A7209 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.4);
    color: white;
    text-decoration: none;
}

.cart-icon .badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #dc3545;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Common Buttons */
.btn-primary {
    background: linear-gradient(135deg, #D4AF37 0%, #B8860B 100%);
    border: none;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #B8860B 0%, #9A7209 100%);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.4);
}

.btn-outline-primary {
    border-color: #D4AF37;
    color: #D4AF37;
}

.btn-outline-primary:hover {
    background-color: #D4AF37;
    border-color: #D4AF37;
}

/* Common Spacing */
.container {
    padding-left: 20px;
    padding-right: 20px;
    max-width: 1400px;
    margin: 0 auto;
}

.container-fluid {
    max-width: 100%;
    padding-left: 20px;
    padding-right: 20px;
}

section {
    padding: 80px 0;
}

section:first-of-type {
    padding-top: 100px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .cart-icon-container {
        top: 15px;
        left: 15px;
    }

    .cart-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }

    section:first-of-type {
        padding-top: 80px;
    }

    .container {
        padding-left: 15px;
        padding-right: 15px;
    }

    section {
        padding: 60px 0;
    }
}

/* RTL Border Radius Adjustments */
[dir="rtl"] .input-group>.form-control:not(:last-child) {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    border-top-right-radius: 8px;
    border-bottom-right-radius: 8px;
}

[dir="rtl"] .input-group>.input-group-text:last-child {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    border-top-left-radius: 8px;
    border-bottom-left-radius: 8px;
}

/* Form Controls Border Emphasis from Left */
.form-control:focus,
.form-select:focus {
    border-left-width: 3px !important;
    padding-left: calc(0.75rem - 1px);
}

/* Input Group RTL Specific */
[dir="rtl"] .input-group {
    flex-direction: row;
}

[dir="rtl"] .input-group .form-control {
    border-left: none;
}

[dir="rtl"] .input-group .input-group-text {
    border-right: none;
}

/* Accessibility - Visually Hidden */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

