/*
Theme Name: Polyabzar
Description: قالب اختصاصی فروشگاه پلی‌ابزار — Orac-inspired warm monochrome, RTL-first, WooCommerce.
Author: Polyabzar
Version: 0.15.2
Requires PHP: 8.0
Text Domain: polyabzar
*/

/* ---------- Fonts (local woff2, ported from the Next.js site) ----------
   Two families only: Markazi Text carries every piece of text on the site,
   Gulzar is the nastaliq accent and appears in exactly one place
   (.hero-tagline). Almarai was dropped 2026-08-02 — it had been the body
   face while Markazi did headings and product-card titles, but the user
   preferred Markazi's texture and asked for it everywhere.

   Markazi is a VARIABLE font with a 400-700 range. There is no 300 and no
   800: any lighter value silently clamps up to 400, so `font-weight: 300`
   (which body used under Almarai) would have rendered *heavier* than
   intended, not lighter. Weight is now the only hierarchy signal left
   between body and headings, so keep 400 for text and >=600 for headings —
   don't reintroduce a 300 anywhere. */

/* Markazi Text - variable Naskh display face for headlines (Orac-style serif) */
@font-face {
  font-family: 'Markazi Text';
  src: url('fonts/MarkaziText-arabic.woff2') format('woff2');
  font-weight: 400 700;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
@font-face {
  font-family: 'Markazi Text';
  src: url('fonts/MarkaziText-latin.woff2') format('woff2');
  font-weight: 400 700;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Same two files again, re-declared under a second family name whose only
   difference is `size-adjust`. This is the body face.

   Why it has to exist: every font-size below ~20px in this stylesheet was
   tuned against Almarai, and Markazi sets much smaller at the same px —
   measured against Almarai at matched size, its running text has ~0.84x the
   ink height (and 0.74x the width). Dropped in raw, all the small text —
   12px eyebrows, 11px badges, 10px cart counters — became genuinely hard to
   read, and body copy looked lost inside its own 1.8 leading.

   size-adjust scales the glyphs while leaving the computed font-size, line
   boxes and layout untouched, so this lifts EVERY small size at once
   without editing a single font-size rule. Hand-retuning ~14 steps of the
   ramp scattered through 100KB of CSS would have been the alternative, and
   would drift out of sync the moment a new rule was added.

   118% comes from measuring real Persian strings, not a single glyph: the
   bowl-height and UI-label ratios both land at ~1.19. Matching pure
   x-height instead would want ~1.46, which overshoots badly — Markazi
   carries a small base letterform with long extenders, so scaling to match
   Almarai's x-height would make its ascenders and dots enormous.

   Headings deliberately keep the UNADJUSTED 'Markazi Text' face: they were
   already set in Markazi and already sized correctly, so touching their
   metrics would break every tuned clamp() in the file.

   Net width check: 0.74 x 1.18 = 0.87, so body text still sets ~13%
   narrower than Almarai did — fixed-width UI (badges, pills, nav) has
   margin rather than overflow risk. */
@font-face {
  font-family: 'Markazi Body';
  src: url('fonts/MarkaziText-arabic.woff2') format('woff2');
  font-weight: 400 700;
  font-display: swap;
  size-adjust: 118%;
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
@font-face {
  font-family: 'Markazi Body';
  src: url('fonts/MarkaziText-latin.woff2') format('woff2');
  font-weight: 400 700;
  font-display: swap;
  size-adjust: 118%;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Gulzar - Nastaliq calligraphic accent face, used sparingly (hero taglines)

   204 KB, and it is the largest single asset on the homepage — bigger than
   this stylesheet, bigger than any photograph. That is tempting to "fix".

   DO NOT SUBSET IT. Tried and measured 2026-08-11 with fontTools: subsetting
   to the Persian charset gives 124 KB (and to the exact tagline strings,
   86 KB) but the result is visibly BROKEN — the letters stop joining and the
   Nastaliq cascade collapses into disconnected glyphs. The give-away is the
   rendered width: the same tagline sets 239px subsetted against 212px
   whole, because the contextual substitutions that pull the cascade together
   are gone. Nastaliq resolves through long GSUB chains and fontTools' glyph
   closure does not keep the intermediate glyphs those chains need, with or
   without --layout-features=*. It fails silently: the font still loads, still
   reports `status: loaded`, and simply renders wrong.

   If this ever has to shrink, the route is a Nastaliq-aware tool (or dropping
   the face on mobile via a media-scoped @font-face), not a glyph subset. */
@font-face {
  font-family: 'Gulzar';
  src: url('fonts/Gulzar-arabic.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

/* ---------- Design tokens (ported from app/globals.css) ----------
   Orac-inspired warm monochrome: ink on white, warm-gray surfaces.
   No color accents — color comes from photography; gold is deliberate. */

:root {
  --background: #F7F5F2;
  --foreground: #232323;
  --card: #F2EEE7;
  --primary: #232323;
  --primary-foreground: #F7F5F2;
  --secondary: #EFEAE2;
  --secondary-foreground: #3A3A3A;
  --muted: #EDE7DD;
  /* Was #777777 — 4.11:1 on --background and 3.87:1 on --card, i.e. every
     piece of secondary copy on the site failed WCAG AA. #5F5C57 keeps the
     warm-gray cast (it is not a neutral #555) at 6.1:1 / 5.8:1. */
  --muted-foreground: #5F5C57;
  --accent: #EDE6DA;
  --accent-foreground: #3A3A3A;
  --destructive: oklch(0.5 0.19 27);
  --border: #E2DCD1;
  --input: #E2DCD1;
  --ring: #B08D57;

  /* Two golds on purpose. --brand-gold is the DECORATIVE value: rules, pins,
     borders, icon strokes, focus rings — surfaces where contrast rules don't
     apply and where the lighter tone is the whole point. It is 2.84:1 on the
     cream ground, so it must never carry text. --brand-gold-text (4.6:1) and
     --brand-bronze-text (5.9:1) are the readable counterparts; the product
     price used the old bronze at 4.06:1, which made the single most
     decision-relevant number on the site the least legible thing on it. */
  --brand-gold: #B08D57;
  --brand-gold-text: #8A6A3A;
  --brand-bronze: #947244;
  --brand-bronze-text: #7A5C33;
  --sale: #B91C1C;

  /* ---- Elevation ----------------------------------------------------------
     Grouped by ROLE, not as a 1-2-3-4 ramp. This surface has three genuinely
     different shadow jobs — a contact shadow on a small control, a lift on a
     flat card, and a deep spread under an overlay — and forcing them onto one
     numeric ramp would make unrelated cases share a value they don't want.

     Before this block there were fourteen hand-written box-shadows using
     eight different black alphas (.05 .06 .08 .1 .15 .2 .25 .28 .3 .35) with
     nothing to explain why a card was .06 and a carousel arrow .15. Near-
     duplicates were merged (.06/.1 → .08, and the two card-hover shadows that
     differed by 2px of blur and .03 alpha); every other value is preserved,
     because the difference was doing real work. */
  --shadow-contact: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-contact-strong: 0 1px 3px rgba(0, 0, 0, 0.2);
  /* Small controls sitting ON photography need more than a contact shadow:
     the backdrop is arbitrary, so the shadow is the only thing separating a
     white dot from a white wall behind it. */
  --shadow-on-photo: 0 1px 3px rgba(0, 0, 0, 0.32);
  --shadow-lift: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-raised: 0 4px 14px rgba(0, 0, 0, 0.15);
  --shadow-raised-hover: 0 6px 20px rgba(0, 0, 0, 0.2);
  --shadow-card-hover: 0 13px 24px -15px rgba(0, 0, 0, 0.26);
  --shadow-overlay: 0 12px 28px -8px rgba(0, 0, 0, 0.28), 0 2px 6px rgba(0, 0, 0, 0.08);
  --shadow-panel: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  --hairline: 0 0 0 1px rgba(0, 0, 0, 0.05);

  /* ---- Layers over imagery -----------------------------------------------
     Backdrops behind an overlay, and the white glass used on controls that
     float over a photo. The hero's own scrim gradients are deliberately NOT
     here: they are a tuned three-stop pair with different values per
     breakpoint (see .hero-scrim), so a shared token would only add a name
     nothing else can reuse. */
  --scrim-backdrop: rgba(0, 0, 0, 0.5);
  --scrim-media: rgba(0, 0, 0, 0.85);
  --glass: rgba(255, 255, 255, 0.95);

  /* One typeface, two optical sizes: body and display are the same Markazi
     outlines, differing only by the 118% size-adjust on the body face (see
     @font-face). Keeping them as two tokens also preserves the ~40 rules
     that say `var(--font-display)` to mean "this is a heading", so bringing
     back a genuinely separate display face later stays a one-line change. */
  --font-body: 'Markazi Body', 'Markazi Text', serif;
  --font-display: 'Markazi Text', serif;
  --font-accent: 'Gulzar', 'Markazi Text', serif;

  --container: 96rem;
  --radius: 0.375rem;
}

.dark {
  --background: #1A1817;
  --foreground: #F7F5F2;
  --card: #232323;
  --primary: #F7F5F2;
  --primary-foreground: #232323;
  --secondary: #2C2A27;
  --secondary-foreground: #F7F5F2;
  --muted: #2C2A27;
  --muted-foreground: #A8A29A;
  --accent: #3D3527;
  --accent-foreground: #F7F5F2;
  --border: #3A3733;
  --input: #3A3733;
  /* The darkened text golds exist to survive a near-white ground. On the
     dark ground they invert: the decorative gold is already 5.7:1 here, and
     the darkened ones would be the unreadable pair. */
  --brand-gold-text: #B08D57;
  --brand-bronze-text: #C39A63;
  --sale: #F87171;
}

/* ---------- Base ---------- */

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

/* polyabzar_img() wraps responsive images in <picture> so WebP can be
   offered with a real fallback. `display: contents` removes the wrapper from
   the box tree entirely, so every existing rule written against the bare
   <img> (`.hero-slide img { height: 100% }`, `.room-photo-clip img`,
   `.product-card-media img`...) keeps working untouched. */
picture { display: contents; }

/* Browsers give native form controls their own UA font (~Arial/Tahoma),
   not the page font — unlike every other element, they don't inherit it
   by default. Missing this is why WooCommerce's stock buttons/inputs
   (place order, apply coupon, qty steppers, login/register submit, save
   address...) kept showing a different font from the rest of the site
   even though .btn-pill etc. covered everything else. */
button, input, select, textarea, optgroup { font-family: inherit; }

body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-body);
  /* 400 is Markazi's floor, not a style choice — see the @font-face note. */
  font-weight: 400;
  /* The base of the type ramp. Everything else in the sheet is sized in rem
     against the ROOT, not against this, so changing it moves only the text
     that inherits — running copy, list items, table cells, form fields —
     and never double-scales a rule that sets its own size. */
  font-size: 1.125rem;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.3;
  margin: 0 0 0.5em;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--brand-bronze-text); }

/* Global keyboard focus ring.
   --ring existed as a token from the start but was referenced exactly once
   (the header search input). Every other focusable thing on the site — every
   nav link, product card, carousel arrow, dot, accordion summary, wishlist
   heart, bottom-nav item — fell through to the browser's default ring: never
   designed for a warm cream ground, and thin enough on some of these controls
   to be easy to lose.

   :focus-visible rather than :focus, so a mouse click doesn't leave a ring
   behind. Deliberately low specificity (0-1-0): the three places that already
   draw their own indicator — the room pin's gold halo and the form fields'
   inset ring — are all authored at higher specificity and keep winning, so
   this fills the gaps without overriding anything considered. */
:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
}

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

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 1.25rem;
}

/* No negative margin: the element is already out of flow, so `margin: -1px`
   bought nothing and pushed the box 1px past its static position — which
   under dir="rtl" is the RIGHT edge of the viewport, giving every page a
   1px horizontal scrollbar (the front page's sr-only <h1> was the one doing
   it). */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* Pill buttons (ported: rounded-full CTAs) */
.btn-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border-radius: 9999px;
  height: 2.75rem;
  padding-inline: 1.75rem;
  font-size: 1.015rem;
  font-weight: 400;
  transition: background-color 0.2s, color 0.2s;
}
.btn-light { background: var(--glass); color: var(--primary); }
.btn-light:hover { background: var(--brand-gold); color: #fff; }
.btn-dark { background: var(--primary); color: var(--primary-foreground); }
.btn-dark:hover { opacity: 0.85; color: var(--primary-foreground); }
.btn-pill svg { width: 1.1em; height: 1.1em; }
.btn-pill:disabled { background: var(--muted); color: var(--muted-foreground); cursor: not-allowed; }
.btn-pill:disabled:hover { opacity: 1; }
.btn-outline { border: 1px solid var(--border); background: transparent; color: var(--foreground); }
.btn-outline:hover { border-color: var(--brand-gold); color: var(--brand-bronze); }
.dark .btn-outline:hover { color: var(--brand-gold); }
.btn-sm { height: 2.25rem; padding-inline: 1.15rem; font-size: 0.925rem; }

/* Section scaffolding */
.section { padding-block: 4rem 2rem; }
.section-title {
  font-family: var(--font-display);
  font-size: clamp(2.135rem, 3.94vw, 2.815rem);
  font-weight: 700;
  margin: 0;
}
.section-title--center { text-align: center; }
.gold-rule {
  display: block;
  height: 2px;
  width: 3.5rem;
  border-radius: 9999px;
  background: var(--brand-gold);
  margin-block: 0.85rem 3rem;
}
.gold-rule--center { margin-inline: auto; }

/* ---------- Header ---------- */

.site-header {
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--background) 95%, transparent);
  position: sticky;
  top: 0;
  z-index: 50;
}
@supports ( backdrop-filter: blur(1px) ) or ( -webkit-backdrop-filter: blur(1px) ) {
  .site-header {
    background: color-mix(in srgb, var(--background) 60%, transparent);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
  }
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4rem;
}

.brand-logo img { height: 3.5rem; width: auto; }

.header-icons {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.header-link { font-size: 0.985rem; transition: color 0.2s; }
.header-link:hover { color: var(--brand-bronze-text); }

.icon-btn {
  display: inline-flex;
  position: relative;
  background: none;
  border: 0;
  padding: 0;
  color: inherit;
  cursor: pointer;
  transition: color 0.2s, transform 0.2s;
}
/* The lift is a pointer affordance and must stay behind (hover: hover). A phone
   latches :hover onto whatever was tapped last and holds it until the next tap
   elsewhere — so on touch this rule left the tapped icon parked 2px above its
   neighbours in the header bar, which reads as the bar losing its alignment
   after every use. :active gives touch the same feedback without moving it. */
@media (hover: hover) {
  .icon-btn:hover { color: var(--brand-bronze-text); transform: translateY(-2px); }
}
.icon-btn:active { color: var(--brand-bronze-text); }
.icon-btn svg { width: 1.25rem; height: 1.25rem; }

.cart-badge {
  position: absolute;
  top: -0.4rem;
  inset-inline-end: -0.5rem;
  width: 1.15rem;
  height: 1.15rem;
  border-radius: 50%;
  background: var(--brand-bronze);
  color: #fff;
  font-size: 0.73rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-contact-strong);
}

.primary-nav { display: flex; align-items: center; gap: 1.5rem; }
.primary-nav a { font-size: 0.985rem; transition: color 0.2s; }
.primary-nav a:hover { color: var(--brand-bronze-text); }

.menu-toggle svg { width: 1.5rem; height: 1.5rem; }

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 1rem;
  padding-block: 1rem;
  border-top: 1px solid var(--border);
}
.mobile-menu.is-open { display: flex; }
.mobile-menu a { font-size: 0.985rem; }

/* ---------- Header category dropdown ----------
   A disclosure under «محصولات», listing the five product families. The header
   is translucent with a backdrop-filter blur, so the panel carries its OWN
   opaque background — inheriting would let the page scroll visibly through it.
   It sits inside the sticky header's z-index: 50 stacking context, so it clears
   page content without a new z-index. */

.nav-dropdown { position: relative; }

.nav-dropdown-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  font-size: 0.985rem;
  cursor: pointer;
  transition: color 0.2s;
}
.nav-dropdown-toggle:hover { color: var(--brand-bronze-text); }
.nav-dropdown-toggle svg { width: 1rem; height: 1rem; transition: transform 0.2s; }
.nav-dropdown.is-open .nav-dropdown-toggle svg { transform: rotate(180deg); }

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 0.6rem);
  inset-inline-start: 0;
  min-width: 13rem;
  display: flex;
  flex-direction: column;
  padding: 0.4rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-overlay);
}
/* Outranks the display:flex above (0,2,0 vs 0,1,0), so the `hidden` attribute
   the script toggles actually hides the panel instead of being overridden. */
