/* UnitV Pro — painel admin (preto + vermelho + gradientes + cards com efeito) */
:root {
  --bg-root: #030203;
  --bg-surface: #0a0508;
  --bg-elevated: #12080c;
  --bg-input: #1a0d10;
  --border: rgba(220, 38, 38, 0.12);
  --border-strong: rgba(220, 38, 38, 0.28);
  --text: #fafafa;
  --text-muted: rgba(255, 255, 255, 0.62);
  --accent: #ef4444;
  --accent-deep: #991b1b;
  --accent-dim: rgba(239, 68, 68, 0.15);
  --accent-hover: #f87171;
  --success: #4ade80;
  --success-dim: rgba(74, 222, 128, 0.14);
  --danger: #fb7185;
  --danger-dim: rgba(251, 113, 133, 0.14);
  --info: #f87171;
  --info-dim: rgba(248, 113, 113, 0.12);
  --violet: #fca5a5;
  --violet-dim: rgba(252, 165, 165, 0.12);
  --magenta: #fecdd3;
  --magenta-dim: rgba(254, 205, 211, 0.1);
  --cyan-bright: #fecaca;
  --cyan-dim: rgba(254, 202, 202, 0.12);
  --lime: #86efac;
  --sidebar-w: 280px;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 12px 40px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(239, 68, 68, 0.06);
  --shadow-card-hover: 0 20px 50px rgba(0, 0, 0, 0.65), 0 0 30px rgba(220, 38, 38, 0.12);
  --font: "Plus Jakarta Sans", system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  height: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg-root);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

@keyframes meshGradient {
  0%, 100% {
    opacity: 1;
    transform: scale(1) translate(0, 0);
  }
  50% {
    opacity: 0.85;
    transform: scale(1.05) translate(1%, -1%);
  }
}

body.app-body {
  min-height: 100vh;
  min-height: 100dvh;
  height: 100%;
  position: relative;
  background-color: var(--bg-root);
  background-image:
    radial-gradient(ellipse 120% 80% at 0% -20%, rgba(127, 29, 29, 0.45), transparent 50%),
    radial-gradient(ellipse 80% 60% at 100% 0%, rgba(185, 28, 28, 0.35), transparent 45%),
    radial-gradient(ellipse 60% 50% at 100% 100%, rgba(69, 10, 10, 0.5), transparent 50%),
    radial-gradient(ellipse 70% 40% at 0% 100%, rgba(220, 38, 38, 0.12), transparent 45%),
    linear-gradient(180deg, #030203 0%, #0a0305 50%, #050308 100%);
  background-attachment: fixed;
  font-size: 15px;
  line-height: 1.55;
  color: var(--text);
}

body.app-body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(circle at 20% 30%, rgba(239, 68, 68, 0.08) 0%, transparent 35%),
    radial-gradient(circle at 80% 70%, rgba(127, 29, 29, 0.15) 0%, transparent 40%);
  animation: meshGradient 18s ease-in-out infinite;
}

.app-shell {
  display: flex;
  min-height: 100vh;
  min-height: 100dvh;
  height: 100%;
  width: 100%;
  position: relative;
  z-index: 1;
}

.app-sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: linear-gradient(180deg, #080305 0%, #0f0609 35%, #050203 100%);
  border-right: 1px solid var(--border);
  box-shadow: 8px 0 48px rgba(0, 0, 0, 0.6), inset -1px 0 0 rgba(239, 68, 68, 0.08);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 100;
}

.app-sidebar__brand {
  padding: 1.5rem 1.25rem 1.25rem;
  border-bottom: 1px solid var(--border);
}

.app-sidebar__logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text);
}

