:root {
    --primary-color: #f97316;
    /* Orange 500 */
    --primary-hover: #ea580c;
    /* Orange 600 */
    --secondary-color: #1e293b;
    /* Slate 800 */
    --text-dark: #0f172a;
    /* Slate 900 */
    --text-muted: #64748b;
    /* Slate 500 */
    --bg-light: #fff7ed;
    /* Orange 50 */
    --bg-card: #ffffff;
    --accent-color: #f97316;
    --success-color: #22c55e;
    --success-bg: #dcfce7;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 1. Global Reset & Box Sizing */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    overflow-x: hidden;
    /* Prevent horizontal scrolling */
    min-height: 100%;
}

body {
    font-family: 'theyearofhandicrafts', 'The Year of Handicrafts', 'alfont_com_TheYearofHandicrafts-SemiBold', 'TheYearofHandicrafts', 'Year of Handicrafts', 'alfont The Year of Handicrafts', 'Tajawal', system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
    font-size: clamp(14px, 1.2vw, 16px);
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* 2. Responsive Container */
.container {
    width: 100%;
    max-width: 1280px;
    /* Desktop max */
    margin: 0 auto;
    padding: 0 16px;
    /* Mobile Padding */
}

@media (min-width: 768px) {
    .container {
        padding: 0 24px;
    }

    /* Tablet */
}

@media (min-width: 1024px) {
    .container {
        padding: 0 32px;
    }

    /* Desktop */
}

/* 3. Responsive Typography */
h1,
h2,
h3,
h4 {
    line-height: 1.3;
    font-weight: 500;
    /* SemiBold as requested for normal headings */
}

h1 {
    font-size: clamp(24px, 4vw, 36px);
}

h2 {
    font-size: clamp(20px, 3vw, 28px);
}

h3 {
    font-size: clamp(18px, 2.5vw, 24px);
}

/* 4. Buttons (Fixed) */
button,
.btn {
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    /* Default: Fit content */
    min-width: 100px;
    min-height: 44px;
    /* Mobile touch target */
    padding: 10px 24px;
    border-radius: var(--radius);
    font-family: inherit;
    font-weight: 500;
    /* SemiBold for buttons */
    border: none;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.95rem;
    line-height: 1.2;
    white-space: nowrap;
    position: relative;
    z-index: 1;
    /* Ensure above overlays */
    touch-action: manipulation;
    /* Improved touch */
}

/* Mobile Checkout Button Exception (Optional) */
.btn-mobile-full {
    width: auto;
}

@media (max-width: 480px) {
    .btn-mobile-full {
        width: 100%;
    }
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 4px 6px rgba(249, 115, 22, 0.25);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(249, 115, 22, 0.3);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: white;
}

.btn-block {
    display: flex;
    width: 100%;
}

/* Mobile/iPhone Interactivity Fixes */
button,
.btn,
a {
    pointer-events: auto;
    touch-action: manipulation;
}

.overlay {
    pointer-events: none;
    /* Pass through clicks when transparent/hidden */
}

.overlay.active {
    pointer-events: auto;
    /* Block when active */
}

.product-image-container,
.product-card {
    position: relative;
    z-index: 1;
}

.product-image-container button {
    z-index: 10;
    /* Ensure buttons above image are clickable */
}

/* 5. Navbar Responsive */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 80px;
    background: rgba(255, 252, 247, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.nav-container {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo img {
    height: 40px;
    width: auto;
}

.nav-icons {
    display: flex;
    gap: 12px;
}

.nav-icons button,
.cart-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    color: var(--text-dark);
    font-size: 1.1rem;
    transition: var(--transition);
}

.nav-icons button:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ef4444;
    color: white;
    font-size: 11px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid white;
}

/* Hero Section */
.hero {
    margin-top: 80px;
    padding: 24px 0;
    background: transparent;
}

.hero-container-wrapper {
    max-width: 1200px !important;
    margin: 0 auto;
}

.hero-card {
    position: relative;
    width: 100%;
    height: clamp(200px, 28vw, 360px);
    background-color: #f7f1e9;
    /* Light neutral matching brand */
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-img-main {
    width: 100%;
    height: 100%;
    object-fit: contain;
    /* CRITICAL: No cropping */
    object-position: center;
    image-rendering: -webkit-optimize-contrast;
    transition: transform 0.5s ease;
}

.hero-img-main:hover {
    transform: scale(1.02);
}

/* Product Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    /* Mobile: 2 cols */
    gap: 16px;
    padding: 20px 0;
}

@media (min-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
        /* Tablet: 3 cols */
        gap: 24px;
    }
}

