:root {
    /* Wahy Electronics brand tokens */
    --blue: #2B44E0;
    --violet: #8B5CF6;
    --violet-hi: #A97CFF;
    --cyan: #22D3EE;
    --amber: #F5A623;
    --amber-light: #FFC257;
    --cta-ink: #241300;

    --primary: var(--blue);
    --secondary: var(--violet);
    --accent: var(--amber);
    --accent-hover: var(--amber-light);
    --red: #E4283A;
    --bg: #F6F7FB;
    --white: #ffffff;
    --surface: #ffffff;
    --text: #12151E;
    --text-light: #5B5F70;
    --border: #DEE1EC;
    --success: #2e7d32;
    --danger: #F4574B;
    --shadow: 0 2px 10px rgba(12,14,20,0.08);

    /* header/footer get their own identity, distinct from the page body */
    --header-bg: #ffffff;
    --header-border: var(--border);
    --footer-bg: #0A0F1F;
    --footer-text: #C7CBDE;
    --footer-heading: #ffffff;
    --footer-link: #A9B0C9;
    --footer-border: #1C2338;

    --font-en: 'Plus Jakarta Sans', 'Inter', 'Segoe UI', Arial, sans-serif;
    --font-ar: 'Tajawal', 'Readex Pro', 'Segoe UI', Tahoma, sans-serif;
}

/* Default is always light mode, regardless of OS preference — dark only
   applies once the user explicitly picks it via the theme toggle button
   (which sets data-theme="dark" on <html>, see :root[data-theme="dark"] below). */

/* Manual theme toggle overrides — must win over prefers-color-scheme in both directions */
:root[data-theme="dark"] {
    --bg: #0C0E14;
    --surface: #12151E;
    --text: #F1F2F8;
    --text-light: #A3A7BA;
    --border: #262B3B;
    --primary: #5B79FF;
    --secondary: #A97CFF;
    --shadow: 0 2px 16px rgba(0,0,0,0.45);
    --success: #4CAF50;
    --header-bg: #171C2C;
    --header-border: #262B3B;
}
:root[data-theme="dark"] .product-card .product-image,
:root[data-theme="dark"] .cart-table .product-thumb {
    background: #1B1F2C;
}
:root[data-theme="light"] {
    --bg: #F6F7FB;
    --surface: #ffffff;
    --text: #12151E;
    --text-light: #5B5F70;
    --border: #DEE1EC;
    --primary: var(--blue);
    --secondary: var(--violet);
    --shadow: 0 2px 10px rgba(12,14,20,0.08);
    --success: #2e7d32;
    --header-bg: #ffffff;
    --header-border: #DEE1EC;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-en);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
}

html[lang="ar"] body {
    font-family: var(--font-ar);
}

a {
    text-decoration: none;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
}

.top-bar {
    background: var(--secondary);
    color: var(--white);
    padding: 8px 0;
    font-size: 12px;
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar a {
    color: var(--white);
    text-decoration: none;
}

.top-bar a:hover {
    text-decoration: underline;
}

.social-icons {
    display: flex;
    gap: 10px;
}

.social-icons a {
    font-size: 14px;
}

.main-header {
    background: var(--header-bg);
    box-shadow: var(--shadow);
    position: relative;
    z-index: 100;
    padding: 15px 0;
    border-bottom: 1px solid var(--header-border);
}

.main-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.logo {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    white-space: nowrap;
}

.logo span {
    color: var(--accent);
}

.logo-mark {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.logo-icon {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
}

.logo-word {
    font-family: var(--font-en);
    font-weight: 800;
    font-size: 21px;
    letter-spacing: -0.01em;
    color: var(--text);
    line-height: 1.1;
}

.logo-sub {
    display: block;
    font-weight: 500;
    font-size: 9.5px;
    letter-spacing: .16em;
    color: var(--text-light);
    text-transform: uppercase;
    margin-top: 1px;
}

.footer-logo-mark {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    text-decoration: none;
    margin-bottom: 15px;
}

.footer-logo-mark .logo-icon {
    width: 26px;
    height: 26px;
}

.footer-logo-mark .logo-word {
    font-size: 17px;
    color: var(--text);
}

.search-bar {
    display: flex;
    max-width: 500px;
    width: 100%;
    border: 2px solid var(--border);
    border-radius: 50px;
    overflow: hidden;
}

.search-bar input {
    border: none;
    padding: 10px 15px;
    outline: none;
    flex: 1;
    font-size: 14px;
}

.search-bar button {
    background: var(--accent);
    color: var(--cta-ink);
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.3s;
}

.search-bar button:hover {
    background: var(--accent-hover);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.cart-icon {
    position: relative;
    font-size: 24px;
    color: var(--primary);
    text-decoration: none;
}

.cart-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--accent);
    color: var(--cta-ink);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.account-link {
    color: var(--primary);
    font-weight: 500;
    font-size: 14px;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    background: none;
    border: none;
    padding: 5px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--primary);
    border-radius: 3px;
    transition: all 0.3s;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -6px);
}

.main-nav {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 999;
}

.nav-list {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-list > li {
    position: relative;
}

.nav-list > li > a {
    color: var(--text);
    padding: 16px 20px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    font-size: 14px;
    transition: color 0.3s;
}

.nav-list > li > a:hover,
.nav-list > li > a.is-active {
    color: var(--primary);
}

.nav-list .nav-dropdown .dropdown-menu {
    display: none;
    position: absolute;
    list-style: none;
    background: var(--surface);
    min-width: 260px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
    border-radius: 0 0 8px 8px;
    z-index: 10;
    top: 100%;
    left: 0;
    padding: 8px 0;
    margin: 0;
}

.nav-list .nav-dropdown:hover .dropdown-menu {
    display: block;
}

.nav-list .dropdown-menu li a {
    color: var(--text);
    padding: 10px 20px;
    display: block;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.3s, color 0.3s;
}

.nav-list .dropdown-menu li a:hover {
    background: #f0f7ff;
    color: var(--primary);
}

.nav-list .dropdown-menu a .count {
    float: right;
    background: var(--accent);
    color: var(--cta-ink);
    border-radius: 10px;
    padding: 0 8px;
    font-size: 11px;
    line-height: 20px;
}

.hero {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: var(--white);
    padding: 80px 0;
    overflow: hidden;
}

.hero .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.hero-content {
    max-width: 600px;
}

.hero-content h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-content p {
    font-size: 18px;
    opacity: 0.9;
    margin-bottom: 30px;
}

.hero-btn {
    display: inline-block;
    background: linear-gradient(135deg, var(--accent) 0%, var(--amber-light) 100%);
    color: var(--cta-ink);
    padding: 15px 30px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 16px;
    border: none;
    cursor: pointer;
    box-shadow: 0 10px 24px -8px rgba(245,166,35,.5);
    transition: filter 0.2s, transform 0.15s;
}

.hero-btn:hover {
    filter: brightness(1.06);
    color: var(--cta-ink);
    transform: translateY(-1px);
}

.hero-image {
    float: right;
    max-width: 45%;
}

.hero-image img {
    max-height: 400px;
}

section {
    padding: 60px 0;
}

.section-title {
    text-align: center;
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--primary);
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 40px;
    font-size: 16px;
}

