/* ===================================================
   KARWAVE — New Palette
   Ink Navy #162447 | Gold #FEC903 | Warm White #FAF8F4
   Slate #5A6472   | Green #2E8B57 | Sand #F0EBE3
   =================================================== */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@500;600;700;800&family=Inter:wght@400;500;600;700&family=Noto+Kufi+Arabic:wght@500;600;700;800&display=swap');

/* ── Light tokens ── */
:root {
  --brand:         #053867;
  --brand-mid:     #1e3160;
  --brand-hover:   #0e1a32;
  --brand-light:   #eaecf3;
  --gold:          #FEC903;
  --gold-hover:    #e6b600;
  --gold-dark:     #b38d00;
  --gold-light:    #fff8d6;
  --bg:            #FAF8F4;
  --sand:          #F0EBE3;
  --surface:       #FFFFFF;
  --surface-2:     #F5F2EE;
  --border:        #E2DDD6;
  --text:          #1a1a1a;
  --text-body:     #5A6472;
  --text-muted:    #5A6472;
  --text-faint:    #9aa3ae;
  --green:         #2E8B57;
  --green-bg:      #e4f5ec;
  --red:           #c0392b;
  --red-bg:        #fdecea;
  --warning:       #b45309;
  --warning-bg:    #fef3c7;
  --white:         #FFFFFF;
  --shadow-xs:     0 1px 2px rgba(22,36,71,.06);
  --shadow-sm:     0 2px 8px rgba(22,36,71,.08);
  --shadow-md:     0 6px 20px rgba(22,36,71,.11);
  --shadow-lg:     0 16px 48px rgba(22,36,71,.16);
  --radius-sm:     8px;
  --radius-md:     14px;
  --radius-lg:     22px;
  --font-display:  'Poppins','Noto Kufi Arabic',sans-serif;
  --font-body:     'Inter','Noto Kufi Arabic',sans-serif;
  --container:     1200px;
  --header-h:      66px;
}

/* ── Dark tokens ── */
[data-theme="dark"] {
  --bg:            #0c1120;
  --sand:          #151e30;
  --surface:       #111827;
  --surface-2:     #1c2535;
  --border:        #2a3348;
  --text:          #f0ece6;
  --text-body:     #9aa3ae;
  --text-muted:    #8b95a3;
  --text-faint:    #5a6472;
  --brand-light:   #1a2540;
  --gold-light:    #2a2200;
  --green-bg:      #0e2a1c;
  --red-bg:        #2a0c0a;
  --warning-bg:    #2a1a04;
  --shadow-xs:     0 1px 2px rgba(0,0,0,.25);
  --shadow-sm:     0 2px 8px rgba(0,0,0,.30);
  --shadow-md:     0 6px 20px rgba(0,0,0,.40);
  --shadow-lg:     0 16px 48px rgba(0,0,0,.55);
}

/* ── Reset ── */
*,*::before,*::after{box-sizing:border-box;margin:0;padding:0;}
html{scroll-behavior:smooth;overflow-x:hidden;}
body{font-family:var(--font-body);background:var(--bg);color:var(--text);line-height:1.6;-webkit-font-smoothing:antialiased;transition:background .22s,color .22s;overflow-x:hidden;width:100%;position:relative;}
[dir="rtl"]{font-family:'Noto Kufi Arabic',var(--font-body);}
h1,h2,h3,h4{font-family:var(--font-display);line-height:1.22;color:var(--text);}
a{color:inherit;text-decoration:none;}
img{max-width:100%;display:block;}
button{font-family:inherit;cursor:pointer;}
ul{list-style:none;}
:focus-visible{outline:3px solid var(--gold);outline-offset:3px;}
.container{max-width:var(--container);margin:0 auto;padding:0 24px;}

/* ── Buttons ── */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:13px 26px;border-radius:var(--radius-sm);font-weight:600;font-size:15px;border:2px solid transparent;white-space:nowrap;transition:all .18s ease;}

/* Gold CTA — primary action */
.btn-primary{background:var(--gold);color:var(--brand);border-color:var(--gold);}
.btn-primary:hover{background:var(--gold-hover);border-color:var(--gold-hover);transform:translateY(-1px);box-shadow:0 6px 20px rgba(254,201,3,.35);}

/* Navy — secondary solid */
.btn-brand{background:var(--brand);color:#fff;border-color:var(--brand);}
.btn-brand:hover{background:var(--brand-hover);transform:translateY(-1px);box-shadow:var(--shadow-md);}

/* Outline */
.btn-outline{background:transparent;color:var(--text);border-color:var(--border);}
.btn-outline:hover{border-color:var(--brand);color:var(--brand);}

/* Light outline (on dark bg) */
.btn-outline-light{background:transparent;color:#fff;border-color:rgba(255,255,255,.5);}
.btn-outline-light:hover{background:rgba(255,255,255,.1);}

.btn-block{width:100%;}
.btn-sm{padding:8px 16px;font-size:13px;}
.btn-xs{padding:5px 10px;font-size:12px;}
.btn:disabled{opacity:.45;cursor:not-allowed;transform:none!important;}

/* ── Site Header ── */
.site-header{position:sticky;top:0;z-index:200;background:var(--brand);height:var(--header-h);box-shadow:0 2px 16px rgba(22,36,71,.35);}
.header-inner{display:flex;align-items:center;justify-content:space-between;height:100%;padding:0 24px;gap:20px;}

/* ── Logo image ── */
.logo-img-link {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
}
.site-logo-img {
  display: block;
  height: 38px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  flex-shrink: 0;
}
.footer-logo-img,
.mobile-logo-img {
  height: 34px;
}

/* Nav */
.main-nav{display:flex;align-items:center;gap:2px;}
.main-nav a{padding:9px 14px;border-radius:var(--radius-sm);font-weight:500;font-size:14.5px;color:rgba(255,255,255,.78);}
.main-nav a:hover{background:rgba(255,255,255,.10);color:#fff;}
.main-nav a.active{background:rgba(254,201,3,.15);color:var(--gold);font-weight:600;}

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

/* Theme toggle */
.theme-toggle{display:flex;align-items:center;gap:2px;background:rgba(255,255,255,.08);border-radius:8px;padding:3px;}
.theme-btn{width:30px;height:28px;border-radius:6px;border:none;background:transparent;color:rgba(255,255,255,.55);display:flex;align-items:center;justify-content:center;cursor:pointer;}
.theme-btn.active{background:rgba(254,201,3,.25);color:var(--gold);}
.theme-btn:hover:not(.active){color:#fff;background:rgba(255,255,255,.08);}

/* ── Flag images in language switcher ── */
.lang-flag-img {
  width: 22px;
  height: 16px;
  object-fit: cover;
  border-radius: 3px;
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.18);
}

/* Slightly larger in the dropdown menu */
.lang-menu-item .lang-flag-img {
  width: 26px;
  height: 18px;
}

/* In mobile drawer buttons */
.mobile-lang-btn .lang-flag-img {
  width: 22px;
  height: 15px;
}

/* ── Lang button (trigger) ── */
.lang-switch { position: relative; }
.lang-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 12px;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.16);
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  font-family: var(--font);
  white-space: nowrap;
}
.lang-btn:hover { background: rgba(255,255,255,.15); }
.lang-code { font-size: 13px; font-weight: 700; }

/* ── Lang dropdown menu ── */
.lang-menu {
  position: absolute;
  top: calc(100% + 8px);
  inset-inline-end: 0;
  background: var(--surface);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  min-width: 180px;
  overflow: hidden;
  display: none;
  z-index: 300;
}
.lang-menu.open { display: block; }

.lang-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  font-size: 14px;
  color: var(--text);
  text-decoration: none;
  transition: background .12s;
}
.lang-menu-item:hover { background: var(--sand); }
.lang-menu-item.active {
  background: var(--brand-light);
  font-weight: 700;
}
[data-theme="dark"] .lang-menu-item.active {
  background: rgba(254,201,3,.08);
}
.lang-menu-name {
  flex: 1;
  font-size: 14px;
}
.lang-menu-code {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-faint);
  margin-inline-start: auto;
}
.lang-menu-item.active .lang-menu-code {
  color: var(--brand);
}
[data-theme="dark"] .lang-menu-item.active .lang-menu-code {
  color: var(--gold);
}

