/* RTL Design System — v1.4 */
:root {
  --black: #1A1A1A; --dark: #333; --mid: #666; --light: #999;
  --border: #E0E0E0; --bg-warm: #F9F7F4; --bg-mid: #F0EDE8;
  --gold: #B8975A; --green: #2D5A27; --green-light: #E8F0E6;
  --red: #C0392B; --white: #FFF; --brown: #7A6450;
  --serif: 'Fraunces', Georgia, serif;
  --sans: 'Archivo', Arial, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  --max: 1320px; --pad-x: 60px; --section: 96px;
  /* Legacy aliases */
  --rtl-black: var(--black); --rtl-dark: var(--dark); --rtl-mid: var(--mid);
  --rtl-light: var(--light); --rtl-border: var(--border); --rtl-bg: var(--bg-warm);
  --rtl-bg-mid: var(--bg-mid); --rtl-gold: var(--gold); --rtl-green: var(--green);
  --rtl-white: var(--white); --rtl-cream: var(--bg-warm); --rtl-muted: var(--mid);
  --rtl-red: var(--red); --rtl-green-lt: var(--green-light);
  --font-serif: var(--serif); --font-sans: var(--sans);
  --score-5: #2D5A27; --score-4: #5A7A2A; --score-3: #A07830; --score-2: #A05030; --score-1: #C0392B;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--sans); font-size: 16px; line-height: 1.65; color: var(--dark); background: var(--bg-warm); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; }
.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; }

/* ═════ NAV ═════ */
.nav { background: var(--bg-mid); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 100; }
.nav-inner { max-width: var(--max); margin: 0 auto; padding: 18px 20px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 48px; }
.logo { font-family: var(--serif); font-weight: 600; font-size: 24px; letter-spacing: -0.01em; color: var(--black); justify-self: start; }
.logo em { font-style: italic; font-weight: 400; color: var(--gold); }
.nav-links { display: flex; gap: 48px; justify-content: center; list-style: none; }
.nav-links a { font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.14em; color: var(--black); padding: 6px 0; border-bottom: 1px solid transparent; transition: border-color 0.2s; }
.nav-links a.active { border-bottom-color: var(--gold); }
.nav-links a:hover { border-bottom-color: var(--black); }
.nav-icons { display: flex; gap: 20px; justify-content: flex-end; color: var(--black); }
.nav-icons svg { width: 20px; height: 20px; cursor: pointer; }

/* ═════ HERO (shared black band) ═════ */
.hero { background: var(--black); color: var(--white); padding: 20px var(--pad-x) 10px; }
.hero-inner { max-width: var(--max); margin: 0 auto; display: flex; flex-direction: column; min-height: 200px; }
.hero-label { font-size: 10px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; display: flex; align-items: center; gap: 14px; }
.hero-label::before { content: ""; display: inline-block; width: 28px; height: 1px; background: var(--gold); }
.hero h1 { font-family: var(--serif); font-weight: 400; font-size: 75px; line-height: 0.95; letter-spacing: -0.02em; color: var(--white) !important; margin-bottom: 10px; font-variation-settings: "opsz" 144; }
.hero h1 em { font-style: italic; font-weight: 400; color: var(--gold) !important; }
.hero-sub { font-family: var(--serif); font-style: italic; font-size: 14px; line-height: 1.45; color: rgba(255,255,255,0.75); max-width: 680px; margin-bottom: 14px; }
.hero-sub--full { max-width: none; }
.hero-divider { border-bottom: 1px solid rgba(255,255,255,0.2); margin-bottom: 24px; }
/* Stats row — directly below title */
.hero-stats-row { display: flex; gap: 32px; align-items: center; margin-top: 6px; font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: rgba(255,255,255,0.5); }
.hero-stat-item { display: inline-flex; gap: 8px; align-items: center; }
.hero-stat-label { color: rgba(255,255,255,0.5); }
.hero-stat-value { color: var(--white); font-weight: 500; font-size: 13px; }
.hero-stat-stars { display: inline-flex; gap: 3px; }
.hero-stat-stars .stars-gold { font-size: 16px; letter-spacing: 4px; color: var(--gold); }
.hero-stat-stars .stars-gold .off { color: rgba(255,255,255,0.15); }
.hero-stat-stars .stars-gold .star-half { letter-spacing: 0; }