.app-sidebar__logo-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(135deg, #ef4444 0%, #7f1d1d 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1rem;
  color: #fff;
  box-shadow: 0 4px 20px rgba(239, 68, 68, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.app-sidebar__logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.app-sidebar__logo-text strong {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.app-sidebar__logo-text span {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.5);
  font-weight: 500;
}

.app-sidebar__nav {
  flex: 1;
  padding: 1rem 0.75rem;
  overflow-y: auto;
}

.app-sidebar__label {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(248, 113, 113, 0.55);
  padding: 0.5rem 0.75rem 0.35rem;
  margin-top: 0.25rem;
}

.app-nav-link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: background 0.2s, color 0.2s, transform 0.15s, box-shadow 0.2s;
  margin-bottom: 2px;
  border: 1px solid transparent;
}

.app-nav-link i {
  font-size: 1.1rem;
  opacity: 0.85;
}

.app-nav-link:hover {
  color: #ffffff;
  background: rgba(239, 68, 68, 0.1);
  transform: translateX(2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.app-nav-link.is-active {
  color: #fff;
  background: linear-gradient(90deg, rgba(127, 29, 29, 0.45), rgba(239, 68, 68, 0.12));
  border-color: rgba(239, 68, 68, 0.4);
  box-shadow: inset 3px 0 0 var(--accent), 0 4px 20px rgba(220, 38, 38, 0.15);
}

.app-sidebar__footer {
  padding: 1rem 0.75rem;
  border-top: 1px solid var(--border);
}

.app-sidebar__hint {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  padding: 0 0.5rem 0.75rem;
  line-height: 1.4;
}

.app-sidebar__hint code {
  color: var(--accent-hover);
}

.app-main {
  flex: 1;
  margin-left: var(--sidebar-w);
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  height: 100%;
}

.app-topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(180deg, rgba(5, 2, 4, 0.94) 0%, rgba(12, 5, 8, 0.88) 100%);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 1.1rem 1.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
}

.app-topbar__title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.app-topbar__subtitle {
  margin: 0.15rem 0 0;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.72);
}

.app-topbar__actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.app-user-pill {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.35rem 0.65rem 0.35rem 0.35rem;
  background: linear-gradient(135deg, rgba(127, 29, 29, 0.35), var(--bg-elevated));
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  font-size: 0.85rem;
  color: #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.app-user-pill__avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ef4444, #7f1d1d);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
  color: #fff;
}

.app-content {
  flex: 1;
  padding: 1.25rem clamp(0.75rem, 3vw, 1.5rem) 2rem;
  width: 100%;
  max-width: none;
  margin: 0;
  min-height: 0;
}

/* Cards + efeito */
@keyframes cardBorderGlow {
  0%, 100% {
    opacity: 0.5;
  }
  50% {
    opacity: 1;
  }
}

.app-card {
  position: relative;
  background: linear-gradient(165deg, rgba(22, 8, 12, 0.92) 0%, rgba(15, 8, 11, 0.97) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.25s ease;
  overflow: hidden;
}

.app-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.35), transparent 40%, rgba(127, 29, 29, 0.25));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
          mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
  opacity: 0.7;
  animation: cardBorderGlow 6s ease-in-out infinite;
}

.app-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card-hover);
  border-color: rgba(239, 68, 68, 0.22);
}

.app-card--padded {
  padding: 1.35rem 1.5rem;
}

.app-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
  position: relative;
  z-index: 1;
}

.app-card__title {
  font-size: 1rem;
  font-weight: 700;
  margin: 0;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.app-card__desc {
  margin: 0.25rem 0 0;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.68);
  max-width: 48ch;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  position: relative;
  padding: 1.25rem 1.35rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: linear-gradient(160deg, rgba(30, 10, 14, 0.85) 0%, rgba(12, 6, 8, 0.95) 100%);
  overflow: hidden;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.4);
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.5), 0 0 20px rgba(220, 38, 38, 0.08);
}

.stat-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--stat-bar, var(--accent));
  opacity: 0.95;
}

.stat-card--amber { --stat-bar: var(--accent); }
.stat-card--emerald { --stat-bar: var(--success); }
.stat-card--sky { --stat-bar: #f87171; }
.stat-card--rose { --stat-bar: var(--danger); }

.stat-card__icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 0.85rem;
  background: var(--stat-icon-bg, var(--accent-dim));
  color: var(--stat-icon, var(--accent));
}

.stat-card--emerald .stat-card__icon {
  --stat-icon-bg: var(--success-dim);
  --stat-icon: var(--success);
}
.stat-card--sky .stat-card__icon {
  --stat-icon-bg: var(--info-dim);
  --stat-icon: #fecaca;
}
.stat-card--rose .stat-card__icon {
  --stat-icon-bg: var(--danger-dim);
  --stat-icon: var(--danger);
}

.stat-card__label {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.65);
  font-weight: 500;
  margin-bottom: 0.15rem;
}

.stat-card__value {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.1;
  color: #ffffff;
}

.stat-card__foot {
  margin-top: 0.65rem;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.55);
}

.app-form-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.35rem;
}