.nav-dropdown-menu[hidden] { display: none; }

.nav-dropdown-menu a {
  display: block;
  padding: 0.45rem 0.6rem;
  border-radius: calc(var(--radius) - 0.125rem);
  font-size: 0.95rem;
  transition: background 0.15s, color 0.15s;
}
.nav-dropdown-menu a:hover,
.nav-dropdown-menu a:focus-visible {
  background: var(--secondary);
  color: var(--brand-bronze-text);
}
/* «همه محصولات» is the one-click route to the shop that turning the trigger
   into a button removed, so it reads as the head of the list rather than one
   more sibling in it. */
.nav-dropdown-menu a.is-all {
  margin-bottom: 0.25rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
}

/* Mobile drawer: two panels, root and products, one level of drill-down. Only
   one is ever in the DOM flow, so the drawer is exactly as tall as the panel
   showing and nothing needs a fixed height. */
.mobile-menu-panel {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.mobile-menu-panel[hidden] { display: none; }

/* Entering panels slide in from the inline-end — under dir="rtl" that is from
   the left, matching the direction the chevrons point. */
@keyframes mobile-panel-in {
  from { opacity: 0; transform: translateX(0.75rem); }
  to   { opacity: 1; transform: none; }
}
.mobile-menu-panel { animation: mobile-panel-in 0.18s ease-out; }
@media (prefers-reduced-motion: reduce) {
  .mobile-menu-panel { animation: none; }
}

/* The drill and back rows are buttons, so they need the anchors' type reset —
   .mobile-menu a sets the size, and these have to match it exactly or the two
   panels look like different menus. */
.mobile-menu-drill,
.mobile-menu-back {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  font-size: 0.985rem;
  text-align: start;
  cursor: pointer;
}
.mobile-menu-drill { justify-content: space-between; }
.mobile-menu-drill svg,
.mobile-menu-back svg { width: 1.1rem; height: 1.1rem; flex-shrink: 0; }

/* The back row is a heading for the panel below it, not a sibling of the
   category links, so it carries a rule and the muted tone of a label. */
.mobile-menu-back {
  gap: 0.3rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--border);
  color: var(--muted-foreground);
}
.mobile-menu-back:hover { color: var(--foreground); }
.mobile-menu-panel a:hover { color: var(--brand-bronze-text); }

.header-search {
  display: none;
  border-top: 1px solid var(--border);
  padding-block: 0.75rem;
}
.header-search.is-open { display: block; }
.header-search form {
  display: flex;
  gap: 0.5rem;
  max-width: 32rem;
  margin-inline: auto;
}
.header-search input {
  flex: 1;
  height: 2.75rem;
  border: 1px solid var(--input);
  border-radius: 9999px;
  padding-inline: 1.25rem;
  background: var(--card);
  color: inherit;
  font-family: inherit;
  font-size: 1.015rem;
}
.header-search input:focus { outline: 2px solid var(--ring); outline-offset: 1px; }

@media (max-width: 767px) {
  .md-only, .primary-nav { display: none; }
}
@media (min-width: 768px) {
  .menu-toggle, .mobile-menu, .mobile-menu.is-open { display: none; }
}

/* ---------- Hero (fade carousel, floating rounded frame) ---------- */

.hero { padding-top: 0.25rem; }

/* Mobile gets its own tighter side inset and a taller frame — a bigger,
   more immersive card than the 4/3 photo ratio used from md up. */
.hero .container { padding-inline: 0.5rem; }
@media (min-width: 768px) {
  .hero .container { padding-inline: 1.25rem; }
}

.hero-frame {
  position: relative;
  overflow: hidden;
  border-radius: 1.25rem;
  aspect-ratio: 4 / 5;
  box-shadow: var(--hairline);
}
@media (min-width: 768px) {
  .hero-frame { border-radius: 1.75rem; aspect-ratio: 21 / 9; }
}

/* A real translateX slider (transform-driven, not native scroll) so drag
   feedback is genuinely 1:1 with the pointer every frame — CSS scroll-snap
   fights JS-driven scrollLeft (it kept snapping mid-drag instead of
   following smoothly), so this bypasses native scroll mechanics entirely.
   direction:ltr keeps child order/left-to-right math simple; RTL is
   restored on .hero-slide for the actual Persian caption content. */
.hero-track {
  display: flex;
  height: 100%;
  direction: ltr;
  touch-action: pan-y;
  cursor: grab;
  user-select: none;
  transition: transform 0.6s cubic-bezier(0.32, 0.72, 0, 1);
  will-change: transform;
  /* Start where the JS slider starts, WITHOUT waiting for the JS.

     front-page.php unconditionally prepends a clone of the last slide as the
     loop buffer, so the first child of this track is a decorative copy —
     lazy-loaded, aria-hidden, and deliberately NOT the LCP candidate. With no
     transform, that clone is what fills the frame from first paint until
     theme.js runs (it is a footer script) and sets the real offset.

     The cost was measured, not theorised: Lighthouse reported the LCP element
     as the CLONE (`hero-modern-fluted`, loading="lazy"), which failed all
     three LCP-discovery checks at once — no fetchpriority, not discoverable
     in the initial HTML (it is behind data-src), and lazy-loaded. Meanwhile
     the real first slide, which carries eager + fetchpriority="high", was
     never the element being measured.

     -100% is exactly the slider's initial position: initLoopSlider starts at
     `position = cloneCount` (1) and steps by heroFrame.clientWidth, and this
     track's width IS the frame width, so -100% === -1 * getStep(). JS then
     writes the same value in px, which is not a change, so nothing animates.
     Do NOT copy this to .room-track — that slider sizes its slides in px at
     runtime, so its step is not 100%.

     Side benefit: with scripting off, the hero now opens on the real first
     slide instead of a clone of the last one. */
  transform: translateX(-100%);
}
.hero-track.is-dragging { transition: none; cursor: grabbing; }
.hero-track img, .hero-track a { -webkit-user-drag: none; user-drag: none; }
@media (prefers-reduced-motion: reduce) {
  .hero-track, .room-track { transition-duration: 0.01ms; }
}

.hero-slide {
  position: relative;
  flex: 0 0 100%;
  height: 100%;
  direction: rtl;
}

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 62%;
}
.hero-slide.is-active img { animation: hero-zoom 8s ease-out forwards; }
@keyframes hero-zoom { from { transform: scale(1); } to { transform: scale(1.06); } }
@media (prefers-reduced-motion: reduce) {
  .hero-slide.is-active img { animation: none; }
}

/* Scrim so white text stays readable; darkest at the reading start (right,
   RTL). Two layers, because one horizontal gradient isn't enough on both
   shapes: the 21/9 desktop crop puts the caption against wall, but the 4/5
   mobile crop is a bright close-up where white-on-white left the title
   barely legible, so a second vertical wash darkens the band the caption
   actually sits in. */
.hero-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to left, rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.26) 45%, transparent),
    linear-gradient(to top, rgba(0, 0, 0, 0.38), transparent 55%);
}
@media (min-width: 768px) {
  .hero-scrim {
    background:
      linear-gradient(to left, rgba(0, 0, 0, 0.58), rgba(0, 0, 0, 0.2) 48%, transparent),
      linear-gradient(to top, rgba(0, 0, 0, 0.2), transparent 40%);
  }
}

.hero-caption {
  position: absolute;
  inset-block: 0;
  inset-inline-start: 1.25rem;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  max-width: 70%;
}
@media (min-width: 768px) {
  .hero-caption { inset-inline-start: 3.5rem; max-width: 36rem; }
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 700;
  color: #fff;
  font-size: clamp(2.25rem, 5.625vw, 4.22rem);
  line-height: 1.25;
  margin: 0;
}

.hero-tagline {
  font-family: var(--font-accent);
  color: var(--glass);
  font-size: clamp(1.405rem, 2.925vw, 2.135rem);
  line-height: 2.6; /* Nastaliq needs generous vertical room */
  margin: 0.5rem 0 0;
}

.hero-cta { margin-top: 1.4rem; }
@media (min-width: 768px) { .hero-cta { margin-top: 2rem; } }

/* Caption entrance. The slide photo cross-slides on its own, but without
   this the text arrives fully formed and rigid at the same instant, which
   reads as a filmstrip rather than a scene change. Staggering the three
   lines in behind the photo is the whole difference between "the slider
   moved" and "the next slide arrived". Keyed off .is-active so it replays
   on every slide change (including the loop wrap, where syncActive() moves
   the class onto the newly-centered slide). */
.hero-slide.is-active .hero-title,
.hero-slide.is-active .hero-tagline,
.hero-slide.is-active .hero-cta {
  animation: hero-rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}
.hero-slide.is-active .hero-title { animation-delay: 0.1s; }
.hero-slide.is-active .hero-tagline { animation-delay: 0.2s; }
.hero-slide.is-active .hero-cta { animation-delay: 0.3s; }
@keyframes hero-rise {
  from { opacity: 0; transform: translateY(1.25rem); }
  to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-slide.is-active .hero-title,
  .hero-slide.is-active .hero-tagline,
  .hero-slide.is-active .hero-cta { animation: none; }
}

/* Arrows + dots as one bottom-center cluster. Side-mounted arrows are the
   obvious layout, but they don't work here: under RTL .hero-caption is
   pinned to the right edge and vertically centered, which is exactly where
   a right-hand "previous" button wants to sit — it landed on top of the
   tagline. Grouping the controls along the bottom keeps the whole photo and
   the caption clear, and reads as a single deliberate control rather than
   two buttons stuck to the frame. */
.hero-nav {
  position: absolute;
  bottom: 0.25rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 0.25rem;
  z-index: 2;
}

/* Glass buttons rather than the opaque .carousel-arrow chrome used
   elsewhere — these sit ON the photograph, and a solid white disc over a
   full-bleed image reads as a sticker. Hidden below md, where the frame is
   swipeable and the extra chrome isn't worth the width. */
.hero-arrow {
  display: none;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  border: 0;
  padding: 0;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(6px);
  color: #fff;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}
@media (min-width: 768px) { .hero-arrow { display: flex; } }
.hero-arrow:hover { background: rgba(255, 255, 255, 0.32); }
.hero-arrow:active { transform: scale(0.92); }
.hero-arrow svg { width: 1.1rem; height: 1.1rem; }

.hero-dots {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}
/* The visible pill is a ::before, so the button itself can stay a 44px-tall
   touch target (WCAG 2.5.8) without the dot looking like a slab. */
.hero-dot {
  position: relative;
  width: 1.5rem;
  height: 2.75rem;
  border: 0;
  padding: 0;
  background: none;
  cursor: pointer;
}
.hero-dot::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.55);
  box-shadow: var(--shadow-on-photo);
  transition: width 0.35s cubic-bezier(0.32, 0.72, 0, 1), background 0.35s;
}
.hero-dot:hover::before { background: rgba(255, 255, 255, 0.85); }
.hero-dot.is-active::before { width: 1.5rem; background: #fff; }

/* ---------- Room explorer (interactive photo carousel, replaces the old
   category grid) ---------- */

.room-intro { max-width: 42rem; margin-inline: auto; text-align: center; margin-bottom: 2.5rem; }
@media (min-width: 768px) { .room-intro { margin-bottom: 3.5rem; } }
.text-gold { color: var(--brand-gold-text); }

/* Same progressive scale as the Next.js version: bigger on desktop, since
   this is the page's main "look inside" moment, not a thumbnail. */
.room-mat { max-width: 28rem; margin-inline: auto; }
@media (min-width: 768px)  { .room-mat { max-width: 36rem; } }
@media (min-width: 1024px) { .room-mat { max-width: 42rem; } }
@media (min-width: 1280px) { .room-mat { max-width: 48rem; } }

/* .room-carousel-inner (not .room-viewport) is the positioning context for
   the arrow buttons — they sit as its direct children, siblings of
   .room-viewport rather than inside it, specifically so the viewport's
   clip-path (below) can't clip them even though they're nudged slightly
   past the photo's edge. Keeping them outside .room-viewport also means
   centering them via top:50% measures against the photo's own height, not
   the taller block that includes the dots row underneath. */
.room-carousel-inner { position: relative; }

/* overflow-x (not overflow:hidden on both axes): needs to contain the two
   peeking side rooms horizontally — both for the visual clip AND so the
   oversized 3-up .room-track doesn't widen the page's own scrollable area —
   while a hotspot popover on the ACTIVE room is still allowed to spill
   above/below its photo card (see .room-popover below). Plain
   overflow:hidden clips both axes and would cut those popovers off. */
.room-viewport { overflow-x: hidden; overflow-y: visible; }

/* Same transform-driven slider as .hero-track (see assets/theme.js
   initLoopSlider) — direction:ltr keeps the position math a plain
   translateX(-position * step), restored to rtl per-slide below.
   Slide width and the centering inset (padding-inline-start) are set in px
   by theme.js (sizeRoomSlides), not here as percentages: a peek carousel
   needs slide-width and inset both measured against the same reference
   (viewport width) at once, which nested CSS percentages (slide% of an
   already-padded track) can't express without the numbers drifting. */
.room-track {
  display: flex;
  direction: ltr;
  touch-action: pan-y;
  cursor: grab;
  user-select: none;
  transition: transform 0.6s cubic-bezier(0.32, 0.72, 0, 1);
  will-change: transform;
}
/* Must exist, not just for dragging: initLoopSlider's jump() adds this class
   to make the seamless-loop reposition instant. .hero-track had the rule and
   .room-track didn't, so every wrap past the last room ANIMATED the jump —
   a half-second slide backwards through the whole track. It went unnoticed
   only because all three rooms used to be the same photo; it also fired a
   spurious transform transitionend that closed whatever callout the visitor
   had just opened. */
.room-track.is-dragging { transition: none; cursor: grabbing; }
.room-track img, .room-track a { -webkit-user-drag: none; user-drag: none; }

/* Non-active rooms recede (scaled down, dimmed, inert) so only the centered
   room reads as interactive, matching the screenshot. */
.room-slide {
  flex-shrink: 0;
  direction: rtl;
  transform: scale(0.86);
  opacity: 0.45;
  pointer-events: none;
  transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.5s;
}
.room-slide.is-active { transform: scale(1); opacity: 1; pointer-events: auto; }

/* Shared round nav-arrow look, reused by the room-explorer carousel and the
   product showcase below — .carousel-arrow is the button chrome, each
   carousel supplies its own -prev/-next positioning since they sit in
   differently-shaped containers (room-explorer: absolute over a photo;
   showcase: absolute beside a card row). */
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  border: 0;
  background: color-mix(in srgb, var(--background) 92%, transparent);
  box-shadow: var(--shadow-raised);
  color: var(--foreground);
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s, transform 0.2s;
}
.carousel-arrow:hover { box-shadow: var(--shadow-raised-hover); }
.carousel-arrow:active { transform: translateY(-50%) scale(0.94); }
.carousel-arrow svg { width: 1.25rem; height: 1.25rem; }
.room-arrow-prev { right: -0.25rem; }
.room-arrow-next { left: -0.25rem; }
.room-arrow-prev:hover, .room-arrow-next:hover { transform: translateY(-50%) scale(1.08); }
@media (min-width: 768px) {
  .carousel-arrow { width: 3rem; height: 3rem; }
  .room-arrow-prev { right: -1.25rem; }
  .room-arrow-next { left: -1.25rem; }
}

/* Same 44px-target-with-a-small-visible-pill trick as .hero-dot. */
.room-dots { display: flex; justify-content: center; align-items: center; gap: 0.25rem; margin-top: 1rem; }
.room-dot {
  position: relative;
  width: 1.5rem;
  height: 2.75rem;
  border: 0;
  padding: 0;
  background: none;
  cursor: pointer;
}
.room-dot::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 9999px;
  background: var(--border);
  transition: width 0.35s cubic-bezier(0.32, 0.72, 0, 1), background 0.35s;
}
.room-dot:hover::before { background: color-mix(in srgb, var(--brand-gold) 55%, var(--border)); }
.room-dot.is-active::before { width: 1.5rem; background: var(--brand-gold); }

.room-photo {
  position: relative;
  aspect-ratio: 1 / 1;
  background: var(--card);
  padding: 0.75rem;
  border-radius: 0.25rem;
  box-shadow: var(--shadow-panel);
}
@media (min-width: 768px) { .room-photo { padding: 1rem; } }

/* The photo clips to its rounded corners, but the pin/line/popover layer
   below sits outside that clip — a popover near the top/bottom edge can
   spill onto the mat instead of being cut off mid-sentence. */
