/* ============================================================
   Cosmic Brass — Design System
   Ancient Astronomical Instruments Simulator
   ============================================================ */

:root {
  /* Surfaces */
  --bg-0: oklch(0.13 0.025 250);
  --bg-1: oklch(0.17 0.028 248);
  --bg-2: oklch(0.21 0.032 245);
  --bg-3: oklch(0.26 0.036 243);
  --bg-panel: oklch(0.18 0.028 248 / 0.85);
  --bg-glass: oklch(0.22 0.03 245 / 0.55);
  --line: oklch(0.42 0.04 240 / 0.45);
  --line-soft: oklch(0.35 0.03 245 / 0.30);

  /* Brass */
  --brass: oklch(0.76 0.115 78);
  --brass-bright: oklch(0.88 0.13 82);
  --brass-mid: oklch(0.65 0.10 75);
  --brass-dim: oklch(0.52 0.08 72);
  --brass-deep: oklch(0.38 0.06 65);
  --brass-glow: oklch(0.78 0.13 78 / 0.5);

  /* Text */
  --ivory: oklch(0.95 0.018 85);
  --text: oklch(0.93 0.018 80);
  --text-dim: oklch(0.74 0.022 78);
  --text-mute: oklch(0.56 0.022 75);
  --text-faint: oklch(0.42 0.02 75);

  /* Accents */
  --copper: oklch(0.66 0.15 35);
  --copper-bright: oklch(0.78 0.16 35);
  --teal: oklch(0.72 0.10 195);
  --crimson: oklch(0.62 0.18 22);
  --star: oklch(0.97 0.04 90);
  --sun: oklch(0.86 0.16 80);
  --moon: oklch(0.92 0.03 240);

  /* Type */
  --f-ar-display: "Reem Kufi", "Amiri", serif;
  --f-ar-body: "Amiri", "Noto Naskh Arabic", serif;
  --f-en-display: "Cormorant Garamond", "EB Garamond", serif;
  --f-en-body: "Inter", system-ui, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, monospace;

  /* Spatial */
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;
  --r-xl: 22px;

  /* Shadows */
  --shadow-soft: 0 4px 20px -8px oklch(0 0 0 / 0.6);
  --shadow-strong: 0 10px 40px -10px oklch(0 0 0 / 0.7);
  --shadow-brass-glow: 0 0 24px -4px var(--brass-glow);
}

* { box-sizing: border-box; }

html, body, #root {
  margin: 0; padding: 0;
  height: 100%;
  overflow: hidden;
  background: var(--bg-0);
  color: var(--text);
  font-family: var(--f-en-body);
  font-size: 14px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  background:
    radial-gradient(ellipse at 18% 12%, oklch(0.24 0.04 250 / 0.7), transparent 55%),
    radial-gradient(ellipse at 82% 88%, oklch(0.20 0.05 30 / 0.4), transparent 55%),
    radial-gradient(ellipse at 50% 50%, oklch(0.18 0.03 248), oklch(0.10 0.02 250));
}

/* Star-dust background ---------------------------------------- */
.starfield {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(1px 1px at 22% 18%, oklch(0.95 0.02 90), transparent 60%),
    radial-gradient(1px 1px at 78% 31%, oklch(0.88 0.04 60), transparent 60%),
    radial-gradient(1px 1px at 38% 62%, oklch(0.96 0.02 90), transparent 60%),
    radial-gradient(1px 1px at 65% 78%, oklch(0.90 0.03 80), transparent 60%),
    radial-gradient(1.5px 1.5px at 12% 84%, oklch(0.99 0.02 90), transparent 60%),
    radial-gradient(1px 1px at 88% 12%, oklch(0.92 0.04 90), transparent 60%),
    radial-gradient(1.2px 1.2px at 50% 8%, oklch(0.99 0.02 90), transparent 60%),
    radial-gradient(0.8px 0.8px at 8% 42%, oklch(0.85 0.04 80), transparent 60%),
    radial-gradient(1px 1px at 92% 55%, oklch(0.96 0.02 90), transparent 60%),
    radial-gradient(1px 1px at 28% 35%, oklch(0.85 0.04 60), transparent 60%);
  opacity: 0.6;
}

/* App shell --------------------------------------------------- */
.app {
  position: fixed;
  inset: 0;
  display: grid;
  grid-template-rows: 56px 1fr 44px;
}