.form-control.app-input,
textarea.form-control.app-input {
  background: var(--bg-input) !important;
  border: 1px solid var(--border-strong) !important;
  color: #ffffff !important;
  border-radius: var(--radius-sm);
  padding: 0.55rem 0.85rem;
}

.form-control.app-input::placeholder {
  color: rgba(255, 255, 255, 0.38);
}

.form-control.app-input:focus {
  border-color: rgba(239, 68, 68, 0.65) !important;
  box-shadow: 0 0 0 3px var(--accent-dim) !important;
}

.btn-app-primary {
  background: linear-gradient(180deg, #f87171 0%, #dc2626 50%, #991b1b 100%);
  border: none;
  color: #fff;
  font-weight: 700;
  border-radius: var(--radius-sm);
  padding: 0.6rem 1.15rem;
  transition: filter 0.2s, transform 0.12s, box-shadow 0.2s;
  box-shadow: 0 4px 16px rgba(220, 38, 38, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.btn-app-primary:hover {
  filter: brightness(1.08);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(220, 38, 38, 0.45);
}

.btn-app-accent {
  background: linear-gradient(180deg, rgba(248, 113, 113, 0.95) 0%, #b91c1c 100%);
  border: none;
  color: #fff;
  font-weight: 700;
  border-radius: var(--radius-sm);
  padding: 0.55rem 1rem;
  transition: filter 0.15s, transform 0.1s;
  box-shadow: 0 4px 14px rgba(185, 28, 28, 0.35);
}

.btn-app-accent:hover {
  filter: brightness(1.08);
  color: #fff;
}

.btn-app-ghost {
  background: transparent;
  border: 1px solid var(--border-strong);
  color: rgba(255, 255, 255, 0.88);
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: background 0.2s, border-color 0.2s;
}

.btn-app-ghost:hover {
  color: #ffffff;
  border-color: rgba(239, 68, 68, 0.45);
  background: rgba(239, 68, 68, 0.08);
}

.btn-app-danger {
  border: 1px solid rgba(248, 113, 113, 0.4);
  color: #fecaca;
  background: rgba(127, 29, 29, 0.35);
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: background 0.2s, transform 0.1s;
}

.btn-app-danger:hover {
  background: rgba(185, 28, 28, 0.45);
  color: #fff;
}

.app-table-wrap {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  background: var(--bg-elevated);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
}

.table.app-table {
  --bs-table-bg: transparent;
  --bs-table-color: var(--text);
  --bs-table-border-color: var(--border);
  margin: 0;
  font-size: 0.88rem;
}

.table.app-table thead th {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 700;
  border-bottom-color: var(--border-strong);
  padding: 0.85rem 1rem;
  background: linear-gradient(180deg, rgba(127, 29, 29, 0.35), rgba(0, 0, 0, 0.4));
}

.table.app-table tbody td {
  padding: 0.85rem 1rem;
  vertical-align: middle;
  color: rgba(255, 255, 255, 0.95);
}

.table.app-table tbody tr {
  cursor: pointer;
  transition: background 0.15s;
}

.table.app-table tbody tr:hover {
  background: rgba(239, 68, 68, 0.06);
}

.badge-app {
  padding: 0.28em 0.65em;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.badge-app--ok {
  background: var(--success-dim);
  color: var(--success);
  border: 1px solid rgba(52, 211, 153, 0.35);
}

.badge-app--off {
  background: var(--danger-dim);
  color: var(--danger);
  border: 1px solid rgba(248, 113, 113, 0.35);
}

.mac-cell {
  font-family: ui-monospace, monospace;
  font-weight: 600;
  color: #fca5a5;
  font-size: 0.82rem;
}

.text-dim {
  color: rgba(255, 255, 255, 0.55) !important;
}

.text-white-50 {
  color: rgba(255, 255, 255, 0.55) !important;
}

.border-violet {
  border-color: rgba(239, 68, 68, 0.5) !important;
}

.badge-pill-cyan {
  background: var(--cyan-dim);
  color: var(--cyan-bright);
  border: 1px solid rgba(254, 202, 202, 0.35);
}

.badge-pill-magenta {
  background: var(--magenta-dim);
  color: #fecdd3;
  border: 1px solid rgba(251, 113, 133, 0.35);
}

.badge-pill-lime {
  background: rgba(74, 222, 128, 0.12);
  color: var(--lime);
  border: 1px solid rgba(74, 222, 128, 0.35);
}

.dns-add-row {
  display: flex;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.dns-add-row .form-control {
  flex: 1;
  min-width: 200px;
}

.dns-stack {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dns-empty {
  padding: 1rem 1.1rem;
  border-radius: var(--radius-sm);
  border: 1px dashed var(--border-strong);
  text-align: center;
  font-size: 0.88rem;
}

.dns-chip {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.55rem 0.75rem;
  border-radius: var(--radius-sm);
  background: rgba(127, 29, 29, 0.2);
  border: 1px solid rgba(239, 68, 68, 0.25);
}

.dns-chip__text {
  flex: 1;
  font-size: 0.9rem;
  color: #ffffff;
  word-break: break-all;
}

.dns-chip__remove {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 8px;
  background: rgba(127, 29, 29, 0.5);
  color: #fff;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s;
}

.dns-chip__remove:hover {
  background: rgba(220, 38, 38, 0.65);
  color: #fff;
}

.alert-app--success {
  background: var(--success-dim);
  border-color: rgba(74, 222, 128, 0.35);
  color: #bbf7d0;
}

.modal-content.app-modal-dark {
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  color: #fff;
  border-radius: var(--radius);
}

.modal-content.app-modal-dark .modal-header {
  border-bottom-color: var(--border);
}

.modal-content.app-modal-dark .modal-footer {
  border-top-color: var(--border);
}

.modal-content.app-modal-dark .btn-close {
  filter: invert(1);
  opacity: 0.7;
}

.info-dl dt {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 0.15rem;
}

.info-dl dd {
  margin-bottom: 0.85rem;
  font-size: 0.92rem;
  word-break: break-all;
}

.info-dl dd:last-child {
  margin-bottom: 0;
}

.dns-replace-card {
  border-left: 4px solid var(--accent);
}

.alert-app {
  border-radius: var(--radius-sm);
  border: 1px solid;
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
}

.alert-app--danger {
  background: rgba(127, 29, 29, 0.35);
  border-color: rgba(248, 113, 113, 0.4);
  color: #fecaca;
}

/* ========== Login — tela cheia, animação, responsivo ========== */
@keyframes loginFadeUp {
 from {
    opacity: 0;
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes loginPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.45), 0 8px 32px rgba(220, 38, 38, 0.35);
  }
  50% {
    box-shadow: 0 0 0 12px rgba(239, 68, 68, 0), 0 12px 40px rgba(220, 38, 38, 0.5);
  }
}

@keyframes loginBgDrift {
  0% {
    transform: translate(0, 0) scale(1);
  }
  50% {
    transform: translate(-2%, 2%) scale(1.03);
  }
  100% {
    transform: translate(0, 0) scale(1);
  }
}

html:has(.login-page),
body:has(.login-page) {
  min-height: 100%;
  height: auto;
}

.login-page {
  min-height: 100vh;
  min-height: 100dvh;
  width: 100%;
  display: flex;
  align-items: stretch;
  background: #020103;
  font-family: var(--font);
  position: relative;
  overflow-x: hidden;
}

.login-page::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 90% 70% at 10% 20%, rgba(127, 29, 29, 0.55), transparent 55%),
    radial-gradient(ellipse 70% 50% at 90% 80%, rgba(69, 10, 10, 0.65), transparent 50%),
    linear-gradient(160deg, #020102 0%, #0a0305 40%, #050208 100%);
  animation: loginBgDrift 22s ease-in-out infinite;
  pointer-events: none;
}

.login-page::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  background: repeating-linear-gradient(
    -12deg,
    transparent,
    transparent 120px,
    rgba(220, 38, 38, 0.02) 120px,
    rgba(220, 38, 38, 0.02) 121px
  );
  pointer-events: none;
  opacity: 0.6;
}

.login-page__aside {
  flex: 0 0 42%;
  max-width: 520px;
  background: linear-gradient(165deg, rgba(15, 5, 8, 0.97) 0%, #080205 50%, #030102 100%);
  border-right: 1px solid rgba(220, 38, 38, 0.2);
  padding: clamp(1.5rem, 4vw, 3rem) clamp(1.25rem, 3vw, 2.5rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.login-page__aside::before {
  content: "";
  position: absolute;
  width: min(90vw, 420px);
  height: min(90vw, 420px);
  background: radial-gradient(circle, rgba(239, 68, 68, 0.25) 0%, transparent 68%);
  top: -15%;
  right: -20%;
  pointer-events: none;
  animation: loginBgDrift 16s ease-in-out infinite reverse;
}

.login-page__aside::after {
  content: "";
  position: absolute;
  bottom: 10%;
  left: -30%;
  width: 80%;
  height: 40%;
  background: radial-gradient(ellipse, rgba(127, 29, 29, 0.2) 0%, transparent 70%);
  pointer-events: none;
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  position: relative;
  z-index: 1;
}

.login-brand__mark {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, #ef4444, #450a0a);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.2rem;
  color: #fff;
  animation: loginPulse 3.5s ease-in-out infinite;
}

.login-aside-title {
  font-size: clamp(1.15rem, 2.5vw, 1.65rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.25;
  margin: 0 0 0.75rem;
  position: relative;
  z-index: 1;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.5);
}

.login-aside-list {
  margin: 0;
  padding: 0;
  list-style: none;
  position: relative;
  z-index: 1;
}

.login-aside-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin-bottom: 0.85rem;
  font-size: clamp(0.85rem, 1.8vw, 0.92rem);
  color: rgba(255, 255, 255, 0.78);
  transition: transform 0.2s;
}

.login-aside-list li:hover {
  transform: translateX(4px);
}

.login-aside-list i {
  color: var(--accent-hover);
  margin-top: 3px;
  filter: drop-shadow(0 0 6px rgba(239, 68, 68, 0.45));
}

.login-page__main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(1rem, 4vw, 2rem);
  position: relative;
  z-index: 1;
  background-image: radial-gradient(ellipse 80% 60% at 70% 20%, rgba(127, 29, 29, 0.12), transparent);
}

.login-page__main::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(220, 38, 38, 0.06) 0%, transparent 45%);
  pointer-events: none;
}

.login-card {
  width: 100%;
  max-width: 420px;
  position: relative;
  z-index: 1;
}

div.login-card__inner {
  animation: loginFadeUp 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.login-card__inner {
  position: relative;
  background: linear-gradient(165deg, rgba(18, 6, 10, 0.92) 0%, rgba(8, 3, 6, 0.95) 100%);
  border: 1px solid rgba(239, 68, 68, 0.22);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 4vw, 2rem);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.65), 0 0 40px rgba(220, 38, 38, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: box-shadow 0.35s ease, border-color 0.35s ease;
}

.login-card__inner:hover {
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.7), 0 0 48px rgba(220, 38, 38, 0.12);
  border-color: rgba(239, 68, 68, 0.35);
}

.login-card__inner::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), transparent 50%, rgba(127, 29, 29, 0.15));
  z-index: -1;
  opacity: 0.5;
  filter: blur(12px);
}

