/* God's Eye of Forex
   Ink-navy desk, bone type, a violet iris. Buy, sell and wait each own one colour
   and nothing else uses them. One typeface (Archivo) worked across its width axis:
   condensed for the call, normal for reading, tabular figures for prices. */

@font-face {
  font-family: 'Archivo';
  src: url('/fonts/archivo.woff2') format('woff2');
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  --abyss: #0a1220;
  --deep: #0f1a2c;
  --raised: #152238;
  --rim: #22314b;
  --bone: #ece6d8;
  --mist: #94a1b9;
  --iris: #8473f2;
  --buy: #35c2a0;
  --sell: #f26b55;
  --wait: #e3b551;
  --tone: var(--mist); /* follows the current call */
  --radius: 14px;
  --gap: 16px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { color-scheme: dark; }
body {
  margin: 0;
  background:
    radial-gradient(1200px 520px at 78% -8%, rgba(132, 115, 242, 0.16), transparent 62%),
    var(--abyss);
  background-attachment: fixed;
  color: var(--bone);
  font: 400 15px/1.5 'Archivo', system-ui, sans-serif;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }
button, select, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--iris); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.note { color: var(--mist); font-size: 13px; }

/* ---- Lock screen ---- */
.lock { min-height: 100dvh; display: grid; place-items: center; padding: 24px; }
.lock-card { width: min(400px, 100%); display: grid; gap: 14px; text-align: left; }
.lock-eye { width: 132px; color: var(--mist); margin-bottom: 6px; }
.lock-card h1 { font-size: 34px; line-height: 1.05; font-stretch: 70%; font-weight: 700; letter-spacing: 0.005em; }
.lock-sub { color: var(--mist); max-width: 34ch; }
.field { display: grid; gap: 6px; margin-top: 8px; }
.field span { font-size: 13px; color: var(--mist); }
.field input {
  background: var(--deep); border: 1px solid var(--rim); border-radius: 10px;
  padding: 13px 14px; font-size: 17px; letter-spacing: 0.08em;
}
.field input:focus { border-color: var(--iris); outline: none; }
.btn-primary {
  background: var(--iris); color: #0b0f1c; border: 0; border-radius: 10px;
  padding: 13px 16px; font-weight: 650; font-size: 16px;
}
.btn-primary:hover { filter: brightness(1.08); }
.btn-primary:disabled { opacity: 0.6; cursor: progress; }
.lock-error { color: var(--sell); font-size: 14px; }

/* ---- Top bar ---- */
.practice { background: var(--wait); color: #1c1503; text-align: center; padding: 7px 14px; font-weight: 600; font-size: 14px; }
.top {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  padding: 14px clamp(14px, 3vw, 32px);
  border-bottom: 1px solid var(--rim);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--bone); text-decoration: none; font-weight: 700; font-stretch: 78%; font-size: 20px; }
