:root { --bakter: #1f3a5f; }

.auth-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, #132639 0%, #1f3a5f 100%);
}
.auth-wrap { width: 100%; max-width: 430px; margin: 2rem auto; padding: 1rem; }
.auth-card { border: none; border-radius: 1rem; box-shadow: 0 10px 40px rgba(0,0,0,.35); }
.auth-card .card-body { padding: 2rem; }
.auth-logo { font-size: 2.75rem; color: var(--bakter); line-height: 1; }

.app-body { background: #f3f5f8; }

/* Áttekintő csempék */
.stat-card { border: none; border-left: .35rem solid var(--bs-secondary); }
.stat-card .stat-value { font-size: 1.9rem; font-weight: 700; line-height: 1.1; }
.stat-card .stat-label { font-size: .8rem; text-transform: uppercase; letter-spacing: .03em; }
/* MINDIG legyen ott, hogy a szám mihez képest értendő */
.stat-card .stat-scope { font-size: .78rem; color: var(--bs-secondary-color); }

/* Súlyosság: szín + szöveg együtt (nem csak szín) */
.sev { font-weight: 600; }
.sev-info     { --sev-bg:#6c757d; }
.sev-low      { --sev-bg:#0dcaf0; }
.sev-medium   { --sev-bg:#ffc107; }
.sev-high     { --sev-bg:#dc3545; }
.sev-critical { --sev-bg:#212529; }
.sev-bar { display:inline-block; width:.5rem; height:1.1rem; border-radius:.15rem; background:var(--sev-bg); vertical-align:-.2rem; }

.table-compact td, .table-compact th { vertical-align: middle; font-size: .9rem; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.ip-link { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; text-decoration: none; }

/* Nyers log-sor: TÁMADÓTÓL származó szöveg – csak <pre>-ben, escape-elve */
.raw-line {
  background: #10151c; color: #d7e2ee; border-radius: .5rem;
  padding: .75rem; font-size: .82rem; white-space: pre-wrap;
  word-break: break-all; max-height: 22rem; overflow: auto; margin: 0;
}
.uri-cell { max-width: 26rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uri-cell:hover { white-space: normal; word-break: break-all; }

.totp-secret {
  font-family: monospace; font-size: .95rem; letter-spacing: 1px;
  background: #f1f3f5; padding: .4rem .6rem; border-radius: .4rem;
  display: inline-block; max-width: 100%; word-break: break-all; white-space: normal; line-height: 1.5;
}
#qrcode { display: inline-block; padding: .5rem; background: #fff; border-radius: .5rem; }
.code-input { letter-spacing: .5rem; font-size: 1.5rem; text-align: center; font-weight: 600; }

.modal-dialog-scrollable .modal-body { max-height: calc(100vh - 12rem); overflow-y: auto; }
.sortable { cursor: pointer; user-select: none; }

/* Mobil: a széles táblák görgethetők maradjanak */
@media (max-width: 767.98px) {
  .stat-card .stat-value { font-size: 1.5rem; }
  .uri-cell { max-width: 12rem; }
}

/* ---------- Élő folyam (live.php) ---------- */
/* Új sor finom bevillanása – hangjelzés SZÁNDÉKOSAN nincs. */
@keyframes flashIn {
  0%   { background-color: rgba(13,110,253,.28); }
  100% { background-color: transparent; }
}
.live-table tr.flash-in { animation: flashIn 1.4s ease-out 1; }

/* A tiltás a legfontosabb esemény: külön háttér + vastagabb bal szegély */
.live-table tr.block-row {
  background-color: rgba(220,53,69,.10);
  box-shadow: inset .35rem 0 0 var(--bs-danger);
}
.live-table tr.block-row:hover { background-color: rgba(220,53,69,.16); }
@keyframes flashBan {
  0%   { background-color: rgba(220,53,69,.55); }
  100% { background-color: rgba(220,53,69,.10); }
}
.live-table tr.block-row.flash-in { animation: flashBan 1.8s ease-out 1; }

/* Súlyosság jelzése a sor bal szélén (szín + a badge szövege együtt) */
.live-table tr.sev-row-critical { box-shadow: inset .25rem 0 0 #212529; }
.live-table tr.sev-row-high     { box-shadow: inset .25rem 0 0 #dc3545; }
.live-table tr.sev-row-medium   { box-shadow: inset .25rem 0 0 #ffc107; }
.live-table tr.sev-row-low      { box-shadow: inset .25rem 0 0 #0dcaf0; }
.live-table tr.sev-row-info     { box-shadow: inset .25rem 0 0 #6c757d; }

/* Állapotjelző pötty */
.live-dot { display:inline-block; width:.6rem; height:.6rem; border-radius:50%; background:#adb5bd; }
.live-dot.dot-live   { background:#198754; animation: pulse 2s infinite; }
.live-dot.dot-paused { background:#ffc107; }
.live-dot.dot-idle   { background:#6c757d; }
.live-dot.dot-error  { background:#dc3545; animation: pulse 1s infinite; }
@keyframes pulse { 0%,100% { opacity:1; } 50% { opacity:.35; } }

/* Mozgáscsökkentést kérő felhasználóknál ne villogjon semmi */
@media (prefers-reduced-motion: reduce) {
  .live-table tr.flash-in { animation: none; }
  .live-dot.dot-live, .live-dot.dot-error { animation: none; }
}
