@charset "UTF-8";
/* ==========================================================================
   بيوت العقارية — Boyoot Real Estate
   main.css — design tokens, reset, layout, header, footer
   Identity: gold sampled from the brand mark (#C89828 / #D8B040) on warm ink.
   ========================================================================== */

/* ==========================================================================
   1. DESIGN TOKENS
   ========================================================================== */
:root {
  /* -- Gold: sampled from the brand mark -------------------------------- */
  --gold-50:  #FDF9EC;
  --gold-100: #F9EFC9;
  --gold-200: #F3E19B;
  --gold-300: #EBCF6A;
  --gold-400: #DDB944;   /* mark core             */
  --gold-500: #C89828;   /* mark primary          */
  --gold-600: #A87C1C;
  --gold-700: #856016;   /* AA gold text on paper */
  --gold-800: #634711;
  --gold-900: #43300B;

  /* -- Ink: warm neutral, keyed to the gold ----------------------------- */
  --ink-950: #100E09;
  --ink-900: #1A1712;
  --ink-800: #262119;
  --ink-700: #3A3327;
  --ink-600: #554C3B;
  --ink-500: #766B56;
  --ink-400: #9C9280;
  --ink-300: #C2BAA9;
  --ink-200: #DED8CB;
  --ink-100: #EFEBE1;
  --ink-50:  #F7F4ED;
  --paper:   #FBF9F4;
  --white:   #FFFFFF;

  /* -- Semantic --------------------------------------------------------- */
  --ok:      #2E7D53;
  --ok-bg:   #E8F3ED;
  --warn:    #B87333;
  --warn-bg: #FBF0E4;
  --bad:     #B3261E;
  --bad-bg:  #FAEAE9;
  --info:    #2C5D8A;
  --info-bg: #E9F0F6;
  --whatsapp:#1FA855;

  /* -- Roles (re-pointed by the dark theme) ----------------------------- */
  --bg:           var(--paper);
  --bg-raised:    var(--white);
  --bg-sunken:    var(--ink-50);
  --bg-inverse:   var(--ink-900);
  --text:         var(--ink-900);
  --text-soft:    var(--ink-600);
  --text-mute:    var(--ink-500);
  --text-inverse: var(--ink-50);
  --line:         var(--ink-200);
  --line-soft:    var(--ink-100);
  --line-strong:  var(--ink-300);
  --accent:       var(--gold-500);
  --accent-text:  var(--gold-700);
  --accent-soft:  var(--gold-100);
  --on-accent:    var(--ink-950);

  /* -- Type ------------------------------------------------------------- */
  --font-display: "Cormorant Garamond", "Tajawal", "Times New Roman", serif;
  --font-body:    "IBM Plex Sans Arabic", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-num:     "IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --step--2: clamp(0.72rem, 0.70rem + 0.10vw, 0.78rem);
  --step--1: clamp(0.82rem, 0.79rem + 0.14vw, 0.90rem);
  --step-0:  clamp(0.95rem, 0.92rem + 0.16vw, 1.05rem);
  --step-1:  clamp(1.12rem, 1.06rem + 0.30vw, 1.32rem);
  --step-2:  clamp(1.35rem, 1.24rem + 0.55vw, 1.75rem);
  --step-3:  clamp(1.65rem, 1.44rem + 1.05vw, 2.40rem);
  --step-4:  clamp(2.00rem, 1.62rem + 1.90vw, 3.30rem);
  --step-5:  clamp(2.40rem, 1.75rem + 3.25vw, 4.60rem);

  /* -- Space ------------------------------------------------------------ */
  --sp-1: 4px;   --sp-2: 8px;   --sp-3: 12px;  --sp-4: 16px;
  --sp-5: 24px;  --sp-6: 32px;  --sp-7: 48px;  --sp-8: 64px;
  --sp-9: 96px;  --sp-10: 128px;

  /* -- Shape ------------------------------------------------------------ */
  --r-xs: 3px;  --r-sm: 6px;  --r-md: 10px;  --r-lg: 16px;  --r-xl: 24px;  --r-pill: 999px;

  /* -- Elevation: soft printed-paper shadows, never a glow -------------- */
  --sh-1: 0 1px 2px rgba(26,23,18,.06), 0 1px 1px rgba(26,23,18,.04);
  --sh-2: 0 2px 6px rgba(26,23,18,.07), 0 4px 14px rgba(26,23,18,.05);
  --sh-3: 0 6px 16px rgba(26,23,18,.09), 0 12px 32px rgba(26,23,18,.07);
  --sh-4: 0 12px 28px rgba(26,23,18,.12), 0 24px 64px rgba(26,23,18,.10);

  --ease: cubic-bezier(.22,.61,.36,1);
  --dur:  .28s;

  --header-h: 76px;
  --wrap: 1240px;
  --wrap-wide: 1440px;
  --wrap-text: 68ch;
}

