/* ==========================================================================
   fiverbox — site design system "Cinematic"
   Near-black stage · warm white type · gold accent · glass · soft rounded shapes.
   One font everywhere: Cairo. RTL (Arabic) + LTR (English) through logical properties.
   Every page uses these classes (see MIGRATION.md). The home page adds /css/home.css.
   Legacy variable names (--brand, --ink, --surface …) are kept as aliases so older
   page-level styles pick up the dark theme automatically.
   ========================================================================== */

/* ---------- tokens ---------- */
:root {
  --bg: #0a0a0a;
  --bg-2: #111111;
  --surface: #141312;
  --surface-2: #1b1917;
  --surface-3: #24211e;
  --line: rgba(255, 244, 225, .09);
  --line-2: rgba(255, 244, 225, .16);
  --text: #f6efe3;
  --text-2: #d8cfc1;
  --muted: #a69d8f;
  --gold: #f5c518;
  --gold-2: #ffd84d;
  --gold-3: #e9a800;
  --amber: #ff9f1c;
  --on-gold: #14110a;
  --success: #4ade80;
  --danger: #f87171;
  --warning: #fbbf24;
  --info: #38bdf8;

  /* legacy aliases (older page styles use these names) */
  --brand: var(--gold);
  --brand-2: var(--amber);
  --brand-ink: var(--gold-2);
  --accent: var(--amber);
  --ink: var(--text);
  --ink-2: var(--text-2);
  --grad: linear-gradient(135deg, #ffe27a 0%, var(--gold) 45%, var(--gold-3) 100%);
  --grad-soft: linear-gradient(135deg, rgba(245, 197, 24, .12), rgba(255, 159, 28, .04));

  --r-sm: .75rem;
  --r: 1.125rem;
  --r-lg: 1.375rem;
  --r-xl: 1.75rem;
  --pill: 999px;
  --radius: var(--r);
  --shadow-1: inset 0 1px 0 rgba(255, 244, 225, .04), 0 .75rem 2rem -1.25rem rgba(0, 0, 0, .9);
  --shadow-2: 0 1.5rem 3rem -1rem rgba(0, 0, 0, .85);
  --shadow-3: 0 1.4rem 3.2rem -1rem rgba(245, 197, 24, .28);

  --ease: cubic-bezier(.25, .8, .25, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);

  --gut: clamp(1rem, 4vw, 4rem);
  --maxw: 100rem;
  --container: 82rem;
  --hh: 4rem;
  --header-h: var(--hh);
  --font: "Cairo", system-ui, -apple-system, "Segoe UI", Tahoma, Arial, sans-serif;

  /* direction tokens (LTR) */
  --os: left;
  --oe: right;
  --to-s: 270deg;
  --to-e: 90deg;
  --tilt: -7deg;
  color-scheme: dark;
}
:root[dir="rtl"] { --os: right; --oe: left; --to-s: 90deg; --to-e: 270deg; --tilt: 7deg; }
@media (min-width: 768px) { :root { --hh: 4.5rem; } }
/* QHD / 4K: everything is in rem, so the whole layout scales up proportionally */
@media (min-width: 1921px) { html { font-size: clamp(16px, .8334vw, 28px); } }

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--bg);
  overflow-x: clip;
  scroll-padding-top: calc(var(--hh) + 1rem);
  scrollbar-color: #3a352e var(--bg);
}
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
/* cross-document view transitions on every page: both pages of a navigation must opt in, otherwise Chrome
   aborts the transition with "InvalidStateError: … opt-in disabled" (it was on the browse pages only) */