/* Top navigation bar */
.topbar {
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  gap: 18px;
  padding: 0 20px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, oklch(0.15 0.025 248 / 0.92), oklch(0.13 0.025 250 / 0.75));
  backdrop-filter: blur(10px);
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-left: 20px;
  border-left: 1px solid var(--line-soft);
  flex-direction: row-reverse;
}
.brand-mark {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, var(--brass-bright), var(--brass-deep));
  box-shadow: inset 0 0 8px oklch(0 0 0 / 0.4), 0 0 14px var(--brass-glow);
  position: relative;
}
.brand-mark::after {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  border: 1px solid oklch(0.30 0.04 60);
  border-top-color: oklch(0.96 0.04 80);
}
.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1;
  text-align: right;
}
.brand-ar {
  font-family: var(--f-ar-display);
  font-size: 17px;
  color: var(--ivory);
  letter-spacing: 0.5px;
}
.brand-en {
  font-family: var(--f-en-display);
  font-style: italic;
  font-size: 11px;
  color: var(--text-mute);
  letter-spacing: 1.2px;
  text-transform: uppercase;
  margin-top: 2px;
}

.nav {
  display: flex;
  flex-direction: row-reverse;
  gap: 4px;
  flex: 1;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav::-webkit-scrollbar { display: none; }

.nav-tab {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  padding: 6px 14px;
  border-radius: var(--r-md);
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: all 0.18s ease;
  white-space: nowrap;
  text-align: right;
}
.nav-tab:hover {
  background: var(--bg-2);
  color: var(--text);
}
.nav-tab.active {
  background: linear-gradient(180deg, oklch(0.30 0.06 70 / 0.55), oklch(0.22 0.04 70 / 0.4));
  border-color: var(--brass-dim);
  color: var(--brass-bright);
  box-shadow: inset 0 0 0 1px oklch(0.95 0.04 80 / 0.05), 0 0 12px oklch(0.65 0.12 75 / 0.3);
}
.nav-tab .ar {
  font-family: var(--f-ar-display);
  font-size: 14px;
  line-height: 1.1;
}
.nav-tab .en {
  font-family: var(--f-en-display);
  font-style: italic;
  font-size: 10px;
  letter-spacing: 0.8px;
  color: var(--text-mute);
  line-height: 1.1;
  margin-top: 1px;
}
.nav-tab.active .en { color: var(--brass-mid); }

.topbar-right {
  display: flex;
  flex-direction: row-reverse;
  gap: 10px;
  align-items: center;
}
.iconbtn {
  width: 32px; height: 32px;
  display: grid; place-items: center;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  color: var(--text-dim);
  cursor: pointer;
  transition: all 0.15s;
}
.iconbtn:hover { color: var(--brass-bright); border-color: var(--brass-dim); }
.iconbtn.on { color: var(--brass-bright); border-color: var(--brass-dim); background: oklch(0.25 0.05 70 / 0.4); }

/* Main stage -------------------------------------------------- */
.stage-wrap {
  position: relative;
  overflow: hidden;
  height: 100%;
}
.stage {
  position: relative;
  overflow: hidden;
  height: 100%;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 340px;
}
.stage.fullwidth { grid-template-columns: 1fr; }

.canvas {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  min-width: 0;
  min-height: 0;
}
.canvas > * { max-width: 100%; max-height: 100%; }
.canvas svg { display: block; max-width: 100%; max-height: 100%; }
.fit-square {
  position: relative;
  aspect-ratio: 1 / 1;
  width: auto;
  height: 100%;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.fit-square > svg { width: 100% !important; height: 100% !important; }

/* Side panel */
.panel {
  border-left: 1px solid var(--line);
  background: var(--bg-panel);
  backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.panel-head {
  padding: 14px 18px 10px;
  border-bottom: 1px solid var(--line-soft);
}
.panel-title-ar {
  font-family: var(--f-ar-display);
  font-size: 18px;
  color: var(--brass-bright);
  letter-spacing: 0.5px;
}
.panel-title-en {
  font-family: var(--f-en-display);
  font-style: italic;
  font-size: 12px;
  color: var(--text-mute);
  letter-spacing: 1.2px;
  margin-top: 2px;
  text-transform: uppercase;
}
.panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px 18px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.panel-body::-webkit-scrollbar { width: 6px; }
.panel-body::-webkit-scrollbar-thumb { background: var(--brass-deep); border-radius: 4px; }

/* Form controls */
.ctrl {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ctrl-label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: var(--text-mute);
}
.ctrl-label .ar {
  font-family: var(--f-ar-body);
  font-size: 13px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--text-dim);
}
.ctrl-label .val {
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--brass-bright);
  letter-spacing: 0.4px;
}

.slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  background: var(--bg-3);
  border-radius: 4px;
  outline: none;
}
.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, var(--brass-bright), var(--brass-mid));
  border: 1px solid var(--brass-deep);
  cursor: pointer;
  box-shadow: 0 0 8px var(--brass-glow);
}
.slider::-moz-range-thumb {
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--brass-bright);
  border: 1px solid var(--brass-deep);
  cursor: pointer;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 12px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  color: var(--text);
  font-family: var(--f-en-body);
  font-size: 12px;
  letter-spacing: 0.3px;
  cursor: pointer;
  transition: all 0.15s;
}
.btn:hover { border-color: var(--brass-dim); color: var(--brass-bright); }
.btn.primary {
  background: linear-gradient(180deg, oklch(0.45 0.10 75), oklch(0.32 0.07 70));
  border-color: var(--brass-dim);
  color: var(--ivory);
}
.btn.primary:hover { background: linear-gradient(180deg, oklch(0.52 0.12 78), oklch(0.38 0.08 72)); }
.btn.ghost { background: transparent; }
.btn.active {
  background: oklch(0.30 0.07 75 / 0.6);
  border-color: var(--brass-mid);
  color: var(--brass-bright);
}

