/* أرض الطيبة والجمال — RTL — هوية فاخرة (مستوحاة من تجارة الجمال العربية الراقية) */

:root {
    /* لوحة: وردي خمري راقٍ + ذهب شامباني */
    --color-primary: #8b3a52;
    --color-primary-dark: #6d2e42;
    --color-primary-soft: rgba(139, 58, 82, 0.12);
    --color-secondary: #7d726e;
    --color-accent: #c5a572;
    --color-accent-dark: #9d7f4a;
    --color-accent-soft: rgba(197, 165, 114, 0.2);
    --color-text: #1f1a1c;
    --color-muted: #6b6560;
    --color-border: rgba(31, 26, 28, 0.08);
    --color-bg-page: #faf7f4;
    --color-bg-page-2: #f3ebe4;
    --color-bg-card: #ffffff;
    --color-promo-bar: linear-gradient(90deg, #f5e6dc 0%, #efe0d4 50%, #f5e6dc 100%);
    --color-sidebar: #f4f0ec;
    --shadow-soft: 0 8px 32px rgba(31, 26, 28, 0.07);
    --shadow-lift: 0 14px 40px rgba(31, 26, 28, 0.1);
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 22px;
    --container-max: 1280px;
    --header-z: 40;
    --font: "IBM Plex Sans Arabic", system-ui, -apple-system, sans-serif;
    --font-display: "Cormorant Garamond", "Times New Roman", serif;
}

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

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.55;
    color: var(--color-text);
    background: radial-gradient(120% 80% at 100% 0%, rgba(197, 165, 114, 0.06), transparent 45%),
        radial-gradient(90% 60% at 0% 20%, rgba(139, 58, 82, 0.04), transparent 50%),
        var(--color-bg-page);
    min-height: 100vh;
}

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

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

ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.custom-container {
    width: 100%;
    max-width: var(--container-max);
    margin-inline: auto;
    padding-inline: 16px;
}

/* شريط العرض */
.promo-bar {
    background: var(--color-promo-bar);
    color: var(--color-primary-dark);
    font-size: 12px;
    font-weight: 700;
    text-align: center;
    padding: 12px 16px;
    position: relative;
    z-index: calc(var(--header-z) + 2);
    letter-spacing: 0.02em;
    border-bottom: 1px solid rgba(197, 165, 114, 0.25);
}

/* رأس الصفحة */
.site-header {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: relative;
    z-index: var(--header-z);
    border-bottom: 1px solid var(--color-border);
    box-shadow: 0 4px 24px rgba(31, 26, 28, 0.04);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 8px;
    padding-bottom: 8px;
}

@media (min-width: 768px) {
    .header-inner {
        padding-top: 16px;
        padding-bottom: 16px;
    }
}

.icon-btn {
    border: none;
    background: transparent;
    padding: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.mobile-menu-button {
    flex-shrink: 0;
}

@media (min-width: 640px) {
    .mobile-menu-button {
        display: none;
    }
}

.header-center {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 0;
}

.logo-link--desktop {
    display: none;
    flex-shrink: 0;
}

.logo-link--text {
    align-items: center;
    max-width: min(220px, 42vw);
}

.logo-text {
    display: block;
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--color-primary-dark);
    line-height: 1.2;
    letter-spacing: 0.04em;
}

@media (min-width: 768px) {
    .logo-text {
        font-size: 1.28rem;
    }
}

@media (min-width: 640px) {
    .logo-link--desktop {
        display: flex;
        align-items: center;
    }
}

.search-wrap {
    flex: 1;
    min-width: 0;
}

.search-field {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(139, 58, 82, 0.12);
    border-radius: 999px;
    padding: 10px 16px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 2px 12px rgba(31, 26, 28, 0.05);
    backdrop-filter: blur(6px);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search-field:focus-within {
    border-color: rgba(197, 165, 114, 0.55);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 0 0 3px var(--color-accent-soft);
}

.search-icon {
    color: var(--color-muted);
    flex-shrink: 0;
}

.search-field input {
    flex: 1;
    border: none;
    outline: none;
    font: inherit;
    background: transparent;
    min-width: 0;
}

.search-field input::placeholder {
    color: #9ca3af;
}

.header-end {
    display: none;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

@media (min-width: 768px) {
    .header-end {
        display: flex;
    }
}

.medal-icon {
    flex-shrink: 0;
}

.tagline {
    display: none;
    margin: 0;
    font-size: 18px;
    color: var(--color-text);
}

@media (min-width: 1024px) {
    .tagline {
        display: block;
    }
}

/* شريط التنقل الثابت */
.nav-sticky {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    z-index: calc(var(--header-z) - 1);
}

.nav-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    position: relative;
    min-height: 48px;
    padding-top: 4px;
    padding-bottom: 4px;
}

.mega-wrap {
    position: relative;
}

.mega-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 48px;
    padding: 0 4px;
    border: none;
    border-bottom: 3.7px solid transparent;
    background: transparent;
    font: inherit;
    font-size: 16px;
    cursor: pointer;
    color: var(--color-primary-dark);
    transition: border-color 0.2s ease, color 0.2s ease;
}

.mega-trigger:hover,
.mega-wrap:hover .mega-trigger {
    border-bottom-color: var(--color-accent);
    color: var(--color-primary);
}

.mega-chevron {
    transition: transform 0.2s ease;
}

.mega-wrap:hover .mega-chevron,
.mega-wrap.is-open .mega-chevron {
    transform: rotate(-180deg);
}

.mega-panel {
    display: none;
    position: absolute;
    top: 100%;
    inset-inline-start: 0;
    width: min(100vw - 32px, var(--container-max));
    max-height: min(80vh, 520px);
    overflow: auto;
    background: #fff;
    box-shadow: var(--shadow-soft);
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    z-index: 50;
}