@media (min-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(4, 1fr);
        /* Desktop: 4 cols */
        gap: 32px;
    }
}

/* Product Card */
.product-card {
    background: white;
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid #f1f5f9;
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

/* Checkout Layout */
.checkout-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    padding-bottom: 100px;
}

@media (min-width: 1024px) {
    .checkout-layout {
        grid-template-columns: 1.8fr 1fr;
        /* Left content wider */
        gap: 40px;
        align-items: start;
    }

    .checkout-summary {
        position: sticky;
        top: 100px;
        background: white;
        padding: 24px;
        border-radius: var(--radius);
        box-shadow: var(--shadow-sm);
        border: 1px solid #f1f5f9;
        height: auto;
    }
}

.cart-item {
    background: white;
    border: 1px solid #f1f5f9;
    padding: 16px;
    border-radius: var(--radius);
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
    position: relative;
    transition: var(--transition);
}

.cart-item:hover {
    border-color: var(--primary-color);
}

.product-image-container {
    aspect-ratio: 4/5;
    /* Fixed Aspect Ratio */
    width: 100%;
    position: relative;
    background: #f8fafc;
}

.product-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

.product-title {
    font-size: 1rem;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-price {
    font-weight: 700;
    /* Bold for emphasis */
    color: var(--primary-color);
    margin-top: auto;
}

/* Product Detail Page Layout */
.product-detail-layout {
    display: grid;
    grid-template-columns: 1fr;
    /* Mobile: Single Column */
    gap: 24px;
    margin-top: 20px;
}

.product-gallery {
    width: 100%;
    position: relative;
    background: #f8fafc;
    border-radius: var(--radius);
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.product-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

@media (min-width: 900px) {
    .product-detail-layout {
        grid-template-columns: 1fr 1fr;
        /* Desktop: 2 Columns */
        align-items: start;
        gap: 40px;
    }

    .product-gallery {
        position: sticky;
        top: 100px;
        /* Sticky on scroll */
    }
}

/* --- Utilities & Badges --- */
.badge-delivery {
    background-color: var(--success-bg);
    color: var(--success-color);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 4px;
    display: inline-block;
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    box-shadow: var(--shadow-sm);
}

.badge-discount {
    background-color: #fee2e2;
    color: #ef4444;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 4px;
}

.old-price {
    text-decoration: line-through;
    color: #94a3b8;
    font-size: 0.85rem;
    margin-bottom: -2px;
}

.wishlist-btn {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: white;
    border: none;
    cursor: pointer;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    color: #94a3b8;
}

.wishlist-btn.active {
    color: #ef4444;
}

.wishlist-btn:hover {
    transform: scale(1.1);
}



/* Hero styles consolidated above */

/* Optional: If we need a button overlay later */
.hero-cta-overlay {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.hero-blob {
    display: none;
}

/* Section Headers - Clean Retail Look */
.section-header {
    text-align: center;
    margin: 60px 0 40px;
}

.section-title {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 10px;
    font-weight: 700;
    /* Bold for emphasis on section titles */
}

.section-subtitle {
    color: var(--accent-color);
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

/* AR Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.9);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.active {
    display: flex;
    opacity: 1;
}

.modal-content {
    background: white;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 20px;
    position: relative;
    animation: modalSlideUp 0.4s ease forwards;
}

.close-modal {
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 2rem;
    color: white;
    cursor: pointer;
    z-index: 10;
    background: rgba(0, 0, 0, 0.5);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ar-view {
    display: flex;
    flex-direction: column;
    height: 600px;
}

.camera-feed {
    flex: 1;
    background: #000;
    position: relative;
    overflow: hidden;
}

.camera-placeholder {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: rgba(255, 255, 255, 0.5);
    text-align: center;
}

.camera-placeholder i {
    font-size: 3rem;
    margin-bottom: 10px;
}

.ar-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
}

#ar-product-img {
    max-width: 60%;
    max-height: 60%;
    filter: drop-shadow(0 20px 30px rgba(0, 0, 0, 0.5));
    cursor: grab;
}

.ar-controls {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
}

.ar-info {
    padding: 20px;
    background: white;
    text-align: center;
    border-top: 1px solid #eee;
}

/* Cart Sidebar */
/* Cart Sidebar */
.cart-sidebar {
    position: fixed;
    top: 0;
    left: -400px;
    /* Hidden by default */
    width: 400px;
    height: 100%;
    background: white;
    z-index: 1500;
    box-shadow: 5px 0 30px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    visibility: hidden;
    /* Prevent peeking */
}

.cart-sidebar.active {
    left: 0;
    visibility: visible;
}

/* Hide count if empty (using JS to toggle class usually, but pure CSS if we used :empty) */
.cart-count:empty,
.cart-count[style*="display: none"] {
    display: none;
}

.cart-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-header h2 {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.close-cart {
    cursor: pointer;
    font-size: 1.5rem;
    color: #94a3b8;
    transition: var(--transition);
}

.close-cart:hover {
    color: var(--accent-color);
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.cart-item {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #f1f5f9;
}

.cart-item-img {
    width: 80px;
    height: 80px;
    border-radius: 10px;
    overflow: hidden;
}

.cart-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-details {
    flex: 1;
}

.cart-item-title {
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.cart-item-price {
    color: var(--accent-color);
    font-weight: 600;
}

.cart-item-remove {
    color: #ef4444;
    font-size: 0.9rem;
    cursor: pointer;
    margin-top: 5px;
    display: inline-block;
}

.cart-footer {
    padding: 20px;
    background: #f8fafc;
    border-top: 1px solid #eee;
}

.total {
    display: flex;
    justify-content: space-between;
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1400;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.overlay.active {
    display: block;
    opacity: 1;
}

/* Footer */
footer {
    background: white;
    color: var(--text-dark);
    padding: 80px 0 30px;
    border-top: 1px solid #f1f5f9;
}

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

.footer-col h3 {
    font-size: 1.5rem;
    margin-bottom: 25px;
    color: var(--text-dark);
    font-weight: 800;
}

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

.footer-col ul li a {
    color: var(--text-muted);
    transition: var(--transition);
    font-weight: 500;
}

.footer-col ul li a:hover {
    color: var(--primary-color);
    padding-right: 5px;
}

.social-links {
    display: flex;
    gap: 20px;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: #f1f5f9;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #f1f5f9;
    color: var(--text-muted);
}

/* Animations */
@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }

    100% {
        transform: translateY(0px);
    }
}

@keyframes modalSlideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

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

/* Toast Animations */
@keyframes slideInDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }

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

@keyframes fadeOutUp {
    from {
        transform: translateY(0);
        opacity: 1;
    }

    to {
        transform: translateY(-20px);
        opacity: 0;
    }
}

.toast {
    background: white;
    padding: 15px 20px;
    border-radius: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 15px;
    animation: slideInDown 0.4s ease forwards;
    pointer-events: auto;
    border: 1px solid #f1f5f9;
}

.toast.toast-success i {
    color: var(--success-color);
}

.toast.toast-error i {
    color: #ef4444;
}

.toast.toast-info i {
    color: var(--secondary-color);
}

.toast.hiding {
    animation: fadeOutUp 0.4s ease forwards;
}

/* Responsive */
@media (max-width: 768px) {
    .hero {
        flex-direction: column;
        height: auto;
        padding-bottom: 50px;
        text-align: center;
    }

    .hero-content {
        padding-right: 0;
        margin-bottom: 50px;
    }

    .hero-title {
        font-size: 3rem;
    }

    .nav-links {
        display: none;
    }

    .menu-btn {
        display: block;
    }

    .cart-sidebar {
        width: 100%;
        left: -100%;
    }
}

.user-avatar-img {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    object-fit: cover;
}

.logout-btn {
    color: #ef4444;
    cursor: pointer;
    font-size: 1.1rem;
    margin-right: 5px;
    transition: var(--transition);
}

/* =========================================
   New Features Styles
   ========================================= */

/* 1. Category Filters */
.filters-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 10px 25px;
    border-radius: 30px;
    border: 1px solid #e2e8f0;
    background: white;
    color: var(--text-dark);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
    font-size: 1rem;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.15);
}

/* 2. Hero Marquee (The "Tape") */
.hero-marquee {
    width: 100%;
    overflow: hidden;
    background: var(--bg-light);
    padding: 40px 0;
    position: relative;
    margin-top: -50px;
    z-index: 1;
}

.marquee-content {
    display: flex;
    gap: 30px;
    animation: scroll 40s linear infinite;
    width: max-content;
}

.marquee-item {
    width: 200px;
    height: 250px;
    border-radius: 15px;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
    box-shadow: var(--shadow-md);
    transition: transform 0.3s ease;
    cursor: pointer;
}

.marquee-item:hover {
    transform: scale(1.05);
}

.marquee-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.marquee-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 15px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: white;
}

.marquee-overlay h4 {
    font-size: 0.9rem;
    font-weight: 600;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Pause animation on hover */
.marquee-content:hover {
    animation-play-state: paused;
}


.logout-btn:hover {
    transform: scale(1.1);
}

/* Product Modal Specifics */
.product-modal-content {
    max-width: 1000px;
    width: 95%;
    display: flex;
    flex-direction: column;
}

.product-details-container {
    display: flex;
    flex-direction: column;
}

@media (min-width: 768px) {
    .product-details-container {
        flex-direction: row;
        height: 600px;
    }

    .product-details-image {
        flex: 1;
        height: 100%;
    }

    .product-details-info {
        flex: 1;
        overflow-y: auto;
    }
}

.product-details-image {
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.product-details-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.1));
}

.product-details-info {
    padding: 40px;
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.detail-header {
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
}

.detail-badge {
    background: var(--accent-color);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    display: inline-block;
    margin-bottom: 10px;
}

.detail-header h2 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.detail-price {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary-color);
}

.detail-description h3 {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.detail-description p {
    color: #64748b;
    line-height: 1.8;
}

.detail-specs {
    display: flex;
    gap: 20px;
    background: #f8fafc;
    padding: 15px;
    border-radius: 10px;
}

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

.spec-item i {
    color: var(--accent-color);
}

.detail-actions {
    margin-top: auto;
    display: flex;
    gap: 15px;
    align-items: center;
}

.quantity-selector {
    display: flex;
    align-items: center;
    border: 1px solid #e2e8f0;
    border-radius: 50px;
    padding: 5px;
}

.quantity-selector button {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    border: none;
    background: #f1f5f9;
    cursor: pointer;
    font-weight: bold;
    color: var(--primary-color);
    transition: var(--transition);
}

.quantity-selector button:hover {
    background: #e2e8f0;
}

.quantity-selector span {
    width: 40px;
    text-align: center;
    font-weight: bold;
}

/* Login Modal */
.login-modal-content {
    max-width: 450px;
    padding: 40px;
}

.login-container {
    text-align: center;
}

.login-header {
    margin-bottom: 30px;
}

.login-header h2 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.login-header p {
    color: #64748b;
    font-size: 0.9rem;
}

.google-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: white;
    border: 1px solid #e2e8f0;
    padding: 12px;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
    font-weight: 600;
    color: #334155;
}

.google-btn:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
}

