/* ═══════════════════════════════════════════════════════════════
   ASPENDOS ONLINE ORDER — CSS Design System
   Bootstrap 5 + Dark/Light Theme + Custom Properties
   ═══════════════════════════════════════════════════════════════ */

/* ─── Theme Variables ─────────────────────────────────────────── */
[data-theme="dark"] {
    --bg-primary: #0d0d0d;
    --bg-secondary: #1a1a1a;
    --bg-card: #1e1e1e;
    --bg-card-hover: #2a2a2a;
    --bg-surface: #252525;
    --bg-overlay: rgba(0, 0, 0, 0.7);
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --text-muted: #6c757d;
    --border-color: #2d2d2d;
    --accent: #e53935;
    --accent-hover: #c62828;
    --accent-light: rgba(229, 57, 53, 0.15);
    --success: #43a047;
    --warning: #fb8c00;
    --shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.6);
}

[data-theme="light"] {
    --bg-primary: #f5f5f5;
    --bg-secondary: #ffffff;
    --bg-card: #ffffff;
    --bg-card-hover: #f8f8f8;
    --bg-surface: #fafafa;
    --bg-overlay: rgba(0, 0, 0, 0.5);
    --text-primary: #212121;
    --text-secondary: #616161;
    --text-muted: #9e9e9e;
    --border-color: #e0e0e0;
    --accent: #e53935;
    --accent-hover: #c62828;
    --accent-light: rgba(229, 57, 53, 0.1);
    --success: #43a047;
    --warning: #fb8c00;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* ─── Base ────────────────────────────────────────────────────── */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--accent-hover);
}

::selection {
    background: var(--accent);
    color: #fff;
}

/* ─── Accessibility & Focus Ring Fixes ───────────────────────── */
h1:focus, h2:focus, h3:focus, h4:focus, h5:focus, h6:focus,
[tabindex="-1"]:focus {
    outline: none !important;
    box-shadow: none !important;
}

/* ─── Premium Loading Screen ─────────────────────────────────── */
.loading-screen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: #0d0d0d;
    position: relative;
    overflow: hidden;
}

/* Floating fire particles */
.loading-particles {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.loading-particles span {
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: radial-gradient(circle, #e53935, #ff6f00);
    opacity: 0;
    animation: floatParticle 3s ease-in-out infinite;
}

.loading-particles span:nth-child(1) { left: 20%; animation-delay: 0s; }
.loading-particles span:nth-child(2) { left: 40%; animation-delay: 0.6s; }
.loading-particles span:nth-child(3) { left: 60%; animation-delay: 1.2s; }
.loading-particles span:nth-child(4) { left: 75%; animation-delay: 1.8s; }
.loading-particles span:nth-child(5) { left: 50%; animation-delay: 2.4s; }

@keyframes floatParticle {
    0%   { bottom: -10px; opacity: 0; transform: scale(0.5); }
    30%  { opacity: 0.8; }
    100% { bottom: 100%; opacity: 0; transform: scale(1.5) translateX(30px); }
}

/* Content container */
.loading-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
}

/* Kebab spinner */
.kebab-spinner {
    position: relative;
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.spinner-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 3px solid transparent;
    border-top-color: #e53935;
    border-right-color: #ff6f00;
    animation: spinRing 1.2s linear infinite;
}

.spinner-ring.ring-2 {
    inset: 8px;
    border-top-color: #ff8f00;
    border-right-color: #e53935;
    animation: spinRing 1.8s linear infinite reverse;
}

.spinner-icon {
    font-size: 2.5rem;
    animation: iconPulse 1.5s ease-in-out infinite;
    filter: drop-shadow(0 0 12px rgba(229, 57, 53, 0.5));
}

@keyframes spinRing {
    to { transform: rotate(360deg); }
}

@keyframes iconPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15) rotate(10deg); }
}