/* -- Dark theme: the gold holds up beautifully on ink ------------------- */
[data-theme="dark"] {
  --bg:           var(--ink-950);
  --bg-raised:    var(--ink-900);
  --bg-sunken:    #0A0906;
  --bg-inverse:   var(--ink-50);
  --text:         #F2EEE4;
  --text-soft:    var(--ink-300);
  --text-mute:    var(--ink-400);
  --text-inverse: var(--ink-900);
  --line:         #332C22;
  --line-soft:    #241F18;
  --line-strong:  #4A4133;
  --accent:       var(--gold-400);
  --accent-text:  var(--gold-300);
  --accent-soft:  #2A2213;
  --on-accent:    var(--ink-950);
  --ok-bg:  #12241B;  --warn-bg: #2A1D0F;  --bad-bg: #2A1210;  --info-bg: #101D28;
  --sh-1: 0 1px 2px rgba(0,0,0,.45);
  --sh-2: 0 2px 6px rgba(0,0,0,.5), 0 4px 14px rgba(0,0,0,.35);
  --sh-3: 0 6px 16px rgba(0,0,0,.55), 0 12px 32px rgba(0,0,0,.4);
  --sh-4: 0 12px 28px rgba(0,0,0,.6), 0 24px 64px rgba(0,0,0,.45);
  color-scheme: dark;
}

/* ==========================================================================
   2. RESET & BASE
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important; scroll-behavior: auto !important;
  }
}

body {
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.75;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  font-feature-settings: "kern", "liga";
  transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease);
}

img, svg, video, canvas { display: block; max-width: 100%; height: auto; }
img { background-color: var(--bg-sunken); }
svg { fill: currentColor; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
table { border-collapse: collapse; width: 100%; }
hr { border: 0; border-top: 1px solid var(--line); }

::selection { background: var(--gold-200); color: var(--ink-950); }

:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--r-xs);
}

.skip-link {
  position: absolute; inset-inline-start: -9999px; top: 0; z-index: 10000;
  background: var(--ink-900); color: var(--gold-300);
  padding: 12px 20px; border-radius: 0 0 var(--r-md) var(--r-md); font-weight: 600;
}
.skip-link:focus { inset-inline-start: 16px; }

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

/* ==========================================================================
   3. LAYOUT
   ========================================================================== */
.wrap      { width: 100%; max-width: var(--wrap);      margin-inline: auto; padding-inline: var(--sp-5); }
.wrap-wide { width: 100%; max-width: var(--wrap-wide); margin-inline: auto; padding-inline: var(--sp-5); }
.wrap-text { width: 100%; max-width: var(--wrap-text); margin-inline: auto; padding-inline: var(--sp-5); }
@media (max-width: 640px) { .wrap, .wrap-wide, .wrap-text { padding-inline: var(--sp-4); } }