/* ── Mobile language buttons with flags ── */
.mobile-lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  background: var(--surface-2);
  color: var(--text-muted);
  text-decoration: none;
  transition: all .15s;
}
.mobile-lang-btn.active {
  background: var(--gold);
  color: var(--brand);
}
.mobile-lang-btn:hover:not(.active) {
  background: var(--sand);
  color: var(--text);
}

/* Cart button */
.cart-btn{position:relative;width:40px;height:40px;border-radius:var(--radius-sm);background:rgba(255,255,255,.08);border:1px solid rgba(255,255,255,.16);display:flex;align-items:center;justify-content:center;color:#fff;}
.cart-btn:hover{background:rgba(254,201,3,.2);border-color:rgba(254,201,3,.4);}
.cart-count{position:absolute;top:-6px;inset-inline-end:-6px;background:var(--gold);color:var(--brand);font-size:10px;font-weight:800;min-width:18px;height:18px;border-radius:9px;display:flex;align-items:center;justify-content:center;padding:0 4px;}

.mobile-toggle{display:none;background:none;border:none;color:#fff;padding:6px;}

/* ── Hero ── */
.hero{background:var(--brand);padding:80px 0 64px;overflow:hidden;position:relative;}
.hero::before{content:'';position:absolute;inset-inline-end:-8%;top:-15%;width:55%;height:130%;background:radial-gradient(ellipse at 70% 40%, rgba(254,201,3,.18) 0%, transparent 65%);pointer-events:none;}
.hero::after{content:'';position:absolute;bottom:0;inset-inline-start:0;inset-inline-end:0;height:4px;background:linear-gradient(90deg,var(--gold) 0%,transparent 100%);}
.hero-inner{display:grid;grid-template-columns:1.15fr 0.85fr;gap:48px;align-items:center;position:relative;z-index:2;}

.eyebrow{display:inline-flex;align-items:center;gap:8px;background:rgba(254,201,3,.14);color:var(--gold);padding:7px 15px;border-radius:100px;font-size:12.5px;font-weight:600;margin-bottom:22px;border:1px solid rgba(254,201,3,.28);}
.eyebrow::before{content:'●';font-size:9px;}

.hero h1{font-size:clamp(30px,4.5vw,52px);color:#fff;margin-bottom:18px;letter-spacing:-.02em;}
.hero h1 span{color:var(--gold);}
.hero p.subtitle{font-size:17px;color:rgba(255,255,255,.7);max-width:460px;margin-bottom:30px;}
.hero-ctas{display:flex;gap:12px;flex-wrap:wrap;margin-bottom:44px;}
.hero-stats{display:flex;gap:32px;flex-wrap:wrap;}
.hero-stat-num{font-family:var(--font-display);font-size:28px;font-weight:800;color:var(--gold);}
.hero-stat-label{font-size:12px;color:rgba(255,255,255,.55);margin-top:2px;}

.hero-visual{display:grid;grid-template-columns:1fr 1fr;gap:14px;}
.hero-card{background:var(--surface);border-radius:var(--radius-lg);padding:16px;box-shadow:var(--shadow-lg);aspect-ratio:1;display:flex;align-items:center;justify-content:center;border:1px solid var(--border);}
.hero-card:nth-child(2){margin-top:32px;}
.hero-card img{width:100%;height:100%;object-fit:contain;}

/* ── Sections ── */
.section{padding:68px 0;}
.section-alt{background:var(--surface);}
.section-head{display:flex;align-items:flex-end;justify-content:space-between;margin-bottom:36px;gap:20px;flex-wrap:wrap;}
.section-head h2{font-size:clamp(22px,3vw,30px);margin-bottom:6px;}
.section-head p{color:var(--text-muted);font-size:15px;}
.section-link{font-weight:600;color:var(--brand);display:flex;align-items:center;gap:5px;white-space:nowrap;font-size:14px;}
.section-link:hover{color:var(--gold-dark);}
[data-theme="dark"] .section-link{color:var(--gold);}

/* ── Category grid ── */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.cat-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  transition: all .18s ease;
  min-height: 260px;
  cursor: pointer;
  text-decoration: none;
  color: var(--text);
}
.cat-card:not(.cat-card-photo) {
  padding: 36px 20px 28px;
  justify-content: center;
  gap: 0;
}
.cat-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: var(--gold);
}
.cat-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 18px;
  background: var(--gold-light);
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand);
}
.cat-icon svg {
  width: 30px;
  height: 30px;
}
[data-theme="dark"] .cat-icon{background:rgba(254,201,3,.12);color:var(--gold);}
.cat-card > span {
  font-weight: 600;
  font-size: 14.5px;
  color: var(--text);
  padding: 0 12px;
  line-height: 1.4;
}

