/* ═══════════════════════════════════════════════════════════════════════
   Frost UI — base do tema (glassmorphism escuro)
   Fundo fixo com glows radiais; tudo que flutua é vidro.
   ═══════════════════════════════════════════════════════════════════════ */

:root {
  --primary: #6ea8ff;
  --text: #ebeef4;
  --muted: #9fb0d0;
  --dim: #7d8db0;
  --card: rgba(255, 255, 255, 0.055);
  --card-hover: rgba(255, 255, 255, 0.085);
  --border: rgba(255, 255, 255, 0.13);
  --border-strong: rgba(255, 255, 255, 0.22);
  --header-bg: rgba(16, 22, 40, 0.55);

  --green: #10b981;
  --amber: #f59e0b;
  --red: #ef4444;

  --radius: 14px;
  --radius-sm: 10px;

  /* Uma curva só para tudo: entradas e hovers com a mesma sensação. */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --speed: 180ms;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, sans-serif;
  font-size: 15px;
  line-height: 1.55;
  color: var(--text);
  background: #0d1220;
  background-image:
    radial-gradient(ellipse 80% 60% at 15% -10%, rgba(59, 90, 246, 0.28), transparent 60%),
    radial-gradient(ellipse 70% 50% at 90% 10%, rgba(139, 92, 246, 0.22), transparent 55%),
    radial-gradient(ellipse 90% 70% at 50% 110%, rgba(6, 182, 212, 0.15), transparent 60%),
    linear-gradient(160deg, #0d1220 0%, #131a2e 50%, #101426 100%);
  background-attachment: fixed;
}

/* ── Vidro ────────────────────────────────────────────────────────────── */
.glass {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.10), 0 8px 32px rgba(0, 0, 0, 0.25);
}

/* ── Tipografia ───────────────────────────────────────────────────────── */
.frost-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
  color: var(--dim);
}

/* ── Controles ────────────────────────────────────────────────────────── */
.input,
select.input {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.75rem;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  outline: none;
  transition: border-color var(--speed) var(--ease), background var(--speed) var(--ease);
}

.input:hover { background: rgba(255, 255, 255, 0.075); }
.input:focus { border-color: rgba(110, 168, 255, 0.6); background: rgba(255, 255, 255, 0.08); }

select.input {
  appearance: none;
  /* Seta desenhada em SVG inline: nada de imagem externa. */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='none' stroke='%239fb0d0' stroke-width='1.5'%3E%3Cpath d='M3 4.5 6 7.5 9 4.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.6rem center;
  background-size: 12px;
  padding-right: 2rem;
  cursor: pointer;
}

select.input option { background: #131a2e; color: var(--text); }

.btn-primary {
  background: linear-gradient(135deg, rgba(76, 120, 255, 0.90), rgba(120, 90, 246, 0.85));
  box-shadow: 0 4px 20px rgba(76, 120, 255, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.6rem 1.25rem;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: filter var(--speed) var(--ease), transform var(--speed) var(--ease);
}

.btn-primary:hover:not(:disabled) { filter: brightness(1.12); }
.btn-primary:active:not(:disabled) { transform: translateY(1px); }
.btn-primary:disabled { opacity: 0.6; cursor: progress; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--muted);
  border-radius: var(--radius-sm);
  padding: 0.45rem 0.8rem;
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--speed) var(--ease), color var(--speed) var(--ease),
              border-color var(--speed) var(--ease);
}

.btn-ghost:hover { background: rgba(255, 255, 255, 0.10); color: var(--text); border-color: var(--border-strong); }
.btn-ghost.accent:hover { color: var(--primary); border-color: rgba(110, 168, 255, 0.45); }
.btn-ghost:disabled { opacity: 0.45; cursor: default; }

/* ── Foco visível em tudo que é interativo ────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: 6px;
}

/* ── Chip ─────────────────────────────────────────────────────────────── */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font-size: 13px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid var(--border);
  color: var(--muted);
}

.chip button {
  background: none;
  border: none;
  color: var(--dim);
  cursor: pointer;
  padding: 0 0 0 2px;
  font-size: 15px;
  line-height: 1;
  transition: color var(--speed) var(--ease);
}

.chip button:hover { color: var(--red); }

/* ── Scrollbar ────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.14);
  border-radius: 5px;
  border: 2px solid transparent;
  background-clip: content-box;
}
::-webkit-scrollbar-thumb:hover { background-color: rgba(255, 255, 255, 0.25); }

/* ── Movimento: respeita quem pediu para reduzir ─────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
