@charset "UTF-8";
/* ==========================================================================
   بيوت العقارية — components.css
   Cards, hero, search, filters, calculator, compare, gallery, modals.
   ========================================================================== */

/* ==========================================================================
   1. HERO
   ========================================================================== */
.hero {
  position: relative;
  min-block-size: clamp(520px, 78vh, 760px);
  display: grid; align-items: center;
  background: var(--ink-950);
  overflow: hidden;
  isolation: isolate;
}
.hero__media { position: absolute; inset: 0; z-index: -2; }
.hero__media img, .hero__media video {
  inline-size: 100%; block-size: 100%; object-fit: cover;
  opacity: .5;
}
/* Ink veil + a single gold hairline at the base — no glow */
.hero__media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(to top, var(--ink-950) 2%, rgba(16,14,9,.72) 42%, rgba(16,14,9,.44) 100%);
}
.hero::after {
  content: ""; position: absolute; inset-inline: 0; inset-block-end: 0; block-size: 3px;
  background: linear-gradient(90deg, transparent, var(--gold-500) 30%, var(--gold-300) 50%, var(--gold-500) 70%, transparent);
  z-index: 2;
}
.hero__inner { position: relative; z-index: 1; padding-block: clamp(64px, 10vw, 120px); }
.hero__body { max-width: 62ch; }
.hero .eyebrow { color: var(--gold-300); }
.hero .eyebrow::before { background: var(--gold-400); }
.hero h1 { color: #fff; margin-block-end: var(--sp-5); }
.hero__lede { font-size: var(--step-1); line-height: 1.7; color: rgba(255,255,255,.8); max-width: 54ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--sp-3); margin-block-start: var(--sp-6); }

/* Hero facts — a ruled row, like a masthead strip */
.hero__facts {
  display: flex; flex-wrap: wrap; gap: var(--sp-6);
  margin-block-start: var(--sp-7); padding-block-start: var(--sp-5);
  border-block-start: 1px solid rgba(255,255,255,.16);
}
.hero__fact { display: flex; flex-direction: column; gap: 2px; }
.hero__fact dt { order: 2; font-size: var(--step--2); letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.55); }
.hero__fact dd { order: 1; font-family: var(--font-num); font-size: var(--step-2); font-weight: 600; color: var(--gold-300); line-height: 1.1; }

/* Page banner — the compact hero used on interior pages */
.banner {
  position: relative; background: var(--ink-900); color: #fff;
  padding-block: clamp(52px, 7vw, 88px); overflow: hidden; isolation: isolate;
}
.banner__media { position: absolute; inset: 0; z-index: -1; }
.banner__media img { inline-size: 100%; block-size: 100%; object-fit: cover; opacity: .34; }
.banner__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(16,14,9,.94), rgba(16,14,9,.62)); }
.banner h1 { color: #fff; margin-block: var(--sp-2) var(--sp-3); }
.banner__lede { color: rgba(255,255,255,.74); max-width: 62ch; font-size: var(--step-0); }
.banner::after {
  content: ""; position: absolute; inset-inline: 0; inset-block-end: 0;
  block-size: 3px; background: var(--gold-500);
}

/* Breadcrumb */
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: var(--step--2); color: var(--text-mute); }
.banner .crumbs { color: rgba(255,255,255,.6); }
.crumbs a { color: inherit; transition: color var(--dur) var(--ease); }
.crumbs a:hover { color: var(--accent-text); }
.banner .crumbs a:hover { color: var(--gold-300); }
.crumbs__sep { opacity: .5; }
.crumbs [aria-current] { color: var(--text-soft); font-weight: 600; }
.banner .crumbs [aria-current] { color: var(--gold-300); }

/* ==========================================================================
   2. CARD — the workhorse listing card
   ========================================================================== */
.card {
  position: relative; display: flex; flex-direction: column;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.card:hover { transform: translateY(-3px); box-shadow: var(--sh-3); border-color: var(--line-strong); }

.card__media { position: relative; overflow: hidden; background: var(--bg-sunken); }
.card__media img { aspect-ratio: 4/3; inline-size: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.card:hover .card__media img { transform: scale(1.045); }
.card__media--tall img { aspect-ratio: 3/4; }

/* Placeholder when a listing has no photo yet — the mark on ink, not a stock image */
.card__media--empty {
  aspect-ratio: 4/3; display: grid; place-items: center;
  background: var(--ink-900);
}
.card__media--empty img { aspect-ratio: auto; inline-size: 42%; max-inline-size: 120px; opacity: .3; background: none; }

.card__badges { position: absolute; inset-block-start: 12px; inset-inline-start: 12px; display: flex; flex-wrap: wrap; gap: 6px; z-index: 2; }
.card__tools   { position: absolute; inset-block-start: 12px; inset-inline-end: 12px; display: flex; flex-direction: column; gap: 6px; z-index: 2; }

.card__body { display: flex; flex-direction: column; gap: var(--sp-3); padding: var(--sp-5); flex: 1; }
.card__kicker { font-size: var(--step--2); font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--accent-text); }
.card__title { font-size: var(--step-1); line-height: 1.35; margin: 0; }
.card__title a { transition: color var(--dur) var(--ease); }
.card__title a:hover { color: var(--accent-text); }
/* Stretched link: the whole card is clickable, tools stay clickable above it */
.card__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.card__meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: var(--step--2); color: var(--text-mute); }
.card__meta span { display: inline-flex; align-items: center; gap: 5px; }
.card__meta svg { inline-size: 14px; block-size: 14px; flex: none; opacity: .75; }
.card__excerpt { font-size: var(--step--1); color: var(--text-soft); line-height: 1.65; }