@media (min-width: 1024px) {
    .mega-wrap:hover .mega-panel,
    .mega-wrap:focus-within .mega-panel {
        display: block;
    }
}

.mega-wrap.is-open .mega-panel {
    display: block;
}

.mega-grid {
    display: grid;
    grid-template-columns: 1fr;
}

@media (min-width: 900px) {
    .mega-grid {
        grid-template-columns: 220px 1fr;
        min-height: 360px;
    }
}

.mega-sidebar {
    background: var(--color-sidebar);
    padding: 8px 0;
}

.mega-cat {
    display: block;
    padding: 10px 16px;
    font-size: 14px;
    border-bottom: 1px solid #eaeaea;
}

.mega-cat:hover {
    background: #fff;
}

.mega-cat.is-active {
    background: #fff;
    color: var(--color-primary);
    font-weight: 700;
}

.mega-main {
    padding: 16px 20px 24px;
}

.mega-heading {
    margin: 0 0 12px;
    font-size: 18px;
    font-weight: 700;
}

.mega-columns {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 16px 24px;
}

.mega-col-title {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    color: var(--color-primary);
}

.mega-col ul li {
    margin-bottom: 6px;
}

.mega-col ul a {
    font-size: 13px;
    color: #555;
}

.mega-col ul a:hover {
    color: var(--color-primary);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 4px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.header-action-btn {
    display: none;
    align-items: center;
    gap: 8px;
    height: 48px;
    padding: 0 8px;
    border: none;
    border-bottom: 3px solid transparent;
    background: transparent;
    font: inherit;
    cursor: pointer;
}

@media (min-width: 768px) {
    .header-action-btn {
        display: inline-flex;
    }
}

.header-action-text {
    display: none;
}

@media (min-width: 1024px) {
    .header-action-text {
        display: inline;
    }
}

.header-icon-link {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 48px;
    padding: 0 8px;
    border-bottom: 3px solid transparent;
}

/* درج الجوال */
.drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 100;
}

.drawer-overlay.is-visible {
    display: block !important;
}

.drawer {
    position: fixed;
    top: 0;
    bottom: 0;
    inset-inline-start: 0;
    width: min(88vw, 320px);
    background: #fff;
    z-index: 101;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-soft);
    transform: translateX(100%);
    transition: transform 0.25s ease;
}

.drawer.is-open {
    transform: translateX(0);
}

.drawer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    border-bottom: 1px solid var(--color-border);
    font-weight: 700;
}

.drawer-nav {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.drawer-nav a {
    padding: 14px 16px;
    border-bottom: 1px solid #f0f0f0;
    font-size: 15px;
}

.drawer-nav a:hover {
    background: #fafafa;
}

/* المحتوى */
.main-section {
    padding-bottom: 32px;
}

.hero-section {
    padding: 6px 0 0;
}

.hero-container {
    padding-inline: 12px;
}

@media (min-width: 768px) {
    .hero-container {
        padding-inline: 16px;
    }
}

.hero-slider {
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
}

.hero-viewport {
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.hero-viewport::-webkit-scrollbar {
    display: none;
}

.hero-track {
    display: flex;
    flex-direction: row;
}

.hero-slide {
    flex: 0 0 100%;
    scroll-snap-align: start;
    min-width: 100%;
}

.hero-slide-link img {
    width: 100%;
    height: auto;
    vertical-align: middle;
    border-radius: var(--radius-xl);
}

.hero-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    width: 44px;
    height: 44px;
    border: none;
    padding: 0;
    cursor: pointer;
    background: rgba(0, 0, 0, 0.28);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
    transition: background 0.15s ease, transform 0.15s ease;
}

.hero-arrow:hover {
    background: rgba(0, 0, 0, 0.42);
}

.hero-arrow:active {
    transform: translateY(-50%) scale(0.94);
}

.hero-arrow-svg {
    display: block;
    width: 28px;
    height: 28px;
    flex-shrink: 0;
}

.hero-arrow--prev {
    inset-inline-end: 8px;
}

.hero-arrow--next {
    inset-inline-start: 8px;
}

@media (max-width: 480px) {
    .hero-arrow {
        width: 38px;
        height: 38px;
    }

    .hero-arrow-svg {
        width: 22px;
        height: 22px;
    }
}

.hero-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    padding: 10px 0 4px;
}

.hero-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    border: none;
    padding: 0;
    background: #d1d5db;
    cursor: pointer;
}

.hero-dot.is-active {
    background: linear-gradient(135deg, var(--color-accent), var(--color-accent-dark));
    transform: scale(1.15);
}

.section-block {
    margin-top: 36px;
}

.section-heading {
    margin: 0 0 18px;
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--color-primary-dark);
    position: relative;
    padding-bottom: 10px;
}

.section-heading::after {
    content: "";
    position: absolute;
    bottom: 0;
    inset-inline-start: 0;
    width: 48px;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--color-accent), transparent);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

@media (min-width: 600px) {
    .category-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 900px) {
    .category-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 16px;
    }
}

.category-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: var(--color-bg-card);
    border-radius: var(--radius-xl);
    padding: 14px 10px 16px;
    border: 1px solid var(--color-border);
    box-shadow: 0 2px 12px rgba(31, 26, 28, 0.05);
    transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}

.category-card:hover {
    box-shadow: var(--shadow-lift);
    transform: translateY(-3px) scale(1.01);
    border-color: rgba(197, 165, 114, 0.35);
}

.category-card-img-wrap {
    width: 100%;
    max-width: 120px;
    aspect-ratio: 1;
    margin-bottom: 10px;
}

