/* ===== Cali Armor - Main Styles ===== */
:root {
    --bg-main: #0a0a0a;
    --bg-card: #1a1a1a;
    --bg-card-hover: #252525;
    --accent: #FFC107;
    --accent-dark: #d4a005;
    --text: #ffffff;
    --text-muted: #9a9a9a;
    --border: #2a2a2a;
    --input-bg: #2a2a2a;
}

* { box-sizing: border-box; }

body {
    background: var(--bg-main);
    color: var(--text);
    font-family: 'Segoe UI', Tahoma, 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    padding-bottom: 80px;
    min-height: 100vh;
}

html[dir="rtl"] body {
    font-family: 'Tahoma', 'Segoe UI', sans-serif;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }

/* ===== Header ===== */
.main-header {
    background: var(--bg-main);
    padding: 12px 20px;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1400px;
    margin: 0 auto;
    gap: 15px;
}

.header-left, .header-right {
    display: flex;
    gap: 10px;
    align-items: center;
    flex: 1;
}

.header-right {
    justify-content: flex-end;
}

.header-center { flex: 2; text-align: center; }

.phone-btn, .lang-btn {
    background: transparent;
    color: var(--accent);
    border: 1px solid var(--accent);
    padding: 6px 14px;
    border-radius: 25px;
    font-size: 13px;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all .2s;
}

.phone-btn:hover, .lang-btn:hover {
    background: var(--accent);
    color: #000;
}

.menu-btn {
    background: transparent;
    color: #fff;
    border: none;
    font-size: 22px;
    cursor: pointer;
    padding: 5px 12px;
}
.menu-btn:hover { color: var(--accent); }

.brand-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: transform .2s;
    max-width: 100%;
}
.brand-logo:hover {
    transform: scale(1.03);
}
.logo-img {
    height: 50px;
    max-height: 50px;
    max-width: 220px;
    width: auto;
    object-fit: contain;
    display: block;
}

/* ===== Categories ===== */
.categories-nav {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    flex-wrap: wrap;
    padding: 15px 0 5px;
    max-width: 1400px;
    margin: 0 auto;
}
html[dir="ltr"] .categories-nav { justify-content: flex-start; }

.cat-tab {
    padding: 10px 28px;
    border-radius: 30px;
    background: var(--bg-card);
    color: #fff;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    border: none;
    transition: all .2s;
    letter-spacing: 1px;
}
.cat-tab:hover { background: var(--bg-card-hover); color: #fff; }
.cat-tab.active {
    background: var(--accent);
    color: #000;
}

/* ===== Product Grid ===== */
.site-main {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 20px;
}

.product-card {
    background: var(--bg-card);
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    align-items: stretch;
    position: relative;
    min-height: 160px;
    transition: transform .2s, box-shadow .2s;
}
.product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(255,193,7,.15);
}

.product-image {
    width: 160px;
    min-width: 160px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
}
.product-image img {
    max-width: 100%;
    max-height: 140px;
    object-fit: contain;
}
.product-image .no-img {
    font-size: 40px;
    color: #ccc;
}

/* Image count badge on product card */
.img-count-badge {
    position: absolute;
    top: 6px;
    left: 6px;
    background: rgba(0,0,0,0.7);
    color: var(--accent);
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 12px;
    font-weight: 600;
    pointer-events: none;
    backdrop-filter: blur(4px);
}
html[dir="rtl"] .img-count-badge { left: auto; right: 6px; }

.product-image { position: relative; }

/* Sale badge on card - subtle corner ribbon */
.sale-tag {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #dc3545;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    z-index: 3;
    letter-spacing: 0.5px;
}
html[dir="rtl"] .sale-tag { right: auto; left: 10px; }

/* Out of stock overlay */
.product-card.is-out-of-stock { opacity: 0.55; filter: grayscale(60%); }
.out-of-stock-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-8deg);
    background: #dc3545;
    color: #fff;
    font-weight: 800;
    padding: 6px 18px;
    font-size: 13px;
    border-radius: 4px;
    z-index: 4;
    letter-spacing: 1px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.6);
    pointer-events: none;
}

/* Price display with sale - clean visible distinction */
.product-price .price-sale,
.product-detail-price .price-sale,
.price-sale {
    color: var(--accent) !important;
    font-weight: 800 !important;
}