.phone-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: white;
    border: 1px solid #e2e8f0;
    padding: 12px;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
    font-weight: 600;
    color: #334155;
    margin-top: 10px;
}

.phone-btn:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: var(--primary-color);
}

.phone-btn i {
    font-size: 1.1rem;
    color: var(--primary-color);
}

/* Payment Modal */
.payment-modal-content {
    max-width: 500px;
    padding: 30px;
}

.payment-header {
    text-align: center;
    margin-bottom: 30px;
}

.payment-header h2 {
    color: var(--primary-color);
    margin-bottom: 5px;
}

.payment-methods {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.payment-method {
    flex: 1;
    border: 2px solid #e2e8f0;
    border-radius: 15px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    color: #64748b;
}

.payment-method.active {
    border-color: var(--accent-color);
    color: var(--accent-color);
    background: #f0fdf4;
}

.payment-method i {
    font-size: 1.5rem;
    display: block;
    margin-bottom: 5px;
}

.form-row {
    display: flex;
    gap: 15px;
}

.form-row .form-group {
    flex: 1;
}

.payment-summary {
    background: #f8fafc;
    padding: 15px;
    border-radius: 10px;
    margin: 20px 0;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    font-weight: bold;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.google-btn img {
    width: 20px;
    height: 20px;
}

/* Profile Styles */
.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 40px;
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
}

.profile-avatar-large {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--accent-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: bold;
    overflow: hidden;
}

.profile-avatar-large img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-info-text h2 {
    color: var(--primary-color);
    margin-bottom: 5px;
}

.profile-info-text p {
    color: #64748b;
}

.profile-tabs {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 10px;
}

.tab-btn {
    background: none;
    border: none;
    padding: 10px 20px;
    font-size: 1rem;
    font-weight: 600;
    color: #94a3b8;
    cursor: pointer;
    position: relative;
    font-family: inherit;
}

.tab-btn.active {
    color: var(--primary-color);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -11px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--accent-color);
}