/* Brand text */
.loading-brand {
    font-family: 'Inter', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    background: linear-gradient(135deg, #e53935, #ff6f00, #ffab00);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: brandShimmer 2s ease-in-out infinite;
    background-size: 200% auto;
}

@keyframes brandShimmer {
    0%, 100% { background-position: 0% center; }
    50% { background-position: 100% center; }
}

.loading-tagline {
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    color: #6c757d;
    font-weight: 400;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-top: -0.5rem;
}

/* Progress bar */
.loading-bar-track {
    width: 140px;
    height: 3px;
    background: rgba(229, 57, 53, 0.15);
    border-radius: 4px;
    overflow: hidden;
    margin-top: 0.5rem;
}

.loading-bar-fill {
    width: 40%;
    height: 100%;
    background: linear-gradient(90deg, #e53935, #ff6f00, #ffab00);
    border-radius: 4px;
    animation: barSlide 1.5s ease-in-out infinite;
}

@keyframes barSlide {
    0%   { transform: translateX(-100%); }
    50%  { transform: translateX(150%); }
    100% { transform: translateX(350%); }
}

/* Loading text */
.loading-text {
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    color: #b0b0b0;
    font-weight: 400;
    animation: textFade 2s ease-in-out infinite;
}

@keyframes textFade {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 1; }
}

/* ─── In-Page Loading State ──────────────────────────────────── */
.page-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: var(--bg-primary);
}

.page-loader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

/* ─── Company Landing Page ────────────────────────────────────── */
.landing-page {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.landing-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.landing-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.55);
    z-index: 1;
}

.landing-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 2rem;
}

.landing-content-bottom {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    text-align: center;
    padding: 2rem;
    width: 100%;
    max-width: 600px;
}

/* ─── Branch Detail Page ──────────────────────────────────────── */
.branch-detail-page {
    background: var(--bg-primary);
    min-height: 100vh;
    padding-bottom: 5rem;
}

.branch-back-btn {
    position: absolute;
    top: 1rem;
    left: 1rem;
    z-index: 10;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    backdrop-filter: blur(4px);
    transition: all 0.3s ease;
}

.branch-back-btn:hover {
    background: var(--accent);
    color: #fff;
}

.branch-slider {
    position: relative;
    height: 350px;
    overflow: hidden;
}

.branch-slider .carousel,
.branch-slider .carousel-inner,
.branch-slider .carousel-item {
    height: 100%;
}

.branch-slider .carousel-item img {
    height: 350px;
    object-fit: cover;
}

.branch-slider-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--accent), #1a1a1a);
    color: rgba(255, 255, 255, 0.5);
}

.branch-detail-title {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
}

.btn-branch-action {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0.6rem 1.1rem;
    border-radius: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn-branch-action:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.btn-branch-action i {
    font-size: 1.1rem;
    color: var(--accent);
}

.btn-branch-action.btn-booking {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.btn-branch-action.btn-booking i {
    color: #fff;
}

.btn-branch-action.btn-booking:hover {
    background: var(--accent-hover);
    color: #fff;
}

.btn-branch-action.btn-rating {
    cursor: default;
}

.branch-detail-info {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1rem 1.25rem;
}

.branch-detail-info .info-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0.6rem 0;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.branch-detail-info .info-row:not(:last-child) {
    border-bottom: 1px solid var(--border-color);
}

.branch-detail-info .info-row i {
    font-size: 1rem;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.fixed-order-btn {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 0.75rem 0;
    background: var(--bg-primary);
    border-top: 1px solid var(--border-color);
    box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.3);
}

.landing-logo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 255, 255, 0.3);
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.landing-title {
    font-size: 3rem;
    font-weight: 800;
    color: #fff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

.landing-subtitle {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 2rem;
    font-weight: 300;
}

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    margin: 0 0.4rem;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
}

.social-icons a:hover {
    background: var(--accent);
    transform: translateY(-2px);
    color: #fff;
}

/* ─── Branch Selection Popup ──────────────────────────────────── */
.branch-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.25rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.branch-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.branch-card .branch-logo {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    object-fit: cover;
}

.branch-card .branch-name {
    font-weight: 600;
    font-size: 1rem;
}

.branch-card .branch-address {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.branch-card .branch-rating {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--warning);
}

/* ─── Branch Header / Banner ──────────────────────────────────── */
.branch-banner {
    position: relative;
    height: 280px;
    overflow: hidden;
    border-radius: 0 0 16px 16px;
}

.branch-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.branch-banner .banner-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
}

.branch-info-bar {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    font-size: 0.9rem;
    color: var(--text-secondary);
    padding: 1rem 0;
}

.branch-info-bar .info-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* ─── Order Type Toggle ───────────────────────────────────────── */
.order-type-toggle {
    display: flex;
    background: var(--bg-surface);
    border-radius: 12px;
    padding: 4px;
    border: 1px solid var(--border-color);
}