.card__foot {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-3);
  padding: var(--sp-4) var(--sp-5);
  border-block-start: 1px solid var(--line-soft);
  background: var(--bg-sunken);
  margin-block-start: auto;
}
.card__price { display: flex; flex-direction: column; gap: 1px; }
.card__price small { font-size: var(--step--2); color: var(--text-mute); }
.card__price b {
  font-family: var(--font-num); font-size: var(--step-1); font-weight: 600;
  color: var(--text); letter-spacing: -.02em; line-height: 1.2;
}
.card__price b .cur { font-size: .62em; font-weight: 500; color: var(--text-mute); margin-inline-start: 3px; }

/* When the prices were last checked. Property listings go stale fast, and a
   visible review date is the difference between a maintained site and one
   that was generated and abandoned. */
.card__checked {
  display: flex; align-items: center; gap: 6px;
  font-size: var(--step--2); color: var(--text-mute);
}
.card__checked::before {
  content: ""; inline-size: 5px; block-size: 5px; flex: none;
  background: var(--ok); border-radius: 50%;
}

/* ---- Wide card: the lead listing laid on its side, spanning two columns.
   A grid where every cell is identical is the shape a generator produces. --- */
@media (min-width: 900px) {
  .card--wide { grid-column: span 2; }
  .card--wide .card__media img { block-size: 100%; aspect-ratio: auto; }
  .card--wide {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    grid-template-areas:
      "media body"
      "media specs"
      "media foot";
    grid-template-rows: 1fr auto auto;
  }
  .card--wide .card__media { grid-area: media; }
  .card--wide .card__body  { grid-area: body; padding-block-end: var(--sp-3); }
  .card--wide .card__specs { grid-area: specs; border-block-start: 0; }
  .card--wide .card__foot  { grid-area: foot; }
  .card--wide .card__title { font-size: var(--step-2); }
  .card--wide .card__excerpt { display: block; }
}
/* On one- and two-column grids it is just a normal card again. */
@media (max-width: 899px) { .card--wide { grid-column: auto; } }

/* Spec strip inside a card — 3 ruled cells */
.card__specs {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border-block-start: 1px solid var(--line-soft);
}
.card__specs div {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 11px 6px; text-align: center;
}
.card__specs div + div { border-inline-start: 1px solid var(--line-soft); }
.card__specs dt { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--text-mute); }
.card__specs dd { font-family: var(--font-num); font-size: var(--step--1); font-weight: 600; color: var(--text); }

/* ==========================================================================
   3. BADGES & PILLS
   ========================================================================== */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px;
  font-size: var(--step--2); font-weight: 700; letter-spacing: .04em;
  border-radius: var(--r-xs);
  background: var(--ink-900); color: var(--gold-200);
  white-space: nowrap;
}
.badge--gold    { background: var(--gold-500); color: var(--ink-950); }
.badge--ok      { background: var(--ok-bg);   color: var(--ok); }
.badge--warn    { background: var(--warn-bg); color: var(--warn); }
.badge--bad     { background: var(--bad-bg);  color: var(--bad); }
.badge--info    { background: var(--info-bg); color: var(--info); }
.badge--quiet   { background: var(--bg-sunken); color: var(--text-soft); border: 1px solid var(--line); }
.badge--outline { background: transparent; color: var(--accent-text); border: 1px solid var(--accent); }
.badge svg { inline-size: 12px; block-size: 12px; }

.pill {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 14px;
  font-size: var(--step--2); font-weight: 600;
  color: var(--text-soft); background: var(--bg-sunken);
  border: 1px solid var(--line); border-radius: var(--r-pill);
  transition: all var(--dur) var(--ease);
}
a.pill:hover, button.pill:hover { color: var(--accent-text); border-color: var(--accent); background: var(--accent-soft); }
.pill.is-on { background: var(--ink-900); color: var(--gold-200); border-color: var(--ink-900); }
.pill svg { inline-size: 14px; block-size: 14px; }

/* Round tool button that sits on a card (favourite / compare) */
.tool-btn {
  display: inline-flex; align-items: center; justify-content: center;
  inline-size: 34px; block-size: 34px;
  color: var(--ink-800); background: rgba(255,255,255,.94);
  border: 1px solid rgba(26,23,18,.1); border-radius: var(--r-sm);
  box-shadow: var(--sh-1);
  transition: all var(--dur) var(--ease);
}
.tool-btn:hover { color: var(--gold-700); background: #fff; transform: scale(1.06); }
.tool-btn svg { inline-size: 17px; block-size: 17px; }
.tool-btn.is-on { background: var(--gold-500); color: var(--ink-950); border-color: var(--gold-500); }
.tool-btn.is-on svg { fill: currentColor; }

/* ==========================================================================
   4. SEARCH & FILTER BAR
   ========================================================================== */
.searchbar {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-3);
  padding: var(--sp-5);
}
/* Lifted over the hero */
.searchbar--float { margin-block-start: -64px; position: relative; z-index: 5; }
@media (max-width: 900px) { .searchbar--float { margin-block-start: var(--sp-6); } }

.searchbar__grid {
  display: grid; gap: var(--sp-3);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 160px), 1fr));
  align-items: end;
}
.searchbar__grid .btn { block-size: 46px; }
.searchbar__tabs { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin-block-end: var(--sp-4); }