.container {
    max-width: 1200px;
    margin: auto;
    padding: 0 20px;
}

.section {
    padding: 40px 0;
}

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

.product-card {
    background: var(--surface);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
    position: relative;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 18px 34px -16px rgba(20,20,50,.28);
    border-color: var(--primary);
}

.product-card .product-image {
    width: 100%;
    height: 220px;
    object-fit: contain;
    padding: 15px;
    background: #f9f9f9;
    display: block;
}

.product-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--accent);
    color: var(--cta-ink);
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 12px;
    font-weight: 600;
    z-index: 1;
}

.product-badge.sale {
    background: var(--danger);
}

.product-badge.new {
    background: var(--success);
}

.product-info {
    padding: 15px;
}

.product-title {
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text);
    font-size: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-title a {
    color: var(--text);
}

.product-title a:hover {
    color: var(--primary);
}

.product-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 5px;
}

.product-old-price {
    text-decoration: line-through;
    color: var(--text-light);
    font-size: 14px;
    margin-left: 8px;
    font-weight: 400;
}

.product-rating {
    color: #ffc107;
    font-size: 14px;
    margin-bottom: 5px;
}

.product-rating .rating-count {
    color: var(--text-light);
    font-size: 13px;
    margin-left: 5px;
}

.add-to-cart {
    background: linear-gradient(135deg, var(--accent) 0%, var(--amber-light) 100%);
    color: var(--cta-ink);
    border: none;
    padding: 10px;
    width: 100%;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
    margin-top: 10px;
    transition: filter 0.2s, transform 0.15s;
    font-size: 14px;
}

.add-to-cart:hover {
    filter: brightness(1.06);
    transform: translateY(-1px);
}

.category-card {
    text-align: center;
    padding: 30px 20px;
    background: var(--surface);
    border-radius: 12px;
    box-shadow: var(--shadow);
    transition: all 0.3s;
    cursor: pointer;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.category-icon {
    font-size: 48px;
    color: var(--accent);
    margin-bottom: 15px;
}

.category-name {
    font-weight: 600;
    font-size: 18px;
    color: var(--text);
}

.category-count {
    color: var(--text-light);
    font-size: 13px;
    margin-top: 5px;
}

.featured-brands {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 40px;
    align-items: center;
    padding: 40px 0;
}

.brand-item {
    opacity: 0.6;
    filter: grayscale(100%);
    transition: all 0.3s;
    max-height: 60px;
}

.brand-item:hover {
    opacity: 1;
    filter: grayscale(0%);
}

.brand-item img {
    max-height: 50px;
}

.page-banner {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: var(--white);
    padding: 60px 0;
    text-align: center;
}

.page-banner h1 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 10px;
}

.page-banner p {
    font-size: 16px;
    opacity: 0.9;
}

.breadcrumb {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 15px;
    font-size: 14px;
}

.breadcrumb a {
    color: rgba(255,255,255,0.8);
}

.breadcrumb a:hover {
    color: var(--white);
}

.breadcrumb .separator {
    color: rgba(255,255,255,0.5);
}

.product-page-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    margin-top: 30px;
}

.product-main-image {
    width: 100%;
    border-radius: 12px;
    background: #f9f9f9;
    padding: 30px;
}

.product-main-image img {
    width: 100%;
    height: 400px;
    object-fit: contain;
}

.product-thumbnails {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.product-thumbnails img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    border: 2px solid var(--border);
    border-radius: 8px;
    cursor: pointer;
    padding: 5px;
    background: #f9f9f9;
    transition: border-color 0.3s;
}

.product-thumbnails img:hover,
.product-thumbnails img.active {
    border-color: var(--accent);
}

.product-details h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text);
}

.product-details .product-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    font-size: 14px;
    color: var(--text-light);
}

.product-details .product-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.product-details .product-meta .in-stock {
    color: var(--success);
    font-weight: 600;
}

.product-price-large {
    font-size: 36px;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 20px;
}

.product-price-large .old-price {
    font-size: 20px;
    color: var(--text-light);
    text-decoration: line-through;
    font-weight: 400;
    margin-left: 15px;
}

.product-options {
    margin-bottom: 25px;
}

.product-options label {
    display: block;
    font-weight: 500;
    margin-bottom: 8px;
    font-size: 14px;
}

.product-options select {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    outline: none;
    font-size: 14px;
    background: var(--surface);
}

.quantity-control {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.quantity-control button {
    width: 40px;
    height: 40px;
    border: 1px solid var(--border);
    background: var(--surface);
    font-size: 18px;
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.3s;
}

.quantity-control button:hover {
    background: #f0f0f0;
}

.quantity-control input {
    width: 60px;
    padding: 8px;
    text-align: center;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 16px;
    outline: none;
}

.add-to-cart-large {
    padding: 15px 40px;
    font-size: 18px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--amber-light) 100%);
    color: var(--cta-ink);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
    box-shadow: 0 10px 24px -8px rgba(245,166,35,.5);
    transition: filter 0.2s, transform 0.15s;
}

.add-to-cart-large:hover {
    filter: brightness(1.06);
    transform: translateY(-1px);
}

.wishlist-btn {
    padding: 15px 20px;
    border: 2px solid var(--border);
    background: var(--surface);
    border-radius: 8px;
    cursor: pointer;
    font-size: 18px;
    color: var(--text-light);
    transition: all 0.3s;
}

.wishlist-btn:hover {
    border-color: var(--danger);
    color: var(--danger);
}

.product-description {
    line-height: 1.8;
    color: var(--text-light);
    margin-top: 30px;
}

.product-description h3 {
    color: var(--text);
    font-size: 20px;
    margin-bottom: 15px;
}