.btn-group { display: flex; gap: 4px; flex-wrap: wrap; }
.btn-group .btn { padding: 6px 10px; font-size: 11px; }

.select {
  appearance: none;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  color: var(--text);
  padding: 7px 30px 7px 10px;
  font-family: var(--f-en-body);
  font-size: 12px;
  cursor: pointer;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--brass-dim) 50%),
    linear-gradient(135deg, var(--brass-dim) 50%, transparent 50%);
  background-position: calc(100% - 14px) 50%, calc(100% - 9px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

/* Readouts ---------------------------------------------------- */
.readout-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.readout {
  padding: 8px 10px;
  background: oklch(0.16 0.025 250 / 0.65);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-sm);
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.readout .lab {
  font-size: 9.5px;
  color: var(--text-mute);
  text-transform: uppercase;
  letter-spacing: 1.2px;
}
.readout .lab-ar {
  font-family: var(--f-ar-body);
  font-size: 11px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--text-dim);
}
.readout .num {
  font-family: var(--f-mono);
  font-size: 16px;
  color: var(--brass-bright);
  letter-spacing: 0.4px;
}
.readout.wide { grid-column: 1 / -1; }

/* Section dividers */
.sect {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.sect-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 4px;
  border-bottom: 1px dashed var(--line-soft);
}
.sect-head .ar {
  font-family: var(--f-ar-display);
  font-size: 14px;
  color: var(--ivory);
}
.sect-head .en {
  font-family: var(--f-en-display);
  font-style: italic;
  font-size: 10.5px;
  color: var(--brass-mid);
  letter-spacing: 1.4px;
  text-transform: uppercase;
}
.sect-head .dot {
  width: 4px; height: 4px;
  background: var(--brass-dim);
  border-radius: 50%;
}

/* Layer toggles */
.layers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}
.layer {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 5px 8px;
  background: oklch(0.16 0.025 250 / 0.4);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-sm);
  cursor: pointer;
  font-size: 11px;
  color: var(--text-dim);
  transition: all 0.15s;
  user-select: none;
}
.layer:hover { border-color: var(--brass-dim); }
.layer.on {
  background: oklch(0.22 0.05 75 / 0.5);
  border-color: var(--brass-dim);
  color: var(--ivory);
}
.layer .sw {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--text-mute);
  flex-shrink: 0;
}
.layer.on .sw { background: var(--brass-bright); box-shadow: 0 0 6px var(--brass-glow); }

