/* Gully ID UI: the ONE token + motion file shared by the landing (/), the sign-in card (/login and the other
   shell pages) and the Gully Wallet. Night ground (W2 Night, Gully ID brand kit v1 dark theme): every surface,
   line, text, accent, radius, font and button style of the three surfaces comes from here, so landing -> sign in ->
   wallet reads as one product. Page stylesheets only map these --ui-* tokens to their own names.
   Kit colours: cyan #00F7FC (mark, primary action on night), gold #F9AE1B (secondary accent), night #05080D.
   Motion: every keyframe runs only inside (prefers-reduced-motion: no-preference); without it the static styles are
   the finished state. CSS + WAAPI only (CSP script-src 'self'). */
:root {
  /* ground and surfaces */
  --ui-night: #05080D;
  --ui-ink: #0A1018;
  --ui-ink-2: #0D1726;
  --ui-deep: #070C14;
  --ui-hover: #101B2C;
  --ui-line: #172233;
  --ui-line-2: #1E2C42;
  --ui-line-3: #22344F;
  /* text */
  --ui-white: #FFFFFF;
  --ui-text: #E7EEF8;
  --ui-text-2: #CFDAE8;
  --ui-soft: #B5C3D6;
  --ui-muted: #9FB0C8;
  --ui-faint: #6E819C;
  /* accents (kit) and states */
  --ui-cyan: #00F7FC;
  --ui-cyan-2: #5FF9FD;
  --ui-cyan-3: #B4FDFE;
  --ui-gold: #F9AE1B;
  --ui-green: #46FB04;
  --ui-red: #FF7A7A;
  --ui-on-cyan: #05080D;
  --ui-cyan-soft: rgba(0, 247, 252, .12);
  /* type */
  --ui-font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ui-display: "Montserrat", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --ui-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  /* shape and depth */
  --ui-r-xl: 18px;
  --ui-r-lg: 14px;
  --ui-r-md: 12px;
  --ui-r: 10px;
  --ui-r-sm: 8px;
  --ui-btn-h: 46px;
  --ui-btn-h-s: 40px;
  --ui-shadow: 0 24px 64px rgba(0, 0, 0, .4);
  --ui-glow: 0 6px 24px rgba(0, 247, 252, .22);
  --ui-wash: radial-gradient(900px 360px at 50% -14%, rgba(0, 247, 252, .11), transparent 60%);
  /* motion */
  --ui-ease: cubic-bezier(.2, .8, .2, 1);
  --ui-dur: 160ms;
  color-scheme: dark;
}

/* ---- buttons: the same three on every surface ---- */
.ui-btn { position: relative; overflow: hidden; isolation: isolate; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--ui-btn-h); padding: 0 18px; border-radius: var(--ui-r); border: 1px solid transparent; font: 700 14.5px/1 var(--ui-font);
  text-decoration: none; white-space: nowrap; cursor: pointer; -webkit-tap-highlight-color: transparent;
  transition: filter var(--ui-dur) var(--ui-ease), border-color var(--ui-dur) var(--ui-ease), background-color var(--ui-dur) var(--ui-ease), transform var(--ui-dur) var(--ui-ease), color var(--ui-dur); }
.ui-btn--primary { background: var(--ui-cyan); color: var(--ui-on-cyan); font-weight: 800; box-shadow: var(--ui-glow); }
.ui-btn--primary:hover { filter: brightness(1.06); color: var(--ui-on-cyan); }
.ui-btn--secondary { background: var(--ui-ink); color: var(--ui-text); border-color: var(--ui-line-3); }
.ui-btn--secondary:hover { border-color: #355078; color: var(--ui-white); }
.ui-btn--ghost { background: transparent; color: var(--ui-text-2); }
.ui-btn--ghost:hover { background: var(--ui-deep); color: var(--ui-white); }
.ui-btn--s { min-height: var(--ui-btn-h-s); padding: 0 14px; font-size: 13.5px; }
.ui-btn:active { transform: translateY(1px); }
.ui-btn:focus-visible { outline: 2px solid var(--ui-cyan); outline-offset: 3px; }
/* hover shine: a light band sweeps across once (static: no band) */
.gw-btn { position: relative; overflow: hidden; isolation: isolate; }
.ui-btn::after, .gw-btn::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .28) 50%, transparent 65%) no-repeat; background-size: 250% 100%; background-position: 160% 0; opacity: 0; }
.ui-btn--secondary::after, .ui-btn--ghost::after, .gw-btn:not(.gw-btn-primary)::after { background-image: linear-gradient(105deg, transparent 35%, rgba(0, 247, 252, .14) 50%, transparent 65%); }

/* ---- shared surfaces ---- */
.ui-card { background: var(--ui-ink); border: 1px solid var(--ui-line); border-radius: var(--ui-r-lg); }
.ui-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ui-faint); flex: none; display: inline-block; }
.is-live > .ui-dot, .ui-dot.is-live { background: var(--ui-green); box-shadow: 0 0 0 3px rgba(70, 251, 4, .15); }
.is-down > .ui-dot, .ui-dot.is-down { background: var(--ui-red); }

/* ---- the shared motion language ---- */
@media (prefers-reduced-motion: no-preference) {
  .ui-btn::after, .gw-btn::after { transition: background-position .7s var(--ui-ease), opacity .2s; }
  .ui-btn:hover::after, .ui-btn:focus-visible::after, .gw-btn:hover::after, .gw-btn:focus-visible::after { background-position: -60% 0; opacity: 1; }
  /* entrance: children marked .ui-rise slide up in order of --i (set in the HTML) */
  .ui-rise { animation: ui-rise .6s var(--ui-ease) both; animation-delay: calc(var(--i, 0) * 70ms + 60ms); }
  /* reveal on scroll where the browser has scroll-driven animations (pure CSS, nothing hidden without it) */
  @supports (animation-timeline: view()) {
    .ui-reveal { animation: ui-rise linear both; animation-timeline: view(); animation-range: entry 0% entry 40%; }
  }
  .ui-float { animation: ui-float 6s ease-in-out infinite; }
  .ui-pulse { animation: ui-pulse 2.8s ease-out infinite; }
  .is-live > .ui-dot, .ui-dot.is-live { animation: ui-dot 2s ease-in-out infinite; }
}
@keyframes ui-rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes ui-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes ui-pulse { 0% { box-shadow: var(--ui-glow), 0 0 0 0 rgba(0, 247, 252, .45); } 70%, 100% { box-shadow: var(--ui-glow), 0 0 0 12px rgba(0, 247, 252, 0); } }
@keyframes ui-dot { 50% { box-shadow: 0 0 0 6px rgba(70, 251, 4, 0); } }
@keyframes ui-blink { 0%, 93%, 100% { opacity: 0; } 95% { opacity: 1; } }
@keyframes ui-pan { from { background-position: 0 0; } to { background-position: 22px 22px; } }
@keyframes ui-hue { 0%, 100% { transform: translate3d(-6%, -4%, 0) scale(1); } 50% { transform: translate3d(6%, 4%, 0) scale(1.08); } }

/* ---- navigation icons (ui/nav-icons.ts, Lucide, 20 px, stroke 1.75): muted, brighter on hover, the Gully ID
   accent when the item is active. Every nav item of the landing, sign-in, wallet and phone tab bars carries one. ---- */
.nav-ic { flex: none; color: var(--ui-muted); transition: color var(--ui-dur) var(--ui-ease); }
a:hover > .nav-ic, button:hover > .nav-ic { color: var(--ui-text); }
[aria-current="page"] > .nav-ic, [aria-selected="true"] > .nav-ic { color: var(--ui-cyan); }