.product-price .price-old,
.product-detail-price .price-old,
.price-old {
    display: inline-block !important;
    color: #888 !important;
    font-weight: 400 !important;
    font-size: 0.6em !important;
    margin-left: 12px !important;
    text-decoration: line-through !important;
    text-decoration-color: #dc3545 !important;
    text-decoration-thickness: 2px !important;
    -webkit-text-decoration-color: #dc3545 !important;
    -webkit-text-decoration-line: line-through !important;
    opacity: 0.75 !important;
    vertical-align: middle !important;
}
html[dir="rtl"] .price-old { margin-left: 0 !important; margin-right: 12px !important; }

.sale-badge-inline {
    display: inline-block;
    background: #dc3545;
    color: #fff;
    font-size: 12px;
    padding: 3px 10px;
    border-radius: 12px;
    margin-left: 10px;
    font-weight: 700;
    vertical-align: middle;
}
html[dir="rtl"] .sale-badge-inline { margin-left: 0; margin-right: 10px; }

/* ===== Similar Products ===== */
.similar-products {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}
.similar-title {
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.similar-title i { color: var(--accent); }
.similar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}
.similar-card {
    background: var(--bg-card);
    border-radius: 10px;
    overflow: hidden;
    text-decoration: none;
    color: #fff;
    transition: transform .2s, box-shadow .2s;
    border: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}
.similar-card:hover {
    transform: translateY(-4px);
    border-color: var(--accent);
    box-shadow: 0 8px 20px rgba(255,193,7,0.15);
    color: #fff;
}
.similar-image {
    width: 100%;
    aspect-ratio: 1;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;
    position: relative;
    overflow: hidden;
}
.similar-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.similar-image .no-img {
    font-size: 40px;
    color: #ccc;
}
.similar-out {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-8deg);
    background: #dc3545;
    color: #fff;
    font-weight: 800;
    padding: 4px 12px;
    font-size: 11px;
    border-radius: 4px;
    letter-spacing: 1px;
}
.similar-info {
    padding: 12px 15px;
}
.similar-name {
    font-size: 13px;
    font-weight: 600;
    margin: 0 0 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 36px;
}
.similar-price {
    font-size: 16px;
    font-weight: 700;
}

@media (max-width: 640px) {
    .similar-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .similar-name { font-size: 12px; }
    .similar-price { font-size: 14px; }
}

.product-info {
    flex: 1;
    padding: 15px 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: end;
}
html[dir="ltr"] .product-info { text-align: left; }

.product-name {
    font-size: 16px;
    font-weight: 700;
    margin: 0 0 8px;
    color: #fff;
}
.product-desc {
    font-size: 12px;
    color: var(--text-muted);
    margin: 0 0 8px;
    line-height: 1.5;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.product-price {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    margin-top: auto;
}

.add-btn {
    position: absolute;
    bottom: -1px;
    left: -1px;
    width: 38px;
    height: 38px;
    background: var(--accent);
    color: #000;
    border: none;
    border-radius: 0 8px 0 10px;
    font-size: 20px;
    font-weight: 900;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s;
}
html[dir="rtl"] .add-btn {
    left: auto;
    right: -1px;
    border-radius: 8px 0 10px 0;
}
.add-btn:hover { background: #fff; }

/* ===== Product Detail Page ===== */
.product-detail {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
    align-items: start;
}

.product-detail-gallery {
    background: linear-gradient(145deg, #1a1a1a 0%, #0d0d0d 100%);
    border-radius: 14px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 460px;
    aspect-ratio: 1;
    position: relative;
    overflow: hidden;
    border: 1px solid #222;
    box-shadow: inset 0 0 60px rgba(255,193,7,0.04), 0 8px 30px rgba(0,0,0,0.4);
}
.product-detail-gallery::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background:
        radial-gradient(circle at 30% 30%, rgba(255,193,7,0.05) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(255,255,255,0.02) 0%, transparent 50%);
    pointer-events: none;
    z-index: 1;
}
.product-detail-gallery img {
    max-width: 88%;
    max-height: 88%;
    object-fit: contain;
    transition: opacity .25s ease, transform .3s ease;
    position: relative;
    z-index: 2;
    filter: drop-shadow(0 10px 30px rgba(0,0,0,0.5));
}
.product-detail-gallery:hover img {
    transform: scale(1.03);
}
.product-detail-gallery-wrap {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* Gallery navigation arrows */
.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,193,7,0.9);
    color: #000;
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s, transform .2s, box-shadow .2s;
    z-index: 5;
    opacity: 0;
    box-shadow: 0 4px 15px rgba(0,0,0,0.4);
}
.product-detail-gallery:hover .gallery-nav {
    opacity: 1;
}
.gallery-nav:hover {
    background: #fff;
    color: #000;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 20px rgba(255,193,7,0.5);
}
.gallery-prev { left: 16px; }
.gallery-next { right: 16px; }
html[dir="rtl"] .gallery-prev { left: auto; right: 16px; }
html[dir="rtl"] .gallery-next { right: auto; left: 16px; }

/* Gallery dots */
.gallery-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 4;
    padding: 8px 14px;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.08);
}
.gallery-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(255,255,255,0.3);
    cursor: pointer;
    transition: all .25s;
}
.gallery-dot:hover { background: rgba(255,255,255,0.6); }
.gallery-dot.active {
    background: var(--accent);
    width: 26px;
    border-radius: 4px;
    box-shadow: 0 0 8px rgba(255,193,7,0.6);
}