/* ── Product cards ── */
.product-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:22px;}
.product-card{background:var(--surface);border-radius:28px;border:1.5px solid var(--border);overflow:hidden;position:relative;display:flex;flex-direction:column;transition:all .18s ease;}
.product-card:hover{transform:translateY(-5px);box-shadow:var(--shadow-md);border-color:var(--gold);}
.product-thumb{aspect-ratio:1;background:#ffffff !important;border-radius:24px;margin:12px 12px 0;position:relative;overflow:hidden;}
.product-thumb img{width:100%;height:100%;object-fit:contain;padding:8px;}
.product-badge{position:absolute;top:10px;inset-inline-start:10px;background:var(--gold);color:var(--brand);font-size:10.5px;font-weight:800;padding:4px 10px;border-radius:100px;text-transform:uppercase;letter-spacing:.04em;}
.product-body{padding:16px;display:flex;flex-direction:column;gap:7px;flex:1;}
.product-cat{font-size:11px;color:var(--text-faint);font-weight:600;text-transform:uppercase;letter-spacing:.05em;}
.product-name{font-weight:600;font-size:15px;line-height:1.4;color:var(--text);}
.product-card a.product-link{position:absolute;inset:0;z-index:1;}
.product-footer{display:flex;align-items:center;justify-content:space-between;margin-top:auto;padding-top:8px;}
.product-price{font-family:var(--font-display);font-weight:700;font-size:17px;color:var(--brand);}
[data-theme="dark"] .product-price{color:var(--gold);}
.product-price small{font-size:11px;color:var(--text-faint);font-weight:500;}
.product-price .compare{text-decoration:line-through;color:var(--text-faint);font-size:12px;margin-inline-start:5px;}

/* Stock bar */
.stock-strip{display:flex;align-items:center;gap:6px;font-size:12px;color:var(--text-muted);margin-top:2px;}
.stock-bar{flex:1;height:4px;background:var(--border);border-radius:2px;overflow:hidden;}
.stock-bar-fill{height:100%;border-radius:2px;transition:width .4s ease;}
.stock-bar-fill.ok{background:var(--green);}
.stock-bar-fill.medium{background:#d97706;}
.stock-bar-fill.low{background:var(--red);}
.stock-num{font-weight:700;white-space:nowrap;}
.stock-num.ok{color:var(--green);}
.stock-num.medium{color:#d97706;}
.stock-num.low{color:var(--red);}
.stock-num.out{color:var(--text-faint);}

.product-add{position:relative;z-index:2;width:36px;height:36px;border-radius:9px;background:var(--brand);color:#fff;display:flex;align-items:center;justify-content:center;flex-shrink:0;border:none;transition:all .18s ease;}
.product-add:hover{background:var(--gold);color:var(--brand);transform:scale(1.08);}
.product-add:disabled{background:var(--border);color:var(--text-faint);transform:none;cursor:not-allowed;}

/* ── Why cards ── */
.why-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:22px;}
.why-card{background:var(--surface);border:1.5px solid var(--border);border-radius:var(--radius-md);padding:28px 22px;transition:all .18s ease;}
.why-card:hover{border-color:var(--gold);box-shadow:var(--shadow-sm);}
.why-icon{width:52px;height:52px;border-radius:14px;background:var(--brand);color:var(--gold);display:flex;align-items:center;justify-content:center;margin-bottom:16px;}
.why-card h3{font-size:16px;margin-bottom:8px;}
.why-card p{color:var(--text-muted);font-size:14px;line-height:1.7;}

/* ── Blog cards ── */
.blog-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:22px;}
.blog-card{background:var(--surface);border-radius:var(--radius-md);overflow:hidden;border:1.5px solid var(--border);position:relative;transition:all .18s ease;}
.blog-card:hover{transform:translateY(-4px);box-shadow:var(--shadow-md);border-color:var(--gold);}
.blog-thumb{aspect-ratio:16/9;background:var(--sand);overflow:hidden;}
.blog-thumb img{width:100%;height:100%;object-fit:cover;}
.blog-body{padding:20px;}
.blog-date{font-size:11.5px;color:var(--gold-dark);font-weight:700;margin-bottom:8px;text-transform:uppercase;letter-spacing:.04em;}
[data-theme="dark"] .blog-date{color:var(--gold);}
.blog-body h3{font-size:17px;margin-bottom:8px;line-height:1.4;}
.blog-body p{color:var(--text-muted);font-size:13.5px;margin-bottom:12px;}
.blog-readmore{font-weight:600;color:var(--brand);font-size:13.5px;display:inline-flex;align-items:center;gap:5px;}
[data-theme="dark"] .blog-readmore{color:var(--gold);}
.blog-card a.blog-link{position:absolute;inset:0;z-index:1;}

.site-footer{background:var(--brand);color:rgba(255,255,255,.68);padding:60px 0 24px;}
.footer-grid{display:grid;grid-template-columns:1fr auto;gap:36px;padding-bottom:36px;border-bottom:1px solid rgba(255,255,255,.1);justify-content:space-between;}
.footer-logo{font-family:var(--font-display);font-weight:800;font-size:21px;color:#fff;margin-bottom:12px;display:flex;align-items:center;gap:8px;}
.footer-col{justify-self:end;margin-inline-start:auto;}
.footer-col h4{color:var(--gold);font-size:12px;margin-bottom:16px;text-transform:uppercase;letter-spacing:.06em;}
.footer-col ul li{margin-bottom:9px;font-size:14px;}
.footer-col ul li a:hover{color:#fff;}
.footer-bottom{display:flex;flex-direction:row;align-items:center;justify-content:center;text-align:center;padding-top:22px;gap:16px;font-size:12.5px;flex-wrap:wrap;}
.social-row{display:flex;gap:8px;margin-top:16px;}
.social-row a{width:34px;height:34px;border-radius:8px;background:rgba(255,255,255,.07);display:flex;align-items:center;justify-content:center;color:rgba(255,255,255,.65);}
.social-row a:hover{background:var(--gold);color:var(--brand);}

/* ── Page head ── */
.page-head{background:var(--brand);padding:50px 0;text-align:center;position:relative;overflow:hidden;}
.page-head::after{content:'';position:absolute;bottom:0;inset-inline-start:0;inset-inline-end:0;height:3px;background:var(--gold);}
.page-head h1{color:#fff;font-size:clamp(24px,3.5vw,36px);margin-bottom:8px;}
.page-head p{color:rgba(255,255,255,.68);font-size:15.5px;}

.breadcrumb{font-size:13px;color:var(--text-muted);margin-bottom:12px;}
.breadcrumb a:hover{color:var(--brand);}

/* ── Shop ── */
.shop-layout{display:grid;grid-template-columns:220px 1fr;gap:30px;align-items:start;}

/* ── Shop Breadcrumbs & Filter Tags ── */
.shop-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.shop-breadcrumbs a {
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  transition: color 0.2s ease;
}
.shop-breadcrumbs a:hover {
  color: var(--brand);
}
.shop-breadcrumbs .sep {
  color: var(--text-faint);
  font-size: 14px;
}
.shop-breadcrumbs .current {
  color: var(--text);
  font-weight: 700;
}

.shop-status-row {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.product-count-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-muted);
}
.active-filter-chips {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  background: rgba(229, 87, 28, 0.08);
  border: 1px solid rgba(229, 87, 28, 0.3);
  border-radius: 20px;
  font-size: 13.5px;
  font-weight: 700;
  color: #d9480f;
  text-decoration: none;
  transition: all 0.2s ease;
}
[data-theme="dark"] .filter-chip {
  background: rgba(255, 180, 0, 0.12);
  border-color: rgba(255, 180, 0, 0.35);
  color: #fcc419;
}
.filter-chip:hover {
  background: rgba(229, 87, 28, 0.16);
  border-color: #d9480f;
}
.chip-remove {
  font-size: 16px;
  line-height: 1;
  font-weight: 400;
  margin-left: 2px;
}
html[dir="rtl"] .chip-remove {
  margin-left: 0;
  margin-right: 2px;
}
.btn-clear-all {
  color: #e53935;
  font-weight: 700;
  font-size: 13.5px;
  text-decoration: none;
  transition: opacity 0.2s ease;
}
.btn-clear-all:hover {
  text-decoration: underline;
  opacity: 0.85;
}
.filter-box{background:var(--surface);border:1.5px solid var(--border);border-radius:var(--radius-md);padding:18px;position:sticky;top:calc(var(--header-h) + 12px);}
.filter-box h4{font-size:11.5px;text-transform:uppercase;letter-spacing:.06em;margin-bottom:14px;color:var(--text-faint);font-weight:700;}
.filter-list a{display:flex;justify-content:space-between;padding:9px 0;font-size:14px;color:var(--text-body);}
.filter-list a:hover,.filter-list a.active{color:var(--brand);font-weight:600;}
[data-theme="dark"] .filter-list a.active{color:var(--gold);}

/* ── Mobile Filter Bar & Off-canvas Drawer ── */
.mobile-filter-bar { display: none; margin-bottom: 20px; align-items: center; justify-content: space-between; gap: 12px; }

/* View Toggle Controls (Grid / List) */
.view-mode-toggle {
  display: inline-flex;
  align-items: center;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 3px;
  gap: 2px;
}
.btn-view-mode {
  background: none;
  border: none;
  padding: 7px 11px;
  border-radius: calc(var(--radius-sm) - 2px);
  color: var(--text-muted);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}
.btn-view-mode:hover {
  color: var(--brand);
}
.btn-view-mode.active {
  background: var(--brand);
  color: #fff;
}
[data-theme="dark"] .btn-view-mode.active {
  background: var(--gold);
  color: var(--brand);
}

/* List View Styles */
.product-card-desc {
  display: none;
}
.product-grid.view-list {
  grid-template-columns: 1fr !important;
  gap: 18px !important;
}
.product-grid.view-list .product-card-desc {
  display: block;
  font-size: 13.5px;
  color: var(--text-muted);
  margin: 8px 0;
  line-height: 1.55;
}

@media(max-width:900px) {
  .product-grid:not(.view-list) {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
  }
  .product-thumb img, .card-gallery-slide img {
    padding: 6px !important;
  }
}

.btn-filter-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s ease;
}
.btn-filter-toggle:hover {
  border-color: var(--brand);
  color: var(--brand);
}
.filter-badge {
  background: var(--brand);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 10px;
}

.mobile-filter-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(2px);
  z-index: 9998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.mobile-filter-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.mobile-filter-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 340px;
  max-width: 85vw;
  height: 100vh;
  background: var(--surface);
  z-index: 9999;
  box-shadow: -4px 0 24px rgba(0,0,0,0.18);
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}
html[dir="rtl"] .mobile-filter-drawer {
  right: auto;
  left: 0;
  transform: translateX(-100%);
  box-shadow: 4px 0 24px rgba(0,0,0,0.18);
}
.mobile-filter-drawer.active {
  transform: translateX(0) !important;
}

.drawer-header {
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.drawer-header h3 {
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--text);
}
.drawer-close {
  background: none;
  border: none;
  font-size: 24px;
  line-height: 1;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px 8px;
}
.drawer-close:hover { color: var(--brand); }

.drawer-body {
  padding: 20px;
  flex: 1;
  overflow-y: auto;
}
.drawer-subtitle {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: 12px;
  color: var(--text-faint);
  font-weight: 700;
}

.drawer-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}
.btn-apply-drawer {
  width: 100%;
  padding: 12px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
}
.btn-apply-drawer:hover {
  background: var(--gold);
  color: var(--brand);
}

.search-box{display:flex;margin-bottom:24px;max-width:400px;}
.search-box input{flex:1;padding:11px 15px;border:1.5px solid var(--border);border-radius:var(--radius-sm) 0 0 var(--radius-sm);font-size:14px;background:var(--surface);color:var(--text);}
[dir="rtl"] .search-box input{border-radius:0 var(--radius-sm) var(--radius-sm) 0;}
.search-box button{padding:0 16px;background:var(--brand);color:#fff;border-radius:0 var(--radius-sm) var(--radius-sm) 0;border:none;}
.search-box button:hover{background:var(--gold);color:var(--brand);}
[dir="rtl"] .search-box button{border-radius:var(--radius-sm) 0 0 var(--radius-sm);}

/* ── Product detail ── */
.product-detail{display:grid;grid-template-columns:1fr 1fr;gap:50px;align-items:start;}
.pd-gallery{background:#ffffff;border:1.5px solid var(--border);border-radius:var(--radius-lg);padding:36px;aspect-ratio:1;display:flex;align-items:center;justify-content:center;}
.pd-gallery img{max-height:100%;}
.pd-info h1{font-size:28px;margin-bottom:12px;}
.pd-price-row{display:flex;align-items:baseline;gap:12px;margin-bottom:18px;}
.pd-price{font-family:var(--font-display);font-size:30px;font-weight:800;color:var(--brand);}
[data-theme="dark"] .pd-price{color:var(--gold);}
.pd-compare{text-decoration:line-through;color:var(--text-faint);font-size:17px;}
.pd-desc{color:var(--text-muted);margin-bottom:22px;line-height:1.82;font-size:15px;}
.pd-meta{display:flex;gap:14px;margin-bottom:24px;flex-wrap:wrap;}
.pd-meta-item{background:var(--sand);padding:10px 16px;border-radius:var(--radius-sm);font-size:13px;color:var(--text-muted);}
.pd-meta-item b{display:block;font-size:15px;color:var(--text);margin-top:3px;font-weight:700;}

.qty-row{display:flex;align-items:center;gap:14px;margin-bottom:22px;flex-wrap:wrap;}
.qty-stepper{display:flex;align-items:center;border:1.5px solid var(--border);border-radius:var(--radius-sm);overflow:hidden;background:var(--surface);}
.qty-stepper button{width:40px;height:42px;background:var(--sand);font-size:18px;border:none;color:var(--text);transition:background .15s;}
.qty-stepper button:hover{background:var(--gold);color:var(--brand);}
.qty-stepper input{width:54px;height:42px;text-align:center;border:none;border-inline:1.5px solid var(--border);font-size:15px;font-weight:700;background:var(--surface);color:var(--text);}

.stock-pill{display:inline-flex;align-items:center;gap:6px;font-size:12.5px;font-weight:700;}
.stock-pill::before{content:'';width:8px;height:8px;border-radius:50%;background:currentColor;}
.stock-pill.high{color:var(--green);}
.stock-pill.medium{color:#d97706;}
.stock-pill.low,.stock-pill.out{color:var(--red);}

.pd-stock-row{margin-bottom:20px;}
.pd-stock-bar{height:6px;background:var(--border);border-radius:3px;overflow:hidden;margin:6px 0 4px;}
.pd-stock-bar-fill{height:100%;border-radius:3px;transition:width .5s ease;}
.pd-stock-count{font-size:12px;color:var(--text-faint);}

/* ── Cart ── */
.cart-layout{display:grid;grid-template-columns:1fr 340px;gap:30px;align-items:start;}
.cart-item{display:grid;grid-template-columns:74px 1fr auto;gap:14px;align-items:center;background:var(--surface);border:1.5px solid var(--border);border-radius:var(--radius-md);padding:14px;margin-bottom:12px;}
.cart-item-thumb{width:74px;height:74px;background:var(--sand);border-radius:var(--radius-sm);display:flex;align-items:center;justify-content:center;overflow:hidden;}
.cart-item-thumb img{width:100%;height:100%;object-fit:contain;padding:6px;}
.cart-item-name{font-weight:600;margin-bottom:4px;font-size:14.5px;}
.cart-item-price{color:var(--text-muted);font-size:13px;}
.cart-item-actions{display:flex;flex-direction:column;align-items:flex-end;gap:8px;}
.cart-item-remove{color:var(--red);font-size:12.5px;font-weight:600;background:none;border:none;cursor:pointer;}
.cart-summary{background:var(--surface);border:1.5px solid var(--border);border-radius:var(--radius-md);padding:22px;position:sticky;top:calc(var(--header-h)+12px);}
.cart-summary h3{margin-bottom:16px;font-size:17px;}
.cart-summary-row{display:flex;justify-content:space-between;padding:9px 0;font-size:14px;color:var(--text-muted);}
.cart-summary-row.total{border-top:1.5px solid var(--border);margin-top:6px;padding-top:14px;font-weight:700;color:var(--text);font-size:17px;}
.empty-state{text-align:center;padding:72px 20px;}
.empty-state .icon-circle{width:84px;height:84px;background:var(--sand);border-radius:50%;display:flex;align-items:center;justify-content:center;margin:0 auto 22px;color:var(--text-faint);}
.empty-state h3{font-size:21px;margin-bottom:8px;}
.empty-state p{color:var(--text-muted);margin-bottom:22px;}

/* ── Forms ── */
.form-group{margin-bottom:18px;}
.form-group label{display:block;font-weight:600;font-size:13.5px;margin-bottom:7px;color:var(--text);}
.form-group input,.form-group textarea,.form-group select{width:100%;padding:12px 14px;border:1.5px solid var(--border);border-radius:var(--radius-sm);font-size:14px;font-family:inherit;background:var(--surface);color:var(--text);}
.form-group input:focus,.form-group textarea:focus,.form-group select:focus{border-color:var(--gold);outline:none;box-shadow:0 0 0 3px rgba(254,201,3,.18);}
.form-row{display:grid;grid-template-columns:1fr 1fr;gap:14px;}
.checkout-layout{display:grid;grid-template-columns:1fr 360px;gap:36px;align-items:start;}
.order-line{display:flex;justify-content:space-between;padding:9px 0;font-size:13.5px;border-bottom:1px solid var(--border);}

.alert{padding:13px 16px;border-radius:var(--radius-sm);margin-bottom:18px;font-size:13.5px;font-weight:500;}
.alert-success{background:var(--green-bg);color:var(--green);}
.alert-error{background:var(--red-bg);color:var(--red);}

/* ── About ── */
.about-grid{display:grid;grid-template-columns:1.2fr 1fr;gap:50px;align-items:start;}
.value-list{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:18px;}
.value-item{display:flex;align-items:center;gap:9px;background:var(--surface);border:1.5px solid var(--border);padding:13px 14px;border-radius:var(--radius-sm);font-weight:600;font-size:13.5px;color:var(--text);}
.value-item svg{color:var(--green);flex-shrink:0;}
.mission-box{background:var(--brand);border-radius:var(--radius-lg);padding:28px;margin-top:18px;border-top:4px solid var(--gold);}
.mission-box h3{color:var(--gold);font-size:12.5px;text-transform:uppercase;letter-spacing:.06em;margin-bottom:10px;}
.mission-box p{color:rgba(255,255,255,.85);font-size:16px;line-height:1.7;}

/* ── Contact ── */
.contact-layout{display:grid;grid-template-columns:1fr 360px;gap:36px;align-items:start;}
.contact-info-box{background:var(--surface);border:1.5px solid var(--border);border-radius:var(--radius-md);padding:24px;}
.contact-info-item{display:flex;gap:12px;align-items:flex-start;padding:13px 0;border-bottom:1px solid var(--border);}
.contact-info-item:last-child{border:none;}
.contact-icon{width:38px;height:38px;border-radius:9px;background:var(--gold-light);display:flex;align-items:center;justify-content:center;color:var(--brand);flex-shrink:0;}
[data-theme="dark"] .contact-icon{background:rgba(254,201,3,.12);color:var(--gold);}
.contact-info-item b{display:block;font-size:12px;color:var(--text-faint);margin-bottom:2px;}

/* ── Blog post ── */
.post-cover{aspect-ratio:21/9;background:var(--sand);border-radius:var(--radius-lg);overflow:hidden;margin-bottom:28px;}
.post-cover img{width:100%;height:100%;object-fit:cover;}
.post-content{max-width:740px;margin:0 auto;}
.post-meta{color:var(--text-faint);font-size:13px;margin-bottom:14px;text-transform:uppercase;letter-spacing:.04em;font-weight:600;}
.post-body{font-size:16.5px;line-height:1.9;color:var(--text);}
.post-body p{margin-bottom:18px;}

/* ── 404 ── */
.error-page{text-align:center;padding:110px 20px;}
.error-page .big-num{font-family:var(--font-display);font-size:96px;font-weight:800;color:var(--gold);line-height:1;}

/* ── Toast ── */
.toast{position:fixed;bottom:22px;inset-inline-start:50%;transform:translateX(-50%) translateY(80px);background:var(--brand);color:#fff;padding:13px 22px;border-radius:var(--radius-sm);font-size:14px;font-weight:600;box-shadow:var(--shadow-lg);z-index:1000;transition:transform .3s ease;white-space:nowrap;border-bottom:3px solid var(--gold);}
[dir="rtl"] .toast{transform:translateX(50%) translateY(80px);}
.toast.show{transform:translateX(-50%) translateY(0);}
[dir="rtl"] .toast.show{transform:translateX(50%) translateY(0);}

/* ══════════════════════════════════════════
   MOBILE DRAWER
   ══════════════════════════════════════════ */
.mobile-backdrop {
  display: none;
  position: fixed; inset: 0; z-index: 298;
  background: rgba(0,0,0,.45);
  backdrop-filter: blur(2px);
}
.mobile-backdrop.open { display: block; }

.mobile-drawer {
  position: fixed;
  top: 0; bottom: 0;
  inset-inline-start: 0;
  width: min(320px, 88vw);
  background: var(--surface);
  z-index: 299;
  display: flex; flex-direction: column;
  overflow-y: auto;
  --drawer-translate: -110%;
  transform: translateX(var(--drawer-translate));
  transition: transform .3s cubic-bezier(.25,.46,.45,.94);
  box-shadow: 4px 0 32px rgba(22,36,71,.22);
}
[dir="rtl"] .mobile-drawer {
  --drawer-translate: 110%;
  box-shadow: -4px 0 32px rgba(22,36,71,.22);
}
.mobile-drawer.open {
  transform: translateX(0);
}

.mobile-drawer-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  background: var(--brand);
  flex-shrink: 0;
}
.mobile-drawer-head .logo { color: #fff; }
.mobile-drawer-head .logo-text { color: #fff; }

.mobile-close {
  width: 36px; height: 36px; border-radius: 8px;
  background: rgba(255,255,255,.12); border: none;
  color: #fff; display: flex; align-items: center; justify-content: center;
  cursor: pointer; flex-shrink: 0;
}
.mobile-close:hover { background: rgba(255,255,255,.22); }

.mobile-nav { padding: 10px 10px 0; flex-shrink: 0; }
.mobile-nav-link {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 14px; border-radius: 10px;
  font-size: 15px; font-weight: 500; color: var(--text);
  margin-bottom: 2px; width: 100%;
}
.mobile-nav-link:hover { background: var(--sand); }
.mobile-nav-link.active {
  background: var(--brand-light); color: var(--brand); font-weight: 700;
}
[data-theme="dark"] .mobile-nav-link.active { color: var(--gold); }
.mobile-nav-link svg { color: var(--text-muted); flex-shrink: 0; }
.mobile-nav-link.active svg { color: var(--brand); }
[data-theme="dark"] .mobile-nav-link.active svg { color: var(--gold); }

.mobile-drawer-divider { height: 1px; background: var(--border); margin: 10px 0; flex-shrink: 0; }

.mobile-auth { padding: 4px 10px 10px; flex-shrink: 0; }
.mobile-user-row { display:flex; align-items:center; gap:12px; padding:10px 14px; margin-bottom:6px; background:var(--sand); border-radius:10px; }

.mobile-settings { padding: 4px 18px 24px; flex-shrink: 0; }
.mobile-settings .theme-toggle {
  display: flex;
  align-items: center;
  gap: 4px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 4px;
  width: 100%;
}
.mobile-settings .theme-btn {
  flex: 1;
  height: 34px;
  width: auto;
  border-radius: 7px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}
.mobile-settings .theme-btn svg {
  flex-shrink: 0;
  color: var(--text-muted);
}
.mobile-settings .theme-btn.active {
  background: var(--surface);
  color: var(--brand);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}
[data-theme="dark"] .mobile-settings .theme-btn.active {
  background: var(--brand-light);
  color: var(--gold);
  border: 1px solid var(--border);
}
.mobile-settings .theme-btn.active svg {
  color: currentColor;
}
.mobile-settings .theme-btn:hover:not(.active) {
  color: var(--text);
  background: rgba(0, 0, 0, 0.04);
}
[data-theme="dark"] .mobile-settings .theme-btn:hover:not(.active) {
  background: rgba(255, 255, 255, 0.05);
}

/* Show/hide desktop vs mobile elements */
.desktop-nav { display: block; }
.desktop-only { display: flex; }
.mobile-toggle { display: none !important; }

/* ══════════════════════════════════════════
   RESPONSIVE BREAKPOINTS
   ══════════════════════════════════════════ */

/* Tablet — 1024px */
@media(max-width:1024px) {
  /* Show hamburger, hide desktop nav earlier to prevent overlap */
  .desktop-nav { display: none; }
  .desktop-only { display: none !important; }
  .mobile-toggle { display: flex !important; }
  
  .cat-grid { grid-template-columns: repeat(2,1fr); }
  .product-grid { grid-template-columns: repeat(3,1fr); }
  .why-grid { grid-template-columns: repeat(2,1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

/* Tablet portrait / large mobile — 900px */
@media(max-width:900px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { max-width: 320px; margin: 0 auto; }
  .product-grid { grid-template-columns: repeat(2,1fr); }
  .blog-grid { grid-template-columns: 1fr 1fr; }
  .shop-layout { grid-template-columns: 1fr; }
  .shop-layout > .filter-box { display: none !important; }
  .shop-layout > div > .search-box { display: none !important; }
  .mobile-filter-bar { display: flex; }
  .product-detail { grid-template-columns: 1fr; }
  .cart-layout { grid-template-columns: 1fr; }
  .checkout-layout { grid-template-columns: 1fr; }
  .contact-layout { grid-template-columns: 1fr; }
  .about-grid { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: repeat(2,1fr); }
}

/* Mobile — 600px */
@media(max-width:600px) {
  .container { padding: 0 16px; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .cat-card { min-height: 180px; }
  .cat-card { min-height: 180px; }
  .product-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .blog-grid { grid-template-columns: 1fr; }
  .why-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-col { justify-self: start !important; margin-inline-start: 0 !important; }
  .form-row { grid-template-columns: 1fr; }
  .hero { padding: 44px 0 30px; }
  .hero h1 { font-size: 26px; }
  .hero-ctas { flex-direction: column; }
  .hero-ctas .btn { width: 100%; text-align: center; justify-content: center; }
  .hero-stats { gap: 18px; }
  .value-list { grid-template-columns: 1fr; }
  .section { padding: 44px 0; }
  .section-head { flex-direction: column; align-items: flex-start; }
  .pd-price-gate { flex-direction: column; gap: 10px; }
  .pd-price-gate .gate-actions { flex-direction: row; }
  .cart-item { grid-template-columns: 60px 1fr; }
  .cart-item-actions { grid-column: 1 / -1; flex-direction: row; }
}

/* Small mobile — 400px */
@media(max-width:400px) {
  .cat-grid { grid-template-columns: repeat(2,1fr); }
  .hero-stat-num { font-size: 22px; }
  .logo-text { font-size: 18px; }
}

/* ── User auth pill (logged-in state in header) ── */
.user-pill {
  display: flex; align-items: center; gap: 7px;
  background: rgba(255,255,255,.10); border: 1px solid rgba(255,255,255,.18);
  border-radius: var(--radius-sm); padding: 6px 10px 6px 7px;
}
.user-pill-avatar {
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--gold); color: var(--brand);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 800; flex-shrink: 0;
}
.user-pill-name { font-size: 13.5px; font-weight: 600; color: #fff; max-width: 90px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-pill-logout { color: rgba(255,255,255,.55); display: flex; align-items: center; margin-inline-start: 4px; }
.user-pill-logout:hover { color: var(--gold); }

/* ── Header login link (ghost, not button) ── */
.btn-header-login {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 12px; border-radius: var(--radius-sm);
  font-size: 13.5px; font-weight: 600; color: rgba(255,255,255,.82);
}
.btn-header-login:hover { background: rgba(255,255,255,.10); color: #fff; }

/* ── Price gate — hidden price for guests ── */
.price-gate {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--sand); border: 1.5px dashed var(--border);
  border-radius: 7px; padding: 6px 12px;
  font-size: 13px; font-weight: 600; color: var(--text-muted);
  white-space: nowrap;
}
[data-theme="dark"] .price-gate { background: var(--surface-2); }
.price-gate svg { color: var(--gold-dark); flex-shrink: 0; }
[data-theme="dark"] .price-gate svg { color: var(--gold); }
.price-gate a { color: var(--brand); font-weight: 700; }
[data-theme="dark"] .price-gate a { color: var(--gold); }
.price-gate a:hover { color: var(--gold-dark); }

/* ── Guest banner on shop/product pages ── */
.guest-banner {
  background: var(--brand); color: #fff;
  padding: 13px 24px; text-align: center; font-size: 14px;
  display: flex; align-items: center; justify-content: center; gap: 12px;
  flex-wrap: wrap;
}
.guest-banner strong { color: var(--gold); }
.guest-banner a.gb-login { color: var(--gold); font-weight: 700; text-decoration: underline; }
.guest-banner a.gb-register { background: var(--gold); color: var(--brand); padding: 6px 16px; border-radius: 6px; font-weight: 700; font-size: 13px; }
.guest-banner a.gb-register:hover { background: var(--gold-hover); }

/* ── Product page price gate (larger) ── */
.pd-price-gate {
  background: var(--sand); border: 1.5px dashed var(--border);
  border-radius: var(--radius-sm); padding: 16px 20px; margin-bottom: 22px;
  display: flex; align-items: center; gap: 14px;
}
[data-theme="dark"] .pd-price-gate { background: var(--surface-2); }
.pd-price-gate .lock-icon {
  width: 44px; height: 44px; background: var(--gold-light); border-radius: 10px;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--gold-dark);
}
[data-theme="dark"] .pd-price-gate .lock-icon { background: rgba(254,201,3,.12); color: var(--gold); }
.pd-price-gate .gate-text { flex: 1; }
.pd-price-gate .gate-text strong { display: block; font-size: 15px; margin-bottom: 3px; }
.pd-price-gate .gate-text span { font-size: 13px; color: var(--text-muted); }
.pd-price-gate .gate-actions { display: flex; gap: 8px; flex-shrink: 0; flex-wrap: wrap; }

/* =============================================
   CAROUSEL
   ============================================= */
.carousel-wrap {
  position: relative;
  overflow: hidden;
  background: var(--brand);
  user-select: none;
}

.carousel-track {
  display: flex;
  transition: transform 0.55s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform;
}

.carousel-slide {
  min-width: 100%;
  position: relative;
}

/* Image fills the slide */
.carousel-slide img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

/* Overlay for text readability */
.carousel-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(22,36,71,.72) 0%,
    rgba(22,36,71,.38) 55%,
    transparent 100%
  );
  display: flex;
  align-items: center;
}
[dir="rtl"] .carousel-overlay {
  background: linear-gradient(
    270deg,
    rgba(22,36,71,.72) 0%,
    rgba(22,36,71,.38) 55%,
    transparent 100%
  );
}

.carousel-content {
  padding: 0 80px;
  max-width: 640px;
  animation: slideFadeIn 0.6s ease both;
}
@keyframes slideFadeIn {
  from { opacity:0; transform: translateY(18px); }
  to   { opacity:1; transform: translateY(0); }
}
.carousel-slide.active .carousel-content { animation: slideFadeIn 0.6s ease 0.1s both; }

.carousel-content h2 {
  font-family: var(--font-display);
  font-size: clamp(24px, 3.5vw, 44px);
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
  margin-bottom: 14px;
  text-shadow: 0 2px 12px rgba(0,0,0,.25);
}
.carousel-content h2 em {
  color: var(--gold);
  font-style: normal;
}
.carousel-content p {
  font-size: clamp(14px, 1.6vw, 17px);
  color: rgba(255,255,255,.82);
  margin-bottom: 26px;
  line-height: 1.65;
}
.carousel-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--gold);
  color: var(--brand);
  padding: 13px 28px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 15px;
  transition: all .2s ease;
}
.carousel-cta:hover {
  background: var(--gold-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(254,201,3,.35);
}

/* ── Prev / Next arrows ── */
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,.12);
  border: 1.5px solid rgba(255,255,255,.22);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all .18s ease;
  backdrop-filter: blur(4px);
}
.carousel-arrow:hover {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--brand);
  transform: translateY(-50%) scale(1.08);
}
.carousel-arrow-prev { inset-inline-start: 20px; }
.carousel-arrow-next { inset-inline-end: 20px; }
html[dir="rtl"] .carousel-arrow svg { transform: scaleX(-1); }

/* ── Dot indicators ── */
.carousel-dots {
  position: absolute;
  bottom: 20px;
  inset-inline-start: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 20;
}
.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 4px;
  background: rgba(255,255,255,.4);
  cursor: pointer;
  transition: all .25s ease;
  border: none;
  padding: 0;
}
.carousel-dot.active {
  width: 28px;
  background: var(--gold);
}
.carousel-dot:hover:not(.active) { background: rgba(255,255,255,.7); }

/* ── Progress bar ── */
.carousel-progress {
  position: absolute;
  bottom: 0;
  inset-inline-start: 0;
  height: 3px;
  background: var(--gold);
  z-index: 20;
  transition: none;
}
.carousel-progress.animating {
  transition: width linear;
}

/* ── Pause on hover indicator ── */
.carousel-paused-badge {
  position: absolute;
  top: 14px;
  inset-inline-end: 20px;
  background: rgba(0,0,0,.45);
  color: rgba(255,255,255,.8);
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  display: none;
  z-index: 20;
}
.carousel-wrap:hover .carousel-paused-badge { display: block; }

/* ── Thumbnail strip (optional, hidden on small screens) ── */
.carousel-thumbs {
  display: flex;
  gap: 6px;
  padding: 8px 20px;
  background: var(--brand);
  overflow-x: auto;
  scrollbar-width: none;
}
.carousel-thumbs::-webkit-scrollbar { display: none; }
.carousel-thumb {
  flex-shrink: 0;
  width: 80px;
  height: 46px;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  opacity: .55;
  border: 2px solid transparent;
  transition: all .18s ease;
}
.carousel-thumb img { width: 100%; height: 100%; object-fit: cover; }
.carousel-thumb.active { opacity: 1; border-color: var(--gold); }
.carousel-thumb:hover:not(.active) { opacity: .8; }

/* ── Responsive ── */
@media (max-width: 768px) {
  /* removed fixed carousel height */
  .carousel-content { padding: 0 40px; max-width: 100%; }
  .carousel-content h2 { font-size: 24px; }
  .carousel-content p { font-size: 14px; margin-bottom: 18px; }
  .carousel-cta { padding: 11px 20px; font-size: 14px; }
  .carousel-arrow { width: 38px; height: 38px; }
  .carousel-thumbs { display: none; }
}
@media (max-width: 480px) {
  /* removed fixed carousel height */
  .carousel-content { padding: 0 20px; }
  .carousel-arrow { display: none; }
}

/* =============================================
   COLOR SWATCHES & PRODUCT GALLERY
   ============================================= */

/* ── Card swatches ── */
.product-swatches {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.swatch {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid var(--surface);
  box-shadow: 0 0 0 1.5px var(--border);
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
  flex-shrink: 0;
  display: inline-block;
}
.swatch:hover { transform: scale(1.22); box-shadow: 0 0 0 2px var(--brand); }
.swatch.active  { box-shadow: 0 0 0 2.5px var(--gold); transform: scale(1.15); }
.swatch-more {
  width: 20px; height: 20px; border-radius: 50%;
  background: var(--surface-2); border: 1.5px solid var(--border);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 9px; font-weight: 800; color: var(--text-muted);
  cursor: default;
}

/* ── Product card mini gallery (dots) ── */
.product-card-gallery { position: relative; overflow: hidden; }
.card-gallery-track {
  display: flex;
  transition: transform .35s ease;
}
.card-gallery-slide {
  min-width: 100%;
  aspect-ratio: 1;
  background: #ffffff !important;
  display: flex; align-items: center; justify-content: center;
}
.card-gallery-slide img {
  width: 100%; height: 100%;
  object-fit: contain; padding: 8px;
}
.card-gallery-dots {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 10px 0 0;
  z-index: 5;
}
.card-gallery-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #cbd5e1;
  border: none; cursor: pointer; padding: 0;
  transition: all .25s ease;
}
.card-gallery-dot.active {
  width: 26px;
  border-radius: 10px;
  background: var(--brand);
}
[data-theme="dark"] .card-gallery-dot { background: rgba(255,255,255,.3); }
[data-theme="dark"] .card-gallery-dot.active { background: var(--gold); }

/* Card Gallery Arrows (< and >) */
.card-gal-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #ffffff;
  border: 1.5px solid #ffffff;
  color: var(--brand);
  box-shadow: 0 3px 10px rgba(0,0,0,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 1 !important;
  transition: all 0.25s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}
.pd-main-image .card-gal-arrow {
  width: 48px;
  height: 48px;
}
.card-gal-arrow:hover {
  background: rgba(255, 255, 255, 0.45) !important;
  border-color: rgba(255, 255, 255, 0.6) !important;
  color: var(--brand);
  box-shadow: none;
  backdrop-filter: blur(6px);
}
.card-gal-arrow:focus,
.card-gal-arrow:active {
  background: #ffffff;
  border-color: #ffffff;
  outline: none;
}
.card-gal-arrow-prev { inset-inline-start: 8px; }
.card-gal-arrow-next { inset-inline-end: 8px; }
html[dir="rtl"] .card-gal-arrow svg { transform: scaleX(-1); }

@media(max-width: 900px) {
  .product-card .card-gal-arrow {
    width: 34px !important;
    height: 34px !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12) !important;
  }
  .product-card .card-gal-arrow svg {
    width: 14px !important;
    height: 14px !important;
  }
  .product-card .card-gal-arrow-prev { inset-inline-start: 6px !important; }
  .product-card .card-gal-arrow-next { inset-inline-end: 6px !important; }

  .pd-main-image .card-gal-arrow {
    width: 42px !important;
    height: 42px !important;
  }
}

/* ── Product code on card ── */
.product-code {
  font-size: 11px;
  color: var(--text-faint);
  font-weight: 600;
  letter-spacing: .03em;
  display: flex;
  align-items: center;
  gap: 5px;
}
.product-code button {
  background: none; border: none; padding: 0;
  color: var(--text-faint); cursor: pointer; line-height: 1;
}
.product-code button:hover { color: var(--brand); }
[data-theme="dark"] .product-code button:hover { color: var(--gold); }

/* ── Detail page gallery ── */
.pd-gallery-wrap {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.pd-main-image {
  background: var(--sand);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  aspect-ratio: 1;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  position: relative;
}
.pd-main-image img {
  width: 100%; height: 100%;
  object-fit: contain; padding: 32px;
  transition: opacity .25s ease;
}
.pd-main-image img.switching { opacity: 0; }
.pd-thumbs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.pd-thumb {
  width: 68px; height: 68px;
  border-radius: 10px;
  border: 2px solid var(--border);
  background: var(--sand);
  overflow: hidden; cursor: pointer;
  transition: border-color .15s ease;
  flex-shrink: 0;
}
.pd-thumb img {
  width: 100%; height: 100%;
  object-fit: contain; padding: 6px;
}
.pd-thumb:hover { border-color: var(--brand); }
.pd-thumb.active { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold); }

/* ── Detail page swatches ── */
.pd-colors { margin-bottom: 22px; }
.pd-colors-label {
  font-size: 13px; font-weight: 600;
  color: var(--text-muted); margin-bottom: 10px;
  display: flex; align-items: center; gap: 8px;
}
.pd-colors-label span {
  color: var(--text); font-weight: 700;
}
.pd-swatches {
  display: flex; gap: 9px; flex-wrap: wrap;
}
.pd-swatch {
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 3px solid var(--surface);
  box-shadow: 0 0 0 1.5px var(--border);
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
  position: relative;
}
.pd-swatch:hover { transform: scale(1.15); box-shadow: 0 0 0 2px var(--brand); }
.pd-swatch.active {
  box-shadow: 0 0 0 3px var(--gold);
  transform: scale(1.1);
}
.pd-swatch.active::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: rgba(255,255,255,.25);
}

