/* assets/css/login.css — login espelhando o painel Vue (escuro, minimalista). */

:root {
  --bg-main:    #0d0f16;
  --bg-card:    #161922;
  --bg-muted:   #1d212e;
  --text-main:  #f1f5f9;
  --text-muted: #94a3b8;
  --text-faint: #64748b;
  --border-color: rgba(255, 255, 255, 0.08);
  --danger: #ef4444;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-full: 9999px;
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.55);
  --transition: 0.18s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Cor principal — azul (padrão) / vermelho */
body[data-theme-color="blue"],
body:not([data-theme-color]) {
  --accent: #1d4ed8;
  --accent-hover: #1e40af;
  --accent-soft: rgba(29, 78, 216, 0.14);
  --accent-border: rgba(29, 78, 216, 0.5);
  --accent-rgb: 29, 78, 216;
}
body[data-theme-color="red"] {
  --accent: #f43f5e;
  --accent-hover: #e11d48;
  --accent-soft: rgba(244, 63, 94, 0.14);
  --accent-border: rgba(244, 63, 94, 0.5);
  --accent-rgb: 244, 63, 94;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  overflow: hidden;
  color: var(--text-main);
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background:
    radial-gradient(900px circle at 50% -10%, rgba(var(--accent-rgb), 0.18), transparent 60%),
    radial-gradient(600px circle at 100% 100%, rgba(var(--accent-rgb), 0.08), transparent 55%),
    var(--bg-main);
}

/* ===== Seletor de tema ===== */
.login__theme {
  position: absolute;
  top: 20px;
  right: 20px;
  display: flex;
  gap: 8px;
  padding: 6px 9px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
}
.theme-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid transparent;
  padding: 0;
  cursor: pointer;
  transition: transform var(--transition);
}
.theme-dot:hover {
  transform: scale(1.15);
}
.theme-dot.is-active {
  border-color: #fff;
}
.theme-dot--blue {
  background: #1d4ed8;
}
.theme-dot--red {
  background: #f43f5e;
}

/* ===== Card ===== */
.card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 380px;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 40px 32px 32px;
}
.card__logo {
  width: 265px;
  max-width: 80%;
  height: auto;
  display: block;
  margin-bottom: 8px;
}
.card__body {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* ===== Campos ===== */
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.field__label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
}
.field__wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.field__prefix {
  position: absolute;
  left: 13px;
  display: flex;
  align-items: center;
  color: var(--text-faint);
  pointer-events: none;
}
.field__prefix svg {
  width: 17px;
  height: 17px;
}
.field__input {
  width: 100%;
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-main);
  padding: 11px 14px;
  font-size: 0.9rem;
  font-family: inherit;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.field__input.has-prefix {
  padding-left: 40px;
}
.field__input.has-suffix {
  padding-right: 42px;
}
.field__input::placeholder {
  color: var(--text-faint);
}
.field__input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.field__input:focus ~ .field__prefix {
  color: var(--accent);
}
.field__suffix {
  position: absolute;
  right: 6px;
  display: flex;
  align-items: center;
}
.eye {
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: var(--text-faint);
  padding: 8px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}
.eye svg {
  width: 18px;
  height: 18px;
}
.eye:hover,
.eye.is-on {
  color: var(--text-main);
}

/* ===== Botão ===== */
.btn-login {
  margin-top: 8px;
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: var(--radius-md);
  background: var(--accent);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background var(--transition);
}
.btn-login:hover {
  background: var(--accent-hover);
}

/* ===== Toast ===== */
.toast-container {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.toast {
  padding: 12px 18px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-left: 3px solid var(--danger);
  color: var(--text-main);
  font-size: 0.875rem;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  transform: translateY(-10px);
  transition: all 0.3s ease;
}
.toast.show {
  opacity: 1;
  transform: translateY(0);
}
