/* Shiyan Rates. Approved look: rates-design/rates-v3-AB.html (city board) + rates-v4-world.html (world). */
:root {
  --olive-900: #2f3b1a; --olive-700: #556b2f; --olive-400: #98b05d; --olive-100: #e9eed6;
  --gold: #c9a961; --gold-hi: #e6cf96;
  --bg: #faf6ec; --surface: #fff; --line: #e6dcc6; --text: #2b231b; --muted: #6f6253;
  --board: #1c2410; --board-2: #263016; --board-line: rgba(230,207,150,.14); --board-muted: #c9c0a8;
  --up: #4f7a3a; --down: #b3412f; --up-hi: #a9e38a; --down-hi: #f0a08f;
  --num: "Bricolage Grotesque", system-ui, sans-serif;
  --ku: "Noto Kufi Arabic", "Bricolage Grotesque", sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--ku); font-size: 15px; }
:lang(en) body, body:lang(en) { font-family: var(--num); }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--olive-700); outline-offset: 2px; border-radius: 8px; }
.num { font-family: var(--num); font-variant-numeric: tabular-nums; direction: ltr; unicode-bidi: isolate; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px 40px; }
.sub { color: var(--muted); font-size: 12.5px; }
.up { color: var(--up); } .down { color: var(--down); }
.board .up { color: var(--up-hi); } .board .down { color: var(--down-hi); }
.fi { width: 30px; height: 22px; border-radius: 5px; background-size: cover; box-shadow: 0 0 0 1px rgba(0,0,0,.08); flex-shrink: 0; display: inline-block; }
section { margin-top: 18px; }
h2 { font-size: 17px; margin: 0 0 12px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 18px; }
.sec-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.sec-head h2 { margin: 0; }

/* header */
header { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 16px 0 6px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; text-decoration: none; }
.mark { width: 36px; height: 36px; border-radius: 10px; background: var(--olive-700); display: grid; place-items: center; color: var(--gold-hi); font-family: var(--num); font-weight: 800; }
.brand small { display: block; font-weight: 500; font-size: 12px; color: var(--muted); }
.langs { display: flex; gap: 2px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.langs a { padding: 6px 12px; border-radius: 999px; font-size: 13px; color: var(--muted); text-decoration: none; min-height: 32px; display: grid; place-items: center; }
.langs a[aria-current] { background: var(--olive-700); color: #fff; }

/* currency tabs */
.tabs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 12px -16px 12px; padding: 0 16px; }
.tabs::-webkit-scrollbar { display: none; }
.tab { flex: 0 0 auto; padding: 9px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); font-weight: 700; font-size: 14px; white-space: nowrap; min-height: 42px; }
.tab[aria-pressed="true"] { background: var(--olive-900); border-color: var(--olive-900); color: var(--gold-hi); }