@media (prefers-reduced-motion: no-preference) { @view-transition { navigation: auto; } }
html.menu-open, html.lock { overflow: hidden; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex; flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem/1.75 var(--font);
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
@supports not (overflow: clip) { html, body { overflow-x: hidden; } }
main { flex: 1; position: relative; overflow-x: clip; padding-top: calc(var(--hh) + env(safe-area-inset-top)); }
/* pages that open with a banner / hero let it run under the transparent header */
main:has(> .page-head), main:has(> .hero), .page-home main { padding-top: 0; }
img { max-width: 100%; height: auto; display: block; }
/* <picture> (WebP copy + JPEG, see WebPTagHelper) lays out as if the <img> were there on its own */
picture { display: contents; }
a { color: var(--gold-2); text-decoration: none; transition: color .25s; }
a:hover { color: var(--gold); }
h1, h2, h3, h4 { margin: 0 0 .5em; font-weight: 800; line-height: 1.35; color: var(--text); }
h1 { font-size: clamp(1.9rem, 1.3rem + 2.6vw, 3.2rem); font-weight: 900; }
h2 { font-size: clamp(1.45rem, 1.1rem + 1.6vw, 2.25rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
hr { border: 0; border-top: 1px solid var(--line); margin: 1.25rem 0; }
::selection { background: var(--gold); color: var(--on-gold); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
[hidden] { display: none !important; }
.ti { line-height: 1; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: fixed; z-index: 300; top: -5rem; inset-inline-start: 1rem; padding: .75rem 1.15rem; border-radius: var(--pill); background: var(--gold); color: var(--on-gold); font-weight: 700; transition: top .3s var(--ease); }
.skip:focus { top: calc(1rem + env(safe-area-inset-top)); color: var(--on-gold); }
[dir="rtl"] .fwd, [dir="rtl"] .flip-rtl { transform: scaleX(-1); }

/* film grain over everything (very subtle) */
.grain { position: fixed; inset: 0; z-index: 90; pointer-events: none; overflow: hidden; opacity: .05; }
.grain::before {
  content: ""; position: absolute; inset: -8rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .75 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 15rem 15rem;
}
@media (prefers-reduced-motion: no-preference) and (min-width: 1024px) and (hover: hover) { .grain::before { animation: grain .9s steps(1) infinite; } }

/* ---------- layout ---------- */
.wrap { width: min(100% - 2 * var(--gut), var(--maxw)); margin-inline: auto; }
.container { width: min(100% - 2 * clamp(1rem, 3vw, 2.5rem), var(--container)); margin-inline: auto; }
.section { padding-block: clamp(2.25rem, 5vw, 4.5rem); }
.section-sm { padding-block: clamp(1.25rem, 3vw, 2rem); }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.grid { display: grid; gap: clamp(14px, 1.6vw, 22px); }
.grid > * { min-width: 0; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.split { display: grid; gap: clamp(18px, 2.5vw, 32px); grid-template-columns: minmax(0, 1fr) minmax(18rem, 22rem); align-items: start; }
.split > * { min-width: 0; }
.split > aside { position: sticky; top: calc(var(--hh) + 1rem); }
@media (max-width: 1000px) { .split { grid-template-columns: minmax(0, 1fr); } .split > aside { position: static; } .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: minmax(0, 1fr); } }

.center { text-align: center; } .start { text-align: start; } .end { text-align: end; }
.muted { color: var(--muted); } .small { font-size: .875rem; } .big { font-size: 1.15rem; }
.gold-text { color: var(--gold); }
.mt-0 { margin-top: 0 } .mt-1 { margin-top: 8px } .mt-2 { margin-top: 16px } .mt-3 { margin-top: 24px } .mt-4 { margin-top: 40px }
.mb-0 { margin-bottom: 0 } .mb-1 { margin-bottom: 8px } .mb-2 { margin-bottom: 16px } .mb-3 { margin-bottom: 24px } .mb-4 { margin-bottom: 40px }
.w-100 { width: 100%; } .nowrap { white-space: nowrap; } .ltr { direction: ltr; unicode-bidi: isolate; } .rtl { direction: rtl; }
.hidden { display: none !important; }
@media (max-width: 720px) { .hide-sm { display: none !important; } }
@media (min-width: 721px) { .show-sm { display: none !important; } }
@media (max-width: 1179.98px) { .xl-only { display: none !important; } }
@media (max-width: 639.98px) { .sm-up { display: none !important; } }

/* ==========================================================================
   Header
   ========================================================================== */
.hd {
  position: fixed; top: 0; inset-inline: 0; z-index: 60; isolation: isolate;
  padding-top: env(safe-area-inset-top);
  padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right);
  background: linear-gradient(to bottom, rgba(5, 5, 5, .72), rgba(5, 5, 5, 0));
}
.hd::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: rgba(10, 10, 10, .82);
  -webkit-backdrop-filter: blur(18px) saturate(150%); backdrop-filter: blur(18px) saturate(150%);
  opacity: 0; transition: opacity .45s var(--ease);
}
.hd::after {
  content: ""; position: absolute; inset-inline: 0; bottom: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(245, 197, 24, .45) 30%, rgba(245, 197, 24, .45) 70%, transparent);
  opacity: 0; transition: opacity .45s var(--ease);
}
.hd.scrolled::before, .hd.scrolled::after, .hd.search-open::before { opacity: 1; }
.hd-in { display: flex; align-items: center; gap: .5rem; height: var(--hh); }

.logo { display: inline-flex; align-items: center; gap: .55rem; min-height: 2.75rem; flex-shrink: 0; color: var(--text); }
.logo:hover { color: var(--text); }
/* the original fiverbox mark (the "5" sphere), recoloured to the site's gold with a dark "5" — /img/brand/logo-*.png */
.logo-mark { width: 2.5rem; height: 2.5rem; flex-shrink: 0; object-fit: contain; filter: drop-shadow(0 0 .65rem rgba(245, 197, 24, .32)); transition: transform .9s var(--ease-out), filter .6s; }
.logo:hover .logo-mark { transform: translateY(-2px) rotate(-6deg) scale(1.06); filter: drop-shadow(0 0 1rem rgba(245, 197, 24, .55)); }
.logo-word { font: 800 clamp(1.25rem, 1.1rem + .5vw, 1.5rem)/1 var(--font); letter-spacing: -.01em; color: var(--text); }
.logo-word b { font-weight: 800; color: var(--gold); }

.hd-nav { display: none; }
.hd-nav a {
  position: relative; display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0 .85rem;
  border-radius: var(--pill); font-size: .95rem; font-weight: 600; color: var(--text-2); white-space: nowrap; transition: color .3s;
}
.hd-nav a::after {
  content: ""; position: absolute; inset-inline: .85rem; bottom: .45rem; height: 2px; border-radius: 2px;
  background: var(--gold); transform: scaleX(0); transform-origin: var(--os) center; transition: transform .5s var(--ease-out);
}
.hd-nav a:hover, .hd-nav a[aria-current="page"] { color: var(--text); }
.hd-nav a:hover::after, .hd-nav a[aria-current="page"]::after { transform: scaleX(1); }
/* the language link + country flag: last in the main menu, set a little apart by a thin divider */
.hd-nav { align-items: center; }
.hd-nav .nav-lang { margin-inline-start: 1rem; padding-inline-end: .4rem; color: var(--gold-2); }
.hd-nav .nav-lang::before {
  content: ""; position: absolute; inset-inline-start: -.55rem; top: 50%; width: 1px; height: 1.1rem; translate: 0 -50%;
  background: var(--line-2);
}
.hd-nav .nav-lang::after { inset-inline-end: .4rem; }
.hd-nav .nav-lang:hover { color: var(--gold); }
.hd-act .hd-lang + .hd-country { margin-inline-start: -.3rem; } /* flag right next to "عربي" / "EN" */
@media (max-width: 639.98px) { /* phones: language + flag fit beside search, add and menu */
  .hd-act { gap: .15rem; }
  .hd-act .hd-lang { width: auto; padding-inline: .4rem; }
  .hd-act .hd-country { width: 2.1rem; }
  .hd-act .hd-lang + .hd-country { margin-inline-start: -.2rem; }
}
@media (max-width: 359.98px) { /* very small phones: "add your service" stays in the menu; slimmer icon buttons */
  .hd-act .hd-cta { display: none; }
  .hd-act .ib { width: 2.4rem; }
}
.hd-act { display: flex; align-items: center; gap: .375rem; margin-inline-start: auto; }
.hd-login {
  display: inline-flex; align-items: center; gap: .45rem; min-height: 2.75rem; padding: 0 .9rem; border-radius: var(--pill);
  border: 0; background: none; font-size: .92rem; font-weight: 600; color: var(--text-2); white-space: nowrap; transition: color .3s, background-color .3s;
}
.hd-login .ti { font-size: 1.3rem; }
.hd-login:hover { color: var(--gold-2); background: rgba(255, 255, 255, .05); }
.hd-cta { --bh: 2.75rem; padding: 0 1.1rem; font-size: .92rem; }
@media (max-width: 639.98px) { .hd-cta { width: 2.75rem; padding: 0; } .hd-cta span { display: none; } }
@media (max-width: 359.98px) { .hd-cta { display: none; } }
.lang { font: 700 .9rem/1 var(--font); }
.lang:lang(ar) { font-size: .78rem; } /* "عربي" on English pages */
.country .flag { width: 1.5rem; height: 1.5rem; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1px rgba(255, 255, 255, .22); transition: opacity .3s; }
.country.detecting .flag, .country.detecting > .ti { opacity: .35; }
.ib.country.detecting::after {
  content: ""; position: absolute; inset: .3rem; border-radius: 50%;
  border: 2px solid rgba(245, 197, 24, .2); border-top-color: var(--gold); animation: spin .8s linear infinite;
}
.burger span {
  position: absolute; left: 50%; top: 50%; width: 1.3rem; height: 2px; margin: -1px 0 0 -.65rem; border-radius: 2px;
  background: currentColor; transition: transform .45s var(--spring);
}
.burger span:first-of-type { transform: translate3d(0, -.3rem, 0); }
.burger span:last-of-type { transform: translate3d(0, .3rem, 0) scaleX(.65); transform-origin: var(--oe) center; }
.burger:hover span:last-of-type { transform: translate3d(0, .3rem, 0) scaleX(1); }
@media (min-width: 1180px) {
  .hd-nav { display: flex; gap: .125rem; margin-inline: auto; }
  .hd-act { margin-inline-start: 0; }
  .hd-act .burger { display: none; }
  .hd-act .hd-lang, .hd-act .hd-country { display: none; } /* shown in the main menu instead */
}

/* header search: drop-down panel under the bar, inline pill on wide screens */
.hd-search {
  position: absolute; top: 100%; inset-inline: 0; padding: .5rem var(--gut) 1rem;
  background: rgba(10, 10, 10, .95); border-bottom: 1px solid var(--line);
  opacity: 0; visibility: hidden; transform: translate3d(0, -.5rem, 0);
  transition: opacity .3s var(--ease), transform .45s var(--ease-out), visibility 0s linear .45s;
}
.hd.search-open .hd-search { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.hs-pill {
  position: relative; display: flex; align-items: center; gap: .5rem; max-width: 46rem; margin-inline: auto; padding-inline: 1rem 0;
  border-radius: var(--pill); background: rgba(255, 255, 255, .06); border: 1px solid var(--line-2); transition: border-color .3s, box-shadow .3s;
}
.hs-pill:focus-within { border-color: rgba(245, 197, 24, .6); box-shadow: 0 0 0 .25rem rgba(245, 197, 24, .14); }
.hs-pill > .ti { color: var(--muted); font-size: 1.1rem; }
.hs-pill input { flex: 1; min-width: 0; height: 2.75rem; background: none; border: 0; outline: none; color: var(--text); font-size: 1rem; text-overflow: ellipsis; }
.hs-go { display: inline-grid; place-items: center; width: 2.75rem; height: 2.75rem; flex-shrink: 0; border: 0; border-radius: 50%; background: var(--gold); color: var(--on-gold); font-size: 1.05rem; transition: transform .45s var(--spring); }
.hs-go:hover { transform: scale(1.08); }
@media (min-width: 1536px) {
  .hd-search { position: static; padding: 0; background: none; border: 0; opacity: 1; visibility: visible; transform: none; transition: none; }
  .hs-pill { width: 15rem; }
  .hd-act .search-btn { display: none; }
  /* the header pill is narrow here: its suggestions open wider, centred under it, so titles can be read */
  .hd-search .suggest { inset-inline: auto; left: 50%; width: min(38rem, calc(100vw - 2rem)); translate: -50% 0; }
}
input[type="search"] { -webkit-appearance: none; appearance: none; }
input[type="search"]::-webkit-search-decoration, input[type="search"]::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }
input::placeholder, textarea::placeholder { color: #8f877a; opacity: 1; }

/* live search suggestions (header, menu, hero) */
.suggest {
  position: absolute; z-index: 70; top: calc(100% + .5rem); inset-inline: 0; margin: 0; padding: .45rem; list-style: none;
  max-height: min(34rem, 72vh); overflow-y: auto; overscroll-behavior: contain;
  scrollbar-width: thin; scrollbar-color: rgba(245, 197, 24, .35) transparent;
  border-radius: var(--r-lg); border: 1px solid var(--line-2); background: rgba(18, 17, 16, .9);
  -webkit-backdrop-filter: blur(1.25rem) saturate(1.4); backdrop-filter: blur(1.25rem) saturate(1.4);
  box-shadow: 0 2rem 4rem -1rem rgba(0, 0, 0, .9), 0 0 3rem -1.5rem rgba(245, 197, 24, .35), inset 0 1px 0 rgba(255, 255, 255, .06);
  animation: pop-in .3s var(--ease-out); text-align: start;
}
.suggest [role="option"] {
  position: relative; display: flex; align-items: center; gap: .85rem; min-height: 3.4rem; padding: .45rem .8rem; border-radius: var(--r-sm);
  color: var(--text); font-size: .92rem; line-height: 1.35; cursor: pointer; transition: background-color .25s;
  animation: sg-in .5s var(--ease-out) both; animation-delay: calc(var(--i, 0) * 40ms); /* rows arrive one after another */
}
/* gold bar on the start edge of the hovered / selected row */
.suggest [role="option"]::before {
  content: ""; position: absolute; inset-block: .75rem; inset-inline-start: .2rem; width: 3px; border-radius: 3px;
  background: var(--gold); box-shadow: 0 0 .6rem var(--gold); transform: scaleY(0); transition: transform .35s var(--spring);
}
/* titles: up to two lines instead of one cut-off line */
.suggest [role="option"] > span:not(.s-ico) {
  flex: 1; min-width: 0; overflow: hidden; overflow-wrap: anywhere;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2;
  transition: transform .35s var(--ease-out), color .25s;
}
.suggest mark { background: none; color: var(--gold); font-weight: 700; }
.suggest [role="option"] img {
  width: 3rem; height: 3rem; flex: none; border-radius: .7rem; object-fit: cover; background: var(--surface-2);
  outline: 1px solid var(--line); outline-offset: -1px; transition: transform .45s var(--spring), outline-color .3s;
}
.suggest .s-ico { display: grid; place-items: center; width: 2.2rem; height: 2.2rem; flex: none; margin-inline: .4rem; border-radius: 50%; background: rgba(245, 197, 24, .14); color: var(--gold); transition: transform .45s var(--spring); }
.suggest .s-go { flex: none; color: var(--gold); font-size: 1.15rem; opacity: 0; transform: translate3d(-.5rem, 0, 0); transition: opacity .25s, transform .35s var(--ease-out); }
[dir="rtl"] .suggest .s-go { transform: translate3d(.5rem, 0, 0); }
.suggest [id$="-all"]:not(:first-child) { margin-top: .35rem; border-top: 1px solid var(--line); border-radius: 0 0 var(--r-sm) var(--r-sm); }
.suggest [role="option"]:hover, .suggest [role="option"][aria-selected="true"] { background: linear-gradient(90deg, rgba(245, 197, 24, .15), rgba(245, 197, 24, .03)); }
[dir="rtl"] .suggest [role="option"]:hover, [dir="rtl"] .suggest [role="option"][aria-selected="true"] { background: linear-gradient(270deg, rgba(245, 197, 24, .15), rgba(245, 197, 24, .03)); }
.suggest [role="option"]:is(:hover, [aria-selected="true"])::before { transform: scaleY(1); }
.suggest [role="option"]:is(:hover, [aria-selected="true"]) > span:not(.s-ico) { color: #fff; transform: translate3d(.25rem, 0, 0); }
[dir="rtl"] .suggest [role="option"]:is(:hover, [aria-selected="true"]) > span:not(.s-ico) { transform: translate3d(-.25rem, 0, 0); }
.suggest [role="option"]:is(:hover, [aria-selected="true"]) img { transform: scale(1.07) rotate(-2deg); outline-color: rgba(245, 197, 24, .7); }
.suggest [role="option"]:is(:hover, [aria-selected="true"]) .s-ico { transform: scale(1.12) rotate(-8deg); }
.suggest [role="option"]:is(:hover, [aria-selected="true"]) .s-go { opacity: 1; transform: none; }
@keyframes sg-in { from { opacity: 0; transform: translate3d(0, .6rem, 0); } }

/* user menu (signed in) */
.ud { position: relative; }
.ud > summary { list-style: none; }
.ud > summary::-webkit-details-marker { display: none; }
.ud-chip {
  display: flex; align-items: center; gap: .55rem; min-height: 2.75rem; padding: .2rem; padding-inline-end: .7rem;
  border-radius: var(--pill); border: 1px solid var(--line-2); background: rgba(255, 255, 255, .04); cursor: pointer; transition: border-color .3s;
}
.ud-chip:hover, .ud[open] .ud-chip { border-color: rgba(245, 197, 24, .55); }
.ud-chip img { width: 2.1rem; height: 2.1rem; border-radius: 50%; object-fit: cover; }
.ud-txt { display: none; flex-direction: column; line-height: 1.25; max-width: 9rem; }
.ud-name { font-size: .85rem; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ud-bal { font-weight: 800; font-size: .85rem; color: var(--gold); text-align: start; font-variant-numeric: tabular-nums; }
@media (min-width: 1440px) { .ud-txt { display: flex; } }
.ud-chev { font-size: .9rem; color: var(--muted); transition: transform .3s var(--ease); }
.ud[open] .ud-chev { transform: rotate(180deg); }
.ud-menu {
  position: absolute; top: calc(100% + .6rem); inset-inline-end: 0; width: 16rem; display: grid; gap: .125rem; padding: .5rem;
  border-radius: var(--r); background: rgba(18, 17, 16, .98); border: 1px solid var(--line-2);
  box-shadow: 0 1.5rem 3rem -1rem rgba(0, 0, 0, .85); transform-origin: top var(--oe); animation: pop-in .35s var(--ease-out);
}
.ud-menu a, .ud-menu button {
  display: flex; align-items: center; gap: .6rem; width: 100%; min-height: 2.75rem; padding: 0 .8rem; border: 0; background: none;
  border-radius: var(--r-sm); font-size: .9rem; color: var(--text-2); text-align: start;
}
.ud-menu a:hover, .ud-menu button:hover { background: rgba(255, 255, 255, .06); color: var(--text); }
.ud-menu .ti { color: var(--gold); font-size: 1.1rem; }
.ud-menu em, .macc-row em {
  display: inline-grid; place-items: center; min-width: 1.4rem; height: 1.4rem; margin-inline-start: auto; padding: 0 .4rem;
  border-radius: var(--pill); background: var(--gold); color: var(--on-gold); font-size: .72rem; font-weight: 800; font-style: normal;
}
.ud-menu .ud-balrow { justify-content: space-between; margin-bottom: .25rem; background: rgba(245, 197, 24, .08); }
.ud-balrow small { color: var(--muted); font-size: .8rem; }
.ud-balrow b { font-size: 1.15rem; font-weight: 800; color: var(--gold); font-variant-numeric: tabular-nums; }
.ud-menu hr { margin: .3rem 0; }

/* ---------- full-screen mobile menu ---------- */
.menu {
  position: fixed; inset: 0; z-index: 80; display: flex; flex-direction: column; overflow-y: auto; overscroll-behavior: contain;
  background: #080808; padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
  opacity: 0; visibility: hidden; transition: opacity .45s var(--ease), visibility 0s linear .45s;
}
.menu.open { opacity: 1; visibility: visible; transition-delay: 0s; }
@media (min-width: 1180px) { .menu { display: none; } }
.menu-glow { position: fixed; inset: 0; pointer-events: none; background: radial-gradient(60% 40% at 85% 0%, rgba(245, 197, 24, .17), transparent 70%), radial-gradient(55% 35% at 0% 100%, rgba(255, 159, 28, .11), transparent 70%); }
.menu-top { position: relative; display: flex; align-items: center; justify-content: space-between; min-height: var(--hh); flex-shrink: 0; }
.menu-body { position: relative; flex: 1; display: flex; flex-direction: column; gap: 1.5rem; padding-block: .5rem 1.75rem; }
.menu-search {
  position: relative; display: flex; align-items: center; gap: .5rem; padding-inline: 1rem .3rem; min-height: 3.4rem; border-radius: var(--pill);
  background: rgba(255, 255, 255, .05); border: 1px solid var(--line-2); transition: border-color .3s, box-shadow .3s;
}
.menu-search:focus-within { border-color: rgba(245, 197, 24, .6); box-shadow: 0 0 0 .25rem rgba(245, 197, 24, .14); }
.menu-search > .ti { color: var(--muted); font-size: 1.15rem; }
.menu-search input { flex: 1; min-width: 0; height: 3rem; background: none; border: 0; outline: none; font-size: 1rem; color: var(--text); }
.menu-search .btn { --bh: 2.75rem; padding: 0 1.1rem; }
.menu-links { display: flex; flex-direction: column; }
.menu-links a {
  display: flex; align-items: baseline; gap: 1rem; padding-block: .35rem; border-bottom: 1px solid var(--line); color: var(--text);
  font: 800 clamp(1.6rem, min(8vw, 6vh), 2.6rem)/1.5 var(--font); transition: color .3s;
}
.menu-links a:hover, .menu-links a[aria-current="page"] { color: var(--gold); }
.menu-links em { min-width: 1.9rem; font: 700 .85rem/1 var(--font); font-style: normal; letter-spacing: .08em; color: var(--gold); }
.menu-links .mk { display: block; overflow: clip; padding-block: .06em .1em; }
.menu-links .mk > span { display: block; }
.menu-acc { display: grid; gap: .15rem; }
.macc-row {
  display: flex; align-items: center; gap: .75rem; width: 100%; min-height: 3rem; padding: 0 .25rem; border: 0; background: none;
  border-radius: var(--r-sm); color: var(--text-2); font-size: 1rem; text-align: start; transition: color .3s;
}
.macc-row:hover { color: var(--text); }
.macc-row .ti { font-size: 1.3rem; color: var(--gold); }
.macc-row .flag { width: 1.4rem; height: 1.4rem; border-radius: 50%; object-fit: cover; }
.macc-row.detecting > .ti, .macc-row.detecting > .flag { animation: spin 1s linear infinite; }
.macc-user { display: flex; align-items: center; gap: .8rem; margin-bottom: .4rem; padding: .8rem; border-radius: var(--r); background: rgba(255, 255, 255, .04); border: 1px solid var(--line); color: var(--text); }
.macc-user img { width: 2.75rem; height: 2.75rem; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.macc-user > span { display: flex; flex-direction: column; min-width: 0; line-height: 1.45; }
.macc-user b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.macc-user small { color: var(--muted); }
.macc-user small span { color: var(--gold); font-weight: 700; }
.macc-pair { display: flex; flex-wrap: wrap; gap: 0 1.5rem; margin-top: .4rem; padding-top: .4rem; border-top: 1px solid var(--line); }
.macc-pair .macc-row { width: auto; }
.menu-cta { width: 100%; margin-top: auto; }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  --bh: 3rem;
  position: relative; isolation: isolate; display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  min-height: var(--bh); padding: 0 1.35rem; border-radius: var(--pill);
  border: 1px solid var(--line-2); background: rgba(255, 255, 255, .05); color: var(--text);
  font-size: .98rem; font-weight: 700; line-height: 1.2; white-space: nowrap; text-align: center; text-decoration: none; cursor: pointer;
  transition: transform .55s var(--spring), background-color .3s, color .3s, border-color .3s, box-shadow .4s;
}
.btn .ti { font-size: 1.15em; }
.btn:hover { transform: translate3d(0, -2px, 0) scale(1.03); color: var(--gold-2); border-color: rgba(245, 197, 24, .6); background: rgba(245, 197, 24, .07); }
.btn:active { transform: scale(.96); transition-duration: .15s; }
.btn[disabled], .btn.disabled { opacity: .5; pointer-events: none; }
@media (max-width: 419px) { .btn { white-space: normal; } }
/* the main call to action: gold */
.btn-gold, .btn-grad {
  color: var(--on-gold); border-color: transparent;
  background: linear-gradient(135deg, #ffe27a 0%, var(--gold) 45%, var(--gold-3) 100%);
  box-shadow: 0 .7rem 1.8rem -.8rem rgba(245, 197, 24, .75), inset 0 1px 0 rgba(255, 255, 255, .5);
}
.btn-gold::after, .btn-grad::after {
  content: ""; position: absolute; inset: -.5rem; z-index: -1; border-radius: inherit;
  background: radial-gradient(closest-side, rgba(245, 197, 24, .5), transparent); opacity: 0; transition: opacity .45s var(--ease);
}
.btn-gold:hover, .btn-grad:hover { color: var(--on-gold); border-color: transparent; background: linear-gradient(135deg, #ffe27a 0%, var(--gold) 45%, var(--gold-3) 100%); }
.btn-gold:hover::after, .btn-grad:hover::after { opacity: 1; }
.btn-ghost, .btn-light { background: rgba(255, 255, 255, .04); }
.btn-success { color: #052e16; border-color: transparent; background: linear-gradient(135deg, #86efac, #22c55e); }
.btn-success:hover { color: #052e16; border-color: transparent; background: linear-gradient(135deg, #86efac, #22c55e); box-shadow: 0 .8rem 1.8rem -.8rem rgba(34, 197, 94, .7); }
.btn-danger { color: #fff; border-color: transparent; background: linear-gradient(135deg, #f87171, #dc2626); }
.btn-danger:hover { color: #fff; border-color: transparent; background: linear-gradient(135deg, #f87171, #dc2626); box-shadow: 0 .8rem 1.8rem -.8rem rgba(239, 68, 68, .7); }
.btn-warning { color: #1c1300; border-color: transparent; background: linear-gradient(135deg, #fde68a, #f59e0b); }
.btn-warning:hover { color: #1c1300; border-color: transparent; background: linear-gradient(135deg, #fde68a, #f59e0b); }
.btn-sm { --bh: 2.4rem; padding: 0 1rem; font-size: .86rem; }
.btn-lg { --bh: 3.5rem; padding: 0 1.8rem; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn.loading { pointer-events: none; }
.btn.loading > * { opacity: .45; }
.btn.loading::before {
  content: ""; position: absolute; left: 50%; top: 50%; width: 1.1rem; height: 1.1rem; margin: -.55rem 0 0 -.55rem;
  border: 2px solid currentColor; border-inline-end-color: transparent; border-radius: 50%; animation: spin .7s linear infinite;
}
.link-btn { background: none; border: 0; color: var(--gold-2); cursor: pointer; padding: 0; font-weight: 700; }
.link-btn:hover { color: var(--gold); }

/* round icon buttons */
.ib, .icon-btn {
  position: relative; display: inline-grid; place-items: center; width: 2.75rem; height: 2.75rem; flex-shrink: 0; padding: 0;
  border-radius: 50%; border: 1px solid transparent; background: none; color: var(--text); font-size: 1.25rem; cursor: pointer;
  transition: transform .45s var(--spring), background-color .3s, color .3s, border-color .3s, opacity .3s;
}
.icon-btn { border-color: var(--line-2); background: rgba(255, 255, 255, .03); }
.ib:hover, .icon-btn:hover { background: rgba(255, 255, 255, .07); color: var(--gold-2); transform: scale(1.06); }
.ib:active, .icon-btn:active { transform: scale(.94); }
.ib-ring { border-color: var(--line-2); background: rgba(255, 255, 255, .03); }
.ib-ring:hover, .icon-btn:hover { border-color: rgba(245, 197, 24, .6); }
.ib[aria-disabled="true"] { opacity: .3; cursor: default; transform: none; background: transparent; color: var(--text); }
.cnt, .icon-btn .count {
  position: absolute; top: .1rem; inset-inline-end: 0; min-width: 1.15rem; height: 1.15rem; padding: 0 .3rem; border-radius: var(--pill);
  background: var(--gold); color: var(--on-gold); font: 800 .68rem/1.15rem var(--font); text-align: center; box-shadow: 0 0 0 2px var(--bg);
}
.ib.pulse .cnt { animation: pulse-ring 1.8s ease-out infinite; }
.avatar { width: 2.25rem; height: 2.25rem; border-radius: 50%; object-fit: cover; flex: none; background: var(--surface-2); }
.avatar-lg { width: 5.25rem; height: 5.25rem; box-shadow: 0 0 0 3px rgba(245, 197, 24, .45); }

/* ==========================================================================
   Cards — the service card (one look everywhere) + generic cards
   ========================================================================== */
.card {
  position: relative; isolation: isolate; container-type: inline-size;
  display: flex; flex-direction: column; min-width: 0;
  border-radius: var(--r-lg); background: linear-gradient(180deg, #161413 0%, #100f0e 100%); border: 1px solid var(--line);
  transition: transform .6s var(--spring), border-color .4s;
}
.card::before {
  content: ""; position: absolute; inset: -1px; z-index: -1; border-radius: inherit; pointer-events: none;
  box-shadow: 0 0 0 1px rgba(245, 197, 24, .55), 0 1.4rem 3.2rem -1rem rgba(245, 197, 24, .28), 0 0 3rem -.5rem rgba(245, 197, 24, .16);
  opacity: 0; transition: opacity .45s var(--ease);
}
.card:hover, .card:focus-within { transform: translate3d(0, -.35rem, 0); border-color: rgba(245, 197, 24, .35); }
.card:hover::before, .card:focus-within::before { opacity: 1; }
.card-media {
  position: relative; display: block; overflow: hidden; aspect-ratio: 16 / 10;
  border-radius: calc(var(--r-lg) - 1px) calc(var(--r-lg) - 1px) 0 0; background: #1b1916;
}
.card-media > img, .card-media > picture > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.4s var(--ease-out), filter 1.2s var(--ease); }
.card:hover .card-media > img, .card:hover .card-media > picture > img { transform: scale(1.08); }
.card-media::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(8, 8, 8, .75) 0%, rgba(8, 8, 8, 0) 55%), linear-gradient(to bottom, rgba(8, 8, 8, .4), rgba(8, 8, 8, 0) 35%);
}
.card .sheen { position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(105deg, transparent 35%, rgba(255, 240, 200, .2) 50%, transparent 65%); transform: translate3d(-100%, 0, 0); }
.card:hover .sheen { transform: translate3d(100%, 0, 0); transition: transform 1.1s var(--ease); }
.card .play {
  position: absolute; z-index: 2; left: 50%; top: 50%; display: grid; place-items: center; width: 3.5rem; height: 3.5rem; margin: -1.75rem 0 0 -1.75rem;
  border-radius: 50%; background: rgba(245, 197, 24, .95); color: var(--on-gold); font-size: 1.35rem;
  box-shadow: 0 0 0 .5rem rgba(245, 197, 24, .2), 0 .8rem 2rem rgba(0, 0, 0, .5);
  opacity: 0; transform: scale(.5); pointer-events: none; transition: transform .55s var(--spring), opacity .35s var(--ease);
}
.card:hover .play { opacity: 1; transform: scale(1); }
.card .tag {
  position: absolute; z-index: 2; top: .75rem; inset-inline-start: .75rem; max-width: calc(100% - 4.75rem); padding: .25rem .7rem;
  border-radius: var(--pill); background: rgba(10, 10, 10, .66); border: 1px solid rgba(255, 244, 225, .14); color: var(--text-2);
  font-size: .72rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none;
}
.card .price, .price-tag {
  display: inline-flex; align-items: baseline; gap: .3rem; padding: .3rem .8rem .25rem; border-radius: var(--pill);
  background: rgba(10, 10, 10, .74); border: 1px solid rgba(245, 197, 24, .5); color: var(--gold); font-weight: 800; line-height: 1.1;
}
.card .price { position: absolute; z-index: 2; bottom: .75rem; inset-inline-start: .75rem; pointer-events: none; }
.card .price small { font-size: .7rem; font-weight: 600; color: var(--text-2); }
.card .price b, .price-tag b { font-size: 1.2rem; font-weight: 900; font-variant-numeric: tabular-nums; }
.price-tag { font-size: 1.15rem; }
.card-media .price-tag { position: absolute; z-index: 2; bottom: .75rem; inset-inline-start: .75rem; }
.card .rank {
  position: absolute; z-index: 2; bottom: -.16em; inset-inline-end: .5rem;
  font: 900 clamp(3.6rem, 28cqi, 6rem)/1 var(--font); color: transparent;
  -webkit-text-stroke: 1.5px rgba(245, 197, 24, .95); text-shadow: 0 0 1.5rem rgba(245, 197, 24, .35); pointer-events: none;
}
.card .fav, .fav-btn {
  display: grid; place-items: center; width: 2.75rem; height: 2.75rem; padding: 0; border-radius: 50%; cursor: pointer;
  background: rgba(10, 10, 10, .6); border: 1px solid rgba(255, 244, 225, .18); color: var(--text); font-size: 1.2rem;
  transition: transform .5s var(--spring), color .3s, background-color .3s, border-color .3s;
}
.card .fav { position: absolute; z-index: 3; top: .5rem; inset-inline-end: .5rem; }
.card .fav:hover, .fav-btn:hover { transform: scale(1.1); color: var(--gold); border-color: rgba(245, 197, 24, .6); }
.card .fav.added, .fav-btn.added { color: var(--gold); background: rgba(245, 197, 24, .16); border-color: rgba(245, 197, 24, .55); }
.card .fav.loading .ti, .fav-btn.loading .ti, .card .fav.busy .ti { animation: pulse .8s ease-in-out infinite; }
.card .fav.pop .ti, .fav-btn.pop .ti { animation: heart-pop .6s var(--spring); }
.card-body { display: flex; flex-direction: column; gap: .5rem; flex: 1; padding: 1rem 1.1rem 1.05rem; }
.card-title {
  font-size: 1rem; font-weight: 700; line-height: 1.65; color: var(--text); margin: 0;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; min-height: 3.3em;
}
a.card-title, .card-title a { color: var(--text); transition: color .3s; }
.card-title a::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.card:hover .card-title, .card:hover .card-title a { color: var(--gold-2); }
.card-title a:focus-visible { outline: none; }
.card:has(.card-title a:focus-visible) { outline: 2px solid var(--gold); outline-offset: 3px; }
.card .meta { display: flex; align-items: center; flex-wrap: wrap; gap: .3rem .5rem; font-size: .8rem; color: var(--muted); }
.card .rc { font-variant-numeric: tabular-nums; }
.card .new { padding: .05rem .55rem; border-radius: var(--pill); background: rgba(245, 197, 24, .12); color: var(--gold-2); font-size: .72rem; font-weight: 700; font-style: normal; }
.card-foot, .card-footer { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-top: auto; padding-top: .55rem; border-top: 1px solid var(--line); }
.card-footer { padding: .7rem 1.1rem; }
.card .seller { position: relative; z-index: 2; display: inline-flex; align-items: center; gap: .5rem; min-width: 0; min-height: 2.75rem; color: var(--text-2); font-size: .84rem; transition: color .3s; }
.card .seller:hover { color: var(--gold-2); }
.card .seller img { width: 1.75rem; height: 1.75rem; flex-shrink: 0; border-radius: 50%; object-fit: cover; border: 1px solid var(--line-2); }
.card .seller span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card .sold { flex-shrink: 0; display: inline-flex; align-items: center; gap: .3rem; font-size: .78rem; color: var(--muted); white-space: nowrap; }
.card .sold .ti { color: var(--gold); font-size: .95rem; }
.card .go { display: grid; place-items: center; width: 2rem; height: 2rem; flex: none; border-radius: 50%; border: 1px solid var(--line-2); color: var(--gold); font-size: .95rem; transition: background-color .3s, color .3s, transform .5s var(--spring); }
.card:hover .go { background: var(--gold); color: var(--on-gold); border-color: transparent; transform: translate3d(calc(var(--dirx, 1) * 3px), 0, 0); }
[dir="rtl"] .card { --dirx: -1; }
@container (max-width: 15rem) {
  .card-body { padding: .8rem .85rem .9rem; }
  .card-title { font-size: .92rem; }
  .card .sold { display: none; }
  .card .price b { font-size: 1.05rem; }
}
.stars { display: inline-flex; gap: .1rem; font-size: .85rem; color: #4d463c; }
.stars .on { color: var(--gold); }
/* service grid — 2 → 3 → 4 → 6 columns; compact horizontal cards on phones */
.cards { display: grid; grid-template-columns: repeat(var(--cols, 1), minmax(0, 1fr)); gap: clamp(1rem, 1.6vw, 1.6rem); }
.cards > * { min-width: 0; }
@media (min-width: 560px) { .cards { --cols: 2; } }
@media (min-width: 900px) { .cards { --cols: 3; } }
@media (min-width: 1280px) { .cards { --cols: 4; } }
@media (min-width: 2400px) { .cards { --cols: 6; } }
@media (max-width: 559.98px) {
  .cards > .card { flex-direction: row; }
  .cards > .card .card-media { flex: 0 0 38%; aspect-ratio: auto; min-height: 8.5rem; border-radius: 0; border-start-start-radius: calc(var(--r-lg) - 1px); border-end-start-radius: calc(var(--r-lg) - 1px); }
  .cards > .card .card-body { min-width: 0; gap: .35rem; padding: .75rem .85rem; }
  .cards > .card .tag, .cards > .card .play, .cards > .card .sold { display: none; }
  .cards > .card .fav { top: .35rem; inset-inline-end: .35rem; width: 2.4rem; height: 2.4rem; }
  .cards > .card .price { bottom: .5rem; inset-inline-start: .5rem; padding: .2rem .6rem; }
  .cards > .card .price small { display: none; }
  .cards > .card .price b { font-size: 1.05rem; }
  .cards > .card .card-title { font-size: .92rem; min-height: 0; }
  .cards > .card .card-foot { padding-top: .25rem; }
}

/* animated outline on hover (replaces the old square border) */
.sq-border { position: relative; transition: border-color .4s, box-shadow .4s; }
.sq-border:hover { border-color: rgba(245, 197, 24, .45); box-shadow: 0 0 0 1px rgba(245, 197, 24, .25), 0 1.2rem 3rem -1.5rem rgba(245, 197, 24, .35); }
.sq-corners { position: relative; }
.sq-corners > .c { display: none; }

/* category tiles (legacy flip tiles: front + gold back) */
.tiles { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.flip { aspect-ratio: 1; perspective: 900px; }
.flip-inner { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform .8s var(--ease-out); }
.flip:hover .flip-inner, .flip:focus-within .flip-inner { transform: rotateY(180deg); }
.flip-front, .flip-back { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 14px; text-align: center; border-radius: var(--r-lg); }
.flip-front { background: var(--surface); border: 1px solid var(--line); }
.flip-front i { font-size: 2.3rem; color: var(--gold); }
.flip-front span { font-weight: 700; font-size: .92rem; color: var(--text-2); line-height: 1.5; }
.flip-back { transform: rotateY(180deg); background: var(--grad); color: var(--on-gold); font-weight: 800; }
.flip-back:hover { color: var(--on-gold); }

/* stat tiles (dashboards) */
.stat { position: relative; padding: 1.25rem; border-radius: var(--r-lg); background: radial-gradient(120% 80% at 100% 0%, rgba(245, 197, 24, .1), transparent 60%), var(--surface); border: 1px solid var(--line); overflow: hidden; }
.stat .label { color: var(--muted); font-weight: 600; font-size: .9rem; }
.stat .value { font-size: 1.9rem; font-weight: 900; color: var(--gold); font-variant-numeric: tabular-nums; }

/* ==========================================================================
   Panels, page head, prose
   ========================================================================== */
.panel { position: relative; border-radius: var(--r-lg); background: linear-gradient(180deg, #161413, #121110); border: 1px solid var(--line); box-shadow: var(--shadow-1); }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 1rem 1.25rem; border-bottom: 1px solid var(--line); }
.panel-head h2, .panel-head h3 { margin: 0; font-size: 1.12rem; display: flex; align-items: center; gap: .5rem; }
.panel-head h2 .ti, .panel-head h3 .ti { color: var(--gold); }
.panel-body { padding: 1.25rem; }
.panel-foot { padding: .9rem 1.25rem; border-top: 1px solid var(--line); background: rgba(255, 255, 255, .02); border-radius: 0 0 var(--r-lg) var(--r-lg); }

/* cinematic banner on top of every inner page (banner image chosen per area in _PageHead) */
.page-head {
  position: relative; isolation: isolate; overflow: hidden;
  padding: calc(var(--hh) + env(safe-area-inset-top) + clamp(1.75rem, 5vw, 4rem)) 0 clamp(1.75rem, 4vw, 3.25rem);
  background: #0c0b0a;
  border-bottom: 1px solid var(--line);
}
.page-head::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background-image: var(--ph-img, none); background-size: cover; background-position: center;
  opacity: .5; transform: scaleX(var(--flip, 1)) scale(1.04);
}
[dir="rtl"] .page-head { --flip: -1; } /* banner subjects sit on the "end" side, away from the title */
.page-head::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 90% at 50% 0%, rgba(245, 197, 24, .14), transparent 70%),
    linear-gradient(var(--to-e), rgba(10, 10, 10, .92) 0%, rgba(10, 10, 10, .72) 45%, rgba(10, 10, 10, .35) 100%),
    linear-gradient(to bottom, rgba(10, 10, 10, .55), rgba(10, 10, 10, .15) 40%, var(--bg) 100%);
}
@media (max-width: 760px) { .page-head::before { background-image: var(--ph-img-sm, var(--ph-img, none)); } }
.page-head .container { position: relative; }
.page-head h1 { margin: 0; display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; text-wrap: balance; }
.page-head h1 .ti { color: var(--gold); font-size: .9em; }
/* the title keeps its own direction (<bdi>) but sits beside the icon, on the page's side */
.page-head h1 bdi { flex: 1 1 0; min-width: 0; text-align: left; }
[dir="rtl"] .page-head h1 bdi { text-align: right; }
.page-head p { color: var(--text-2); margin: .6rem 0 0; max-width: 46rem; font-size: clamp(1rem, .95rem + .25vw, 1.15rem); }
.page-head .ph-kicker {
  display: inline-flex; align-items: center; margin-bottom: .55rem; padding: .2rem .75rem; border-radius: var(--pill);
  border: 1px solid rgba(245, 197, 24, .3); background: rgba(245, 197, 24, .1); color: var(--gold); font-size: .8rem; font-weight: 800;
}
.page-head .rule-line { display: block; width: 4.5rem; height: 3px; margin-top: 1rem; border-radius: 3px; background: var(--grad); box-shadow: 0 0 1rem rgba(245, 197, 24, .5); }
@media (prefers-reduced-motion: no-preference) { .page-head::before { animation: ken-soft 30s ease-in-out infinite alternate; } }

.section-title { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 1.4rem; }
.section-title::before { content: ""; width: .6rem; height: .6rem; border-radius: 50%; background: var(--gold); box-shadow: 0 0 .8rem var(--gold); flex: none; }
.section-title h2 { margin: 0; }
.section-title .more { margin-inline-start: auto; }
.more {
  display: inline-flex; align-items: center; gap: .5rem; min-height: 2.75rem; padding: 0 1.1rem; border-radius: var(--pill);
  border: 1px solid var(--line-2); color: var(--text); font-size: .92rem; font-weight: 600; white-space: nowrap;
  transition: transform .5s var(--spring), border-color .3s, background-color .3s;
}
.more .ti { color: var(--gold); }
.more:hover { color: var(--text); border-color: rgba(245, 197, 24, .6); background: rgba(245, 197, 24, .08); transform: translate3d(0, -2px, 0); }
.lead { color: var(--text-2); font-size: clamp(1rem, .95rem + .25vw, 1.15rem); }

.prose { max-width: 56rem; color: var(--text-2); }
.prose h2, .prose h3 { color: var(--text); }
.prose h2 { margin-top: 1.6em; } .prose h3 { margin-top: 1.3em; }
.prose ul, .prose ol { padding-inline-start: 1.4em; }
.prose li { margin-bottom: .45em; }
.prose li::marker { color: var(--gold); }
.prose strong, .prose b { color: var(--text); }

.breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: .88rem; color: var(--muted); margin-bottom: .75rem; }
.breadcrumb a { color: var(--text-2); }
.breadcrumb a:hover { color: var(--gold); }
.breadcrumb .sep { opacity: .5; }

/* ==========================================================================
   Forms
   ========================================================================== */
.form { display: grid; gap: 16px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field > label, .label { font-weight: 700; font-size: .92rem; color: var(--text-2); }
.field .help { color: var(--muted); font-size: .82rem; }
.field .error, .field-validation-error { color: var(--danger); font-size: .85rem; font-weight: 600; }
.req::after { content: " *"; color: var(--danger); }
.input, .select, .textarea, input.form, select.form, textarea.form {
  width: 100%; min-height: 3rem; padding: .6rem 1rem; border-radius: .9rem; outline: none;
  background: #121110; border: 1px solid var(--line-2); color: var(--text);
  transition: border-color .25s, box-shadow .25s, background-color .25s;
}
.select { padding-inline-end: 2.4rem; -webkit-appearance: none; appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23f5c518' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right .9rem center; background-size: 1rem; }
[dir="rtl"] .select { background-position: left .9rem center; }
.select option { background: #1b1917; color: var(--text); }
.textarea { min-height: 8.5rem; resize: vertical; line-height: 1.7; }
.input:hover, .select:hover, .textarea:hover { border-color: rgba(255, 244, 225, .28); }
.input:focus, .select:focus, .textarea:focus { border-color: rgba(245, 197, 24, .7); box-shadow: 0 0 0 .25rem rgba(245, 197, 24, .14); background: #151412; }
.input[readonly], .input:disabled, .select:disabled, .textarea:disabled { opacity: .65; }
.input.invalid, .textarea.invalid, .input-validation-error { border-color: var(--danger); animation: shake .4s; }
.counter { font-size: .8rem; font-weight: 700; color: var(--success); text-align: end; }
.counter.warn { color: var(--warning); } .counter.over { color: var(--danger); }
.check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 600; color: var(--text-2); }
.check input, input[type="checkbox"], input[type="radio"] { accent-color: var(--gold); }
.check input { width: 18px; height: 18px; }
.input-group { display: flex; gap: .5rem; } .input-group .input { flex: 1; } .input-group .btn { flex: none; }
.captcha-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.captcha-row img { width: 150px; height: 56px; border-radius: .75rem; border: 1px solid var(--line-2); background: #fff; }
.captcha-row .input { max-width: 120px; text-align: center; font-size: 1.3rem; letter-spacing: .3em; direction: ltr; }
input[type="file"] { color: var(--text-2); max-width: 100%; }
input[type="file"]::file-selector-button { margin-inline-end: .75rem; padding: .5rem 1rem; border-radius: var(--pill); border: 1px solid var(--line-2); background: rgba(255, 255, 255, .06); color: var(--text); font: inherit; font-weight: 700; cursor: pointer; }
input[type="file"]::file-selector-button:hover { border-color: rgba(245, 197, 24, .6); color: var(--gold-2); }

/* Tom Select (token boxes) */
.ts-wrapper .ts-control { min-height: 3rem; padding: .55rem 1rem; border-radius: .9rem; border: 1px solid var(--line-2); background: #121110 !important; color: var(--text); box-shadow: none; font-size: 1rem; }
.ts-wrapper .ts-control input { color: var(--text); }
.ts-wrapper.focus .ts-control { border-color: rgba(245, 197, 24, .7); box-shadow: 0 0 0 .25rem rgba(245, 197, 24, .14); }
.ts-dropdown { border-radius: var(--r); border: 1px solid var(--line-2); background: #171513; color: var(--text); box-shadow: var(--shadow-2); overflow: hidden; }
.ts-dropdown .option { display: flex; align-items: center; gap: 10px; padding: .55rem .9rem; color: var(--text-2); }
.ts-dropdown .option img { width: 44px; height: 44px; object-fit: cover; flex: none; border-radius: .5rem; }
.ts-dropdown .active { background: rgba(245, 197, 24, .12); color: var(--text); }
.ts-dropdown .no-results, .ts-dropdown .create { color: var(--muted); padding: .55rem .9rem; }
.ts-wrapper.multi .ts-control > div { border-radius: var(--pill); background: rgba(245, 197, 24, .16); color: var(--gold-2); border: 1px solid rgba(245, 197, 24, .4); }
.ts-wrapper.plugin-remove_button .item .remove { border-color: rgba(245, 197, 24, .3) !important; display: inline-flex; align-items: center; justify-content: center; min-width: 1.6rem; min-height: 1.6rem; } /* ≥ 24px tap size */

/* Quill editor (dark) */
.ql-toolbar.ql-snow { border: 1px solid var(--line-2) !important; border-radius: .9rem .9rem 0 0; background: #1b1917; }
.ql-container.ql-snow { border: 1px solid var(--line-2) !important; border-top: 0 !important; border-radius: 0 0 .9rem .9rem; }
.ql-container { min-height: 220px; font-family: var(--font) !important; font-size: 1rem !important; background: #121110; color: var(--text); }
.ql-editor.ql-blank::before { color: #8f877a !important; }
.ql-snow .ql-stroke { stroke: var(--text-2) !important; }
.ql-snow .ql-fill, .ql-snow .ql-stroke.ql-fill { fill: var(--text-2) !important; }
.ql-snow .ql-picker { color: var(--text-2) !important; }
.ql-snow .ql-picker-options { background: #1b1917 !important; border-color: var(--line-2) !important; }
.ql-snow button:hover .ql-stroke, .ql-snow button.ql-active .ql-stroke, .ql-snow .ql-picker-label:hover .ql-stroke { stroke: var(--gold) !important; }
.ql-snow button:hover .ql-fill, .ql-snow button.ql-active .ql-fill { fill: var(--gold) !important; }
.ql-snow .ql-tooltip { background: #1b1917; color: var(--text); border-color: var(--line-2); box-shadow: var(--shadow-2); }
.ql-snow .ql-tooltip input[type=text] { background: #121110; color: var(--text); border-color: var(--line-2); }
[dir="rtl"] .ql-editor { text-align: right; }

/* ==========================================================================
   Tables & DataTables
   ========================================================================== */
.table-wrap { overflow-x: auto; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--surface); }
table.table { width: 100%; border-collapse: collapse; background: transparent; color: var(--text-2); }
table.table th { text-align: start; font-size: .8rem; font-weight: 700; letter-spacing: .03em; color: var(--muted); background: rgba(255, 255, 255, .025); padding: .8rem 1rem; border-bottom: 1px solid var(--line-2); white-space: nowrap; }
table.table td { padding: .8rem 1rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.table tbody tr { transition: background-color .2s; }
table.table tbody tr:hover { background: rgba(245, 197, 24, .05); }
table.table tbody tr:last-child td { border-bottom: 0; }
table.table img.thumb { width: 64px; height: 40px; object-fit: cover; border-radius: .5rem; }
div.dt-container { font-size: .95rem; color: var(--text-2); }
div.dt-container .dt-input, div.dt-container .dt-search input, div.dt-container select.dt-input { border: 1px solid var(--line-2) !important; border-radius: var(--pill) !important; padding: .35rem .8rem !important; background: #121110 !important; color: var(--text) !important; }
div.dt-container .dt-paging .dt-paging-button { border-radius: var(--pill) !important; border: 1px solid var(--line) !important; margin-inline: 2px !important; color: var(--text-2) !important; background: transparent !important; }
div.dt-container .dt-paging .dt-paging-button.current, div.dt-container .dt-paging .dt-paging-button:hover:not(.disabled) { background: var(--gold) !important; color: var(--on-gold) !important; border-color: var(--gold) !important; }
div.dt-container .dt-paging .dt-paging-button.disabled { opacity: .55; color: var(--muted) !important; }
div.dt-container .dt-layout-row { margin: 10px 0 !important; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .6rem 1rem; }
div.dt-container .dt-layout-row > .dt-layout-cell { margin: 0 !important; padding: 0 !important; }
div.dt-container .dt-layout-row:not(.dt-layout-table) > .dt-layout-cell { flex: 0 1 auto; }
div.dt-container .dt-layout-row.dt-layout-table > .dt-layout-cell { flex: 1 1 100%; min-width: 0; overflow-x: auto; }
div.dt-container .dt-search, div.dt-container .dt-length { display: inline-flex; align-items: center; gap: .5rem; }
div.dt-container .dt-search label, div.dt-container .dt-length label { margin: 0; }
div.dt-container .dt-search input { margin: 0 !important; }
div.dt-container .dt-info { color: var(--muted); }
table.dataTable thead th { text-align: start !important; }
table.dataTable thead > tr > th.dt-orderable-asc span.dt-column-order::before, table.dataTable thead > tr > th.dt-orderable-desc span.dt-column-order::after { opacity: .35; }
table.dataTable > tbody > tr { background: transparent !important; }
table.dataTable.stripe > tbody > tr:nth-child(odd) > *, table.dataTable.display > tbody > tr:nth-child(odd) > * { box-shadow: inset 0 0 0 9999px rgba(255, 255, 255, .02) !important; }
table.dataTable.hover > tbody > tr:hover > *, table.dataTable.display > tbody > tr:hover > * { box-shadow: inset 0 0 0 9999px rgba(245, 197, 24, .06) !important; }

/* ==========================================================================
   Badges, alerts, tabs, rating, chips, empty states
   ========================================================================== */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: .15rem .65rem; border-radius: var(--pill); font-size: .76rem; font-weight: 700; background: rgba(255, 255, 255, .06); color: var(--text-2); border: 1px solid var(--line-2); white-space: nowrap; }
.badge-success { background: rgba(34, 197, 94, .13); color: #86efac; border-color: rgba(34, 197, 94, .32); }
.badge-danger { background: rgba(239, 68, 68, .13); color: #fca5a5; border-color: rgba(239, 68, 68, .32); }
.badge-warning { background: rgba(245, 158, 11, .14); color: #fcd34d; border-color: rgba(245, 158, 11, .34); }
.badge-info { background: rgba(56, 189, 248, .13); color: #7dd3fc; border-color: rgba(56, 189, 248, .32); }
.badge-brand { background: var(--gold); color: var(--on-gold); border-color: var(--gold); }

.alert { display: flex; gap: 12px; align-items: flex-start; padding: .9rem 1.1rem; border-radius: var(--r); border: 1px solid rgba(56, 189, 248, .3); background: rgba(56, 189, 248, .08); color: var(--text); animation: fade-up .4s var(--ease-out); }
.alert i, .alert .ti { font-size: 1.3rem; line-height: 1.4; color: var(--info); }
.alert-success { border-color: rgba(34, 197, 94, .32); background: rgba(34, 197, 94, .08); }
.alert-success .ti { color: var(--success); }
.alert-danger { border-color: rgba(239, 68, 68, .35); background: rgba(239, 68, 68, .08); }
.alert-danger .ti { color: var(--danger); }
.alert-warning { border-color: rgba(245, 158, 11, .35); background: rgba(245, 158, 11, .08); }
.alert-warning .ti { color: var(--warning); }

.tabs { display: flex; gap: .35rem; padding: .3rem; border-radius: var(--pill); background: rgba(255, 255, 255, .04); border: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; width: fit-content; max-width: 100%; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button, .tabs a { position: relative; padding: .55rem 1.1rem; border-radius: var(--pill); background: none; border: 0; font-weight: 700; color: var(--muted); cursor: pointer; white-space: nowrap; transition: color .3s, background-color .3s; }
.tabs button:hover, .tabs a:hover { color: var(--text); }
.tabs .active { color: var(--on-gold); background: var(--grad); box-shadow: 0 .5rem 1.2rem -.6rem rgba(245, 197, 24, .7); }
.tab-panel { display: none; animation: fade-up .4s var(--ease-out); } .tab-panel.active { display: block; }

.rating { display: inline-flex; gap: 2px; color: var(--gold); font-size: 1.05rem; }
.rating .off { color: #4d463c; }
.rating-input { display: inline-flex; flex-direction: row-reverse; gap: 4px; }
.rating-input input { display: none; }
.rating-input label { font-size: 1.8rem; color: #4d463c; cursor: pointer; transition: transform .2s var(--ease), color .2s; }
.rating-input label:hover, .rating-input label:hover ~ label, .rating-input input:checked ~ label { color: var(--gold); }
.rating-input label:hover { transform: scale(1.2) rotate(-8deg); }

.chip {
  display: inline-flex; align-items: center; gap: .45rem; min-height: 2.5rem; padding: 0 1rem; max-width: 100%;
  border-radius: var(--pill); border: 1px solid var(--line-2); background: rgba(20, 19, 18, .62); color: var(--text-2);
  font-size: .88rem; font-weight: 600; white-space: nowrap; cursor: pointer;
  transition: transform .5s var(--spring), border-color .3s, color .3s, background-color .3s;
}
.chip span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.chip .ti { flex-shrink: 0; color: var(--gold); font-size: 1.05rem; }
.chip:hover { transform: translate3d(0, -2px, 0); border-color: rgba(245, 197, 24, .6); color: var(--text); background: rgba(245, 197, 24, .1); }
.chip.active { background: var(--grad); color: var(--on-gold); border-color: transparent; }
.chip.active .ti { color: var(--on-gold); }

.empty { text-align: center; padding: 3rem 1.25rem; color: var(--muted); border-radius: var(--r-lg); border: 1px dashed var(--line-2); }
.empty .sq-icon { width: 4.5rem; height: 4.5rem; margin: 0 auto 14px; display: grid; place-items: center; font-size: 2rem; color: var(--gold); border-radius: 50%; background: radial-gradient(circle at 35% 30%, rgba(255, 226, 122, .3), rgba(245, 197, 24, .08) 60%); box-shadow: 0 0 2.5rem rgba(245, 197, 24, .2); }

/* ==========================================================================
   Dialogs, toasts, loaders, cookie bar, back-to-top
   ========================================================================== */
dialog.dlg {
  border: 1px solid var(--line-2); padding: 0; width: min(520px, calc(100vw - 32px)); max-height: calc(100vh - 40px); border-radius: var(--r-xl);
  background: radial-gradient(90% 60% at 50% 0%, rgba(245, 197, 24, .09), transparent 70%), #121110; color: var(--text);
  box-shadow: 0 2.5rem 6rem -1.5rem rgba(0, 0, 0, .95), 0 0 4rem -2rem rgba(245, 197, 24, .35); overflow: hidden;
}
dialog.dlg-lg { width: min(820px, calc(100vw - 32px)); }
dialog.dlg[open] { animation: dlg-in .5s var(--ease-out); }
dialog.dlg::backdrop { background: rgba(3, 3, 3, .7); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); animation: fade .3s; }
.dlg-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 1.1rem 1.35rem; border-bottom: 1px solid var(--line); }
.dlg-head h3 { margin: 0; font-size: 1.12rem; display: flex; align-items: center; gap: .55rem; }
.dlg-head h3 .ti { color: var(--gold); font-size: 1.3rem; }
.dlg-close { width: 2.4rem; height: 2.4rem; display: grid; place-items: center; border-radius: 50%; background: rgba(255, 255, 255, .06); border: 1px solid var(--line); color: var(--text); cursor: pointer; font-size: 1.1rem; transition: transform .4s var(--spring), border-color .3s, color .3s; }
.dlg-close:hover { transform: rotate(90deg); border-color: rgba(245, 197, 24, .6); color: var(--gold); }
.dlg-body { padding: 1.35rem; max-height: calc(100vh - 170px); overflow: auto; }
.dlg-foot { display: flex; gap: 10px; justify-content: flex-end; padding: 1rem 1.35rem; border-top: 1px solid var(--line); }
.dlg-deco { display: none; }
.or-line { display: flex; align-items: center; gap: 12px; color: var(--muted); font-weight: 700; font-size: .85rem; }
.or-line::before, .or-line::after { content: ""; flex: 1; height: 1px; background: var(--line-2); }
/* "continue with Google / Facebook / LinkedIn" (Views/Shared/_SocialSignIn.cshtml) */
.social-signin { display: grid; gap: .75rem; }
.social-btns { display: grid; grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr)); gap: .5rem; }
.social-btn { justify-content: center; font-weight: 700; }
.social-btn .ti { font-size: 1.15rem; }
/* hint for members who joined with Facebook / LinkedIn while those buttons are off */
.social-old { display: flex; align-items: flex-start; gap: .5rem; margin: 0; padding: .65rem .8rem; border-radius: var(--r-sm); border: 1px dashed var(--line-2); background: rgba(255, 255, 255, .03); color: var(--muted); font-size: .82rem; line-height: 1.55; text-align: start; }
.social-old > .ti { flex: none; margin-top: .15rem; color: var(--gold); font-size: 1rem; }
.social-old .link-btn { font-size: inherit; }
.social-google .ti { color: #ea4335; }
.social-facebook .ti { color: #1877f2; }
.social-linkedin .ti { color: #0a66c2; }
.social-btn { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 3rem; border-radius: var(--pill); border: 1px solid var(--line-2); background: rgba(255, 255, 255, .04); color: var(--text); font-weight: 700; cursor: pointer; transition: transform .5s var(--spring), border-color .3s; }
.social-btn:hover { border-color: rgba(245, 197, 24, .6); transform: translate3d(0, -2px, 0); color: var(--text); }
.social-btn.fb i { color: #1877f2; } .social-btn.gg i { color: #ea4335; }
.form-msg:empty { display: none; }

.toasts { position: fixed; z-index: 200; inset-inline: 1rem; bottom: calc(1.25rem + env(safe-area-inset-bottom)); display: grid; justify-items: center; gap: .5rem; pointer-events: none; }
.toast {
  pointer-events: auto; display: flex; align-items: center; gap: .6rem; max-width: min(32rem, 100%); padding: .75rem 1.25rem; border-radius: var(--pill);
  background: rgba(24, 21, 18, .97); border: 1px solid rgba(245, 197, 24, .45); color: var(--text); font-size: .92rem; font-weight: 600;
  box-shadow: 0 1rem 2.5rem rgba(0, 0, 0, .6), 0 0 2rem -.5rem rgba(245, 197, 24, .3); animation: toast-in .5s var(--spring);
}
.toast .ti { font-size: 1.25rem; color: var(--gold); flex: none; }
.toast.success .ti { color: var(--success); }
.toast.error { border-color: rgba(239, 68, 68, .55); }
.toast.error .ti { color: var(--danger); }
.toast.out { opacity: 0; transform: translate3d(0, .75rem, 0) scale(.96); transition: opacity .35s, transform .35s; }

.topbar-progress { position: fixed; top: 0; inset-inline: 0; height: 3px; z-index: 300; background: var(--grad); box-shadow: 0 0 1rem rgba(245, 197, 24, .7); transform-origin: var(--os) center; transform: scaleX(0); opacity: 0; transition: opacity .3s; }
.topbar-progress.on { opacity: 1; animation: progress 1.4s var(--ease-out) infinite; }
.sq-loader { display: inline-block; width: 2.6rem; height: 2.6rem; border-radius: 50%; border: 3px solid rgba(245, 197, 24, .18); border-top-color: var(--gold); animation: spin .8s linear infinite; }
.sq-loader i { display: none; }
.loader-overlay { position: fixed; inset: 0; z-index: 250; display: none; place-items: center; background: rgba(5, 5, 5, .55); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.loader-overlay.on { display: grid; animation: fade .2s; }
.skeleton { position: relative; overflow: hidden; background: var(--surface-2); border-radius: var(--r-sm); }
.skeleton::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255, 244, 225, .06), transparent); animation: shimmer 1.4s infinite; }

.scroll-top {
  position: fixed; bottom: calc(1.25rem + env(safe-area-inset-bottom)); inset-inline-start: 1.25rem; z-index: 40; width: 3rem; height: 3rem;
  display: grid; place-items: center; border: 0; border-radius: 50%; color: var(--on-gold); background: var(--grad); cursor: pointer; font-size: 1.25rem;
  box-shadow: 0 .8rem 2rem -.6rem rgba(245, 197, 24, .7); opacity: 0; transform: translate3d(0, 1.25rem, 0) scale(.8); pointer-events: none;
  transition: opacity .4s var(--ease), transform .55s var(--spring);
}
.scroll-top.show { opacity: 1; transform: none; pointer-events: auto; }
.scroll-top:hover { transform: translate3d(0, -3px, 0) scale(1.06); }

.cookie-bar {
  position: fixed; z-index: 95; bottom: calc(1rem + env(safe-area-inset-bottom)); inset-inline: 1rem; max-width: 46rem; margin-inline: auto;
  display: none; gap: 1rem; align-items: center; padding: .9rem 1rem .9rem 1.25rem; border-radius: var(--r-xl);
  background: rgba(20, 18, 16, .96); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  border: 1px solid var(--line-2); color: var(--text-2); box-shadow: var(--shadow-2); font-size: .92rem;
}
.cookie-bar > .ti { color: var(--gold); }
.cookie-bar.show { display: flex; animation: toast-in .5s var(--spring); }
.cookie-bar a { color: var(--gold-2); }
.cookie-actions { display: flex; flex: none; gap: .5rem; justify-content: center; }
@media (max-width: 600px) { .cookie-bar.show { flex-direction: column; align-items: stretch; text-align: center; } }

/* the old floating-squares decoration is retired */
.squares { display: none !important; }

/* ==========================================================================
   Slider, poll (legacy markup used outside the home page)
   ========================================================================== */
.slider { position: relative; overflow: hidden; aspect-ratio: 850 / 350; border-radius: var(--r-lg); background: var(--surface-2); border: 1px solid var(--line); }
.slider > * { position: absolute; inset: 0; opacity: 0; transition: opacity 1s, transform 6s linear; transform: scale(1.05); }
.slider > *.on { opacity: 1; transform: scale(1); }
.slider img { width: 100%; height: 100%; object-fit: cover; }
.slider-dots { position: absolute; bottom: 12px; inset-inline: 0; display: flex; justify-content: center; gap: 8px; z-index: 2; opacity: 1 !important; transform: none !important; }
.slider-dots button { width: 10px; height: 10px; border-radius: var(--pill); border: 0; background: rgba(255, 255, 255, .45); cursor: pointer; padding: 0; transition: width .4s var(--ease-out), background-color .3s; }
.slider-dots button.on { width: 26px; background: var(--gold); }

.poll-bar { height: .65rem; border-radius: var(--pill); background: rgba(255, 255, 255, .07); margin: 4px 0 12px; overflow: hidden; }
.poll-bar span { display: block; height: 100%; width: 0; border-radius: inherit; background: linear-gradient(var(--to-e), var(--gold-3), var(--gold), #ffe27a); transition: width 1.2s var(--ease-out); }

/* ==========================================================================
   Footer (the "Midnight" footer)
   ========================================================================== */
.ftr {
  --vi: #8b5cf6; --cy: #22d3ee; --pk: #f472b6;
  position: relative; z-index: 2; overflow: hidden; margin-top: clamp(1.5rem, 4vw, 3rem);
  padding-top: clamp(3.25rem, 7vw, 5.5rem);
  background: linear-gradient(180deg, rgba(10, 11, 20, 0), rgba(10, 11, 20, .92) 40%);
  color: var(--text-2);
}
.ftr-line { position: absolute; top: 0; inset-inline: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--vi) 20%, var(--cy) 50%, var(--pk) 80%, transparent); }
.ftr-line::after { content: ""; position: absolute; top: -1px; left: 0; width: 22%; height: 3px; border-radius: 99px; background: radial-gradient(closest-side, #fff, rgba(34, 211, 238, .7) 50%, transparent); filter: blur(1px); animation: travel-x 6s ease-in-out infinite; }
[dir="rtl"] .ftr-line::after { left: auto; right: 0; animation-name: travel-x-rtl; }
.ftr-line::before { content: ""; position: absolute; inset: -30px 10% auto; height: 60px; background: radial-gradient(50% 50% at 50% 0%, rgba(139, 92, 246, .35), transparent 70%); }
.ftr-grid { display: grid; gap: 2.1rem 1.5rem; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ftr-grid > * { min-width: 0; }
.ftr-brand { grid-column: 1 / -1; }
.ftr-brand p { margin-top: 1rem; color: var(--text-2); max-width: 24rem; font-size: .95rem; }
.ftr .social { display: flex; gap: .6rem; margin-top: 1.25rem; }
.ftr .social a { border-color: var(--line-2); background: rgba(255, 255, 255, .04); color: var(--text); }
.ftr .social a:hover { border-color: rgba(139, 92, 246, .6); background: rgba(139, 92, 246, .14); color: #fff; }
.ftr h4 { font-size: .98rem; margin-bottom: .6rem; color: #fff; }
.ftr ul { margin: 0; padding: 0; list-style: none; }
.ftr ul a, .ftr ul button { display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0; border: 0; background: none; color: var(--text-2); font: inherit; font-size: .93rem; text-align: start; cursor: pointer; transition: color .3s, translate .45s var(--spring); }
.ftr ul a:hover, .ftr ul button:hover { color: #fff; translate: 4px 0; }
[dir="rtl"] .ftr ul a:hover, [dir="rtl"] .ftr ul button:hover { translate: -4px 0; }
.ftr-bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1.5rem; margin-top: 2.5rem; padding-block: 1.35rem; border-top: 1px solid rgba(255, 255, 255, .08); color: #8a90ab; font-size: .86rem; }
.ftr-bottom .pp { display: inline-flex; align-items: center; gap: .5rem; }
.ftr-bottom .pp .ti { font-size: 1.3rem; color: #60a5fa; }
/* PayPal JavaScript SDK v6 button (js/paypal.js) */
paypal-button.pp-btn { display: block; width: 100%; min-height: 3rem; }
/* accepted payment marks (Visa / Mastercard / PayPal) on white cards */
.pay { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem .9rem; }
.pay-txt { display: inline-flex; align-items: center; gap: .4rem; }
.pay-txt .ti { color: var(--gold); font-size: 1.05rem; }
.pay-marks { display: inline-flex; gap: .45rem; }
.pm { display: grid; place-items: center; width: 3.35rem; height: 2.15rem; border-radius: .5rem; background: linear-gradient(180deg, #fff, #f1f1f4); box-shadow: 0 8px 18px -10px rgba(0, 0, 0, .9), inset 0 0 0 1px rgba(0, 0, 0, .06); transition: transform .35s var(--ease-out), box-shadow .35s; }
.pm:hover { transform: translate3d(0, -2px, 0); box-shadow: 0 12px 24px -10px rgba(245, 197, 24, .45), inset 0 0 0 1px rgba(0, 0, 0, .06); }
.pm svg { width: 80%; height: 72%; overflow: visible; }
.ftr-bottom a { color: var(--text-2); display: inline-flex; align-items: center; gap: .35rem; min-height: 2.75rem; }
.ftr-bottom a:hover { color: #fff; }
.ftr-word {
  margin-top: .5rem; text-align: center; white-space: nowrap; user-select: none; pointer-events: none;
  font: 900 clamp(3rem, 18vw, 16.5rem)/.82 var(--font); letter-spacing: -.05em;
  background: linear-gradient(180deg, rgba(196, 181, 253, .22), rgba(196, 181, 253, 0) 85%);
  -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent;
}
@media (min-width: 900px) {
  .ftr-grid { grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); }
  .ftr-brand { grid-column: auto; }
}
@media (max-width: 380px) { .ftr-grid { grid-template-columns: minmax(0, 1fr); } }

/* ==========================================================================
   Scroll reveal — data-reveal (fade-up) or data-reveal="left|right|zoom|flip";
   children of [data-stagger] reveal one after another.
   ========================================================================== */
@media (prefers-reduced-motion: no-preference) {
  html:not(.no-js) [data-reveal] { opacity: 0; transform: translate3d(0, 1.75rem, 0); transition: opacity .9s var(--ease), transform 1.1s var(--ease-out); transition-delay: var(--delay, 0s); }
  html:not(.no-js) [data-reveal="left"] { transform: translate3d(-2.5rem, 0, 0); }
  html:not(.no-js) [data-reveal="right"] { transform: translate3d(2.5rem, 0, 0); }
  html:not(.no-js) [data-reveal="zoom"] { transform: scale(.94); }
  html:not(.no-js) [data-reveal="flip"] { transform: perspective(800px) rotateX(-12deg) translate3d(0, 1.25rem, 0); transform-origin: top; }
  html:not(.no-js) [data-reveal].in { opacity: 1; transform: none; }
}

/* ==========================================================================
   Keyframes
   ========================================================================== */
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fade { from { opacity: 0; } }
@keyframes fade-up { from { opacity: 0; transform: translate3d(0, .75rem, 0); } }
@keyframes pop-in { from { opacity: 0; transform: translate3d(0, -.4rem, 0) scale(.97); } }
@keyframes dlg-in { from { opacity: 0; transform: translate3d(0, 1.5rem, 0) scale(.96); } }
@keyframes toast-in { from { opacity: 0; transform: translate3d(0, 1rem, 0) scale(.92); } }
@keyframes shimmer { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
@keyframes progress { 0% { transform: scaleX(0); } 60% { transform: scaleX(.7); } 100% { transform: scaleX(1); opacity: 0; } }
@keyframes shake { 20%, 60% { transform: translateX(-5px); } 40%, 80% { transform: translateX(5px); } }
@keyframes pulse { 50% { transform: scale(.82); opacity: .6; } }
@keyframes pulse-ring { 0% { box-shadow: 0 0 0 2px var(--bg), 0 0 0 2px rgba(245, 197, 24, .7); } 100% { box-shadow: 0 0 0 2px var(--bg), 0 0 0 10px rgba(245, 197, 24, 0); } }
@keyframes heart-pop { 0% { transform: scale(1); } 35% { transform: scale(1.45); } 100% { transform: scale(1); } }
@keyframes travel-x { from { transform: translateX(-100%); opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } to { transform: translateX(560%); opacity: 0; } }
@keyframes travel-x-rtl { from { transform: translateX(100%); opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } to { transform: translateX(-560%); opacity: 0; } }
@keyframes ken-soft { from { transform: scaleX(var(--flip, 1)) scale(1.04); } to { transform: scaleX(var(--flip, 1)) scale(1.12) translate3d(-1%, .8%, 0); } }
/* names used by older page styles (kept so their animations still run) */
@keyframes fadeIn { from { opacity: 0; } }
@keyframes fadeUp { from { opacity: 0; transform: translate3d(0, .75rem, 0); } }
@keyframes slideDown { from { opacity: 0; transform: translate3d(0, -.6rem, 0); } }
@keyframes popIn { 0% { transform: scale(.4); } 70% { transform: scale(1.12); } 100% { transform: scale(1); } }
@keyframes dlgIn { from { opacity: 0; transform: translate3d(0, 1.5rem, 0) scale(.96); } }
@keyframes toastIn { from { opacity: 0; transform: translate3d(0, 1rem, 0) scale(.92); } }
@keyframes toastOut { to { opacity: 0; transform: translate3d(0, .75rem, 0) scale(.96); } }
@keyframes spinSlow { to { transform: rotate(360deg); } }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes gradientShift { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes pulseSquare { 0%, 100% { box-shadow: 0 0 0 0 rgba(245, 197, 24, .55); } 50% { box-shadow: 0 0 0 7px rgba(245, 197, 24, 0); } }
@keyframes grain {
  0% { transform: translate3d(0, 0, 0); } 20% { transform: translate3d(-2.5rem, 1.5rem, 0); } 40% { transform: translate3d(1.5rem, -3rem, 0); }
  60% { transform: translate3d(-3.5rem, -1rem, 0); } 80% { transform: translate3d(2rem, 3rem, 0); } 100% { transform: translate3d(0, 0, 0); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; animation-delay: 0s !important; transition-duration: .01ms !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
  .ftr-line::after, .grain::before, .page-head::before { animation: none !important; }
}