.filters {
  display: flex; flex-wrap: wrap; gap: var(--sp-3);
  align-items: center;
  padding-block: var(--sp-4);
  border-block: 1px solid var(--line);
  margin-block-end: var(--sp-6);
}
.filters__label { font-size: var(--step--2); font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--text-mute); }
.filters select, .filters input { inline-size: auto; min-inline-size: 150px; padding-block: 9px; }
.filters__spacer { margin-inline-start: auto; }

.result-count { font-size: var(--step--1); color: var(--text-soft); }
.result-count b { font-family: var(--font-num); color: var(--text); }

/* Chips showing the filters currently applied */
.active-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-block-end: var(--sp-5); }
.chip {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 5px 8px 5px 12px;
  font-size: var(--step--2); font-weight: 600;
  background: var(--accent-soft); color: var(--accent-text);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  border-radius: var(--r-sm);
}
[dir="rtl"] .chip { padding: 5px 12px 5px 8px; }
.chip button { display: inline-flex; color: inherit; opacity: .65; }
.chip button:hover { opacity: 1; }
.chip svg { inline-size: 13px; block-size: 13px; }

/* Loading state for AJAX result grids */
.is-loading { position: relative; min-block-size: 200px; opacity: .45; pointer-events: none; }
.skeleton {
  background: linear-gradient(90deg, var(--bg-sunken) 25%, var(--line-soft) 50%, var(--bg-sunken) 75%);
  background-size: 200% 100%;
  animation: byt-shimmer 1.4s linear infinite;
  border-radius: var(--r-md);
}
@keyframes byt-shimmer { to { background-position: -200% 0; } }
.skeleton-card { block-size: 380px; }

/* ==========================================================================
   5. STAT / FACT BLOCKS
   ========================================================================== */
.stats { display: grid; gap: 1px; background: var(--line); grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.stat { background: var(--bg-raised); padding: var(--sp-5) var(--sp-4); text-align: center; }
.stat__num { font-family: var(--font-num); font-size: var(--step-3); font-weight: 600; color: var(--accent-text); line-height: 1.1; letter-spacing: -.03em; }
.stat__label { font-size: var(--step--2); color: var(--text-mute); letter-spacing: .06em; text-transform: uppercase; margin-block-start: 6px; }
.section--inverse .stats { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.12); }
.section--inverse .stat { background: var(--bg-inverse); }
.section--inverse .stat__num { color: var(--gold-300); }
.section--inverse .stat__label { color: rgba(255,255,255,.55); }

/* Numbered feature list — the "why us" block, set like a contents page */
.ledger { display: grid; gap: 1px; background: var(--line); border-block: 1px solid var(--line); }
.ledger__row {
  display: grid; gap: var(--sp-4) var(--sp-5);
  grid-template-columns: 56px 1fr;
  align-items: start;
  padding: var(--sp-5) var(--sp-2);
  background: var(--bg);
}
.ledger__no { font-family: var(--font-num); font-size: var(--step-1); font-weight: 600; color: var(--accent); letter-spacing: -.02em; }
.ledger__title { font-family: var(--font-display); font-size: var(--step-2); margin-block-end: 6px; }
.ledger__text { font-size: var(--step--1); color: var(--text-soft); line-height: 1.7; max-width: 62ch; }
@media (min-width: 900px) { .ledger__row { grid-template-columns: 56px 1fr 1.4fr; align-items: baseline; } .ledger__title { margin: 0; } }

/* Icon feature tile */
.feature { display: flex; flex-direction: column; gap: var(--sp-3); padding: var(--sp-5); background: var(--bg-raised); border: 1px solid var(--line); border-radius: var(--r-md); }
.feature__icon {
  display: inline-flex; align-items: center; justify-content: center;
  inline-size: 46px; block-size: 46px;
  color: var(--accent-text); background: var(--accent-soft);
  border-radius: var(--r-sm);
}
.feature__icon svg { inline-size: 23px; block-size: 23px; }
.feature h3 { font-size: var(--step-1); }
.feature p { font-size: var(--step--1); color: var(--text-soft); }

/* ==========================================================================
   6. AMENITIES
   ========================================================================== */
.amenities { display: grid; gap: var(--sp-3); grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr)); }
.amenity {
  display: flex; align-items: center; gap: 11px;
  padding: 13px 15px;
  font-size: var(--step--1); font-weight: 500;
  background: var(--bg-raised); border: 1px solid var(--line); border-radius: var(--r-sm);
}
.amenity svg { inline-size: 19px; block-size: 19px; flex: none; color: var(--accent); }

/* ==========================================================================
   7. SPEC TABLE (key/value list on a single listing)
   ========================================================================== */
.spec-table { border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; background: var(--bg-raised); }
.spec-table__row { display: grid; grid-template-columns: minmax(120px, 38%) 1fr; gap: var(--sp-4); padding: 14px var(--sp-5); }
.spec-table__row + .spec-table__row { border-block-start: 1px solid var(--line-soft); }
.spec-table__row:nth-child(odd) { background: var(--bg-sunken); }
.spec-table dt { font-size: var(--step--1); color: var(--text-mute); }
.spec-table dd { font-size: var(--step--1); font-weight: 600; color: var(--text); }
.spec-table dd.num { font-family: var(--font-num); }

