/* Guiderio public site — Warm Editorial language shared with the app:
   cream surfaces, terracotta accent, Newsreader display / Manrope body. */

:root {
  --bg: #f5efe6;
  --surface: #fbf7ee;
  --surface-2: #f0e7d6;
  --text: #2b2218;
  --mute: #7a6c58;
  --faint: #a59881;
  --accent: #b94e2c;
  --accent-2: #8c3b1f;
  --accent-3: #ebd9c4;
  --accent-soft: #f1d4c4;
  --border: #e3d6bf;

  --ink: #1a140d;         /* dark band, from the app's dark theme */
  --ink-2: #241b11;
  --ink-text: #f5ecdb;
  --ink-mute: #a89880;
  --ink-accent: #e07959;
  --ink-border: #3a2e1f;

  --font-display: 'Newsreader', Georgia, serif;
  --font-body: 'Manrope', -apple-system, system-ui, sans-serif;

  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 1px 2px rgba(43, 34, 24, 0.05), 0 10px 30px rgba(43, 34, 24, 0.08);
  --shadow-lg: 0 12px 32px rgba(43, 34, 24, 0.1), 0 32px 80px rgba(43, 34, 24, 0.14);

  --wrap: 1120px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

/* Paper grain — a whisper of texture so the cream doesn't read flat. */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0.17 0 0 0 0 0.13 0 0 0 0 0.09 0 0 0 0.03 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

::selection { background: var(--accent-soft); }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.01em;
}

a { color: inherit; }

.eyebrow {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent);
  margin-bottom: 14px;
}
.eyebrow-light { color: var(--ink-accent); }

/* ============ Nav ============ */

.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 18px 24px;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.01em;
}
.nav-mark { border-radius: 8px; flex: none; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
  font-size: 14px;
  font-weight: 600;
}
.nav-links a { text-decoration: none; color: var(--mute); transition: color 0.15s; }
.nav-links a:hover { color: var(--text); }

.nav-cta {
  color: #fff !important;
  background: var(--accent);
  padding: 9px 18px;
  border-radius: 999px;
  transition: background 0.15s;
}
.nav-cta:hover { background: var(--accent-2); }

/* ---- Language picker: a dropdown, not a pill row. Each option shows its
   own name in its own script, plus which stops on the map speak it — turns
   a utility control into a small preview of the coverage section. ---- */

.lang-picker { position: relative; }

.lang-trigger {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.lang-trigger svg:first-child { color: var(--accent); flex: none; }
.lang-trigger:hover { border-color: var(--faint); }
.lang-trigger[aria-expanded='true'] { box-shadow: 0 0 0 3px var(--accent-soft); border-color: var(--accent); }

.lang-chevron { transition: transform 0.2s ease; color: var(--faint); }
.lang-trigger[aria-expanded='true'] .lang-chevron { transform: rotate(180deg); }

.lang-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 220px;
  list-style: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 6px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px) scale(0.98);
  transform-origin: top right;
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s;
  z-index: 20;
}
.lang-picker.open .lang-menu {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.lang-menu li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 12px;
  border-radius: calc(var(--radius) - 5px);
  cursor: pointer;
  transition: background 0.12s;
}
.lang-menu li:hover,
.lang-menu li.active-option { background: var(--surface-2); }
.lang-menu li[aria-selected='true'] { background: var(--accent-soft); }

.lang-native { font-size: 15px; font-weight: 700; color: var(--text); }
.lang-menu li[aria-selected='true'] .lang-native { color: var(--accent-2); }
.lang-local { font-size: 11.5px; color: var(--faint); white-space: nowrap; }

/* ============ Hero ============ */

.hero {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 56px;
  align-items: center;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 72px 24px 96px;
}

.hero h1 {
  font-size: clamp(44px, 6.2vw, 76px);
  margin-bottom: 22px;
}
.hero h1 em {
  font-style: italic;
  color: var(--accent);
}

.lede {
  font-size: 18px;
  color: var(--mute);
  max-width: 46ch;
  margin-bottom: 34px;
}