.brand-mark { width: 38px; color: var(--bone); }
.brand-iris { fill: var(--iris); }
.brand-pupil { fill: var(--abyss); }
.picker select {
  background: var(--deep); border: 1px solid var(--rim); border-radius: 9px;
  padding: 8px 30px 8px 12px; font-weight: 550;
}
.top-right { margin-left: auto; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.links { display: flex; gap: 14px; }
.links a { color: var(--mist); text-decoration: none; font-size: 14px; border-bottom: 1px solid transparent; }
.links a:hover { color: var(--bone); border-bottom-color: var(--mist); }
.online { color: var(--mist); font-size: 14px; display: inline-flex; align-items: center; gap: 6px; }
.online i { width: 7px; height: 7px; border-radius: 50%; background: var(--buy); }
.online b { color: var(--bone); font-weight: 600; }
.btn-quiet { background: none; border: 1px solid var(--rim); border-radius: 9px; padding: 7px 12px; color: var(--mist); font-size: 14px; }
.btn-quiet:hover { color: var(--bone); border-color: var(--mist); }

.feed-alert { margin: 12px clamp(14px, 3vw, 32px) 0; padding: 10px 14px; border-radius: 10px; border: 1px solid var(--sell); color: var(--bone); background: rgba(242, 107, 85, 0.1); font-size: 14px; }

/* ---- Grid ---- */
.grid {
  display: grid; gap: var(--gap);
  grid-template-columns: repeat(12, minmax(0, 1fr));
  padding: var(--gap) clamp(14px, 3vw, 32px) 8px;
  max-width: 1480px; margin: 0 auto;
}
.card { grid-column: span 4; background: var(--deep); border: 1px solid var(--rim); border-radius: var(--radius); padding: 18px; min-width: 0; }
.card.chart-card { grid-column: span 8; padding-bottom: 14px; }
.card.eye-card { grid-column: span 4; border-color: color-mix(in srgb, var(--tone) 45%, var(--rim)); }
.card.half { grid-column: span 6; }
.card.wide { grid-column: 1 / -1; }
.card > h3, .card > .card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.fold { background: none; border: 0; color: var(--mist); font-size: 13px; font-weight: 500; padding: 2px 0; }
.fold:hover { color: var(--bone); }
.card.is-min > :not(h3):not(.card-head) { display: none; }
.card.is-min > h3, .card.is-min > .card-head { margin-bottom: 0; }
.card h3 { font-size: 15px; font-weight: 600; color: var(--bone); margin-bottom: 12px; }
.card h4 { font-size: 13px; font-weight: 500; color: var(--mist); margin-bottom: 2px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.card-head h3 { margin: 0; }
.sub-h { margin-top: 18px; }
.empty { color: var(--mist); padding: 18px 0; }

/* ---- Segmented buttons ---- */
.seg { display: inline-flex; background: var(--abyss); border: 1px solid var(--rim); border-radius: 10px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg button { background: none; border: 0; border-radius: 7px; padding: 6px 11px; color: var(--mist); font-size: 14px; font-weight: 500; }
.seg button:hover { color: var(--bone); }
.seg button[aria-pressed='true'] { background: var(--raised); color: var(--bone); box-shadow: inset 0 0 0 1px var(--rim); }
.seg-wide { display: grid; grid-template-columns: repeat(3, 1fr); width: 100%; }
.seg-wide button { padding: 8px 6px; display: grid; gap: 0; line-height: 1.25; }
.seg-wide small { font-size: 12px; font-weight: 400; color: var(--mist); }

/* ---- Price + chart ---- */
.price-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.mkt-name { font-size: 22px; font-weight: 650; font-stretch: 85%; }
.badge { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; border: 1px solid var(--buy); color: var(--buy); margin-right: 4px; }
.badge[data-state='delayed'], .badge[data-state='stale'], .badge[data-state='practice'] { border-color: var(--wait); color: var(--wait); }
.badge[data-state='down'] { border-color: var(--sell); color: var(--sell); }
.badge[data-state='closed'] { border-color: var(--mist); color: var(--mist); }
.price-block { text-align: right; }
.price { font-size: clamp(34px, 4.4vw, 52px); font-weight: 600; font-stretch: 88%; line-height: 1; letter-spacing: -0.01em; }
.price.tick-up { color: var(--buy); }
.price.tick-down { color: var(--sell); }
.price { transition: color 0.9s ease; }
.change { margin-top: 6px; font-size: 15px; color: var(--mist); }
.change.up { color: var(--buy); }
.change.down { color: var(--sell); }
.chart-controls { display: flex; gap: 8px; flex-wrap: wrap; }
.chart-tools { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 14px 0 8px; flex-wrap: wrap; }
.readout { min-height: 20px; }
.chart-wrap { position: relative; height: clamp(300px, 46vh, 470px); }
#chart { width: 100%; height: 100%; display: block; touch-action: pan-y; }
.chart-wrap .empty { position: absolute; inset: 0; display: grid; place-items: center; }
.levels { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; font-size: 13px; color: var(--mist); }
.levels b { color: var(--bone); font-weight: 550; margin-left: 5px; }

/* ---- The Eye ---- */
.eye-card[data-state='go'][data-side='buy'] { --tone: var(--buy); }
.eye-card[data-state='go'][data-side='sell'] { --tone: var(--sell); }
.eye-card[data-state='wait'] { --tone: var(--wait); }
.eye-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.eye { width: min(230px, 62%); height: auto; overflow: visible; }
.eye-white { fill: #0b1424; }
.eye-iris { fill: color-mix(in srgb, var(--tone) 55%, var(--iris)); }
.eye-rays line { stroke: rgba(10, 18, 32, 0.38); stroke-width: 1.4; }
.eye-rim { fill: none; stroke: rgba(10, 18, 32, 0.7); stroke-width: 5; }
.eye-pupil { fill: #070b14; }
.eye-glint { fill: rgba(236, 230, 216, 0.75); }
.eye-lid { fill: none; stroke: var(--bone); stroke-width: 2.6; stroke-linejoin: round; }
.score { text-align: right; line-height: 1; }
.score-num { display: block; font-size: 62px; font-weight: 700; font-stretch: 68%; color: var(--tone); }
.score-of { color: var(--mist); font-size: 13px; }
.headline { margin-top: 10px; font-size: clamp(30px, 2.9vw, 42px); line-height: 1.02; font-weight: 750; font-stretch: 66%; color: var(--tone); text-wrap: balance; }
.eye-card[data-state='no'] .headline, .eye-card[data-state='aside'] .headline, .eye-card[data-state='closed'] .headline, .eye-card[data-state='nodata'] .headline, .eye-card[data-state='late'] .headline { color: var(--bone); }
.verdict-line { margin: 8px 0 16px; color: var(--bone); max-width: 46ch; }
.notice { margin: -6px 0 16px; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--wait); color: var(--wait); font-size: 14px; max-width: 46ch; }

.asks { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.ask {
  background: var(--raised); border: 1px solid var(--rim); border-radius: 11px;
  padding: 13px 12px; text-align: left; font-weight: 600; font-size: 15px; line-height: 1.2;
}
.ask:hover { border-color: var(--mist); }
.ask[aria-pressed='true'] { border-color: var(--iris); box-shadow: inset 0 0 0 1px var(--iris); }
.ask-wide { grid-column: 1 / -1; }
.answer { margin-top: 10px; padding: 12px 14px; border-radius: 11px; background: var(--abyss); border-left: 3px solid var(--mist); }
.answer[data-ok='true'] { border-left-color: var(--buy); }
.answer[data-ok='false'] { border-left-color: var(--wait); }
.toggle { display: inline-flex; align-items: center; gap: 8px; margin-top: 12px; color: var(--mist); font-size: 14px; cursor: pointer; }
.toggle input { accent-color: var(--iris); width: 16px; height: 16px; }

/* ---- Plan ---- */
.plan dl { display: grid; grid-template-columns: auto 1fr; gap: 9px 16px; margin: 0; }
.plan dt { color: var(--mist); }
.plan dd { margin: 0; text-align: right; font-weight: 550; }
.plan .why { grid-column: 1 / -1; text-align: left; color: var(--mist); font-size: 13px; font-weight: 400; margin-top: -4px; }
.ladder { margin-top: 14px; border-top: 1px solid var(--rim); padding-top: 12px; display: grid; gap: 7px; }
.ladder li { display: grid; grid-template-columns: 44px 1fr auto; gap: 10px; align-items: center; }
.ladder .bar { height: 5px; border-radius: 3px; background: var(--raised); overflow: hidden; }
.ladder .bar i { display: block; height: 100%; background: var(--mist); border-radius: 3px; }
.ladder .tp { color: var(--mist); }
.ladder .px { font-weight: 550; }
.side-buy { color: var(--buy); }
.side-sell { color: var(--sell); }

/* ---- Sessions and liquidity ---- */
.sessions { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.liq-head { font-size: clamp(22px, 2.1vw, 30px); font-weight: 700; font-stretch: 70%; line-height: 1.08; text-wrap: balance; }
.liq-line { margin-top: 6px; max-width: 64ch; }
.range { position: relative; margin: 34px 4px 30px; height: 6px; border-radius: 3px; background: var(--raised); }
.range i { font-style: normal; }
.range .span { position: absolute; top: 0; bottom: 0; background: color-mix(in srgb, var(--iris) 55%, var(--raised)); border-radius: 3px; }
.range .end { position: absolute; top: -6px; width: 2px; height: 18px; background: var(--bone); }
.range .end.taken { background: var(--mist); opacity: 0.6; }
.range .end span { position: absolute; top: 22px; transform: translateX(-50%); white-space: nowrap; font-size: 12.5px; color: var(--mist); }
.range .end b { color: var(--bone); font-weight: 600; }
.range .now { position: absolute; top: -9px; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: var(--bone); box-shadow: 0 0 0 3px var(--deep); }
.range .now span { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); white-space: nowrap; font-size: 12.5px; font-weight: 600; }
.sess-list { display: grid; gap: 9px; }
.sess-list li { display: grid; grid-template-columns: 12px 1fr auto; gap: 10px; align-items: baseline; }
.sess-list .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--rim); align-self: center; }
.sess-list li[data-open='true'] .dot { background: var(--buy); }
.sess-list li[data-open='true'] .nm { font-weight: 650; }
.sess-list .kz .nm { color: var(--mist); }
.sess-list .when { color: var(--mist); font-size: 14px; text-align: right; }
.sess-now { color: var(--mist); font-size: 13px; margin-bottom: 10px; }

/* ---- Path + reload zones (plan card) ---- */
.path { margin-top: 14px; border-top: 1px solid var(--rim); padding-top: 12px; }
.path p { max-width: 52ch; }
.path .track { height: 5px; border-radius: 3px; background: var(--raised); overflow: hidden; margin-top: 8px; }
.path .track i { display: block; height: 100%; background: var(--iris); border-radius: 3px; }
.reloads { margin-top: 14px; border-top: 1px solid var(--rim); padding-top: 12px; }
.reloads ul { display: grid; gap: 7px; }
.reloads li { display: flex; justify-content: space-between; gap: 12px; }
.reloads .st { color: var(--mist); }
.reloads li[data-state='in'] .st { color: var(--wait); font-weight: 600; }
.reloads li[data-state='passed'] { opacity: 0.55; }
.mini-h { font-size: 13px; font-weight: 500; color: var(--mist); margin-bottom: 6px; }

/* ---- Checks + factors ---- */
.checks { display: grid; gap: 10px; }
.checks li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; }
.checks .dot { width: 18px; height: 18px; border-radius: 50%; margin-top: 2px; border: 2px solid var(--mist); }
.checks li[data-ok='true'] .dot { background: var(--buy); border-color: var(--buy); }
.checks li[data-ok='false'] .dot { border-color: var(--wait); }
.checks b { font-weight: 600; }
.checks p { color: var(--mist); font-size: 14px; }
.factors { display: grid; gap: 11px; }
.factors .row { display: flex; justify-content: space-between; gap: 10px; }
.factors .meter { height: 5px; background: var(--raised); border-radius: 3px; margin: 5px 0 4px; overflow: hidden; }
.factors .meter i { display: block; height: 100%; background: var(--iris); border-radius: 3px; }
.factors p { color: var(--mist); font-size: 13px; }

/* ---- Reads ---- */
.read + .read { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--rim); }
.read p { max-width: 62ch; }

/* ---- Tape ---- */
.tape-pace { font-size: 30px; font-weight: 700; font-stretch: 70%; line-height: 1.1; }
.split { display: flex; height: 8px; border-radius: 4px; overflow: hidden; margin: 14px 0 8px; background: var(--raised); }
.split .u { background: var(--buy); }
.split .d { background: var(--sell); }
.split-labels { display: flex; justify-content: space-between; font-size: 14px; }

/* ---- Calendar ---- */
.cal { display: grid; gap: 10px; }
.cal li { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding-bottom: 10px; border-bottom: 1px solid var(--rim); }
.cal li:last-child { border-bottom: 0; padding-bottom: 0; }
.cal .title { font-weight: 600; }
.cal .count { font-weight: 600; text-align: right; }
.cal .when, .cal .nums { color: var(--mist); font-size: 13px; }
.cal .nums { text-align: right; }
.cal li.past { opacity: 0.55; }
.cal li.soon .count { color: var(--wait); }
#cal-note { margin-top: 10px; }

/* ---- Cross-market ---- */
.cross-verdict { font-size: 24px; font-weight: 700; font-stretch: 72%; line-height: 1.1; margin-bottom: 6px; }
.cross-list { display: grid; gap: 8px; margin-top: 12px; }
.cross-list li { display: flex; justify-content: space-between; gap: 12px; }
.cross-list small { display: block; color: var(--mist); font-size: 13px; }
.up { color: var(--buy); }
.down { color: var(--sell); }

/* ---- Gaps ---- */
.gaps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px; }
.gap h4 { font-size: 15px; color: var(--bone); font-weight: 600; }
.gap .big { font-size: 24px; font-weight: 700; font-stretch: 72%; line-height: 1.15; margin: 2px 0 4px; }
.gap .fill { height: 6px; background: var(--raised); border-radius: 3px; overflow: hidden; margin: 10px 0 6px; }
.gap .fill i { display: block; height: 100%; background: var(--iris); }
.gap p { color: var(--mist); font-size: 13px; }
.gap p + p { margin-top: 6px; }