.category-card-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.category-card-label {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.35;
    color: var(--color-text);
}

/* ماركات — شبكة ثابتة + شريط تمرير يعمل في RTL */
.brand-section-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.brand-section-head--text-only {
    margin-bottom: 14px;
}

.brand-section-icon {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.section-heading-inline {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 700;
}

.brand-section-head--text-only .section-heading-inline {
    font-size: 1.35rem;
}

.brand-carousel-outer {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    min-height: 140px;
}

.brand-carousel {
    display: flex;
    flex-direction: row;
    gap: 12px;
    min-width: 0;
    min-height: 120px;
    width: 100%;
    direction: ltr;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 10px 4px 14px;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x;
    align-items: center;
}

.brand-carousel:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

.brand-tile {
    flex: 0 0 auto;
    width: 100px;
    min-width: 100px;
    min-height: 104px;
    scroll-snap-align: start;
    background: #fff;
    border-radius: var(--radius-md);
    padding: 12px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-tile img {
    width: 100%;
    height: 96px;
    max-height: 96px;
    object-fit: contain;
}

.brand-nav {
    align-self: center;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--color-border);
    background: #fff;
    cursor: pointer;
    color: var(--color-text);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.brand-nav:hover:not(:disabled) {
    border-color: rgba(197, 165, 114, 0.65);
    color: var(--color-primary-dark);
    box-shadow: 0 4px 14px rgba(139, 58, 82, 0.12);
    transform: scale(1.04);
}

.brand-nav:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.brand-nav-icon {
    font-size: 1.35rem;
    line-height: 1;
    font-weight: 600;
    display: block;
    margin-top: -2px;
}

@media (max-width: 480px) {
    .brand-nav {
        width: 36px;
        height: 36px;
    }

    .brand-carousel-outer {
        gap: 6px;
    }
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* أقوى العروض — شريط منتجات */
.section-deals {
    margin-top: 32px;
    padding-bottom: 8px;
}

.section-deals-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.section-deals-title {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-primary-dark);
}

.section-deals-all {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--color-accent-dark);
    white-space: nowrap;
    transition: color 0.2s ease;
}

.section-deals-all:hover {
    color: var(--color-primary);
    text-decoration: underline;
}

.product-carousel-outer {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: stretch;
    gap: 8px;
    min-height: 0;
}

.product-strip {
    display: flex;
    flex-direction: row;
    gap: 14px;
    min-width: 0;
    width: 100%;
    direction: ltr;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 4px 2px 12px;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x;
}

.product-strip:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

.product-card {
    flex: 0 0 auto;
    width: 200px;
    min-width: 200px;
    scroll-snap-align: start;
    background: var(--color-bg-card);
    border-radius: var(--radius-xl);
    border: 1px solid var(--color-border);
    overflow: hidden;
    box-shadow: 0 4px 18px rgba(31, 26, 28, 0.06);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.product-card:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: var(--shadow-lift);
    border-color: rgba(197, 165, 114, 0.35);
}

@media (min-width: 480px) {
    .product-card {
        width: 220px;
        min-width: 220px;
    }
}

.product-card-media {
    position: relative;
    background: #fafafa;
    aspect-ratio: 1;
    isolation: isolate;
}

.product-badge {
    position: absolute;
    bottom: 8px;
    inset-inline-start: 8px;
    top: auto;
    inset-inline-end: auto;
    z-index: 2;
    font-size: 10px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 4px;
    color: #fff;
    line-height: 1.2;
    max-width: calc(100% - 52px);
    text-align: center;
}

.product-badge--bestseller {
    background: linear-gradient(135deg, #22c55e, #16a34a);
}

.product-badge--most_wanted {
    background: linear-gradient(135deg, #a855f7, #7c3aed);
}

.product-icon-btn {
    position: absolute;
    z-index: 5;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
    cursor: pointer;
    pointer-events: auto;
    touch-action: manipulation;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    padding: 0;
    transition: color 0.15s ease, transform 0.15s ease;
}

.product-icon-btn:hover {
    color: var(--color-primary);
}

/* النقر يُسجَّل على الزر وليس على الصورة/الأيقونة داخله */
.product-icon-btn img,
.product-icon-btn svg {
    pointer-events: none;
}

.product-cart.is-added {
    color: var(--color-primary);
    transform: scale(1.06);
    transition: transform 0.2s ease, color 0.2s ease;
}

/* في RTL: inline-end = يسار الشاشة — بجانب رابط الصورة دون تغطيته */
.product-wish {
    top: 8px;
    inset-inline-end: 8px;
    inset-inline-start: auto;
}

.product-cart {
    bottom: 8px;
    inset-inline-end: 8px;
}

.product-qty-control {
    position: absolute;
    z-index: 6;
    bottom: 8px;
    inset-inline-end: 8px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.14);
    padding: 4px 6px;
}

.product-qty-btn {
    width: 26px;
    height: 26px;
    border: none;
    border-radius: 50%;
    background: #f3f4f6;
    color: #111827;
    font-size: 17px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
}

.product-qty-btn:hover {
    background: #e5e7eb;
}

.product-qty-num {
    min-width: 14px;
    text-align: center;
    font-size: 12px;
    font-weight: 800;
    color: #111827;
}

/* الرابط يملأ المساحة؛ بدون هذا يبقى مستطيل الرابط يلتقط النقر فوق أزرار السلة/المفضلة */
.product-card-img-link {
    position: relative;
    z-index: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    padding: 12px;
    pointer-events: none;
}

.product-card-img-link img {
    width: 100%;
    height: 100%;
    max-height: 100%;
    object-fit: contain;
    pointer-events: auto;
    cursor: pointer;
}

.product-card-body {
    padding: 10px 12px 14px;
    text-align: right;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
    font-size: 12px;
    margin-bottom: 6px;
    color: #666;
}

.product-rating-star {
    color: #f5a623;
    font-size: 14px;
    line-height: 1;
}

.product-rating-num {
    font-weight: 600;
    color: var(--color-text);
}

.product-rating-count {
    color: #9ca3af;
}

.product-brand {
    margin: 0 0 4px;
    font-size: 12px;
    color: #757575;
}

.product-title {
    margin: 0 0 10px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.45;
    min-height: 2.9em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

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

.product-price-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.price-old {
    font-size: 12px;
    color: #9ca3af;
    text-decoration: line-through;
}

.price-new {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--color-primary-dark);
}

.price-pct {
    font-size: 11px;
    font-weight: 700;
    color: #1f1a1c;
    background: linear-gradient(135deg, var(--color-accent), var(--color-accent-dark));
    padding: 2px 6px;
    border-radius: 999px;
}

.price-pct--on-img {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    font-size: 11px;
    font-weight: 800;
    color: var(--color-primary);
    background: #fff0f3;
    padding: 4px 8px;
    border-radius: 4px;
    line-height: 1.2;
    pointer-events: none;
}

.product-wish.is-active,
.pdp-wish.is-active {
    color: #e11d48;
}

.product-wish.is-active svg path,
.pdp-wish.is-active svg path {
    fill: currentColor;
    stroke: currentColor;
}

/* شبكة بانرات 2×2 */
.section-promo-grid {
    margin-top: 28px;
    padding-bottom: 16px;
}

.promo-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

@media (min-width: 768px) {
    .promo-grid {
        gap: 14px;
    }
}

.promo-grid-item {
    display: block;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: #f5f5f5;
    line-height: 0;
}

.promo-grid-item--full {
    grid-column: 1 / -1;
}

.promo-grid-item img {
    width: 100%;
    height: auto;
    display: block;
    vertical-align: middle;
}

/* التذييل */
.site-footer {
    margin-top: 24px;
    background: #fcfcfc;
    border-top: 1px solid #eee;
}

.footer-top {
    padding: 32px 0 24px;
}

.footer-grid {
    display: grid;
    gap: 28px;
}

@media (min-width: 900px) {
    .footer-grid {
        grid-template-columns: 1.2fr 1fr 1.2fr 1fr;
        gap: 24px;
    }
}

.footer-title {
    margin: 0 0 16px;
    font-size: 1.05rem;
    font-weight: 700;
}

.footer-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 16px;
}

.footer-tag {
    font-size: 14px;
    padding-bottom: 4px;
    border-bottom: 2px solid transparent;
}

.footer-tag:hover {
    border-bottom-color: #000;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    font-size: 14px;
    color: #444;
}

.footer-links a:hover {
    color: var(--color-primary);
}

.footer-contact li {
    margin-bottom: 10px;
}

.footer-contact-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.footer-social {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 16px;
}

.footer-social img {
    width: 28px;
    height: 28px;
}

.store-badges {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.store-badges img {
    max-width: 160px;
}

.footer-payments {
    background: #fff;
    border-top: 1px solid #eee;
    padding: 12px 0 16px;
}

.payment-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 16px 20px;
}

.payment-row--banner {
    flex-wrap: nowrap;
}

.footer-payment-banner {
    display: block;
    width: auto;
    max-width: min(420px, 88vw);
    max-height: 32px;
    height: auto;
    margin-inline: auto;
    object-fit: contain;
}

@media (min-width: 768px) {
    .footer-payment-banner {
        max-width: min(520px, 70vw);
        max-height: 36px;
    }
}

.footer-bottom {
    padding: 20px 0 28px;
    text-align: center;
}

.footer-bottom-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}