.room-photo-clip {
  position: absolute;
  inset: 0.75rem;
  overflow: hidden;
  border-radius: 0.125rem;
}
@media (min-width: 768px) { .room-photo-clip { inset: 1rem; } }
.room-photo-clip img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.room-pin {
  position: absolute;
  transform: translate(-50%, -50%);
  transition: opacity 0.3s;
}
.room-pin.is-dimmed { opacity: 0.35; }

/* Pins are siblings, so paint order is DOM order: without this, a pin further
   down the list draws its dot ON TOP of an earlier pin's open callout — which
   is exactly what happened, since the callout is ~a third of the photo tall
   and routinely covers the next pin down. Raising only the open pin keeps the
   callout above every other pin without reordering anything. */
.room-pin.is-active,
.room-pin.is-hover { z-index: 3; }

/* 2.75rem (44px) hit area for touch, with the visible dot centered inside
   it — the dot itself is 1rem and would be well under the WCAG 2.5.8
   minimum as its own target. */
.room-pin-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}
.room-pin-ping {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1.75rem;
  height: 1.75rem;
  margin: -0.875rem 0 0 -0.875rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--brand-gold) 60%, transparent);
  animation: room-pin-ping 2.4s cubic-bezier(0, 0, 0.2, 1) infinite;
}
/* The ping is an attract-loop: it exists to say "these dots do something".
   Once a callout is open the question is answered, so it stops on the open
   pin and on the dimmed ones alike rather than pulsing under the text. */
.room-pin.is-dimmed .room-pin-ping,
.room-pin.is-active .room-pin-ping,
.room-pin.is-hover .room-pin-ping { animation-play-state: paused; opacity: 0; }
@keyframes room-pin-ping {
  0%   { transform: scale(1); opacity: 0.9; }
  70%, 100% { transform: scale(2.1); opacity: 0; }
}
.room-pin-dot {
  position: relative;
  display: block;
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background: var(--brand-gold);
  box-shadow: 0 0 0 2px #fff, var(--shadow-on-photo);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s;
}
.room-pin-btn:hover .room-pin-dot,
.room-pin.is-hover .room-pin-dot { transform: scale(1.25); }
.room-pin.is-active .room-pin-dot {
  transform: scale(1.35);
  box-shadow: 0 0 0 3px #fff, 0 2px 8px rgba(0, 0, 0, 0.35);
}
.room-pin-btn:focus-visible { outline: none; }
.room-pin-btn:focus-visible .room-pin-dot {
  box-shadow: 0 0 0 2px #fff, 0 0 0 5px var(--brand-gold);
}

/* Leader line + label. Not display:none/block — that can't transition, and
   the callout popping into existence at full size is the single jarring
   moment in an otherwise slow, considered section. visibility keeps it out
   of the a11y tree and out of hit-testing while closed, and (unlike
   display) still animates. .is-hover is the pointer/focus preview,
   .is-active the committed click; both show the same thing. */
.room-line, .room-popover {
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.22s ease, visibility 0.22s, transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}
.room-pin.is-active .room-line, .room-pin.is-active .room-popover,
.room-pin.is-hover .room-line, .room-pin.is-hover .room-popover {
  visibility: visible;
  opacity: 1;
}

/* The line draws itself out from the pin rather than fading in place: it's
   scaled to nothing along its own axis while closed, with the origin at the
   pin end. */
.room-line {
  position: absolute;
  background: color-mix(in srgb, var(--brand-gold) 70%, transparent);
}
/* Physical left/right/top/bottom, not logical inset-inline-*: "direction"
   here means which way the line points on screen, which must not flip
   under dir="rtl". up/down keep the popover horizontally centered on the
   pin — since the pin sits near the photo's horizontal center, a centered
   popover can never overflow the viewport, unlike left/right which did on
   narrow phones once the pin was more than ~half the popover's width from
   either edge. */
.room-pin[data-direction="left"] .room-line,
.room-pin[data-direction="right"] .room-line {
  top: 50%;
  height: 1px;
  width: 2rem;
  transform: translateY(-50%) scaleX(0);
}
.room-pin[data-direction="right"] .room-line { left: 100%; transform-origin: left center; }
.room-pin[data-direction="left"] .room-line { right: 100%; transform-origin: right center; }
.room-pin.is-active[data-direction="left"] .room-line,
.room-pin.is-active[data-direction="right"] .room-line,
.room-pin.is-hover[data-direction="left"] .room-line,
.room-pin.is-hover[data-direction="right"] .room-line { transform: translateY(-50%) scaleX(1); }

.room-pin[data-direction="up"] .room-line,
.room-pin[data-direction="down"] .room-line {
  left: 50%;
  width: 1px;
  height: 2rem;
  transform: translateX(-50%) scaleY(0);
}
.room-pin[data-direction="down"] .room-line { top: 100%; transform-origin: center top; }
.room-pin[data-direction="up"] .room-line { bottom: 100%; transform-origin: center bottom; }
.room-pin.is-active[data-direction="up"] .room-line,
.room-pin.is-active[data-direction="down"] .room-line,
.room-pin.is-hover[data-direction="up"] .room-line,
.room-pin.is-hover[data-direction="down"] .room-line { transform: translateX(-50%) scaleY(1); }

.room-popover {
  position: absolute;
  width: 10rem;
  border-radius: 0.625rem;
  background: color-mix(in srgb, var(--background) 96%, transparent);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-overlay);
  border: 1px solid var(--border);
  padding: 0.65rem 0.8rem;
  text-align: center;
}
/* The photo behind is small on a phone; a 10rem card eats over half of it. */
@media (max-width: 639px) {
  .room-popover { width: 8.75rem; padding: 0.55rem 0.6rem; }
}

/* Invisible bridge across the leader-line gap. The hover preview keys off
   pointerenter/pointerleave on .room-pin, and the popover is a descendant
   of it — but the 2rem of leader line between them is empty space, so
   moving the mouse from the dot toward the callout to click its link left
   the pin's subtree, closed the callout, and the link went with it. The
   bridge fills that gap with a hit-testable child of the popover, so the
   pointer never leaves. It inherits the popover's visibility, so it can't
   swallow clicks meant for the photo while the callout is closed. */
.room-popover::before {
  content: '';
  position: absolute;
}
.room-pin[data-direction="down"] .room-popover::before { left: 0; right: 0; bottom: 100%; height: 2rem; }
.room-pin[data-direction="up"] .room-popover::before { left: 0; right: 0; top: 100%; height: 2rem; }
.room-pin[data-direction="left"] .room-popover::before { top: 0; bottom: 0; left: 100%; width: 2rem; }
.room-pin[data-direction="right"] .room-popover::before { top: 0; bottom: 0; right: 100%; width: 2rem; }

/* Each popover slides in a short way along its own leader line (and never
   across it), so the callout reads as being pulled out of the pin. The
   closed offset is the same axis and sign as the line's own direction. */
.room-pin[data-direction="left"] .room-popover,
.room-pin[data-direction="right"] .room-popover { top: 50%; }
.room-pin[data-direction="right"] .room-popover {
  left: calc(100% + 2rem);
  transform: translateY(-50%) translateX(-0.5rem);
}
.room-pin[data-direction="left"] .room-popover {
  right: calc(100% + 2rem);
  transform: translateY(-50%) translateX(0.5rem);
}
.room-pin.is-active[data-direction="left"] .room-popover,
.room-pin.is-active[data-direction="right"] .room-popover,
.room-pin.is-hover[data-direction="left"] .room-popover,
.room-pin.is-hover[data-direction="right"] .room-popover { transform: translateY(-50%); }

.room-pin[data-direction="up"] .room-popover,
.room-pin[data-direction="down"] .room-popover { left: 50%; }
.room-pin[data-direction="down"] .room-popover {
  top: calc(100% + 2rem);
  transform: translateX(-50%) translateY(-0.5rem);
}
.room-pin[data-direction="up"] .room-popover {
  bottom: calc(100% + 2rem);
  transform: translateX(-50%) translateY(0.5rem);
}
.room-pin.is-active[data-direction="up"] .room-popover,
.room-pin.is-active[data-direction="down"] .room-popover,
.room-pin.is-hover[data-direction="up"] .room-popover,
.room-pin.is-hover[data-direction="down"] .room-popover { transform: translateX(-50%); }

.room-popover-title { font-family: var(--font-display); font-weight: 700; font-size: 1.125rem; margin: 0; }
.room-popover-tagline { font-size: 0.845rem; color: var(--muted-foreground); line-height: 1.5; margin: 0.25rem 0 0; }
.room-popover-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin-top: 0.5rem;
  font-size: 0.845rem;
  font-weight: 600;
  color: var(--brand-gold-text);
}
.room-popover-link:hover { color: var(--brand-bronze-text); text-decoration: underline; }
.room-popover-link svg { width: 0.75rem; height: 0.75rem; }

@media (prefers-reduced-motion: reduce) {
  .room-pin-ping { animation: none; opacity: 0; }
  /* Keep the show/hide, drop the travel — a callout that only fades is
     still perfectly legible, but nothing slides. */
  .room-line, .room-popover { transition-duration: 0.01ms; }
  .room-pin[data-direction="right"] .room-popover { transform: translateY(-50%); }
  .room-pin[data-direction="left"] .room-popover { transform: translateY(-50%); }
  .room-pin[data-direction="down"] .room-popover { transform: translateX(-50%); }
  .room-pin[data-direction="up"] .room-popover { transform: translateX(-50%); }
}

/* .feature-icon is also reused (smaller, via .dashboard-tile override) on
   the My Account dashboard tiles — keep it even though .trust-strip below
   replaced its original use on the homepage. */
.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--foreground) 15%, transparent);
  margin-bottom: 1rem;
}
.feature-icon svg { width: 1.75rem; height: 1.75rem; }

/* ---------- Trust strip (why-polyurethane reassurances, restated as a
   slow ambient marquee instead of a full boilerplate section) ----------
   The DOM (see front-page.php) repeats the 4 features 16 times total, as
   two identical 8-repeat halves back to back. Animating translateX(-50%)
   moves exactly one half's width, so half #2 slides into exactly the
   screen position half #1 started at — continuous coverage, no snap.
   That only works if the track's RESTING position is left-anchored (so
   half #1 starts flush at the strip's left edge and half #2 immediately
   follows it, off to the right). .trust-strip inherits dir="rtl" from
   <html>, and a block-level child wider than its container defaults to
   right-anchored under RTL — sliding a RIGHT-anchored strip left just
   runs it off-screen with nothing behind it, which is what actually
   caused the "goes blank partway through" bug: the two endpoints (0% and
   50%) matched pixel-for-pixel, so an endpoints-only check missed that
   most of the MIDDLE of the animation was empty. Forcing direction:ltr
   on the strip itself (not just the track) is what pins it left. Each
   half also needs to stay wider than any real viewport, since a single
   half alone has to cover the screen at the widest intermediate point —
   16 total reps keeps that half comfortably above ~5800px. */
.trust-strip {
  direction: ltr;
  overflow: hidden;
  background: var(--card);
  border-block: 1px solid var(--border);
  padding-block: 1.1rem;
}
.trust-track {
  display: flex;
  width: max-content;
  direction: ltr; /* plain translateX math; text itself stays rtl per-item below */
  animation: trust-marquee 90s linear infinite;
}
/* Hold it still while the pointer is on it, so a label that catches
   someone's eye can be read instead of sliding out from under them. */
.trust-strip:hover .trust-track { animation-play-state: paused; }
@media (prefers-reduced-motion: reduce) { .trust-track { animation: none; } }

@keyframes trust-marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

.trust-item {
  direction: rtl;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  white-space: nowrap;
  padding-inline: 1.75rem;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1.07rem;
  border-inline-end: 1px solid var(--border);
}

.trust-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--brand-gold) 40%, transparent);
  color: var(--brand-gold);
  flex-shrink: 0;
}
.trust-icon svg { width: 1rem; height: 1rem; }

/* ---------- Product showcase ----------
   Deliberately NOT the transform/clone slider used for the hero and room
   explorer — those need a seamless infinite loop over a small, fixed slide
   count, which is worth the clone/position bookkeeping. This row is driven
   by however many products are starred Featured in wp-admin (no fixed
   count, and it changes), so a native scroll-snap row is the better fit:
   the browser handles snapping/touch/trackpad for free and nothing needs
   to change as products are added — the prev/next buttons just nudge the
   native scroll position by one card. */
.showcase-sub { text-align: center; color: var(--muted-foreground); margin: 0.75rem 0 0; }

.showcase-carousel-inner { position: relative; }

.showcase-track {
  display: flex;
  gap: 1.25rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-block: 0.25rem; /* breathing room for the card's hover shadow */
  scrollbar-width: none;
  /* Fewer featured products than fit the row is the normal case, not an
     edge case (three at the 23% desktop basis leaves a quarter of the row
     empty, which reads as a layout hole at the end of the line). `safe` is
     doing the real work: plain `center` on a scroll container centers the
     overflow too, pushing the start of the row out past scrollLeft: 0 where
     it can never be scrolled back to — the row loaded a third of the way in
     with the first product already clipped. `safe center` falls back to
     start alignment exactly when the content overflows, so short rows
     center and long rows still begin at their first card. */
  justify-content: safe center;
  /* Keeps the snapped card off the container's own edge. Without it the row
     sat flush to the gutter and the first card read as clipped rather than
     as the start of a row; scroll-padding has to match, or snapping puts the
     card back against the edge the padding just cleared. */
  padding-inline: 0.75rem;
  scroll-padding-inline: 0.75rem;
}
.showcase-track::-webkit-scrollbar { display: none; }
.showcase-track.is-dragging { scroll-snap-type: none; cursor: grabbing; }
.showcase-track.is-dragging a { pointer-events: none; }

/* 86%, not 74%. The peek is deliberate — it's the only "there is more here"
   signal on touch — but a quarter of the next card is enough to render its
   title and price as a legible fragment, and a price sliced to «۰۰,۰۰۰ تومان»
   reads as a real (and alarmingly cheap) price rather than as a cut-off one.
   A ~14% sliver still shows an edge without showing readable text. */
.showcase-item { flex: 0 0 86%; scroll-snap-align: start; }
@media (min-width: 640px)  { .showcase-item { flex-basis: 45%; } }
@media (min-width: 1024px) { .showcase-item { flex-basis: 31%; } }
@media (min-width: 1280px) { .showcase-item { flex-basis: 23%; } }

/* Arrows only exist when there is something to scroll to. They used to
   render unconditionally, so with three products they floated over blank
   margin and did nothing at all when clicked. */
.showcase-arrow-prev, .showcase-arrow-next {
  display: none;
  transition: opacity 0.2s, background 0.2s, transform 0.2s, box-shadow 0.2s;
}
.showcase-arrow-prev:disabled, .showcase-arrow-next:disabled {
  opacity: 0;
  pointer-events: none;
}
.showcase-arrow-prev:hover:not(:disabled) { transform: translateY(-50%) scale(1.08); }
.showcase-arrow-next:hover:not(:disabled) { transform: translateY(-50%) scale(1.08); }

/* Desktop only, and hanging outside the row rather than over it: below md
   there is no gutter to hang in, so the arrows sat on top of the first and
   last cards covering their wishlist buttons. Touch scrolling covers that
   case without them. */
@media (min-width: 768px) {
  .showcase-carousel-inner.is-scrollable .showcase-arrow-prev,
  .showcase-carousel-inner.is-scrollable .showcase-arrow-next { display: flex; }
  .showcase-arrow-prev { right: -1.25rem; }
  .showcase-arrow-next { left: -1.25rem; }
}

/* Counter stands in for the arrows below 768px, where they're hidden. Tabular
   figures so the number doesn't jitter the line as it counts up. */
.showcase-counter {
  display: flex;
  justify-content: center;
  align-items: baseline;
  gap: 0.3rem;
  margin: 1.25rem 0 0;
  font-size: 0.955rem;
  font-variant-numeric: tabular-nums;
  color: var(--muted-foreground);
}
.showcase-counter [data-showcase-current] { color: var(--foreground); font-weight: 700; }

@media (min-width: 768px) {
  .showcase-counter { display: none; }
}

.showcase-cta { text-align: center; margin-top: 2.5rem; }

/* ---------- FAQ ---------- */

.faq-wrap { max-width: 56rem; margin-inline: auto; }

.faq-sub {
  text-align: center;
  color: var(--muted-foreground);
  font-size: 1.24rem;
  margin: -2rem 0 3rem; /* tucks under the gold rule */
}