.section        { padding-block: clamp(56px, 8vw, 112px); }
.section--tight { padding-block: clamp(40px, 5vw, 64px); }
.section--sunken  { background: var(--bg-sunken); }
.section--raised  { background: var(--bg-raised); }
.section--inverse { background: var(--bg-inverse); color: var(--text-inverse); }
.section--inverse :is(h1,h2,h3,h4) { color: inherit; }
.section--inverse .section-lede { color: rgba(255,255,255,.72); }
[data-theme="dark"] .section--inverse .section-lede { color: var(--ink-600); }

.grid { display: grid; gap: var(--sp-5); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); }
.stack > * + * { margin-block-start: var(--sp-4); }
.cluster { display: flex; flex-wrap: wrap; gap: var(--sp-3); align-items: center; }

/* ==========================================================================
   4. TYPOGRAPHY
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.005em;
  color: var(--text);
  text-wrap: balance;
}
h1 { font-size: var(--step-5); }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-3); }
h4 { font-size: var(--step-2); }
h5 { font-size: var(--step-1); }
h6 { font-size: var(--step-0); }

/* Arabic sets tighter and wants more leading than the Latin serif */
[dir="rtl"] :is(h1,h2,h3,h4,h5,h6),
:lang(ar) :is(h1,h2,h3,h4,h5,h6) { line-height: 1.35; letter-spacing: 0; }

p { text-wrap: pretty; }
p + p { margin-block-start: 1em; }

.lede { font-size: var(--step-1); line-height: 1.65; color: var(--text-soft); }

/* Eyebrow — a small-caps rule, not a pill */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-body);
  font-size: var(--step--2); font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--accent-text);
  margin-block-end: var(--sp-3);
}
.eyebrow::before { content: ""; inline-size: 28px; block-size: 2px; background: var(--accent); flex: none; }
.section--inverse .eyebrow { color: var(--gold-400); }
.section--inverse .eyebrow::before { background: var(--gold-400); }

