﻿:root {
    --radius: 0.375rem;
    --background: oklch(0.982 0.008 85);
    --foreground: oklch(0.29 0.035 48);
    --card: oklch(0.971 0.013 78);
    --card-foreground: var(--foreground);
    --popover: var(--background);
    --popover-foreground: var(--foreground);
    --primary: oklch(0.34 0.047 48);
    --primary-foreground: oklch(0.985 0.008 85);
    --secondary: oklch(0.95 0.014 85);
    --secondary-foreground: var(--foreground);
    --muted: oklch(0.955 0.009 85);
    --muted-foreground: oklch(0.49 0.032 48);
    --accent: oklch(0.91 0.031 14);
    --accent-foreground: var(--foreground);
    --destructive: oklch(0.53 0.13 35);
    --destructive-foreground: var(--primary-foreground);
    --border: oklch(0.82 0.035 65);
    --input: var(--border);
    --ring: var(--primary);
    --sale: oklch(0.54 0.115 38);
    --sale-foreground: oklch(0.985 0.009 85);
    --photo: oklch(0.94 0.008 85);
    --overlay: oklch(0.2 0.03 48 / 75%);
    --stitch: oklch(0.77 0.046 65);
    --shadow-card-hover: 0 5px 18px oklch(0.34 0.047 48 / 10%);
}
.product-card[hidden] {
    display: none !important;
}
/* Full-width boutique bands; only the repeated products are framed. */
.store-container {
    width: 100%;
    padding-inline: 40px;
}
.store-logo {
    width: 90px;
    height: auto;
    display: block;
}

.store-header {
    border-bottom: 1px solid var(--border);
}

.store-brand-row {
    padding-block: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.wordmark {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 38px;
    line-height: 1.25;
}

.wordmark-dot {
    color: var(--sale);
}

.brand-caption {
    font-size: 9px;
    margin-top: 2px;
}

.header-note {
    font-size: 13px;
    color: var(--muted-foreground);
    text-align: end;
}

.eyebrow {
    font-size: 11px;
    font-weight: 500;
}
/* Right drawer retains the boutique tokens and nested Arabic navigation. */
.store-menu-sheet {
    width: min(380px, calc(100vw - 24px));
    max-width: none;
    overflow-y: auto;
}

.store-navigation {
    margin-top: 28px;
    padding-inline: 0;
}

.navigation-items {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.navigation-split {
    display: flex;
    border-bottom: 1px dashed var(--stitch);
}

.navigation-all,
.navigation-name {
    height: 48px;
    justify-content: flex-start;
    font-size: 16px;
}

.navigation-name {
    flex: 1;
}

.navigation-chevron {
    width: 44px;
    height: 48px;
    flex: none;
}

    .navigation-chevron svg {
        transition: transform 180ms;
    }

.navigation-split[data-active="true"],
.navigation-all[data-active="true"] {
    color: var(--primary);
    background: var(--accent);
}

.navigation-children:not([hidden]) {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 12px;
    padding-inline-start: 16px;
    border-inline-start: 1px dashed var(--stitch);
}

.navigation-children button {
    justify-content: flex-start;
    min-height: 44px;
}

.navigation-children [data-active="true"] {
    background: var(--accent);
    color: var(--accent-foreground);
}

.catalog-count {
    padding-block: 16px;
    font-size: 12px;
    color: var(--muted-foreground);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    align-items: stretch;
    grid-auto-rows: 1fr;
    gap: 24px;
}

.product-card {
    min-width: 0;
    display: flex;
    flex-direction: column;
    height: 100%;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 200ms;
}

    .product-card:hover {
        box-shadow: var(--shadow-card-hover);
    }

.product-photo {
    position: relative;
    aspect-ratio: 4 / 4.5;
    overflow: hidden;
    background: var(--photo);
    flex: none;
}

    .product-photo img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 500ms;
    }

    .product-photo:hover img {
        transform: scale(1.025);
    }

.discount-badge {
    position: absolute;
    top: 12px;
    inset-inline-start: 12px;
    background: var(--sale);
    color: var(--sale-foreground);
    padding: 5px 8px;
    font-size: 10px;
    border-radius: 4px;
}

.photo-index {
    position: absolute;
    bottom: 12px;
    inset-inline-end: 12px;
    background: var(--card);
    padding: 5px 8px;
    font-size: 9px;
}

.product-card-body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.product-name {
    font-size: 19px;
    line-height: 1.65;
    height: 3.3em;
    margin-top: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card-pricing {
    margin-block: 10px 16px;
}

.card-price-slot {
    display: grid;
    grid-template-rows: 24px 20px;
    align-items: center;
    height: 44px;
}

.product-price {
    font-size: 14px;
    font-weight: 500;
}

.product-old-price {
    color: var(--muted-foreground);
    font-weight: 400;
    font-size: 12px;
}

.product-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 7px;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px dashed var(--stitch);
}

.store-contact-button {
    height: 40px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.store-detail-button {
    height: 36px;
    font-size: 12px;
    border: 1px solid var(--border);
    border-radius: 4px;
}

.store-footer {
    border-top: 1px dashed var(--stitch);
    padding-block: 24px;
}

.details-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
    gap: 80px;
    padding-block: 20px 70px;
}

.gallery-main {
    position: relative;
    aspect-ratio: 1;
    background: var(--photo);
    overflow: hidden;
    border-radius: 3px;
}

    .gallery-main img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.gallery-controls {
    position: absolute;
    bottom: 18px;
    left: 18px;
    right: 18px;
    display: flex;
    justify-content: space-between;
}

.gallery-thumbnails {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 12px;
}

.gallery-thumbnail {
    aspect-ratio: 1.4;
    height: auto;
    padding: 0;
    overflow: hidden;
    border: 2px solid transparent;
    border-radius: 3px;
}

    .gallery-thumbnail[data-active="true"] {
        border-color: var(--primary);
    }

    .gallery-thumbnail img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.details-title {
    font-size: 40px;
    line-height: 1.5;
    margin-block: 16px 22px;
}

.detail-price {
    font-size: 24px;
}

.detail-sale {
    display: inline-flex;
    font-size: 11px;
    color: var(--sale);
    background: var(--secondary);
    padding: 5px 8px;
}

.detail-section {
    border-top: 1px solid var(--border);
    padding-block: 22px;
}

    .detail-section h2 {
        font-size: 22px;
        margin-bottom: 12px;
    }

.detail-description {
    color: var(--muted-foreground);
    font-size: 14px;
    line-height: 1.8;
}

.spec-row {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 16px;
    padding-block: 8px;
    font-size: 12px;
}

.zoom-content {
    max-width: min(920px, calc(100vw - 24px));
    border-radius: 4px;
}

.zoom-photo {
    width: 100%;
    max-height: 75vh;
    object-fit: contain;
}

@media (max-width: 1023px) {
    .store-container {
        padding-inline: 24px;
    }

    .product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 18px;
    }

    .details-layout {
        gap: 32px;
    }
}

