/* ── Design tokens ───────────────────────────────────────────────────────── */
:root {
  /* Base */
  --bg-deep:       #080c14;
  --glass-bg:      rgba(192, 210, 240, 0.06);
  --glass-border:  rgba(200, 220, 255, 0.16);
  --glass-shadow:  0 8px 48px rgba(0, 0, 0, 0.5);

  --text:          #eef2ff;
  --text-muted:    rgba(190, 210, 240, 0.65);
  --text-dim:      rgba(150, 180, 220, 0.4);

  /* Cool silver-steel accents */
  --accent-sky:    #38bdf8;   /* arctic ice blue  */
  --accent-steel:  #7dd3fc;   /* sky steel        */
  --accent-slate:  #94a3b8;   /* silver slate     */
  --accent-cyan:   #22d3ee;   /* glacier cyan     */
  --accent-frost:  #bae6fd;   /* frosted silver   */
  --accent-teal:   #2dd4bf;   /* cool teal        */
  --accent-err:    #f87171;   /* soft coral error */

  /* Gradient base colours */
  --grad-1: #060a12;
  --grad-2: #0c1628;
  --grad-3: #081422;

  /* Radii */
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-xl: 32px;

  /* Motion */
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Reset ───────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ── Body / background ───────────────────────────────────────────────────── */
body {
  font-family: -apple-system, "SF Pro Display", "Segoe UI", system-ui, sans-serif;
  background-color: var(--bg-deep);
  background-image:
    /* top-left: icy arctic blue pool */
    radial-gradient(ellipse 75% 55% at 15% 8%,   rgba(56,  189, 248, 0.18) 0%, transparent 60%),
    /* top-right: silver-steel shimmer */
    radial-gradient(ellipse 60% 45% at 88% 6%,   rgba(148, 163, 184, 0.14) 0%, transparent 55%),
    /* centre: deep glacier cyan */
    radial-gradient(ellipse 55% 45% at 50% 50%,  rgba(34,  211, 238, 0.09) 0%, transparent 60%),
    /* bottom: steel teal glow */
    radial-gradient(ellipse 70% 50% at 50% 95%,  rgba(45,  212, 191, 0.13) 0%, transparent 60%),
    /* right: frosted silver */
    radial-gradient(ellipse 45% 40% at 92% 55%,  rgba(186, 230, 253, 0.07) 0%, transparent 50%),
    linear-gradient(165deg, var(--grad-1) 0%, var(--grad-2) 55%, var(--grad-3) 100%);
  background-attachment: fixed;
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── Glassmorphism base ──────────────────────────────────────────────────── */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(28px) saturate(1.8) brightness(1.05);
  -webkit-backdrop-filter: blur(28px) saturate(1.8) brightness(1.05);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-lg);
  box-shadow: var(--glass-shadow), inset 0 1px 0 rgba(255,255,255,0.08);
}

/* ── App shell ───────────────────────────────────────────────────────────── */
.app-shell {
  max-width: 780px;
  margin: 0 auto;
  padding: 1.25rem 1rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

/* ── Top bar ─────────────────────────────────────────────────────────────── */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.2rem;
}

.topbar-brand h1 {
  font-size: clamp(1.25rem, 3.5vw, 1.6rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(130deg, #e2eeff 0%, var(--accent-frost) 40%, var(--accent-sky) 75%, var(--accent-teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.1;
}

.topbar-brand p {
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.01em;
  margin-top: 0.15rem;
}

.topbar-user {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.user-pill {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem 0.35rem 0.5rem;
  border-radius: 999px;
  background: rgba(200,220,255,0.06);
  border: 1px solid rgba(200,220,255,0.14);
  font-size: 0.82rem;
  color: var(--text-muted);
}

.user-avatar {
  width: 24px; height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-sky), var(--accent-teal));
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.btn-link {
  background: none;
  border: 1px solid rgba(200,220,255,0.15);
  border-radius: 999px;
  color: var(--text-muted);
  font-size: 0.78rem;
  cursor: pointer;
  padding: 0.3rem 0.8rem;
  transition: all 0.15s var(--ease-smooth);
}
.btn-link:hover {
  background: rgba(200,220,255,0.07);
  color: var(--text);
}

/* ── Camera card ─────────────────────────────────────────────────────────── */
.video-card {
  width: 100%;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  position: relative;
  border-radius: var(--r-xl);
  border: 1px solid rgba(200,225,255,0.16);
  box-shadow: 0 0 0 1px rgba(56,189,248,0.15), var(--glass-shadow);
}

.video-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 60%, rgba(6,10,18,0.7) 100%);
  z-index: 1;
  pointer-events: none;
}

