/* Olight – پنج تم قابل انتخاب + منوی جذاب‌تر. بعد از tailwind.css لینک شود. */
.category-collection-icon{width:60px;height:60px}
html[data-theme="light"]{
  --color-olight-paper:#FBF9F5;  --color-olight-ink:#1F1B16;  --color-olight-muted:#5E5648;  --color-olight-gold:#7A5C14;  --color-olight-sand:#F1EADF;
  --o-surface:#FFFFFF; --o-line:#E6DED0; --o-deep:#EFE7D9; --o-deep-text:#1F1B16; --o-on-gold:#FFFFFF; --o-btn:#1F1B16; --o-btn-text:#FFFFFF; --o-hero:#E8DFD1; --o-hero-text:#1F1B16; --o-hero-muted:#5E5648; --o-hero-accent:#7A5C14; --o-hero-btn:#1F1B16; --o-hero-btn-text:#FFFFFF; --o-hero-btn-hover:#7A5C14;
  --o-logo-filter:none; --o-brand-filter:grayscale(1); color-scheme:light;
}
html[data-theme="emerald-light"]{
  --color-olight-paper:#F3F7F3;  --color-olight-ink:#12261F;  --color-olight-muted:#4F6A5F;  --color-olight-gold:#17694F;  --color-olight-sand:#E4EFE8;
  --o-surface:#FAFDFB; --o-line:#D3E2D8; --o-deep:#E1ECE5; --o-deep-text:#12261F; --o-on-gold:#FFFFFF; --o-btn:#0F3D2E; --o-btn-text:#F3F7F3; --o-hero:#DCEBE1; --o-hero-text:#12261F; --o-hero-muted:#3F5A4E; --o-hero-accent:#17694F; --o-hero-btn:#0F3D2E; --o-hero-btn-text:#F3F7F3; --o-hero-btn-hover:#17694F;
  --o-logo-filter:none; --o-brand-filter:grayscale(1); color-scheme:light;
}
html[data-theme="midnight"]{
  --color-olight-paper:#F4F1EA;  --color-olight-ink:#0F1D3A;  --color-olight-muted:#5B6579;  --color-olight-gold:#7E5F18;  --color-olight-sand:#EAE4D6;
  --o-surface:#FBF9F4; --o-line:#DDD6C6; --o-deep:#0F1D3A; --o-deep-text:#FFFFFF; --o-on-gold:#0F1D3A; --o-btn:#0F1D3A; --o-btn-text:#F4F1EA; --o-hero:#0F1D3A; --o-hero-text:#F4F1EA; --o-hero-muted:#BFC8DA; --o-hero-accent:#D3B574; --o-hero-btn:#D3B574; --o-hero-btn-text:#0F1D3A; --o-hero-btn-hover:#E6CD94;
  --o-logo-filter:none; --o-brand-filter:grayscale(1); color-scheme:light;
}
html[data-theme="bordeaux"]{
  --color-olight-paper:#F8F1EE;  --color-olight-ink:#2E1A1E;  --color-olight-muted:#6F5E5F;  --color-olight-gold:#9A5A45;  --color-olight-sand:#F0E2DC;
  --o-surface:#FDF9F7; --o-line:#E5D3CC; --o-deep:#3A0F1A; --o-deep-text:#FFFFFF; --o-on-gold:#FFFFFF; --o-btn:#4B1623; --o-btn-text:#F8F1EE; --o-hero:#4B1623; --o-hero-text:#F8F1EE; --o-hero-muted:#E2C9C6; --o-hero-accent:#E6B9A2; --o-hero-btn:#E6B9A2; --o-hero-btn-text:#3A0F1A; --o-hero-btn-hover:#F0CDB9;
  --o-logo-filter:none; --o-brand-filter:grayscale(1); color-scheme:light;
}
html[data-theme="onyx"]{
  --color-olight-paper:#0B0A08;  --color-olight-ink:#F4F0E7;  --color-olight-muted:#B9B1A2;  --color-olight-gold:#D2B36F;  --color-olight-sand:#191611;
  --o-surface:#15120E; --o-line:#393124; --o-deep:#080706; --o-deep-text:#F4F0E7; --o-on-gold:#17130C; --o-btn:#D8BA76; --o-btn-text:#17130C; --o-hero:#19150E; --o-hero-text:#F4F0E7; --o-hero-muted:#C4BBAA; --o-hero-accent:#E4CA8B; --o-hero-btn:#E4CA8B; --o-hero-btn-text:#17130C; --o-hero-btn-hover:#F0DDAA;
  --o-logo-filter:brightness(0) invert(1); --o-brand-filter:grayscale(1) invert(1); color-scheme:dark;
}