/* ---- Watchlist ---- */
.watch { display: grid; }
.watch button {
  display: grid; grid-template-columns: 1fr auto 76px 88px; gap: 12px; align-items: center;
  background: none; border: 0; border-top: 1px solid var(--rim); padding: 10px 6px; text-align: left; border-radius: 0;
}
.watch button:first-child { border-top: 0; }
.watch button:hover { background: var(--raised); }
.watch button[aria-current='true'] { background: var(--raised); box-shadow: inset 3px 0 0 var(--iris); }
.watch .nm { font-weight: 600; }
.watch .px, .watch .pc { text-align: right; }
.watch .lean { text-align: right; font-size: 13px; color: var(--mist); white-space: nowrap; }

/* ---- Footer ---- */
.foot { max-width: 1480px; margin: 0 auto; padding: 18px clamp(14px, 3vw, 32px) 40px; color: var(--mist); font-size: 13px; display: grid; gap: 6px; }
.foot p { max-width: 96ch; }

/* ---- Smaller screens ---- */
@media (max-width: 1080px) {
  .card.chart-card, .card.eye-card { grid-column: 1 / -1; }
  .card { grid-column: span 6; }
  .card.half { grid-column: 1 / -1; }
  .eye-card { order: -1; }
  .sessions { grid-template-columns: 1fr; gap: 22px; }
}
@media (max-width: 680px) {
  :root { --gap: 12px; }
  .card, .card.half { grid-column: 1 / -1; }
  .card { padding: 15px; }
  .top { gap: 10px; }
  .brand span { font-size: 18px; }
  .top-right { width: 100%; margin-left: 0; justify-content: space-between; }
  .chart-wrap { height: 300px; }
  .watch button { grid-template-columns: 1fr auto 66px; }
  .watch .lean { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .price { transition: none; }
}