.copyright {
    margin: 0;
    font-size: 13px;
    color: var(--color-muted);
}

.footer-dev-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    font-size: 0.88rem;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #1e293b, #334155);
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.footer-dev-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
    color: #fff;
}

/* ——— صفحة المنتج PDP ——— */
.product-page {
    padding-bottom: 56px;
    background: var(--color-bg-page);
}

.pdp-container {
    padding-top: 8px;
}

.pdp-shell {
    background: #ffffff;
    border: 1px solid #eeeeee;
    border-radius: var(--radius-lg);
    padding: 12px 20px 28px;
    margin-bottom: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.pdp-not-found {
    padding: 48px 0;
    text-align: center;
}

.pdp-back-link {
    color: var(--color-primary);
    font-weight: 600;
}

.pdp-breadcrumb {
    padding: 8px 0 20px;
    font-size: 13px;
    color: #8d8383;
    line-height: 1.5;
}

.pdp-breadcrumb-list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.pdp-breadcrumb-item a {
    color: #6b6b6b;
}

.pdp-breadcrumb-item a:hover {
    color: var(--color-primary);
}

.pdp-breadcrumb-item span[aria-current="page"] {
    color: #222;
    font-weight: 500;
}

.pdp-breadcrumb-sep {
    color: #d1d1d1;
    user-select: none;
    font-weight: 300;
}

.pdp-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(300px, 420px);
    gap: 36px 40px;
    align-items: start;
    padding: 8px 0 8px;
}