/* Image counter top-right */
.gallery-counter {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(10px);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 14px;
    z-index: 4;
    border: 1px solid rgba(255,255,255,0.1);
    letter-spacing: 0.5px;
}
html[dir="rtl"] .gallery-counter { right: auto; left: 16px; }

/* Thumbnails */
.gallery-thumbs {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 6px 2px;
    scrollbar-width: thin;
}
.gallery-thumbs::-webkit-scrollbar { height: 4px; }
.gallery-thumbs::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 3px; }
.thumb {
    flex-shrink: 0;
    width: 72px;
    height: 72px;
    background: linear-gradient(145deg, #1a1a1a 0%, #0d0d0d 100%);
    border: 2px solid #222;
    border-radius: 10px;
    padding: 6px;
    cursor: pointer;
    overflow: hidden;
    transition: border-color .2s, transform .2s, box-shadow .2s;
    opacity: 0.7;
}
.thumb:hover {
    transform: translateY(-2px);
    border-color: rgba(255,193,7,0.5);
    opacity: 1;
}
.thumb.active {
    border-color: var(--accent);
    opacity: 1;
    box-shadow: 0 4px 15px rgba(255,193,7,0.25);
}
.thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

.product-detail-info h1 {
    font-size: 30px;
    font-weight: 800;
    margin-bottom: 20px;
}
.product-detail-price {
    font-size: 28px;
    color: var(--accent);
    font-weight: 700;
    margin-bottom: 20px;
}
.product-detail-desc {
    color: var(--text-muted);
    line-height: 1.8;
    font-size: 15px;
    margin-bottom: 25px;
}

.share-btn {
    background: var(--accent);
    color: #000;
    border: none;
    padding: 10px 25px;
    border-radius: 25px;
    font-weight: 700;
    cursor: pointer;
}

.notes-section { margin-top: 25px; }
.notes-section h3 { font-size: 15px; margin-bottom: 8px; }
.notes-section textarea {
    width: 100%;
    background: var(--input-bg);
    color: #fff;
    border: none;
    padding: 15px;
    border-radius: 10px;
    min-height: 60px;
    font-family: inherit;
}

.add-to-cart-btn {
    width: 100%;
    background: var(--accent);
    color: #000;
    border: none;
    padding: 14px;
    border-radius: 30px;
    font-size: 18px;
    font-weight: 800;
    cursor: pointer;
    margin-top: 20px;
}
.add-to-cart-btn:hover { background: #fff; }

.qty-control {
    display: inline-flex;
    gap: 15px;
    align-items: center;
    background: var(--bg-card);
    border-radius: 25px;
    padding: 5px 15px;
    margin-top: 20px;
}
.qty-control button {
    background: transparent;
    color: var(--accent);
    border: none;
    font-size: 20px;
    cursor: pointer;
    width: 30px;
    height: 30px;
}
.qty-control input {
    background: transparent;
    border: none;
    color: #fff;
    width: 50px;
    text-align: center;
    font-size: 16px;
}

/* ===== Bottom nav ===== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-main);
    border-top: 1px solid var(--border);
    padding: 15px 0;
    display: flex;
    justify-content: space-around;
    z-index: 100;
}
.bn-btn {
    color: #fff;
    font-size: 22px;
    position: relative;
    background: transparent;
    border: none;
    cursor: pointer;
}
.bn-btn:hover { color: var(--accent); }
.cart-badge {
    position: absolute;
    top: -8px;
    right: -10px;
    background: var(--accent);
    color: #000;
    font-size: 11px;
    border-radius: 50%;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    padding: 2px;
}

/* ===== Side menu ===== */
.side-menu {
    position: fixed;
    top: 0;
    right: -320px;
    width: 300px;
    height: 100vh;
    background: var(--bg-card);
    z-index: 200;
    padding: 60px 20px 20px;
    transition: right .3s;
    box-shadow: -3px 0 20px rgba(0,0,0,.5);
}
html[dir="ltr"] .side-menu { right: auto; left: -320px; transition: left .3s; box-shadow: 3px 0 20px rgba(0,0,0,.5); }
.side-menu.open { right: 0; }
html[dir="ltr"] .side-menu.open { left: 0; }
.side-menu ul { list-style: none; padding: 0; margin: 0; }
.side-menu li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 10px;
    color: #fff;
    border-bottom: 1px solid var(--border);
    font-size: 15px;
}
.side-menu li a:hover { color: var(--accent); }

.close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255,255,255,.1);
    color: #fff;
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
}
html[dir="ltr"] .close-btn { right: auto; left: 15px; }