.camera-idle-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: rgba(6,10,20,0.55);
  backdrop-filter: blur(3px);
  transition: opacity 0.3s;
}

.camera-idle-overlay.hidden { opacity: 0; pointer-events: none; }

.camera-idle-icon {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: rgba(56,189,248,0.12);
  border: 1.5px solid rgba(56,189,248,0.35);
  display: flex; align-items: center; justify-content: center;
}

.camera-idle-overlay p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

#camera {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: #000;
}

#captureCanvas { display: none; }

/* scanning ring */
.scan-ring {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  display: none;
}
.scan-ring.active { display: block; }
.scan-ring::after {
  content: '';
  position: absolute;
  inset: 10px;
  border-radius: var(--r-xl);
  border: 1.5px solid var(--accent-sky);
  animation: scanPulse 1.4s var(--ease-smooth) infinite;
}
@keyframes scanPulse {
  0%   { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.04); }
}

/* ── Controls grid ───────────────────────────────────────────────────────── */
.controls {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: 1fr 1fr;
}

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn {
  position: relative;
  overflow: hidden;
  border: none;
  border-radius: var(--r-md);
  min-height: 62px;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  padding: 0.8rem 1rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  text-align: center;
  transition: transform 0.15s var(--ease-spring), box-shadow 0.15s var(--ease-smooth), opacity 0.15s;
  -webkit-tap-highlight-color: transparent;
}

/* chrome sheen overlay */
.btn::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 50%;
  background: linear-gradient(to bottom, rgba(255,255,255,0.10), transparent);
  border-radius: var(--r-md) var(--r-md) 0 0;
  pointer-events: none;
}
.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0);
  transition: background 0.12s;
}
.btn:hover::after  { background: rgba(255,255,255,0.07); }
.btn:active::after { background: rgba(255,255,255,0.13); }
.btn:active  { transform: scale(0.97); }
.btn:disabled { opacity: 0.38; pointer-events: none; }

.btn-icon { line-height: 1; display: flex; align-items: center; justify-content: center; }
.btn-label { font-size: 0.8rem; font-weight: 600; }

/* Start / Stop */
.btn-start {
  grid-column: 1 / -1;
  min-height: 54px;
  border-radius: var(--r-xl);
  background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 40%, #0369a1 100%);
  box-shadow: 0 4px 20px rgba(14,165,233,0.35), inset 0 1px 0 rgba(255,255,255,0.18);
  font-size: 1rem;
}
.btn-start:hover { box-shadow: 0 6px 28px rgba(14,165,233,0.50), inset 0 1px 0 rgba(255,255,255,0.18); }