/* Data table (unit types, payment plans) */
.data-table { border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; background: var(--bg-raised); }
.data-table table { font-size: var(--step--1); }
.data-table :is(th, td) { padding: 13px var(--sp-4); text-align: start; }
.data-table th {
  background: var(--ink-900); color: var(--gold-200);
  font-size: var(--step--2); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap;
}
.data-table td { border-block-start: 1px solid var(--line-soft); }
.data-table tbody tr:nth-child(even) td { background: var(--bg-sunken); }
.data-table tbody tr:hover td { background: var(--accent-soft); }
.data-table .num { font-family: var(--font-num); font-weight: 600; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ==========================================================================
   8. STICKY SIDEBAR (single listing)
   ========================================================================== */
.listing-layout { display: grid; gap: var(--sp-7); align-items: start; }
@media (min-width: 1000px) { .listing-layout { grid-template-columns: minmax(0, 1fr) 360px; } }

.side-card {
  background: var(--bg-raised); border: 1px solid var(--line);
  border-radius: var(--r-md); box-shadow: var(--sh-2); overflow: hidden;
}
.side-card__head { padding: var(--sp-5); background: var(--ink-900); color: #fff; }
.side-card__head .label { font-size: var(--step--2); letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.6); }
.side-card__head .price { font-family: var(--font-num); font-size: var(--step-3); font-weight: 600; color: var(--gold-300); line-height: 1.2; letter-spacing: -.03em; }
.side-card__body { padding: var(--sp-5); display: flex; flex-direction: column; gap: var(--sp-4); }
@media (min-width: 1000px) { .side-sticky { position: sticky; inset-block-start: calc(var(--header-h) + 24px); } }

/* Consultant strip */
.consultant { display: flex; align-items: center; gap: var(--sp-3); padding-block-end: var(--sp-4); border-block-end: 1px solid var(--line-soft); }
.consultant img, .consultant__avatar {
  inline-size: 48px; block-size: 48px; border-radius: 50%; object-fit: cover; flex: none;
  display: grid; place-items: center;
  background: var(--ink-900); color: var(--gold-300);
  font-family: var(--font-display); font-size: 19px; font-weight: 700;
}
.consultant strong { display: block; font-size: var(--step--1); }
.consultant span { font-size: var(--step--2); color: var(--text-mute); }

/* ==========================================================================
   9. GALLERY
   ========================================================================== */
.gallery { display: grid; gap: var(--sp-2); grid-template-columns: repeat(4, 1fr); }
.gallery__item { position: relative; overflow: hidden; border-radius: var(--r-sm); cursor: zoom-in; background: var(--bg-sunken); }
.gallery__item img { inline-size: 100%; block-size: 100%; aspect-ratio: 1; object-fit: cover; transition: transform .6s var(--ease); }
.gallery__item:hover img { transform: scale(1.05); }
.gallery__item:first-child { grid-column: span 2; grid-row: span 2; }
.gallery__item:first-child img { aspect-ratio: 1; }
.gallery__more {
  position: absolute; inset: 0; display: grid; place-items: center;
  background: rgba(16,14,9,.72); color: #fff;
  font-family: var(--font-num); font-size: var(--step-2); font-weight: 600;
}
@media (max-width: 700px) { .gallery { grid-template-columns: repeat(2, 1fr); } .gallery__item:first-child { grid-column: span 2; grid-row: auto; } }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 2000;
  display: grid; grid-template-rows: auto 1fr auto;
  background: rgba(10,9,6,.96);
  opacity: 0; visibility: hidden; transition: opacity var(--dur) var(--ease), visibility var(--dur);
}
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox__bar { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); padding: var(--sp-4) var(--sp-5); color: rgba(255,255,255,.75); font-size: var(--step--1); }
.lightbox__stage { display: grid; place-items: center; padding: var(--sp-4); min-block-size: 0; }
.lightbox__stage img { max-inline-size: 100%; max-block-size: 100%; object-fit: contain; border-radius: var(--r-sm); background: none; }
.lightbox__thumbs { display: flex; gap: 8px; padding: var(--sp-4); overflow-x: auto; justify-content: center; }
.lightbox__thumbs img { inline-size: 62px; block-size: 46px; object-fit: cover; border-radius: var(--r-xs); opacity: .45; cursor: pointer; transition: opacity var(--dur) var(--ease); }
.lightbox__thumbs img:hover, .lightbox__thumbs img.is-on { opacity: 1; outline: 2px solid var(--gold-400); }
.lightbox__nav {
  position: absolute; inset-block-start: 50%; transform: translateY(-50%);
  inline-size: 46px; block-size: 46px; display: grid; place-items: center;
  color: #fff; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.2); border-radius: 50%;
}
.lightbox__nav:hover { background: var(--gold-500); color: var(--ink-950); border-color: var(--gold-500); }
.lightbox__nav--prev { inset-inline-start: var(--sp-5); }
.lightbox__nav--next { inset-inline-end: var(--sp-5); }
.lightbox__nav svg { inline-size: 22px; block-size: 22px; }

/* ==========================================================================
   10. CALCULATOR
   ========================================================================== */
.calc { display: grid; gap: var(--sp-6); }
@media (min-width: 900px) { .calc { grid-template-columns: 1fr 380px; align-items: start; } }

.calc__controls { display: flex; flex-direction: column; gap: var(--sp-6); }
.calc__control { display: flex; flex-direction: column; gap: 11px; }
.calc__control-head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--sp-4); }
.calc__control-head label { font-size: var(--step--1); font-weight: 600; color: var(--text-soft); }
.calc__value { font-family: var(--font-num); font-size: var(--step-1); font-weight: 600; color: var(--accent-text); letter-spacing: -.02em; }
.calc__scale { display: flex; justify-content: space-between; font-family: var(--font-num); font-size: var(--step--2); color: var(--text-mute); }