.profile-tab-content {
    display: none;
}

.profile-tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

.orders-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.order-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: var(--shadow-sm);
    border: 1px solid #f1f5f9;
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #f1f5f9;
}

.order-id {
    font-weight: 700;
    color: var(--primary-color);
}

.order-date {
    font-size: 0.9rem;
    color: #94a3b8;
}

.order-status {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.status-pending {
    background: #fff7ed;
    color: #c2410c;
}

.status-processing {
    background: #eff6ff;
    color: #1d4ed8;
}

.status-completed {
    background: #f0fdf4;
    color: #15803d;
}

.order-items-preview {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    overflow-x: auto;
    padding-bottom: 5px;
}

.order-item-thumb {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    border: 1px solid #eee;
}

.order-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.order-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 700;
    color: var(--primary-color);
}

.empty-state {
    text-align: center;
    padding: 50px;
    color: #cbd5e1;
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 15px;
}

.settings-card {
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
    max-width: 600px;
}

.divider {
    margin: 25px 0;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.divider::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 1px;
    background: #e2e8f0;
    z-index: 1;
}

.divider span {
    background: white;
    padding: 0 15px;
    color: #94a3b8;
    font-size: 0.9rem;
    z-index: 2;
}

.form-group {
    margin-bottom: 20px;
    text-align: right;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--primary-color);
    font-weight: 500;
    font-size: 0.9rem;
}