/* Spacer pushes search to bottom */
.hero-spacer { flex: 1; min-height: 40px; }

/* Search bar — icon on right */
.searchbar { border-bottom: 1px solid rgba(255,255,255,0.8); padding: 0 0 8px; display: flex; align-items: center; gap: 12px; margin-bottom: 0; }
.searchbar input { flex: 1; background: transparent; border: none; outline: none; color: var(--white); font-family: var(--serif); font-size: 17px; font-weight: 400; padding: 4px 0; order: 1; }
.searchbar input::placeholder { color: rgba(255,255,255,0.3); font-style: italic; }
.searchbar-btn { background: none; border: none; cursor: pointer; order: 2; padding: 4px; }
.searchbar-btn svg { width: 20px; height: 20px; color: rgba(255,255,255,0.6); }
.searchbar-btn:hover svg { color: var(--white); }

/* Meta right (About page) */
.hero-meta-right { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: rgba(255,255,255,0.45); padding: 8px 0; }

.hero-divider { border-bottom: 1px solid rgba(255,255,255,0.2); margin-bottom: 16px; }

/* ═════ SECTION LABELS ═════ */
.section { padding: var(--section) var(--pad-x); max-width: var(--max); margin: 0 auto; }
.section-label { font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); margin-bottom: 20px; display: flex; align-items: center; gap: 14px; }
.section-label::before { content: ""; display: inline-block; width: 28px; height: 1px; background: var(--gold); }
.section-h2 { font-family: var(--serif); font-weight: 500; font-size: 44px; line-height: 1.1; letter-spacing: -0.015em; color: var(--black); margin-bottom: 40px; max-width: 820px; }
.section-h2 em { font-style: italic; font-weight: 400; }
.section-header-row { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 40px; flex-wrap: wrap; gap: 24px; }
.section-header-row .section-h2 { margin-bottom: 0; }
.view-all { font-family: var(--sans); font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--black); border-bottom: 1px solid var(--gold); padding-bottom: 3px; }
.view-all:hover { color: var(--gold); }

/* ═════ BRAND CARD (full variant — Ratings + Homepage) ═════ */
.card { background: var(--white); border: 1px solid var(--border); display: flex; flex-direction: column; text-decoration: none; color: inherit; transition: transform 0.35s cubic-bezier(.2,.7,.2,1), box-shadow 0.35s; position: relative; overflow: hidden; }
.card:hover { transform: translateY(-4px); box-shadow: 0 20px 40px -20px rgba(0,0,0,0.12); }
.card-img { aspect-ratio: 4/3; position: relative; overflow: hidden; background: linear-gradient(135deg, #D9D4CC, #A89D8C); }
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.card-img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 60%, rgba(0,0,0,0.08)); pointer-events: none; }
.card-badge { position: absolute; top: 16px; left: 16px; background: rgba(255,255,255,0.94); color: var(--black); padding: 6px 10px; font-family: var(--mono); font-size: 10px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; z-index: 2; }
.card-badge.new { background: var(--gold); color: var(--white); }
.card-badge.updated { background: var(--green); color: var(--white); }
.card-body { padding: 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-name { font-family: var(--serif); font-weight: 500; font-size: 21px; line-height: 1.1; color: var(--black); }
.card-score-row { display: flex; align-items: center; gap: 12px; }
.stars { letter-spacing: 2px; font-size: 14px; line-height: 1; color: var(--green); }
.stars .star-full { color: var(--green); }
.stars .off { color: var(--border); }
.stars-gold { letter-spacing: 3px; color: var(--gold); line-height: 1; }
.stars-gold .star-full { color: var(--gold); }
.stars-gold .off { color: var(--border); }

/* Half star — left half colored, right half grey */
.star-half {
  display: inline-block;
  position: relative;
  width: 1em;
  height: 1em;
  vertical-align: middle;
  letter-spacing: 0;
}
.star-half-filled {
  position: absolute;
  left: 0; top: 0;
  width: 50%;
  overflow: hidden;
  display: inline-block;
  line-height: 1;
}
.star-half-empty {
  color: var(--border);
  display: inline-block;
  line-height: 1;
}
.stars .star-half-filled { color: var(--green); }
.stars-gold .star-half-filled { color: var(--gold); }
.hero-stat-stars .star-half-filled { color: var(--gold); }
.hero-stat-stars .star-half-empty { color: rgba(255,255,255,0.15); }
.score-num { font-family: var(--mono); font-size: 12px; color: var(--mid); font-weight: 500; }
.card-meta { font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; color: var(--mid); }
.card-footer { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: baseline; font-family: var(--mono); font-size: 11px; color: var(--light); }
.price { display: inline-flex; gap: 2px; color: var(--black); font-weight: 500; }
.price .off { color: var(--border); }
.card-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-family: var(--serif); font-size: 48px; font-weight: 700; color: var(--light); }