.faq-item {
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  background: var(--card);
  padding-inline: 1.5rem;
  margin-bottom: 1rem;
  transition: box-shadow 0.2s;
}
.faq-item:hover { box-shadow: var(--shadow-lift); }

.faq-item summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1.25rem;
  font-weight: 700;
  font-size: 1.24rem;
}
.faq-item summary::-webkit-details-marker { display: none; }

.faq-chevron { flex-shrink: 0; transition: transform 0.2s; }
.faq-chevron svg { width: 1rem; height: 1rem; display: block; }
.faq-item[open] .faq-chevron { transform: rotate(180deg); }

.faq-item .faq-answer {
  color: var(--muted-foreground);
  margin: 0;
  /* ~72ch, not the 56rem wrapper width. At full width the answers ran past
     100 characters a line, which is a long way past comfortable even
     allowing for Persian's narrower average glyph. */
  max-width: 68ch;
  padding-bottom: 1.25rem;
}

/* Admin-only draft marker on FAQ answers still awaiting sign-off. Never
   rendered for customers — see the 'verify' flag in front-page.php. */
.faq-verify {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 1.25rem;
  border: 1px dashed color-mix(in srgb, var(--brand-gold) 55%, transparent);
  background: color-mix(in srgb, var(--brand-gold) 10%, transparent);
  border-radius: var(--radius);
  padding: 0.6rem 0.85rem;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--brand-bronze-text);
}
.faq-verify-note { font-weight: 400; color: var(--muted-foreground); }

.faq-cta { text-align: center; margin-top: 3rem; }
.faq-cta p { color: var(--muted-foreground); margin: 0 0 1rem; }

/* ---------- Call to action ---------- */

.cta {
  background: color-mix(in srgb, var(--muted) 40%, var(--background));
  padding-block: 5rem;
  text-align: center;
}
.cta h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.135rem, 4.5vw, 3.375rem);
  margin: 0;
}
.cta p {
  color: var(--muted-foreground);
  font-size: 1.24rem;
  max-width: 44rem;
  margin: 1.25rem auto 2rem;
}

/* ---------- Main / Footer ---------- */

.site-main { min-height: 60vh; padding-bottom: 2.5rem; }

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--card);
  color: var(--muted-foreground);
  padding-block: 3rem 2rem;
  margin-bottom: 3.75rem; /* clearance for mobile bottom nav */
}

@media (min-width: 768px) {
  .site-footer { margin-bottom: 0; }
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}
/* The brand column carries more text than the link columns, so it gets the
   extra fraction rather than an equal quarter. */
@media (min-width: 640px)  { .footer-grid { grid-template-columns: repeat(2, 1fr); gap: 2rem 2.5rem; } }
@media (min-width: 1024px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 3rem; } }

.footer-col-title {
  font-family: var(--font-display);
  font-size: 1.295rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 0.9rem;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.55rem; }
.footer-col a { color: var(--muted-foreground); }
.footer-col a:hover { color: var(--brand-bronze-text); }

.footer-logo { display: inline-block; }
.footer-logo img { display: block; width: auto; height: 2.5rem; }
.footer-blurb { margin: 1rem 0 0; max-width: 30ch; line-height: 1.9; }

.footer-phone {
  font-size: 1.295rem;
  font-weight: 700;
  color: var(--foreground) !important;
  font-variant-numeric: tabular-nums;
}

.footer-trust {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-top: 2.5rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--border);
}
.footer-enamad img, .footer-enamad iframe { display: block; max-width: 100px; height: auto; }

.footer-legal {
  margin: 1.75rem 0 0;
  font-size: 0.9rem;
  text-align: center;
}
@media (min-width: 640px) { .footer-legal { text-align: start; } }

/* ---------- Breadcrumb band ---------- */

.breadcrumb-band {
  background: color-mix(in srgb, var(--muted) 40%, var(--background));
  border-bottom: 1px solid var(--border);
}
.breadcrumb {
  padding-block: 0.75rem;
  font-size: 0.985rem;
  color: var(--muted-foreground);
}
/* The flex row moved off .breadcrumb onto the <ol> when the trail became a
   real ordered list (template-parts/breadcrumb.php). Keep the list markers
   and the UA's default padding off it — under RTL that padding lands on the
   right and pushes the whole trail off the container edge.
   flex-wrap matters now that product pages have a fourth crumb: a long
   product name next to a long category name overflows 390px otherwise. */
.breadcrumb ol {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.breadcrumb li { display: inline-flex; align-items: center; gap: 0.5rem; }
.breadcrumb a { display: inline-flex; align-items: center; gap: 0.35rem; }
.breadcrumb a:hover { color: var(--foreground); }
.breadcrumb a svg { width: 1rem; height: 1rem; }
.breadcrumb .is-current { color: var(--foreground); }

/* ---------- Shop archive ---------- */

.shop-hero { padding-block: 3.5rem 2rem; text-align: center; }
.shop-hero-sub {
  color: var(--muted-foreground);
  font-size: 1.24rem;
  max-width: 40rem;
  margin: 1rem auto 0;
  line-height: 1.9;
}

.shop-layout {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding-bottom: 2rem;
}
@media (min-width: 1024px) {
  .shop-layout { flex-direction: row; align-items: flex-start; }
  .shop-filters { flex: 0 0 16rem; position: sticky; top: 5.5rem; }
  .shop-results { flex: 1; min-width: 0; }
}

.shop-filters {
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  background: var(--card);
  overflow: hidden;
}
.filters-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
  border-bottom: 1px solid var(--border);
}
.filters-header h2 {
  font-family: var(--font-display);
  font-size: 1.24rem;
  font-weight: 700;
  margin: 0;
}
.filters-reset { font-size: 0.845rem; color: var(--muted-foreground); }
.filters-reset:hover { color: var(--foreground); }

.filter-group { border-bottom: 1px solid var(--border); }
.filter-group:last-child { border-bottom: 0; }
.filter-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
  background: none;
  border: 0;
  font-family: inherit;
  font-weight: 600;
  color: inherit;
  cursor: pointer;
}
.filter-toggle:hover { background: color-mix(in srgb, var(--muted) 50%, transparent); }
.filter-toggle span:first-child { display: flex; align-items: center; gap: 0.5rem; }
.filter-toggle svg { width: 1rem; height: 1rem; transition: transform 0.2s; }
.filter-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.filter-count {
  font-size: 0.79rem;
  background: var(--primary);
  color: var(--primary-foreground);
  border-radius: 9999px;
  padding: 0.1rem 0.5rem;
}
.filter-body { padding: 0 1rem 1rem; display: none; flex-direction: column; gap: 0.25rem; }
.filter-body.is-open { display: flex; }
.filter-check {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem;
  margin-inline: -0.5rem;
  border-radius: 0.375rem;
  cursor: pointer;
  font-size: 1.07rem;
}
.filter-check:hover { background: color-mix(in srgb, var(--muted) 50%, transparent); }
.filter-check input { width: 1.15rem; height: 1.15rem; accent-color: var(--foreground); }

.active-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  font-size: 0.955rem;
  color: var(--muted-foreground);
}
.filter-badge {
  background: var(--secondary);
  color: var(--secondary-foreground);
  border-radius: 9999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.9rem;
}

.shop-count { font-size: 0.985rem; color: var(--muted-foreground); margin-bottom: 1rem; }
.shop-empty { text-align: center; color: var(--muted-foreground); padding-block: 3rem; }

.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}
@media (min-width: 1024px) { .product-grid { grid-template-columns: repeat(3, 1fr); gap: 1.5rem; } }
.product-grid--3 { grid-template-columns: repeat(1, 1fr); }
@media (min-width: 768px) { .product-grid--3 { grid-template-columns: repeat(3, 1fr); } }

.shop-pagination {
  display: flex;
  justify-content: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}
.shop-pagination a, .shop-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.375rem;
  border: 1px solid var(--border);
  font-size: 0.985rem;
  padding-inline: 0.5rem;
}
.shop-pagination a:hover { border-color: var(--foreground); }
.shop-pagination .current { background: var(--primary); color: var(--primary-foreground); border-color: var(--primary); }
.shop-pagination .dots { border: 0; }

/* Load more. archive-product.php renders this AND the numbered nav; whichever
   one is not in use is hidden rather than left out, so no-JS visitors and
   crawlers still have paged links. .has-load-more is only present while a
   next page exists — on the last page the nav comes back, which is the only
   navigation someone who landed there from a crawled URL has. */
.shop-nav.has-load-more .shop-pagination { display: none; }

.shop-more {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}
.shop-more-count { font-size: 0.875rem; color: var(--muted-foreground); }
.shop-load-more.is-loading { opacity: 0.55; pointer-events: none; }
.shop-load-more.has-error { border-color: var(--destructive); color: var(--destructive); }

/* ---------- Product card ---------- */

.product-card { display: block; }
.product-card article { height: 100%; }

.product-card-media {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 0.5rem;
  background: var(--muted);
}
.product-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.product-card:hover .product-card-media img { transform: scale(1.05); }

.product-card-badges {
  position: absolute;
  top: 0.75rem;
  inset-inline-start: 0.75rem;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.4rem;
}
.badge {
  display: inline-block;
  border-radius: 0.2rem;
  padding: 0.3rem 0.65rem;
  font-size: 0.79rem;
  font-weight: 700;
  white-space: nowrap;
}
.badge-sale { background: var(--brand-bronze); color: #fff; }
.badge-new { border: 1px solid color-mix(in srgb, var(--brand-gold) 60%, transparent); background: var(--background); color: var(--brand-bronze-text); }
.badge-outline { border: 1px solid var(--border); background: var(--card); color: var(--foreground); }

.wishlist-btn {
  position: absolute;
  top: 0.75rem;
  inset-inline-end: 0.75rem;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  border: 0;
  background: color-mix(in srgb, var(--card) 90%, transparent);
  color: var(--muted-foreground);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-contact);
  transition: color 0.2s;
}
.wishlist-btn svg { width: 1.15rem; height: 1.15rem; }
.wishlist-btn:hover { color: var(--sale); }
.wishlist-btn[aria-pressed="true"] { color: var(--sale); }
.wishlist-btn[aria-pressed="true"] svg { fill: currentColor; }

.wishlist-btn--outline {
  position: static;
  width: 3rem;
  height: 3rem;
  border-radius: 9999px;
  border: 1px solid var(--border);
  background: transparent;
  box-shadow: none;
  flex-shrink: 0;
}

.product-card-body { padding-block: 1rem 0.5rem; text-align: right; }

/* Fixed-height line, present whether or not it has content. Only some
   products carry a style term, so a conditionally-rendered eyebrow pushed
   the title and price of those cards a line higher than their neighbours —
   in a row of four, nothing lined up. Reserving the line costs 1.15rem and
   makes the row read as a grid again. */
.product-card-eyebrow {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  min-height: 1.15rem;
  margin-bottom: 0.25rem;
  font-size: 0.845rem;
  line-height: 1.15rem;
}
.product-card-cat { color: var(--foreground); font-weight: 700; }
/* Separator drawn rather than typed, so it never lands on its own line and
   never appears when the style term is missing. */
.product-card-style { color: var(--muted-foreground); }
.product-card-cat + .product-card-style::before {
  content: "";
  display: inline-block;
  width: 1px;
  height: 0.7em;
  margin-inline-end: 0.4rem;
  background: var(--border);
  vertical-align: baseline;
}
.product-card-body h3 {
  font-family: var(--font-display);
  font-size: 1.405rem;
  font-weight: 700;
  line-height: 1.4;
  margin: 0 0 0.5rem;
}

.product-card-price { display: flex; align-items: baseline; gap: 0.5rem; flex-wrap: wrap; }
.price-regular, .price-sale { font-weight: 700; color: var(--brand-bronze-text); }
.price-sale { color: var(--sale) !important; }
.price-was { font-size: 0.955rem; color: var(--muted-foreground); text-decoration: line-through; }

/* ---------- Single product ---------- */

.product-detail-wrap { padding-block: 2rem; }

.product-detail {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  margin-bottom: 3rem;
}
@media (min-width: 1024px) { .product-detail { grid-template-columns: 1fr 1fr; gap: 3rem; } }

.product-gallery-main {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 0.5rem;
  overflow: hidden;
  background: var(--muted);
  margin-bottom: 1rem;
}
.product-gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-zoom-btn {
  position: absolute; bottom: 0.75rem; inset-inline-end: 0.75rem; z-index: 1;
  width: 2.5rem; height: 2.5rem; border-radius: 50%; border: 0;
  background: color-mix(in srgb, var(--background) 85%, transparent); color: inherit;
  display: flex; align-items: center; justify-content: center; cursor: zoom-in;
}
.gallery-zoom-btn svg { width: 1.1rem; height: 1.1rem; }

.product-gallery-thumbs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.gallery-thumb {
  aspect-ratio: 1 / 1;
  border-radius: 0.5rem;
  overflow: hidden;
  border: 2px solid var(--border);
  padding: 0;
  cursor: pointer;
  background: none;
}
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumb.is-active, .gallery-thumb:hover { border-color: var(--foreground); }

.product-detail-badges { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }

.product-detail-title {
  font-family: var(--font-display);
  font-size: clamp(1.97rem, 3.94vw, 2.815rem);
  font-weight: 700;
  margin: 0 0 1rem;
}
.product-detail-desc { font-size: 1.24rem; color: var(--muted-foreground); line-height: 1.9; margin: 0 0 1.5rem; }

.product-detail-price { margin-bottom: 1.5rem; }
.product-detail-price .price-was { font-size: 1.295rem; margin-bottom: 0.25rem; }
.price-sale-big { font-size: 2.53rem; font-weight: 700; color: var(--sale); }
.price-regular-big { font-size: 2.08rem; font-weight: 700; color: var(--brand-bronze-text); }

.stock-status { font-size: 1.015rem; font-weight: 600; margin: -0.75rem 0 1.5rem; }
.stock-status.stock-low { color: var(--brand-bronze-text); }

.qty-row { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.5rem; font-size: 1.015rem; font-weight: 600; }
.qty-stepper { display: flex; align-items: center; border: 1px solid var(--border); border-radius: 0.5rem; overflow: hidden; }
.qty-btn { width: 2.5rem; height: 2.5rem; border: 0; background: none; color: inherit; font-size: 1.24rem; cursor: pointer; }
.qty-btn:hover { background: var(--muted); }
.qty-stepper input {
  width: 3.5rem;
  height: 2.5rem;
  border: 0;
  border-inline: 1px solid var(--border);
  text-align: center;
  background: transparent;
  color: inherit;
  font-family: inherit;
  -moz-appearance: textfield;
}
.qty-stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.product-detail-actions { display: flex; gap: 1rem; margin-bottom: 2rem; }
.btn-add-to-cart { flex: 1; height: 3.25rem; padding-inline: 1.5rem; font-size: 1.125rem; }

/* Bulk / custom-build prompt on the product page. The whole box is the link,
   so the tap target is the card rather than a word inside it. */
.product-b2b {
  display: flex; align-items: center; gap: 0.85rem;
  background: color-mix(in srgb, var(--muted) 50%, transparent);
  border: 1px solid transparent;
  border-radius: 0.5rem;
  padding: 0.9rem 1rem;
  margin-bottom: 1.5rem;
  transition: border-color 0.2s, background-color 0.2s;
}
.product-b2b:hover { border-color: color-mix(in srgb, var(--brand-gold) 55%, transparent); }
.product-b2b-icon {
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
  width: 2.25rem; height: 2.25rem; border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--brand-gold) 45%, transparent);
  color: var(--brand-gold);
}
.product-b2b-icon svg { width: 1.1rem; height: 1.1rem; }
.product-b2b-text { display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; }
.product-b2b-text strong { font-size: 1.07rem; font-weight: 600; }
.product-b2b-text span { font-size: 0.9rem; color: var(--muted-foreground); line-height: 1.6; }
/* Chevron points at the physical start edge; in RTL it must travel that way
   on hover, so the translate is negative. */
.product-b2b-chevron { width: 1rem; height: 1rem; flex-shrink: 0; margin-inline-start: auto; color: var(--brand-bronze-text); transition: transform 0.2s; }
.product-b2b:hover .product-b2b-chevron { transform: translateX(-0.2rem); }

.specs-block h2 { font-family: var(--font-display); font-size: 1.69rem; margin: 0 0 0.75rem; }
.specs-table { border: 1px solid var(--border); border-radius: 0.5rem; overflow: hidden; margin-bottom: 1rem; }
.specs-row { display: grid; grid-template-columns: 8rem 1fr; }
.specs-row.is-alt { background: color-mix(in srgb, var(--muted) 40%, transparent); }
/* 1rem, not the 0.875rem this started at: Markazi's glyphs run small even with
   the size-adjust twin, so 14px here read as fine print next to the 1rem
   description below. line-height is pulled under the body's 1.8 so the rows
   don't grow taller than they were. */