@media (max-width: 960px) {
    .pdp-layout {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .pdp-buy {
        order: -1;
    }
}

/* في RTL: الصف الأول (المصغّرات) يظهر جهة البداية = اليمين للتبديل بين الصور */
.pdp-gallery {
    display: flex;
    flex-direction: row;
    gap: 16px;
    align-items: flex-start;
    justify-content: flex-start;
}

.pdp-thumbs {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-shrink: 0;
}

.pdp-thumb {
    padding: 0;
    border: 2px solid #e8e8e8;
    border-radius: var(--radius-md);
    background: #fff;
    cursor: pointer;
    overflow: hidden;
    width: 76px;
    height: 76px;
    transition: border-color 0.15s ease;
}

.pdp-thumb.is-active {
    border-color: #111111;
}

.pdp-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.pdp-main-photo {
    position: relative;
    background: #fafafa;
    border: 1px solid #f0f0f0;
    border-radius: var(--radius-lg);
    min-height: 320px;
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pdp-main-img {
    display: none;
    max-width: 100%;
    max-height: 560px;
    width: auto;
    height: auto;
    margin: 0 auto;
}

.pdp-main-img.is-active {
    display: block;
}

.pdp-buy {
    padding: 4px 0 0;
}

.pdp-brand-block {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
    position: relative;
}

.pdp-wish {
    flex-shrink: 0;
    padding: 6px;
    border: none;
    background: transparent;
    color: #333;
    cursor: pointer;
    border-radius: 50%;
    line-height: 0;
}

.pdp-wish:hover {
    color: var(--color-primary);
    background: #fff5f7;
}

.pdp-brand-meta {
    flex: 1;
    min-width: 0;
}

.pdp-brand-name {
    display: block;
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: -0.02em;
    color: #111;
    line-height: 1.3;
}

.pdp-brand-more {
    display: inline-block;
    margin-top: 6px;
    font-size: 0.88rem;
    font-weight: 600;
    color: #2e7d32;
    text-decoration: none;
}

.pdp-brand-more:hover {
    text-decoration: underline;
}

.pdp-original-badge {
    flex-shrink: 0;
    font-size: 11px;
    background: #e8f5e9;
    color: #1b5e20;
    padding: 6px 12px;
    border-radius: 999px;
    font-weight: 700;
    white-space: nowrap;
    align-self: flex-start;
}

.pdp-rating-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px 14px;
    margin-bottom: 16px;
}

.pdp-stars {
    display: inline-flex;
    gap: 2px;
    letter-spacing: 0;
}

.pdp-star {
    font-size: 1.1rem;
    color: #e0e0e0;
    line-height: 1;
}

.pdp-star.pdp-star--on {
    color: #ffc107;
}

.pdp-reviews-count {
    font-size: 0.92rem;
    color: #555;
    font-weight: 500;
}

.pdp-title {
    margin: 0 0 10px;
    font-size: 1.5rem;
    font-weight: 800;
    line-height: 1.35;
    color: #000;
}

.pdp-subtitle {
    margin: 0 0 20px;
    color: #5a5a5a;
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.5;
}

.pdp-price-block {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 10px 12px;
    margin-bottom: 14px;
}

.pdp-price-old {
    font-size: 1rem;
    color: #9ca3af;
    text-decoration: line-through;
}

.pdp-price-new {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--color-primary);
    letter-spacing: -0.02em;
}

.pdp-currency {
    font-size: 0.92em;
    font-weight: 700;
}

.pdp-discount-badge {
    font-size: 0.9rem;
    font-weight: 800;
    color: #fff;
    background: var(--color-primary);
    padding: 4px 10px;
    border-radius: 6px;
}

.pdp-tax-note {
    width: 100%;
    font-size: 0.8rem;
    color: #8d8383;
    margin-top: 4px;
}

.pdp-alert {
    background: #fff5f7;
    border: 1px solid #ffd6e0;
    color: #c2185b;
    padding: 14px 16px;
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 18px;
    text-align: center;
}

.pdp-add-cart {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 16px 24px;
    border: none;
    border-radius: var(--radius-md);
    background: #000000;
    color: #fff;
    font: inherit;
    font-weight: 800;
    font-size: 1.05rem;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    transition: background 0.15s ease, transform 0.05s ease;
}

.pdp-add-cart:hover {
    background: #222;
}

.pdp-add-cart:active {
    transform: scale(0.99);
}

.pdp-add-cart.is-added {
    background: var(--color-primary);
}

.pdp-cart-hint {
    margin: 14px 0 0;
    padding: 12px 14px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #14532d;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: var(--radius-md);
    line-height: 1.5;
}

.pdp-cart-hint a {
    color: var(--color-primary);
    font-weight: 800;
    text-decoration: underline;
}

.pdp-tabs-wrap {
    margin-top: 0;
    padding: 32px 0 40px;
    background: #fff;
    border: 1px solid #eee;
    border-radius: var(--radius-lg);
    padding-inline: 20px;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.pdp-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0 4px;
    border-bottom: 1px solid #e8e8e8;
    margin-bottom: 22px;
}

.pdp-tab {
    padding: 14px 18px;
    border: none;
    background: none;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    color: #8d8383;
    border-bottom: 3px solid transparent;
    margin-bottom: -1px;
    transition: color 0.15s ease, border-color 0.15s ease;
}

.pdp-tab.is-active {
    color: #000;
    font-weight: 800;
    border-bottom-color: #000;
}

.pdp-tab:hover:not(.is-active) {
    color: #444;
}

.pdp-panel {
    padding: 4px 0 12px;
}

.pdp-panel[hidden] {
    display: none !important;
}

.pdp-panel-heading {
    font-size: 1.2rem;
    font-weight: 800;
    margin: 0 0 10px;
    color: #111;
    line-height: 1.4;
}

.pdp-desc-lead {
    margin: 0 0 16px;
    font-size: 1rem;
    font-weight: 700;
    color: #333;
    line-height: 1.55;
}