.calc__out { background: var(--ink-900); color: #fff; border-radius: var(--r-md); overflow: hidden; }
.calc__out-head { padding: var(--sp-6) var(--sp-5); text-align: center; border-block-end: 1px solid rgba(255,255,255,.12); }
.calc__out-head .label { font-size: var(--step--2); letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.55); }
.calc__out-head .figure {
  font-family: var(--font-num); font-size: clamp(2rem, 5vw, 2.8rem); font-weight: 600;
  color: var(--gold-300); line-height: 1.1; letter-spacing: -.035em; margin-block: 8px 4px;
}
.calc__out-head .unit { font-size: var(--step--1); color: rgba(255,255,255,.6); }
.calc__breakdown { padding: var(--sp-4) var(--sp-5); display: flex; flex-direction: column; }
.calc__line { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); padding-block: 11px; font-size: var(--step--1); }
.calc__line + .calc__line { border-block-start: 1px solid rgba(255,255,255,.09); }
.calc__line span { color: rgba(255,255,255,.62); }
.calc__line b { font-family: var(--font-num); font-weight: 600; color: #fff; }
.calc__line--total b { color: var(--gold-300); font-size: var(--step-0); }
.calc__actions { padding: var(--sp-4) var(--sp-5) var(--sp-5); display: flex; flex-direction: column; gap: var(--sp-2); }

/* ==========================================================================
   11. COMPARE
   ========================================================================== */
.compare-tray {
  position: fixed; inset-inline: 0; inset-block-end: 0; z-index: 880;
  background: var(--ink-900); color: #fff;
  border-block-start: 2px solid var(--gold-500);
  transform: translateY(105%); transition: transform .34s var(--ease);
  box-shadow: 0 -8px 32px rgba(0,0,0,.28);
}
.compare-tray.is-open { transform: translateY(0); }
.compare-tray__inner { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-4); padding-block: var(--sp-3); }
.compare-tray__label { font-size: var(--step--2); font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--gold-300); }
.compare-tray__slots { display: flex; gap: var(--sp-2); flex: 1; flex-wrap: wrap; }
.compare-slot {
  display: flex; align-items: center; gap: 9px;
  min-inline-size: 150px; padding: 7px 11px;
  font-size: var(--step--2);
  background: rgba(255,255,255,.07); border: 1px dashed rgba(255,255,255,.22); border-radius: var(--r-sm);
  color: rgba(255,255,255,.45);
}
.compare-slot.is-filled { border-style: solid; border-color: rgba(255,255,255,.28); color: #fff; }
.compare-slot img { inline-size: 34px; block-size: 26px; object-fit: cover; border-radius: var(--r-xs); flex: none; }
.compare-slot span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-inline-size: 140px; }
.compare-slot button { color: rgba(255,255,255,.55); display: inline-flex; margin-inline-start: auto; }
.compare-slot button:hover { color: #fff; }
.compare-slot svg { inline-size: 14px; block-size: 14px; }

.compare-grid { overflow-x: auto; }
.compare-grid table { min-inline-size: 640px; }
.compare-grid :is(th, td) { padding: 14px var(--sp-4); text-align: start; border: 1px solid var(--line); vertical-align: top; font-size: var(--step--1); }
.compare-grid thead th { background: var(--ink-900); color: #fff; }
.compare-grid tbody th { background: var(--bg-sunken); font-weight: 600; color: var(--text-soft); white-space: nowrap; }
.compare-grid img { inline-size: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: var(--r-sm); margin-block-end: 10px; }
.compare-grid .is-best { background: var(--accent-soft); font-weight: 700; }

/* ==========================================================================
   12. MODAL
   ========================================================================== */
.modal {
  position: fixed; inset: 0; z-index: 1200;
  display: grid; place-items: center; padding: var(--sp-4);
  background: rgba(16,14,9,.6);
  opacity: 0; visibility: hidden; transition: opacity var(--dur) var(--ease), visibility var(--dur);
}
.modal.is-open { opacity: 1; visibility: visible; }
.modal__panel {
  inline-size: min(520px, 100%); max-block-size: 90vh; overflow-y: auto;
  background: var(--bg-raised); border-radius: var(--r-lg); box-shadow: var(--sh-4);
  transform: translateY(14px) scale(.985); transition: transform var(--dur) var(--ease);
  position: relative;
}
.modal.is-open .modal__panel { transform: none; }
.modal__head { padding: var(--sp-6) var(--sp-6) var(--sp-4); border-block-end: 1px solid var(--line-soft); }
.modal__head h3 { font-size: var(--step-2); margin-block-end: 6px; }
.modal__head p { font-size: var(--step--1); color: var(--text-soft); }
.modal__body { padding: var(--sp-6); display: flex; flex-direction: column; gap: var(--sp-4); }
.modal__close {
  position: absolute; inset-block-start: var(--sp-4); inset-inline-end: var(--sp-4);
  inline-size: 34px; block-size: 34px; display: grid; place-items: center;
  color: var(--text-mute); border-radius: var(--r-sm);
}
.modal__close:hover { color: var(--text); background: var(--bg-sunken); }
.modal__close svg { inline-size: 18px; block-size: 18px; }

/* ==========================================================================
   13. TABS & ACCORDION
   ========================================================================== */
.tabs { display: flex; gap: 2px; border-block-end: 1px solid var(--line); margin-block-end: var(--sp-5); overflow-x: auto; }
.tabs button {
  padding: 12px 18px; white-space: nowrap;
  font-size: var(--step--1); font-weight: 600; color: var(--text-mute);
  border-block-end: 2px solid transparent; margin-block-end: -1px;
  transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.tabs button:hover { color: var(--text); }
.tabs button[aria-selected="true"] { color: var(--accent-text); border-block-end-color: var(--accent); }
.tab-panel[hidden] { display: none; }

.accordion { border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; background: var(--bg-raised); }
.accordion details + details { border-block-start: 1px solid var(--line-soft); }
.accordion summary {
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-5); cursor: pointer;
  font-size: var(--step-0); font-weight: 600; list-style: none;
  transition: background-color var(--dur) var(--ease);
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary:hover { background: var(--bg-sunken); }
.accordion summary::after {
  content: ""; inline-size: 10px; block-size: 10px; flex: none;
  border-inline-end: 2px solid var(--accent); border-block-end: 2px solid var(--accent);
  transform: rotate(45deg); transition: transform var(--dur) var(--ease);
  margin-block-end: 4px;
}
.accordion details[open] summary::after { transform: rotate(-135deg); margin-block: 4px 0; }
.accordion__body { padding: 0 var(--sp-5) var(--sp-5); font-size: var(--step--1); color: var(--text-soft); line-height: 1.75; }

/* ==========================================================================
   14. TIMELINE (payment plan / delivery)
   ========================================================================== */
.timeline { position: relative; padding-inline-start: 28px; }
.timeline::before { content: ""; position: absolute; inset-block: 8px; inset-inline-start: 6px; inline-size: 2px; background: var(--line); }
.timeline__item { position: relative; padding-block-end: var(--sp-5); }
.timeline__item::before {
  content: ""; position: absolute; inset-block-start: 7px; inset-inline-start: -28px;
  inline-size: 13px; block-size: 13px; background: var(--bg); border: 2.5px solid var(--accent); border-radius: 50%;
}
.timeline__item:last-child { padding-block-end: 0; }
.timeline__when { font-family: var(--font-num); font-size: var(--step--2); font-weight: 600; color: var(--accent-text); letter-spacing: .04em; }
.timeline__what { font-size: var(--step--1); color: var(--text-soft); margin-block-start: 3px; }
.timeline__what b { color: var(--text); }

/* ==========================================================================
   15. TESTIMONIALS
   ========================================================================== */
.quote {
  display: flex; flex-direction: column; gap: var(--sp-4);
  padding: var(--sp-6); background: var(--bg-raised);
  border: 1px solid var(--line); border-radius: var(--r-md);
  position: relative;
}
.quote::before {
  content: "\201C"; position: absolute; inset-block-start: 4px; inset-inline-end: 20px;
  font-family: var(--font-display); font-size: 84px; line-height: 1; color: var(--gold-200);
}
[dir="rtl"] .quote::before { content: "\201D"; }
.quote__text { font-size: var(--step-0); line-height: 1.8; color: var(--text-soft); position: relative; }
.quote__who { display: flex; align-items: center; gap: var(--sp-3); margin-block-start: auto; padding-block-start: var(--sp-4); border-block-start: 1px solid var(--line-soft); }
.quote__who img, .quote__avatar {
  inline-size: 42px; block-size: 42px; border-radius: 50%; object-fit: cover; flex: none;
  display: grid; place-items: center; background: var(--ink-900); color: var(--gold-300);
  font-family: var(--font-display); font-size: 17px; font-weight: 700;
}
.quote__who strong { display: block; font-size: var(--step--1); }
.quote__who span { font-size: var(--step--2); color: var(--text-mute); }
.stars { display: inline-flex; gap: 2px; color: var(--gold-500); }
.stars svg { inline-size: 15px; block-size: 15px; }

/* ==========================================================================
   16. PAGINATION
   ========================================================================== */
.pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-block-start: var(--sp-7); }
.pagination :is(a, span) {
  display: inline-flex; align-items: center; justify-content: center;
  min-inline-size: 42px; block-size: 42px; padding-inline: 13px;
  font-family: var(--font-num); font-size: var(--step--1); font-weight: 600;
  color: var(--text-soft); background: var(--bg-raised);
  border: 1px solid var(--line); border-radius: var(--r-sm);
  transition: all var(--dur) var(--ease);
}
.pagination a:hover { color: var(--accent-text); border-color: var(--accent); }
.pagination .current { background: var(--ink-900); color: var(--gold-200); border-color: var(--ink-900); }
.pagination .dots { border-color: transparent; background: none; }

/* ==========================================================================
   17. FLOATING UI
   ========================================================================== */
.to-top {
  position: fixed; inset-block-end: 24px; inset-inline-start: 24px; z-index: 850;
  inline-size: 44px; block-size: 44px;
  display: grid; place-items: center;
  color: var(--gold-200); background: var(--ink-900);
  border: 1px solid rgba(255,255,255,.14); border-radius: var(--r-sm);
  box-shadow: var(--sh-3);
  opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: opacity var(--dur) var(--ease), visibility var(--dur), transform var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--gold-500); color: var(--ink-950); }
.to-top svg { inline-size: 19px; block-size: 19px; }

/* Mobile action bar on a listing */
.sticky-cta {
  position: fixed; inset-inline: 0; inset-block-end: 0; z-index: 870;
  display: none; gap: var(--sp-2); padding: 10px var(--sp-4);
  padding-block-end: calc(10px + env(safe-area-inset-bottom, 0px));
  background: var(--bg-raised); border-block-start: 1px solid var(--line);
  box-shadow: 0 -4px 20px rgba(26,23,18,.1);
}
.sticky-cta .btn { flex: 1; }
@media (max-width: 999px) { .sticky-cta.is-on { display: flex; } body.has-sticky-cta { padding-block-end: 72px; } }

/* Reading progress rule under the header */
.progress-rule {
  position: fixed; inset-block-start: 0; inset-inline: 0; z-index: 950;
  block-size: 2px; background: var(--gold-500);
  transform-origin: 0 50%; transform: scaleX(0);
}
[dir="rtl"] .progress-rule { transform-origin: 100% 50%; }

/* Toast */
.toast-stack { position: fixed; inset-block-end: 24px; inset-inline-end: 24px; z-index: 1500; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 11px;
  padding: 13px 18px; max-inline-size: 340px;
  background: var(--ink-900); color: #fff;
  border-inline-start: 3px solid var(--gold-500);
  border-radius: var(--r-sm); box-shadow: var(--sh-4);
  font-size: var(--step--1);
  animation: byt-toast-in .3s var(--ease);
  pointer-events: auto;
}
.toast--ok  { border-inline-start-color: var(--ok); }
.toast--bad { border-inline-start-color: var(--bad); }
.toast svg { inline-size: 18px; block-size: 18px; flex: none; color: var(--gold-400); }
.toast--ok svg  { color: var(--ok); }
.toast--bad svg { color: var(--bad); }
.toast.is-out { animation: byt-toast-out .25s var(--ease) forwards; }
@keyframes byt-toast-in  { from { opacity: 0; transform: translateY(12px); } }
@keyframes byt-toast-out { to   { opacity: 0; transform: translateY(8px); } }

/* ==========================================================================
   18. EMPTY & 404
   ========================================================================== */
.empty { text-align: center; padding-block: var(--sp-9); }
.empty__mark { inline-size: 92px; margin-inline: auto; opacity: .28; margin-block-end: var(--sp-5); background: none; }
.empty h3 { font-size: var(--step-2); margin-block-end: var(--sp-3); }
.empty p { color: var(--text-soft); max-width: 46ch; margin-inline: auto; margin-block-end: var(--sp-5); }

.error-code {
  font-family: var(--font-num); font-size: clamp(5rem, 18vw, 11rem); font-weight: 600;
  line-height: .9; letter-spacing: -.06em; color: var(--gold-200);
}

/* ==========================================================================
   19. MAP & VIDEO EMBEDS
   ========================================================================== */
.embed { position: relative; border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--line); background: var(--bg-sunken); }
.embed iframe { display: block; inline-size: 100%; aspect-ratio: 16/9; border: 0; }
.embed--map iframe { aspect-ratio: 16/10; }
/* Click-to-load video facade — keeps YouTube off the critical path */
.video-facade { position: relative; cursor: pointer; }
.video-facade img { inline-size: 100%; aspect-ratio: 16/9; object-fit: cover; }
.video-facade__play {
  position: absolute; inset: 0; display: grid; place-items: center;
  background: rgba(16,14,9,.35); transition: background-color var(--dur) var(--ease);
}
.video-facade:hover .video-facade__play { background: rgba(16,14,9,.5); }
.video-facade__play span {
  inline-size: 68px; block-size: 68px; display: grid; place-items: center;
  background: var(--gold-500); color: var(--ink-950); border-radius: 50%;
  box-shadow: var(--sh-3);
}
.video-facade__play svg { inline-size: 26px; block-size: 26px; margin-inline-start: 3px; }
[dir="rtl"] .video-facade__play svg { transform: scaleX(-1); margin-inline: 0 3px; }