.specs-label, .specs-value { padding: 0.75rem 1rem; font-size: 1.125rem; line-height: 1.7; }
.specs-label { font-weight: 600; }
.specs-value { color: var(--muted-foreground); }
.specs-empty { grid-column: 1 / -1; text-align: center; }

.btn-outline { border: 1px solid var(--border); background: transparent; color: inherit; }
.btn-outline:hover { border-color: var(--foreground); }
.install-guide-link { width: 100%; justify-content: center; }

.product-description { border-top: 1px solid var(--border); padding-top: 3rem; margin-bottom: 3rem; }
.product-description h2 { font-family: var(--font-display); font-size: 1.97rem; margin: 0 0 1.25rem; }
.product-description-content {
  max-width: 65ch;
  font-size: 1.125rem;
  line-height: 1.9;
  color: var(--muted-foreground);
}
.product-description-content > *:first-child { margin-top: 0; }
.product-description-content > *:last-child { margin-bottom: 0; }
.product-description-content ul, .product-description-content ol { padding-inline-start: 1.5rem; }
.product-description-content img { max-width: 100%; height: auto; border-radius: 0.5rem; }

.related-products { border-top: 1px solid var(--border); padding-top: 3rem; }
.related-products h2 { font-family: var(--font-display); font-size: 1.97rem; margin: 0 0 2rem; }

/* ---------- Mobile bottom nav (app-style shell) ---------- */

.mobile-bottom-nav {
  position: fixed;
  inset-inline: 0;
  bottom: 0;
  z-index: 60;
  display: flex;
  justify-content: space-around;
  align-items: center;
  height: 4rem;
  background: color-mix(in srgb, var(--background) 88%, transparent);
  border-top: 1px solid var(--border);
  padding-bottom: env(safe-area-inset-bottom);
  /* Forces its own compositing layer. Fixed + backdrop-filter bars are
     prone to visibly resizing/flickering on Chrome for Android while its
     own address-bar/tab-switcher chrome animates in or out on scroll,
     since the blur would otherwise resample the page behind it every
     frame of that transition. */
  transform: translateZ(0);
}
@supports ( backdrop-filter: blur(1px) ) or ( -webkit-backdrop-filter: blur(1px) ) {
  .mobile-bottom-nav {
    background: color-mix(in srgb, var(--background) 70%, transparent);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
  }
}

.mobile-bottom-nav a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  height: 100%;
  font-size: 0.775rem; /* was 10px at 4.1:1 — the smallest, faintest text on the site */
  color: var(--muted-foreground);
  transition: color 0.2s;
}
.mobile-bottom-nav a svg { width: 1.25rem; height: 1.25rem; flex-shrink: 0; }
.mobile-bottom-nav a:hover { color: var(--foreground); }
.mobile-bottom-nav a.is-active { color: var(--foreground); font-weight: 700; }

/* Same fixed box as the plain svg siblings above, so the cart's extra
   wrapper (needed only to anchor .bn-badge) can't size or shrink
   differently from the other three nav icons. */
.bn-icon-wrap { position: relative; display: inline-flex; width: 1.25rem; height: 1.25rem; flex-shrink: 0; }
.bn-badge {
  position: absolute;
  top: -0.4rem;
  inset-inline-end: -0.6rem;
  min-width: 1rem;
  height: 1rem;
  padding-inline: 0.2rem;
  border-radius: 9999px;
  background: var(--brand-bronze);
  color: #fff;
  font-size: 0.675rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.dark .bn-badge { background: var(--brand-gold); }

@media (min-width: 768px) {
  .mobile-bottom-nav { display: none; }
}

/* ---------- WooCommerce notices ---------- */

.woocommerce-message, .woocommerce-info, .woocommerce-error, .woocommerce-noreviews {
  position: relative;
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 1rem 1.25rem;
  padding-inline-start: 3.75rem;
  border-radius: 0.75rem;
  background: var(--card);
  border: 1px solid var(--border);
  font-size: 1.015rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  box-shadow: 0 2px 10px color-mix(in srgb, var(--foreground) 6%, transparent);
  animation: notice-in 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes notice-in {
  from { opacity: 0; transform: translateY(-0.5rem); }
  to { opacity: 1; transform: translateY(0); }
}

/* Icon badge: replaces WooCommerce's own icon font (a jarring default green/red
   that isn't part of this palette at all) with a small circular brand-colored
   badge, matching the checkmark treatment on the order-received page. */
.woocommerce-message::before, .woocommerce-info::before, .woocommerce-error::before, .woocommerce-noreviews::before {
  content: '';
  font-size: 0;
  position: absolute;
  inset-inline-start: 1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 2rem;
  height: 2rem;
  flex-shrink: 0;
  border-radius: 50%;
  background-color: var(--brand-bronze);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 1rem 1rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E");
}
.dark .woocommerce-message::before, .dark .woocommerce-noreviews::before { background-color: var(--brand-gold); }

.woocommerce-info::before {
  background-color: var(--muted-foreground);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='12' y1='10.5' x2='12' y2='16'/%3E%3Ccircle cx='12' cy='7.5' r='0.75' fill='white' stroke='none'/%3E%3C/svg%3E");
}

.woocommerce-error {
  border-color: #dc2626;
  color: #dc2626;
  background: color-mix(in srgb, #dc2626 8%, var(--card));
}
.woocommerce-error::before {
  background-color: #dc2626;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 6 6 18M6 6l12 12'/%3E%3C/svg%3E");
}

.woocommerce-message .button, .woocommerce-error .button { margin-inline-start: auto; }

/* ---------- Form kit (account + checkout classic forms) ---------- */

.form-row { margin-bottom: 1.25rem; }
.form-row label { display: block; font-size: 0.955rem; font-weight: 600; margin-bottom: 0.4rem; }
.form-row label .required { color: #dc2626; text-decoration: none; }
/* The `body` prefix is load-bearing, not defensive padding.
   WooCommerce ships `.woocommerce form .form-row .input-text` — three
   classes and a type, (0,3,1) — which outranks a plain
   `.form-row input[type="text"]` at (0,2,1). It was winning on every
   account and checkout field, forcing height:auto, a 4px radius, a white
   background and 0.5em padding, so the "My Account" forms rendered as raw
   browser inputs on an otherwise fully-styled page. Source order can't fix
   a specificity loss; adding `body` lifts these to (0,3,2)/(0,2,3), which
   clears core's rule in both shapes. */
body .form-row input[type="text"], body .form-row input[type="email"], body .form-row input[type="tel"],
body .form-row input[type="password"], body .form-row input[type="number"], body .form-row textarea, body .form-row select,
body .woocommerce form .form-row .input-text, body .woocommerce form .form-row select,
body .woocommerce-input-wrapper input, body .woocommerce-input-wrapper select {
  width: 100%;
  height: 2.75rem;
  border: 1px solid var(--input);
  border-radius: 0.5rem;
  padding-inline: 1rem;
  background: var(--card);
  color: inherit;
  font-family: inherit;
  font-size: 1.015rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
body .form-row textarea, body .woocommerce form .form-row textarea.input-text { height: auto; padding-block: 0.75rem; min-height: 6rem; }
body .form-row input:hover:not(:disabled):not([readonly]),
body .form-row select:hover, body .form-row textarea:hover { border-color: color-mix(in srgb, var(--brand-gold) 45%, var(--input)); }
body .form-row input:focus, body .form-row select:focus, body .form-row textarea:focus {
  outline: none;
  border-color: var(--brand-gold);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-gold) 20%, transparent);
}
body .form-row input[readonly] { background: var(--muted); color: var(--muted-foreground); cursor: default; }
.form-row.woocommerce-invalid input { border-color: var(--sale); }

/* Field furniture used by the account forms: an inline "(optional)" marker
   and a small note under an input. */
.form-optional { font-weight: 400; color: var(--muted-foreground); font-size: 0.9rem; }
.form-note { display: block; font-size: 0.88rem; color: var(--muted-foreground); margin-top: 0.4rem; line-height: 1.6; }
.account-form-grid { display: grid; grid-template-columns: 1fr; gap: 0 1.25rem; }
@media (min-width: 640px) {
  .account-form-grid { grid-template-columns: 1fr 1fr; }
  .account-form-grid .form-row-wide, .account-form-grid > .form-row:not(.form-row-first):not(.form-row-last) { grid-column: 1 / -1; }
}
.account-form-actions { margin: 0.5rem 0 0; }

/* Core still lays these out with floats: `.woocommerce form .form-row-first,
   .form-row-last { width: 47%; float: right }`. Inside a grid the float is
   inert, but the 47% is not — it resolves against the grid CELL, so each
   field rendered at just under half of its own column and the name row came
   out as two short inputs with a gap in the middle. The same rule hits the
   address form's wrapper, so neutralize it for every grid wrapper at once
   (3 classes + 2 types beats core's 2 + 1). */
body .woocommerce form .account-form-grid .form-row,
body .woocommerce form .woocommerce-address-fields__field-wrapper .form-row,
body .woocommerce form .woocommerce-billing-fields__field-wrapper .form-row,
body .woocommerce form .woocommerce-shipping-fields__field-wrapper .form-row {
  width: auto;
  float: none;
}

/* Latin digits inside an RTL field: keep the number itself LTR so the
   leading zero stays put, but sit it at the RTL start edge like every other
   field's text. */
body .form-row input[type="tel"] { direction: ltr; text-align: right; }

.woocommerce-billing-fields__field-wrapper, .woocommerce-shipping-fields__field-wrapper,
.woocommerce-address-fields__field-wrapper, .create-account {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0 1.25rem;
}
@media (min-width: 640px) {
  .woocommerce-billing-fields__field-wrapper, .woocommerce-shipping-fields__field-wrapper,
  .woocommerce-address-fields__field-wrapper { grid-template-columns: 1fr 1fr; }
  .form-row-wide { grid-column: 1 / -1; }
}

label.checkbox, .form-row .woocommerce-form__label-for-checkbox {
  display: flex; align-items: center; gap: 0.6rem; font-weight: 400; font-size: 1.015rem; cursor: pointer;
}
.form-row input[type="checkbox"], .form-row input[type="radio"] { width: 1.15rem; height: 1.15rem; accent-color: var(--foreground); flex-shrink: 0; }

.select2-container .select2-selection--single {
  height: 2.75rem !important;
  border: 1px solid var(--input) !important;
  border-radius: 0.5rem !important;
  background: var(--card) !important;
  display: flex;
  align-items: center;
  padding-inline: 1rem;
}
.select2-container .select2-selection__rendered { color: inherit !important; padding: 0 !important; line-height: normal !important; }
.select2-container .select2-selection__arrow { height: 2.75rem !important; }

/* select2's open dropdown is appended to <body>, outside .form-row, and ships
   its own default WP-admin blue (#007cba) highlight — restyle to match the
   warm/neutral palette used everywhere else instead of the plain input skin above. */
.select2-dropdown {
  border: 1px solid var(--border) !important;
  border-radius: 0.5rem !important;
  background: var(--card) !important;
  font-family: var(--font-body);
  overflow: hidden;
}
.select2-search--dropdown { padding: 0.5rem !important; background: var(--card); }
.select2-search--dropdown .select2-search__field {
  border: 1px solid var(--input) !important;
  border-radius: 0.375rem !important;
  background: var(--background) !important;
  color: inherit !important;
  font-family: inherit !important;
  padding-inline: 0.6rem !important;
}
.select2-results__option { color: var(--foreground); }
.select2-results__option--highlighted[aria-selected],
.select2-results__option[aria-selected="true"] {
  background: var(--accent) !important;
  color: var(--accent-foreground) !important;
}

fieldset { border: 1px solid var(--border); border-radius: 0.5rem; padding: 1.25rem; margin: 0 0 1.5rem; }
fieldset legend { padding-inline: 0.5rem; font-weight: 700; font-family: var(--font-display); font-size: 1.18rem; }

.woocommerce a.button, .woocommerce button.button, .woocommerce input.button, .woocommerce #place_order {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border-radius: 9999px;
  height: 2.75rem;
  padding-inline: 1.75rem;
  font-size: 1.015rem;
  font-weight: 400;
  border: 0;
  background: var(--primary);
  color: var(--primary-foreground);
  cursor: pointer;
  transition: opacity 0.2s;
}
.woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce #place_order:hover {
  background: var(--primary);
  opacity: 0.85;
  color: var(--primary-foreground);
}
.woocommerce button.button:disabled, .woocommerce button.button.disabled, .woocommerce input.button:disabled {
  background: var(--muted) !important; color: var(--muted-foreground) !important; opacity: 1 !important; cursor: not-allowed;
}
/* WooCommerce's own stylesheet ships a higher-specificity `.button.alt` rule
   (its default brand purple, #7f54b9) that otherwise wins over the plain
   `.woocommerce a.button` rule above on the cart's "Proceed to checkout" link. */
.woocommerce a.button.alt, .woocommerce button.button.alt, .woocommerce input.button.alt {
  background: var(--primary);
  color: var(--primary-foreground);
}
.woocommerce a.button.alt:hover, .woocommerce button.button.alt:hover, .woocommerce input.button.alt:hover {
  background: var(--primary);
  opacity: 0.85;
  color: var(--primary-foreground);
}
.dark .woocommerce a.button.alt:hover, .dark .woocommerce button.button.alt:hover, .dark .woocommerce input.button.alt:hover {
  background: var(--brand-gold);
}

/* ---------- My Account shell ----------
   Layout is a sticky sidebar + content card, the same shape as the shop
   archive's .shop-layout. Everything inside now speaks the theme's own
   vocabulary (display serif headings, gold rules, warm card surfaces)
   instead of WooCommerce's defaults — see the form-kit override below for
   why the inputs in particular had to be reclaimed. */

.account-shell {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding-block: 2.5rem 4rem;
}
@media (min-width: 1024px) {
  .account-shell { flex-direction: row; align-items: flex-start; gap: 2.25rem; }
  .account-nav-wrap { flex: 0 0 17rem; position: sticky; top: 5.5rem; }
  .account-content { flex: 1; min-width: 0; }
}

.account-nav-wrap {
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--card);
  overflow: hidden;
}

/* WooCommerce core ships `.woocommerce-account .woocommerce-MyAccount-navigation
   { float: right; width: 30% }` (its old two-column layout) which shrink-wraps
   this nav to its text instead of filling .account-nav-wrap — the active
   item's pill background then renders narrower than its own label. That core
   rule's two-class selector outweighs a plain `.woocommerce-MyAccount-navigation`
   here despite our stylesheet loading later, so match its specificity to win. */
.woocommerce-account .woocommerce-MyAccount-navigation { float: none; width: 100%; }

/* Identity block: says whose account this is. Without it the sidebar was six
   anonymous links that could have belonged to anyone. */
.account-identity {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 1.15rem 1.15rem 1rem;
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--brand-gold) 7%, var(--card));
}
.account-avatar {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--brand-gold) 18%, var(--background));
  border: 1px solid color-mix(in srgb, var(--brand-gold) 45%, transparent);
  color: var(--brand-bronze);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.405rem;
  line-height: 1;
}
.dark .account-avatar { color: var(--brand-gold); }
.account-identity-text { display: flex; flex-direction: column; min-width: 0; gap: 0.15rem; }
.account-identity-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.18rem;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* The phone is Latin digits inside an RTL block; without an explicit
   direction the leading zero hops to the wrong end. */
.account-identity-phone {
  font-size: 0.88rem;
  color: var(--muted-foreground);
  direction: ltr;
  text-align: right;
}

.woocommerce-MyAccount-navigation ul { list-style: none; margin: 0; padding: 0.5rem; display: flex; flex-direction: column; gap: 0.1rem; }
.woocommerce-MyAccount-navigation a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.7rem 0.9rem;
  border-radius: 0.6rem;
  font-size: 1.015rem;
  font-weight: 600;
  color: var(--muted-foreground);
  transition: background 0.2s, color 0.2s;
}
.account-nav-icon { display: flex; flex-shrink: 0; }
.account-nav-icon svg { width: 1.15rem; height: 1.15rem; }
.woocommerce-MyAccount-navigation a:hover { background: color-mix(in srgb, var(--muted) 65%, transparent); color: var(--foreground); }

/* Active state is a warm tint plus a gold marker, not the solid black slab
   this used to be: at 17rem wide that slab was the heaviest object on the
   page and pulled the eye away from the content it was labelling. */