.order-type-toggle .toggle-btn {
    flex: 1;
    padding: 0.6rem 1rem;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.9rem;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.order-type-toggle .toggle-btn.active {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 2px 8px rgba(229, 57, 53, 0.3);
}

.order-type-toggle .toggle-btn small {
    font-size: 0.75rem;
    opacity: 0.8;
}

/* ─── Offers Bar ──────────────────────────────────────────────── */
.offers-bar {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding: 0.75rem 0;
    scrollbar-width: none;
}

.offers-bar::-webkit-scrollbar {
    display: none;
}

.offer-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0.5rem 1rem;
    background: var(--accent-light);
    border: 1px solid var(--accent);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent);
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s ease;
}

.offer-chip:hover {
    background: var(--accent);
    color: #fff;
}

/* ─── Category Bar Wrapper (with arrows) ─────────────────────── */
.category-bar-wrapper {
    display: flex;
    align-items: center;
    gap: 0;
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    overflow: hidden;
}

.cat-arrow {
    flex-shrink: 0;
    width: 36px;
    height: 42px;
    border: none;
    background: var(--bg-surface);
    color: var(--text-secondary);
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.cat-arrow:hover {
    background: var(--accent);
    color: #fff;
}

.cat-all-btn {
    flex-shrink: 0;
    width: 42px;
    height: 42px;
    border: none;
    border-left: 1px solid var(--border-color);
    background: var(--bg-surface);
    color: var(--text-secondary);
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.cat-all-btn:hover {
    background: var(--accent);
    color: #fff;
}

/* ─── Sticky Category Tabs ────────────────────────────────────── */
.category-tabs {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding: 0.5rem 0.5rem;
    scrollbar-width: none;
    flex: 1;
    cursor: grab;
}

.category-tabs::-webkit-scrollbar {
    display: none;
}

.category-tab {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    white-space: nowrap;
    cursor: pointer;
    background: var(--bg-surface);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.category-tab:hover,
.category-tab.active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

/* ─── Product Cards ───────────────────────────────────────────── */
.product-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    height: 100%;
}

.product-card:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}

.product-card .card-img-wrapper {
    position: relative;
    height: 160px;
    overflow: hidden;
    background: var(--bg-surface);
}

.product-card .card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .card-img-wrapper img {
    transform: scale(1.05);
}

.product-card .discount-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: var(--accent);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
}

.product-card .card-body {
    padding: 0.875rem;
}

.product-card .card-title {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
}

.product-card .card-text {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card .price-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 0.75rem;
}

.product-card .price {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 1rem;
}

.product-card .price-original {
    text-decoration: line-through;
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-left: 0.5rem;
}

.product-card .btn-add {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: none;
    background: var(--accent);
    color: #fff;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.product-card .btn-add:hover {
    background: var(--accent-hover);
    transform: scale(1.1);
}

/* ─── Category Section ────────────────────────────────────────── */
.category-section {
    margin-bottom: 2rem;
}

.category-section .category-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
}

.category-section .category-count {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

/* ─── Basket (Sidebar & Mobile) ───────────────────────────────── */
.basket-sidebar {
    position: sticky;
    top: 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.25rem;
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
}

.basket-sidebar .basket-title {
    font-weight: 700;
    font-size: 1.15rem;
    margin-bottom: 1rem;
}

.basket-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
}

.basket-item:last-child {
    border-bottom: none;
}

.basket-item .item-name {
    font-weight: 500;
    font-size: 0.9rem;
}

.basket-item .item-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.basket-item .item-price {
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
}

.basket-item .quantity-control {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 0.5rem;
}

.basket-item .quantity-control button {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--bg-surface);
    color: var(--text-primary);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.basket-item .quantity-control button:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.basket-summary {
    border-top: 2px solid var(--border-color);
    padding-top: 1rem;
    margin-top: 1rem;
}

.basket-summary .summary-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.basket-summary .summary-row.total {
    font-weight: 700;
    font-size: 1.1rem;
    margin-top: 0.5rem;
}

.min-order-warning {
    background: var(--accent-light);
    border: 1px solid var(--accent);
    border-radius: 8px;
    padding: 0.75rem;
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 500;
    margin-bottom: 1rem;
}

.btn-checkout {
    width: 100%;
    padding: 0.875rem;
    border: none;
    border-radius: 12px;
    background: var(--accent);
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-checkout:hover {
    background: var(--accent-hover);
}

.btn-checkout:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ─── Mobile Floating Basket Bar ──────────────────────────────── */
.floating-basket {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 0.75rem 1rem;
    background: var(--accent);
    color: #fff;
    display: none;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    box-shadow: 0 -2px 16px rgba(0, 0, 0, 0.3);
}

.floating-basket .basket-count {
    background: #fff;
    color: var(--accent);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
}

/* ─── Product Detail Modal ────────────────────────────────────── */
.modal-content {
    background: var(--bg-card) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
    border-radius: 16px !important;
}

.modal-header {
    border-bottom: 1px solid var(--border-color) !important;
}

.modal-footer {
    border-top: 1px solid var(--border-color) !important;
}

.modal-body .product-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 1rem;
}