.pdp-prose {
    line-height: 1.85;
    color: #4b5563;
    font-size: 0.95rem;
}

.pdp-panel-body--collapsible .pdp-prose {
    max-height: 11rem;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.pdp-panel-body--collapsible.is-expanded .pdp-prose {
    max-height: 120rem;
}

.pdp-read-more-wrap {
    text-align: center;
    margin-top: 16px;
}

.pdp-read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 4px;
    padding: 8px 12px;
    border: none;
    background: none;
    font: inherit;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--color-primary);
    cursor: pointer;
}

.pdp-read-more:hover {
    text-decoration: underline;
}

.pdp-read-more-chevron {
    font-size: 0.65rem;
    transition: transform 0.25s ease;
    display: inline-block;
}

.pdp-read-more-chevron.is-open {
    transform: rotate(180deg);
}

.pdp-specs {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 10px 28px;
    margin: 0;
}

.pdp-specs dt {
    font-weight: 700;
    margin: 0;
    color: #111;
}

.pdp-specs dd {
    margin: 0;
    color: #555;
}

.pdp-spec-line {
    grid-column: 1 / -1;
}

/* منتجات موصى بها — بطاقات أوضح */
.pdp-recommended {
    margin-top: 8px;
    padding: 24px 0 8px;
}

.pdp-rec-head {
    margin-bottom: 8px;
}

.pdp-rec-title {
    font-size: 1.1rem;
    font-weight: 800;
}

.pdp-rec-carousel {
    padding-bottom: 8px;
}

.pdp-rec-strip .product-card--pdp-rec {
    background: #fff;
    border: 1px solid #eee;
    border-radius: var(--radius-md);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.pdp-rec-strip .product-card--pdp-rec:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.pdp-rec-nav {
    background: #fff;
    border: 1px solid #e5e5e5;
}

/* ——— صفحة قائمة القسم (category.php) ——— */
.catalog-page {
    padding-bottom: 48px;
}

.catalog-empty {
    padding: 48px 0;
    text-align: center;
}

.catalog-breadcrumb {
    padding: 12px 0 20px;
    font-size: 13px;
    color: #8d8383;
}

.catalog-breadcrumb-list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.catalog-breadcrumb-list a {
    color: #6b6b6b;
}

.catalog-breadcrumb-list a:hover {
    color: var(--color-primary);
}

.catalog-breadcrumb-sep {
    color: #d1d1d1;
}

.catalog-layout {
    display: grid;
    grid-template-columns: minmax(260px, 300px) minmax(0, 1fr);
    gap: 24px 28px;
    align-items: start;
}

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

    .catalog-sidebar {
        order: 2;
    }

    .catalog-main {
        order: 1;
    }
}

.catalog-sidebar {
    background: #fff;
    border: 1px solid #eeeeee;
    border-radius: var(--radius-lg);
    padding: 16px 14px 20px;
    position: sticky;
    top: 100px;
}

@media (max-width: 960px) {
    .catalog-sidebar {
        position: static;
    }
}

.catalog-filter-heading {
    margin: 0 0 14px;
    font-size: 1rem;
    font-weight: 800;
    color: #111;
}

.catalog-filter-block {
    border: 1px solid #eee;
    border-radius: var(--radius-md);
    margin-bottom: 12px;
    background: #fafafa;
}

.catalog-filter-summary {
    padding: 12px 14px;
    font-weight: 700;
    font-size: 0.92rem;
    cursor: pointer;
    list-style: none;
}

.catalog-filter-summary::-webkit-details-marker {
    display: none;
}

.catalog-filter-body {
    padding: 0 12px 14px;
}

.catalog-brand-search-label {
    display: block;
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 6px;
}

.catalog-brand-search {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e5e5e5;
    border-radius: var(--radius-md);
    font: inherit;
    margin-bottom: 10px;
    background: #fff;
}

.catalog-brand-list {
    max-height: 220px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.catalog-brand-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.88rem;
    cursor: pointer;
    padding: 4px 0;
}

.catalog-brand-item input {
    width: 16px;
    height: 16px;
    accent-color: var(--color-primary);
}

.catalog-filter-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.catalog-sub-link {
    font-size: 0.9rem;
    font-weight: 600;
    color: #444;
    padding: 6px 0;
    border-bottom: 1px solid transparent;
}

.catalog-sub-link:hover,
.catalog-sub-link.is-active {
    color: var(--color-primary);
}

.catalog-sub-link.is-active {
    border-bottom-color: var(--color-primary);
}

.catalog-muted {
    font-size: 0.85rem;
    color: #888;
    line-height: 1.5;
}

.catalog-placeholder-note {
    margin: 0;
}

.catalog-title-wrap {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.catalog-filter-active {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: #666;
}

.catalog-tree-wrap {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.catalog-tree-sub {
    border: 1px solid #eee;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: #fafafa;
}

.catalog-tree-sub-summary {
    padding: 10px 12px;
    font-size: 0.88rem;
    font-weight: 700;
    color: #222;
    cursor: pointer;
    list-style: none;
}

.catalog-tree-sub-summary::-webkit-details-marker {
    display: none;
}

.catalog-tree-sub-body {
    padding: 0 12px 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.catalog-tree-scope-link {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--color-primary);
    text-decoration: none;
    align-self: flex-start;
}

.catalog-tree-scope-link:hover {
    text-decoration: underline;
}

.catalog-tree-leaf-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.catalog-tree-leaf-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #444;
    cursor: pointer;
}

.catalog-tree-leaf-item input {
    margin-top: 3px;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    accent-color: var(--color-primary);
}

.catalog-tree-empty-note {
    margin: 0;
    font-size: 0.8rem;
    color: #888;
}

.catalog-apply-btn {
    width: 100%;
    margin-top: 8px;
    padding: 12px 16px;
    border: none;
    border-radius: var(--radius-md);
    background: #111;
    color: #fff;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.catalog-apply-btn:hover {
    background: #333;
}

.catalog-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #eee;
}