.product-description ul {
    list-style: disc;
    padding-left: 20px;
    margin-bottom: 15px;
}

.product-description ul li {
    margin-bottom: 8px;
}

.product-tabs {
    margin-top: 60px;
}

.tab-headers {
    display: flex;
    border-bottom: 2px solid var(--border);
    gap: 0;
}

.tab-header {
    padding: 15px 30px;
    cursor: pointer;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.3s;
    background: none;
    border-top: none;
    border-left: none;
    border-right: none;
    font-size: 16px;
}

.tab-header:hover {
    color: var(--accent);
}

.tab-header.active {
    color: var(--accent);
    border-bottom-color: var(--accent);
}

.tab-content {
    display: none;
    padding: 30px 0;
}

.tab-content.active {
    display: block;
}

.cart-page {
    margin: auto;
}

.cart-content {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 30px;
    align-items: start;
}

.cart-table-wrap {
    background: var(--surface);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.cart-actions {
    margin-top: 20px;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.empty-cart {
    text-align: center;
    padding: 60px 20px;
}

.empty-cart i {
    font-size: 4rem;
    color: var(--border);
    margin-bottom: 20px;
}

.empty-cart h3 {
    color: var(--text);
    margin-bottom: 10px;
}

.empty-cart p {
    color: var(--text-light);
    margin-bottom: 25px;
}

@media (max-width: 900px) {
    .cart-content {
        grid-template-columns: 1fr;
    }
}

.cart-table {
    width: 100%;
    border-collapse: collapse;
}

.cart-table th {
    background: var(--primary);
    color: var(--white);
    padding: 12px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

.cart-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

.cart-table .product-thumb {
    width: 60px;
    height: 60px;
    object-fit: contain;
    border-radius: 8px;
    background: #f9f9f9;
    padding: 5px;
}

.cart-table .cart-product-title {
    font-weight: 500;
    color: var(--text);
}

.cart-table .cart-remove {
    color: var(--danger);
    cursor: pointer;
    background: none;
    border: none;
    font-size: 18px;
}

.cart-summary {
    margin-top: 30px;
    padding: 20px;
    background: var(--surface);
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.cart-summary .cart-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    font-size: 16px;
}

.cart-summary .cart-row.total {
    border-top: 2px solid var(--border);
    margin-top: 10px;
    padding-top: 15px;
    font-size: 24px;
    font-weight: 700;
}

.cart-summary .cart-row.total .amount {
    color: var(--accent);
}

.coupon-section {
    display: flex;
    gap: 10px;
    margin: 20px 0;
}

.coupon-section input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    outline: none;
}

.coupon-section button {
    padding: 10px 20px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

.checkout-btn {
    background: linear-gradient(135deg, var(--accent) 0%, var(--amber-light) 100%);
    color: var(--cta-ink);
    padding: 15px 40px;
    border-radius: 8px;
    font-size: 18px;
    border: none;
    cursor: pointer;
    width: 100%;
    font-weight: 700;
    box-shadow: 0 10px 24px -8px rgba(245,166,35,.5);
    transition: filter 0.2s, transform 0.15s;
}

.checkout-btn:hover {
    filter: brightness(1.06);
    transform: translateY(-1px);
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 25px;
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
}

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

.btn-outline-danger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 25px;
    background: var(--surface);
    color: var(--danger);
    border: 1px solid var(--danger);
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: filter 0.2s;
}

.btn-outline-danger:hover {
    filter: brightness(0.95);
}

.contact-form {
    max-width: 600px;
    margin: auto;
}

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

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 5px;
    font-size: 14px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    outline: none;
    font-family: inherit;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-group textarea {
    min-height: 150px;
    resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--accent);
}

.form-group .error {
    color: var(--danger);
    font-size: 13px;
    margin-top: 5px;
}

.form-group.has-error input,
.form-group.has-error textarea {
    border-color: var(--danger);
}

.submit-btn {
    background: var(--accent);
    color: var(--cta-ink);
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 16px;
    transition: background 0.3s;
}

.submit-btn:hover {
    background: var(--accent-hover);
}

.admin-layout {
    display: flex;
}

.admin-sidebar {
    width: 250px;
    background: linear-gradient(180deg, #12151E 0%, #0C0E14 100%);
    color: var(--white);
    min-height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
    overflow-y: auto;
}

.admin-sidebar .admin-logo {
    padding: 18px 20px;
    font-size: 20px;
    font-weight: 700;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    text-align: center;
}

.admin-sidebar .admin-logo a {
    color: var(--white);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-family: var(--font-en);
}

.admin-sidebar .admin-logo a svg {
    width: 26px;
    height: 26px;
    flex-shrink: 0;
}

.admin-sidebar .admin-logo span {
    color: var(--cyan);
}

.admin-sidebar .admin-user {
    padding: 15px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    font-size: 13px;
    opacity: 0.8;
}

.admin-sidebar a {
    color: var(--white);
    padding: 12px 20px;
    display: block;
    text-decoration: none;
    font-size: 14px;
    transition: background 0.3s;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.admin-sidebar a:hover {
    background: var(--secondary);
}

.admin-sidebar a i {
    width: 20px;
    margin-right: 10px;
    text-align: center;
}

.admin-sidebar a.active {
    background: var(--secondary);
    border-right: 3px solid var(--accent);
}

.admin-main {
    margin-left: 250px;
    padding: 30px;
    flex: 1;
    min-height: 100vh;
}

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

.admin-header h1 {
    font-size: 24px;
    color: var(--primary);
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--surface);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.admin-table th {
    background: var(--primary);
    color: var(--white);
    padding: 12px 15px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

.admin-table td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
    vertical-align: middle;
}

.admin-table tr:hover td {
    background: #f8f8ff;
}

.admin-table .actions {
    display: flex;
    gap: 5px;
}

.admin-form {
    max-width: 600px;
}

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

.admin-btn {
    background: var(--accent);
    color: var(--cta-ink);
    padding: 8px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.admin-btn:hover {
    background: var(--accent-hover);
}

.admin-btn-danger {
    background: var(--danger);
}

.admin-btn-danger:hover {
    background: #b71c1c;
}

.admin-btn-success {
    background: var(--success);
}

.admin-btn-success:hover {
    background: #1b5e20;
}

.admin-btn-sm {
    padding: 5px 12px;
    font-size: 12px;
}

.admin-card {
    background: var(--surface);
    border-radius: 12px;
    padding: 25px;
    box-shadow: var(--shadow);
    margin-bottom: 25px;
}

.admin-card h3 {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--primary);
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--surface);
    border-radius: 12px;
    padding: 25px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 20px;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--white);
}

.stat-icon.primary {
    background: var(--primary);
}

.stat-icon.accent {
    background: var(--accent);
}

.stat-icon.success {
    background: var(--success);
}

.stat-icon.danger {
    background: var(--danger);
}

.stat-info .stat-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--text);
}