.woocommerce-MyAccount-navigation li.is-active a {
  background: color-mix(in srgb, var(--brand-gold) 13%, var(--background));
  color: var(--foreground);
}
.woocommerce-MyAccount-navigation li.is-active a::before {
  content: '';
  position: absolute;
  inset-inline-start: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 1.4rem;
  border-radius: 9999px;
  background: var(--brand-gold);
}
.woocommerce-MyAccount-navigation li.is-active .account-nav-icon { color: var(--brand-bronze); }
.dark .woocommerce-MyAccount-navigation li.is-active .account-nav-icon { color: var(--brand-gold); }
.woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--customer-logout { border-top: 1px solid var(--border); margin-top: 0.4rem; padding-top: 0.4rem; }

/* Under lg the sidebar stacked ABOVE the content at full height, so landing
   on any account page pushed the actual content most of a screen down. A grid
   keeps the same links one thumb-reach away without that cost. */
@media (max-width: 1023px) {
  .account-nav-wrap { border-radius: 0.85rem; }
  /* Compact identity: on a phone this block sits above everything else, so
     the desktop proportions cost a third of the first screen before any
     content appears. Same information, one line shorter. */
  .account-identity { padding: 0.7rem 0.85rem; gap: 0.65rem; }
  .account-avatar { width: 2.1rem; height: 2.1rem; font-size: 1.125rem; }
  .account-identity-name { font-size: 1.07rem; }
  .account-identity-phone { font-size: 0.81rem; }

  /* A grid, not the horizontal scroller this used to be. As one nowrap row the
     six tabs measured 793px against a 348px strip on a 390px phone, so four of
     them — نشانی and علاقه‌مندی‌ها among them — sat off-screen behind a swipe that
     no edge fade or cut-off tab hinted at. Every tab is now on screen.

     Three per row, in explicit columns. auto-fit was tempting and wrong: it
     found room for four at 414px, which splits six tabs 4+2 and leaves a hole
     where the fifth and sixth would go. A fixed three divides them evenly. */
  .woocommerce-MyAccount-navigation ul {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.35rem;
    padding: 0.5rem;
  }
  /* Icon over label, because side by side the icon, its gap and the padding ate
     57px of an 84px cell and left the label almost nothing. */
  .woocommerce-MyAccount-navigation li { display: flex; }
  .woocommerce-MyAccount-navigation a {
    flex: 1;
    flex-direction: column;
    justify-content: center;
    gap: 0.3rem;
    min-height: 4.4rem;
    padding: 0.55rem 0.35rem;
    text-align: center;
    font-size: 0.83rem;
    line-height: 1.35;
  }
  /* li stretches to its grid row and the anchor flexes to fill it, so a label
     that wraps to two lines doesn't leave the pills beside it short. */
  .account-nav-icon svg { width: 1.3rem; height: 1.3rem; }
  .woocommerce-MyAccount-navigation li.is-active a::before { content: none; }
  .woocommerce-MyAccount-navigation li.is-active a {
    background: color-mix(in srgb, var(--brand-gold) 16%, var(--background));
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand-gold) 40%, transparent);
  }
  /* The desktop list rules خروج off because in a vertical list it would read as
     a sixth page; among tiles its own icon and last place already say what it is. */
  .woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--customer-logout {
    border-top: 0; margin-top: 0; padding-top: 0;
  }
}

/* Above ~34rem all six fit on one row as a tab bar, which is both shorter than
   two rows and closer to what the desktop sidebar does. Below it, three columns
   keep the longest label («علاقه‌مندی‌ها») on one line. */
@media (min-width: 544px) and (max-width: 1023px) {
  .woocommerce-MyAccount-navigation ul { grid-template-columns: repeat(6, 1fr); }
}

.account-content {
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--background);
  padding: 1.75rem;
}
@media (min-width: 768px) { .account-content { padding: 2rem 2.25rem; } }

/* Section heading shared by every sub-page, so orders/wishlist/addresses all
   announce themselves the same way. Core gives most of these endpoints no
   heading at all — you simply land on a table. */
.account-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}
.account-section-head h2, .account-section-head h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.69rem;
  margin: 0;
}
.account-section-head h3 { font-size: 1.35rem; }
.account-section-count, .account-section-link { font-size: 0.955rem; color: var(--muted-foreground); }
.account-section-link { font-weight: 700; color: var(--brand-bronze); }
.dark .account-section-link { color: var(--brand-gold); }
.account-section-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.account-section-intro { color: var(--muted-foreground); margin: -0.75rem 0 1.5rem; font-size: 1.035rem; }

/* ---------- Dashboard ---------- */

.dashboard-greeting { margin-bottom: 2rem; }
.dashboard-eyebrow {
  font-size: 0.81rem;
  letter-spacing: 0.18em;
  color: var(--brand-bronze);
  margin: 0 0 0.4rem;
}
.dark .dashboard-eyebrow { color: var(--brand-gold); }
.dashboard-greeting h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.91rem, 3.94vw, 2.53rem);
  margin: 0;
}
.dashboard-greeting .gold-rule { margin-block: 0.75rem 1rem; }
.dashboard-greeting p { color: var(--muted-foreground); margin: 0; max-width: 34rem; }

.dashboard-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}
@media (min-width: 640px) { .dashboard-stats { gap: 1rem; } }
.dashboard-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  text-align: center;
  padding: 1.25rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 0.85rem;
  background: var(--card);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.dashboard-stat:hover {
  border-color: color-mix(in srgb, var(--brand-gold) 50%, transparent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-card-hover);
  color: inherit;
}
.dashboard-stat-num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2.135rem;
  line-height: 1;
  color: var(--brand-bronze);
}
.dark .dashboard-stat-num { color: var(--brand-gold); }
.dashboard-stat-label { font-size: 0.845rem; color: var(--muted-foreground); line-height: 1.4; }

/* ---------- Order cards (orders list + dashboard "latest order") ----------
   Replaces the re-skinned <table>: a table can only ever show the four
   columns WooCommerce defines, so orders rendered as label/value pairs with
   no product imagery — on a store selling decorative mouldings that was the
   most generic surface on the site. */

.order-list { display: flex; flex-direction: column; gap: 0.85rem; }

.order-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 0.9rem;
  background: var(--card);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.order-card:hover {
  border-color: color-mix(in srgb, var(--brand-gold) 45%, transparent);
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-1px);
  color: inherit;
}

/* Thumbnails overlap into a small stack — an order is one thing, not three,
   and a row of separate squares reads as three separate orders. */
.order-card-thumbs { display: flex; flex-shrink: 0; }
.order-thumb {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 0.6rem;
  overflow: hidden;
  background: var(--background);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-contact);
}
.order-thumb + .order-thumb { margin-inline-start: -1.1rem; }
.order-thumb img { width: 100%; height: 100%; object-fit: cover; }
.order-thumb--more {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--muted-foreground);
  background: var(--muted);
}

.order-card-body { flex: 1; min-width: 0; }
.order-card-top { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; }
.order-card-number { font-family: var(--font-display); font-weight: 700; font-size: 1.24rem; direction: ltr; }
.order-card-meta { font-size: 0.9rem; color: var(--muted-foreground); margin: 0.3rem 0 0; }
.order-card-dot { margin-inline: 0.4rem; }
/* The total anchors the far end of the row. Left inside .order-card-body it
   sat under the date, and since the body is flex:1 with right-aligned RTL
   text, everything clustered against the right edge with a wide dead gap
   before the chevron. */
.order-card-side { flex-shrink: 0; text-align: start; }
.order-card-total { font-weight: 700; font-size: 1.07rem; white-space: nowrap; }
.order-card-cta { flex-shrink: 0; color: var(--muted-foreground); transition: color 0.2s, transform 0.2s; }
.order-card-cta svg { width: 1.15rem; height: 1.15rem; }
.order-card:hover .order-card-cta { color: var(--brand-bronze); transform: translateX(-3px); }
.dark .order-card:hover .order-card-cta { color: var(--brand-gold); }

@media (max-width: 479px) {
  .order-card { gap: 0.75rem; padding: 0.85rem; }
  .order-thumb { width: 2.75rem; height: 2.75rem; }
  .order-card-cta { display: none; }
}

/* Status as a pill, grouped into three tones (see
   polyabzar_order_status_tone) so the list reads at a glance instead of
   making people parse seven different Persian words for "in progress". */
.order-status {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.65rem;
  border-radius: 9999px;
  font-size: 0.81rem;
  font-weight: 700;
  line-height: 1.6;
  white-space: nowrap;
}
.order-status::before { content: ''; width: 0.4rem; height: 0.4rem; border-radius: 50%; background: currentColor; }
.order-status--done { background: color-mix(in srgb, #15803d 12%, transparent); color: #15803d; }
.order-status--active { background: color-mix(in srgb, var(--brand-gold) 20%, transparent); color: var(--brand-bronze); }
.order-status--stopped { background: color-mix(in srgb, #dc2626 11%, transparent); color: #dc2626; }
.dark .order-status--done { background: color-mix(in srgb, #4ade80 16%, transparent); color: #4ade80; }
.dark .order-status--active { color: var(--brand-gold); }
.dark .order-status--stopped { background: color-mix(in srgb, #f87171 16%, transparent); color: #f87171; }

.woocommerce-pagination { display: flex; justify-content: center; gap: 0.5rem; margin-top: 1.75rem; }

/* ---------- Empty states ----------
   Shared by orders / wishlist / dashboard. Core prints a bare sentence (or a
   notice box); a centered icon + line + action reads as a designed state
   rather than a missing one. */
.account-empty {
  text-align: center;
  padding-block: 3rem;
  color: var(--muted-foreground);
}
.account-empty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.5rem;
  height: 3.5rem;
  margin-bottom: 1rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--brand-gold) 12%, var(--card));
  color: var(--brand-bronze);
}
.dark .account-empty-icon { color: var(--brand-gold); }
.account-empty-icon svg { width: 1.6rem; height: 1.6rem; }
.account-empty p { margin: 0 0 1.5rem; }

/* ---------- View single order ---------- */

/* Summary header replacing core's run-on "Order #x was placed on y and is
   currently z." sentence. */
.order-summary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: 0.9rem;
  background: var(--card);
}
@media (min-width: 640px) { .order-summary { grid-template-columns: repeat(3, 1fr); gap: 1.5rem; } }
.order-summary-row { display: flex; flex-direction: column; gap: 0.4rem; align-items: flex-start; }
.order-summary-label { font-size: 0.845rem; color: var(--muted-foreground); }
.order-summary-value { font-size: 1.07rem; }
.order-summary-value--strong { font-weight: 700; }

.order-notes-title { font-family: var(--font-display); font-weight: 700; font-size: 1.35rem; margin: 2rem 0 1rem; }
.order-notes { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.75rem; }
.order-note { border: 1px solid var(--border); border-radius: 0.75rem; padding: 1rem 1.25rem; background: var(--card); }
.order-note-meta { font-size: 0.845rem; color: var(--muted-foreground); margin: 0 0 0.35rem; }
.order-note-body { font-size: 1.015rem; }
.order-note-body p { margin: 0; }

.woocommerce-order-details, .woocommerce-customer-details { margin-top: 2rem; }
.woocommerce-order-details__title, .woocommerce-column__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.35rem;
  margin: 0 0 1rem;
}
.woocommerce-table--order-details {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid var(--border);
  border-radius: 0.9rem;
  overflow: hidden;
  background: var(--card);
  font-size: 1.015rem;
}
.woocommerce-table--order-details th, .woocommerce-table--order-details td {
  padding: 0.85rem 1.1rem;
  text-align: start;
  border-bottom: 1px solid var(--border);
}
.woocommerce-table--order-details thead th { background: color-mix(in srgb, var(--muted) 55%, transparent); font-size: 0.9rem; color: var(--muted-foreground); font-weight: 700; }
.woocommerce-table--order-details tfoot tr:last-child th, .woocommerce-table--order-details tfoot tr:last-child td { border-bottom: 0; font-weight: 700; }
.woocommerce-table--order-details .woocommerce-Price-amount { white-space: nowrap; }
.woocommerce-order p mark { font-weight: 700; background: none; color: var(--brand-bronze); }
.dark .woocommerce-order p mark { color: var(--brand-gold); }
.woocommerce-customer-details address {
  font-style: normal;
  font-size: 1.015rem;
  line-height: 2;
  color: var(--muted-foreground);
  border: 1px solid var(--border);
  border-radius: 0.9rem;
  padding: 1.25rem 1.5rem;
  background: var(--card);
}

/* ---------- Addresses ---------- */

.address-grid { display: grid; grid-template-columns: 1fr; gap: 1rem; list-style: none; padding: 0; margin: 0; }
@media (min-width: 640px) { .address-grid { grid-template-columns: 1fr 1fr; } }
.address-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: 0.9rem;
  padding: 1.4rem 1.5rem;
  background: var(--card);
}
.address-card .woocommerce-Address-title { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.9rem; }
.address-card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--brand-gold) 14%, transparent);
  color: var(--brand-bronze);
  flex-shrink: 0;
}
.dark .address-card-icon { color: var(--brand-gold); }
.address-card-icon svg { width: 1rem; height: 1rem; }
.address-card h3 { font-family: var(--font-display); font-size: 1.24rem; font-weight: 700; margin: 0; }
.address-card address { font-style: normal; font-size: 1.015rem; line-height: 2; color: var(--muted-foreground); margin: 0; }
.address-card-action {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: auto;
  padding-top: 1rem;
  font-size: 0.925rem;
  font-weight: 700;
  color: var(--brand-bronze);
  align-self: flex-start;
}
.dark .address-card-action { color: var(--brand-gold); }
.address-card-action svg { width: 0.8rem; height: 0.8rem; }
.address-card-action:hover { text-decoration: underline; text-underline-offset: 3px; color: var(--brand-bronze); }

/* An unset address used to be one line of grey text floating at the top of a
   card stretched to match its filled neighbour. Center the state instead, so
   the pair reads as deliberate either way. */
.address-card.is-empty { align-items: center; justify-content: center; text-align: center; gap: 0.75rem; min-height: 11rem; }
.address-card.is-empty .woocommerce-Address-title { flex-direction: column; margin-bottom: 0; }
.address-card-empty { font-size: 0.99rem; color: var(--muted-foreground); margin: 0; }

/* ---------- Wishlist ---------- */
.wishlist-empty .btn-pill { margin-top: 0; }

/* ---------- Auth (phone + OTP login) ---------- */

.auth-wrap { max-width: 28rem; margin-inline: auto; padding-block: 3rem 4rem; }
.auth-wrap .section-title--center { margin-bottom: 2rem; }
.auth-card { border: 1px solid var(--border); border-radius: 1rem; background: var(--card); padding: 2rem; }
.auth-card .woocommerce-button { width: 100%; }

/* Checkout's login gate — same card look as .auth-wrap, but sized to sit
   inside .checkout-wrap instead of full-page-centered. */
.auth-gate { max-width: 28rem; margin-inline: auto; text-align: center; }
.auth-gate-sub { color: var(--muted-foreground); margin-bottom: 1.5rem; }
.auth-gate .auth-card { text-align: right; }