@media (max-width: 767px) {
    .store-container {
        padding-inline: 12px;
    }

    .store-brand-row {
        padding-block: 12px;
    }

    .wordmark {
        font-size: 32px;
    }

    .header-note {
        font-size: 12px;
    }

    .navigation-items {
        gap: 18px;
    }

    .navigation-all,
    .navigation-name {
        font-size: 13px;
        padding-inline: 6px;
    }

    .navigation-children:not([hidden]) {
        gap: 4px 8px;
    }

    .navigation-children button {
        font-size: 12px;
        padding-inline: 8px;
    }

    .product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .product-card-body {
        padding: 10px;
    }

    .product-name {
        font-size: 15px;
    }

    .product-price {
        font-size: 11px;
    }

    .product-old-price {
        font-size: 10px;
    }

    .store-contact-button,
    .store-detail-button {
        font-size: 10px;
        gap: 4px;
        padding-inline: 2px;
    }

        .store-contact-button svg {
            width: 12px;
            height: 12px;
        }

    .discount-badge {
        top: 8px;
        inset-inline-start: 8px;
    }

    .photo-index {
        bottom: 8px;
        inset-inline-end: 8px;
    }

    .details-layout {
        grid-template-columns: 1fr;
        gap: 28px;
        padding-block: 8px 40px;
    }

    .details-title {
        font-size: 30px;
    }

    .store-footer {
        padding-block: 20px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}

.product-price,
.product-old-price {
    unicode-bidi: isolate;
}

.catalog-title,
.details-title,
.product-name {
    overflow-wrap: anywhere;
}

.category-tab {
    gap: 6px;
}

.sort-select {
    min-width: 0;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--background);
    color: var(--foreground);
    font-family: Tahoma, Arial, sans-serif;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font: inherit;
    color: inherit;
    cursor: pointer;
    border: 0;
    background: transparent;
}

button,
a {
    touch-action: manipulation;
}

    button:focus-visible,
    a:focus-visible {
        outline: 2px solid var(--sale);
        outline-offset: 3px;
    }

img {
    display: block;
    max-width: 100%;
}

[hidden] {
    display: none !important;
}

.brand-caption {
    text-align: center;
    letter-spacing: 3px;
}

.header-note {
    line-height: 1.8;
}

.menu-button {
    font-size: 27px;
    width: 44px;
    height: 44px;
}

.store-detail-button {
    display: flex;
    justify-content: center;
    align-items: center;
}