.section-head { max-width: 60ch; margin-block-end: var(--sp-7); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .eyebrow { justify-content: center; }
.section-lede { font-size: var(--step-1); color: var(--text-soft); margin-block-start: var(--sp-3); }

.section-head-row {
  display: flex; flex-wrap: wrap; gap: var(--sp-5);
  align-items: flex-end; justify-content: space-between;
  margin-block-end: var(--sp-7);
}

/* Gold accent inside a heading — an underline, never a fill */
.gilt {
  color: var(--accent-text);
  background-image: linear-gradient(var(--gold-300), var(--gold-300));
  background-repeat: no-repeat;
  background-position: 0 92%;
  background-size: 100% .12em;
  padding-inline: .06em;
}
.section--inverse .gilt { color: var(--gold-300); background-image: linear-gradient(var(--gold-600), var(--gold-600)); }

/* Figures set in mono — the ledger feel */
.num { font-family: var(--font-num); font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; letter-spacing: -.02em; }

/* Full-width page template: block alignments get the room they ask for. */
.byt-wide-page > :not(.alignfull):not(.alignwide) {
  width: 100%; max-width: var(--wrap); margin-inline: auto;
  padding-inline: var(--sp-5);
}
.byt-wide-page > .alignwide { width: 100%; max-width: var(--wrap-wide); margin-inline: auto; padding-inline: var(--sp-5); }
.byt-wide-page > .alignfull { width: 100%; max-width: none; }
.byt-wide-page { padding-block: var(--sp-7); }

.prose { max-width: var(--wrap-text); }
.prose :is(h2,h3,h4) { margin-block: 1.6em .5em; }
.prose p, .prose ul, .prose ol { margin-block-end: 1em; }
.prose ul, .prose ol { padding-inline-start: 1.4em; }
.prose ul { list-style: none; }
.prose ul > li { position: relative; padding-inline-start: 4px; }
.prose ul > li::before {
  content: ""; position: absolute; inset-inline-start: -1.1em; top: .68em;
  inline-size: 6px; block-size: 6px; background: var(--accent); border-radius: 1px; transform: rotate(45deg);
}
.prose ol { list-style: decimal; }
.prose ol > li::marker { color: var(--accent-text); font-family: var(--font-num); font-weight: 600; }
.prose a { color: var(--accent-text); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.prose a:hover { text-decoration-thickness: 2px; }
.prose blockquote {
  border-inline-start: 3px solid var(--accent);
  padding-inline-start: var(--sp-5); margin-block: var(--sp-5);
  font-family: var(--font-display); font-size: var(--step-1); font-style: italic; color: var(--text-soft);
}
.prose img { border-radius: var(--r-md); margin-block: var(--sp-5); }
.prose table { margin-block: var(--sp-5); font-size: var(--step--1); }
.prose :is(th,td) { border: 1px solid var(--line); padding: 10px 14px; text-align: start; }
.prose th { background: var(--bg-sunken); font-weight: 700; }

/* ==========================================================================
   5. BUTTONS
   ========================================================================== */
.btn {
  --btn-bg: var(--accent); --btn-fg: var(--on-accent); --btn-bd: var(--accent);
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 13px 26px;
  font-family: var(--font-body); font-size: var(--step--1); font-weight: 600; line-height: 1.2;
  letter-spacing: .01em;
  color: var(--btn-fg); background: var(--btn-bg);
  border: 1.5px solid var(--btn-bd); border-radius: var(--r-sm);
  cursor: pointer; white-space: nowrap; text-align: center;
  transition: transform .18s var(--ease), background-color var(--dur) var(--ease),
              color var(--dur) var(--ease), border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.btn:hover { transform: translateY(-1px); box-shadow: var(--sh-2); }
.btn:active { transform: translateY(0); box-shadow: none; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .5; pointer-events: none; }
.btn svg { inline-size: 18px; block-size: 18px; flex: none; }

.btn--primary { --btn-bg: var(--gold-500); --btn-bd: var(--gold-500); --btn-fg: var(--ink-950); }
.btn--primary:hover { --btn-bg: var(--gold-400); --btn-bd: var(--gold-400); }
.btn--ink { --btn-bg: var(--ink-900); --btn-bd: var(--ink-900); --btn-fg: var(--gold-200); }
.btn--ink:hover { --btn-bg: var(--ink-800); --btn-bd: var(--ink-800); }
.btn--outline { --btn-bg: transparent; --btn-bd: var(--line-strong); --btn-fg: var(--text); }
.btn--outline:hover { --btn-bd: var(--accent); --btn-fg: var(--accent-text); --btn-bg: transparent; box-shadow: none; }
.btn--ghost { --btn-bg: transparent; --btn-bd: transparent; --btn-fg: var(--text-soft); }
.btn--ghost:hover { --btn-fg: var(--accent-text); --btn-bg: var(--accent-soft); box-shadow: none; }
.btn--onink { --btn-bg: transparent; --btn-bd: rgba(255,255,255,.28); --btn-fg: #fff; }
.btn--onink:hover { --btn-bd: var(--gold-400); --btn-fg: var(--gold-300); }
.btn--wa { --btn-bg: var(--whatsapp); --btn-bd: var(--whatsapp); --btn-fg: #fff; }
.btn--wa:hover { --btn-bg: #1a924a; --btn-bd: #1a924a; }

.btn--sm { padding: 9px 16px; font-size: var(--step--2); gap: 7px; }
.btn--sm svg { inline-size: 15px; block-size: 15px; }
.btn--lg { padding: 16px 34px; font-size: var(--step-0); }
.btn--block { display: flex; inline-size: 100%; }

/* Text link with a rule that grows on hover */
.link-arrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 600; font-size: var(--step--1); color: var(--accent-text);
  padding-block-end: 3px; border-block-end: 1.5px solid transparent;
  transition: border-color var(--dur) var(--ease), gap var(--dur) var(--ease);
}
.link-arrow:hover { border-block-end-color: currentColor; gap: 13px; }
.link-arrow svg { inline-size: 16px; block-size: 16px; flex: none; }
[dir="rtl"] .link-arrow svg { transform: scaleX(-1); }

/* ==========================================================================
   6. FORMS
   ========================================================================== */
.field { display: flex; flex-direction: column; gap: 7px; }
.field > label, .form-label {
  font-size: var(--step--2); font-weight: 600; color: var(--text-soft);
  letter-spacing: .04em; text-transform: uppercase;
}
.input, .select, .textarea,
input[type="text"], input[type="tel"], input[type="email"],
input[type="number"], input[type="search"], input[type="url"],
input[type="date"], select, textarea {
  inline-size: 100%;
  padding: 12px 14px;
  font-family: var(--font-body); font-size: var(--step--1);
  color: var(--text); background: var(--bg-raised);
  border: 1.5px solid var(--line); border-radius: var(--r-sm);
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
textarea { min-block-size: 110px; resize: vertical; line-height: 1.6; }
:is(.input, .select, .textarea, input, select, textarea):focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}
:is(input, textarea)::placeholder { color: var(--text-mute); opacity: 1; }
select {
  appearance: none; padding-inline-end: 40px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23766B56' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-size: 17px;
  background-position: right 13px center;
}
[dir="rtl"] select { background-position: left 13px center; }
[data-theme="dark"] select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239C9280' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
}
.field-hint  { font-size: var(--step--2); color: var(--text-mute); }
.field-error { font-size: var(--step--2); color: var(--bad); font-weight: 600; }
.is-invalid { border-color: var(--bad) !important; }

/* The visible track is a 4px rule, but the input itself is 32px tall so a
   finger has something to land on. Styling the element to 4px would leave a
   4px hit area — unusable on a phone. */
input[type="range"] {
  inline-size: 100%; block-size: 32px; padding: 0; border: 0; margin: 0;
  appearance: none; background: transparent; cursor: pointer;
}
input[type="range"]::-webkit-slider-runnable-track {
  block-size: 4px; background: var(--line); border-radius: var(--r-pill);
}
input[type="range"]::-webkit-slider-thumb {
  appearance: none; inline-size: 22px; block-size: 22px; border-radius: 50%;
  background: var(--gold-500); border: 3px solid var(--bg-raised); box-shadow: var(--sh-2);
  cursor: grab; margin-block-start: -9px; /* centre the thumb on the track */
}
input[type="range"]::-moz-range-track {
  block-size: 4px; background: var(--line); border-radius: var(--r-pill);
}
input[type="range"]::-moz-range-thumb {
  inline-size: 22px; block-size: 22px; border-radius: 50%; border: 3px solid var(--bg-raised);
  background: var(--gold-500); box-shadow: var(--sh-2); cursor: grab;
}
input[type="range"]:focus-visible { outline-offset: 4px; }

.check { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-size: var(--step--1); }
.check input[type="checkbox"], .check input[type="radio"] {
  inline-size: 18px; block-size: 18px; margin-block-start: 3px; flex: none;
  accent-color: var(--gold-500); cursor: pointer;
}

.form-note { font-size: var(--step--2); color: var(--text-mute); line-height: 1.6; }
.form-status { padding: 12px 16px; border-radius: var(--r-sm); font-size: var(--step--1); font-weight: 600; }
.form-status--ok  { background: var(--ok-bg);  color: var(--ok);  border: 1px solid color-mix(in srgb, var(--ok) 25%, transparent); }
.form-status--bad { background: var(--bad-bg); color: var(--bad); border: 1px solid color-mix(in srgb, var(--bad) 25%, transparent); }

/* ==========================================================================
   7. HEADER
   ========================================================================== */
.site-header {
  position: sticky; top: 0; z-index: 900;
  background: color-mix(in srgb, var(--bg-raised) 94%, transparent);
  border-block-end: 1px solid var(--line-soft);
  transition: box-shadow var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
@supports (backdrop-filter: blur(4px)) { .site-header { backdrop-filter: saturate(1.4) blur(10px); } }
.site-header.is-stuck { box-shadow: var(--sh-2); border-block-end-color: var(--line); }

.header-bar { display: flex; align-items: center; gap: var(--sp-5); block-size: var(--header-h); }

/* -- Brand lockup: mark + wordmark set in the theme's own type ---------- */
.brand { display: inline-flex; align-items: center; gap: 11px; flex: none; }
.brand__mark { inline-size: 42px; block-size: 42px; object-fit: contain; background: none; flex: none; }
.brand__text { display: flex; flex-direction: column; line-height: 1; gap: 3px; }
.brand__ar {
  font-family: var(--font-body); font-size: 18px; font-weight: 700;
  color: var(--text); letter-spacing: -.01em; white-space: nowrap;
}
.brand__en {
  font-family: var(--font-body); font-size: 9px; font-weight: 600;
  letter-spacing: .22em; text-transform: uppercase; color: var(--accent-text); white-space: nowrap;
}
.brand__lockup { block-size: 46px; inline-size: auto; object-fit: contain; background: none; }
@media (max-width: 400px) { .brand__text { display: none; } }

/* -- Primary nav -- */
.nav-main { display: flex; align-items: center; gap: 2px; margin-inline-start: auto; }
.nav-main > li { position: relative; }
.nav-main a {
  position: relative; display: block;
  padding: 9px 14px; border-radius: var(--r-sm);
  font-size: var(--step--1); font-weight: 500; color: var(--text-soft); white-space: nowrap;
  transition: color var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
.nav-main a:hover { color: var(--text); background: var(--bg-sunken); }
.nav-main a.is-active { color: var(--accent-text); font-weight: 600; }
.nav-main > li > a.is-active::after {
  content: ""; position: absolute; inset-inline: 14px; inset-block-end: 2px;
  block-size: 2px; background: var(--accent); border-radius: 1px;
}
.nav-main .sub-menu {
  position: absolute; inset-block-start: calc(100% + 6px); inset-inline-start: 0;
  min-inline-size: 210px; padding: 6px;
  background: var(--bg-raised); border: 1px solid var(--line);
  border-radius: var(--r-md); box-shadow: var(--sh-3);
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease), visibility var(--dur);
}
.nav-main > li:hover > .sub-menu,
.nav-main > li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.nav-main .sub-menu a { padding: 9px 12px; }

.header-tools { display: flex; align-items: center; gap: var(--sp-2); flex: none; }

/* -- Icon buttons: language, theme, favourites, menu -- */
.icon-btn {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  min-inline-size: 40px; block-size: 40px; padding-inline: 10px;
  border: 1.5px solid var(--line); border-radius: var(--r-sm);
  color: var(--text-soft); background: transparent;
  transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
.icon-btn:hover { color: var(--accent-text); border-color: var(--accent); }
.icon-btn svg { inline-size: 18px; block-size: 18px; }
.icon-btn__label { font-size: var(--step--2); font-weight: 700; letter-spacing: .06em; }
.icon-btn[data-count]:not([data-count="0"])::after {
  content: attr(data-count);
  position: absolute; inset-block-start: -6px; inset-inline-end: -6px;
  min-inline-size: 18px; padding: 0 5px;
  font-family: var(--font-num); font-size: 10px; font-weight: 700; line-height: 17px;
  color: var(--ink-950); background: var(--gold-400);
  border: 1.5px solid var(--bg-raised);
  border-radius: var(--r-pill); text-align: center;
}

.nav-toggle { display: none; }
.nav-toggle__box { position: relative; inline-size: 18px; block-size: 12px; }
.nav-toggle__box span {
  position: absolute; inset-inline: 0; block-size: 2px; background: currentColor; border-radius: 2px;
  transition: transform var(--dur) var(--ease), opacity var(--dur) var(--ease);
}
.nav-toggle__box span:nth-child(1) { inset-block-start: 0; }
.nav-toggle__box span:nth-child(2) { inset-block-start: 5px; }
.nav-toggle__box span:nth-child(3) { inset-block-start: 10px; }
.nav-toggle[aria-expanded="true"] .nav-toggle__box span:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__box span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__box span:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

@media (max-width: 1080px) {
  .nav-main { display: none; }
  .nav-toggle { display: inline-flex; }
  .header-tools { margin-inline-start: auto; }
  .header-tools .btn { display: none; }
}

/* Between roughly 400 and 480px the wordmark and four tool buttons together
   outgrew the bar — the Plus/Max phone widths. Drop the favourites shortcut
   (it lives in the drawer) and tighten the buttons rather than losing the
   wordmark or the language switch. */
@media (max-width: 560px) {
  .header-bar { gap: var(--sp-3); }
  .brand { min-inline-size: 0; }
  .brand__mark { inline-size: 38px; block-size: 38px; }
  .brand__ar { font-size: 16px; }
  .brand__text { min-inline-size: 0; overflow: hidden; }
  .brand__ar, .brand__en { overflow: hidden; text-overflow: ellipsis; }
  .header-tools { gap: 5px; }
  .header-tools .icon-btn { min-inline-size: 38px; padding-inline: 7px; }
  .header-tools .icon-btn[data-byt-fav-count] { display: none; }
}

/* -- Mobile drawer -- */
.drawer {
  position: fixed; inset-block: 0; inset-inline-end: 0; z-index: 1000;
  inline-size: min(360px, 88vw);
  background: var(--bg-raised);
  border-inline-start: 1px solid var(--line);
  box-shadow: var(--sh-4);
  transform: translateX(100%);
  /* Hidden outright when closed, not merely pushed aside. Sliding it out by
     its own width leaves a sliver showing whenever the inset is offset by a
     scrollbar gutter — which is exactly what happens in RTL, where the
     scrollbar sits on the same edge the panel hides behind. */
  visibility: hidden;
  transition: transform .34s var(--ease), visibility .34s;
  display: flex; flex-direction: column;
  overflow-y: auto; overscroll-behavior: contain;
}
[dir="rtl"] .drawer { transform: translateX(-100%); }
.drawer.is-open { transform: translateX(0); visibility: visible; }
.drawer__head {
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-5); border-block-end: 1px solid var(--line-soft);
  position: sticky; inset-block-start: 0; background: var(--bg-raised); z-index: 1;
}
.drawer__body { padding: var(--sp-5); display: flex; flex-direction: column; gap: var(--sp-5); }
.drawer__nav { display: flex; flex-direction: column; }
.drawer__nav a {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 4px; font-size: var(--step-0); font-weight: 500;
  color: var(--text); border-block-end: 1px solid var(--line-soft);
}
.drawer__nav a.is-active { color: var(--accent-text); font-weight: 700; }
.drawer__nav .sub-menu a { padding-inline-start: var(--sp-5); font-size: var(--step--1); color: var(--text-soft); }
.drawer-scrim {
  position: fixed; inset: 0; z-index: 999;
  background: rgba(16,14,9,.5);
  opacity: 0; visibility: hidden; transition: opacity var(--dur) var(--ease), visibility var(--dur);
}
.drawer-scrim.is-open { opacity: 1; visibility: visible; }

/* ==========================================================================
   8. FOOTER
   ========================================================================== */
.site-footer {
  background: var(--ink-950); color: var(--ink-300);
  padding-block-start: clamp(48px, 6vw, 80px);
  border-block-start: 3px solid var(--gold-500);
}
.site-footer h4 {
  font-family: var(--font-body); font-size: var(--step--2); font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase; color: var(--gold-300);
  margin-block-end: var(--sp-4);
}
/* One column by default. A hard 260px + 160px minimum would overflow a
   320px phone before any auto-fit had a chance to drop a column. */
.footer-grid {
  display: grid;
  gap: var(--sp-6);
  grid-template-columns: 1fr;
  padding-block-end: var(--sp-7);
}
@media (min-width: 560px) {
  .footer-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: var(--sp-7); }
}
@media (min-width: 900px) {
  .footer-grid { grid-template-columns: minmax(240px, 1.5fr) repeat(auto-fit, minmax(min(100%, 150px), 1fr)); }
}
.footer-brand__logo { block-size: 82px; inline-size: auto; margin-block-end: var(--sp-4); background: none; }
.footer-about { font-size: var(--step--1); line-height: 1.85; color: var(--ink-400); max-width: 46ch; }
.footer-links { display: flex; flex-direction: column; gap: 11px; }
.footer-links a { font-size: var(--step--1); color: var(--ink-300); transition: color var(--dur) var(--ease); }
.footer-links a:hover { color: var(--gold-300); }

.footer-contact { display: flex; flex-direction: column; gap: 13px; }
.footer-contact__row { display: flex; align-items: flex-start; gap: 11px; font-size: var(--step--1); color: var(--ink-300); }
.footer-contact__row svg { inline-size: 17px; block-size: 17px; flex: none; margin-block-start: 4px; color: var(--gold-500); }
.footer-contact__row a:hover { color: var(--gold-300); }

.socials { display: flex; gap: var(--sp-2); margin-block-start: var(--sp-5); }
.socials a {
  display: inline-flex; align-items: center; justify-content: center;
  inline-size: 38px; block-size: 38px;
  border: 1px solid rgba(255,255,255,.14); border-radius: var(--r-sm);
  color: var(--ink-300);
  transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
.socials a:hover { color: var(--ink-950); background: var(--gold-400); border-color: var(--gold-400); }
.socials svg { inline-size: 17px; block-size: 17px; }

.footer-bottom {
  border-block-start: 1px solid rgba(255,255,255,.09);
  padding-block: var(--sp-5);
  display: flex; flex-wrap: wrap; gap: var(--sp-4);
  align-items: center; justify-content: space-between;
  font-size: var(--step--2); color: var(--ink-500);
}
.footer-bottom a { color: var(--ink-400); }
.footer-bottom a:hover { color: var(--gold-300); }
.footer-bottom nav { display: flex; flex-wrap: wrap; gap: var(--sp-4); }

/* ==========================================================================
   9. UTILITIES
   ========================================================================== */
.text-center { text-align: center; }
.text-start  { text-align: start; }
.mt-0 { margin-block-start: 0; }
.mt-4 { margin-block-start: var(--sp-4); }
.mt-5 { margin-block-start: var(--sp-5); }
.mt-6 { margin-block-start: var(--sp-6); }
.mt-7 { margin-block-start: var(--sp-7); }
.mb-0 { margin-block-end: 0; }
.mb-5 { margin-block-end: var(--sp-5); }
.mb-6 { margin-block-end: var(--sp-6); }
.hide { display: none !important; }
@media (max-width: 768px) { .hide-sm { display: none !important; } }
@media (min-width: 769px) { .hide-lg { display: none !important; } }

/* Reveal on scroll — a short, restrained lift */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } }

/* Hairline rule with a gold lozenge — a print device between sections */
.rule { display: flex; align-items: center; gap: var(--sp-4); color: var(--line); }
.rule::before, .rule::after { content: ""; block-size: 1px; background: currentColor; flex: 1; }
.rule__tick { inline-size: 7px; block-size: 7px; background: var(--accent); transform: rotate(45deg); flex: none; }

.aspect-16-9 { aspect-ratio: 16/9; object-fit: cover; inline-size: 100%; }
.aspect-4-3  { aspect-ratio: 4/3;  object-fit: cover; inline-size: 100%; }
.aspect-1-1  { aspect-ratio: 1/1;  object-fit: cover; inline-size: 100%; }

/* Print */
@media print {
  .site-header, .site-footer, .drawer, .drawer-scrim, .byt-chat, .sticky-cta,
  .to-top, .compare-tray { display: none !important; }
  body { background: #fff; color: #000; font-size: 11pt; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 9pt; color: #555; }
}