/* Footer status bar ------------------------------------------- */
.status {
  display: flex;
  align-items: center;
  padding: 0 20px;
  gap: 18px;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, oklch(0.13 0.025 250 / 0.7), oklch(0.10 0.02 250 / 0.95));
  backdrop-filter: blur(10px);
  font-size: 11.5px;
}
.status .goal {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
}
.status .goal-icon {
  width: 18px; height: 18px;
  display: grid; place-items: center;
  border: 1px solid var(--brass-dim);
  border-radius: 50%;
  color: var(--brass-bright);
  font-size: 10px;
  flex-shrink: 0;
}
.status .goal-text-ar {
  font-family: var(--f-ar-body);
  font-size: 13px;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.status .goal-sep {
  width: 1px; height: 16px;
  background: var(--line-soft);
}
.status .goal-text-en {
  font-family: var(--f-en-display);
  font-style: italic;
  color: var(--text-mute);
  letter-spacing: 0.6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.status .meta {
  display: flex;
  gap: 14px;
  color: var(--text-mute);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}
.status .meta b {
  color: var(--brass-bright);
  font-weight: 400;
  margin-right: 4px;
}

/* Tour overlay ------------------------------------------------ */
.tour {
  position: absolute;
  pointer-events: none;
  inset: 0;
  z-index: 50;
}
.tour-card {
  pointer-events: auto;
  position: absolute;
  width: 320px;
  background: oklch(0.18 0.03 245 / 0.95);
  border: 1px solid var(--brass-dim);
  border-radius: var(--r-md);
  padding: 14px 16px;
  box-shadow: var(--shadow-strong), 0 0 24px oklch(0.65 0.12 75 / 0.25);
  backdrop-filter: blur(12px);
}
.tour-card .step {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--brass-mid);
  letter-spacing: 1.5px;
  text-transform: uppercase;
}
.tour-card h3 {
  font-family: var(--f-ar-display);
  font-size: 17px;
  color: var(--ivory);
  margin: 4px 0 0;
}
.tour-card .en-h {
  font-family: var(--f-en-display);
  font-style: italic;
  font-size: 12px;
  color: var(--brass-mid);
  letter-spacing: 0.8px;
  margin-bottom: 8px;
}
.tour-card p {
  margin: 4px 0;
  font-family: var(--f-ar-body);
  font-size: 13.5px;
  color: var(--text);
  line-height: 1.55;
}
.tour-card .en-p {
  font-family: var(--f-en-body);
  font-style: italic;
  font-size: 11.5px;
  color: var(--text-mute);
  margin-top: 4px;
  line-height: 1.45;
}
.tour-actions {
  display: flex;
  justify-content: space-between;
  margin-top: 12px;
  align-items: center;
}

/* Info popovers */
.info-pop {
  position: absolute;
  background: oklch(0.16 0.025 250 / 0.97);
  border: 1px solid var(--brass-dim);
  border-radius: var(--r-sm);
  padding: 8px 12px;
  font-size: 12px;
  color: var(--ivory);
  pointer-events: none;
  z-index: 40;
  box-shadow: var(--shadow-soft);
  white-space: nowrap;
}
.info-pop .ar { font-family: var(--f-ar-body); display: block; }
.info-pop .en { font-family: var(--f-en-display); font-style: italic; color: var(--brass-mid); font-size: 11px; }

/* SVG helpers */
svg.instrument {
  display: block;
  max-width: 100%;
  max-height: 100%;
  filter: drop-shadow(0 8px 28px oklch(0 0 0 / 0.55));
}
.instrument text {
  fill: var(--brass-bright);
  font-family: var(--f-en-body);
}

/* Bilingual primitives */
.bi { display: flex; flex-direction: column; gap: 1px; }
.bi .ar { font-family: var(--f-ar-display); }
.bi .en { font-family: var(--f-en-display); font-style: italic; color: var(--text-mute); }

/* Sphere stage container */
.sphere-stage {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1800px;
}

/* Lab info window — collapsible bottom-left card on simulation screens */
.lab-info {
  position: absolute;
  left: 18px;
  bottom: 18px;
  max-width: 340px;
  background: var(--bg-glass);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 12px 14px;
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow-soft);
  font-family: var(--f-ar-body);
  font-size: 12.5px;
  color: var(--text-dim);
  line-height: 1.55;
  z-index: 5;
}
.lab-info .en { font-family: var(--f-en-body); font-style: italic; font-size: 11px; color: var(--text-faint); margin-top: 4px; }
.lab-info .ttl { font-family: var(--f-ar-display); color: var(--brass-bright); font-size: 14px; margin-bottom: 4px; display: flex; align-items: center; gap: 8px; }
.lab-info .ttl small { font-family: var(--f-en-display); font-style: italic; color: var(--brass-mid); font-size: 11px; letter-spacing: 1px; }
.lab-info button { margin-top: 8px; }