.stat-info .stat-label {
    font-size: 14px;
    color: var(--text-light);
}

.whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #25d366;
    color: var(--white);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    z-index: 999;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.3s;
}

.whatsapp-float:hover {
    background: #20bd5a;
    color: var(--white);
}

.back-to-top {
    position: fixed;
    bottom: 90px;
    right: 20px;
    background: var(--primary);
    color: var(--white);
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 998;
    border: none;
    font-size: 20px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    transition: background 0.3s;
}

.back-to-top:hover {
    background: var(--secondary);
}

.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--success);
    color: var(--white);
    padding: 15px 25px;
    border-radius: 8px;
    z-index: 9999;
    display: none;
    animation: slideInRight 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    font-size: 14px;
    font-weight: 500;
    max-width: 350px;
}

.toast.error {
    background: var(--danger);
}

.toast.info {
    background: var(--primary);
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.loader {
    display: none;
    width: 40px;
    height: 40px;
    border: 4px solid var(--border);
    border-top: 4px solid var(--accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 40px auto;
}

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

.empty-state {
    text-align: center;
    padding: 60px 20px;
}

.empty-state i {
    font-size: 64px;
    color: var(--text-light);
    margin-bottom: 20px;
}

.empty-state h2 {
    font-size: 24px;
    color: var(--text);
    margin-bottom: 10px;
}

.empty-state p {
    color: var(--text-light);
    margin-bottom: 20px;
}

.filter-section {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    align-items: center;
}

.filter-section select {
    padding: 10px 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    outline: none;
    font-size: 14px;
    background: var(--surface);
}

.filter-section .filter-btn {
    padding: 10px 20px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
}

.filter-section .filter-btn:hover {
    background: var(--secondary);
}

.site-footer {
    background: var(--footer-bg);
    color: var(--footer-text);
    padding: 50px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 30px;
}

.site-footer h4 {
    color: var(--footer-heading);
    margin-bottom: 18px;
    font-size: 15px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.site-footer p {
    line-height: 1.8;
    font-size: 13.5px;
    color: var(--footer-text);
}

.site-footer .footer-links,
.site-footer .footer-contact {
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-footer a {
    color: var(--footer-link);
    text-decoration: none;
    display: block;
    margin-bottom: 9px;
    font-size: 13.5px;
    transition: color 0.2s;
}

.site-footer a:hover {
    color: var(--amber);
}

.footer-logo-mark .logo-word,
.footer-logo-mark .logo-sub {
    color: var(--footer-heading) !important;
}

.footer-contact li {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 9px;
    font-size: 13.5px;
    color: var(--footer-text);
}
.footer-contact li i { width: 16px; color: var(--amber); }
.footer-contact li a { margin-bottom: 0; display: inline; }

.footer-bottom {
    border-top: 1px solid var(--footer-border);
    padding-top: 20px;
    text-align: center;
    margin-top: 34px;
    font-size: 13px;
    color: var(--footer-text);
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-top: 30px;
}

.pagination a {
    padding: 8px 15px;
    border: 1px solid var(--border);
    border-radius: 5px;
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s;
}

.pagination a:hover {
    background: var(--primary);
    color: var(--white);
}

.pagination a.active {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

.pagination a.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.about-content {
    max-width: 800px;
    margin: auto;
    line-height: 1.8;
    color: var(--text-light);
}

.about-content h2 {
    color: var(--primary);
    font-size: 24px;
    margin-bottom: 15px;
    margin-top: 30px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.feature-card {
    text-align: center;
    padding: 30px;
    background: var(--surface);
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.feature-card i {
    font-size: 40px;
    color: var(--accent);
    margin-bottom: 15px;
}

.feature-card h3 {
    font-size: 18px;
    color: var(--text);
    margin-bottom: 10px;
}

.feature-card p {
    color: var(--text-light);
    font-size: 14px;
}

.checkout-page {
    max-width: 900px;
    margin: auto;
}

.checkout-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 30px;
}

.checkout-section {
    background: var(--surface);
    padding: 25px;
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

.checkout-section h3 {
    font-size: 18px;
    margin-bottom: 20px;
    color: var(--primary);
}

.order-summary-item {
    display: flex;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid var(--border);
}

.order-summary-item img {
    width: 60px;
    height: 60px;
    object-fit: contain;
    border-radius: 8px;
    background: #f9f9f9;
    padding: 5px;
}

.order-summary-item .item-details {
    flex: 1;
}

.order-summary-item .item-details h4 {
    font-size: 14px;
    font-weight: 500;
}

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

.order-total {
    padding-top: 15px;
}

.order-total .total-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 14px;
}

.order-total .total-row.grand-total {
    font-size: 20px;
    font-weight: 700;
    border-top: 2px solid var(--border);
    padding-top: 15px;
    margin-top: 10px;
}

.order-total .total-row.grand-total .amount {
    color: var(--accent);
}

.payment-methods {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.payment-method {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.3s;
}

.payment-method:hover,
.payment-method.selected {
    border-color: var(--accent);
}

.payment-method input {
    accent-color: var(--accent);
}

@media (max-width: 992px) {
    .checkout-grid {
        grid-template-columns: 1fr;
    }

    .product-page-layout {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .admin-stats {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }
}

@media (max-width: 768px) {
    .hero-grid {
        grid-template-columns: 1fr !important;
        grid-template-rows: auto !important;
        min-height: 0 !important;
    }

    .hero-grid > div[style*="grid-row: span 2"] {
        grid-row: auto !important;
        padding: 35px 25px !important;
    }

    .hamburger {
        display: flex;
    }

    .search-bar {
        display: none;
    }

    .main-nav {
        top: 0;
    }

    .nav-list {
        display: none;
        flex-direction: column;
        width: 100%;
    }

    .nav-list.active {
        display: flex;
    }

    .nav-list > li > a {
        padding: 12px 15px;
        border-bottom: 1px solid var(--border);
    }

    .nav-list .nav-dropdown .dropdown-menu {
        display: block;
        position: static;
        min-width: 100%;
        box-shadow: none;
        background: #f8f9fa;
        border-radius: 0;
    }

    .nav-list .dropdown-menu a {
        color: var(--text);
        padding: 10px 25px;
    }

    .nav-list .dropdown-menu a:hover {
        background: #eef5ff;
    }

    .hero {
        padding: 50px 0;
    }

    .hero .container {
        flex-direction: column;
        text-align: center;
    }

    .hero-content h1 {
        font-size: 32px;
    }

    .hero-content p {
        font-size: 16px;
    }

    .hero-image {
        display: none;
    }

    .section-title {
        font-size: 26px;
    }

    .grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 15px;
    }

    .top-bar .container {
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }

    .main-header {
        padding: 10px 0;
    }

    .logo {
        font-size: 22px;
    }

    .page-banner h1 {
        font-size: 28px;
    }

    .product-details h1 {
        font-size: 24px;
    }

    .product-price-large {
        font-size: 28px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .admin-sidebar {
        width: 60px;
        overflow: hidden;
    }

    .admin-sidebar .admin-logo {
        padding: 15px 10px;
        font-size: 14px;
    }

    .admin-sidebar a {
        padding: 12px 10px;
        text-align: center;
    }

    .admin-sidebar a i {
        margin-right: 0;
    }

    .admin-sidebar a span {
        display: none;
    }

    .admin-sidebar .admin-user {
        display: none;
    }

    .admin-main {
        margin-left: 60px;
        padding: 15px;
    }

    .admin-header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .admin-form .form-row {
        grid-template-columns: 1fr;
    }

    .cart-table {
        font-size: 13px;
    }

    .cart-table .product-thumb {
        width: 40px;
        height: 40px;
    }

    .cart-summary .cart-row.total {
        font-size: 20px;
    }

    .filter-section {
        flex-direction: column;
    }

    .filter-section select {
        width: 100%;
    }

    .tab-header {
        padding: 12px 15px;
        font-size: 14px;
    }

    .product-main-image img {
        height: 250px;
    }
}

@media (max-width: 480px) {
    .grid {
        grid-template-columns: 1fr;
    }

    .hero-content h1 {
        font-size: 26px;
    }

    .hero-btn {
        padding: 12px 24px;
        font-size: 14px;
    }

    .section-title {
        font-size: 22px;
    }

    .header-actions .account-link {
        display: none;
    }

    .page-banner {
        padding: 40px 0;
    }

    .page-banner h1 {
        font-size: 24px;
    }

    .breadcrumb {
        font-size: 12px;
    }
}

/* ==========================================================================
   2026-07-29 additions: header redesign, account dropdown, mobile slide nav,
   admin table-responsive, RTL/lang toggle support
   ========================================================================== */

.lang-toggle {
    display: inline-flex !important;
    align-items: center;
    gap: 5px;
}

/* Sticky header shrink-on-scroll */
.main-header {
    transition: padding 0.25s ease, box-shadow 0.25s ease;
}
.main-header.header-scrolled {
    padding: 8px 0;
    box-shadow: 0 4px 18px rgba(0,0,0,0.12);
}
.main-header.header-scrolled .logo img {
    height: 34px !important;
}

/* Search bar polish */
.search-bar {
    transition: box-shadow 0.25s ease, border-color 0.25s ease;
}
.search-bar:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(0, 115, 207, 0.12);
}

/* Dropdown menu polish */
.nav-list .nav-dropdown .dropdown-menu {
    opacity: 0;
    transform: translateY(-6px);
    visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    display: block;
    pointer-events: none;
}
.nav-list .nav-dropdown:hover .dropdown-menu {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
    pointer-events: auto;
}

/* Account dropdown */
.account-dropdown {
    position: relative;
}
.account-icon {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--primary);
    font-size: 22px;
    cursor: pointer;
}
.account-icon-logged {
    font-size: 20px;
}
.account-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.account-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--surface);
    min-width: 190px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
    border-radius: 8px;
    padding: 8px 0;
    margin-top: 12px;
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    z-index: 20;
}
.account-dropdown:hover .account-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.account-dropdown-menu li a {
    display: block;
    padding: 10px 18px;
    color: var(--text);
    font-size: 14px;
    font-weight: 500;
    transition: background 0.2s, color 0.2s;
}
.account-dropdown-menu li a i {
    width: 16px;
    margin-right: 6px;
}
.account-dropdown-menu li a:hover {
    background: #f0f7ff;
    color: var(--primary);
}

/* Mobile slide-in nav panel */
.mobile-nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1099;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.mobile-nav-overlay.active {
    display: block;
    opacity: 1;
}
.mobile-nav-close {
    display: none;
}

@media (max-width: 992px) {
    .mobile-nav-close {
        display: block;
        background: none;
        border: none;
        font-size: 28px;
        line-height: 1;
        color: var(--text);
        cursor: pointer;
        align-self: flex-end;
        padding: 10px;
        margin-bottom: 10px;
    }
    .account-name {
        display: none;
    }
    .main-nav {
        position: fixed;
        top: 0;
        right: 0;
        height: 100%;
        width: 280px;
        max-width: 85vw;
        background: var(--surface);
        z-index: 1100;
        transform: translateX(100%);
        transition: transform 0.3s ease;
        overflow-y: auto;
        border-bottom: none;
        box-shadow: -8px 0 30px rgba(0,0,0,0.15);
    }
    .main-nav.active {
        transform: translateX(0);
    }
    .main-nav .container {
        display: flex;
        flex-direction: column;
        padding: 15px;
        width: 100%;
    }
    .nav-list {
        display: flex !important;
    }
}

/* Admin: responsive table wrapper so action buttons stay reachable on mobile */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.table-responsive .admin-table {
    min-width: 720px;
}

/* ==========================================================================
   2026-07-29b: header redesign v2 (logo breathing room, wide integrated
   search bar, nav phone number), stock badge, admin table fit-to-width
   ========================================================================== */

.main-header { padding: 20px 0; }
.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 30px;
}
.logo img { height: 50px; width: auto; display: block; }
.main-header.header-scrolled { padding: 10px 0; }
.main-header.header-scrolled .logo img { height: 38px !important; }

.search-bar {
    flex: 1 1 auto;
    max-width: 640px;
    width: 100%;
    position: relative;
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    background: var(--surface);
    overflow: visible;
}
.search-bar form {
    display: flex;
    align-items: stretch;
    width: 100%;
}
.search-bar-icon {
    position: absolute;
    inset-inline-start: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    font-size: 15px;
    pointer-events: none;
}
.search-bar input {
    padding-block: 13px;
    padding-inline-start: 42px;
    padding-inline-end: 14px;
    font-size: 15px;
    border-start-start-radius: 10px;
    border-end-start-radius: 10px;
    width: 100%;
}
.search-bar button {
    display: flex;
    align-items: center;
    gap: 7px;
    padding-inline: 22px;
    border-start-end-radius: 10px;
    border-end-end-radius: 10px;
    font-weight: 600;
    white-space: nowrap;
}

.header-actions { gap: 26px; }

.main-nav .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}
.nav-phone {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-weight: 700;
    font-size: 14px;
    white-space: nowrap;
    text-decoration: none;
}
.nav-phone i { color: var(--accent); }

@media (max-width: 992px) {
    .search-bar { max-width: none; }
    .nav-phone { display: none; }
    .main-nav .container { justify-content: flex-start; }
}

@media (max-width: 768px) {
    .main-header { padding: 14px 0; }
    .header-content { gap: 14px; }
    .logo img { height: 36px; }
    .search-bar input { padding-inline-start: 38px; padding-block: 10px; font-size: 14px; }
    .search-bar button span { display: none; }
    .search-bar button { padding-inline: 14px; }
}

/* Storefront stock badge (customer-facing pages only — admin keeps numeric stock) */
.stock-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
}
.stock-badge.in-stock { background: #d4edda; color: #155724; }
.stock-badge.out-stock { background: #f8d7da; color: #721c24; }

/* Admin products table: fit-to-width, no horizontal scroll.
   admin-main is a flex:1 item, which by default refuses to shrink below its
   content's intrinsic (min-content) width — a long nowrap product name would
   otherwise balloon the whole layout. min-width:0 lets it shrink properly so
   table-layout:fixed + colgroup can actually take effect. */
.admin-main { min-width: 0; }
.admin-table-fit {
    table-layout: fixed;
    width: 100%;
    min-width: 0;
}
.admin-table-fit .cell-product { min-width: 0; }
.admin-table-fit .cell-product-meta { min-width: 0; }
.admin-table-fit th,
.admin-table-fit td {
    padding: 9px 10px;
    overflow: hidden;
}
.thumb-tbl {
    width: 38px;
    height: 38px;
    object-fit: cover;
    border-radius: 5px;
    border: 1px solid var(--border);
    display: block;
}
.cell-product-name {
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.cell-product-meta {
    display: flex;
    gap: 8px;
    margin-top: 3px;
    font-size: 11px;
    color: var(--text-light);
    overflow: hidden;
}
.cell-sku {
    white-space: nowrap;
    flex-shrink: 0;
}
.cell-sku::after { content: '\2022'; margin-inline-start: 8px; }
.cell-cat {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.cell-price, .cell-stock {
    font-size: 13px;
    white-space: nowrap;
}
.admin-table-fit .actions { display: block; }
.row-actions-menu { position: relative; display: inline-block; }
.row-actions-toggle { width: 32px; padding: 6px 0; }
.row-actions-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    inset-inline-end: 0;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: 0 8px 22px rgba(0,0,0,0.15);
    min-width: 130px;
    z-index: 30;
    padding: 6px 0;
    margin-top: 4px;
}
.row-actions-dropdown.open { display: block; }
.row-actions-dropdown a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    font-size: 13px;
    color: var(--text);
    text-decoration: none;
}
.row-actions-dropdown a:hover { background: #f0f7ff; }
.row-actions-dropdown a.danger-link { color: var(--danger, #dc3545); }

@media (max-width: 900px) {
    .cell-sku { display: none; }
    .cell-sku::after { content: none; }
}

/* Product description rich content (scraped tables/lists/links) */
.product-description-body h3,
.product-description-body h4,
.product-description-body h5 {
    color: var(--text);
    margin: 22px 0 10px;
    font-size: 1.05rem;
    font-weight: 700;
}
.product-description-body h3:first-child,
.product-description-body h4:first-child,
.product-description-body h5:first-child { margin-top: 0; }
.product-description-body p { margin: 0 0 14px; }
.product-description-body ul,
.product-description-body ol { margin: 0 0 16px; padding-inline-start: 22px; }
.product-description-body li { margin-bottom: 6px; }
.product-description-body a { color: var(--secondary); text-decoration: underline; }
.product-description-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 0 20px;
    font-size: 0.92rem;
}
.product-description-body th,
.product-description-body td {
    border: 1px solid var(--border);
    padding: 8px 12px;
    text-align: start;
}
.product-description-body th {
    background: var(--surface-container-low, #f2f4f5);
    font-weight: 600;
}
.product-description-body table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* ===== Home page rebuild additions ===== */
.hero-new {
    position: relative;
    overflow: hidden;
    padding: clamp(44px,7vw,84px) 0 clamp(36px,5vw,60px);
    background:
        radial-gradient(60% 90% at 85% 0%, color-mix(in srgb, var(--violet) 16%, transparent), transparent 70%),
        radial-gradient(50% 70% at 0% 100%, color-mix(in srgb, var(--cyan) 12%, transparent), transparent 70%),
        var(--surface);
    border-bottom: 1px solid var(--border);
}
.hero-new .container { display: grid; grid-template-columns: 1.05fr .95fr; gap: 44px; align-items: center; }
@media (max-width: 880px) { .hero-new .container { grid-template-columns: 1fr; } }
.hero-eyebrow {
    font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
    color: var(--primary); display: flex; align-items: center; gap: 8px; margin-bottom: 14px;
}
.hero-eyebrow::before { content: ""; width: 18px; height: 2px; background: currentColor; border-radius: 2px; }
.hero-new h1 { font-family: var(--font-en); font-size: clamp(30px,4.4vw,50px); font-weight: 800; line-height: 1.1; letter-spacing: -0.02em; margin-bottom: 16px; }
.hero-new h1 .grad { background: linear-gradient(100deg, var(--blue), var(--violet) 60%, var(--cyan)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-new p.lede { font-size: 16px; color: var(--text-light); max-width: 48ch; margin-bottom: 26px; }
.hero-cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.trust-row { display: flex; gap: 26px; margin-top: 30px; flex-wrap: wrap; font-family: var(--font-en); }
.trust-row b { display: block; font-size: 20px; font-weight: 800; color: var(--text); }
.trust-row span { font-size: 11.5px; color: var(--text-light); }
.hero-visual { border-radius: 20px; border: 1px solid var(--border); background: var(--surface); aspect-ratio: 1/.86; position: relative; overflow: hidden; }
.hero-visual canvas { width: 100%; height: 100%; display: block; }
.hero-visual .live-chip { position: absolute; bottom: 14px; inset-inline-start: 14px; background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 6px 11px; font-family: var(--font-en); font-size: 11px; color: var(--text-light); display: flex; align-items: center; gap: 6px; }
.hero-visual .live-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 0 3px color-mix(in srgb, var(--cyan) 25%, transparent); }

.chip-row { display: flex; gap: 10px; flex-wrap: wrap; }
.chip { font-size: 13px; font-weight: 600; padding: 10px 16px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text); text-decoration: none; transition: border-color .15s, color .15s; }
.chip:hover { border-color: var(--primary); color: var(--primary); }

.section-head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 24px; gap: 16px; flex-wrap: wrap; }
.section-head h2 { font-family: var(--font-en); font-size: clamp(20px,2.6vw,28px); font-weight: 800; color: var(--text); margin: 0; }
.section-head .see-all { font-size: 12.5px; font-weight: 700; color: var(--primary); text-decoration: none; font-family: var(--font-en); white-space: nowrap; }

.btn-add-cart {
    width: 100%; padding: 11px; border: none; border-radius: 10px; cursor: pointer;
    font-size: 13.5px; font-weight: 700; font-family: var(--font-en);
    background: linear-gradient(135deg, var(--amber) 0%, var(--amber-light) 100%);
    color: var(--cta-ink); transition: filter .15s, transform .1s;
}
.btn-add-cart:hover { filter: brightness(1.05); }
.btn-add-cart:active { transform: translateY(1px); }

.stat-strip { display: grid; grid-template-columns: repeat(4,1fr); gap: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 24px; }
@media (max-width: 760px) { .stat-strip { grid-template-columns: repeat(2,1fr); } }
.stat-strip .stat b { display: block; font-family: var(--font-en); font-size: 24px; font-weight: 800; color: var(--primary); }
.stat-strip .stat span { font-size: 12px; color: var(--text-light); }

/* ===== Listing page rebuild additions ===== */
.page-head-band { background: linear-gradient(135deg, var(--blue), var(--violet)); color: #fff; padding: 40px 0; }
.page-head-band h1 { font-family: var(--font-en); font-size: 26px; font-weight: 800; margin: 0; }
.page-head-band p { opacity: .85; font-size: 13.5px; margin-top: 6px; }

.listing-layout { display: grid; grid-template-columns: 250px 1fr; gap: 26px; align-items: start; }
@media (max-width: 860px) { .listing-layout { grid-template-columns: 1fr; } }
.filter-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 18px; position: sticky; top: 96px; }
.filter-card h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-light); margin: 0 0 12px; }
.filter-card ul { list-style: none; margin: 0; padding: 0; }
.filter-card li { margin-bottom: 4px; }
.filter-card a { display: block; padding: 8px 10px; border-radius: 8px; color: var(--text); text-decoration: none; font-size: 13.5px; }
.filter-card a:hover { background: var(--bg); }
.filter-card a.active { background: linear-gradient(135deg, var(--amber), var(--amber-light)); color: var(--cta-ink); font-weight: 700; }

.toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; flex-wrap: wrap; gap: 12px; }
.toolbar .count { color: var(--text-light); font-size: 13px; }
.sort-select { padding: 9px 12px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); color: var(--text); font-size: 13px; }

.pagination { display: flex; justify-content: center; gap: 6px; margin-top: 36px; flex-wrap: wrap; align-items: center; }
.pagination a, .pagination span.ellipsis { padding: 9px 14px; border: 1px solid var(--border); border-radius: 9px; text-decoration: none; color: var(--text); font-family: var(--font-en); font-size: 13px; }
.pagination a:hover { border-color: var(--primary); color: var(--primary); }
.pagination a.active { background: linear-gradient(135deg, var(--amber), var(--amber-light)); color: var(--cta-ink); border-color: transparent; font-weight: 700; }
.pagination span.ellipsis { border: none; color: var(--text-light); padding-inline: 4px; }

.empty-state { text-align: center; padding: 70px 20px; color: var(--text-light); }
.empty-state i { font-size: 44px; color: var(--border); margin-bottom: 16px; display: block; }

/* ===== Categories page ===== */
.cat-tile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px,1fr)); gap: 16px; }
.cat-tile { display: flex; justify-content: space-between; align-items: center; padding: 18px 22px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; text-decoration: none; transition: border-color .15s, transform .15s; }
.cat-tile:hover { border-color: var(--primary); transform: translateY(-2px); }
.cat-tile .cat-name { display: flex; align-items: center; gap: 14px; font-weight: 700; color: var(--text); font-size: 13.5px; }
.cat-tile .cat-icon { width: 22px; height: 22px; }
.cat-tile .cat-count { color: var(--text-light); font-size: 12px; white-space: nowrap; font-family: var(--font-en); }