/* cool steel-tinted action buttons */
.btn-scan {
  background: linear-gradient(140deg, #1e3a5f 0%, #1d4ed8 100%);
  box-shadow: 0 3px 14px rgba(29,78,216,0.32), inset 0 1px 0 rgba(255,255,255,0.10);
  border: 1px solid rgba(96,165,250,0.2);
}
.btn-ocr {
  background: linear-gradient(140deg, #134e4a 0%, #0d9488 100%);
  box-shadow: 0 3px 14px rgba(13,148,136,0.32), inset 0 1px 0 rgba(255,255,255,0.10);
  border: 1px solid rgba(45,212,191,0.2);
}
.btn-remember {
  background: linear-gradient(140deg, #1e3a5f 0%, #0284c7 100%);
  box-shadow: 0 3px 14px rgba(2,132,199,0.32), inset 0 1px 0 rgba(255,255,255,0.10);
  border: 1px solid rgba(56,189,248,0.2);
}
.btn-identify {
  background: linear-gradient(140deg, #1e3952 0%, #0e7490 100%);
  box-shadow: 0 3px 14px rgba(14,116,144,0.32), inset 0 1px 0 rgba(255,255,255,0.10);
  border: 1px solid rgba(34,211,238,0.2);
}

/* ── Status bar ──────────────────────────────────────────────────────────── */
.status-bar {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.7rem 1rem;
  border-radius: var(--r-md);
}

.status-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--text-dim);
  flex-shrink: 0;
  transition: background 0.3s, box-shadow 0.3s;
}
.status-dot.active  { background: #4ade80; box-shadow: 0 0 7px rgba(74,222,128,0.75); }
.status-dot.working { background: var(--accent-sky); box-shadow: 0 0 7px rgba(56,189,248,0.75); animation: blink 1s ease infinite; }
.status-dot.error   { background: var(--accent-err); }

@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0.3} }

.status-text {
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* ── Result panel ────────────────────────────────────────────────────────── */
.result-panel {
  padding: 1.25rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.result-section { display: flex; flex-direction: column; gap: 0.4rem; }

.result-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.result-value {
  font-size: 1rem;
  line-height: 1.55;
  color: var(--text);
  min-height: 1.55rem;
}

.result-value.answer { font-size: 1.05rem; }

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  list-style: none;
  min-height: 1.6rem;
}

.tag {
  padding: 0.22rem 0.7rem;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 500;
  background: rgba(56,189,248,0.12);
  border: 1px solid rgba(56,189,248,0.25);
  color: var(--accent-frost);
}

.divider {
  height: 1px;
  background: rgba(200,220,255,0.1);
}

/* ── Audio player ────────────────────────────────────────────────────────── */
audio {
  width: 100%;
  height: 36px;
  border-radius: var(--r-sm);
  accent-color: var(--accent-sky);
  margin-top: 0.25rem;
}
audio.hidden { display: none; }

/* ── Utility ─────────────────────────────────────────────────────────────── */
.hidden { display: none !important; }

/* ── Auth pages ──────────────────────────────────────────────────────────── */
.auth-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  padding: 2.5rem 2.25rem 2rem;
  border-radius: var(--r-xl);
  background: rgba(192,218,255,0.055);
  backdrop-filter: blur(36px) saturate(2) brightness(1.06);
  -webkit-backdrop-filter: blur(36px) saturate(2) brightness(1.06);
  border: 1px solid rgba(200,225,255,0.17);
  box-shadow:
    0 24px 64px rgba(0,0,0,0.5),
    0 0 0 1px rgba(56,189,248,0.10),
    inset 0 1px 0 rgba(255,255,255,0.09);
  animation: cardIn 0.4s var(--ease-spring) both;
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to   { opacity: 1; transform: none; }
}

.auth-logo-wrap { text-align: center; margin-bottom: 2rem; }

.auth-logo-icon {
  width: 56px; height: 56px;
  margin: 0 auto 0.75rem;
  border-radius: var(--r-md);
  background: linear-gradient(135deg, #0369a1, #0891b2);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 22px rgba(8,145,178,0.4), inset 0 1px 0 rgba(255,255,255,0.15);
}

.auth-logo {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(130deg, #e2eeff, var(--accent-frost) 50%, var(--accent-sky));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.auth-tagline {
  margin-top: 0.3rem;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.auth-heading {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.input-group { display: flex; flex-direction: column; gap: 0.35rem; }

.auth-form label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

.auth-hint {
  font-weight: 400;
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-left: 0.3rem;
}

.auth-form input {
  width: 100%;
  padding: 0.78rem 1rem;
  border-radius: var(--r-sm);
  border: 1px solid rgba(200,225,255,0.12);
  background: rgba(200,220,255,0.04);
  color: var(--text);
  font-size: 0.97rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}
.auth-form input::placeholder { color: rgba(150,180,220,0.3); }
.auth-form input:focus {
  border-color: var(--accent-sky);
  background: rgba(56,189,248,0.06);
  box-shadow: 0 0 0 3px rgba(56,189,248,0.15);
}

.auth-error {
  padding: 0.65rem 0.9rem;
  border-radius: var(--r-sm);
  background: rgba(248,113,113,0.10);
  border: 1px solid rgba(248,113,113,0.28);
  color: #fca5a5;
  font-size: 0.85rem;
  line-height: 1.4;
}

.auth-btn {
  margin-top: 0.5rem;
  width: 100%;
  min-height: 50px;
  border-radius: var(--r-md);
  font-size: 0.97rem;
  font-weight: 600;
  background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 50%, #0369a1 100%);
  box-shadow: 0 4px 20px rgba(14,165,233,0.38), inset 0 1px 0 rgba(255,255,255,0.15);
  transition: box-shadow 0.15s, transform 0.12s var(--ease-spring);
}
.auth-btn:hover  { box-shadow: 0 6px 28px rgba(14,165,233,0.54), inset 0 1px 0 rgba(255,255,255,0.15); transform: translateY(-1px); }
.auth-btn:active { transform: scale(0.98); }

.auth-switch {
  margin-top: 1.25rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.auth-switch a {
  color: var(--accent-sky);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.12s;
}
.auth-switch a:hover { color: var(--accent-frost); text-decoration: underline; }

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (min-width: 600px) {
  .controls { grid-template-columns: repeat(4, 1fr); }
  .btn-start { grid-column: 1 / -1; }
}

@media (max-width: 400px) {
  .topbar-brand h1 { font-size: 1.1rem; }
  .btn { min-height: 56px; }
}

/* ── Navigation button ───────────────────────────────────────────────────── */
.btn-navigate {
  background: linear-gradient(140deg, #0e3f5c 0%, #0891b2 100%);
  box-shadow: 0 3px 14px rgba(8,145,178,0.35), inset 0 1px 0 rgba(255,255,255,0.10);
  border: 1px solid rgba(34,211,238,0.22);
}

/* ── Navigation panel ────────────────────────────────────────────────────── */
.nav-panel { animation: cardIn 0.3s var(--ease-spring) both; }

.nav-input-row {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

.nav-input-row input {
  flex: 1;
  padding: 0.72rem 1rem;
  border-radius: var(--r-sm);
  border: 1px solid rgba(200,225,255,0.12);
  background: rgba(200,220,255,0.04);
  color: var(--text);
  font-size: 0.97rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}
.nav-input-row input::placeholder { color: rgba(150,180,220,0.3); }
.nav-input-row input:focus {
  border-color: var(--accent-cyan);
  background: rgba(34,211,238,0.06);
  box-shadow: 0 0 0 3px rgba(34,211,238,0.15);
}

.nav-go-btn {
  grid-column: unset !important;
  min-width: 70px;
  min-height: 44px;
  border-radius: var(--r-sm);
  font-size: 0.9rem;
}

.nav-stop-row { align-items: flex-start; }
.nav-stop-btn {
  width: 100%;
  min-height: 44px;
  border-radius: var(--r-md);
  background: linear-gradient(135deg, #7f1d1d, #b91c1c);
  box-shadow: 0 3px 14px rgba(185,28,28,0.3);
  border: 1px solid rgba(252,165,165,0.15);
  font-size: 0.9rem;
}

/* ── Destination candidate cards ─────────────────────────────────────────── */
.nav-candidates {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 0.35rem;
}

.nav-status-text { margin-top: 0.35rem; }

.nav-candidate-card {
  width: 100%;
  text-align: left;
  background: rgba(56,189,248,0.06);
  border: 1px solid rgba(56,189,248,0.18);
  border-radius: var(--r-md);
  padding: 0.8rem 1rem;
  cursor: pointer;
  color: var(--text);
  font-family: inherit;
  transition: background 0.15s, border-color 0.15s, transform 0.12s var(--ease-spring);
}
.nav-candidate-card:hover {
  background: rgba(56,189,248,0.12);
  border-color: rgba(56,189,248,0.35);
}
.nav-candidate-card:active { transform: scale(0.98); }
.nav-candidate-card.chosen {
  background: rgba(56,189,248,0.16);
  border-color: var(--accent-sky);
  box-shadow: 0 0 0 2px rgba(56,189,248,0.25);
}

.nav-candidate-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.2rem;
}

.nav-candidate-name {
  font-size: 0.96rem;
  font-weight: 600;
  color: var(--text);
}

.nav-candidate-dist {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  background: rgba(45,212,191,0.15);
  border: 1px solid rgba(45,212,191,0.3);
  color: var(--accent-teal);
  white-space: nowrap;
  flex-shrink: 0;
}

.nav-candidate-address {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ── Voice indicator pill ────────────────────────────────────────────────── */
.voice-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 20px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  font-size: 0.7rem;
  color: var(--text-muted);
  user-select: none;
  transition: border-color 0.3s;
}

.voice-mic {
  opacity: 0.55;
  flex-shrink: 0;
  transition: opacity 0.3s;
}

.voice-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-muted);
  flex-shrink: 0;
  transition: background 0.3s, box-shadow 0.3s;
}

/* Active: green pulsing dot */
.voice-pill.listening .voice-dot {
  background: #22c55e;
  box-shadow: 0 0 6px #22c55e88;
  animation: voice-pulse 1.8s ease-in-out infinite;
}
.voice-pill.listening .voice-mic {
  opacity: 0.9;
  stroke: #22c55e;
}
.voice-pill.listening {
  border-color: rgba(34, 197, 94, 0.35);
}

/* Activated: yellow/amber — Echo heard, waiting for command */
.voice-pill.activated .voice-dot {
  background: #fbbf24;
  box-shadow: 0 0 8px #fbbf2499;
  animation: voice-pulse 0.7s ease-in-out infinite;
}
.voice-pill.activated .voice-mic {
  opacity: 1;
  stroke: #fbbf24;
}
.voice-pill.activated {
  border-color: rgba(251, 191, 36, 0.5);
}

/* Error: red dot */
.voice-pill.error .voice-dot {
  background: #f87171;
}
.voice-pill.error {
  border-color: rgba(248, 113, 113, 0.35);
}

@keyframes voice-pulse {
  0%, 100% { opacity: 1;   transform: scale(1);    }
  50%       { opacity: 0.5; transform: scale(0.8);  }
}

/* ── Startup overlay ─────────────────────────────────────────────────────── */
.startup-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(6, 10, 18, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.startup-overlay.hidden {
  display: none;
}

.startup-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  padding: 48px 36px;
  border-radius: 24px;
  text-align: center;
  max-width: 320px;
  animation: fadeUp 0.4s ease;
}

.startup-card h2 {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--accent-frost);
  letter-spacing: 0.04em;
  margin: 0;
}

.startup-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.5;
  margin: 0;
}

.startup-btn {
  margin-top: 8px;
  padding: 14px 36px;
  font-size: 1rem;
  border-radius: 50px;
  background: linear-gradient(135deg, var(--accent-sky), var(--accent-teal));
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.03em;
  box-shadow: 0 4px 20px rgba(56,189,248,0.3);
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Guide Mode ──────────────────────────────────────────────────────────── */

/* Guide Mode button — amber/orange */
.btn-guide {
  background: linear-gradient(135deg, rgba(251,146,60,0.18), rgba(245,158,11,0.28));
  border-color: rgba(251,146,60,0.35);
  color: #fbbf24;
}
.btn-guide:hover:not(:disabled) {
  background: linear-gradient(135deg, rgba(251,146,60,0.28), rgba(245,158,11,0.38));
  box-shadow: 0 0 18px rgba(251,146,60,0.3);
}
.btn-guide.active {
  background: linear-gradient(135deg, rgba(251,146,60,0.4), rgba(245,158,11,0.5));
  border-color: rgba(251,146,60,0.7);
  box-shadow: 0 0 24px rgba(251,146,60,0.45);
  animation: guidePulseBtn 2s ease-in-out infinite;
}
@keyframes guidePulseBtn {
  0%, 100% { box-shadow: 0 0 24px rgba(251,146,60,0.45); }
  50%       { box-shadow: 0 0 38px rgba(251,146,60,0.75); }
}

/* Guide panel */
.guide-panel { border-color: rgba(251,146,60,0.3); }
.guide-panel.danger { border-color: rgba(248,113,113,0.7); animation: dangerFlash 0.4s ease 3; }

@keyframes dangerFlash {
  0%, 100% { background: var(--glass-bg); }
  50%       { background: rgba(220, 38, 38, 0.18); }
}

.guide-header { display: flex; flex-direction: column; gap: 6px; }

.guide-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.guide-pulse {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: #fbbf24;
  animation: guideDot 1.4s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes guideDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.4; transform: scale(0.7); }
}

.guide-hint { font-size: 0.8rem; color: var(--text-muted); margin: 0; }

.guide-guidance {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--accent-frost);
  line-height: 1.4;
  transition: color 0.3s ease;
}
.guide-panel.danger .guide-guidance { color: #fca5a5; }

.guide-log {
  max-height: 160px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.38rem;
  padding-right: 0.2rem;
}

.guide-log-empty {
  color: var(--text-muted);
  font-size: 0.8rem;
  margin: 0;
}

.guide-log-entry {
  padding: 0.42rem 0.58rem;
  border-radius: var(--r-sm);
  border: 1px solid rgba(56,189,248,0.2);
  background: rgba(56,189,248,0.08);
  color: var(--text-muted);
  font-size: 0.76rem;
  line-height: 1.25;
}

.guide-log-entry.danger {
  border-color: rgba(248,113,113,0.35);
  background: rgba(248,113,113,0.13);
  color: #fca5a5;
}

/* Danger banner */
.guide-danger-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(220, 38, 38, 0.22);
  border: 1px solid rgba(248,113,113,0.5);
  border-radius: var(--r-sm);
  padding: 10px 14px;
  color: #fca5a5;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  margin-top: 2px;
}
.guide-danger-banner.hidden { display: none; }