/* Store badges — drawn in-theme rather than the stock black plaques. */
.store-badges { display: flex; flex-wrap: wrap; gap: 14px; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 11px 20px 11px 16px;
  background: var(--text);
  color: var(--surface);
  border-radius: 14px;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-shadow: var(--shadow);
}
.badge:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.badge span { display: flex; flex-direction: column; line-height: 1.25; font-weight: 700; font-size: 16px; }
.badge small { font-size: 10.5px; font-weight: 600; opacity: 0.75; text-transform: uppercase; letter-spacing: 0.06em; }

/* ---- The player (signature element) ---- */

.hero-player { position: relative; }

.player-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 18px 18px 22px;
  transform: rotate(1.6deg);
  transition: transform 0.35s ease;
}
.hero-player:hover .player-card { transform: rotate(0deg); }

.player-cover {
  background: linear-gradient(180deg, var(--surface-2), var(--accent-soft));
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 16px;
}
.player-cover svg { display: block; width: 100%; height: auto; }

.ripple { opacity: 0; }
.playing .ripple { animation: ripple 1.8s ease-out infinite; }
.playing .r2 { animation-delay: 0.25s; }
.playing .r3 { animation-delay: 0.5s; }
@keyframes ripple {
  0% { opacity: 0; }
  25% { opacity: 0.9; }
  100% { opacity: 0; }
}

.player-track {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 500;
  line-height: 1.2;
}
.player-sub { font-size: 13px; color: var(--faint); font-weight: 600; margin-top: 2px; }

.player-wave {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 44px;
  margin: 16px 0 12px;
}
.player-wave i {
  flex: 1;
  border-radius: 3px;
  background: var(--accent-3);
  height: calc(var(--h) * 1%);
  min-height: 12%;
  transition: background 0.3s;
}
.player-wave i.played { background: var(--accent); }
.playing .player-wave i { animation: bounce 1.1s ease-in-out infinite; animation-delay: var(--d); }
@keyframes bounce {
  0%, 100% { transform: scaleY(0.7); }
  50% { transform: scaleY(1.15); }
}

.player-controls { display: flex; align-items: center; gap: 14px; }

.play-btn {
  flex: none;
  width: 52px;
  height: 52px;
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background 0.15s, transform 0.15s;
}
.play-btn:hover { background: var(--accent-2); transform: scale(1.05); }
.play-btn .icon-stop { display: none; }
.playing .play-btn .icon-play { display: none; }
.playing .play-btn .icon-stop { display: block; }

.player-progress {
  flex: 1;
  height: 5px;
  border-radius: 999px;
  background: var(--surface-2);
  overflow: hidden;
}
.player-progress-fill {
  width: 0%;
  height: 100%;
  border-radius: 999px;
  background: var(--accent);
  transition: width 0.2s linear;
}
.player-time { font-size: 12.5px; font-weight: 700; color: var(--faint); font-variant-numeric: tabular-nums; }

.player-hint {
  margin-top: 16px;
  text-align: center;
  font-size: 13.5px;
  color: var(--faint);
  font-style: italic;
  font-family: var(--font-display);
  font-size: 16px;
}

/* ============ Ticker ============ */