/* the board: Zakho -> Baghdad road */
.board { background: radial-gradient(120% 140% at 85% 0%, var(--board-2), var(--board)); color: #f4ecd8; border-radius: 26px; padding: 24px 26px; position: relative; overflow: hidden; margin-top: 0; }
.board::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(0deg, rgba(255,255,255,.025) 0 2px, transparent 2px 4px); pointer-events: none; }
.board > * { position: relative; z-index: 1; }
.btop { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.btop b { color: var(--gold-hi); font-size: 17px; }
.live { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--board-muted); }
.dot { width: 9px; height: 9px; border-radius: 50%; background: #8fd16a; box-shadow: 0 0 0 4px rgba(143,209,106,.18); }
.dot.old { background: #c9a961; box-shadow: 0 0 0 4px rgba(201,169,97,.18); }
.cols, .stop, .road { display: grid; grid-template-columns: 34px 1fr 1fr 1fr; gap: 14px; align-items: center; }
.cols { color: var(--board-muted); font-size: 13px; margin: 16px 0 6px; }
.stop { width: 100%; background: none; border: 0; padding: 4px 0; text-align: start; color: inherit; border-radius: 12px; }
.stop:hover .name { color: var(--gold-hi); }
.pin { width: 20px; height: 20px; border-radius: 50%; border: 4px solid var(--gold-hi); background: var(--board); justify-self: center; }
.stop.home .pin { background: var(--gold-hi); box-shadow: 0 0 0 6px rgba(230,207,150,.16); }
.name { font-size: 22px; font-weight: 800; }
.name small { display: block; font-size: 13px; font-weight: 700; }
.price { position: relative; }
.price .num { display: block; font-size: clamp(22px, 4.2vw, 46px); font-weight: 800; color: var(--gold-hi); line-height: 1.1; }
.price .none { color: var(--board-muted); font-size: 14px; }
.tag { position: absolute; top: 100%; inset-inline-start: 0; white-space: nowrap; font-size: 11.5px; font-weight: 700; color: var(--olive-900); background: var(--gold-hi); border-radius: 6px; padding: 2px 8px; }
.road { height: 46px; }
.road i { width: 4px; height: 100%; background: repeating-linear-gradient(180deg, var(--gold) 0 8px, transparent 8px 14px); justify-self: center; }
.road span { font-size: 12.5px; color: var(--board-muted); grid-column: 2 / -1; }
.bfoot { margin-top: 14px; color: var(--board-muted); font-size: 13px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.bars { display: inline-flex; gap: 3px; vertical-align: middle; margin-inline-end: 6px; }
.bars i { width: 6px; height: 14px; border-radius: 2px; background: rgba(152,176,93,.25); }
.bars i.on { background: var(--olive-400); }
.notice { background: rgba(230,207,150,.12); border: 1px solid var(--board-line); color: var(--gold-hi); border-radius: 12px; padding: 10px 12px; font-size: 13px; margin-top: 12px; }

/* other currencies + converter */
.row2 { display: grid; grid-template-columns: 1.3fr 1fr; gap: 18px; }
.row2 > section { margin-top: 0; }
.mini { width: 100%; border-collapse: collapse; }
.mini th { font-size: 12.5px; color: var(--muted); font-weight: 500; text-align: start; padding: 0 4px 8px; }
.mini td { padding: 10px 4px; border-top: 1px solid var(--line); font-weight: 700; }
.field { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 14px; padding: 6px 8px 6px 14px; background: var(--bg); margin-bottom: 10px; }
.field input { flex: 1; min-width: 0; border: 0; background: none; font-family: var(--num); font-size: 22px; font-weight: 800; height: 44px; outline: none; direction: ltr; }
.field select { border: 1px solid var(--line); border-radius: 10px; background: var(--surface); height: 40px; padding: 0 8px; max-width: 55%; }

/* world: neighbours strip */
.near { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px 2px; }
.near::-webkit-scrollbar { display: none; }
.nb { flex: 0 0 auto; min-width: 150px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 14px; text-align: start; }
.nb .top { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14px; }
.nb .v { display: block; font-size: 24px; font-weight: 800; margin-top: 10px; }
.nb small { font-size: 12px; }

/* travel calculator */
.travel { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: center; }
.travel .q { font-size: 15px; color: var(--board-muted); display: block; margin-bottom: 8px; }
.pick { display: flex; align-items: center; gap: 10px; background: rgba(255,255,255,.07); border: 1px solid var(--board-line); border-radius: 14px; padding: 6px 12px; margin-bottom: 14px; }
.pick select, .pick input { flex: 1; min-width: 0; background: none; border: 0; color: #f4ecd8; height: 42px; outline: none; font-weight: 700; }
.pick select option { color: #2b231b; }
.pick input { font-family: var(--num); font-size: 22px; font-weight: 800; color: var(--gold-hi); direction: ltr; }
.ans { text-align: center; }
.ans .fi { width: 54px; height: 40px; border-radius: 8px; }
.ans .big { display: block; font-size: clamp(32px, 6vw, 56px); font-weight: 800; color: var(--gold-hi); margin-top: 8px; }
.ans small { color: var(--board-muted); }

/* all currencies */
.search { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 0 14px; height: 46px; background: var(--bg); margin-bottom: 10px; }
.chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin-bottom: 10px; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: 0 0 auto; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line); background: none; font-size: 13.5px; font-weight: 700; min-height: 38px; }
.chip[aria-pressed="true"] { background: var(--olive-900); border-color: var(--olive-900); color: var(--gold-hi); }
.rows { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 22px; }
.row { display: flex; align-items: center; gap: 10px; padding: 8px 2px; border-top: 1px solid var(--line); }
.row .open { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; background: none; border: 0; padding: 4px 0; text-align: start; }
.row .n { flex: 1; min-width: 0; }
.row .n b { display: block; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .n small { color: var(--muted); font-size: 12px; }
.row .r .num { display: block; font-weight: 800; font-size: 16px; }
.row .r small { font-size: 12px; font-weight: 700; }
.star { background: none; border: 0; color: var(--gold); font-size: 20px; width: 40px; height: 40px; border-radius: 10px; flex-shrink: 0; }
.more { margin-top: 10px; width: 100%; height: 44px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); font-weight: 700; }

/* movers */
.movers { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.mv { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); }
.mv .n { flex: 1; font-weight: 700; font-size: 14px; }

/* map */
.map { width: 100%; aspect-ratio: 2 / 1; display: block; background: var(--bg); border-radius: 14px; touch-action: manipulation; }
.map path { fill: #d9d0b8; stroke: #fff; stroke-width: .4; cursor: pointer; }
.map path:hover, .map path.sel { fill: var(--olive-700); }
.map path.home { fill: var(--gold); }
.mapinfo { display: flex; align-items: center; gap: 10px; margin-top: 10px; min-height: 44px; }

/* gold rows on the board */
.gold .price .num { font-size: clamp(20px, 3.6vw, 38px); }

/* chart sheet */
.sheet { position: fixed; inset: 0; z-index: 50; display: grid; place-items: end center; background: rgba(20,17,12,.45); }
.sheet[hidden] { display: none; }
.panel { width: min(640px, 100%); background: var(--surface); border-radius: 22px 22px 0 0; padding: 18px 18px calc(18px + env(safe-area-inset-bottom)); max-height: 90dvh; overflow: auto; }
@media (min-width: 761px) { .sheet { place-items: center; } .panel { border-radius: 22px; } }
.ph { display: flex; align-items: center; gap: 10px; }
.ph b { flex: 1; font-size: 17px; }
.x { width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); font-size: 18px; }
.ranges { display: flex; gap: 6px; margin: 12px 0; }
.chart { width: 100%; height: 220px; display: block; }
.chart .ln { fill: none; stroke: var(--olive-700); stroke-width: 2.5; vector-effect: non-scaling-stroke; }
.chart .ar { fill: rgba(85,107,47,.1); }
.empty { text-align: center; color: var(--muted); padding: 40px 0; }

footer { text-align: center; color: var(--muted); font-size: 12.5px; padding-top: 26px; line-height: 1.8; }
footer a { color: var(--olive-700); }

/* ───────── Live background: dark olive world map, gold pulse on the place being shown (Fanar, 2026-10-21).
   The map slides so the place sits under the pulse; the pulse itself stays put (same ping as shiyanagency.com). */
body { background: #141b0c; }
.bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none;
  background: radial-gradient(120% 90% at 50% 38%, #2c3a17 0%, #1a2410 55%, #10160a 100%); }
.bg-world { position: absolute; left: 0; top: 0; width: 2000px; height: 1000px; transform-origin: 0 0; opacity: 0; transition: opacity 1.2s ease; will-change: transform; }
.bg-world.ready { opacity: 1; }
.bg-world.moving { transition: transform 1.6s cubic-bezier(.65, 0, .25, 1), opacity 1.2s ease; }
.bg-world path { fill: #34441d; stroke: #4b5e2a; stroke-width: .6; vector-effect: non-scaling-stroke; }
.bg-world path.on { fill: #4a5f27; }
.bg-world .grat { fill: none; stroke: rgba(230,207,150,.06); stroke-width: .5; vector-effect: non-scaling-stroke; }
.bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20,27,12,.15), rgba(20,27,12,.55)); }
.bg-pin { position: absolute; left: 50%; top: var(--pin-y, 30%); width: 0; height: 0; z-index: 1; transition: opacity .4s; }
.bg-pin.hide { opacity: 0; }
.bg-pin i { position: absolute; left: -7px; top: -7px; width: 14px; height: 14px; border-radius: 50%; background: var(--gold-hi); box-shadow: 0 0 18px 4px rgba(230,207,150,.45); }
.bg-pin b { position: absolute; left: -7px; top: -7px; width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid var(--gold-hi); animation: ping 2.6s ease-out infinite; }
.bg-pin b + b { animation-delay: 1.3s; }
.bg-pin > span { position: absolute; top: 16px; left: 0; transform: translateX(-50%); width: max-content; white-space: nowrap; color: var(--gold-hi); font-weight: 700; font-size: 13px; letter-spacing: .02em; text-shadow: 0 1px 8px rgba(0,0,0,.6); display: flex; align-items: center; gap: 6px; }
.bg-pin > span .fi { width: 20px; height: 15px; }
@keyframes ping { from { transform: scale(1); opacity: .9; } to { transform: scale(5); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .bg-world.moving { transition: opacity 1.2s ease; } .bg-pin b { animation: none; } }

/* Text that sits straight on the dark map turns light; cards keep their cream look. */
header .brand, header .brand small, .near-head h2, .near-head .sub, footer, footer a { color: #efe6cf; }
header .brand small, .near-head .sub, footer { color: #c9c0a8; }
.mark { box-shadow: 0 0 0 1px rgba(230,207,150,.25); }
.tab { background: rgba(255,253,246,.92); }
/* Glass board: the map and its pulse show through. The empty stage above it is the map's window. */
.stage { height: 120px; }
.board { background: linear-gradient(180deg, rgba(30,40,16,.78), rgba(16,22,10,.9)); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  box-shadow: 0 30px 60px -30px rgba(0,0,0,.7); border: 1px solid rgba(230,207,150,.14); }
.card, .nb { box-shadow: 0 24px 50px -30px rgba(0,0,0,.6); }

/* Grid children may shrink below their content (long currency names in selects and table heads). */
.row2 > *, .travel > *, .cols > *, .stop > * { min-width: 0; }
.pick select { width: 100%; text-overflow: ellipsis; }
.row2 .card { overflow-x: auto; }

@media (max-width: 760px) {
  .board { padding: 18px 14px; border-radius: 22px; }
  .cols, .stop { grid-template-columns: 26px 1.1fr 1fr 1fr; gap: 8px; }
  .road { grid-template-columns: 26px 1.1fr 1fr 1fr; gap: 8px; }
  .road span { font-size: 11.5px; }
  .name { font-size: 17px; }
  .name small { font-size: 12px; }
  .row2, .travel, .movers { grid-template-columns: 1fr; }
  .rows { grid-template-columns: 1fr; }
}
@media (min-width: 761px) and (max-width: 1060px) { .rows { grid-template-columns: 1fr 1fr; } }
@media (prefers-reduced-motion: no-preference) { .tab, .chip, .stop { transition: background .15s, color .15s; } }