/* Top-right floating compass / quick info */
.float-tr {
  position: absolute;
  top: 18px;
  right: 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 5;
}

/* Animations */
@keyframes spin-slow { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes pulse-glow { 0%, 100% { opacity: 0.6; } 50% { opacity: 1; } }
@keyframes shimmer { 0% { opacity: 0.3; } 50% { opacity: 1; } 100% { opacity: 0.3; } }

.spin-slow { animation: spin-slow 60s linear infinite; }
.pulse-glow { animation: pulse-glow 2.5s ease-in-out infinite; }

/* Hub (landing) ----------------------------------------------- */
.hub {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  padding: 24px 48px 32px;
  overflow: auto;
}
.hub-title-bar {
  text-align: center;
  margin-bottom: 18px;
  flex-shrink: 0;
}
.hub-title-bar .ar {
  font-family: var(--f-ar-display);
  font-size: 22px;
  color: var(--brass-bright);
  letter-spacing: 1px;
}
.hub-title-bar .en {
  font-family: var(--f-en-display);
  font-style: italic;
  font-size: 12px;
  color: var(--text-mute);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-top: 2px;
}
.hub-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  flex: 1;
  min-height: 0;
}
@media (max-width: 1000px) {
  .hub-grid { grid-template-columns: repeat(2, 1fr); }
}
.hub-card {
  background: linear-gradient(180deg, oklch(0.20 0.03 248 / 0.7), oklch(0.15 0.025 250 / 0.8));
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 16px 18px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  overflow: hidden;
  transition: all 0.25s ease;
  min-height: 0;
}
.hub-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: var(--r-lg);
  padding: 1px;
  background: linear-gradient(135deg, transparent, var(--brass-dim), transparent 60%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s;
}
.hub-card:hover {
  transform: translateY(-3px);
  border-color: var(--brass-dim);
  box-shadow: var(--shadow-strong), var(--shadow-brass-glow);
}
.hub-card:hover::before { opacity: 1; }

.hub-card .num {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--brass-mid);
  letter-spacing: 2px;
}
.hub-card .name-ar {
  font-family: var(--f-ar-display);
  font-size: 22px;
  color: var(--ivory);
  line-height: 1.1;
}
.hub-card .name-en {
  font-family: var(--f-en-display);
  font-style: italic;
  font-size: 13px;
  color: var(--brass-bright);
  letter-spacing: 0.8px;
}
.hub-card .desc {
  font-family: var(--f-ar-body);
  font-size: 12px;
  color: var(--text-dim);
  line-height: 1.5;
  margin-top: 2px;
}
.hub-card .glyph {
  position: absolute;
  bottom: -16px;
  right: -16px;
  width: 130px;
  height: 130px;
  opacity: 0.15;
  pointer-events: none;
  transition: opacity 0.3s;
}
.hub-card:hover .glyph { opacity: 0.36; }

.hub-title {
  position: absolute;
  top: 22px;
  left: 60px;
  right: 60px;
  text-align: center;
}
.hub-title .ar {
  font-family: var(--f-ar-display);
  font-size: 22px;
  color: var(--brass-bright);
  letter-spacing: 1px;
}
.hub-title .en {
  font-family: var(--f-en-display);
  font-style: italic;
  font-size: 13px;
  color: var(--text-mute);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-top: 3px;
}

/* tags */
.tag {
  display: inline-block;
  padding: 2px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--brass-mid);
  font-family: var(--f-mono);
}

/* Specifically for arabic context */
[dir="rtl"] { unicode-bidi: plaintext; }

/* utility */
.row { display: flex; gap: 8px; align-items: center; }
.col { display: flex; flex-direction: column; gap: 8px; }
.spacer { flex: 1; }
.sep { height: 1px; background: var(--line-soft); margin: 4px 0; }