/* ==========================================================================
   20. NEWSLETTER
   ========================================================================== */
.newsletter { display: grid; gap: var(--sp-6); align-items: center; }
@media (min-width: 860px) { .newsletter { grid-template-columns: 1fr auto; } }
.newsletter__form { display: flex; flex-wrap: wrap; gap: var(--sp-2); min-inline-size: min(100%, 420px); }
.newsletter__form input { flex: 1; min-inline-size: 200px; }

/* ==========================================================================
   21. LOGO WALL (developers)
   ========================================================================== */
.logo-wall { display: grid; gap: 1px; background: var(--line); grid-template-columns: repeat(auto-fill, minmax(min(100%, 180px), 1fr)); border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.logo-wall a {
  display: grid; place-items: center; gap: 8px;
  padding: var(--sp-5) var(--sp-4); min-block-size: 118px;
  background: var(--bg-raised); text-align: center;
  transition: background-color var(--dur) var(--ease);
}
.logo-wall a:hover { background: var(--bg-sunken); }
.logo-wall img { max-block-size: 46px; inline-size: auto; object-fit: contain; filter: grayscale(1); opacity: .7; transition: all var(--dur) var(--ease); background: none; }
.logo-wall a:hover img { filter: none; opacity: 1; }
.logo-wall .name { font-size: var(--step--2); font-weight: 600; color: var(--text-soft); }
.logo-wall .count { font-family: var(--font-num); font-size: var(--step--2); color: var(--text-mute); }

/* ==========================================================================
   22. AREA TILE
   ========================================================================== */
.area-tile {
  position: relative; display: block; overflow: hidden;
  border-radius: var(--r-md); background: var(--ink-900); isolation: isolate;
  min-block-size: 260px;
}
.area-tile img { position: absolute; inset: 0; inline-size: 100%; block-size: 100%; object-fit: cover; opacity: .62; transition: transform .8s var(--ease), opacity var(--dur) var(--ease); }
.area-tile:hover img { transform: scale(1.06); opacity: .48; }
.area-tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(16,14,9,.94) 8%, rgba(16,14,9,.28) 62%); }
.area-tile__body { position: relative; z-index: 1; display: flex; flex-direction: column; justify-content: flex-end; block-size: 100%; min-block-size: 260px; padding: var(--sp-5); color: #fff; }
.area-tile__body h3 { color: #fff; font-size: var(--step-2); }
.area-tile__meta { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-block-start: 8px; font-size: var(--step--2); color: rgba(255,255,255,.72); }
.area-tile__meta b { font-family: var(--font-num); color: var(--gold-300); font-weight: 600; }
.area-tile--lg { min-block-size: 380px; }
.area-tile--lg .area-tile__body { min-block-size: 380px; }

/* ==========================================================================
   23. SPLIT FEATURE (image + copy)
   ========================================================================== */
.split { display: grid; gap: var(--sp-7); align-items: center; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; } .split--reverse > :first-child { order: 2; } }

/* A statement and its qualifier, set side by side rather than stacked —
   the heading keeps its own column so the line length stays short. */
.split--copy { align-items: start; gap: var(--sp-5) var(--sp-7); }
@media (min-width: 900px) { .split--copy { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); } }