.ticker {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  overflow: hidden;
  white-space: nowrap;
  position: relative;
  z-index: 2;
}
.ticker-track {
  display: inline-flex;
  align-items: center;
  gap: 28px;
  padding: 13px 0;
  animation: ticker 36s linear infinite;
}
.ticker-track span {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 17px;
  color: var(--mute);
}
.ticker-track i { color: var(--accent); font-style: normal; font-size: 12px; }
@keyframes ticker {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ============ Tour stops ============ */

.tour {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 96px 24px;
  position: relative;
  z-index: 2;
}

.tour-head { text-align: center; margin-bottom: 64px; }
.tour-head h2 { font-size: clamp(32px, 4vw, 46px); }

.stops {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.stop {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 30px 28px 34px;
  box-shadow: var(--shadow);
}

.stop-no {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 999px;
  padding: 5px 12px;
  margin-bottom: 22px;
}

.stop-art { width: 72px; height: 72px; margin-bottom: 18px; }
.stop-art svg { width: 100%; height: 100%; }

.stop h3 { font-size: 26px; margin-bottom: 8px; }
.stop p { color: var(--mute); font-size: 15px; }

/* ============ Coverage ============ */

.coverage {
  border-top: 1px solid var(--border);
  background: var(--surface);
  position: relative;
  z-index: 2;
}
.coverage > * {
  max-width: var(--wrap);
  margin: 0 auto;
  padding-inline: 24px;
}

.coverage-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 56px;
  padding-top: 88px;
  margin-bottom: 52px;
}
.coverage-head-copy { max-width: 640px; }
.coverage-head h2 { font-size: clamp(32px, 4vw, 46px); }
.coverage-head em { font-style: italic; color: var(--accent); }
.coverage-sub { color: var(--mute); margin-top: 12px; font-size: 16px; }

/* ---- Ticket counter: a nod to stop.b2 ("your ticket code opens the
   guide") — the live count rendered as a torn ticket stub, notched on
   both edges like a real admission ticket. ---- */

.ticket-counter {
  position: relative;
  flex: none;
  width: 216px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  transform: rotate(-2deg);
  transition: transform 0.3s ease;
}
.ticket-counter:hover { transform: rotate(0deg); }

/* Punched-hole notches: solid circles cut from the card in the page
   background colour, ringed with a solid border — avoids a dashed border on
   a curve, which some engines rasterize very slowly. */
.ticket-notch {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg);
  border: 1.5px solid var(--border);
}
.ticket-notch-t { top: -12px; }
.ticket-notch-b { bottom: -12px; }

/* The perforation itself: a straight dashed rule (no radius) under the
   eyebrow — the one place a dashed line is safe to use. */
.ticket-eyebrow {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  padding-bottom: 14px;
  margin-bottom: 12px;
  border-bottom: 1.5px dashed var(--border);
  width: 100%;
}
.ticket-count {
  font-family: var(--font-display);
  font-size: 56px;
  font-weight: 600;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}
.ticket-unit {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 14.5px;
  color: var(--mute);
}

.coverage-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  padding-bottom: 88px;
}

.country {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 22px 26px;
}

.country h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 23px;
  margin-bottom: 16px;
}
.country-flag { font-size: 22px; line-height: 1; }

.cities {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.cities li {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--accent-2);
  background: var(--accent-soft);
  border-radius: 999px;
  padding: 5px 13px;
}

.country.soon { border-color: var(--faint); background: transparent; }
.country.soon .cities li { color: var(--mute); background: var(--surface-2); }
.soon-tag {
  display: inline-block;
  margin-top: 16px;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--faint);
}

/* ============ Attractions band ============ */

.attractions {
  background: var(--ink);
  color: var(--ink-text);
  position: relative;
  z-index: 2;
}

.attractions-inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 88px 24px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 64px;
  align-items: center;
}

.attractions h2 { font-size: clamp(30px, 3.6vw, 42px); margin-bottom: 16px; }
.attractions-copy > p { color: var(--ink-mute); max-width: 50ch; margin-bottom: 28px; }

.btn-light {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--ink-accent);
  color: var(--ink);
  font-weight: 800;
  font-size: 15px;
  text-decoration: none;
  padding: 13px 24px;
  border-radius: 999px;
  transition: transform 0.15s, filter 0.15s;
}
.btn-light:hover { transform: translateY(-2px); filter: brightness(1.06); }

.env-note { margin-top: 14px; font-size: 12.5px; color: var(--ink-mute); font-style: italic; }

/* Mini dashboard rows — a wink at the CMS, not a screenshot. */
.attractions-art { display: grid; gap: 12px; }