.option-group {
    margin-bottom: 1.25rem;
}

.option-group .option-title {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.option-group .option-title .badge {
    font-size: 0.65rem;
}

/* No grow/scale effect on dressing pill buttons */
.option-group .btn,
.option-group .btn:hover,
.option-group .btn:focus,
.option-group .btn:active,
.option-group .btn:focus-visible {
    transform: none !important;
    box-shadow: none !important;
    outline: none !important;
}

/* Mobile: Product detail modal full-screen */
@media (max-width: 768px) {
    .modal-product-detail .modal-dialog {
        margin: 0;
        max-width: 100%;
        min-height: 100vh;
    }

    .modal-product-detail .modal-content {
        min-height: 100vh;
        border-radius: 0;
        border: none;
    }

    .modal-product-detail .modal-body {
        max-height: calc(100vh - 130px) !important;
    }
}

/* Sticky search + category bar */
.sticky-controls {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--bg-primary);
    padding-top: 0.5rem;
    padding-bottom: 0.25rem;
}

.option-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--border-color);
}

.option-item:last-child {
    border-bottom: none;
}

.option-item label {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.option-item .option-price {
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* ─── Highlights Carousel ─────────────────────────────────────── */
.highlights-carousel {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding: 0.5rem 0 1rem;
    scrollbar-width: none;
}

.highlights-carousel::-webkit-scrollbar {
    display: none;
}

.highlight-card {
    flex: 0 0 180px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
}

.highlight-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}

.highlight-card img {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.highlight-card .highlight-info {
    padding: 0.6rem;
}

.highlight-card .highlight-title {
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.highlight-card .highlight-price {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--accent);
}

/* ─── Search Bar ──────────────────────────────────────────────── */
.search-bar {
    position: relative;
}

.search-bar input {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0.7rem 1rem 0.7rem 2.8rem;
    width: 100%;
    color: var(--text-primary);
    font-size: 0.9rem;
    transition: border-color 0.2s ease;
}

.search-bar input:focus {
    outline: none;
    border-color: var(--accent);
}

.search-bar input::placeholder {
    color: var(--text-muted);
}

.search-bar .search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

/* ─── Profile Sidebar ─────────────────────────────────────────── */
.profile-sidebar {
    position: fixed;
    top: 0;
    right: -320px;
    width: 320px;
    height: 100vh;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border-color);
    z-index: 2000;
    transition: right 0.3s ease;
    overflow-y: auto;
    padding: 1.5rem;
}

.profile-sidebar.open {
    right: 0;
}

.profile-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.profile-backdrop.open {
    opacity: 1;
    visibility: visible;
}

.profile-menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0.875rem 0;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
    cursor: pointer;
    transition: color 0.2s ease;
    font-weight: 500;
}

.profile-menu-item:hover {
    color: var(--accent);
}

.profile-menu-item i {
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
}

/* ─── Buttons ─────────────────────────────────────────────────── */
.btn-accent {
    background: var(--accent);
    border: none;
    color: #fff;
    border-radius: 12px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-accent:hover {
    background: var(--accent-hover);
    color: #fff;
}

.btn-outline-light-custom {
    border: 2px solid rgba(255, 255, 255, 0.4);
    color: #fff;
    border-radius: 12px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    backdrop-filter: blur(4px);
    transition: all 0.3s ease;
}

.btn-outline-light-custom:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.6);
    color: #fff;
}

/* ─── Form Controls ───────────────────────────────────────────── */
.form-control-dark {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    border-radius: 10px;
}

.form-control-dark:focus {
    background: var(--bg-surface);
    border-color: var(--accent);
    color: var(--text-primary);
    box-shadow: 0 0 0 0.2rem rgba(229, 57, 53, 0.15);
}

/* ─── Responsive ──────────────────────────────────────────────── */
@media (max-width: 768px) {
    .landing-title {
        font-size: 2rem;
    }

    .landing-logo {
        width: 80px;
        height: 80px;
    }

    .branch-banner {
        height: 200px;
    }

    .basket-sidebar {
        display: none;
    }

    .floating-basket {
        display: flex;
    }

    .product-card .card-img-wrapper {
        height: 130px;
    }

    .profile-sidebar {
        width: 100%;
        right: -100%;
    }
}