.catalog-title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 800;
    color: #000;
}

.catalog-sort {
    display: flex;
    align-items: center;
    gap: 10px;
}

.catalog-sort-label {
    font-size: 0.88rem;
    color: #666;
    font-weight: 600;
}

.catalog-sort-select {
    min-width: 200px;
    padding: 10px 14px;
    border: 1px solid #ddd;
    border-radius: var(--radius-md);
    font: inherit;
    font-weight: 600;
    background: #fff;
    cursor: pointer;
}

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

.catalog-grid .product-card.is-hidden-by-limit {
    display: none;
}

.catalog-show-more-wrap {
    margin-top: 16px;
    text-align: center;
}

.catalog-show-more-btn {
    border: 1px solid #d1d5db;
    background: #fff;
    color: #111827;
    border-radius: 10px;
    padding: 10px 18px;
    font-weight: 700;
    cursor: pointer;
}

.catalog-show-more-btn:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

@media (min-width: 1200px) {
    .catalog-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

.catalog-no-results {
    padding: 48px 24px;
    text-align: center;
    background: #fff;
    border: 1px dashed #ddd;
    border-radius: var(--radius-lg);
    color: #666;
}

.catalog-no-results a {
    color: var(--color-primary);
    font-weight: 700;
}

.product-card--catalog {
    background: #fff;
    border: 1px solid #eeeeee;
    border-radius: var(--radius-md);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: box-shadow 0.15s ease;
}

.product-card--catalog:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

.product-card--catalog .product-card-media {
    background: #fafafa;
}

.product-card--catalog .product-title {
    font-size: 0.88rem;
    line-height: 1.4;
}

.product-card--catalog .price-new {
    font-weight: 800;
    color: #111;
}

.product-card--catalog .price-pct--on-img {
    font-weight: 800;
}

/* شارة عدد السلة + صفحات السلة والمفضلة */
.header-cart-with-badge {
    position: relative;
}

.header-cart-count {
    position: absolute;
    top: 2px;
    inset-inline-end: 0;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    background: var(--color-primary);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    line-height: 18px;
    text-align: center;
}

.cart-page,
.favorites-page {
    padding-bottom: 40px;
}

.cart-page-title,
.favorites-page-title {
    margin: 0 0 8px;
    font-size: 1.45rem;
    font-weight: 800;
}

.favorites-page-lead {
    margin: 0 0 20px;
    font-size: 0.92rem;
    color: #666;
    max-width: 42rem;
}

.cart-page-inner {
    margin-top: 16px;
}

.cart-empty,
.favorites-empty {
    padding: 40px 24px;
    text-align: center;
    background: #fafafa;
    border: 1px dashed #ddd;
    border-radius: var(--radius-lg);
    color: #555;
}

.cart-back-shop {
    font-weight: 700;
    color: var(--color-primary);
}

.cart-lines-panel {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.cart-layout {
    display: grid;
    gap: 24px;
}

@media (min-width: 992px) {
    .cart-layout {
        grid-template-columns: 1fr minmax(280px, 340px);
        align-items: start;
    }
}

.cart-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border: 1px solid #eee;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.cart-table thead {
    background: #fafafa;
}

.cart-table th {
    padding: 12px 10px;
    font-size: 0.82rem;
    font-weight: 700;
    text-align: right;
    border-bottom: 1px solid #eee;
}

.cart-table td {
    padding: 14px 10px;
    vertical-align: middle;
    border-bottom: 1px solid #f0f0f0;
    font-size: 0.9rem;
}

.cart-col-thumb {
    width: 88px;
}

.cart-col-thumb img {
    display: block;
    width: 72px;
    height: 72px;
    object-fit: contain;
    border-radius: var(--radius-sm);
    background: #fafafa;
}

.cart-line-brand {
    font-size: 0.78rem;
    color: #888;
    margin-bottom: 4px;
}

.cart-line-title {
    display: block;
    font-weight: 700;
    color: #111;
    text-decoration: none;
    margin-bottom: 6px;
    line-height: 1.35;
}

.cart-line-title:hover {
    color: var(--color-primary);
}

.cart-line-prices {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: baseline;
}

.cart-line-old {
    font-size: 0.82rem;
    color: #9ca3af;
    text-decoration: line-through;
}

.cart-line-unit {
    font-weight: 700;
    color: #111;
}

.cart-qty {
    display: inline-flex;
    align-items: center;
    gap: 0;
    border: 1px solid #ddd;
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.cart-qty-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: #f5f5f5;
    font-size: 1.1rem;
    cursor: pointer;
    line-height: 1;
}

.cart-qty-btn:hover {
    background: #eee;
}

.cart-qty-num {
    min-width: 28px;
    text-align: center;
    font-weight: 700;
}

.cart-remove-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    font-size: 1.25rem;
    line-height: 1;
    color: #999;
    cursor: pointer;
}

.cart-remove-btn:hover {
    color: #c00;
}

.cart-summary {
    padding: 20px;
    border: 1px solid #eee;
    border-radius: var(--radius-md);
    background: #fafafa;
}

.cart-summary-title {
    margin: 0 0 16px;
    font-size: 1.05rem;
    font-weight: 800;
}

.cart-summary-rows {
    margin: 0 0 20px;
}

.cart-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    padding: 8px 0;
    font-size: 0.92rem;
    border-bottom: 1px solid #eee;
}