.form-input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-family: inherit;
    transition: var(--transition);
}

.form-input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.1);
}

/* User Profile in Nav */
.user-profile {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.user-avatar {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: var(--accent-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.user-name {
    font-weight: 600;
    color: var(--primary-color);
    display: none;
}

@media (min-width: 768px) {
    .user-name {
        display: block;
    }
}

@media (min-width: 768px) {

    /* Order Tracker Styles */
    .order-tracker {
        display: flex;
        justify-content: space-between;
        margin: 30px 0;
        position: relative;
        overflow-x: auto;
        /* Handle small screens */
        padding-bottom: 20px;
    }

    .tracker-step {
        flex: 1;
        text-align: center;
        position: relative;
        z-index: 2;
        min-width: 80px;
    }

    .tracker-step::before {
        content: '';
        position: absolute;
        top: 15px;
        right: -50%;
        width: 100%;
        height: 3px;
        background: #e2e8f0;
        z-index: -1;
    }

    .tracker-step:last-child::before {
        display: none;
    }

    .step-icon {
        width: 35px;
        height: 35px;
        background: white;
        border: 2px solid #e2e8f0;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0 auto 10px;
        color: #94a3b8;
        transition: all 0.3s;
    }

    .step-label {
        font-size: 0.8rem;
        color: #94a3b8;
        font-weight: 600;
    }

    /* Active State */
    .tracker-step.active .step-icon {
        background: var(--primary-color);
        border-color: var(--primary-color);
        color: white;
        box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.2);
    }

    .tracker-step.active .step-label {
        color: var(--primary-color);
    }

    .tracker-step.completed .step-icon {
        background: var(--success-color);
        border-color: var(--success-color);
        color: white;
    }

    .tracker-step.completed::before {
        background: var(--success-color);
    }

    /* Timeline Styles */
    .order-timeline {
        margin-top: 30px;
        border-top: 1px solid #f1f5f9;
        padding-top: 20px;
    }

    .timeline-item {
        display: flex;
        gap: 15px;
        margin-bottom: 20px;
        position: relative;
    }

    .timeline-item::after {
        content: '';
        position: absolute;
        top: 25px;
        right: 7px;
        width: 2px;
        height: calc(100% + 10px);
        background: #f1f5f9;
        z-index: 1;
    }

    .timeline-item:last-child::after {
        display: none;
    }

    .timeline-dot {
        width: 16px;
        height: 16px;
        background: var(--primary-color);
        border-radius: 50%;
        margin-top: 5px;
        flex-shrink: 0;
        z-index: 2;
        border: 3px solid white;
        box-shadow: 0 0 0 2px #e2e8f0;
    }

    .timeline-content h4 {
        margin: 0 0 5px;
        font-size: 0.95rem;
    }

    .timeline-date {
        font-size: 0.8rem;
        color: #94a3b8;
    }
}