/* ═════ HOW IT WORKS ═════ */
.hiw-wrap { background: var(--bg-mid); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.steps { margin-top: 24px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--white); }
.step { padding: 40px 28px 36px; border-right: 1px solid var(--border); }
.step:last-child { border-right: none; }
.step-num { font-family: var(--serif); font-weight: 400; line-height: 1; color: var(--black); margin-bottom: 20px; display: block; }
.step-num-sub { font-family: var(--mono); font-size: 11px; color: var(--gold); vertical-align: top; margin-left: 4px; font-weight: 500; }
.step-title { font-family: var(--sans); font-weight: 700; font-size: 13px; color: var(--black); margin-bottom: 10px; line-height: 1.35; }
.step-desc { font-size: 13px; line-height: 1.6; color: var(--mid); }

/* ═════ GHOST SLOTS ═════ */
.card-ghost { background: transparent; border: 1px dashed var(--border); display: flex; align-items: center; justify-content: center; min-height: 380px; color: var(--light); font-family: var(--serif); font-style: italic; font-size: 15px; text-align: center; padding: 24px; line-height: 1.5; }

/* ═════ META FOOTER ═════ */
.meta-footer { background: var(--bg-mid); padding: 28px var(--pad-x); border-top: 1px solid var(--border); }
.meta-footer-inner { max-width: var(--max); margin: 0 auto; display: flex; justify-content: space-between; align-items: center; gap: 32px; flex-wrap: wrap; }
.meta-items { display: flex; gap: 40px; font-family: var(--mono); font-size: 12px; color: var(--mid); }
.meta-items span { color: var(--black); font-weight: 500; margin-left: 6px; }
.meta-footer a { font-family: var(--sans); font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--black); border-bottom: 1px solid var(--gold); padding-bottom: 3px; }

/* ═════ RESPONSIVE ═════ */
@media (max-width: 1100px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
  .step { border-bottom: 1px solid var(--border); }
}
@media (max-width: 900px) {
  .hero h1 { font-size: 42px !important; }
  .hero-bottom { flex-direction: column; align-items: flex-start; gap: 20px; }
  .hero-bottom .stats-group { gap: 24px; flex-wrap: wrap; }
  .nav-inner { grid-template-columns: 1fr; gap: 12px; justify-items: center; }
  .nav-links { gap: 24px; flex-wrap: wrap; }
  .nav-icons { display: none; }
}
@media (max-width: 560px) {
  :root { --pad-x: 20px; }
}