/* The calculator's own heading, held to a readable measure above the tool. */
.calc-lead { max-width: 60ch; margin-block-end: var(--sp-6); }
.calc-lead h2 { font-size: var(--step-3); margin-block-end: var(--sp-3); }

/* ==========================================================================
   AREA SPLIT
   One tall tile for the lead city, the rest stacked beside it. A four-up row
   of identical tiles is the default every template lands on.
   ========================================================================== */
.area-split { display: grid; gap: var(--sp-4); }
.area-split__rest { display: grid; gap: var(--sp-4); grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }

@media (min-width: 900px) {
  .area-split { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.35fr); align-items: stretch; }
  .area-split > .reveal:first-child,
  .area-split > .reveal:first-child .area-tile { block-size: 100%; }
  .area-split__rest { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .area-split__rest .area-tile,
  .area-split__rest .area-tile__body { min-block-size: 0; block-size: 100%; }
}
.split__media { position: relative; border-radius: var(--r-md); overflow: hidden; }
.split__media img { inline-size: 100%; aspect-ratio: 4/3; object-fit: cover; }
/* A gold rule offset behind the image — a printed register mark */
.split__media::before {
  content: ""; position: absolute; inset-block: 18px; inset-inline-start: -10px;
  inline-size: 3px; background: var(--gold-500); z-index: 1;
}