/* ── Category card image thumbnail ── */
.cat-thumb {
  width: 72px;
  height: 72px;
  border-radius: 14px;
  overflow: hidden;
  margin: 0 auto 12px;
  border: 1.5px solid var(--border);
  background: var(--sand);
  flex-shrink: 0;
}
.cat-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s ease;
}
.cat-card:hover .cat-thumb img {
  transform: scale(1.08);
}

/* ── Category card with full-bleed photo (like reference image 2) ── */
.cat-card-photo {
  padding: 0;
  overflow: hidden;
  border-radius: var(--radius-md);
  display: block;
  position: relative;
  background: var(--surface);
}
.cat-card-photo:hover { transform: translateY(-5px); }

.cat-card-img {
  width: 100%; 
  display: block;
}
.cat-card-img img {
  width: 100%; 
  height: auto;
  object-fit: contain;
  transition: transform .35s ease;
  display: block;
}
.cat-card-photo:hover .cat-card-img img { transform: scale(1.06); }

.cat-card-overlay {
  position: absolute; inset: 0;
  background: radial-gradient(circle at bottom center, rgba(0,0,0,0.2) 0%, transparent 60%);
  pointer-events: none;
}
.cat-card-label {
  position: absolute;
  bottom: 16px; left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--text);
  font-family: var(--font-display);
  font-size: 13.5px;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.14);
  white-space: normal;
  text-align: center;
  max-width: calc(100% - 24px);
  line-height: 1.35;
  z-index: 2;
  transition: all .2s ease;
}
.cat-card-photo:hover .cat-card-label {
  background: #053867;
  color: #ffffff;
}