.store-contact-button {
    background: var(--primary);
    color: var(--primary-foreground);
    padding: 8px;
}

.wide {
    width: 100%;
    height: 48px;
}

.product-name {
    font-weight: 500;
    margin-bottom: 0;
}

.product-photo {
    display: block;
}

.store-footer {
    color: var(--muted-foreground);
    font-size: 12px;
}

.muted {
    font-size: 12px;
    color: var(--muted-foreground);
    line-height: 1.8;
    margin-top: 12px;
}

.gallery-main {
    display: block;
    width: 100%;
    padding: 0;
}

.back {
    display: inline-block;
    margin-block: 22px;
}

.store-menu-sheet {
    position: fixed;
    inset: 0 0 0 auto;
    margin: 0;
    height: 100dvh;
    max-height: 100dvh;
    border: 0;
    border-inline-start: 1px solid var(--border);
    padding: 28px 20px;
    background: var(--background);
    color: var(--foreground);
}

dialog::backdrop {
    background: var(--overlay);
}

dialog:not(.store-menu-sheet) {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--background);
    color: var(--foreground);
    max-width: min(90vw, 850px);
    padding: 24px;
}

dialog[open] {
    animation: appear 0.15s ease-out;
}

.dialog-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.close {
    font-size: 28px;
    width: 44px;
    height: 44px;
}

.navigation-items {
    margin-top: 24px;
}

.navigation-all,
.navigation-name,
.navigation-children button {
    text-align: right;
    padding: 12px;
    width: 100%;
}

.navigation-children {
    margin-bottom: 12px;
}

    .navigation-name[data-active="true"],
    .navigation-all[data-active="true"],
    .navigation-children button[data-active="true"] {
        background: var(--accent);
    }

.navigation-chevron[aria-expanded="true"] {
    transform: rotate(180deg);
}

.zoom-photo {
    max-height: 75vh;
}

.detail-section {
    margin-top: 20px;
}

body:has(dialog[open]) {
    overflow: hidden;
}