/* ==========================================================================
   24. FIGURES STRIP
   A ruled typographic row rather than another grid of cards — the page needs
   at least one block that is set, not boxed.
   ========================================================================== */
.figures {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr));
  gap: var(--sp-5) var(--sp-7);
  border-block: 1px solid var(--line-strong);
  padding-block: var(--sp-6);
}
.figure-item { display: flex; flex-direction: column; gap: 4px; }
.figure-item__n {
  font-family: var(--font-num);
  font-size: clamp(2rem, 4vw, 2.9rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -.04em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.figure-item__n sup {
  font-size: .42em; font-weight: 600; letter-spacing: 0;
  color: var(--accent-text); vertical-align: super; margin-inline-start: 2px;
}
.figure-item__k {
  font-size: var(--step--1); font-weight: 600; color: var(--text);
}
.figure-item__d {
  font-size: var(--step--2); color: var(--text-mute); line-height: 1.5; max-width: 24ch;
}
/* A hairline between the columns, suppressed at the row start */
@media (min-width: 700px) {
  .figures { gap: var(--sp-5) 0; }
  .figure-item { padding-inline: var(--sp-5); border-inline-start: 1px solid var(--line); }
  .figure-item:first-child { padding-inline-start: 0; border-inline-start: 0; }
}

/* ==========================================================================
   25. TOUCH SIZING
   Anything a finger has to hit needs ~44px of comfortable area. Several
   controls were sized for a mouse pointer: the card tool buttons at 34px,
   small buttons at 33px tall, and footer links at 22px line boxes.
   ========================================================================== */
@media (max-width: 900px) {
  .tool-btn { inline-size: 40px; block-size: 40px; }
  .tool-btn svg { inline-size: 19px; block-size: 19px; }

  .btn--sm { padding: 12px 18px; }

  /* Grow the hit area without moving the text: the rule stays where it was. */
  .link-arrow { padding-block: 10px; }

  .footer-links { gap: 2px; }
  .footer-links a { padding-block: 9px; }
  /* Pad the anchor, not the row — the row is a flex line, and padding it
     leaves the tappable phone number itself at its 24px line box. */
  .footer-contact__row { align-items: center; }
  .footer-contact__row a { display: inline-block; padding-block: 9px; }
  .footer-contact__row svg { margin-block-start: 0; }
  .footer-bottom nav a { padding-block: 8px; }

  /* Sliders: a 32px band is workable with a mouse, thin under a thumb. */
  input[type="range"] { block-size: 40px; }
  input[type="range"]::-webkit-slider-thumb { margin-block-start: -13px; }

  .crumbs a { padding-block: 6px; }

  .card__specs div { padding-block: 13px; }

  .socials a { inline-size: 42px; block-size: 42px; }

  .pill { padding: 10px 16px; }
  .byt-chip { padding: 10px 15px; }
}

/* Phones: give the card foot room to breathe when price and button stack. */
@media (max-width: 420px) {
  .card__foot { flex-direction: column; align-items: stretch; gap: var(--sp-3); }
  .card__foot .btn { justify-content: center; }
  .hero__facts { gap: var(--sp-5); }
  .hero__actions .btn { flex: 1 1 100%; }
  .searchbar { padding: var(--sp-4); }
  .section-head-row { align-items: flex-start; }
}