.phone-otp-error { color: #dc2626; font-size: 0.955rem; margin: -0.5rem 0 0.75rem; }
.phone-otp-hint { font-size: 1.015rem; color: var(--muted-foreground); margin-bottom: 1rem; }
.phone-otp-dev-code { font-size: 0.9rem; color: var(--brand-bronze-text); background: color-mix(in srgb, var(--brand-gold) 15%, transparent); border-radius: 0.375rem; padding: 0.5rem 0.75rem; margin-bottom: 1rem; }
.phone-otp-change { text-align: center; margin-top: 0.5rem; }
.otp-change-phone-btn { background: none; border: 0; color: var(--muted-foreground); font-size: 0.955rem; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.otp-change-phone-btn:hover { color: var(--foreground); }

/* ---------- Cart ---------- */

.cart-wrap { padding-block: 2rem 4rem; }
.cart-title { margin-bottom: 2rem; }
.cart-layout { display: flex; flex-direction: column; gap: 2rem; }
@media (min-width: 1024px) {
  .cart-layout { flex-direction: row; align-items: flex-start; }
  .cart-items-col { flex: 1; min-width: 0; }
  .cart-summary-col { flex: 0 0 20rem; position: sticky; top: 5.5rem; }
}

.cart-item-card { display: flex; gap: 1rem; align-items: center; padding: 1.25rem; border: 1px solid var(--border); border-radius: 0.75rem; background: var(--card); margin-bottom: 1rem; }
.cart-item-thumb { flex: 0 0 5rem; width: 5rem; height: 5rem; border-radius: 0.5rem; overflow: hidden; background: var(--muted); }
.cart-item-thumb img { width: 100%; height: 100%; object-fit: cover; }
.cart-item-main { flex: 1; min-width: 0; }
.cart-item-main a { font-family: var(--font-display); font-weight: 700; font-size: 1.125rem; }
.cart-item-price { font-size: 0.955rem; color: var(--muted-foreground); margin-top: 0.25rem; }
.cart-item-actions { display: flex; align-items: center; gap: 1rem; margin-top: 0.75rem; flex-wrap: wrap; }
.cart-item-actions .qty-stepper { height: 2.5rem; }
.cart-item-actions .qty-stepper input { width: 3rem; }
.cart-item-subtotal { font-weight: 700; color: var(--brand-bronze-text); white-space: nowrap; margin-inline-start: auto; }
.cart-item-remove { color: var(--muted-foreground); font-size: 1.575rem; line-height: 1; background: none; border: 0; cursor: pointer; padding: 0.25rem; flex-shrink: 0; }
.cart-item-remove:hover { color: var(--sale); }

.cart-actions-row { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: center; justify-content: space-between; margin-top: 1.5rem; }
.cart-coupon { display: flex; gap: 0.5rem; flex: 1; min-width: 14rem; }
.cart-coupon input { flex: 1; height: 2.75rem; border: 1px solid var(--input); border-radius: 9999px; padding-inline: 1.25rem; background: var(--card); font-family: inherit; }

.cart-empty-state { text-align: center; padding-block: 4rem; }
.cart-empty-state svg { width: 3.5rem; height: 3.5rem; color: var(--muted-foreground); margin-bottom: 1.5rem; }
.cart-empty-state p { color: var(--muted-foreground); margin-bottom: 1.5rem; font-size: 1.18rem; }

.cart-summary-card, .checkout-summary-card { border: 1px solid var(--border); border-radius: 0.75rem; background: var(--card); padding: 1.5rem; }
.cart-summary-card h2, .checkout-summary-card h3 { font-family: var(--font-display); font-size: 1.405rem; margin: 0 0 1rem; }
.totals-row { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding-block: 0.6rem; border-bottom: 1px solid var(--border); font-size: 1.015rem; }
.totals-row:last-of-type { border-bottom: 0; }
.totals-row.order-total { font-weight: 700; font-size: 1.24rem; padding-top: 1rem; }
.totals-row.order-total .amount { color: var(--brand-bronze-text); }
.cart-summary-card .btn-pill { width: 100%; margin-top: 1.25rem; justify-content: center; }
.wc-proceed-to-checkout { margin-top: 1.25rem; }
.wc-proceed-to-checkout .checkout-button { width: 100%; height: 3rem; }

.cross-sells { border-top: 1px solid var(--border); padding-top: 2.5rem; margin-top: 2.5rem; }
.cross-sells h2 { font-family: var(--font-display); font-size: 1.69rem; margin: 0 0 1.5rem; }

/* ---------- Checkout ---------- */

.checkout-wrap { padding-block: 2rem 4rem; }
.checkout-layout { display: flex; flex-direction: column; gap: 2rem; }
@media (min-width: 1024px) {
  .checkout-layout { flex-direction: row; align-items: flex-start; }
  .checkout-summary { flex: 0 0 22rem; position: sticky; top: 5.5rem; }
  .checkout-fields { flex: 1; min-width: 0; }
}

.checkout-line-item { display: flex; justify-content: space-between; gap: 1rem; padding-block: 0.6rem; border-bottom: 1px solid var(--border); font-size: 0.955rem; }
.checkout-line-item .name { color: var(--foreground); }
.checkout-line-item .qty { color: var(--muted-foreground); font-size: 0.9rem; }

.checkout-section { margin-bottom: 2rem; }
.checkout-section h3 { font-family: var(--font-display); font-size: 1.465rem; margin: 0 0 1.25rem; }

.wc_payment_methods { list-style: none; margin: 0 0 1.25rem; padding: 0; display: flex; flex-direction: column; gap: 0.75rem; }
.wc_payment_method { border: 1px solid var(--border); border-radius: 0.5rem; padding: 1rem; background: var(--card); }
.wc_payment_method label { font-weight: 700; cursor: pointer; display: flex; align-items: center; gap: 0.6rem; margin: 0; }
.wc_payment_method input[type="radio"] { width: 1.15rem; height: 1.15rem; accent-color: var(--foreground); }
/* Gateway logos get no size from WooCommerce — its rule for these sets only
   margin/padding/position/box-shadow — so they render at natural size. Zibal
   ships a 150x71 PNG, which fills the narrow order-summary column and wraps
   the method title onto two lines. Full WC selector because the margin reset
   overrides theirs, and a bare `.wc_payment_method img` (0,1,1) would lose to
   `.woocommerce-checkout #payment ul.payment_methods li img` (1,2,3) — the
   same trap documented on .payment_box below. The `auto` inline-start margin
   parks the logo on the far edge of the flex label instead of crowding it. */
#add_payment_method #payment ul.payment_methods li img,
.woocommerce-cart #payment ul.payment_methods li img,
.woocommerce-checkout #payment ul.payment_methods li img { max-height: 1.75rem; width: auto; margin: 0; margin-inline-start: auto; }
.payment_box { margin-top: 0.75rem; padding-top: 0.75rem; border-top: 1px dashed var(--border); font-size: 0.955rem; color: var(--muted-foreground); }
/* The background needs WooCommerce's own selector, not just `.payment_box`.
   WC paints this box its brand lavender (#dcd7e2) from
   `.woocommerce-checkout #payment div.payment_box` — specificity (1,2,1),
   which beats a bare `.payment_box` (0,1,0) no matter the source order. A
   plain `background: transparent` was added here on 2026-07-24 and silently
   never applied for exactly that reason. Same trap as `.button.alt` further
   up: when overriding WooCommerce, match its selector, don't shorten it. */
#add_payment_method #payment div.payment_box,
.woocommerce-cart #payment div.payment_box,
.woocommerce-checkout #payment div.payment_box { background: transparent; }
.payment_box p { margin: 0; }

.woocommerce-terms-and-conditions-wrapper { margin-bottom: 1.25rem; font-size: 0.955rem; }
.place-order #place_order { width: 100%; height: 3.25rem; font-size: 1.125rem; }

.woocommerce-order { max-width: 34rem; margin-inline: auto; padding-block: 3rem 5rem; text-align: center; }
.woocommerce-order-icon { width: 4rem; height: 4rem; margin: 0 auto 1.5rem; border-radius: 50%; background: var(--brand-gold); color: #fff; display: flex; align-items: center; justify-content: center; }
.woocommerce-order-icon svg { width: 1.75rem; height: 1.75rem; }
.woocommerce-thankyou-order-received { font-size: 1.295rem; font-weight: 700; }
.woocommerce-order-overview {
  list-style: none; margin: 2rem 0; padding: 1.5rem; border: 1px solid var(--border); border-radius: 0.75rem;
  background: var(--card); text-align: right; display: flex; flex-direction: column; gap: 0.75rem;
}
.woocommerce-order-overview li { display: flex; justify-content: space-between; font-size: 1.015rem; }
.woocommerce-order-actions { display: flex; gap: 0.75rem; justify-content: center; margin-top: 2rem; flex-wrap: wrap; }

/* ---------- Inspiration gallery ---------- */

.insp-hero { padding-block: 3rem 1.5rem; text-align: center; }
.insp-hero-sub { color: var(--muted-foreground); font-size: 1.18rem; max-width: 36rem; margin: 1rem auto 0; line-height: 1.9; }

.insp-wrap { padding-block: 1rem 4rem; }
.insp-filters { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-bottom: 2rem; }
.insp-chip { border: 1px solid var(--border); background: transparent; color: var(--muted-foreground); border-radius: 9999px; padding: 0.5rem 1.25rem; font-size: 0.955rem; font-family: inherit; cursor: pointer; transition: 0.2s; }
.insp-chip:hover { border-color: var(--foreground); color: var(--foreground); }
.insp-chip.is-active { background: var(--primary); color: var(--primary-foreground); border-color: var(--primary); }

.insp-grid { columns: 1; column-gap: 1rem; }
@media (min-width: 640px) { .insp-grid { columns: 2; } }
@media (min-width: 1024px) { .insp-grid { columns: 3; } }
.insp-tile { display: block; width: 100%; break-inside: avoid; margin-bottom: 1rem; position: relative; border: 0; padding: 0; border-radius: 1rem; overflow: hidden; cursor: pointer; background: var(--muted); }
.insp-tile img, .insp-tile a { -webkit-user-drag: none; user-drag: none; }
.insp-tile img { width: 100%; height: auto; display: block; transition: transform 0.5s ease; }
.insp-tile:hover img { transform: scale(1.04); }
.insp-tile-label {
  position: absolute; bottom: 0.75rem; inset-inline-start: 0.75rem;
  background: color-mix(in srgb, var(--background) 88%, transparent); backdrop-filter: blur(4px);
  border-radius: 9999px; padding: 0.35rem 0.9rem; font-size: 0.845rem; font-weight: 700;
  opacity: 0; transform: translateY(0.5rem); transition: 0.2s;
}
.insp-tile:hover .insp-tile-label, .insp-tile:focus-visible .insp-tile-label { opacity: 1; transform: translateY(0); }

.insp-drawer { position: fixed; inset: 0; z-index: 70; visibility: hidden; }
.insp-drawer.is-open { visibility: visible; }
.insp-drawer-backdrop { position: absolute; inset: 0; background: var(--scrim-backdrop); opacity: 0; transition: opacity 0.3s; border: 0; padding: 0; cursor: pointer; }
.insp-drawer.is-open .insp-drawer-backdrop { opacity: 1; }
.insp-drawer-panel {
  position: absolute; top: 0; bottom: 0; inset-inline-start: 0; width: 100%; max-width: 30rem;
  background: var(--background); box-shadow: 10px 0 30px rgba(0, 0, 0, 0.15);
  transform: translateX(100%); transition: transform 0.35s cubic-bezier(0.25, 1, 0.5, 1);
  overflow-y: auto;
}
.insp-drawer.is-open .insp-drawer-panel { transform: translateX(0); }
.insp-drawer-close {
  position: absolute; top: 1rem; inset-inline-start: 1rem; z-index: 2; width: 2.5rem; height: 2.5rem;
  border-radius: 50%; border: 0; background: color-mix(in srgb, var(--background) 85%, transparent);
  color: inherit; font-size: 1.69rem; line-height: 1; cursor: pointer;
}
.insp-drawer-media { aspect-ratio: 4 / 3; background: var(--muted); }
.insp-drawer-media img { width: 100%; height: 100%; object-fit: cover; }
.insp-drawer-body { padding: 1.75rem; }
.insp-drawer-body h2 { font-family: var(--font-display); font-size: 1.69rem; margin: 0.75rem 0 1.5rem; }
@media (max-width: 640px) {
  .insp-drawer-panel { max-width: 100%; }
}

/* Product image lightbox — click the main gallery photo (or its zoom
   button) to see it full-screen; unlike .insp-drawer this centers the
   image itself rather than sliding in a side panel, since there's no
   accompanying text content to show alongside it. */
.img-lightbox { position: fixed; inset: 0; z-index: 80; visibility: hidden; }
.img-lightbox.is-open { visibility: visible; }
.img-lightbox-backdrop { position: absolute; inset: 0; background: var(--scrim-media); opacity: 0; transition: opacity 0.3s; border: 0; padding: 0; cursor: pointer; }
.img-lightbox.is-open .img-lightbox-backdrop { opacity: 1; }
.img-lightbox-panel {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  padding: 2rem; pointer-events: none;
  opacity: 0; transform: scale(0.95); transition: opacity 0.25s, transform 0.25s;
}
.img-lightbox.is-open .img-lightbox-panel { opacity: 1; transform: scale(1); }
.img-lightbox-panel img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 0.5rem; pointer-events: auto; cursor: zoom-out; }
.img-lightbox-close {
  position: absolute; top: 1rem; inset-inline-end: 1rem; z-index: 2; width: 2.5rem; height: 2.5rem;
  border-radius: 50%; border: 0; background: color-mix(in srgb, var(--background) 85%, transparent);
  color: var(--foreground); font-size: 1.69rem; line-height: 1; cursor: pointer; pointer-events: auto;
}

/* ---------- همکاری با ما (work-with-us) ----------
   Informational only — no form lives here. Two equal tracks, then the path,
   then a band that hands off to the contact page. The cards are deliberately
   the same weight: neither track is the "real" one, and making one bigger
   would push everyone down it. */

.wwu-hero { padding-block: 3rem 1.5rem; text-align: center; }
.wwu-hero-sub {
  color: var(--muted-foreground); font-size: 1.18rem;
  max-width: 42rem; margin: 1.25rem auto 0; line-height: 1.9;
}

.wwu-tracks { display: grid; grid-template-columns: 1fr; gap: 1.5rem; padding-block: 1rem 3.5rem; }
@media (min-width: 860px) { .wwu-tracks { grid-template-columns: 1fr 1fr; } }

.wwu-track {
  display: flex; flex-direction: column;
  background: var(--card); border: 1px solid var(--border);
  border-radius: 1rem; padding: clamp(1.5rem, 3vw, 2.25rem);
  box-shadow: var(--shadow-raised); transition: box-shadow 0.25s;
}
.wwu-track:hover { box-shadow: var(--shadow-card-hover); }
.wwu-track-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 3rem; height: 3rem; border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--brand-gold) 50%, transparent);
  color: var(--brand-gold); margin-bottom: 1.25rem;
}
.wwu-track-icon svg { width: 1.4rem; height: 1.4rem; }
.wwu-track-eyebrow { font-size: 0.88rem; font-weight: 600; color: var(--brand-bronze-text); }
.wwu-track h2 {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.69rem, 3.375vw, 2.135rem); margin: 0.35rem 0 0.75rem;
}
.wwu-track-lead { color: var(--muted-foreground); line-height: 1.9; margin: 0 0 1.35rem; }

.wwu-track-points { list-style: none; padding: 0; margin: 0 0 1.35rem; display: grid; gap: 0.6rem; }
.wwu-track-points li { display: flex; align-items: flex-start; gap: 0.6rem; font-size: 1.035rem; line-height: 1.7; }
.wwu-track-points svg { width: 1.05rem; height: 1.05rem; flex-shrink: 0; margin-top: 0.28rem; color: var(--brand-gold); }

.wwu-track-for {
  font-size: 0.955rem; color: var(--muted-foreground); line-height: 1.8;
  border-top: 1px solid var(--border); padding-top: 1.1rem; margin: 0 0 1.6rem;
}
.wwu-track-for span { font-weight: 600; color: var(--foreground); }
/* Pinned to the bottom so both cards' buttons align even when the bullet
   lists end at different heights. */
.wwu-track-cta { margin-top: auto; align-self: flex-start; }

.wwu-steps-band {
  background: color-mix(in srgb, var(--muted) 40%, var(--background));
  padding-block: 4rem;
}
.wwu-steps { list-style: none; padding: 0; margin: 2.25rem 0 0; display: grid; gap: 2.25rem; }
@media (min-width: 768px) { .wwu-steps { grid-template-columns: repeat(3, 1fr); gap: 2rem; } }
.wwu-steps li { text-align: center; }
.wwu-step-n {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.75rem; height: 2.75rem; border-radius: 50%;
  background: var(--primary); color: var(--primary-foreground);
  font-family: var(--font-display); font-size: 1.465rem; margin-bottom: 0.9rem;
}
.wwu-steps h3 { font-family: var(--font-display); font-size: 1.35rem; margin: 0 0 0.4rem; }
.wwu-steps p { color: var(--muted-foreground); font-size: 1.035rem; line-height: 1.8; margin: 0; }
.wwu-draft-note { max-width: 44rem; margin-inline: auto; margin-top: 2.5rem; }

/* Hand-off band. The phone is the primary action here for the same reason it
   is on the contact page: for a project enquiry a call settles in a minute
   what a form takes two days to. */
.wwu-contact-band { padding-block: 4rem; text-align: center; }
.wwu-contact-band h2 { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.8rem, 3.94vw, 2.475rem); margin: 0 0 0.9rem; }
.wwu-contact-band > .container > p { color: var(--muted-foreground); max-width: 40rem; margin: 0 auto 1.75rem; line-height: 1.9; }
.wwu-contact-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; justify-content: center; }
.wwu-contact-hours { font-size: 0.955rem; color: var(--muted-foreground); margin-top: 1.25rem; }