@media (min-width: 769px) {
    .floating-basket {
        display: none !important;
    }
}

/* ─── Animations ──────────────────────────────────────────────── */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.4s ease forwards;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slide-up {
    animation: slideUp 0.5s ease forwards;
}

/* ─── Scrollbar ───────────────────────────────────────────────── */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

/* ═══════════════════════════════════════════════════════════ */
/* Checkout Page                                               */
/* ═══════════════════════════════════════════════════════════ */
.checkout-page {
    max-width: 600px;
    margin: 0 auto;
    padding: 1.5rem;
    min-height: 100vh;
}

.checkout-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    gap: 0;
}

.checkout-steps .step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.checkout-steps .step.active {
    color: var(--accent);
}

.checkout-steps .step.completed {
    color: #4CAF50;
}

.checkout-steps .step-circle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.checkout-steps .step.active .step-circle {
    background: var(--accent);
    color: #fff;
}

.checkout-steps .step.completed .step-circle {
    background: #4CAF50;
    color: #fff;
}

.checkout-steps .step-line {
    width: 60px;
    height: 3px;
    background: var(--bg-secondary);
    margin: 0 8px;
    margin-bottom: 20px;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.checkout-steps .step-line.active {
    background: var(--accent);
}

.checkout-card {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 1.5rem;
    border: 1px solid var(--border-color);
}

.checkout-card .form-label {
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.checkout-card .form-control {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    border-radius: 10px;
    padding: 0.6rem 0.875rem;
}

.checkout-card .form-control:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 2px rgba(229, 57, 53, 0.15);
}

.checkout-card .form-control::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.checkout-card .text-muted {
    color: rgba(255, 255, 255, 0.4) !important;
}

.order-type-toggle {
    display: flex;
    gap: 8px;
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 4px;
}

.order-type-toggle button {
    flex: 1;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    padding: 0.6rem;
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.order-type-toggle button.active {
    background: var(--accent);
    color: #fff;
}

.payment-options {
    display: flex;
    gap: 12px;
}

.payment-btn {
    flex: 1;
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 1rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.payment-btn.active {
    border-color: var(--accent);
    background: rgba(229, 57, 53, 0.08);
}

.payment-btn.disabled-payment {
    opacity: 0.4;
    cursor: not-allowed;
}

.logged-in-badge {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(76, 175, 80, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.text-accent {
    color: var(--accent) !important;
    text-decoration: none;
    font-weight: 600;
}

.text-accent:hover {
    text-decoration: underline;
}

.order-items-summary {
    max-height: 200px;
    overflow-y: auto;
}

@media (max-width: 768px) {
    .checkout-page {
        padding: 1rem;
    }

    .checkout-steps .step-line {
        width: 40px;
    }
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* ═══════════════════════════════════════════════════════════════
   HAMBURGER MENU & SIDEBAR
   ═══════════════════════════════════════════════════════════════ */

/* ─── Hamburger Button ────────────────────────────────────────── */
.hamburger-btn {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1040;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: #fff;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.hamburger-btn:hover {
    background: var(--accent);
    border-color: var(--accent);
    transform: scale(1.05);
}

/* ─── Sidebar Overlay ─────────────────────────────────────────── */
.sidebar-overlay {
    position: fixed;
    inset: 0;
    z-index: 1200;
    background: rgba(0, 0, 0, 0);
    transition: background 0.35s ease;
    pointer-events: none;
}

.sidebar-overlay.active {
    background: rgba(0, 0, 0, 0.6);
    pointer-events: all;
}

/* ─── Sidebar Panel ───────────────────────────────────────────── */
.sidebar-menu {
    position: fixed;
    top: 0;
    right: -360px;
    z-index: 1300;
    width: 320px;
    max-width: 85vw;
    height: 100vh;
    background: var(--bg-card);
    border-left: 1px solid var(--border-color);
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.4);
    transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    overscroll-behavior: contain;
}

.sidebar-menu.open {
    right: 0;
}

.sidebar-content {
    padding: 0;
}

/* ─── Sidebar Header ─────────────────────────────────────────── */
.sidebar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 1.5rem 1.25rem 1.25rem;
    position: relative;
}

.sidebar-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), #ff6b35);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.sidebar-avatar i {
    font-size: 1.4rem;
    color: #fff;
}

.sidebar-user-name {
    font-weight: 700;
    font-size: 1.05rem;
    margin: 0;
    color: var(--text-primary);
}

.sidebar-link-btn {
    background: none;
    border: none;
    padding: 0;
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.sidebar-link-btn:hover {
    color: var(--accent-hover);
}

.sidebar-close-btn {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: var(--bg-surface);
    color: var(--text-secondary);
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.sidebar-close-btn:hover {
    background: var(--accent);
    color: #fff;
}

/* ─── Sidebar Divider ─────────────────────────────────────────── */
.sidebar-divider {
    height: 1px;
    background: var(--border-color);
    margin: 0.5rem 1.25rem;
}

/* ─── Sidebar Menu Items ──────────────────────────────────────── */
.sidebar-item {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 0.85rem 1.25rem;
    border: none;
    background: transparent;
    color: var(--text-primary);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
}

.sidebar-item:hover {
    background: var(--bg-surface);
}

.sidebar-item i {
    font-size: 1.15rem;
    width: 24px;
    text-align: center;
    color: var(--text-secondary);
    flex-shrink: 0;
}

.sidebar-item:hover i {
    color: var(--accent);
}

.sidebar-item-danger {
    color: var(--accent);
}

.sidebar-item-danger i {
    color: var(--accent) !important;
}

.sidebar-item-accent {
    color: var(--accent);
    font-weight: 600;
}

.sidebar-item-accent i {
    color: var(--accent) !important;
}

/* ─── Sidebar Badge ───────────────────────────────────────────── */
.sidebar-badge {
    margin-left: auto;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    background: var(--bg-surface);
    padding: 3px 10px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

/* ─── Mobile Adjustments ──────────────────────────────────────── */
@media (max-width: 576px) {
    .hamburger-btn {
        top: 0.75rem;
        right: 0.75rem;
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .sidebar-menu {
        width: 300px;
    }
}

/* ═══════════════════════════════════════════════════════════════
   ORDER TRACKING TIMELINE & SUB-TABS
   ═══════════════════════════════════════════════════════════════ */

/* ─── Order Sub-Tabs ──────────────────────────────────────────── */
.order-sub-tabs {
    display: flex;
    background: var(--bg-card);
    border-radius: 12px;
    padding: 4px;
    border: 1px solid var(--border-color);
}

.order-sub-tab {
    flex: 1;
    padding: 0.55rem 1rem;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.9rem;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.order-sub-tab.active {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 2px 8px rgba(229, 57, 53, 0.3);
}

.order-count-badge {
    background: rgba(255, 255, 255, 0.25);
    padding: 1px 8px;
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: 700;
}

.order-sub-tab:not(.active) .order-count-badge {
    background: var(--accent-light);
    color: var(--accent);
}

/* ─── Tracking Timeline ──────────────────────────────────────── */
.tracking-timeline {
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: 1rem 0 0.5rem;
    position: relative;
}

.tracking-step {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 0.5rem 0;
    position: relative;
}

/* Vertical connector line */
.tracking-step:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 13px;
    top: calc(0.5rem + 28px);
    bottom: -0.5rem;
    width: 2px;
    background: var(--border-color);
    transition: background 0.3s ease;
}

.tracking-step.completed:not(:last-child)::after {
    background: var(--success);
}

.tracking-step.current:not(:last-child)::after {
    background: linear-gradient(to bottom, var(--accent), var(--border-color));
}

/* Dot */
.tracking-dot {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--bg-surface);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.7rem;
    color: var(--text-secondary);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

.tracking-step.completed .tracking-dot {
    background: var(--success);
    border-color: var(--success);
    color: #fff;
}

.tracking-step.current .tracking-dot {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    box-shadow: 0 0 0 4px var(--accent-light);
}

/* Pulsing animation for current step */
.tracking-pulse {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #fff;
    animation: trackingPulse 1.5s ease-in-out infinite;
}

@keyframes trackingPulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.6);
        opacity: 0.5;
    }
}

/* Label */
.tracking-label {
    display: flex;
    flex-direction: column;
    padding-top: 3px;
}

.tracking-title {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
}

.tracking-step:not(.completed):not(.current) .tracking-title {
    color: var(--text-secondary);
}

.tracking-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 1px;
}

.tracking-step.current .tracking-title {
    color: var(--accent);
}

/* ─── Profile Accent Button ──────────────────────────────────── */
.btn-accent {
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.25s ease;
}

.btn-accent:hover {
    background: var(--accent-hover);
    color: #fff;
}