/* ===== Lang Modal / Search Modal ===== */
.lang-modal, .search-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.85);
    z-index: 300;
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding: 40px 20px;
    overflow-y: auto;
}
.lang-modal.open, .search-modal.open { display: flex; }
.lang-modal-inner {
    width: 100%;
    max-width: 500px;
    padding: 40px 20px;
    position: relative;
}
.search-modal-inner {
    width: 100%;
    max-width: 1200px;
    padding: 30px 20px;
    position: relative;
}

.lang-title, .search-title {
    color: #fff;
    font-size: 22px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 30px;
}

.lang-option {
    display: block;
    background: var(--accent);
    color: #000;
    padding: 15px;
    border-radius: 40px;
    text-align: center;
    margin-bottom: 15px;
    font-weight: 700;
    font-size: 18px;
    transition: background .2s;
}
.lang-option:hover { background: #fff; color: #000; }

.search-box-wrap {
    position: relative;
    margin-bottom: 20px;
}
.search-input {
    width: 100%;
    background: var(--input-bg);
    border: none;
    color: #fff;
    padding: 15px 45px 15px 20px;
    border-radius: 8px;
    font-size: 15px;
}
.search-clear {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,.1);
    color: #fff;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
}
html[dir="rtl"] .search-clear { left: 10px; right: auto; }

.search-results {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 12px;
}

.search-result-item {
    background: var(--bg-card);
    padding: 10px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #fff;
    cursor: pointer;
    transition: background .2s;
}
.search-result-item:hover { background: var(--bg-card-hover); }
.search-result-item img {
    width: 50px;
    height: 50px;
    object-fit: cover;
    background: #fff;
    border-radius: 4px;
}
.search-result-name { flex: 1; font-size: 13px; }
.search-result-price { color: var(--accent); font-weight: 600; font-size: 13px; }

.load-more-btn {
    width: 100%;
    background: var(--bg-card);
    border: none;
    color: #fff;
    padding: 14px;
    border-radius: 10px;
    cursor: pointer;
    margin-top: 15px;
}
.load-more-btn:hover { background: var(--bg-card-hover); }

/* ===== Cart Page ===== */
.cart-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 30px 20px;
}
.cart-empty {
    text-align: center;
    padding: 80px 20px;
}
.cart-empty-icon {
    font-size: 90px;
    color: var(--accent);
    margin-bottom: 20px;
}
.cart-empty-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 10px;
}
.cart-empty-sub { color: var(--text-muted); }