.login-card h1 {
  font-size: 1.45rem;
  font-weight: 800;
  margin: 0 0 0.35rem;
  letter-spacing: -0.03em;
}

.login-card .lead-in {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.login-card .lead-in code {
  color: #fca5a5;
  background: rgba(127, 29, 29, 0.35);
  padding: 0.1em 0.35em;
  border-radius: 6px;
}

/* Painel interno — mobile / tablet */
@media (max-width: 991.98px) {
  .login-page {
    flex-direction: column;
    min-height: 100vh;
    min-height: 100dvh;
  }

  .login-page__aside {
    flex: 0 0 auto;
    max-width: none;
    width: 100%;
    border-right: none;
    border-bottom: 1px solid rgba(220, 38, 38, 0.25);
    padding: 1.25rem 1.25rem 1rem;
  }

  .login-aside-title {
    margin-top: 0.75rem;
    font-size: 1.05rem;
  }

  .login-aside-list {
    display: grid;
    gap: 0.5rem;
  }

  .login-aside-list li {
    margin-bottom: 0;
    font-size: 0.8rem;
  }

  .login-page__main {
    flex: 1;
    align-items: flex-start;
    padding: 1.25rem 1rem 2rem;
  }

  .app-shell {
    flex-direction: column;
  }

  .app-sidebar {
    position: fixed !important;
    left: -280px !important;
    top: 0 !important;
    bottom: 0 !important;
    width: 280px !important;
    z-index: 9999 !important;
    flex-direction: column !important;
    border-bottom: none;
    transition: left 0.3s ease !important;
  }

  .app-sidebar.active {
    left: 0 !important;
  }

  .app-main {
    margin-left: 0;
    width: 100%;
  }

  .app-content {
    padding-bottom: calc(2rem + env(safe-area-inset-bottom, 0px));
  }
}
