/* Project Car — painel web profissional */
:root {
  --bg: #070b12;
  --sidebar: #0a0f18;
  --surface: #0e1520;
  --surface-2: #111b29;
  --surface-3: #162131;
  --border: #1d2a3c;
  --border-soft: rgba(129, 157, 190, .12);
  --text: #edf3fa;
  --muted: #7f91a8;
  --blue: #4285ff;
  --blue-soft: rgba(66, 133, 255, .12);
  --cyan: #21c5d9;
  --purple: #9b7bff;
  --green: #35d07f;
  --amber: #f6b84a;
  --red: #ff5d68;
  --mono: "Cascadia Code", Consolas, "Courier New", monospace;
  --shadow: 0 18px 48px rgba(0, 0, 0, .28);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { height: 100%; scroll-behavior: smooth; }
body {
  height: 100vh;
  overflow: hidden;
  color: var(--text);
  background:
    radial-gradient(900px 500px at 62% -120px, rgba(47, 111, 237, .16), transparent 65%),
    var(--bg);
  font-family: Inter, "Segoe UI", system-ui, -apple-system, sans-serif;
  font-size: 14px;
}
button, input { font: inherit; }
button { transition: transform .15s ease, border-color .15s ease, background .15s ease; }
button:hover { transform: translateY(-1px); }
.hidden { display: none !important; }
.tab-hidden { display: none !important; }
.eyebrow, .section-kicker {
  color: #6e8aaa; font-size: 10px; font-weight: 800; letter-spacing: .16em;
}

/* Login */
.login-overlay {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: flex-start; justify-content: center;
  overflow-x: hidden; overflow-y: auto; padding: 16px;
  background:
    linear-gradient(rgba(4, 8, 14, .86), rgba(4, 8, 14, .94)),
    radial-gradient(circle at 50% 0, rgba(66, 133, 255, .28), transparent 45%);
}
.login-card {
  width: min(540px, 100%);
  margin: auto 0;
  padding: 24px 28px;
  border: 1px solid rgba(110, 144, 181, .2);
  border-radius: 20px;
  background: linear-gradient(150deg, rgba(19, 29, 44, .98), rgba(10, 16, 25, .98));
  box-shadow: 0 28px 90px rgba(0, 0, 0, .55);
}
.login-brand, .side-brand { display: flex; align-items: center; gap: 12px; }
.login-brand { justify-content: center; }
.login-logo { display: block; width: min(260px, 100%); height: auto; }
.side-logo { display: block; width: 190px; max-width: 100%; height: auto; }
.login-mark, .brand-mark {
  display: grid; place-items: center; flex: 0 0 auto;
  width: 42px; height: 42px; border-radius: 12px;
  color: #fff; font-size: 12px; font-weight: 900; letter-spacing: -.02em;
  background: linear-gradient(145deg, #3478ff, #1651c8);
  box-shadow: 0 8px 22px rgba(47, 111, 237, .3);
}
.login-brand h1 { font-size: 17px; }
.login-brand p { color: var(--muted); font-size: 12px; margin-top: 2px; }
.login-copy { margin: 15px 0 14px; }
.login-copy h2 { margin: 7px 0 8px; font-size: 25px; letter-spacing: -.03em; }
.login-copy p { color: var(--muted); line-height: 1.55; }
.login-card label { display: block; color: #a8b7c9; font-size: 12px; margin-bottom: 5px; }
.login-card input {
  width: 100%; padding: 10px 12px; margin-bottom: 9px;
  border: 1px solid var(--border); border-radius: 10px;
  color: var(--text); background: #09111c;
}
.login-card input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(66, 133, 255, .12); }
.login-card button {
  width: 100%; padding: 11px; border: 0; border-radius: 10px;
  color: #fff; background: linear-gradient(135deg, #3478ff, #195bd8);
  font-weight: 700; cursor: pointer;
}
.login-card button:disabled { cursor: wait; opacity: .65; }
.login-card .btn-auth-secondary {
  margin-top: 9px;
  border: 1px solid rgba(110, 144, 181, .24);
  color: #9eb1c7;
  background: rgba(9, 17, 28, .72);
}
.login-card .btn-auth-secondary:hover {
  color: #fff;
  border-color: rgba(66, 133, 255, .55);
}
.discord-auth-panel {
  padding: 18px;
  border: 1px solid rgba(88, 101, 242, .55);
  border-radius: 14px;
  text-align: center;
  background: rgba(88, 101, 242, .1);
}
.discord-auth-panel h3 { margin: 9px 0 6px; }
.discord-auth-panel p {
  margin: 0 0 15px;
  color: #b8c4d6;
  font-size: 13px;
  line-height: 1.5;
}
.discord-auth-panel .discord-mark {
  color: #aeb7ff;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
}
.discord-auth-panel #btnDiscordAuth {
  background: linear-gradient(135deg, #5865f2, #404eed);
}
.auth-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.trial-info {
  margin: 0 0 9px;
  color: #77d7a4;
  font-size: 11px;
  text-align: center;
}
.login-erro {
  color: #ff8991; min-height: 0; margin: 0 0 10px;
  font-size: 12px; text-align: center;
}
.login-erro:empty { display: none; }
.login-advanced {
  margin: 12px 0 4px;
  color: #7d8fa3;
  font-size: 12px;
}
.login-advanced summary {
  cursor: pointer;
  margin-bottom: 8px;
  color: #9aabbd;
}
.login-advanced[open] summary { margin-bottom: 10px; }
.login-security { color: #708299; font-size: 11px; text-align: center; margin-top: 12px; }
.login-security span { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--green); margin-right: 5px; }

@media (max-width: 560px) {
  .login-overlay { padding: 8px; }
  .login-card { padding: 18px; border-radius: 14px; }
  .login-logo { width: min(210px, 100%); }
  .login-copy { margin: 8px 0 10px; }
  .login-copy h2 { font-size: 21px; margin: 4px 0; }
  .login-copy p { font-size: 11px; }
  .auth-grid { gap: 8px; }
}

@media (max-width: 390px) {
  .auth-grid { grid-template-columns: 1fr; gap: 0; }
}

/* Configuração isolada por tenant */
.tenant-settings-form { padding: 6px 2px 18px; }
.tenant-settings-form label {
  display: block;
  margin: 13px 0 6px;
  color: #8fa2b8;
  font-size: 11px;
  font-weight: 700;
}
.tenant-settings-form input {
  width: 100%;
  padding: 12px 13px;
  border: 1px solid var(--border);
  border-radius: 9px;
  color: var(--text);
  background: #09111c;
}
.tenant-settings-form input:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(66, 133, 255, .12);
}
.tenant-settings-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.tenant-settings-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
}
.tenant-license-box, .tenant-bridge-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px;
  border: 1px solid rgba(66, 133, 255, .2);
  border-radius: 12px;
  background: rgba(9, 17, 28, .75);
}
.tenant-bridge-box { margin-bottom: 12px; }
.tenant-license-box strong, .tenant-bridge-box strong {
  display: block;
  margin: 7px 0 5px;
  color: #d9e7f8;
  font-family: var(--mono);
  font-size: 14px;
}
.tenant-license-box small, .tenant-bridge-box small { color: #71859c; }
.tenant-bridge-box strong.online { color: #75d9a4; }
.tenant-bridge-box strong.offline { color: #ff9299; }
.bridge-download-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 9px;
  border: 1px solid rgba(110, 144, 181, .2);
  border-radius: 7px;
  color: #8296ad;
  background: rgba(9, 17, 28, .6);
  font-size: 10px;
  text-decoration: none;
  white-space: nowrap;
}
.bridge-download-link:hover {
  color: #b9c9da;
  border-color: rgba(66, 133, 255, .4);
}

.admin-clients-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, .8fr);
  gap: 16px;
}
.admin-client-detail {
  min-height: 260px;
  padding: 18px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: rgba(9, 17, 28, .74);
}
.admin-client-detail h3 { margin-bottom: 5px; font-size: 17px; }
.admin-client-detail .client-email { color: #8296ad; font-size: 11px; }
.admin-client-meta {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 7px 10px;
  margin: 18px 0;
  font-size: 11px;
}
.admin-client-meta span { color: #657990; }
.admin-client-meta b {
  overflow: hidden;
  color: #b7c7d9;
  font-family: var(--mono);
  font-weight: 500;
  text-overflow: ellipsis;
}
.admin-client-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.admin-client-actions button { width: 100%; }
.admin-client-actions [data-client-action="excluir"] { grid-column: 1 / -1; }
.client-row { cursor: pointer; }
.client-row:hover td { background: rgba(66, 133, 255, .06); }
.client-row.selected td { background: rgba(66, 133, 255, .1); }
.client-status {
  display: inline-flex;
  padding: 4px 7px;
  border-radius: 999px;
  color: #75d9a4;
  background: rgba(49, 195, 125, .1);
}
.client-status.suspended {
  color: #ff9299;
  background: rgba(255, 93, 104, .1);
}
.btn-danger {
  padding: 9px 12px;
  border: 1px solid rgba(255, 93, 104, .35);
  border-radius: 8px;
  color: #ff9ba2;
  background: rgba(255, 93, 104, .1);
  cursor: pointer;
}
.btn-danger:hover { background: rgba(255, 93, 104, .18); }

@media (max-width: 700px) {
  .tenant-settings-grid { grid-template-columns: 1fr; gap: 0; }
  .tenant-settings-actions, .tenant-license-box, .tenant-bridge-box {
    align-items: stretch;
    flex-direction: column;
  }
  .admin-clients-layout { grid-template-columns: 1fr; }
}

/* Estrutura */
.app-shell { height: 100vh; min-height: 0; display: grid; grid-template-columns: 238px minmax(0, 1fr); }
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: 238px; z-index: 30;
  display: flex; flex-direction: column; padding: 24px 16px 18px;
  background: linear-gradient(180deg, #0b111b, #080d15);
  border-right: 1px solid var(--border-soft);
}
.side-brand { justify-content: center; padding: 0 8px 20px; border-bottom: 1px solid var(--border-soft); }
.side-brand strong, .side-brand span { display: block; }
.side-brand strong { font-size: 15px; }
.side-brand span { color: var(--muted); font-size: 11px; margin-top: 2px; }
.brand-mark { width: 36px; height: 36px; border-radius: 10px; }
.side-nav { display: flex; flex-direction: column; gap: 5px; padding-top: 22px; }
.side-nav a {
  display: flex; align-items: center; gap: 11px; padding: 11px 12px;
  border: 1px solid transparent; border-radius: 9px;
  color: #8494a8; text-decoration: none; font-size: 12px; font-weight: 600;
}
.side-nav a span { color: #52657d; font-family: var(--mono); font-size: 9px; }
.side-nav a:hover, .side-nav a.active {
  color: #e9f1fb; background: var(--blue-soft); border-color: rgba(66, 133, 255, .18);
}
.side-nav a.active span { color: #67a0ff; }
.side-status { margin-top: auto; padding: 15px 12px; border: 1px solid var(--border-soft); border-radius: 11px; background: rgba(255,255,255,.018); }
.status-label { color: #53657b; font-size: 9px; letter-spacing: .12em; font-weight: 800; margin-bottom: 12px; }
.status-row { display: flex; align-items: center; gap: 10px; }
.status-row strong, .status-row small { display: block; }
.status-row strong { font-size: 11px; }
.status-row small { color: var(--muted); font-size: 9px; margin-top: 2px; }
.conn-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--red); box-shadow: 0 0 10px rgba(255, 93, 104, .5); }
.conn-dot.on { background: var(--green); box-shadow: 0 0 10px rgba(53, 208, 127, .55); }
.btn-logout {
  margin-top: 9px; padding: 10px; border: 1px solid var(--border-soft); border-radius: 9px;
  color: #75869b; background: transparent; cursor: pointer; font-size: 11px;
}
.btn-logout:hover { color: var(--text); border-color: #34455b; }
.workspace {
  grid-column: 2; min-width: 0; height: 100vh; min-height: 0; overflow: hidden;
  display: grid; grid-template-rows: 78px minmax(0, 1fr);
}
.topbar {
  position: relative; z-index: 20;
  display: flex; justify-content: space-between; align-items: center;
  min-height: 78px; padding: 15px 30px;
  border-bottom: 1px solid var(--border-soft);
  background: rgba(7, 11, 18, .82); backdrop-filter: blur(16px);
}
.topbar h1 { font-size: 17px; margin-top: 4px; letter-spacing: -.02em; }
.topbar-meta { display: flex; align-items: center; gap: 16px; text-align: right; }
.topbar-meta span, .topbar-meta strong { display: block; }
.topbar-meta span { color: #52657d; font-size: 8px; font-weight: 800; letter-spacing: .1em; }
.topbar-meta strong { margin-top: 3px; font-family: var(--mono); font-size: 11px; color: #a4b4c7; font-weight: 500; }
.operator-avatar {
  display: grid; place-items: center; width: 34px; height: 34px;
  border-radius: 50%; border: 1px solid #2a3b51; color: #a8c8ff;
  background: #111c2b; font-size: 10px; font-weight: 800;
}
.container {
  width: min(1540px, 100%); height: 100%; min-height: 0; margin: 0 auto;
  padding: 20px 30px 12px; overflow: hidden;
  display: flex; flex-direction: column;
}
.welcome { display: flex; justify-content: space-between; align-items: center; margin-bottom: 22px; }
.welcome h2 { margin: 5px 0 5px; font-size: 24px; letter-spacing: -.035em; }
.welcome p { color: var(--muted); font-size: 12px; }
.system-ok {
  display: flex; align-items: center; gap: 8px; padding: 9px 12px;
  border: 1px solid rgba(53, 208, 127, .2); border-radius: 999px;
  color: #84e3af; background: rgba(53, 208, 127, .07); font-size: 10px; font-weight: 700;
}
.system-ok i, .live-pill i { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px rgba(53,208,127,.6); }

/* Métricas */
.cards { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; }
.card {
  position: relative; overflow: hidden; min-height: 126px; padding: 15px 16px;
  border: 1px solid var(--border-soft); border-radius: 12px;
  background: linear-gradient(145deg, rgba(17, 27, 41, .94), rgba(12, 19, 29, .96));
  box-shadow: 0 8px 28px rgba(0,0,0,.12);
}
.card::after {
  content: ""; position: absolute; right: -35px; top: -45px; width: 105px; height: 105px;
  border-radius: 50%; background: var(--metric-color); opacity: .07; filter: blur(4px);
}
.metric-top { display: flex; justify-content: space-between; align-items: center; }
.metric-icon {
  display: grid; place-items: center; width: 27px; height: 27px; border-radius: 8px;
  color: var(--metric-color); background: color-mix(in srgb, var(--metric-color) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--metric-color) 22%, transparent);
  font-size: 10px; font-weight: 900;
}
.metric-state { color: #506278; font-size: 7px; font-weight: 800; letter-spacing: .1em; }
.card-value { margin-top: 13px; font-size: 25px; line-height: 1; font-weight: 750; letter-spacing: -.04em; }
.card-label { color: var(--muted); margin-top: 7px; font-size: 10px; }
.card-blue { --metric-color: var(--blue); }
.card-purple { --metric-color: var(--purple); }
.card-cyan { --metric-color: var(--cyan); }
.card-red { --metric-color: var(--red); }
.card-red .card-value { color: #ff7d86; }
.card-green { --metric-color: var(--green); }
.card-amber { --metric-color: var(--amber); }

/* Painéis */
.grid {
  flex: 1; min-height: 0;
  display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr);
  gap: 18px; margin-bottom: 12px;
}
.grid.single-tab { grid-template-columns: minmax(0, 1fr); }
.grid > .panel { min-height: 0; display: flex; flex-direction: column; }
.panel {
  scroll-margin-top: 95px; overflow: hidden;
  border: 1px solid var(--border-soft); border-radius: 13px;
  background: linear-gradient(145deg, rgba(15, 23, 35, .96), rgba(11, 18, 28, .98));
  box-shadow: var(--shadow);
}
.painel-recursos-ativos {
  flex: 1; min-height: 0; margin-bottom: 12px;
  display: flex; flex-direction: column;
}
.panel-head {
  min-height: 67px; padding: 14px 17px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  border-bottom: 1px solid var(--border-soft);
}
.panel-title { display: flex; align-items: center; gap: 11px; }
.panel-icon {
  display: grid; place-items: center; flex: 0 0 auto; width: 30px; height: 30px;
  border-radius: 8px; color: #8cb7ff; background: var(--blue-soft);
  border: 1px solid rgba(66,133,255,.2); font-size: 10px; font-weight: 900;
}
.panel-icon.green { color: #79dfa8; background: rgba(53,208,127,.09); border-color: rgba(53,208,127,.18); }
.panel-icon.red { color: #ff8991; background: rgba(255,93,104,.09); border-color: rgba(255,93,104,.18); }
.panel-icon.purple { color: #baa8ff; background: rgba(155,123,255,.09); border-color: rgba(155,123,255,.18); }
.panel-icon.amber { color: #e1b565; background: rgba(246,184,74,.09); border-color: rgba(246,184,74,.18); }
.painel-jogadores {
  flex: 1; min-height: 0; margin-bottom: 12px;
  display: flex; flex-direction: column;
}
.jogadores-layout {
  flex: 1; min-height: 0; display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, .75fr);
}
.tabela-jogadores { min-height: 0; overflow: auto; }
.tabela-jogadores tbody tr { cursor: pointer; }
.tabela-jogadores tbody tr.selected { background: rgba(66,133,255,.08); }
.muted-line { color: #60738a; font-size: 8px; margin-top: 2px; }
.player-ip { color: #8db9ff; font-family: var(--mono); font-size: 9px; white-space: nowrap; }
.jogador-detalhe {
  border-left: 1px solid var(--border-soft); background: rgba(4,8,14,.35);
  min-height: 0; overflow: auto; padding: 14px;
}
.jogador-card-head {
  display: flex; justify-content: space-between; gap: 12px; margin-bottom: 14px;
}
.jogador-card-head h3 { font-size: 14px; margin-bottom: 4px; }
.jogador-card-head span { color: #60738a; font-size: 9px; }
.jogador-stats {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 14px;
}
.jogador-stats > div {
  padding: 8px 10px; border: 1px solid var(--border-soft); border-radius: 8px;
  background: rgba(255,255,255,.02);
}
.jogador-stats span { display: block; color: #60738a; font-size: 8px; margin-bottom: 4px; }
.jogador-stats b { color: #d7e3f0; font-size: 11px; font-weight: 650; word-break: break-word; }
.jogador-stats .full { grid-column: 1 / -1; }
.jogador-acoes { display: flex; flex-wrap: wrap; gap: 7px; }
.panel-head h2 { font-size: 12px; font-weight: 700; }
.panel-sub { display: block; color: #60738a; font-size: 9px; margin-top: 3px; }
.panel-actions { display: flex; align-items: center; gap: 8px; }
.btn-primary, .btn-secondary, .btn-mini {
  padding: 7px 11px; border-radius: 7px; cursor: pointer; font-size: 9px; font-weight: 750;
}
.btn-primary { border: 1px solid #3a7af0; color: #fff; background: linear-gradient(135deg, #3b82f6, #2563cc); }
.btn-secondary, .btn-mini { border: 1px solid #2a3b51; color: #a9b8ca; background: #121d2b; }
.btn-secondary:hover, .btn-mini:hover { color: #fff; border-color: #416083; }
.badge { padding: 4px 7px; border-radius: 999px; color: #ff9aa1; background: rgba(255,93,104,.1); font-size: 8px; font-weight: 900; letter-spacing: .08em; }
.live-pill { display: flex; align-items: center; gap: 6px; color: #7edba7; font-size: 8px; font-weight: 900; letter-spacing: .1em; }
.busca-recursos {
  width: 230px; max-width: 42%; padding: 9px 11px;
  border: 1px solid #26364a; border-radius: 8px;
  color: var(--text); background: #0a121d; font-size: 10px;
}
.busca-recursos:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(66,133,255,.08); }
.resource-filters { display: flex; justify-content: flex-end; gap: 7px; flex: 1; }
.resource-filters select.busca-recursos { width: 125px; }
.lista-recursos-ativos { flex: 1; min-height: 0; overflow: hidden; padding: 0; }
.recurso-ativo {
  padding: 5px 8px; border: 1px solid rgba(53,208,127,.16); border-radius: 6px;
  color: #76dca4; background: rgba(53,208,127,.055); font: 9px var(--mono);
}
.tabela-resources {
  height: 100%; max-height: none; overflow: auto;
  scroll-padding-bottom: 24px; scrollbar-gutter: stable;
}
.tabela-resources::after { content: ""; display: block; height: 22px; }
.tabela-resources tbody tr:last-child td { border-bottom: 0; }
.tabela-resources table { font-size: 11px; }
.tabela-resources th { position: sticky; top: 0; z-index: 2; background: #0e1723; }
.tabela-resources th:last-child, .tabela-resources td:last-child { text-align: right; }
.resource-state {
  display: inline-flex; align-items: center; gap: 7px; min-width: 88px;
  color: #8497ad; font-size: 9px; font-weight: 650;
}
.resource-state i { width: 6px; height: 6px; border-radius: 50%; background: #65758a; }
.state-started { color: #70dca2; }
.state-started i { background: var(--green); box-shadow: 0 0 7px rgba(53,208,127,.5); }
.state-stopped, .state-missing { color: #ff8991; }
.state-stopped i, .state-missing i { background: var(--red); }
.state-starting, .state-stopping { color: #e1b565; }
.state-starting i, .state-stopping i { background: var(--amber); }
.resource-actions { display: flex; justify-content: flex-end; gap: 6px; }
.btn-resource {
  min-width: 62px; padding: 6px 9px; border: 1px solid #2a3b51; border-radius: 6px;
  color: #a9b8ca; background: #121d2b; cursor: pointer; font-size: 9px; font-weight: 700;
}
.btn-resource.primary { color: #8db9ff; border-color: rgba(66,133,255,.35); background: rgba(66,133,255,.09); }
.btn-resource.danger { color: #ff8f96; border-color: rgba(255,93,104,.25); background: rgba(255,93,104,.06); }
.btn-resource:disabled { opacity: .55; cursor: wait; transform: none; }
.btn-protect-resource {
  min-width: 68px; padding: 6px 9px; border: 1px solid rgba(53,208,127,.32);
  border-radius: 6px; color: #7fe0aa; background: rgba(53,208,127,.08);
  cursor: pointer; font-size: 9px; font-weight: 750;
}
.btn-protect-resource:hover { border-color: rgba(53,208,127,.58); background: rgba(53,208,127,.15); }
.btn-protect-resource:disabled { opacity: .55; cursor: wait; transform: none; }
.btn-unprotect-resource {
  min-width: 105px; padding: 6px 9px; border: 1px solid rgba(255,93,104,.3);
  border-radius: 6px; color: #ff969d; background: rgba(255,93,104,.07);
  cursor: pointer; font-size: 9px; font-weight: 750;
}
.btn-unprotect-resource:disabled { opacity: .55; cursor: wait; }
.core-tag {
  display: inline-block; margin-left: 7px; padding: 2px 5px; border-radius: 4px;
  color: #8db9ff; background: rgba(66,133,255,.1); font-size: 7px; letter-spacing: .08em;
}
.protected-tag {
  display: inline-block; margin-left: 7px; padding: 2px 5px; border-radius: 4px;
  color: #79dfa8; background: rgba(53,208,127,.09); font-size: 7px; letter-spacing: .08em;
}
.fxap-tag {
  display: inline-block; margin-left: 7px; padding: 2px 5px; border-radius: 4px;
  color: #c6a25f; background: rgba(246,184,74,.09); font-size: 7px; letter-spacing: .08em;
}
.control-off { color: #60738a; font-size: 8px; }
.aviso-controle {
  margin: 12px 14px; padding: 10px 12px; border: 1px solid rgba(246,184,74,.18);
  border-radius: 8px; color: #c6a25f; background: rgba(246,184,74,.05); font-size: 9px;
}

/* Tabela */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 10px; }
th, td { padding: 12px 15px; text-align: left; border-bottom: 1px solid rgba(129,157,190,.08); }
th { color: #5e7188; font-size: 8px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
td { color: #9eafc1; }
td b { color: #e1e9f3; font-weight: 650; }
tbody tr:hover { background: rgba(66,133,255,.035); }
.vazio { width: 100%; color: #61738a; text-align: center; padding: 28px; font-size: 10px; }

/* Alertas */
.aviso-canary {
  margin: 12px 12px 0; padding: 10px 11px; border-radius: 8px;
  border: 1px solid rgba(246,184,74,.16); color: #ba9a5c;
  background: rgba(246,184,74,.045); font-size: 9px; line-height: 1.5;
}
.aviso-canary strong { color: #d8b66f; }
.feed { flex: 1; min-height: 0; max-height: none; overflow-y: auto; padding: 12px; }
.canary-item {
  margin-bottom: 8px; padding: 11px 12px;
  border: 1px solid rgba(255,93,104,.14); border-left: 2px solid var(--red); border-radius: 8px;
  background: rgba(255,93,104,.045); animation: slideIn .25s ease;
}
.canary-item.novo { box-shadow: 0 0 0 2px rgba(255,93,104,.13); }
.canary-item.dump-time { box-shadow: 0 0 0 2px rgba(255,140,0,.22); }
.canary-item.dump-time .canary-motivo { color: #ffb347; }
.canary-top { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.canary-top-actions { display: flex; align-items: center; gap: 8px; }
.canary-motivo { color: #ff939a; font-size: 10px; font-weight: 750; }
.canary-time { color: #5d7087; font-size: 8px; white-space: nowrap; }
.btn-remove-event {
  padding: 3px 6px; border: 1px solid rgba(255,93,104,.2); border-radius: 5px;
  color: #d87b82; background: rgba(255,93,104,.05); cursor: pointer;
  font-size: 7px; font-weight: 700;
}
.btn-remove-event:hover { color: #fff; border-color: rgba(255,93,104,.45); }
.btn-remove-event:disabled { opacity: .5; cursor: wait; }
.canary-grid { display: grid; grid-template-columns: auto 1fr auto 1fr; gap: 4px 9px; font-size: 8px; }
.canary-grid span { color: #5f7187; }
.canary-grid b { overflow: hidden; color: #aab9ca; font-family: var(--mono); font-weight: 500; text-overflow: ellipsis; }
@keyframes slideIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }

/* Registros */
.log-view {
  flex: 1; min-height: 0; max-height: none; overflow-y: auto; padding: 13px 17px;
  background: rgba(3, 8, 14, .45); font: 9px/1.75 var(--mono);
}
#registros, #console-txadmin {
  flex: 1; min-height: 0; margin-bottom: 12px;
  display: flex; flex-direction: column;
}
#protecao > .table-wrap { flex: 1; min-height: 0; overflow: auto; }
.log-line { white-space: pre-wrap; word-break: break-word; }
.log-info { color: #6aa4f7; }
.log-ok { color: #68d99b; }
.log-aviso { color: #e0af5d; }
.log-erro { color: #ff7d86; }
.log-titulo { color: #ad96ff; font-weight: 700; }
.log-time { color: #465a72; margin-right: 6px; }
.console-tools { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.console-note {
  padding: 8px 17px; border-bottom: 1px solid var(--border-soft);
  color: #5f7288; background: rgba(33,197,217,.025); font-size: 9px;
}
.tx-console {
  flex: 1; height: auto; min-height: 0; overflow: auto; padding: 14px 17px;
  color: #9fb1c5; background: #04080d; font: 10px/1.65 var(--mono);
}
.tx-console-line { display: flex; gap: 10px; white-space: pre-wrap; word-break: break-word; }
.tx-console-line::before { content: "›"; flex: 0 0 auto; color: #344b63; }
.tx-console-line.console-error { color: #ff818a; }
.tx-console-line.console-warning { color: #e1b565; }
.tx-console-line.console-success { color: #68d99b; }
.tx-console-line.console-script { color: #72a9f4; }
.console-empty { display: grid; place-items: center; height: 100%; color: #52657b; }
.console-command {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 9px;
  padding: 10px 14px; border-top: 1px solid var(--border-soft); background: #071019;
  color: var(--cyan); font: 12px var(--mono);
}
.console-command input {
  min-width: 0; padding: 10px 12px; border: 1px solid #26394e; border-radius: 6px;
  outline: none; color: #c8d7e8; background: #04080d; font: 11px var(--mono);
}
.console-command input:focus { border-color: var(--cyan); box-shadow: 0 0 0 2px rgba(33,197,217,.1); }
.console-command button {
  padding: 10px 15px; border: 1px solid rgba(33,197,217,.35); border-radius: 6px;
  color: #bff8ff; background: rgba(33,197,217,.12); cursor: pointer; font-weight: 700;
}
.console-command button:hover { background: rgba(33,197,217,.2); }
.console-command button:disabled { cursor: wait; opacity: .55; }
footer {
  flex: 0 0 auto; display: flex; justify-content: space-between;
  color: #46576c; padding: 5px 3px 0; font-size: 9px;
}

/* Barras de rolagem */
* { scrollbar-width: thin; scrollbar-color: #2a3b51 transparent; }
::-webkit-scrollbar { width: 7px; height: 7px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #29394d; border-radius: 999px; }

@media (max-width: 1250px) {
  .cards { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 960px) {
  .app-shell { display: flex; flex-direction: column; }
  .sidebar {
    position: static; flex: 0 0 64px; width: 100%; min-height: 64px;
    padding: 12px 18px; flex-direction: row; align-items: center; gap: 14px;
  }
  .side-brand { padding: 0 14px 0 0; border: 0; border-right: 1px solid var(--border-soft); }
  .side-logo { width: 145px; }
  .side-nav { flex: 1; padding: 0; flex-direction: row; overflow-x: auto; }
  .side-nav a { white-space: nowrap; padding: 9px; }
  .side-status, .btn-logout { display: none; }
  .workspace { width: 100%; height: calc(100vh - 64px); }
  .grid { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .topbar { padding: 13px 18px; }
  .topbar-meta > div:first-child { display: none; }
  .container { padding: 20px 15px 30px; }
  .welcome { align-items: flex-start; gap: 15px; }
  .welcome h2 { font-size: 20px; }
  .system-ok { display: none; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .panel-head { align-items: flex-start; flex-direction: column; }
  .busca-recursos { width: 100%; max-width: none; }
  .console-tools { width: 100%; }
  .console-tools .busca-recursos { flex: 1; }
  .console-command { grid-template-columns: auto 1fr; }
  .console-command button { grid-column: 2; }
  .jogadores-layout { grid-template-columns: 1fr; }
  .jogador-detalhe { border-left: 0; border-top: 1px solid var(--border-soft); max-height: 280px; }
  .canary-grid { grid-template-columns: auto 1fr; }
  footer { gap: 8px; flex-direction: column; }
}
