/* Rawaayat Orders: app layout and components. Motion + icons live in rawaayat-ui.css */
:root {
  --bg: #F6F5F2; --surface: #FFFFFF; --line: #ECE8DF; --line2: #D8D4CB; --ink: #1E1C18; --muted: #625E55; --muted2: #8A857B;
  --gold: #7D5A17; --gold-2: #5E430F; --gold-soft: #F5EEDD; --gold-light: #E3C67E; --gold-mid: #C9A24E;
  --dark: #2B2925; --dark-2: #221F1A; --green: #1C6A3A; --green-soft: #E2F0E6; --blue: #1F4C86; --blue-soft: #E3ECF8;
  --red: #8E2B2B; --red-soft: #F7E4E4; --amber: #8A5300; --amber-soft: #FCEFD8;
  --radius: 18px; --nav-h: 68px;
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font-family: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased; }
body { min-height: 100vh; min-height: 100dvh; background: radial-gradient(120% 50% at 100% 0%, #F3EBDA 0%, var(--bg) 55%) fixed; }
a { color: var(--gold); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, p { margin: 0; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.serif { font-family: 'Cormorant Garamond', Georgia, serif; font-style: italic; font-weight: 600; }
.muted { color: var(--muted); }
.nowrap { white-space: nowrap; }
.num { white-space: nowrap; letter-spacing: -0.02em; display: inline-block; max-width: 100%; }
.rs { font-size: .58em; font-weight: 700; opacity: .8; margin-right: .12em; letter-spacing: 0; }

/* ---------- shell ---------- */
#app { min-height: 100vh; min-height: 100dvh; }
/* Glow layers sit outside cards; clip (not hidden) so focusing an input can never scroll a card sideways. */
.foil, .dark, .login { overflow: clip; }
/* One column on phones, never wider than the screen (min-content of nowrap figures must not stretch it). */
.desk-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
.desk-grid > * { min-width: 0; }
html, body { overflow-x: clip; }
.layout { display: flex; min-height: 100vh; min-height: 100dvh; }
.side { display: none; }
.main { flex: 1; min-width: 0; }
.screen { max-width: 560px; margin: 0 auto; padding: calc(14px + var(--safe-t)) 16px calc(var(--nav-h) + 34px + var(--safe-b)); display: flex; flex-direction: column; gap: 14px; }
.screen.wide { max-width: 1240px; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.title { font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.subtitle { font-size: 13px; color: var(--muted); font-weight: 500; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { width: 36px; height: 34px; display: block; }
.brand .serif { font-size: 27px; line-height: 1; }

.bottomnav { position: fixed; left: 12px; right: 12px; bottom: calc(12px + var(--safe-b)); height: var(--nav-h); border-radius: 24px; border: 1px solid rgba(255,255,255,.9); box-shadow: 0 14px 34px -14px rgba(43,41,37,.45); display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: center; padding: 0 4px; z-index: 40; max-width: 536px; margin: 0 auto; }
.navlink { display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--muted); font-size: 11px; font-weight: 600; min-height: 48px; justify-content: center; position: relative; }
.navlink[aria-current="page"] { color: var(--gold); font-weight: 800; }
.navlink[aria-current="page"]::after { content: ""; width: 5px; height: 5px; border-radius: 3px; background: var(--gold-mid); position: absolute; bottom: 2px; }
.navfab { justify-self: center; width: 56px; height: 56px; border-radius: 20px; color: #fff; display: flex; align-items: center; justify-content: center; margin-top: -26px; border: 4px solid var(--bg); }

/* ---------- surfaces ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; box-shadow: 0 8px 20px -18px rgba(43,41,37,.5); }
.card.tight { padding: 10px 12px; }
.card h2, .section-title { font-size: 15px; font-weight: 800; display: flex; align-items: center; gap: 8px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.dark { background: linear-gradient(150deg, #34312B 0%, var(--dark-2) 100%); color: #fff; border-radius: 22px; padding: 16px; box-shadow: 0 24px 40px -26px rgba(34,31,26,.75); }
.dark .lbl { font-size: 12px; color: #D9D3C4; font-weight: 600; }
.dark .divider { border-top: 1px solid rgba(255,255,255,.12); }
.stat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 10px 12px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.stat .k { font-size: 11px; color: var(--muted); font-weight: 600; }
.stat .v { font-size: 18px; font-weight: 800; min-width: 0; }
.stat.dk { background: var(--dark); border-color: var(--dark); color: #fff; }
.stat.dk .k { color: #D9D3C4; }

/* ---------- controls ---------- */
.btn { height: 48px; padding: 0 16px; border-radius: 14px; border: 1px solid #E7E4DD; background: #fff; font-weight: 700; font-size: 15px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; color: var(--ink); }
.btn.sm { height: 38px; padding: 0 12px; font-size: 13px; border-radius: 11px; }
.btn.lg { height: 58px; font-size: 17px; border-radius: 18px; width: 100%; }
.btn.gold, .navfab { border: 0; color: #fff; background: linear-gradient(135deg, #9A7428 0%, #7D5A17 45%, #5E430F 100%); }
.navfab { border: 4px solid var(--bg); }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.soft { background: var(--gold-soft); border-color: #EADFC4; color: var(--gold-2); }
.btn.danger { color: var(--red); }
.btn[disabled] { background: #D8D4CB !important; color: var(--muted) !important; box-shadow: none !important; cursor: not-allowed; animation: none !important; }
.iconbtn { width: 44px; height: 44px; border-radius: 14px; border: 1px solid #E7E4DD; background: #fff; display: inline-flex; align-items: center; justify-content: center; color: var(--ink); flex-shrink: 0; }
.iconbtn.round { border-radius: 22px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label, .flabel { font-size: 13px; font-weight: 600; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.req { color: #9A3B1E; }
.input, .select, .textarea { width: 100%; height: 50px; border: 1px solid var(--line2); border-radius: 14px; padding: 0 14px; font-size: 16px; background: #fff; color: var(--ink); }
.textarea { height: auto; min-height: 84px; padding: 12px 64px 12px 12px; line-height: 1.45; resize: vertical; }
.select { appearance: none; -webkit-appearance: none; padding-right: 44px; font-weight: 700; }
.inwrap { position: relative; }
.inwrap > .lead { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); pointer-events: none; }
.inwrap > .trail { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); pointer-events: none; color: var(--muted); }
.has-lead { padding-left: 58px; }
.has-icon { padding-left: 42px; }
.search { display: flex; align-items: center; gap: 8px; height: 48px; border: 1px solid #E7E4DD; border-radius: 14px; padding: 0 12px; background: #fff; color: var(--muted); }
.search input { border: 0; outline: none; box-shadow: none !important; flex: 1; min-width: 0; font-size: 15px; background: transparent; color: var(--ink); }
.field-error { font-size: 12px; font-weight: 700; color: #9A3B1E; }
.invalid { border-color: #C76A4E !important; }
.money-in { display: flex; align-items: center; gap: 8px; height: 52px; border-radius: 14px; background: #fff; padding: 0 12px; border: 2px solid transparent; }
.money-in.big { height: 62px; }
.money-in span.cur { font-weight: 800; color: #9A7428; font-size: 14px; }
.money-in input { border: 0; outline: none; box-shadow: none !important; flex: 1; min-width: 0; font-size: 18px; font-weight: 700; background: transparent; color: var(--ink); }
.money-in.big input { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; }
.money-in:focus-within { border-color: var(--gold-mid); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.chips.scroll::-webkit-scrollbar { display: none; }
.chip { height: 40px; padding: 0 14px 0 11px; border-radius: 999px; border: 1px solid #E7E4DD; background: #fff; font-weight: 600; font-size: 14px; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; flex-shrink: 0; color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--dark); color: #fff; border-color: var(--dark); box-shadow: 0 6px 14px -8px rgba(43,41,37,.7); }
.chip .count { min-width: 22px; height: 22px; border-radius: 11px; font-size: 11px; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; background: #F0EDE6; color: var(--muted); padding: 0 6px; }
.chip[aria-pressed="true"] .count { background: var(--gold-light); color: var(--dark); }

.seg { position: relative; display: grid; grid-auto-columns: minmax(0, 1fr); grid-auto-flow: column; padding: 4px; background: rgba(236,233,226,.9); border-radius: 14px; }
.seg .ind { position: absolute; top: 4px; bottom: 4px; left: 4px; border-radius: 10px; background: #fff; box-shadow: 0 2px 8px -2px rgba(43,41,37,.25); }
.seg button { position: relative; z-index: 1; height: 38px; border: 0; background: transparent; border-radius: 10px; font-weight: 600; font-size: 14px; color: var(--muted); transition: color .3s; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.seg button[aria-selected="true"], .seg button[aria-pressed="true"] { color: var(--ink); font-weight: 700; }
.seg.dark-seg { background: rgba(255,255,255,.08); }
.seg.dark-seg .ind { background: rgba(255,255,255,.16); box-shadow: none; }
.seg.dark-seg button { color: #CFC8B8; }
.seg.dark-seg button[aria-selected="true"] { color: #fff; }

/* ---------- list rows ---------- */
.list { display: flex; flex-direction: column; gap: 8px; }
.row { display: flex; align-items: center; gap: 12px; background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 10px 12px 10px 10px; color: var(--ink); box-shadow: 0 6px 16px -14px rgba(43,41,37,.5); min-width: 0; }
.row .main-col { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.row .t { font-size: 15px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .s { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: flex; align-items: center; gap: 4px; }
.row .end { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex-shrink: 0; }
.row .amt { font-size: 14px; font-weight: 800; white-space: nowrap; }
.tile { width: 46px; height: 46px; border-radius: 14px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; }
.tile.sm { width: 34px; height: 34px; border-radius: 11px; }
.avatar { width: 44px; height: 44px; border-radius: 22px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; }
.avatar.gold { background: linear-gradient(135deg, #B8862B, #6E4F12); color: #fff; box-shadow: inset 0 1px 0 rgba(255,236,190,.5); }
.pill { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; font-weight: 700; padding: 3px 8px 3px 5px; border-radius: 999px; white-space: nowrap; }
.pill.new { background: var(--gold-soft); color: var(--gold-2); }
.pill.in_progress { background: var(--blue-soft); color: var(--blue); }
.pill.delivered { background: var(--green-soft); color: var(--green); }
.pill.cancelled { background: var(--red-soft); color: var(--red); }
.daylabel { font-size: 11px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; margin-top: 6px; }
.bar { height: 6px; border-radius: 3px; background: #F0EDE6; overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, #9A7428, var(--gold-light)); }
.empty { text-align: center; padding: 28px 16px; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 10px; font-size: 14px; }
.empty .tile { width: 56px; height: 56px; border-radius: 18px; background: var(--gold-soft); color: var(--gold); }
.skeleton { background: linear-gradient(90deg, #EEEBE4 0%, #F7F5F0 50%, #EEEBE4 100%); background-size: 200% 100%; animation: shimmertext 1.4s linear infinite; border-radius: 14px; }

/* ---------- sheets, toasts, overlays ---------- */
.overlay { position: fixed; inset: 0; z-index: 80; background: rgba(24,21,16,.55); -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); display: flex; flex-direction: column; justify-content: flex-end; align-items: center; }
.sheetbox { width: 100%; max-width: 560px; background: linear-gradient(180deg, #fff 0%, #FCFAF5 100%); border-radius: 30px 30px 0 0; padding: 10px 18px calc(22px + var(--safe-b)); display: flex; flex-direction: column; gap: 12px; box-shadow: 0 -20px 50px -20px rgba(0,0,0,.45); max-height: 92vh; overflow-y: auto; }
.grabber { width: 44px; height: 5px; border-radius: 3px; background: var(--line2); align-self: center; }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--nav-h) + 26px + var(--safe-b)); z-index: 120; background: var(--dark); color: #fff; padding: 12px 16px; border-radius: 14px; font-size: 14px; font-weight: 600; box-shadow: 0 14px 30px -10px rgba(0,0,0,.5); display: flex; align-items: center; gap: 8px; max-width: calc(100% - 32px); }
.toast.err { background: #7A2A1E; }
.offline-banner { position: fixed; top: calc(8px + var(--safe-t)); left: 50%; transform: translateX(-50%); z-index: 110; background: var(--amber-soft); color: var(--amber); border: 1px solid #F1D9A6; padding: 8px 14px; border-radius: 999px; font-size: 13px; font-weight: 700; display: flex; align-items: center; gap: 6px; box-shadow: 0 10px 20px -12px rgba(0,0,0,.4); }
.waveline { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 12px; background: #FBEDEA; color: var(--red); font-size: 13px; font-weight: 700; }
.mic { position: absolute; right: 8px; top: 8px; width: 50px; height: 50px; border-radius: 25px; border: 0; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #F7E9C6, #EBD39A); color: #6E4F12; box-shadow: 0 6px 14px -8px rgba(125,90,23,.8); }
.mic.on { background: #C0392B; color: #fff; }

/* celebration */
.celebrate { position: fixed; inset: 0; z-index: 100; background: rgba(24,21,16,.62); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); overflow: hidden; }
.celebrate .stage { position: absolute; left: 0; right: 0; bottom: 0; height: 100%; max-width: 560px; margin: 0 auto; overflow: hidden; }
.celebrate .card-done { position: absolute; left: 16px; right: 16px; top: max(18vh, 120px); background: linear-gradient(180deg, #fff, #FBF6EA); border-radius: 28px; padding: 64px 22px 22px; display: flex; flex-direction: column; align-items: center; gap: 8px; box-shadow: 0 30px 60px -20px rgba(0,0,0,.5); }
.medal-wrap { position: absolute; top: -46px; left: 50%; margin-left: -46px; width: 92px; height: 92px; }
.medal-disc { width: 92px; height: 92px; border-radius: 46px; background: radial-gradient(circle at 30% 25%, #FFF1CC 0%, #E3C67E 35%, #B8862B 70%, #7D5A17 100%); display: flex; align-items: center; justify-content: center; box-shadow: 0 12px 30px -8px rgba(125,90,23,.8), inset 0 2px 0 rgba(255,255,255,.6); }
.p0{left:-6px;bottom:18vh;--x:142px;--y:-457px;--r:644deg;--w:6px;--h:10px;--c:#F6E7BF;--t:2.07s;--dl:0.32s;border-radius:50%}.p1{right:-6px;bottom:18vh;--x:-114px;--y:-399px;--r:-328deg;--w:6px;--h:12px;--c:#E3C67E;--t:2.04s;--dl:0.02s}.p2{left:-6px;bottom:18vh;--x:204px;--y:-443px;--r:468deg;--w:6px;--h:6px;--c:#E3C67E;--t:2.38s;--dl:0.02s}.p3{right:-6px;bottom:18vh;--x:-279px;--y:-448px;--r:-536deg;--w:6px;--h:14px;--c:#9A7428;--t:2.25s;--dl:0.06s}.p4{left:-6px;bottom:18vh;--x:208px;--y:-672px;--r:-894deg;--w:6px;--h:10px;--c:#9A7428;--t:1.65s;--dl:0.07s}.p5{right:-6px;bottom:18vh;--x:-234px;--y:-652px;--r:677deg;--w:10px;--h:6px;--c:#F6E7BF;--t:1.84s;--dl:0.28s;border-radius:50%}.p6{left:-6px;bottom:18vh;--x:238px;--y:-504px;--r:323deg;--w:10px;--h:14px;--c:#EBD39A;--t:1.96s;--dl:0.21s}.p7{right:-6px;bottom:18vh;--x:-78px;--y:-440px;--r:-764deg;--w:8px;--h:12px;--c:#FFFFFF;--t:1.94s;--dl:0.34s}.p8{left:-6px;bottom:18vh;--x:79px;--y:-665px;--r:826deg;--w:8px;--h:14px;--c:#EBD39A;--t:1.88s;--dl:0.17s}.p9{right:-6px;bottom:18vh;--x:-264px;--y:-613px;--r:310deg;--w:8px;--h:6px;--c:#EBD39A;--t:2.13s;--dl:0.02s}.p10{left:-6px;bottom:18vh;--x:239px;--y:-538px;--r:831deg;--w:10px;--h:14px;--c:#EBD39A;--t:1.91s;--dl:0.23s;border-radius:50%}.p11{right:-6px;bottom:18vh;--x:-65px;--y:-616px;--r:-603deg;--w:6px;--h:6px;--c:#E3C67E;--t:1.77s;--dl:0.10s}.p12{left:-6px;bottom:18vh;--x:249px;--y:-506px;--r:-647deg;--w:10px;--h:10px;--c:#C9A24E;--t:1.96s;--dl:0.19s}.p13{right:-6px;bottom:18vh;--x:-286px;--y:-450px;--r:680deg;--w:8px;--h:6px;--c:#F6E7BF;--t:2.15s;--dl:0.13s}.p14{left:-6px;bottom:18vh;--x:119px;--y:-457px;--r:-324deg;--w:7px;--h:12px;--c:#E3C67E;--t:1.99s;--dl:0.21s}.p15{right:-6px;bottom:18vh;--x:-127px;--y:-524px;--r:-244deg;--w:8px;--h:14px;--c:#C9A24E;--t:2.15s;--dl:0.18s;border-radius:50%}.p16{left:-6px;bottom:18vh;--x:218px;--y:-407px;--r:707deg;--w:10px;--h:6px;--c:#FFFFFF;--t:1.92s;--dl:0.17s}.p17{right:-6px;bottom:18vh;--x:-162px;--y:-411px;--r:-435deg;--w:7px;--h:6px;--c:#C9A24E;--t:1.69s;--dl:0.21s}.p18{left:-6px;bottom:18vh;--x:86px;--y:-380px;--r:-820deg;--w:6px;--h:14px;--c:#9A7428;--t:1.62s;--dl:0.31s}.p19{right:-6px;bottom:18vh;--x:-217px;--y:-572px;--r:392deg;--w:8px;--h:14px;--c:#FFFFFF;--t:1.70s;--dl:0.30s}.p20{left:-6px;bottom:18vh;--x:179px;--y:-625px;--r:-735deg;--w:7px;--h:10px;--c:#EBD39A;--t:1.87s;--dl:0.09s;border-radius:50%}.p21{right:-6px;bottom:18vh;--x:-272px;--y:-462px;--r:-768deg;--w:8px;--h:12px;--c:#EBD39A;--t:2.03s;--dl:0.01s}.p22{left:-6px;bottom:18vh;--x:195px;--y:-532px;--r:898deg;--w:8px;--h:14px;--c:#C9A24E;--t:1.88s;--dl:0.08s}.p23{right:-6px;bottom:18vh;--x:-198px;--y:-637px;--r:577deg;--w:7px;--h:12px;--c:#B8862B;--t:1.92s;--dl:0.28s}.p24{left:-6px;bottom:18vh;--x:111px;--y:-645px;--r:-744deg;--w:6px;--h:10px;--c:#B8862B;--t:1.82s;--dl:0.09s}.p25{right:-6px;bottom:18vh;--x:-237px;--y:-689px;--r:-592deg;--w:8px;--h:14px;--c:#E3C67E;--t:1.78s;--dl:0.08s;border-radius:50%}.p26{left:-6px;bottom:18vh;--x:110px;--y:-552px;--r:-449deg;--w:6px;--h:6px;--c:#EBD39A;--t:1.88s;--dl:0.23s}.p27{right:-6px;bottom:18vh;--x:-273px;--y:-441px;--r:637deg;--w:7px;--h:6px;--c:#C9A24E;--t:1.95s;--dl:0.22s}.p28{left:-6px;bottom:18vh;--x:82px;--y:-582px;--r:-714deg;--w:6px;--h:12px;--c:#C9A24E;--t:2.39s;--dl:0.01s}.p29{right:-6px;bottom:18vh;--x:-211px;--y:-618px;--r:389deg;--w:10px;--h:14px;--c:#C9A24E;--t:2.04s;--dl:0.05s}.p30{left:-6px;bottom:18vh;--x:63px;--y:-432px;--r:779deg;--w:7px;--h:6px;--c:#B8862B;--t:1.76s;--dl:0.31s;border-radius:50%}.p31{right:-6px;bottom:18vh;--x:-67px;--y:-508px;--r:-457deg;--w:7px;--h:14px;--c:#F6E7BF;--t:2.04s;--dl:0.29s}.p32{left:-6px;bottom:18vh;--x:75px;--y:-561px;--r:709deg;--w:10px;--h:12px;--c:#9A7428;--t:1.72s;--dl:0.18s}.p33{right:-6px;bottom:18vh;--x:-283px;--y:-605px;--r:427deg;--w:7px;--h:12px;--c:#C9A24E;--t:1.98s;--dl:0.25s}.p34{left:-6px;bottom:18vh;--x:202px;--y:-411px;--r:573deg;--w:10px;--h:10px;--c:#9A7428;--t:1.65s;--dl:0.07s}.p35{right:-6px;bottom:18vh;--x:-70px;--y:-430px;--r:-759deg;--w:6px;--h:10px;--c:#FFFFFF;--t:1.86s;--dl:0.34s;border-radius:50%}
.g0{left:82%;--x:2px;--y:522px;--s:5px;--t:2.83s;--dl:0.95s}.g1{left:65%;--x:2px;--y:546px;--s:5px;--t:3.49s;--dl:1.45s}.g2{left:29%;--x:23px;--y:649px;--s:4px;--t:2.78s;--dl:0.75s}.g3{left:44%;--x:-26px;--y:763px;--s:4px;--t:2.80s;--dl:0.50s}.g4{left:42%;--x:20px;--y:482px;--s:4px;--t:3.52s;--dl:1.10s}.g5{left:50%;--x:-21px;--y:549px;--s:4px;--t:3.55s;--dl:0.51s}.g6{left:15%;--x:-5px;--y:669px;--s:4px;--t:3.59s;--dl:1.37s}.g7{left:24%;--x:15px;--y:640px;--s:6px;--t:2.67s;--dl:0.47s}.g8{left:44%;--x:-25px;--y:789px;--s:5px;--t:2.23s;--dl:0.98s}.g9{left:60%;--x:15px;--y:429px;--s:6px;--t:2.66s;--dl:1.07s}.g10{left:70%;--x:-26px;--y:477px;--s:4px;--t:3.56s;--dl:0.35s}.g11{left:37%;--x:-13px;--y:440px;--s:4px;--t:2.58s;--dl:0.38s}.g12{left:58%;--x:24px;--y:766px;--s:5px;--t:2.77s;--dl:0.95s}.g13{left:70%;--x:6px;--y:673px;--s:5px;--t:2.33s;--dl:0.28s}.g14{left:93%;--x:-19px;--y:637px;--s:3px;--t:2.58s;--dl:0.22s}.g15{left:14%;--x:21px;--y:553px;--s:3px;--t:3.05s;--dl:0.51s}.g16{left:37%;--x:25px;--y:482px;--s:6px;--t:2.22s;--dl:1.59s}.g17{left:57%;--x:29px;--y:557px;--s:4px;--t:2.26s;--dl:1.19s}.g18{left:17%;--x:-20px;--y:554px;--s:3px;--t:2.45s;--dl:1.51s}.g19{left:85%;--x:-11px;--y:691px;--s:4px;--t:2.61s;--dl:0.90s}.g20{left:26%;--x:-13px;--y:597px;--s:3px;--t:3.59s;--dl:0.25s}.g21{left:5%;--x:16px;--y:678px;--s:4px;--t:2.92s;--dl:0.54s}.g22{left:61%;--x:-24px;--y:757px;--s:6px;--t:3.12s;--dl:0.96s}.g23{left:54%;--x:2px;--y:577px;--s:4px;--t:3.58s;--dl:0.68s}.g24{left:95%;--x:16px;--y:745px;--s:4px;--t:2.77s;--dl:0.69s}.g25{left:9%;--x:23px;--y:486px;--s:3px;--t:2.30s;--dl:1.24s}
.s0{--x:0px;--y:-70px;--r:90deg;background:#E3C67E}.s1{--x:50px;--y:-50px;--r:-120deg;background:#F6E7BF}.s2{--x:72px;--y:0px;--r:200deg;background:#C9A24E}.s3{--x:50px;--y:50px;--r:-60deg;background:#FFFFFF}.s4{--x:0px;--y:70px;--r:140deg;background:#E3C67E}.s5{--x:-50px;--y:50px;--r:-200deg;background:#B8862B}.s6{--x:-72px;--y:0px;--r:80deg;background:#F6E7BF}.s7{--x:-50px;--y:-50px;--r:-140deg;background:#C9A24E}.s8{--x:120px;--y:-24px;--r:300deg;background:#E3C67E}.s9{--x:-120px;--y:-24px;--r:-300deg;background:#E3C67E}.s10{--x:140px;--y:20px;--r:160deg;background:#FFFFFF}.s11{--x:-140px;--y:20px;--r:-160deg;background:#C9A24E}

@keyframes kenburns { 0% { transform: scale(1.02) translate(0, 0); } 100% { transform: scale(1.12) translate(-2%, -3%); } }
.daytab { display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 58px; padding: 8px 6px; border-radius: 14px; border: 1px solid var(--line); background: #fff; font-weight: 700; color: var(--ink); flex-shrink: 0; position: relative; }
.daytab[aria-pressed="true"] { background: var(--dark); color: #fff; border-color: var(--dark); }
.daytab .dn { font-size: 11px; font-weight: 600; opacity: .75; }
.daytab .badge { position: absolute; top: -6px; right: -4px; min-width: 18px; height: 18px; border-radius: 9px; background: var(--gold-light); color: var(--dark); font-size: 10px; font-weight: 800; display: flex; align-items: center; justify-content: center; padding: 0 4px; }
.slot { font-size: 11px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; margin-top: 6px; display: flex; align-items: center; gap: 6px; }

/* charts */
.chart { position: relative; height: 200px; }
.chart .cols { position: absolute; inset: 0 0 22px 0; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; align-items: end; border-bottom: 1px solid #E7E4DD; }
.chart .col { display: flex; justify-content: center; align-items: flex-end; gap: 3px; height: 100%; position: relative; }
.chart .b { width: 42%; max-width: 26px; border-radius: 7px 7px 3px 3px; background: linear-gradient(180deg, #EFE4C6, #E2D3A8); min-height: 2px; }
.chart .b.cur { background: linear-gradient(180deg, #E3C67E, #B8862B); }
.chart .b.ly { background: transparent; border: 2px dashed #CFC8B8; border-bottom: 0; }
.chart .labels { position: absolute; left: 0; right: 0; bottom: 0; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; }
.chart .labels span { font-size: 11px; color: var(--muted); text-align: center; white-space: nowrap; overflow: hidden; }
.chart svg.line { position: absolute; left: 0; top: 0; width: 100%; height: calc(100% - 22px); overflow: visible; pointer-events: none; }
.legend { display: flex; gap: 14px; font-size: 12px; color: var(--muted); font-weight: 600; flex-wrap: wrap; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.delta { display: inline-flex; align-items: center; gap: 3px; font-size: 12px; font-weight: 800; padding: 4px 9px; border-radius: 999px; white-space: nowrap; }
.delta.up { color: var(--green); background: var(--green-soft); }
.delta.down { color: var(--red); background: var(--red-soft); }
.delta.flat { color: var(--muted); background: #F0EDE6; }
.dark .delta.up { color: #2B2925; background: linear-gradient(135deg, #F1DBA2, #D4B060); }
.dark .delta.down { color: #FFD9CF; background: rgba(224,122,95,.25); }

/* login */
.login { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px 20px; gap: 22px; background: radial-gradient(90% 60% at 50% 0%, #3A352C 0%, #1E1B16 70%); color: #fff; position: relative; overflow: hidden; }
.login .box { width: 100%; max-width: 400px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); border-radius: 26px; padding: 22px; display: flex; flex-direction: column; gap: 14px; -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); position: relative; z-index: 1; }
.login .input { background: rgba(255,255,255,.95); }
.login label { color: #D9D3C4 !important; }

/* ---------- desktop ---------- */
@media (min-width: 1024px) {
  .side { display: flex; flex-direction: column; gap: 1.75rem; width: 250px; flex-shrink: 0; position: sticky; top: 0; height: 100vh; background: linear-gradient(170deg, #34312B 0%, #1E1B16 100%); color: #fff; padding: 1.5rem 1rem; }
  .side .brand .serif { font-size: 30px; }
  .side nav { display: flex; flex-direction: column; gap: 4px; }
  .sidelink { display: flex; align-items: center; gap: 12px; height: 46px; padding: 0 12px; border-radius: 12px; color: #D9D3C4; font-weight: 500; font-size: 14px; transition: background-color .3s, color .3s; }
  .sidelink:hover { background: rgba(255,255,255,.06); color: #fff; }
  .sidelink[aria-current="page"] { background: linear-gradient(135deg, rgba(227,198,126,.22), rgba(227,198,126,.06)); border: 1px solid rgba(227,198,126,.3); color: #F1DBA2; font-weight: 700; }
  .bottomnav { display: none; }
  .screen { padding: 28px 32px 48px; max-width: 760px; }
  .screen.wide { max-width: 1240px; }
  .toast { bottom: 28px; }
  .desk-grid { grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); }
  .mobile-only { display: none !important; }
}
@media (max-width: 1023px) { .desk-only { display: none !important; } }
@media (max-width: 380px) { .stat .v { font-size: 16px; } .title { font-size: 23px; } }