@keyframes appear {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.navigation-name,
.navigation-all,
.navigation-children a {
    display: block;
    text-align: right;
    padding: 12px;
    min-height: 44px;
}

    .navigation-children a[data-active="true"] {
        background: var(--accent);
    }

a.store-contact-button {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Arabic typography and balanced product cards. */
@font-face {
    font-family: Tajawal;
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("/fonts/Tajawal-Regular.ttf") format("truetype");
}

@font-face {
    font-family: Tajawal;
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url("/fonts/Tajawal-Medium.ttf") format("truetype");
}

body {
    font-family: Tajawal, Tahoma, sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.6;
}

body,
button,
input,
select,
textarea,
.product-card .eyebrow,
.product-card .product-name,
.product-card .product-price,
.product-card .product-old-price,
.product-card .product-old-price del,
.product-card .discount-badge,
.product-card .store-contact-button,
.product-card .store-detail-button {
    font-family: "Tajawal", Tahoma, sans-serif;
}
.product-card .product-name,
.product-card .product-price {
    font-weight: 500;
}

.product-card .eyebrow,
.product-card .product-old-price,
.product-card .store-contact-button,
.product-card .store-detail-button {
    font-weight: 400;
}
.product-grid {
    grid-template-columns: repeat(auto-fill,minmax(250px,1fr));
    gap: 20px;
    grid-auto-rows: 1fr;
}

.product-card {
    width: 100%;
    max-width: 320px;
    justify-self: center;
    border-radius: 10px;
    background: #fffdf9;
    border-color: #ded4c9;
}

.product-photo {
    aspect-ratio: 1 / 1;
}

.product-card-body {
    padding: 16px;
}

.eyebrow {
    font-size: 13px;
    font-weight: 400;
    color: #76675b;
    line-height: 20px;
}

.product-name {
    font-family: inherit;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    white-space: normal;
    overflow: hidden;
    font-size: 19px;
    font-weight: 500;
    line-height: 25px;
    height: 50px;
    margin: 5px 0 0;
    color: #3d3028;
}

.product-card-pricing {
    margin: 4px 0 12px;
}

.card-price-slot {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px 10px;
    min-height: 26px;
    height: auto;
}

.product-price {
    font-size: 17px;
    font-weight: 500;
    line-height: 26px;
    color: #554333;
}

.product-old-price {
    font-size: 14px;
    font-weight: 400;
    line-height: 22px;
    color: #76675b;
}

    .product-old-price:empty {
        display: none;
    }

.product-actions {
    gap: 8px;
    padding-top: 12px;
}

.store-contact-button, .store-detail-button {
    font-size: 15px;
    font-weight: 400;
    min-height: 44px;
    height: auto;
    line-height: 22px;
    padding: 10px 6px;
    border-radius: 6px;
}

.discount-badge {
    font-size: 13px;
    font-weight: 500;
    padding: 4px 9px;
}

.details-title {
    font-family: inherit;
    font-size: 30px;
    font-weight: 500;
}

.details-layout .product-price {
    font-size: 22px;
}

.detail-description {
    font-size: 17px;
}

.detail-section h2 {
    font-size: 22px;
    font-weight: 500;
}

.spec-row {
    font-size: 16px;
}

    .spec-row strong {
        font-weight: 500;
    }

.navigation-name, .navigation-all, .navigation-children a {
    font-size: 17px;
    font-weight: 400;
}

@media (min-width: 2000px) {
    .product-grid {
        grid-template-columns: repeat(auto-fill,minmax(250px,300px));
        justify-content: start;
    }
}

@media (max-width: 767px) {
    .product-grid {
        grid-template-columns: repeat(2,minmax(0,1fr));
        gap: 12px;
    }

    .product-card {
        max-width: none;
    }

    .product-card-body {
        padding: 12px;
    }

    .product-name {
        font-size: 17px;
        line-height: 24px;
        height: 48px;
    }

    .product-price {
        font-size: 16px;
    }

    .product-old-price {
        font-size: 13px;
    }

    .card-price-slot {
        min-height: 48px;
        align-content: start;
        gap: 0 8px;
    }

    .store-contact-button, .store-detail-button {
        font-size: 14px;
        min-height: 44px;
    }
}

@media (max-width: 359px) {
    .product-grid {
        grid-template-columns: 1fr;
    }

    .product-card {
        max-width: 300px;
    }
}

/* Sidebar HTML; native details expand each category without JavaScript. */
.store-sidebar {
    position: fixed;
    inset: 0 0 0 auto;
    width: 300px;
    max-width: 90vw;
    height: 100dvh;
    overflow-y: auto;
    z-index: 101;
    background: #faf7f2;
    padding: 24px 18px;
    border-left: 1px solid #ded4c9
}

.menu-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(40,30,22,.35);
    z-index: 100;
    border: 0;
    width: 100%;
    height: 100%
}

.menu-is-open {
    overflow: hidden
}

.sidebar-navigation {
    margin-top: 10px;
    direction: rtl;
}

.menu-category {
    border-bottom: 1px solid #e5dbcf
}

.menu-category summary {
    padding: 14px 12px;
    cursor: pointer;
    font-size: 17px;
    font-weight: 400
}

.menu-link {
    display: block;
    padding: 10px;
    color: inherit;
    text-decoration: none;
    width: 100%;
    text-align: start;
}

.submenu {
    margin: 0 12px 12px 0;
    padding-right: 12px;
    border-right: 1px solid #d8c7b5
}

    .submenu a {
        font-size: 15px
    }

.menu-link:hover, .menu-category summary:hover {
    background: #eee5db
}
.product-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom:6px;
}

    .product-badges .discount-badge,
    .product-badges .stock-badge {
        position: static;
        display: inline-flex;
        align-items: center;
        padding: 4px 10px;
        border-radius: 6px;
        font-size: 12px;
        font-weight: 500;
    }

    .product-badges .discount-badge {
        background: #fee2e2;
        color: #b91c1c;
    }

    .product-badges .stock-badge {
        background: #dcfce7;
        color: #15803d;
    }

.empty-products[hidden] {
    display: none !important;
}

.empty-products {
    grid-column: 1 / -1;
    box-sizing: border-box;
    width: 100%;
    padding: 48px 20px;
    margin: 16px 0;
    text-align: center;
    font-family: "Tajawal", sans-serif;
    background: #faf7f2;
    border: 1px solid #e8ded2;
    border-radius: 20px;
}

.empty-products-icon {
    display: grid;
    place-items: center;
    width: 76px;
    height: 76px;
    margin: 0 auto 20px;
    color: #927254;
    background: #efe5d8;
    border-radius: 50%;
}

    .empty-products-icon svg {
        width: 36px;
        height: 36px;
    }

.empty-products h3 {
    margin: 0 0 10px;
    color: #594737;
    font-size: clamp(18px, 3vw, 22px);
    font-weight: 500;
    line-height: 1.5;
}

.empty-products p {
    max-width: 320px;
    margin: 0 auto 24px;
    color: #75695e;
    font-size: 15px;
    line-height: 1.8;
}

.empty-products button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 44px;
    padding: 10px 20px;
    border: 1px solid #b9cfd5;
    border-radius: 10px;
    background: #dce9ec;
    color: #334f59;
    font: inherit;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease;
}

    .empty-products button:hover {
        background: #ccdee3;
    }

    .empty-products button:focus-visible {
        outline: 3px solid #5384a7;
        outline-offset: 4px;
    }

.product-card[hidden] {
    display: none !important;
}