.cart-summary-row dt {
    margin: 0;
    font-weight: 600;
    color: #555;
}

.cart-summary-row dd {
    margin: 0;
    font-weight: 700;
}

.cart-summary-row--savings dd {
    color: #16a34a;
}

.cart-summary-row--total {
    border-bottom: none;
    padding-top: 12px;
    font-size: 1.05rem;
}

.cart-coupon-block {
    margin-bottom: 16px;
}

.cart-coupon-label {
    display: block;
    font-size: 0.82rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: #444;
}

.cart-coupon-row {
    display: flex;
    gap: 8px;
}

.cart-coupon-input {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: var(--radius-sm);
    font: inherit;
    background: #fff;
}

.cart-coupon-btn {
    padding: 10px 16px;
    border: 1px solid #111;
    border-radius: var(--radius-sm);
    background: #111;
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}

.cart-coupon-btn:hover {
    background: #333;
}

.cart-coupon-hint {
    margin: 8px 0 0;
    font-size: 0.78rem;
    color: #888;
}

.cart-coupon-hint.is-success {
    color: #15803d;
}

.cart-coupon-hint.is-error {
    color: #b91c1c;
}

.cart-checkout-btn {
    width: 100%;
    padding: 14px 16px;
    border: none;
    border-radius: var(--radius-md);
    background: #111;
    color: #fff;
    font: inherit;
    font-weight: 800;
    font-size: 1rem;
    cursor: pointer;
}

.cart-checkout-btn:hover {
    background: #333;
}

.checkout-modal[hidden] {
    display: none !important;
}

.checkout-modal {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.checkout-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
}

.checkout-modal-dialog {
    position: relative;
    width: min(560px, 100%);
    max-height: min(88vh, 760px);
    overflow: auto;
    background: #fff;
    border-radius: var(--radius-lg);
    border: 1px solid #eee;
    box-shadow: var(--shadow-lift);
    padding: 20px;
}

.checkout-modal-close {
    position: absolute;
    top: 10px;
    inset-inline-end: 10px;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 50%;
    background: #f3f3f3;
    color: #333;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
}

.checkout-modal-title {
    margin: 0 0 6px;
    font-size: 1.25rem;
    font-weight: 800;
}

.checkout-modal-subtitle {
    margin: 0 0 16px;
    color: #666;
    font-size: 0.9rem;
}

.checkout-form {
    display: grid;
    gap: 12px;
}

.checkout-field label {
    display: block;
    margin-bottom: 6px;
    font-size: 0.88rem;
    font-weight: 700;
}

.checkout-field input,
.checkout-field textarea {
    width: 100%;
    border: 1px solid #ddd;
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    font: inherit;
}

.checkout-field textarea {
    resize: vertical;
}

.checkout-form-status {
    margin: 0;
    font-size: 0.86rem;
    font-weight: 700;
}

.checkout-form-status.is-error {
    color: #b91c1c;
}

.checkout-form-status.is-success {
    color: #15803d;
}

.checkout-form-actions {
    margin-top: 4px;
}

.favorites-grid {
    margin-top: 8px;
}

/* صفحة الإعلانات والإشعارات */
.notifications-page {
    padding-bottom: 48px;
}

.notifications-page-head {
    margin-bottom: 24px;
}

.notifications-page-title {
    margin: 0 0 8px;
    font-size: 1.45rem;
    font-weight: 800;
    color: #111;
}

.notifications-page-lead {
    margin: 0;
    font-size: 0.95rem;
    color: #666;
    max-width: 40rem;
    line-height: 1.55;
}

.notification-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.notification-item {
    background: #fff;
    border: 1px solid #eee;
    border-radius: var(--radius-lg);
    padding: 18px 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.notification-item-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.notification-date {
    font-size: 0.82rem;
    font-weight: 600;
    color: #888;
}

.notification-badge {
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: none;
    padding: 4px 10px;
    border-radius: 999px;
    background: #fff0f3;
    color: var(--color-primary);
}

.notification-item-title {
    margin: 0 0 10px;
    font-size: 1.05rem;
    font-weight: 800;
    color: #111;
    line-height: 1.35;
}

.notification-item-body {
    margin: 0;
    font-size: 0.92rem;
    color: #444;
    line-height: 1.65;
}

.notifications-empty {
    padding: 40px 24px;
    text-align: center;
    background: #fafafa;
    border: 1px dashed #ddd;
    border-radius: var(--radius-lg);
    color: #555;
}

/* —— CMS (صفحات JSON) —— */
.cms-main .cms-root {
    background: transparent;
}

.cms-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.6rem 1.35rem;
    border-radius: var(--radius-xl);
    font-weight: 700;
    text-decoration: none;
    border: 1px solid transparent;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cms-btn--gold {
    background: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-dark) 100%);
    color: #1a1410;
    border-color: rgba(197, 165, 114, 0.55);
    box-shadow: 0 6px 20px rgba(157, 127, 74, 0.28);
}

.cms-btn--gold:hover {
    color: #1a1410;
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 10px 28px rgba(157, 127, 74, 0.35);
}

.cms-btn--outline {
    background: transparent;
    color: var(--color-primary-dark);
    border-color: rgba(139, 58, 82, 0.35);
}

.cms-btn--outline:hover {
    border-color: var(--color-accent);
    color: var(--color-accent-dark);
}

.cms-btn--ghost {
    background: rgba(255, 255, 255, 0.65);
    color: var(--color-primary-dark);
    border-color: var(--color-border);
}

.cms-slot-wrap {
    margin-bottom: 1rem;
}

.cms-banner--overlay::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.15));
    pointer-events: none;
}

.cms-banner .position-relative {
    z-index: 1;
}