.mini-row {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--ink-2);
  border: 1px solid var(--ink-border);
  border-radius: var(--radius);
  padding: 15px 18px;
}
.mini-row > div { flex: 1; display: flex; flex-direction: column; line-height: 1.35; }
.mini-row b { font-size: 15px; font-weight: 700; }
.mini-row i { font-style: normal; font-size: 12.5px; color: var(--ink-mute); }
.mini-row em {
  font-style: normal;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #7fc79a;
}
.mini-dot { width: 9px; height: 9px; border-radius: 50%; background: #7fc79a; flex: none; }
.mini-row.draft .mini-dot { background: var(--ink-mute); }
.mini-row.draft em { color: var(--ink-mute); }

/* ============ Footer ============ */

.footer { border-top: 1px solid var(--border); position: relative; z-index: 2; }

.footer-inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 40px 24px;
  display: flex;
  align-items: center;
  gap: 28px;
  flex-wrap: wrap;
}
.footer .nav-brand { font-size: 16px; }

.footer-links { display: flex; gap: 22px; flex: 1; font-size: 13.5px; font-weight: 600; }
.footer-links a { color: var(--mute); text-decoration: none; }
.footer-links a:hover { color: var(--text); }

.footer-note { font-size: 13px; color: var(--faint); font-family: var(--font-display); font-style: italic; }

/* ============ Reveal on scroll ============ */

.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: none; }
.stops .reveal:nth-child(2) { transition-delay: 0.12s; }
.stops .reveal:nth-child(3) { transition-delay: 0.24s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .ticker-track { animation: none; }
  .playing .player-wave i, .playing .ripple { animation: none; }
  .playing .ripple { opacity: 0.7; }
}

:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* ============ Arabic / RTL ============ */

/* Arabic counterparts of the type pairing: Amiri (serif) + Tajawal (sans). */
html[lang='ar'] {
  --font-display: 'Amiri', 'Newsreader', serif;
  --font-body: 'Tajawal', 'Manrope', system-ui, sans-serif;
}

/* Tracking and slant don't suit Arabic script — neutralize both. */
html[lang='ar'] .eyebrow,
html[lang='ar'] .stop-no,
html[lang='ar'] .badge small,
html[lang='ar'] .soon-tag,
html[lang='ar'] .mini-row em { letter-spacing: 0; }
html[lang='ar'] em,
html[lang='ar'] .player-hint,
html[lang='ar'] .ticker-track span,
html[lang='ar'] .env-note,
html[lang='ar'] .footer-note { font-style: normal; }

/* Amiri renders small at equal size — nudge the serif moments up. */
html[lang='ar'] .hero h1 { line-height: 1.25; }
html[lang='ar'] .lede,
html[lang='ar'] .stop p,
html[lang='ar'] .attractions-copy > p { font-size: 17px; }

[dir='rtl'] .ticker-track { animation-name: ticker-rtl; }
@keyframes ticker-rtl {
  from { transform: translateX(0); }
  to { transform: translateX(50%); }
}

[dir='rtl'] .btn-light svg { transform: scaleX(-1); }
[dir='rtl'] .player-card { transform: rotate(-1.6deg); }
[dir='rtl'] .hero-player:hover .player-card { transform: rotate(0deg); }

[dir='rtl'] .lang-menu { right: auto; left: 0; transform-origin: top left; }
[dir='rtl'] .ticket-counter { transform: rotate(2deg); }
[dir='rtl'] .ticket-counter:hover { transform: rotate(0deg); }

/* ============ Responsive ============ */

@media (max-width: 1060px) {
  .coverage-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; gap: 48px; padding-top: 40px; padding-bottom: 64px; }
  .hero-player { max-width: 440px; }
  .stops { grid-template-columns: 1fr; max-width: 480px; margin: 0 auto; }
  .attractions-inner { grid-template-columns: 1fr; gap: 44px; padding: 64px 24px; }
  .nav-links a:not(.nav-cta) { display: none; }
  .tour { padding: 64px 24px; }
  .coverage-head { flex-direction: column; text-align: center; padding-top: 64px; margin-bottom: 40px; }
  .coverage-head-copy { max-width: 100%; }
  .coverage-grid { padding-bottom: 64px; }
}

@media (max-width: 560px) {
  .coverage-grid { grid-template-columns: 1fr; }
  .nav-cta { display: none; }
}
