/* EstateFlow tokens and primitives. Lagoon cyan is the one brand colour; everything else is neutral. */
:root {
  --brand: #0E93B0; --brand-hi: #19B0CF; --brand-ink: #0A6F88; --on-brand: #fff;
  --tint: rgba(14, 147, 176, .10); --tint-2: rgba(14, 147, 176, .18); --ring: rgba(14, 147, 176, .28);
  --accent: #F5B544; --accent-ink: #9A6408; --accent-tint: rgba(245, 181, 68, .16);
  --side: #0A2A35; --side-hi: #0F3C4B;
  --bg: #F3F6F8; --surface: #FFFFFF; --raised: #FFFFFF; --soft: #F5F8FA; --soft-2: #EEF3F6; --field: #F6F9FB;
  --ink: #0E1A22; --ink-2: #44525E; --muted: #85929E; --hair: #EDF1F4; --line: #E2E8ED;
  --ok: #12A16B; --ok-tint: rgba(18, 161, 107, .12); --warn: #D98A0B; --warn-tint: rgba(232, 156, 20, .14); --bad: #E0464C; --bad-tint: rgba(224, 70, 76, .11);
  --info: #4C6FFF; --info-tint: rgba(76, 111, 255, .11); --violet: #7B61FF; --violet-tint: rgba(123, 97, 255, .12);
  --sh: 0 1px 2px rgba(16, 32, 44, .04), 0 8px 24px -14px rgba(16, 32, 44, .14);
  --sh-lift: 0 2px 4px rgba(16, 32, 44, .05), 0 22px 48px -22px rgba(16, 32, 44, .32);
  --sh-pop: 0 24px 60px -18px rgba(16, 32, 44, .34), 0 0 0 1px rgba(16, 32, 44, .05);
  --r: 18px; --r-lg: 22px; --r-md: 14px; --r-sm: 10px;
  --display: 'Sora', 'Plus Jakarta Sans', system-ui, sans-serif;
  --font: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --bar: rgba(243, 246, 248, .8);
  --sw: 264px; --tb: 72px;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --brand: #22C3E3; --brand-hi: #4FD6EE; --brand-ink: #5CDAF1; --on-brand: #04161C;
  --tint: rgba(34, 195, 227, .12); --tint-2: rgba(34, 195, 227, .2); --ring: rgba(34, 195, 227, .35);
  --accent: #F7C25E; --accent-ink: #F7C25E; --accent-tint: rgba(247, 194, 94, .14);
  --side: #0B0F12; --side-hi: #141A1F;
  --bg: #0A0D10; --surface: #12171B; --raised: #171D22; --soft: #182026; --soft-2: #1D262D; --field: #161C21;
  --ink: #EDF3F6; --ink-2: #A6B2BC; --muted: #6E7B86; --hair: #1C2329; --line: #252E36;
  --ok: #2FD08A; --ok-tint: rgba(47, 208, 138, .13); --warn: #F1AE3D; --warn-tint: rgba(241, 174, 61, .14); --bad: #FF6B6F; --bad-tint: rgba(255, 107, 111, .13);
  --info: #7B97FF; --info-tint: rgba(123, 151, 255, .14); --violet: #A08CFF; --violet-tint: rgba(160, 140, 255, .15);
  --sh: 0 0 0 1px rgba(255, 255, 255, .03), 0 14px 34px -22px rgba(0, 0, 0, .9);
  --sh-lift: 0 0 0 1px rgba(255, 255, 255, .05), 0 26px 60px -26px rgba(0, 0, 0, .95);
  --sh-pop: 0 0 0 1px rgba(255, 255, 255, .07), 0 30px 70px -24px rgba(0, 0, 0, .95);
  --bar: rgba(10, 13, 16, .78);
  color-scheme: dark;
}
/* Big monitors: scale everything up so nothing looks tiny. */
@media (min-width: 1600px) { :root { --z: 1.07; } }
@media (min-width: 1800px) { :root { --z: 1.15; } }
@media (min-width: 2100px) { :root { --z: 1.25; } }
@media (min-width: 2500px) { :root { --z: 1.4; } }
@media (min-width: 3200px) { :root { --z: 1.6; } }
html { zoom: var(--z, 1); -webkit-text-size-adjust: 100%; }

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { font-family: var(--font); font-size: 14px; line-height: 1.5; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; font-feature-settings: 'cv11', 'ss01'; }
h1, h2, h3, h4 { font-family: var(--display); margin: 0; letter-spacing: -0.02em; text-wrap: balance; color: var(--ink); }
p { margin: 0; text-wrap: pretty; }
a { color: var(--brand-ink); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
img, svg { display: block; }
.ic { flex: none; display: inline-block; vertical-align: -0.2em; }
.num, .tnum { font-variant-numeric: tabular-nums; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 8px; }
::selection { background: var(--tint-2); }
.grow { flex: 1; min-width: 0; }
.muted { color: var(--muted); }
.nowrap { white-space: nowrap; }
.ell { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 650; font-size: 13.5px; white-space: nowrap; transition: background .15s, border-color .15s, box-shadow .15s, transform .1s; text-decoration: none; }
.btn:hover { border-color: color-mix(in srgb, var(--brand) 35%, var(--line)); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; pointer-events: none; }
.btn.pri { background: linear-gradient(180deg, var(--brand-hi), var(--brand)); border-color: transparent; color: var(--on-brand); box-shadow: 0 6px 16px -8px var(--brand), inset 0 1px 0 rgba(255, 255, 255, .22); }
.btn.pri:hover { filter: brightness(1.05); }
.btn.dark { background: var(--ink); color: var(--bg); border-color: transparent; }
.btn.gold { background: linear-gradient(180deg, #FFCB6B, #F2A93B); border-color: transparent; color: #3B2604; box-shadow: 0 6px 16px -8px #F2A93B; }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.ghost:hover { background: var(--soft); }
.btn.danger { color: var(--bad); }
.btn.danger.solid { background: var(--bad); color: #fff; border-color: transparent; }
.btn.sm { height: 32px; padding: 0 11px; font-size: 12.5px; border-radius: 10px; gap: 6px; }
.btn.lg { height: 48px; padding: 0 22px; font-size: 15px; border-radius: 14px; }
.btn.icon { width: 40px; padding: 0; }
.btn.icon.sm { width: 32px; }
.btn.block { width: 100%; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--brand-ink); font-weight: 650; font-size: 13px; display: inline-flex; align-items: center; gap: 4px; }
.linkbtn:hover { text-decoration: underline; }

/* fields */
.fld { display: grid; gap: 6px; min-width: 0; }
.fld > span { font-size: 12.5px; font-weight: 650; color: var(--ink-2); display: flex; align-items: center; gap: 6px; }
.fld > span em { font-style: normal; color: var(--muted); font-weight: 500; }
.in, .fld input, .fld select, .fld textarea { width: 100%; height: 42px; padding: 0 13px; border-radius: 12px; border: 1px solid var(--line); background: var(--field); color: var(--ink); outline: none; transition: border-color .15s, box-shadow .15s, background .15s; min-width: 0; }
.fld textarea { height: auto; min-height: 84px; padding: 10px 13px; resize: vertical; line-height: 1.5; }
.in:focus, .fld input:focus, .fld select:focus, .fld textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 4px var(--tint); background: var(--surface); }
.fld select, select.in { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2385929E' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 34px; }
.fld .hint { font-size: 12px; color: var(--muted); }
.fld.err input, .fld.err select { border-color: var(--bad); }
.in-ic { position: relative; }
.in-ic > .ic { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.in-ic > input { padding-left: 38px; }
.pre { display: flex; align-items: stretch; }
.pre > b { display: grid; place-items: center; padding: 0 12px; border: 1px solid var(--line); border-right: 0; border-radius: 12px 0 0 12px; background: var(--soft); color: var(--muted); font-weight: 600; font-size: 13px; }
.pre > input { border-radius: 0 12px 12px 0 !important; }
.check { display: flex; align-items: center; gap: 10px; cursor: pointer; font-weight: 550; }
.check input { width: 18px; height: 18px; accent-color: var(--brand); }

/* switch */
.sw { position: relative; width: 40px; height: 24px; flex: none; }
.sw input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.sw i { position: absolute; inset: 0; border-radius: 99px; background: var(--line); transition: background .2s; }
.sw i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .2s; }
.sw input:checked + i { background: var(--brand); }
.sw input:checked + i::after { transform: translateX(16px); }

/* pills and chips */
.pill { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border-radius: 99px; font-size: 11.5px; font-weight: 700; background: var(--soft-2); color: var(--ink-2); white-space: nowrap; }
.pill::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .85; }
.pill.plain::before { display: none; }
.pill.ok { background: var(--ok-tint); color: var(--ok); }
.pill.warn { background: var(--warn-tint); color: var(--warn); }
.pill.bad { background: var(--bad-tint); color: var(--bad); }
.pill.brand { background: var(--tint); color: var(--brand-ink); }
.pill.info { background: var(--info-tint); color: var(--info); }
.pill.violet { background: var(--violet-tint); color: var(--violet); }
.pill.gold { background: var(--accent-tint); color: var(--accent-ink); }
.pill.dark { background: var(--ink); color: var(--bg); }
.delta { display: inline-flex; align-items: center; gap: 3px; height: 22px; padding: 0 7px; border-radius: 99px; font-size: 11.5px; font-weight: 700; background: var(--ok-tint); color: var(--ok); }
.delta.down { background: var(--bad-tint); color: var(--bad); }
.delta.flat { background: var(--soft-2); color: var(--muted); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 13px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); font-weight: 600; font-size: 13px; white-space: nowrap; transition: all .15s; }
.chip:hover { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); color: var(--ink); }
.chip.on { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chip.on.brand { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.chip b { font-weight: 700; font-size: 11px; padding: 1px 6px; border-radius: 99px; background: var(--soft-2); color: var(--ink-2); }
.chip.on b { background: rgba(255, 255, 255, .18); color: inherit; }

/* segmented control */
.seg { display: inline-flex; padding: 3px; border-radius: 12px; background: var(--soft-2); gap: 2px; }
.seg button { height: 32px; padding: 0 12px; border: 0; border-radius: 9px; background: transparent; color: var(--ink-2); font-weight: 650; font-size: 12.5px; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(16, 32, 44, .12); }
:root[data-theme="dark"] .seg button.on { background: var(--soft); }

/* avatars */
.av { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 750; font-size: 12.5px; color: #fff; flex: none; letter-spacing: .01em; }
.av.sm { width: 28px; height: 28px; font-size: 11px; }
.av.lg { width: 48px; height: 48px; font-size: 16px; }
.av.xl { width: 64px; height: 64px; font-size: 21px; }
.av.sq { border-radius: 12px; }

/* icon chips */
.ib { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--tint); color: var(--brand-ink); flex: none; }
.ib.sm { width: 30px; height: 30px; border-radius: 10px; }
.ib.lg { width: 48px; height: 48px; border-radius: 15px; }
.ib.ok { background: var(--ok-tint); color: var(--ok); }
.ib.warn { background: var(--warn-tint); color: var(--warn); }
.ib.bad { background: var(--bad-tint); color: var(--bad); }
.ib.info { background: var(--info-tint); color: var(--info); }
.ib.violet { background: var(--violet-tint); color: var(--violet); }
.ib.gold { background: var(--accent-tint); color: var(--accent-ink); }
.ib.dark { background: var(--ink); color: var(--bg); }

/* wordmark */
.wm { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); }
.wm-t { display: grid; line-height: 1.05; }
.wm-t b { font-family: var(--display); font-weight: 700; font-size: 18.5px; letter-spacing: -0.03em; }
.wm-t b em { font-style: normal; color: var(--brand); }
.wm-t small { font-size: 10.5px; font-weight: 600; color: var(--muted); margin-top: 4px; letter-spacing: .01em; }

/* meter */
.meter { height: 6px; border-radius: 99px; background: var(--soft-2); overflow: hidden; }
.meter > i { display: block; height: 100%; border-radius: inherit; background: var(--brand); transition: width .4s; }
.meter.warn > i { background: var(--warn); }
.meter.full > i { background: var(--bad); }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; } }