/* ---------- تماس با ما (contact) ----------
   The ways to reach us ARE the page: the methods sit full-width directly
   under the hero, with the phone card given the strongest treatment because
   one tap to a person beats any form. The message form follows in a tinted
   band below, deliberately quieter — it is the out-of-hours fallback, not
   the headline. */

.ct-hero { padding-block: 3rem 1.25rem; text-align: center; }
.ct-hero-sub { color: var(--muted-foreground); font-size: 1.18rem; max-width: 40rem; margin: 1.25rem auto 0; line-height: 1.9; }

.ct-methods-wrap { padding-block: 1.5rem 1rem; }
/* auto-fit, not a fixed column count: how many methods render depends on how
   many of them have real values in polyabzar_contact_info(). With the email
   still unset that is three, and a hard repeat(4) would leave a dead cell. */
.ct-methods { display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media (min-width: 700px) { .ct-methods { grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); } }

.ct-method {
  display: flex; flex-direction: column; align-items: flex-start;
  background: var(--card); border: 1px solid var(--border);
  border-radius: 1rem; padding: 1.75rem 1.5rem;
  transition: box-shadow 0.25s, border-color 0.25s;
}
a.ct-method:hover { border-color: color-mix(in srgb, var(--brand-gold) 55%, transparent); box-shadow: var(--shadow-card-hover); }

.ct-method-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.75rem; height: 2.75rem; border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--brand-gold) 45%, transparent);
  color: var(--brand-gold); margin-bottom: 1.1rem;
}
.ct-method-icon svg { width: 1.25rem; height: 1.25rem; }
.ct-method-label { font-size: 0.88rem; color: var(--muted-foreground); margin-bottom: 0.4rem; }
.ct-method-value { font-size: 1.18rem; font-weight: 600; line-height: 1.7; }
.ct-method-hint { font-size: 0.9rem; color: var(--muted-foreground); line-height: 1.7; margin-top: 0.4rem; }
.ct-method-action {
  display: inline-flex; align-items: center; gap: 0.3rem;
  margin-top: auto; padding-top: 1rem;
  font-size: 0.955rem; font-weight: 600; color: var(--brand-bronze-text);
}
.ct-method-action svg { width: 0.95rem; height: 0.95rem; transition: transform 0.2s; }
/* The chevron points at the physical start edge, so in RTL it must travel
   that way on hover too — a plain positive translateX would walk it the
   wrong direction. */
a.ct-method:hover .ct-method-action svg { transform: translateX(-0.2rem); }

/* The phone gets ink-on-card inversion rather than merely a thicker border:
   at a glance it has to read as "do this one". */
.ct-method--primary { background: var(--primary); border-color: var(--primary); color: var(--primary-foreground); }
.ct-method--primary .ct-method-icon { border-color: color-mix(in srgb, var(--primary-foreground) 35%, transparent); color: var(--brand-gold); }
.ct-method--primary .ct-method-label,
.ct-method--primary .ct-method-hint { color: color-mix(in srgb, var(--primary-foreground) 72%, transparent); }
.ct-method--primary .ct-method-value { font-size: 1.35rem; }
.ct-method--primary .ct-method-action { color: var(--brand-gold); }
a.ct-method--primary:hover { border-color: var(--brand-gold); }

.ct-b2b-line { text-align: center; color: var(--muted-foreground); font-size: 1.035rem; margin-top: 2rem; }
.ct-b2b-line a { color: var(--brand-bronze-text); font-weight: 600; text-decoration: underline; text-underline-offset: 0.25em; }

/* Form band — tinted so it reads as a secondary zone rather than competing
   with the methods above. */
.ct-message-band { background: color-mix(in srgb, var(--muted) 40%, var(--background)); padding-block: 4rem; margin-top: 2.5rem; }
.ct-message-inner { max-width: 42rem; margin-inline: auto; }
.ct-form-title { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.575rem, 3.375vw, 2.025rem); margin: 0 0 0.5rem; text-align: center; }
.ct-form-sub { text-align: center; color: var(--muted-foreground); margin: 0 0 2rem; line-height: 1.8; }

.ct-notice { border: 1px solid; border-radius: 0.6rem; padding: 0.9rem 1.1rem; margin-bottom: 1.6rem; font-size: 1.035rem; line-height: 1.7; }
.ct-notice--success { border-color: color-mix(in srgb, var(--brand-gold) 55%, transparent); background: var(--accent); color: var(--foreground); }
.ct-notice--error { border-color: var(--sale); background: color-mix(in srgb, var(--sale) 8%, var(--card)); color: var(--sale); }

.ct-grid { display: grid; grid-template-columns: 1fr; gap: 0 1.25rem; }
@media (min-width: 640px) { .ct-grid { grid-template-columns: 1fr 1fr; } }

/* Honeypot: off-screen rather than display:none, which the cruder bots skip. */
.ct-hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.ct-submit { width: 100%; justify-content: center; margin-top: 0.5rem; border: 0; font-family: inherit; cursor: pointer; }
.ct-form-foot { text-align: center; margin-top: 1.1rem; }


/* ---------- Policy pages (شرایط ارسال / رویه بازگشت کالا / قوانین و مقررات) ----------
   One shared layout via template-parts/policy-page.php. Long-form legal text,
   so the measure is capped and the leading is looser than the rest of the
   site — these are read in paragraphs, not scanned like a product card. */

.policy-hero { padding-block: 3rem 1.25rem; text-align: center; }
.policy-intro { color: var(--muted-foreground); font-size: 1.15rem; max-width: 40rem; margin: 1.25rem auto 0; line-height: 1.9; }

.policy-wrap { max-width: 48rem; padding-block: 1.5rem 4rem; }

/* Admin-only completeness warning. Loud on purpose: an unfinished policy page
   that looks finished is the failure mode worth preventing. */
.policy-admin-notice {
  border: 1px solid var(--sale);
  background: color-mix(in srgb, var(--sale) 6%, var(--card));
  border-radius: 0.75rem; padding: 1.15rem 1.35rem; margin-bottom: 2.5rem;
}
.policy-admin-notice strong { color: var(--sale); display: block; margin-bottom: 0.5rem; }
.policy-admin-notice p { font-size: 0.99rem; line-height: 1.8; margin: 0 0 0.5rem; }
.policy-admin-notice ul { margin: 0 0 0.75rem; padding-inline-start: 1.2rem; font-size: 0.99rem; line-height: 1.9; }
.policy-admin-notice code { background: var(--muted); padding: 0.1rem 0.35rem; border-radius: 0.25rem; font-size: 0.85em; }
.policy-admin-note { color: var(--muted-foreground); font-size: 0.9rem !important; margin: 0 !important; }

/* Unfilled value inside body copy — visible so an incomplete sentence reads
   as incomplete rather than as a finished, wrong statement. */
.policy-gap {
  background: color-mix(in srgb, var(--sale) 12%, transparent);
  color: var(--sale); border-radius: 0.25rem;
  padding: 0.05rem 0.4rem; font-size: 0.9em; font-weight: 600; white-space: nowrap;
}

.policy-toc {
  background: color-mix(in srgb, var(--muted) 45%, var(--background));
  border: 1px solid var(--border); border-radius: 0.85rem;
  padding: 1.35rem 1.5rem; margin-bottom: 2.5rem;
}
.policy-toc h2 { font-family: var(--font-display); font-size: 1.18rem; margin: 0 0 0.75rem; }
.policy-toc ol { margin: 0; padding-inline-start: 1.2rem; }
.policy-toc li { font-size: 1.015rem; line-height: 2; }
.policy-toc a { color: var(--foreground); }
.policy-toc a:hover { color: var(--brand-bronze-text); text-decoration: underline; text-underline-offset: 0.25em; }

/* .entry-content rides along on every one of these rather than getting a
   second long-form stylesheet of its own. The policy pages already solved
   "a column of Persian prose at a readable measure"; blog posts and plain WP
   pages have exactly the same problem, and two sets of rules for one job
   drift apart. Note h2 gains the rule-under-heading treatment for free. */
.policy-section { margin-bottom: 2.5rem; scroll-margin-top: 6rem; }
.policy-section h2, .entry-content h2 {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.405rem, 2.815vw, 1.69rem); margin: 0 0 0.85rem;
  padding-bottom: 0.6rem; border-bottom: 1px solid var(--border);
}
.policy-section p, .entry-content p { line-height: 2; margin: 0 0 1rem; }
.policy-section ul, .policy-section ol,
.entry-content ul, .entry-content ol { margin: 0 0 1rem; padding-inline-start: 1.35rem; }
.policy-section li, .entry-content li { line-height: 2; margin-bottom: 0.4rem; }
.policy-section a, .entry-content a { color: var(--brand-bronze-text); font-weight: 600; text-decoration: underline; text-underline-offset: 0.25em; }
.policy-section strong, .entry-content strong { font-weight: 600; }

/* h2 above already has its own margin; these are the levels the editor can
   also produce, plus the block elements the classic/block editor emits. */
.entry-content h3 { font-family: var(--font-display); font-weight: 700; font-size: 1.29rem; margin: 2rem 0 0.6rem; }
.entry-content h4 { font-family: var(--font-display); font-weight: 700; font-size: 1.13rem; margin: 1.75rem 0 0.5rem; }
.entry-content h2:not(:first-child) { margin-top: 2.5rem; }
.entry-content img { max-width: 100%; height: auto; border-radius: 0.5rem; }
.entry-content figure { margin: 0 0 1.5rem; }
.entry-content figcaption { font-size: 0.955rem; color: var(--muted-foreground); margin-top: 0.5rem; text-align: center; }
.entry-content blockquote {
  margin: 0 0 1.5rem; padding-inline-start: 1.1rem;
  border-inline-start: 3px solid var(--brand-gold); color: var(--muted-foreground);
}
/* Long code/pre must scroll inside itself rather than widening the page —
   under RTL an overflowing block pushes the whole column off-screen. */
.entry-content pre { overflow-x: auto; background: var(--muted); padding: 1rem; border-radius: 0.5rem; direction: ltr; text-align: left; }
.entry-content table { width: 100%; border-collapse: collapse; margin-bottom: 1.5rem; display: block; overflow-x: auto; }
.entry-content th, .entry-content td { border: 1px solid var(--border); padding: 0.6rem 0.8rem; }

.policy-updated { font-size: 0.955rem; color: var(--muted-foreground); border-top: 1px solid var(--border); padding-top: 1.25rem; }
.policy-help { text-align: center; color: var(--muted-foreground); font-size: 1.035rem; margin-top: 2.5rem; }
.policy-help a { color: var(--brand-bronze-text); font-weight: 600; text-decoration: underline; text-underline-offset: 0.25em; }

/* ---------- درباره ما (about) ----------
   Not a policy page: it gets its own layout rather than the capped-measure
   long-form one, because it is scanned rather than read. */

.about-hero { padding-block: 3rem 1.5rem; text-align: center; }
.about-lead { color: var(--muted-foreground); font-size: 1.18rem; max-width: 44rem; margin: 1.25rem auto 0; line-height: 1.9; }
.about-meta { font-size: 0.99rem; color: var(--muted-foreground); margin-top: 0.75rem; text-align: center; }
.about-section-sub { text-align: center; color: var(--muted-foreground); max-width: 40rem; margin: 1rem auto 2rem; line-height: 1.9; }

.about-cats { list-style: none; padding: 0; margin: 0 auto 2rem; display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: center; }
.about-cats a {
  display: inline-block; border: 1px solid var(--border); border-radius: 9999px;
  padding: 0.55rem 1.25rem; font-size: 1.015rem; transition: 0.2s;
}
.about-cats a:hover { border-color: var(--brand-gold); color: var(--brand-bronze-text); }
.about-cta-line { text-align: center; margin: 0; }

.about-why-band { background: color-mix(in srgb, var(--muted) 40%, var(--background)); padding-block: 4rem; }
.about-why { display: grid; grid-template-columns: 1fr; gap: 1.25rem; margin-top: 2.25rem; }
@media (min-width: 640px) { .about-why { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .about-why { grid-template-columns: repeat(4, 1fr); } }
.about-why-card { background: var(--card); border: 1px solid var(--border); border-radius: 1rem; padding: 1.75rem 1.5rem; }
.about-why-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.75rem; height: 2.75rem; border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--brand-gold) 45%, transparent);
  color: var(--brand-gold); margin-bottom: 1.1rem;
}
.about-why-icon svg { width: 1.25rem; height: 1.25rem; }
.about-why-card h3 { font-family: var(--font-display); font-size: 1.295rem; margin: 0 0 0.5rem; }
.about-why-card p { color: var(--muted-foreground); font-size: 1.015rem; line-height: 1.85; margin: 0; }

.about-work-grid { display: grid; grid-template-columns: 1fr; gap: 1.25rem; margin-top: 2rem; }
@media (min-width: 768px) { .about-work-grid { grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); } }
.about-work-grid article { border: 1px solid var(--border); border-radius: 1rem; padding: 1.6rem 1.5rem; background: var(--card); }
.about-work-grid h3 { font-family: var(--font-display); font-size: 1.35rem; margin: 0 0 0.5rem; }
.about-work-grid p { color: var(--muted-foreground); font-size: 1.015rem; line-height: 1.85; margin: 0 0 0.9rem; }
.about-work-grid a { color: var(--brand-bronze-text); font-weight: 600; font-size: 1.015rem; text-decoration: underline; text-underline-offset: 0.25em; }

/* Sign-up name step (template-parts/phone-otp-form.php, step 3). Two columns
   once there is room; the rest of the step reuses .phone-otp-* above. */
.phone-otp-names { display: grid; grid-template-columns: 1fr; gap: 0 1rem; }
@media (min-width: 560px) { .phone-otp-names { grid-template-columns: 1fr 1fr; } }

/* ---------- Blog (مجله) ----------
   home.php / archive.php / single.php / template-parts/post-card.php.
   The card deliberately mirrors .product-card's shape — whole card is the
   link, media on top, body below — so the two grids read as one system. */

.blog-wrap { padding-block: 1rem 4rem; }

.post-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 2rem;
}
@media (min-width: 640px) { .post-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .post-grid { grid-template-columns: repeat(3, 1fr); } }

.post-card { display: block; }
.post-card article { height: 100%; }
.post-card-media {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 0.5rem;
  background: var(--muted);
}
.post-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.post-card:hover .post-card-media img { transform: scale(1.05); }

.post-card-body { padding-block: 1rem 0.5rem; }
.post-card-eyebrow { font-size: 0.845rem; color: var(--muted-foreground); margin-bottom: 0.25rem; }
.post-card-body h3 {
  font-family: var(--font-display);
  font-size: 1.405rem;
  font-weight: 700;
  line-height: 1.4;
  margin: 0 0 0.5rem;
}
.post-card:hover .post-card-body h3 { color: var(--brand-bronze-text); }
.post-card-excerpt { color: var(--muted-foreground); line-height: 1.85; margin: 0; font-size: 1.015rem; }

/* ---------- Single post ---------- */

.post-meta { text-align: center; color: var(--muted-foreground); font-size: 0.985rem; margin: 0; }
.post-hero-media { margin-bottom: 2.5rem; border-radius: 0.75rem; overflow: hidden; }
.post-hero-media img { width: 100%; height: auto; display: block; }

.post-nav {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}
@media (min-width: 640px) { .post-nav { grid-template-columns: repeat(2, 1fr); } }
.post-nav-link { border: 1px solid var(--border); border-radius: 0.75rem; padding: 1rem 1.25rem; transition: 0.2s; }
.post-nav-link:hover { border-color: var(--brand-gold); }
.post-nav-label { display: block; font-size: 0.9rem; color: var(--muted-foreground); margin-bottom: 0.3rem; }
.post-nav-title { display: block; font-family: var(--font-display); font-weight: 700; font-size: 1.13rem; }

/* ---------- Search results (search.php) ----------
   Non-product hits; product hits reuse .product-grid above. */

.search-results { padding-block: 1rem 4rem; }
.search-other { margin-top: 2rem; }
.search-result { padding-block: 1.25rem; border-bottom: 1px solid var(--border); }
.search-result h2 { font-family: var(--font-display); font-weight: 700; font-size: 1.29rem; margin: 0 0 0.4rem; }
.search-result a:hover { color: var(--brand-bronze-text); }
.search-result p { color: var(--muted-foreground); line-height: 1.85; margin: 0; }

/* ---------- 404 ----------
   .header-search is display:none by default because in the header it is a
   drawer the search icon toggles. On the 404 page it is always visible, so
   the modifier re-shows it and drops the header's divider. */
.header-search.is-static { display: block; border-top: 0; padding-block: 0 2rem; }
.error-404-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; justify-content: center; padding-bottom: 3rem; }