@layer utilities{
  :where(html[data-theme]) .bg-white{background-color:var(--o-surface)}
  :where(html[data-theme]) .bg-white\/95{background-color:color-mix(in srgb,var(--o-surface) 95%,transparent)}
  :where(html[data-theme]) .bg-white\/90{background-color:color-mix(in srgb,var(--o-surface) 90%,transparent)}
  :where(html[data-theme]) .group:hover .group-hover\:bg-white{background-color:var(--o-surface)}
  :where(html[data-theme]) [class*="border-black/"]{border-color:var(--o-line)}
  :where(html[data-theme]) a.bg-olight-ink,
  :where(html[data-theme]) button.bg-olight-ink{background-color:var(--o-btn);color:var(--o-btn-text)}
  :where(html[data-theme]) .hover\:bg-olight-ink:hover{background-color:var(--o-btn);color:var(--o-btn-text)}
  :where(html[data-theme]) .hover\:bg-olight-gold:hover{color:var(--o-on-gold)}
  :where(html[data-theme]) #cart-count{color:var(--o-on-gold)}

  /* بخش تیره/روشن و فوتر (در تم‌های لایت، روشن می‌شوند) */
  :where(html[data-theme]) :is(section,footer).bg-olight-ink{background-color:var(--o-deep);color:var(--o-deep-text)}
  :where(html[data-theme]) :is(section,footer).bg-olight-ink [class*="text-white/"]{color:color-mix(in srgb,var(--o-deep-text) 68%,transparent)}
  :where(html[data-theme]) :is(section,footer).bg-olight-ink .hover\:text-white:hover{color:var(--o-deep-text)}
  :where(html[data-theme]) :is(section,footer).bg-olight-ink .text-olight-gold{color:var(--o-hero-accent)}
  :where(html[data-theme]) footer [class*="border-white/"]{border-color:color-mix(in srgb,var(--o-deep-text) 14%,transparent)}
  :where(html[data-theme]) footer a.bg-white{background-color:#fff}

  /* کارت اصلی */
  :where(html[data-theme]) .bg-\[\#e8dfd1\]{background-color:var(--o-hero)}
  :where(html[data-theme]) #home h1{color:var(--o-hero-text)}
  :where(html[data-theme]) #home p.text-olight-muted{color:var(--o-hero-muted)}
  :where(html[data-theme]) #home p.text-olight-gold{color:var(--o-hero-accent)}
  :where(html[data-theme]) #home a.bg-olight-ink{background-color:var(--o-hero-btn);color:var(--o-hero-btn-text)}
  :where(html[data-theme]) #home a.bg-olight-ink:hover{background-color:var(--o-hero-btn-hover);color:var(--o-hero-btn-text)}
  :where(html[data-theme]) #home .bg-linear-to-r{background-image:linear-gradient(to left,var(--o-hero),color-mix(in srgb,var(--o-hero) 20%,transparent),transparent)}
  @media (min-width:48rem){
    :where(html[data-theme]) #home .bg-linear-to-r{background-image:linear-gradient(to left,color-mix(in srgb,var(--o-hero) 20%,transparent),transparent)}
  }
  :where(html[data-theme]) header a[href="#home"] img{filter:var(--o-logo-filter)}
  :where(html[data-theme]) img[src*="brand_"]{filter:var(--o-brand-filter)}
}
html[data-theme] body,
html[data-theme] :is(header,section,footer,#mobile-menu,#search-panel,.olight-theme-menu){
  transition:background-color .28s ease,color .28s ease,border-color .28s ease,box-shadow .28s ease
}
html[data-theme] ::selection{background:var(--color-olight-gold);color:var(--o-on-gold,#fff)}
html[data-theme] :is(a,button,input,select,textarea):focus-visible{outline-color:var(--color-olight-gold)}

/* ===== منو ===== */
html{scroll-padding-top:88px}
header>div:first-child{transition:padding .25s ease}
header.is-scrolled{box-shadow:0 12px 30px -18px rgba(0,0,0,.35)}
header.is-scrolled>div:first-child{padding-block:.5rem}
header nav[aria-label="پیمایش اصلی"]{gap:4px;font-size:14.5px;font-weight:500}
header nav[aria-label="پیمایش اصلی"] a,#mobile-menu nav a{letter-spacing:0;text-transform:none}
header nav[aria-label="پیمایش اصلی"] a{position:relative;display:inline-flex;align-items:center;min-height:44px;padding:0 16px;
  border-radius:999px;transition:color .2s,background-color .2s}
header nav[aria-label="پیمایش اصلی"] a::after{content:"";position:absolute;inset-inline:16px;bottom:7px;height:2px;border-radius:2px;
  background:var(--color-olight-gold);transform:scaleX(0);transition:transform .25s ease}
header nav[aria-label="پیمایش اصلی"] a:is(:hover,:focus-visible,[aria-current="true"]){
  color:var(--color-olight-gold);background:color-mix(in srgb,var(--color-olight-gold) 9%,transparent)}
header nav[aria-label="پیمایش اصلی"] a:is(:hover,:focus-visible,[aria-current="true"])::after{transform:scaleX(1)}
header nav[aria-label="پیمایش اصلی"] .olight-theme-menu-toggle{display:inline-flex;align-items:center;gap:8px;min-height:44px;padding:0 16px;
  border:0;border-radius:999px;background:transparent;color:inherit;font:inherit;letter-spacing:0;text-transform:none;cursor:pointer;transition:color .2s,background-color .2s}
header nav[aria-label="پیمایش اصلی"] .olight-theme-menu-toggle:is(:hover,:focus-visible,[aria-expanded="true"]){
  color:var(--color-olight-gold);background:color-mix(in srgb,var(--color-olight-gold) 9%,transparent)}
.olight-theme-menu{position:relative}
.olight-theme-preview,.olight-theme-swatch{display:inline-block;flex:none;width:18px;height:18px;border:1px solid color-mix(in srgb,var(--color-olight-ink) 24%,transparent);border-radius:50%}
.olight-theme-menu-indicator{display:inline-flex;align-items:center;gap:8px}
.olight-theme-chevron{display:inline-block;font-size:20px;line-height:1;transition:transform .2s ease}
.olight-theme-menu.is-open .olight-theme-chevron{transform:rotate(180deg)}
.olight-theme-menu-panel{position:absolute;inset-block-start:calc(100% + 10px);inset-inline-start:0;z-index:80;min-width:238px;padding:7px;
  border:1px solid var(--o-line);border-radius:16px;background:var(--o-surface);color:var(--color-olight-ink);
  box-shadow:0 18px 44px rgba(0,0,0,.2);backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}
.olight-theme-menu-option{display:flex;align-items:center;gap:10px;width:100%;min-height:42px;padding:8px 10px;border:0;border-radius:10px;
  background:transparent;color:inherit;text-align:start;font:inherit;font-size:13px;letter-spacing:0;text-transform:none;cursor:pointer;transition:background-color .18s,color .18s}
.olight-theme-menu-option:is(:hover,[aria-pressed="true"]){background:color-mix(in srgb,var(--color-olight-gold) 12%,transparent)}
.olight-theme-menu-option:focus-visible,.olight-theme-menu-toggle:focus-visible{outline:2px solid var(--color-olight-gold);outline-offset:2px}
#mobile-menu{padding:6px 20px 14px}
#mobile-menu nav{gap:0}
#mobile-menu nav a{display:flex;align-items:center;justify-content:space-between;min-height:52px;font-size:16px;font-weight:500;
  border-bottom:1px solid var(--o-line,rgba(0,0,0,.08))}
#mobile-menu nav a:last-child{border-bottom:0}
#mobile-menu nav a::after{content:"‹";font-size:24px;line-height:1;color:var(--color-olight-gold);transition:transform .2s}
#mobile-menu nav a:hover::after{transform:translateX(-4px)}
#mobile-menu nav a[aria-current="true"]{color:var(--color-olight-gold)}
#mobile-menu nav .olight-theme-menu{width:100%;border-bottom:1px solid var(--o-line,rgba(0,0,0,.08))}
#mobile-menu nav .olight-theme-menu-toggle{display:flex;align-items:center;justify-content:space-between;width:100%;min-height:52px;padding:0;
  border:0;border-radius:0;background:transparent;color:inherit;text-align:start;font:inherit;font-size:16px;font-weight:500;letter-spacing:0;text-transform:none;cursor:pointer}
#mobile-menu nav .olight-theme-menu-panel{position:static;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;width:100%;min-width:0;
  padding:0 0 12px;border:0;border-radius:0;background:transparent;box-shadow:none;backdrop-filter:none;-webkit-backdrop-filter:none}
#mobile-menu nav .olight-theme-menu-panel[hidden]{display:none}
#mobile-menu nav .olight-theme-menu-option{min-height:44px;padding:8px;background:color-mix(in srgb,var(--color-olight-gold) 5%,var(--o-surface));font-size:12px}
@media (prefers-reduced-motion:reduce){header *,#mobile-menu *{transition:none!important}}

/* ===== منوی انتخاب رنگ‌بندی ===== */
@media(prefers-reduced-motion:reduce){
  html[data-theme] body,html[data-theme] :is(header,section,footer,#mobile-menu,#search-panel,.olight-theme-menu),
  .olight-theme-menu *{transition:none!important}
}
:where(html[data-theme="onyx"]) .hover\:border-olight-ink:hover{border-color:var(--o-btn)}

/* Featured products */
#featured.featured-section{
  position:relative;
  isolation:isolate;
  overflow:hidden;
  background:
    radial-gradient(ellipse at 8% 0%,color-mix(in srgb,var(--color-olight-gold) 11%,transparent),transparent 34rem),
    var(--color-olight-paper);
}
#featured.featured-section::before{
  position:absolute;
  inset-block-start:0;
  inset-inline: max(calc((100% - 80rem)/2),1rem);
  height:1px;
  background:linear-gradient(90deg,transparent,color-mix(in srgb,var(--color-olight-gold) 38%,transparent),transparent);
  content:"";
}
#featured .featured-container{position:relative;z-index:1}
#featured .featured-heading{margin-block-end:2.5rem;gap:2rem}
#featured .featured-copy{max-width:44rem}
#featured .featured-eyebrow{display:flex;align-items:center;gap:.65rem;margin:0;color:var(--color-olight-gold);letter-spacing:.12em}
#featured .featured-eyebrow span{font-size:1rem;line-height:1}
#featured .featured-title{margin-block-start:.85rem;color:var(--color-olight-ink);font-size:clamp(2rem,4vw,3.25rem);line-height:1.25}
#featured .featured-description{max-width:38rem;margin-block-start:.8rem;color:var(--color-olight-muted);line-height:2}
#featured .featured-filter-area{display:flex;flex-direction:column;align-items:flex-start;gap:.65rem}
#featured .featured-filter-caption{padding-inline-start:.4rem;color:var(--color-olight-muted);font-size:.72rem;font-weight:600}
#featured .featured-filters{gap:.4rem;padding:.38rem;border:1px solid var(--o-line);border-radius:999px;background:var(--o-surface);box-shadow:0 10px 28px color-mix(in srgb,var(--color-olight-ink) 7%,transparent)}
#featured .featured-filter{min-height:2.65rem;padding-inline:1.1rem;border-color:transparent;background:transparent;color:var(--color-olight-muted);cursor:pointer;transition:background-color .2s,color .2s,border-color .2s,transform .2s}
#featured .featured-filter:hover{border-color:color-mix(in srgb,var(--color-olight-gold) 32%,transparent);background:color-mix(in srgb,var(--color-olight-gold) 8%,var(--o-surface));color:var(--color-olight-ink);transform:translateY(-1px)}
#featured .featured-filter.bg-olight-ink{border-color:var(--o-btn);background:var(--o-btn);color:var(--o-btn-text);box-shadow:0 5px 14px color-mix(in srgb,var(--color-olight-gold) 20%,transparent)}
#featured .featured-filter:focus-visible,#featured .featured-more:focus-visible{outline:2px solid var(--color-olight-gold);outline-offset:3px}
#product-grid .product-card{display:flex;flex-direction:column;overflow:hidden;border:1px solid var(--o-line);border-radius:1rem;background:var(--o-surface);box-shadow:0 14px 35px color-mix(in srgb,var(--color-olight-ink) 10%,transparent);transition:transform .25s ease,border-color .25s ease,box-shadow .25s ease}
#product-grid .product-card.hidden{display:none}
#product-grid .product-card:hover{transform:translateY(-4px);border-color:color-mix(in srgb,var(--color-olight-gold) 48%,var(--o-line));box-shadow:0 20px 42px color-mix(in srgb,var(--color-olight-ink) 16%,transparent)}
#product-grid .product-media{position:relative;height:14rem;overflow:hidden;background:var(--color-olight-sand)}
#product-grid .product-media>img{display:block;width:100%;height:100%;object-fit:cover;transition:transform .55s cubic-bezier(.2,.7,.2,1)}
#product-grid .product-card:hover .product-media>img{transform:scale(1.055)}
#product-grid .product-image-placeholder{display:grid;width:100%;height:100%;place-content:center;gap:.5rem;background:radial-gradient(circle,var(--o-surface),var(--color-olight-sand));color:var(--color-olight-gold);text-align:center}
#product-grid .product-image-placeholder span{font-family:Georgia,serif;font-size:4.5rem;line-height:1}
#product-grid .product-favorite{position:absolute;inset-block-start:.85rem;inset-inline-start:.85rem;display:grid;width:2.7rem;height:2.7rem;place-items:center;border:1px solid rgba(255,255,255,.72);border-radius:999px;background:rgba(255,255,255,.88);color:var(--color-olight-ink);box-shadow:0 5px 18px rgba(0,0,0,.12);cursor:pointer;backdrop-filter:blur(10px);transition:transform .2s ease,background-color .2s ease,color .2s ease}
#product-grid .product-favorite:hover{transform:scale(1.07);background:var(--o-surface)}
#product-grid .product-favorite svg{width:1.25rem;height:1.25rem}
#product-grid .product-favorite.is-favorite{color:#b33b48}
#product-grid .product-favorite.is-favorite svg{fill:currentColor}
#product-grid .product-favorite:focus-visible{outline:2px solid var(--color-olight-gold);outline-offset:3px}
#product-grid .product-featured-badge{position:absolute;inset-block-start:.9rem;inset-inline-end:.9rem;padding:.38rem .75rem;border:1px solid color-mix(in srgb,var(--color-olight-gold) 28%,transparent);border-radius:999px;background:color-mix(in srgb,var(--o-surface) 92%,transparent);color:var(--color-olight-ink);font-size:.65rem;font-weight:700;box-shadow:0 5px 16px rgba(0,0,0,.08);backdrop-filter:blur(8px)}
#product-grid .product-details{padding:1rem 1.15rem .9rem}
#product-grid .product-meta{overflow:hidden;color:var(--color-olight-muted);font-size:.65rem;font-weight:700;text-overflow:ellipsis;white-space:nowrap}
#product-grid .product-price{display:flex;align-items:baseline;gap:.45rem;margin-block-start:.45rem;color:var(--color-olight-ink);line-height:1.45}
#product-grid .product-price-value{font-size:clamp(1.15rem,1.6vw,1.55rem);font-weight:800;font-variant-numeric:tabular-nums}
#product-grid .product-currency{color:var(--color-olight-muted);font-size:.72rem;font-weight:600}
#product-grid .product-price-unavailable{color:var(--color-olight-muted);font-size:1.05rem}
#product-grid .product-title{margin-block-start:.35rem;color:var(--color-olight-ink);font-size:.9rem;font-weight:600;line-height:1.8}
#product-grid .product-specs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));border-block-start:1px solid var(--o-line);color:var(--color-olight-muted)}
#product-grid .product-spec{display:flex;min-width:0;align-items:center;gap:.6rem;padding:.8rem .9rem}
#product-grid .product-spec+.product-spec{border-inline-start:1px solid var(--o-line)}
#product-grid .product-spec-icon{flex:none;width:1.35rem;height:1.35rem;color:var(--color-olight-gold)}
#product-grid .product-spec-copy{display:flex;min-width:0;flex-direction:column;gap:.12rem}
#product-grid .product-spec-value{overflow:hidden;color:var(--color-olight-ink);font-size:.78rem;font-weight:700;text-overflow:ellipsis;white-space:nowrap}
#product-grid .product-spec-label{color:var(--color-olight-muted);font-size:.62rem}
#product-grid .product-rating{display:flex;align-items:center;justify-content:space-between;gap:.6rem;padding:.8rem 1.05rem;border-block-start:1px solid var(--o-line);background:color-mix(in srgb,var(--color-olight-paper) 78%,var(--o-surface))}
#product-grid .product-rating-label{color:var(--color-olight-muted);font-size:.63rem;font-weight:700}
#product-grid .product-rating-summary{display:flex;align-items:center;gap:.35rem;white-space:nowrap}
#product-grid .product-rating-stars{color:var(--color-olight-gold);font-size:.73rem;letter-spacing:.05em}
#product-grid .product-rating-score{color:var(--color-olight-ink);font-size:.72rem;font-weight:800}
#product-grid .product-rating-count,#product-grid .product-rating-empty{color:var(--color-olight-muted);font-size:.62rem}
#featured .featured-message{margin-block-start:1rem;border:1px dashed var(--o-line);border-radius:1rem;background:color-mix(in srgb,var(--o-surface) 72%,transparent)}
#featured .featured-more-wrap{margin-block-start:3rem}
#featured .featured-more{align-items:center;gap:.8rem;min-height:3rem;border-color:var(--o-line);background:var(--o-surface);color:var(--color-olight-ink);transition:background-color .2s,color .2s,border-color .2s,transform .2s}
#featured .featured-more:hover{transform:translateY(-2px)}
#featured .featured-more span{color:var(--color-olight-gold);font-size:1rem}
@media(max-width:639px){
  #featured .featured-heading{align-items:stretch;gap:1.5rem;margin-block-end:1.75rem}
  #featured .featured-filter-area{gap:.55rem}
  #featured .featured-filters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));width:100%;border-radius:1rem}
  #featured .featured-filter{padding-inline:.5rem}
  #product-grid .product-card{border-radius:.85rem}
  #product-grid .product-media{height:10.5rem}
  #product-grid .product-details{padding:.75rem .8rem .65rem}
  #product-grid .product-price-value{font-size:1.08rem}
  #product-grid .product-title{font-size:.78rem}
  #product-grid .product-spec{gap:.35rem;padding:.65rem .45rem}
  #product-grid .product-spec-icon{width:1.1rem;height:1.1rem}
  #product-grid .product-spec-value{font-size:.68rem}
  #product-grid .product-spec-label{font-size:.58rem}
  #product-grid .product-rating{flex-wrap:wrap;justify-content:center;padding:.65rem .7rem}
  #product-grid .product-rating-label{width:100%;text-align:center}
  #product-grid .product-rating-label,#product-grid .product-rating-count,#product-grid .product-rating-empty{font-size:.56rem}
  #product-grid .product-rating-stars{font-size:.62rem}
  #product-grid .product-rating-score{font-size:.65rem}
}
@media(prefers-reduced-motion:reduce){
  #featured .featured-filter,#featured .featured-more,#product-grid .product-card,#product-grid .product-card img{transition:none}
}