.cart-item {
    background: var(--bg-card);
    padding: 15px;
    border-radius: 10px;
    display: grid;
    grid-template-columns: 80px 1fr auto auto;
    gap: 15px;
    align-items: center;
    margin-bottom: 15px;
}
.cart-item img { width: 80px; height: 80px; object-fit: contain; background: #fff; border-radius: 6px; }
.cart-item-name { font-weight: 600; }
.cart-item-price { color: var(--accent); font-size: 14px; }

.cart-summary {
    background: var(--bg-card);
    padding: 20px;
    border-radius: 10px;
    margin-top: 20px;
}
.cart-total {
    font-size: 22px;
    font-weight: 700;
    color: var(--accent);
}

/* ===== Forms ===== */
.form-card {
    background: var(--bg-card);
    padding: 30px;
    border-radius: 12px;
    max-width: 500px;
    margin: 40px auto;
}
.form-card h2 { margin-bottom: 25px; text-align: center; }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; margin-bottom: 6px; font-size: 14px; color: var(--text-muted); }
.form-control {
    width: 100%;
    background: var(--input-bg);
    border: 1px solid var(--border);
    color: #fff;
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
}
.form-control:focus {
    outline: none;
    border-color: var(--accent);
}
.btn-primary-custom {
    background: var(--accent);
    color: #000;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-weight: 700;
    cursor: pointer;
    width: 100%;
    font-size: 15px;
}
.btn-primary-custom:hover { background: #fff; }

.alert-box {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
}
.alert-success { background: rgba(40, 167, 69, .15); color: #28a745; border: 1px solid #28a745; }
.alert-error { background: rgba(220, 53, 69, .15); color: #dc3545; border: 1px solid #dc3545; }

/* ===== Checkout ===== */
.checkout-wrap {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    max-width: 1100px;
    margin: 30px auto;
    padding: 0 20px;
}

/* ===== Customer Dashboard ===== */
.customer-dashboard {
    max-width: 1100px;
    margin: 30px auto;
    padding: 0 20px;
}
.dashboard-hero {
    background: linear-gradient(135deg, #1a1a1a 0%, #252525 100%);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 25px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    gap: 15px;
    flex-wrap: wrap;
}
.hero-welcome {
    font-size: 22px;
    margin-bottom: 6px;
}
.hero-welcome strong { color: var(--accent); }
.hero-email {
    color: var(--text-muted);
    font-size: 13px;
}
.logout-btn {
    background: transparent;
    border: 1px solid #dc3545;
    color: #dc3545;
    padding: 8px 18px;
    border-radius: 25px;
    font-size: 13px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all .2s;
}
.logout-btn:hover {
    background: #dc3545;
    color: #fff;
}

.dashboard-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 25px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0;
}
.dash-tab {
    padding: 10px 20px;
    background: transparent;
    color: #bbb;
    text-decoration: none;
    border-radius: 8px 8px 0 0;
    font-size: 14px;
    border-bottom: 3px solid transparent;
    transition: all .2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.dash-tab:hover {
    background: var(--bg-card);
    color: var(--accent);
}
.dash-tab.active {
    color: var(--accent);
    border-bottom-color: var(--accent);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}
.stats-grid .stat-card {
    background: var(--bg-card);
    padding: 25px;
    border-radius: 12px;
    border: 1px solid var(--border);
    border-left: 4px solid var(--accent);
    position: relative;
    overflow: hidden;
}
.stats-grid .stat-icon {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 32px;
    color: var(--accent);
    opacity: 0.25;
}
html[dir="rtl"] .stats-grid .stat-icon { right: auto; left: 15px; }
.stats-grid .stat-num {
    font-size: 32px;
    font-weight: 800;
    color: var(--accent);
}
.stats-grid .stat-label {
    color: var(--text-muted);
    font-size: 14px;
    margin-top: 5px;
}

.orders-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.order-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 15px 20px;
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 15px;
    align-items: center;
    text-decoration: none;
    color: #fff;
    transition: all .2s;
}
.order-card:hover {
    border-color: var(--accent);
    transform: translateX(-3px);
    color: #fff;
}
html[dir="rtl"] .order-card:hover { transform: translateX(3px); }
.order-num {
    font-size: 16px;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 4px;
}
.order-date {
    color: var(--text-muted);
    font-size: 12px;
}
.order-total {
    font-size: 17px;
    font-weight: 700;
    color: #fff;
}
.status-badge {
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.status-pending { background: rgba(255,193,7,0.2); color: #FFC107; border: 1px solid #FFC107; }
.status-confirmed { background: rgba(23,162,184,0.2); color: #17a2b8; border: 1px solid #17a2b8; }
.status-shipped { background: rgba(111,66,193,0.2); color: #a78bfa; border: 1px solid #a78bfa; }
.status-delivered { background: rgba(40,167,69,0.2); color: #28a745; border: 1px solid #28a745; }
.status-cancelled { background: rgba(220,53,69,0.2); color: #dc3545; border: 1px solid #dc3545; }

.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: var(--bg-card);
    border-radius: 12px;
    border: 1px dashed var(--border);
}
.empty-state i {
    font-size: 60px;
    color: var(--accent);
    opacity: 0.5;
    margin-bottom: 15px;
}
.empty-state p {
    color: var(--text-muted);
    font-size: 16px;
    margin-bottom: 10px;
}

.order-detail {
    background: transparent;
}

@media (max-width: 640px) {
    .order-card { grid-template-columns: 1fr auto; gap: 10px; }
    .order-card .status-badge { grid-column: 1 / -1; justify-self: start; }
    .dash-tab { padding: 8px 12px; font-size: 12px; }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .product-grid { grid-template-columns: 1fr; }
    .product-detail { grid-template-columns: 1fr; }
    .checkout-wrap { grid-template-columns: 1fr; }
    .logo-img { height: 38px; max-height: 38px; max-width: 160px; }
    .categories-nav { justify-content: center; }
    .cat-tab { padding: 8px 18px; font-size: 12px; }
    .product-card { min-height: 140px; }
    .product-image { width: 130px; min-width: 130px; }
    .product-name { font-size: 14px; }
    .product-desc { font-size: 11px; }
    .search-results { grid-template-columns: 1fr; }
    .header-left .phone-btn { font-size: 11px; padding: 4px 10px; }
}
@media (max-width: 768px) {
    .product-grid { grid-template-columns: 1fr; }
    .product-detail { grid-template-columns: 1fr; }
    .checkout-wrap { grid-template-columns: 1fr; }
    .logo-img { height: 38px; max-height: 38px; max-width: 160px; }
    .categories-nav { justify-content: center; }
    .cat-tab { padding: 8px 18px; font-size: 12px; }
    .product-card { min-height: 140px; }
    .product-image { width: 130px; min-width: 130px; }
    .product-name { font-size: 14px; }
    .product-desc { font-size: 11px; }
    .search-results { grid-template-columns: 1fr; }
    .header-left .phone-btn { font-size: 11px; padding: 4px 10px; }
}

/* ===== Admin ===== */
.admin-wrapper { display: grid; grid-template-columns: 250px 1fr; min-height: 100vh; }
.admin-sidebar { background: #111; padding: 20px; }
.admin-sidebar h3 { color: var(--accent); margin-bottom: 20px; font-size: 18px; }
.admin-sidebar a { display: block; padding: 10px; color: #ddd; border-radius: 6px; margin-bottom: 5px; }
.admin-sidebar a:hover, .admin-sidebar a.active { background: var(--accent); color: #000; }
.admin-content { padding: 30px; background: var(--bg-main); }
.admin-table { width: 100%; border-collapse: collapse; background: var(--bg-card); border-radius: 8px; overflow: hidden; }
.admin-table th, .admin-table td { padding: 12px; text-align: start; border-bottom: 1px solid var(--border); }
.admin-table th { background: #1e1e1e; color: var(--accent); }
.admin-table tr:last-child td { border-bottom: none; }
.btn-sm { padding: 5px 12px; border-radius: 4px; font-size: 12px; border: none; cursor: pointer; }
.btn-edit { background: var(--accent); color: #000; }
.btn-delete { background: #dc3545; color: #fff; }
.btn-view { background: #17a2b8; color: #fff; }

.admin-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; margin-bottom: 30px; }
.stat-card { background: var(--bg-card); padding: 25px; border-radius: 10px; text-align: center; border-left: 4px solid var(--accent); }
.stat-num { font-size: 32px; font-weight: 800; color: var(--accent); }
.stat-label { color: var(--text-muted); margin-top: 5px; }