/* Tablet — 2 columns */
@media(max-width: 1024px) {
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Small mobile — 2 columns still, slightly smaller */
@media(max-width: 400px) {
  .cat-card { min-height: 160px; }
  .cat-card { min-height: 160px; }
}

@media(max-width:500px) {
  .cat-card-label { font-size: 12px; padding: 6px 12px; bottom: 10px; }
}

/* ── Services section on homepage ── */
.services-home-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.service-home-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all .18s ease;
  text-decoration: none;
  color: var(--text);
}
.service-home-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--gold);
}

/* When a cover image exists */
.service-home-img {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--sand);
  flex-shrink: 0;
}
.service-home-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s ease;
}
.service-home-card:hover .service-home-img img {
  transform: scale(1.04);
}

/* When no image — show icon placeholder like why-cards */
.service-home-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--brand);
  color: var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 24px 22px 0;
  flex-shrink: 0;
}

.service-home-body {
  padding: 18px 22px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.service-home-body h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  line-height: 1.35;
  color: var(--text);
}
.service-home-body p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  flex: 1;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.service-home-link {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--brand);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: auto;
}
[data-theme="dark"] .service-home-link { color: var(--gold); }
.service-home-card:hover .service-home-link { color: var(--gold-dark); }
[data-theme="dark"] .service-home-card:hover .service-home-link { color: var(--gold-hover); }

/* Responsive */
@media(max-width: 900px) {
  .services-home-grid { grid-template-columns: repeat(2, 1fr); }
}
@media(max-width: 560px) {
  .services-home-grid { grid-template-columns: 1fr; gap: 14px; }
}

/* ── Password input with eye toggle ── */
.pw-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.pw-wrap input[type="password"],
.pw-wrap input[type="text"] {
  width: 100%;
  padding-inline-end: 44px;
}

.pw-toggle {
  position: absolute;
  inset-inline-end: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-faint);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: 5px;
  transition: color .15s ease;
  line-height: 1;
  flex-shrink: 0;
}

.pw-toggle:hover {
  color: var(--brand);
}

[data-theme="dark"] .pw-toggle:hover {
  color: var(--gold);
}

.pw-wrap input {
  padding-right: 44px;
}
[dir="rtl"] .pw-wrap input {
  padding-right: 14px;
  padding-left: 44px;
}