/* ===== Search page ===== */
.search-page-form { display: flex; gap: 10px; margin-bottom: 24px; }
.search-page-form input { flex: 1; padding: 12px 16px; border: 1px solid var(--border); border-radius: 999px; font-size: 13.5px; background: var(--surface); color: var(--text); }
.search-page-form input:focus { outline: none; border-color: var(--primary); }
.search-page-form button { padding: 12px 26px; background: linear-gradient(135deg, var(--blue), var(--violet)); color: #fff; border: none; border-radius: 999px; cursor: pointer; font-weight: 700; font-size: 13.5px; }

/* ===== Content page (about, etc.) ===== */
.content-page { max-width: 800px; margin: 0 auto; }
.content-page h2 { font-family: var(--font-en); font-size: 22px; font-weight: 800; color: var(--text); margin-bottom: 14px; }
.content-page p { line-height: 1.85; color: var(--text-light); font-size: 14.5px; margin-bottom: 18px; }

/* ===== Alerts ===== */
.alert { border-radius: 12px; padding: 16px 18px; margin-bottom: 22px; font-size: 13.5px; }
.alert ul { list-style: none; margin: 0; padding: 0; }
.alert li { padding: 2px 0; }
.alert-success { background: color-mix(in srgb, var(--success) 12%, var(--surface)); color: var(--success); border: 1px solid color-mix(in srgb, var(--success) 30%, transparent); text-align: center; }
.alert-success i { font-size: 30px; display: block; margin-bottom: 8px; }
.alert-success h3 { margin: 0 0 4px; font-size: 16px; }
.alert-danger { background: color-mix(in srgb, var(--danger) 10%, var(--surface)); color: var(--danger); border: 1px solid color-mix(in srgb, var(--danger) 30%, transparent); }

/* ===== Auth pages (login / register) ===== */
.auth-page { padding: 48px 0; }
.auth-card { max-width: 420px; margin: 0 auto; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 34px; box-shadow: var(--shadow); }
.auth-card.auth-card-wide { max-width: 480px; }
.auth-card .btn-add-cart { padding: 13px; font-size: 14px; }
.auth-divider { text-align: center; margin: 20px 0; color: var(--text-light); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.oauth-group { display: flex; flex-direction: column; gap: 10px; }
.oauth-btn { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 12px; border: 1px solid var(--border); border-radius: 10px; text-decoration: none; color: var(--text); font-weight: 600; font-size: 13.5px; background: var(--surface); transition: border-color .15s; }
.oauth-btn:hover { border-color: var(--primary); }
.oauth-google i { color: #DB4437; }
.oauth-facebook i { color: #1877F2; }
.auth-switch { text-align: center; margin-top: 20px; color: var(--text-light); font-size: 13px; }
.auth-switch a { color: var(--primary); font-weight: 700; text-decoration: none; }

/* ===== Account pages ===== */
.account-page { padding: 40px 0; }
.account-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 30px; box-shadow: var(--shadow); margin-bottom: 22px; }
.account-head { display: flex; align-items: center; gap: 18px; margin-bottom: 22px; padding-bottom: 22px; border-bottom: 1px solid var(--border); }
.account-avatar { width: 64px; height: 64px; border-radius: 50%; background: linear-gradient(135deg, var(--blue), var(--violet)); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 1.6rem; font-weight: 800; flex-shrink: 0; }
.account-head h2 { margin: 0 0 4px; font-size: 18px; color: var(--text); }
.account-head p { margin: 0; color: var(--text-light); font-size: 13.5px; }
.account-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 14px; margin-bottom: 22px; }
.account-stats .stat { background: var(--bg); border-radius: 12px; padding: 16px; text-align: center; }
.account-stats .stat b { display: block; font-size: 22px; font-weight: 800; color: var(--primary); font-family: var(--font-en); }
.account-stats .stat span { color: var(--text-light); font-size: 12px; }
.account-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.account-contact p { margin: 0; color: var(--text-light); font-size: 13.5px; }
.account-contact i { width: 18px; color: var(--primary); }
.back-link { display: inline-flex; align-items: center; gap: 6px; color: var(--primary); text-decoration: none; font-weight: 600; font-size: 13.5px; margin-bottom: 18px; }

/* ===== Orders list & detail ===== */
.order-list { display: flex; flex-direction: column; gap: 14px; }
.order-row { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 18px 22px; text-decoration: none; color: inherit; transition: border-color .15s; }
.order-row:hover { border-color: var(--primary); }
.order-row .order-no { font-weight: 700; color: var(--text); font-size: 14px; }
.order-row .order-date { color: var(--text-light); font-size: 12.5px; margin-top: 3px; }
.order-row .order-meta { display: flex; align-items: center; gap: 18px; }
.order-row .order-amount { color: var(--primary); font-weight: 800; }
.order-status { padding: 5px 14px; border-radius: 999px; font-size: 11.5px; font-weight: 700; text-transform: capitalize; }
.order-status-pending { background: #fff3cd; color: #856404; }
.order-status-confirmed, .order-status-processing { background: #d1ecf1; color: #0c5460; }
.order-status-shipped { background: #cfe2ff; color: #084298; }
.order-status-delivered { background: #d4edda; color: #155724; }
.order-status-cancelled { background: #f8d7da; color: #721c24; }
.order-detail-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 28px; box-shadow: var(--shadow); margin-bottom: 22px; }
.order-detail-card h3 { font-size: 16px; margin-bottom: 14px; color: var(--text); }
.order-line { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 13.5px; }
.order-line:last-of-type { border-bottom: none; }
.order-line-total { display: flex; justify-content: space-between; padding-top: 16px; margin-top: 10px; border-top: 2px solid var(--border); font-size: 18px; font-weight: 800; }
.order-line-total span:last-child { color: var(--primary); }
.order-ship p { margin: 0; color: var(--text-light); line-height: 1.9; font-size: 13.5px; }

/* ===== Contact page ===== */
.contact-content { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
@media (max-width: 820px) { .contact-content { grid-template-columns: 1fr; } }
.contact-content h3 { font-size: 17px; color: var(--text); margin-bottom: 20px; }
.info-item { display: flex; gap: 14px; margin-bottom: 22px; }
.info-item i { font-size: 18px; color: var(--primary); width: 22px; text-align: center; margin-top: 2px; }
.info-item h4 { margin: 0 0 4px; color: var(--text); font-size: 13.5px; }
.info-item p { margin: 0; color: var(--text-light); font-size: 13.5px; }
.map-container { border-radius: 12px; overflow: hidden; border: 1px solid var(--border); }
.map-container iframe { display: block; border: 0; width: 100%; }
.contact-form-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 28px; box-shadow: var(--shadow); }
.contact-form-card h3 { padding-bottom: 14px; border-bottom: 1px solid var(--border); margin-bottom: 20px; }
.required-mark { color: var(--danger); }

/* ===== Theme toggle button ===== */
.theme-toggle-btn {
    width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--header-border);
    background: var(--bg); color: var(--text); display: flex; align-items: center; justify-content: center;
    cursor: pointer; flex-shrink: 0; transition: border-color .15s, color .15s;
}
.theme-toggle-btn:hover { border-color: var(--primary); color: var(--primary); }
.theme-toggle-btn .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle-btn .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle-btn .icon-moon { display: block; }

/* ===== Product page breadcrumb bar (replaces the oversized gradient band) ===== */
.product-crumb-bar { background: var(--surface); border-bottom: 1px solid var(--border); padding: 12px 0; }
.product-crumb-bar a { color: var(--text-light); text-decoration: none; font-size: 13px; display: inline-flex; align-items: center; gap: 6px; }
.product-crumb-bar a:hover { color: var(--primary); }
