/* =============================================================
   SURVIVAL SHIELD // THREAT CENTER — Tactical HUD Terminal
   Apenas tema visual; compatível com vars legadas (--neon, --txt-*, ...)
   ============================================================= */

/* Fontes carregadas uma única vez via <link> no base.twig (Plus Jakarta Sans + JetBrains Mono).
   @import removido para não baixar as famílias duas vezes e não bloquear o render. */

:root {
  /* DESIGN SYSTEM — Tokens (Sleek, Friendly Redesign) */
  --color-bg-primary: #050806;
  --color-bg-panel: rgba(10, 18, 14, 0.72);
  --color-bg-panel-elevated: rgba(16, 28, 22, 0.85);
  --color-bg-accent: rgba(22, 38, 30, 0.9);
  --color-grid-line: rgba(0, 242, 116, 0.06);

  --color-text-white: #ffffff;
  --color-text-primary: #ffffff;
  --color-text-muted: #ffffff; /* REGRA: texto cinza vira branco (hierarquia por tamanho/peso) */
  --color-text-hud: #00f274;

  --color-border: rgba(0, 242, 116, 0.15);
  --color-border-solid: rgba(0, 242, 116, 0.28);

  --color-tactical: #00f274;
  --color-tactical-dim: #00c75e;
  --color-warn: #f5a524;
  --color-alert: #ff4646;
  --color-safe: #00f274;

  --badge-low-bg: rgba(0, 242, 116, 0.08);
  --badge-low-text: #00f274;
  --badge-low-border: rgba(0, 242, 116, 0.3);

  --badge-elevated-bg: rgba(245, 165, 36, 0.08);
  --badge-elevated-text: #f5a524;
  --badge-elevated-border: rgba(245, 165, 36, 0.3);

  --badge-critical-bg: rgba(255, 70, 70, 0.08);
  --badge-critical-text: #ff4646;
  --badge-critical-border: rgba(255, 70, 70, 0.3);

  --font-sans: "Plus Jakarta Sans", system-ui, sans-serif;
  --font-mono: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Plus Jakarta Sans", system-ui, sans-serif;

  /* Altura combinada linha status + ticker (layout em coluna CSS) */
  --tac-topbar-stack-h: 52px;

  /* Retrocompatível (templates + chaos_map inline) */
  --bg-0: var(--color-bg-primary);
  --bg-1: var(--color-bg-primary);
  --bg-2: var(--color-bg-panel);
  --bg-3: var(--color-bg-panel-elevated);
  --line: color-mix(in srgb, var(--color-border) 55%, transparent);
  --line-2: var(--color-border-solid);
  --neon: var(--color-tactical);
  --neon-dim: var(--color-tactical-dim);
  --neon-glow: rgba(0, 242, 116, 0.35);
  --red: var(--color-alert);
  --red-glow: rgba(255, 70, 70, 0.4);
  --orange: var(--color-warn);
  --yellow: #ffbd33;
  --ice: #6cd0ff;
  --txt-0: var(--color-text-primary);
  --txt-1: var(--color-text-white);
  --txt-2: var(--color-text-white);
  --txt-muted: var(--color-text-muted);
  --font-ui: var(--font-sans);
}

/* ---------- Utilidades tema ---------- */
.text-glow {
  text-shadow: 0 0 6px color-mix(in srgb, currentColor 30%, transparent);
}

.text-glow-sm {
  text-shadow: 0 0 4px currentColor;
}

.border-glow {
  box-shadow:
    0 0 0 1px var(--color-tactical),
    0 0 12px rgba(52, 209, 127, 0.4);
}

@keyframes tac-blink-dot {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
    animation-timing-function: step-end;
  }
}

@keyframes tac-pulse-alert {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.4;
  }
}

@keyframes tac-caret-blink {
  50% {
    opacity: 0;
  }
}

/* ---------- Reset + Body (camadas) ---------- */
* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
}

body {
  background-color: var(--color-bg-primary);
  background-image:
    
    radial-gradient(1100px 560px at 50% -12%, rgba(52,209,127,.06), transparent 60%);
  background-size: auto;
  background-attachment: fixed;
  color: var(--color-text-primary);
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.5;
  overflow-x: hidden;
}

/* Vinheta */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 0%, rgba(0, 0, 0, 0.4) 100%);
}

/* CRT scanlines — disabled (de-militarised) */
body::after {
  content: none;
}

/* ---------- TOPBAR / STATUS + TICKER (.scroll-alert = segunda linha; ações ficam sobre a primeira) ---------- */
.tac-topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: block;
  min-height: var(--tac-topbar-stack-h);
  padding: 0;
  background: rgba(13, 19, 14, 0.8);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--color-border);
  font-family: var(--font-mono);
  color: var(--color-text-hud);
}

/* Heading (título + ?) só no mobile; desktop usa sidebar / título na página */
.tac-topbar-heading {
  display: none;
}

@media (min-width: 768px) {
  .tac-topbar-actions {
    position: absolute;
    top: 6px;
    right: 12px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-left: 0 !important;
  }
}

.tac-topbar-desktop {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 14px;
  padding: 6px 56px 0 16px;
  min-height: 28px;
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.tac-topbar .tag {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  color: var(--color-text-hud);
}

.tac-topbar .tag .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow:
    0 0 6px rgba(52, 209, 127, 0.8),
    0 0 10px rgba(52, 209, 127, 0.4);
  animation: tac-blink-dot 1s infinite;
}

.tac-topbar .divider {
  color: var(--color-tactical-dim);
}

.tac-topbar .scroll-alert {
  flex: 1 1 100%;
  width: 100%;
  margin: 0;
  padding: 5px 16px 7px;
  min-height: 18px;
  overflow: hidden;
  white-space: nowrap;
  font-size: 10px;
  font-weight: 400;
  text-transform: uppercase;
  color: rgb(245 165 36 / 0.9);
  background: rgb(12 19 16 / 0.6);
  border-top: 1px solid rgb(38 53 45 / 0.45);
  box-sizing: border-box;
}

.tac-topbar .scroll-alert span {
  display: inline-block;
  padding-left: 100%;
  animation: scroll-alert-marquee 120s linear infinite;
}

@keyframes scroll-alert-marquee {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(-100%);
  }
}

.tac-topbar-actions {
  display: inline-flex;
  gap: 8px;
  align-items: center;
}

@media (max-width: 900px) and (min-width: 768px) {
  .tac-topbar-desktop {
    padding-right: 56px;
  }
}

/* ---------- Shell + main ---------- */
.tac-shell {
  display: flex;
  min-height: calc(100vh - var(--tac-topbar-stack-h));
  position: relative;
  z-index: 3;
  max-width: 100vw;
}

.tac-main {
  flex: 1;
  padding: clamp(16px, 3vw, 28px);
  padding-bottom: 88px;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.tac-page-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 3vw, 34px);
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.1;
  text-transform: none;
  color: var(--color-text-primary);
  margin: 0 0 6px;
}

.tac-page-title--inline-ico {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45em;
}

.tac-page-title--inline-ico .tac-page-title-ico {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  color: inherit;
}

.tac-page-title--inline-ico .tac-svg-ico svg {
  width: 1em;
  height: 1em;
  display: block;
  stroke: currentColor;
  filter: drop-shadow(0 0 10px rgba(52, 209, 127, 0.35));
}

.home-module-inline-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
}

.home-module-inline-ico .tac-svg-ico svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
}

.home-premium-inline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.tac-page-sub {
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 400;
  color: var(--color-text-muted);
  letter-spacing: 0;
  margin-bottom: 22px;
  line-height: 1.5;
}

/* ---------- Sidebar ---------- */
.tac-sidebar {
  width: 240px;
  flex-shrink: 0;
  position: sticky;
  align-self: flex-start;
  top: var(--tac-topbar-stack-h);
  height: calc(100vh - var(--tac-topbar-stack-h));
  overflow-x: hidden;
  overflow-y: auto;
  padding: 16px 12px 12px;
  background: rgba(13, 19, 14, 0.95);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-right: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
}

/* Barra de rolagem alinhada ao HUD (Firefox + WebKit) */
.tac-sidebar,
.tac-sidebar .tac-nav {
  scrollbar-width: thin;
  scrollbar-color: color-mix(in srgb, var(--color-tactical) 52%, #1a221a) rgba(0, 0, 0, 0.5);
}

.tac-sidebar::-webkit-scrollbar,
.tac-sidebar .tac-nav::-webkit-scrollbar {
  width: 7px;
}

.tac-sidebar::-webkit-scrollbar-track,
.tac-sidebar .tac-nav::-webkit-scrollbar-track {
  background: rgba(5, 10, 6, 0.75);
  border-left: 1px solid color-mix(in srgb, var(--color-border) 75%, transparent);
}

.tac-sidebar::-webkit-scrollbar-thumb,
.tac-sidebar .tac-nav::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg,
      color-mix(in srgb, var(--color-tactical) 42%, #0f150f),
      color-mix(in srgb, var(--color-tactical-dim) 75%, #080c08));
  border-radius: 10px;
  border: 1px solid rgba(52, 209, 127, 0.2);
  box-shadow: inset 0 0 5px rgba(52, 209, 127, 0.1);
}

.tac-sidebar::-webkit-scrollbar-thumb:hover,
.tac-sidebar .tac-nav::-webkit-scrollbar-thumb:hover {
  background: color-mix(in srgb, var(--color-tactical) 55%, #101810);
  box-shadow: 0 0 8px rgba(52, 209, 127, 0.22);
}

.tac-sidebar::-webkit-scrollbar-corner,
.tac-sidebar .tac-nav::-webkit-scrollbar-corner {
  background: rgba(5, 10, 6, 0.75);
}

.tac-logo {
  padding: 16px 12px 20px;
  border-bottom: 1px solid color-mix(in srgb, var(--color-border) 60%, transparent);
  margin-bottom: 8px;
  font-family: var(--font-display);
}

.tac-logo-row {
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-text-hud);
  text-shadow: 0 0 10px rgba(52, 209, 127, 0.35);
}

.tac-logo-shield {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--color-text-hud);
  filter: drop-shadow(0 0 8px rgba(52, 209, 127, 0.55));
}

.tac-logo-shield .tac-svg-ico svg {
  width: 22px;
  height: 22px;
}

.tac-logo-text {
  font-size: 18px;
  font-weight: 400;
  line-height: 1.2;
}

.tac-logo .version {
  display: block;
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
}

.tac-nav {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}

.tac-nav-idx {
  flex: 0 0 1.5rem;
  width: 1.5rem;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: color-mix(in srgb, var(--color-text-muted) 90%, transparent);
}

.tac-svg-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.tac-svg-ico svg {
  width: 16px;
  height: 16px;
  display: block;
}

.tac-nav a:hover .tac-nav-idx,
.tac-nav a.active .tac-nav-idx {
  color: color-mix(in srgb, currentColor 70%, var(--color-text-muted));
}

.tac-nav a .txt {
  flex: 1 1 auto;
  min-width: 0;
}

.tac-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 10px;
  margin-bottom: 2px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  color: color-mix(in srgb, var(--color-text-muted) 92%, var(--color-text-hud));
  border: 1px solid transparent;
  border-left: 2px solid transparent;
  border-radius: 12px;
  transition: all 0.15s ease;
}

.tac-nav a:hover {
  color: #f2fff2;
}

.tac-nav a:hover .tac-svg-ico svg {
  stroke: #f2fff2;
}

.tac-nav a.active .tac-svg-ico svg {
  stroke: var(--color-tactical);
  filter: drop-shadow(0 0 6px rgba(52, 209, 127, 0.45));
}

.tac-nav a.active::after {
  content: "";
  width: 12px;
  height: 12px;
  min-width: 12px;
  flex-shrink: 0;
  margin-left: auto;
  border-radius: 50%;
  background: var(--color-tactical);
  box-shadow: 0 0 12px var(--color-tactical);
  animation: tac-blink-dot 1.2s ease-in-out infinite;
}

/* Locked — discreet “curiosity” cue (premium / plan) without yelling */
.tac-nav a.locked {
  opacity: 0.78;
  color: color-mix(in srgb, var(--color-tactical) 38%, var(--color-text-muted));
  border-radius: 10px;
  border-color: rgba(52, 209, 127, 0.12);
  border-left-width: 2px;
  border-left-color: color-mix(in srgb, #fbbf24 45%, transparent);
  background:
    linear-gradient(102deg,
      rgba(251, 191, 36, 0.065) 0%,
      rgba(52, 209, 127, 0.045) 44%,
      transparent 74%);
  box-shadow: inset 0 0 0 1px rgba(52, 209, 127, 0.06);
}

.tac-nav a.locked:hover {
  opacity: 0.94;
  color: color-mix(in srgb, var(--color-tactical) 48%, #e8fde8);
  border-left-color: color-mix(in srgb, #fcd34d 58%, transparent);
  background:
    linear-gradient(102deg,
      rgba(251, 191, 36, 0.115) 0%,
      rgba(52, 209, 127, 0.07) 48%,
      transparent 82%);
  box-shadow: inset 0 0 14px rgba(52, 209, 127, 0.09);
}

.tac-nav a.locked:not(:hover):not(.active) {
  animation: tac-nav-locked-breathe 10s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .tac-nav a.locked:not(:hover):not(.active) {
    animation: none;
  }
}

@keyframes tac-nav-locked-breathe {

  0%,
  100% {
    border-left-color: color-mix(in srgb, #eab308 40%, transparent);
    box-shadow: inset 0 0 0 1px rgba(52, 209, 127, 0.06);
  }

  50% {
    border-left-color: color-mix(in srgb, #fcd34d 52%, transparent);
    box-shadow:
      inset 0 0 0 1px rgba(52, 209, 127, 0.09),
      0 0 12px rgba(251, 191, 36, 0.08);
  }
}

.tac-nav a.locked::after {
  content: "🔒";
  margin-left: auto;
  font-size: 10px;
  opacity: 0.88;
  animation: none;
  box-shadow: none;
  border-radius: 12px;
  width: auto;
  height: auto;
  background: none;
}

.tac-nav a[href*="admin"]:not([href*="profile"]) {
  color: color-mix(in srgb, var(--color-alert) 85%, var(--color-text-muted));
  border-left-color: transparent;
}

.tac-nav a[href*="admin"]:not([href*="profile"]):hover {
  border-left-color: var(--color-alert);
  color: var(--color-alert);
}

.tac-nav .sep {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.22em;
  color: color-mix(in srgb, var(--color-text-muted) 88%, transparent);
  padding: 18px 12px 8px;
  text-transform: uppercase;
}

.tac-nav .sep::before {
  content: "▸ ";
}

.tac-sidebar-footer {
  margin-top: auto;
  padding: 12px;
  border-top: 1px solid color-mix(in srgb, var(--color-border) 55%, transparent);
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
}

.tac-sidebar-footer b {
  color: var(--color-text-hud);
  font-weight: 600;
}

/* ---------- Cards / painéis ---------- */
.tac-card {
  background: var(--color-bg-panel);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  padding: 20px;
  position: relative;
  overflow: visible;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.tac-card:hover {
  border-color: rgba(0, 242, 116, 0.35);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 15px rgba(0, 242, 116, 0.08);
}

.tac-card::before,
.tac-card::after {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  border: 2px solid var(--color-tactical);
  pointer-events: none;
  z-index: 1;
}

.tac-card::before {
  top: -1px;
  left: -1px;
  border-right: none;
  border-bottom: none;
}

.tac-card::after {
  bottom: -1px;
  right: -1px;
  border-left: none;
  border-top: none;
}

.tac-card.red::before,
.tac-card.red::after {
  border-color: var(--color-alert);
}

.tac-card.orange::before,
.tac-card.orange::after {
  border-color: var(--color-warn);
}

.tac-card-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.2em;
  line-height: 1.25;
  text-transform: uppercase;
  color: var(--color-text-hud);
  margin: 0 0 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid color-mix(in srgb, var(--color-border) 55%, transparent);
  display: flex;
  align-items: center;
  gap: 8px;
}

.tac-card-title .marker {
  width: 4px;
  height: 14px;
  background: var(--color-tactical);
  box-shadow: 0 0 8px rgba(52, 209, 127, 0.5);
}

.tac-card.red .tac-card-title {
  color: var(--color-alert);
}

.tac-card.red .tac-card-title .marker {
  background: var(--color-alert);
  box-shadow: 0 0 8px rgba(240, 89, 79, 0.45);
}

.tac-card.orange .tac-card-title {
  color: var(--color-warn);
}

.tac-card.orange .tac-card-title .marker {
  background: var(--color-warn);
}

@media (max-width: 639px) {
  .tac-card {
    padding: 12px;
  }
}

/* ---------- Grid KPIs ---------- */
.tac-grid {
  display: grid;
  gap: 16px;
}

.tac-grid.cols-4 {
  grid-template-columns: repeat(4, 1fr);
}

.tac-grid.cols-3 {
  grid-template-columns: repeat(3, 1fr);
}

.tac-grid.cols-2 {
  grid-template-columns: repeat(2, 1fr);
}

@media (max-width: 1100px) {
  .tac-grid.cols-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .tac-grid.cols-3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {

  .tac-grid.cols-4,
  .tac-grid.cols-3,
  .tac-grid.cols-2 {
    grid-template-columns: 1fr;
  }

  .tac-sidebar {
    width: 72px;
    padding: 10px 6px;
  }

  .tac-sidebar .tac-logo .version,
  .tac-sidebar .tac-nav a span.txt,
  .tac-sidebar .tac-nav-idx,
  .tac-sidebar .sep {
    display: none;
  }
}

/* ---------- Gauge ---------- */
.tac-gauge {
  position: relative;
  width: 176px;
  height: 176px;
  margin: 0 auto;
}

.tac-gauge svg {
  transform: rotate(-90deg);
}

.tac-gauge svg circle:first-of-type {
  stroke: #1b2a22;
}

.tac-card.red .tac-gauge svg circle:nth-of-type(2) {
  stroke: var(--color-alert);
  filter: drop-shadow(0 0 6px rgba(240, 89, 79, 0.55));
}

.tac-gauge svg circle:nth-of-type(2) {
  stroke: var(--color-warn);
  filter: drop-shadow(0 0 6px rgba(245, 165, 36, 0.45));
}

.tac-gauge .val {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.tac-gauge .val .num {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 400;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
  color: var(--color-alert);
  text-shadow:
    0 0 8px color-mix(in srgb, var(--color-alert) 65%, transparent),
    0 0 16px color-mix(in srgb, var(--color-alert) 35%, transparent);
}

.tac-gauge .val .pct {
  font-family: var(--font-display);
  font-size: 28px;
  color: inherit;
}

.tac-gauge .val .lbl {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.16em;
  margin-top: 8px;
  color: var(--color-text-muted);
  text-transform: uppercase;
}

/* ---------- Tabela ---------- */
.tac-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.05em;
}

.tac-table th {
  text-align: left;
  font-weight: 600;
  color: var(--color-text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 6px 10px;
  border-bottom: 1px solid color-mix(in srgb, var(--color-border) 50%, transparent);
  font-size: 10px;
}

.tac-table td {
  padding: 10px;
  border-bottom: 1px solid color-mix(in srgb, var(--color-border) 45%, transparent);
  color: var(--color-text-primary);
}

.tac-table tr:last-child td {
  border-bottom: none;
}

.tac-table tr:hover td {
  background: rgba(52, 209, 127, 0.04);
}

/* ---------- Barras ---------- */
.tac-bar {
  height: 6px;
  border-radius: 12px;
  background: var(--color-bg-primary);
  border: 1px solid color-mix(in srgb, var(--color-border) 55%, transparent);
  overflow: hidden;
  position: relative;
}

.tac-bar>span {
  display: block;
  height: 100%;
  background: var(--color-tactical);
  box-shadow: 0 0 8px currentColor;
}

.tac-bar.red>span {
  background: var(--color-alert);
  box-shadow: 0 0 8px var(--color-alert);
}

.tac-bar.orange>span {
  background: var(--color-warn);
  box-shadow: 0 0 8px var(--color-warn);
}

.tac-bar.yellow>span {
  background: #ffbd33;
  box-shadow: 0 0 8px rgba(255, 189, 51, 0.6);
}

/* ---------- Badges ---------- */
.tac-badge {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  border: 2px solid var(--badge-low-border);
  border-radius: 12px;
  background: var(--badge-low-bg);
  color: var(--badge-low-text);
  box-shadow: 0 0 6px rgba(52, 209, 127, 0.3);
}

.tac-badge.red {
  border-color: var(--badge-critical-border);
  color: var(--badge-critical-text);
  background: var(--badge-critical-bg);
  animation: tac-pulse-alert 1.2s ease-in-out infinite;
  box-shadow: 0 0 8px rgba(240, 89, 79, 0.35);
}

.tac-badge.orange {
  border-color: var(--badge-elevated-border);
  color: var(--badge-elevated-text);
  background: var(--badge-elevated-bg);
  box-shadow: 0 0 8px rgba(245, 165, 36, 0.35);
}

.tac-badge.yellow {
  border-color: #ffbd33;
  color: #ffbd33;
  background: rgba(255, 189, 51, 0.15);
}

.tac-badge.green {
  border-color: var(--badge-low-border);
  color: var(--badge-low-text);
  background: var(--badge-low-bg);
}

/* ---------- Terminal feed ---------- */
.tac-terminal {
  background: var(--color-bg-primary);
  border: 1px solid var(--color-border);
  padding: 12px;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.45;
  max-height: 18rem;
  overflow-y: auto;
}

.tac-terminal .line {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  align-items: baseline;
  margin-bottom: 8px;
  padding-left: 12px;
  border-left: 2px solid var(--color-border);
  color: color-mix(in srgb, var(--color-text-primary) 88%, transparent);
  transition: border-color 0.15s;
}

.tac-terminal .line:hover {
  border-left-color: var(--color-tactical-dim);
}

.tac-terminal .line .ts {
  color: var(--color-text-muted);
  margin-right: 6px;
  font-size: 11px;
}

.tac-terminal .line .prompt {
  color: var(--color-warn);
  margin-right: 4px;
}

/* ---------- Inputs / botões (Tactical) ---------- */
.tac-input,
textarea.tac-input {
  width: 100%;
  background: var(--color-bg-primary);
  border: 1px solid var(--color-border);
  color: var(--color-text-primary);
  padding: 10px 12px;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 400;
  border-radius: 12px;
  outline: none;
  transition: all 0.15s;
}

.tac-input:focus {
  border-color: var(--color-tactical);
  box-shadow: 0 0 0 1px rgba(52, 209, 127, 0.25);
}

.tac-input::placeholder {
  color: rgba(255, 255, 255, 0.7);
  opacity: 1;
}

.tac-btn {
  min-height: 44px;
  padding: 12px 16px;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.2em;
  line-height: 1.375;
  text-transform: uppercase;
  cursor: pointer;
  border: 2px solid var(--color-tactical);
  border-radius: 12px;
  background: rgba(52, 209, 127, 0.1);
  color: var(--color-tactical);
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px));
  transition: all 0.15s;
}

.tac-btn:hover {
  background: var(--color-tactical);
  color: var(--color-bg-primary);
  box-shadow:
    0 0 12px rgba(52, 209, 127, 0.55),
    0 0 24px rgba(52, 209, 127, 0.25);
}

.tac-btn.red {
  border-color: var(--color-alert);
  color: var(--color-alert);
  background: rgba(240, 89, 79, 0.1);
}

.tac-btn.red:hover {
  background: var(--color-alert);
  color: #120203;
  box-shadow: 0 0 14px rgba(240, 89, 79, 0.45);
}

.tac-btn.ghost {
  border-color: var(--color-border);
  color: var(--color-text-muted);
  background: transparent;
}

.tac-btn.ghost:hover {
  border-color: var(--color-tactical-dim);
  color: var(--color-text-primary);
}

/* ---------- Login ---------- */
.tac-login-wrap {
  min-height: calc(100vh - var(--tac-topbar-stack-h));
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 20px;
}

.tac-login {
  width: 100%;
  max-width: 420px;
  border: 1px solid var(--color-border);
  background: var(--color-bg-panel);
  padding: 34px 32px;
  border-radius: 12px;
  position: relative;
}

.tac-login h1 {
  font-family: var(--font-display);
  color: var(--color-text-hud);
  font-size: clamp(22px, 3vw, 28px);
  letter-spacing: 0.2em;
  margin: 0 0 6px;
  text-shadow: 0 0 12px rgba(52, 209, 127, 0.35);
}

.tac-login .sub {
  font-family: var(--font-mono);
  color: var(--color-text-white);
  font-size: 10px;
  letter-spacing: 0.2em;
  margin-bottom: 26px;
  text-transform: uppercase;
}

.tac-login label {
  display: block;
  font-family: var(--font-mono);
  font-size: 16px;
  letter-spacing: 0.1em;
  color: var(--color-text-white);
  margin-bottom: 6px;
  text-transform: uppercase;
}

.tac-login .field {
  margin-bottom: 16px;
}

.tac-login .error {
  color: var(--color-alert);
  border: 2px solid var(--color-alert);
  background: rgba(240, 89, 79, 0.08);
  padding: 8px 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  margin-bottom: 16px;
}

.tac-login .tac-btn {
  font-size: 16px;
}

/* ---------- Chat ---------- */
.chat-wrap {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 180px);
}

.chat-log {
  flex: 1;
  overflow-y: auto;
  background: var(--color-bg-primary);
  border: 1px solid var(--color-border);
  padding: 16px;
  font-family: var(--font-mono);
  font-size: 13px;
}

.chat-msg {
  margin-bottom: 14px;
}

.chat-msg .who {
  font-size: 16px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 6px;
  font-family: var(--font-mono);
}

.chat-msg.user .who {
  color: var(--ice);
}

.chat-msg.assistant .who {
  color: var(--color-tactical);
}

.chat-msg .txt {
  white-space: pre-wrap;
  font-size: 16px;
}

.chat-msg.user .txt {
  color: var(--color-text-primary);
}

.chat-msg.assistant .txt {
  color: color-mix(in srgb, var(--color-tactical) 92%, white);
  text-shadow: 0 0 6px rgba(52, 209, 127, 0.3);
}

.chat-msg .src {
  display: inline-block;
  margin-left: 8px;
  font-size: 9px;
  color: white;
  letter-spacing: 0.1em;
}

.chat-input-row {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.chat-input-row textarea {
  flex: 1;
  min-height: 58px;
  resize: vertical;
}

#chat-input {
  font-size: 16px;
  color: #ffffff;
}

#chat-input::placeholder {
  font-size: 16px;
  color: #ffffff;
  opacity: 1;
}

#chat-send {
  font-size: 16px;
}

/* ---------- Map ---------- */
#mapid {
  height: 70vh;
  border: 1px solid var(--color-border);
  filter: hue-rotate(62deg) saturate(0.65) brightness(0.52);
}

/* ---------- Checkbox / quota ---------- */
.tac-check {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 4px;
  border-bottom: 1px solid color-mix(in srgb, var(--color-border) 50%, transparent);
}

.tac-check input[type="checkbox"] {
  accent-color: var(--color-tactical);
  width: 16px;
  height: 16px;
}

.tac-check .name {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.05em;
}

.tac-check.done .name {
  color: var(--color-text-muted);
  text-decoration: line-through;
}

.quota-box {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--color-text-muted);
  margin-top: 8px;
}

.quota-box b {
  color: var(--color-tactical);
  font-weight: 600;
}

.home-subline,
.bunker-subline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.home-subline-main,
.bunker-subline-main {
  min-width: 0;
}

.home-subline-line1,
.home-subline-line2 {
  display: inline;
}

.home-subline-line2 {
  margin-left: 0.35em;
}

.home-subline-quota,
.bunker-subline-quota {
  margin-top: 0;
  margin-left: auto;
}

a.home-module-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

a.home-module-link.locked {
  opacity: 0.8;
  pointer-events: none;
  border-color: color-mix(in srgb, #fbbf24 28%, var(--color-border));
  box-shadow:
    inset 0 0 0 1px rgba(52, 209, 127, 0.07),
    inset 3px 0 0 color-mix(in srgb, #eab308 32%, transparent);
  background-image: linear-gradient(155deg,
      rgba(251, 191, 36, 0.07) 0%,
      transparent 58%);
}

/* ---------- News cards ---------- */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}

.news-grid .tac-card p {
  font-size: 16px;
  font-family: var(--font-sans);
  color: var(--color-text-muted);
}

.news-card {
  display: flex;
  flex-direction: column;
  position: relative;
  background: color-mix(in srgb, var(--color-bg-panel-elevated) 40%, transparent);
  border: 1px solid var(--color-border);
  padding: 0;
  overflow: hidden;
  border-radius: 12px;
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
  border-left: 4px solid var(--color-tactical);
}

.news-card__media {
  display: block;
  position: relative;
  aspect-ratio: 16 / 9;
  background: #0e1210;
  overflow: hidden;
  flex-shrink: 0;
}

.news-card__media:focus-visible {
  outline: 2px solid var(--color-tactical);
  outline-offset: 2px;
}

.news-card__media--static {
  pointer-events: none;
}

.news-card__img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.25s ease, filter 0.2s ease;
}

.news-card__img--fallback {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.news-card__img--fallback.is-visible {
  opacity: 1;
}

.news-card__media--fallback-on .news-card__placeholder {
  display: none;
}

.news-card__media:has(.news-card__img:not(.news-card__img--fallback)) .news-card__placeholder {
  display: none;
}

.news-card:hover .news-card__img {
  transform: scale(1.03);
  filter: brightness(1.05);
}

.news-card__placeholder {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: repeating-linear-gradient(-12deg,
      rgba(30, 38, 32, 0.9) 0 12px,
      rgba(12, 16, 14, 0.95) 12px 24px),
    var(--color-bg-primary);
}

.news-card__placeholder span {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.28em;
  color: var(--color-text-muted);
  opacity: 0.7;
}

.news-card__body {
  padding: 14px 16px 16px 20px;
}

.news-card:hover {
  border-color: color-mix(in srgb, var(--color-tactical) 40%, var(--color-border));
  box-shadow:
    0 0 0 1px rgba(52, 209, 127, 0.2),
    0 8px 24px rgba(0, 0, 0, 0.35);
}

.news-card h3 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 400;
  letter-spacing: 0.12em;
  color: var(--color-text-primary);
  margin: 0 0 8px;
  line-height: 1.35;
}

.news-card h3 a {
  color: inherit;
  text-decoration: none;
  font-size: 16px;
}

.news-card h3 a:hover {
  color: var(--color-tactical);
}

.news-card__cta {
  margin-top: 4px;
}

.news-card .meta {
  font-size: 16px;
  font-family: var(--font-mono);
  color: var(--color-text-muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.news-card p {
  color: color-mix(in srgb, var(--color-text-primary) 80%, transparent);
  font-size: 16px;
  font-weight: 500;
  font-family: var(--font-sans);
  line-height: 1.5;
  margin: 0 0 12px;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.news-card a {
  color: var(--color-tactical);
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-decoration: none;
}

.news-card a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.news-card__media,
.news-card__media:hover {
  text-decoration: none !important;
}

.news-subline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 16px !important;
}

.news-subline-main {
  min-width: 0;
  font-size: 16px !important;
}

.news-subline-meta {
  font-family: var(--font-mono);
  font-size: 16px;
  letter-spacing: 0.12em;
  color: var(--color-text-muted);
  max-width: 100%;
  text-align: right;
}

@media (max-width: 640px) {
  .news-subline-meta {
    text-align: left;
    flex-basis: 100%;
  }
}

/* ---------- Efeitos utilitários ---------- */
.flicker {
  animation: flicker-soft 3s infinite;
}

@keyframes flicker-soft {

  0%,
  18%,
  22%,
  25%,
  53%,
  57%,
  100% {
    opacity: 1;
  }

  20%,
  24%,
  55% {
    opacity: 0.65;
  }
}

.blink::after {
  content: "▊";
  margin-left: 2px;
  animation: tac-caret-blink 1s steps(1) infinite;
  color: var(--color-text-hud);
}

/* ---------- Ícones / assets ---------- */
img,
svg,
video,
canvas {
  max-width: 100%;
  height: auto;
}

/* Barra inferior + dica de scroll: o wrapper esconde-se no desktop */
.tac-bottom-nav-outer,
.tac-bottom-drawer {
  display: none;
}

.icon-btn {
  width: 40px;
  height: 40px;
  min-width: 40px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid color-mix(in srgb, var(--color-border) 70%, transparent);
  border-radius: 12px;
  background: transparent;
  color: var(--color-text-hud);
  font-size: 18px;
  line-height: 1;
}

.icon-btn:hover {
  border-color: var(--color-tactical-dim);
  box-shadow: 0 0 10px rgba(52, 209, 127, 0.25);
}

/* ---------- Tablet ---------- */
@media (min-width: 768px) and (max-width: 1024px) {
  .tac-main {
    padding: 18px clamp(14px, 3vw, 22px);
  }

  .tac-grid.cols-4,
  .tac-grid.cols-3,
  .tac-grid.cols-2 {
    grid-template-columns: 1fr 1fr;
  }
}

/* ---------- Mobile (<768px mantido do projeto) ---------- */
@media (max-width: 767px) {
  :root {
    --tac-topbar-stack-h: 56px;
  }

  html,
  body {
    overflow-x: hidden;
  }

  .tac-topbar {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    min-height: 56px;
    padding: 0 12px;
  }

  .tac-topbar-heading {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1 1 auto;
    min-width: 0;
    order: 0;
  }

  .tac-topbar-title {
    display: block;
    flex: 1 1 auto;
    min-width: 0;
    font-family: var(--font-display);
    font-size: 16px;
    font-weight: 400;
    letter-spacing: 0.12em;
    color: var(--color-text-hud);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 2px;
  }

  .tac-topbar-help-btn {
    width: 32px;
    height: 32px;
    max-width: 32px;
    flex-shrink: 0;
  }

  .tac-topbar-help-btn .tac-page-help-btn__mark {
    font-size: 13px;
  }

  /* Título grande + ? no corpo: já no header (evita duplicar) */
  .tac-main .tac-page-title-row:not(.tac-page-title-row--centered) {
    display: flex !important;
  }

  .tac-main .hud-brand-row {
    display: none !important;
  }

  .tac-topbar-desktop {
    display: none !important;
  }

  .tac-topbar-actions {
    position: relative;
    top: auto;
    right: auto;
    order: 1;
    margin-left: auto;
    flex-shrink: 0;
  }

  .tac-shell {
    min-height: calc(100vh - 56px);
    display: block;
  }

  .tac-main {
    padding: 12px 12px calc(84px + env(safe-area-inset-bottom));
  }

  .tac-sidebar {
    display: none !important;
  }

  .tac-bottom-nav-outer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 80;
    display: block;
    padding: 6px 10px calc(6px + env(safe-area-inset-bottom));
    background: rgba(5, 8, 5, 0.96);
    border-top: 1px solid var(--color-border);
    box-sizing: border-box;
    font-family: var(--font-sans);
  }

  .tac-bottom-nav {
    position: relative;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    align-items: stretch;
    gap: 0;
    min-height: 56px;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    overflow-y: hidden;
  }

  .tac-bottom-nav a,
  .tac-bottom-nav .tac-bottom-nav-more-btn {
    min-height: 48px;
    border: 0;
    background: transparent;
    color: #ffffff;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    border-radius: 12px;
    box-sizing: border-box;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
  }

  .tac-bottom-nav a:hover,
  .tac-bottom-nav a.active,
  .tac-bottom-nav .tac-bottom-nav-more-btn:hover {
    color: var(--color-tactical);
    background: rgba(0, 242, 116, 0.06);
  }

  .tac-bottom-nav .icon {
    font-size: 20px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: inherit;
  }

  .tac-bottom-nav .icon .tac-svg-ico svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
  }

  .tac-bottom-nav .label {
    font-size: 11px !important;
    font-weight: 600;
    line-height: 1.15;
    text-align: center;
    letter-spacing: 0.04em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    text-transform: uppercase;
  }

  .tac-bottom-nav a.active {
    color: var(--color-tactical);
    background: rgba(52, 209, 127, 0.12);
    box-shadow: inset 0 -2px 0 var(--color-tactical);
  }

  /* Drawer de mais opções (More Bottom Sheet Drawer) */
  .tac-bottom-drawer {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.22s ease, visibility 0.22s ease;
  }

  .tac-bottom-drawer.open {
    visibility: visible;
    opacity: 1;
  }

  .tac-bottom-drawer-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(4, 7, 5, 0.85);
    backdrop-filter: blur(6px);
  }

  .tac-bottom-drawer-content {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(6, 11, 8, 0.98);
    border-top: 2px solid var(--color-tactical);
    border-radius: 18px 18px 0 0;
    box-shadow: 0 -8px 24px rgba(0, 242, 116, 0.2);
    padding: 18px 16px calc(24px + env(safe-area-inset-bottom)) 16px;
    transform: translateY(100%);
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    max-height: 80vh;
    overflow-y: auto;
    box-sizing: border-box;
  }

  .tac-bottom-drawer.open .tac-bottom-drawer-content {
    transform: translateY(0);
  }

  .tac-bottom-drawer-handle {
    width: 36px;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    margin: -6px auto 16px auto;
  }

  .tac-bottom-drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(0, 242, 116, 0.12);
  }

  .tac-bottom-drawer-title {
    font-family: var(--font-sans);
    font-size: 13px;
    font-weight: 800;
    color: var(--color-tactical);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-shadow: 0 0 6px rgba(0, 242, 116, 0.25);
  }

  .tac-bottom-drawer-close-btn {
    background: none;
    border: none;
    color: var(--color-text-muted);
    font-size: 26px;
    cursor: pointer;
    padding: 2px 8px;
    line-height: 1;
    transition: color 0.15s ease;
  }

  .tac-bottom-drawer-close-btn:hover {
    color: var(--color-tactical);
  }

  .tac-drawer-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .tac-drawer-list-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    background: rgba(12, 20, 15, 0.45);
    border: 1px solid rgba(0, 242, 116, 0.05);
    border-radius: 10px;
    color: var(--color-text-primary);
    text-decoration: none;
    transition: all 0.15s ease;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
  }

  .tac-drawer-list-item:hover,
  .tac-drawer-list-item.active {
    background: rgba(0, 242, 116, 0.08);
    border-color: var(--color-tactical);
    color: var(--color-tactical);
    box-shadow: 0 0 10px rgba(0, 242, 116, 0.12);
  }

  .tac-drawer-list-item .icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: inherit;
    flex-shrink: 0;
  }

  .tac-drawer-list-item .icon .tac-svg-ico svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
  }

  .tac-drawer-list-item.locked {
    opacity: 0.5;
    border-color: rgba(245, 165, 36, 0.18);
  }

  .tac-drawer-list-item.locked .label::after {
    content: " 🔒";
    font-size: 10px;
    margin-left: 4px;
  }

  .tac-drawer-list-item.locked:hover {
    color: var(--color-warn);
    border-color: var(--color-warn);
    background: rgba(245, 165, 36, 0.05);
  }

  .tac-drawer-list-item.logout-item {
    color: var(--color-alert);
    border-color: rgba(255, 70, 70, 0.08);
  }

  .tac-drawer-list-item.logout-item:hover {
    background: rgba(255, 70, 70, 0.06);
    border-color: var(--color-alert);
    color: var(--color-alert);
  }

  .tac-grid.cols-4,
  .tac-grid.cols-3,
  .tac-grid.cols-2,
  .news-grid {
    grid-template-columns: 1fr !important;
  }

  .chat-input-row {
    flex-direction: column;
  }

  body,
  p,
  li,
  td,
  input,
  textarea,
  button,
  select {
    font-size: 14px;
  }

  .tac-page-title {
    font-size: clamp(22px, 6vw, 28px);
  }

  .tac-page-title-row--centered .tac-page-help-btn {
    width: 36px;
    height: 36px;
    max-width: 36px;
  }

  .tac-page-title-row--centered .tac-page-help-btn__mark {
    font-size: 14px;
  }

  .tac-page-sub,
  .tac-card-title,
  .quota-box,
  .news-card .meta,
  .tac-table th {
    font-size: 13px !important;
    letter-spacing: 0.04em !important;
  }

  .tac-badge {
    padding: 6px 10px;
    font-size: 10px;
  }

  .tac-badge,
  .news-card a {
    font-size: 12px !important;
  }

  .tac-btn,
  .tac-input,
  textarea.tac-input,
  .tac-nav a {
    min-height: 44px;
  }

  .tac-btn {
    width: 100%;
  }

  .tac-table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
  }

  .tac-terminal,
  .chat-log,
  .news-grid {
    -webkit-overflow-scrolling: touch;
  }

  .home-subline {
    display: block;
  }

  .home-subline-main {
    display: block;
    line-height: 1.5;
  }

  .home-subline-line1,
  .home-subline-line2 {
    display: block;
  }

  .home-subline-line2 {
    margin-left: 0;
    margin-top: 14px;
  }

  .home-subline-quota {
    display: flex;
    margin-top: 10px;
    margin-left: 0;
    width: 100%;
  }

  .bunker-subline {
    display: block;
  }

  .bunker-subline-main {
    display: block;
    line-height: 1.5;
  }

  .bunker-subline-quota {
    display: flex;
    margin-top: 10px;
    margin-left: 0;
    width: 100%;
  }

  .news-subline {
    display: block;
  }

  .news-subline-main {
    display: block;
    line-height: 1.5;
  }

  .page-command .tac-main {
    padding: 0 0 calc(72px + env(safe-area-inset-bottom));
  }

  .page-command .tac-page-sub {
    display: none !important;
  }

  .page-command .tac-card {
    border: 0;
    padding: 0;
    background: transparent;
    box-shadow: none;
  }

  .page-command .tac-card::before,
  .page-command .tac-card::after {
    display: none;
  }

  .page-command .tac-card-title {
    display: none;
  }

  .page-command .chat-wrap {
    height: calc(100dvh - var(--tac-topbar-stack-h) - 72px - env(safe-area-inset-bottom));
  }

  .page-command .chat-log {
    border-left: 0;
    border-right: 0;
    border-top: 0;
    margin: 0;
    padding: 14px 16px;
  }

  .page-command .chat-input-row {
    margin: 0;
    padding: 10px 12px;
    border-top: 1px solid var(--color-border);
    background: var(--color-bg-panel);
  }

  .page-command .chat-input-row textarea {
    min-height: 96px;
    max-height: 34dvh;
  }

  .page-command #chat-send {
    width: 100%;
  }

  .icon-btn {
    min-width: 44px;
    min-height: 44px;
    width: 44px;
    height: 44px;
    font-size: 20px;
  }
}

/* ---------- Page title + help (?) ---------- */
/* Flex: título e ? agrupados à esquerda (sem empurrar o botão para a margem direita) */
.tac-page-title-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: nowrap;
  gap: 12px;
  margin: 0 0 10px;
}

.tac-page-title-row .tac-page-title {
  margin-bottom: 0;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
}

/* Título + ? centrados (ex.: ACCESS DENIED) */
.tac-page-title-row--centered {
  justify-content: center;
  width: 100%;
}

.tac-page-help-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  max-width: 40px;
  padding: 0;
  margin: 0;
  box-sizing: border-box;
  border-radius: 50%;
  border: 2px solid var(--neon);
  background:
    radial-gradient(circle at 35% 28%, rgba(131, 235, 121, 0.22), transparent 55%),
    linear-gradient(165deg, rgba(52, 209, 127, 0.18), rgba(5, 10, 6, 0.96));
  color: var(--neon);
  cursor: pointer;
  box-shadow:
    0 0 0 1px rgba(52, 209, 127, 0.2),
    0 0 20px rgba(52, 209, 127, 0.35);
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.12s ease, background 0.15s ease;
}

.tac-page-help-btn:hover {
  border-color: var(--color-text-hud);
  color: var(--color-text-hud);
  box-shadow:
    0 0 0 1px rgba(131, 235, 121, 0.35),
    0 0 28px rgba(52, 209, 127, 0.5);
  transform: scale(1.05);
}

.tac-page-help-btn:focus-visible {
  outline: 2px solid var(--neon);
  outline-offset: 3px;
}

.tac-page-help-btn__ring {
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  border: 1px solid rgba(52, 209, 127, 0.28);
  pointer-events: none;
}

.tac-page-help-btn__mark {
  position: relative;
  z-index: 1;
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 16px;
  line-height: 1;
  color: inherit;
  text-shadow: 0 0 12px rgba(52, 209, 127, 0.65);
}

/* Help modal */
.tac-page-help-modal {
  position: fixed;
  inset: 0;
  z-index: 4000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.tac-page-help-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.tac-page-help-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 4, 2, 0.72);
  backdrop-filter: blur(4px);
}

.tac-page-help-modal__panel {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  max-height: min(88vh, 640px);
  overflow: auto;
  padding: 22px 22px 20px;
  border-radius: 12px;
  border: 1px solid var(--color-border-solid);
  background: linear-gradient(180deg, var(--color-bg-panel-elevated), var(--color-bg-panel));
  box-shadow:
    0 0 0 1px rgba(52, 209, 127, 0.12),
    0 24px 80px rgba(0, 0, 0, 0.65);
}

.tac-page-help-modal__close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  background: rgba(5, 8, 5, 0.6);
  color: var(--txt-0);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.tac-page-help-modal__close:hover {
  border-color: var(--neon);
  color: var(--neon);
}

.tac-page-help-modal__title {
  margin: 0 36px 16px 0;
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: 0.14em;
  line-height: 1.35;
}

.tac-page-help-modal__kicker {
  display: block;
  font-size: 11px;
  color: var(--txt-2);
  letter-spacing: 0.28em;
  margin-bottom: 6px;
}

.tac-page-help-modal__context {
  display: block;
  font-size: clamp(17px, 2.2vw, 22px);
  color: var(--color-text-hud);
  text-shadow: 0 0 10px rgba(52, 209, 127, 0.35);
  text-transform: uppercase;
}

.tac-page-help-modal__body {
  border-top: 1px solid var(--color-border);
  padding-top: 18px;
}

.tac-page-help-video-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 12px 8px 8px;
}

.tac-page-help-video-root {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  min-height: 1px;
}

.tac-page-help-video-root vturb-smartplayer {
  display: block;
  margin: 0 auto;
  width: 100%;
  max-width: 400px;
}

.tac-page-help-modal__hint {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--txt-2);
  text-align: center;
  max-width: 280px;
}

.tac-page-help-modal__hint--hidden {
  display: none;
}

body.tac-modal-open {
  overflow: hidden;
}

/* Feature announcement (above help modal if both used) */
.tac-page-help-modal.tac-feature-announce-modal {
  z-index: 4050;
}

.tac-feature-announce__lead {
  margin: 0 0 18px;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.55;
  letter-spacing: 0.06em;
  color: var(--txt-1);
}

.tac-feature-announce__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

/* ---------- Support page ---------- */
.tac-support-hero {
  max-width: 640px;
  margin: 0 auto;
  padding: clamp(22px, 4vw, 36px) clamp(18px, 3vw, 28px);
  border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--color-border-solid) 80%, transparent);
  background:
    linear-gradient(165deg, rgba(6, 10, 7, 0.92) 0%, rgba(4, 8, 5, 0.96) 100%),
    radial-gradient(120% 90% at 8% 25%, rgba(45, 70, 160, 0.14), transparent 52%),
    radial-gradient(100% 80% at 92% 78%, rgba(160, 35, 45, 0.1), transparent 48%),
    var(--color-bg-panel);
  box-shadow:
    inset 0 0 0 1px rgba(52, 209, 127, 0.06),
    0 18px 48px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
}

.tac-support-hero__head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.tac-support-hero__ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: rgba(52, 209, 127, 0.14);
  border: 1px solid color-mix(in srgb, var(--neon) 45%, transparent);
  color: var(--neon);
  box-shadow: 0 0 18px rgba(52, 209, 127, 0.2);
}

.tac-support-hero__ico .tac-svg-ico svg {
  width: 26px;
  height: 26px;
}

.tac-support-hero__title {
  margin: 0;
  font-family: var(--font-sans);
  font-size: clamp(1.35rem, 3.5vw, 1.75rem);
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.2;
  color: #f4faf3;
  text-shadow: 0 0 20px rgba(52, 209, 127, 0.15);
}

.tac-support-hero__lead {
  margin: 0 0 24px;
  font-family: var(--font-sans);
  font-size: 18px;
  line-height: 1.65;
  color: color-mix(in srgb, var(--color-text-primary) 92%, transparent);
  text-align: center;
}

.tac-support-hero__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.tac-support-mail-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 300px;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--neon) 55%, #1a3a14);
  background: linear-gradient(180deg, #7ee6a0 0%, var(--neon) 42%, color-mix(in srgb, var(--neon) 85%, #0d2808) 100%);
  color: #0a100a;
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12) inset,
    0 6px 22px rgba(52, 209, 127, 0.35);
  transition: transform 0.12s ease, filter 0.12s ease, box-shadow 0.12s ease;
  word-break: break-all;
}

.tac-support-mail-btn:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.16) inset,
    0 10px 28px rgba(52, 209, 127, 0.45);
}

.tac-support-mail-btn:focus-visible {
  outline: 2px solid var(--color-text-hud);
  outline-offset: 3px;
}

.tac-support-mail-btn__ico {
  font-size: 18px;
  line-height: 1;
  filter: drop-shadow(0 1px 0 rgba(255, 255, 255, 0.25));
}

@media (max-width: 767px) {
  .tac-support-hero__lead {
    text-align: left;
    font-size: 18px;
  }

  .tac-support-mail-btn {
    width: 100%;
    padding: 14px 18px;
    font-size: 16px;
  }
}



/* Estilização do Banner Largura Total */
.assistance-banner {
  width: 100%;
  /* background: linear-gradient(rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.85)), url('https://images.unsplash.com/photo-1508612761958-e931d843bdd5?q=80&w=1500') center/cover no-repeat; */
  background: linear-gradient(rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.55)), url('../img/banner-login.jpg') center/cover no-repeat;
  /* Substitua o link acima pelo caminho da imagem da bandeira americana escurecida se preferir */
  padding: 30px 20px;
  box-sizing: border-box;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.assistance-content {
  max-width: 800px;
  display: flex;
  align-items: center;
  gap: 20px;
  text-align: left;
}

.assistance-icon {
  flex-shrink: 0;
  /* Cor verde neon baseada no estilo do seu app */
  filter: drop-shadow(0 0 8px rgba(52, 209, 127, 0.4));
}

.assistance-text h2 {
  font-family: 'Inter', sans-serif;
  color: #ffffff;
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 6px 0;
  letter-spacing: 0.03em;
}

.assistance-text p {
  font-family: 'JetBrains Mono', monospace;
  color: #cccccc;
  font-size: 16px;
  margin: 0;
  line-height: 1.5;
}

/* Responsividade para telas menores */
@media (max-width: 600px) {
  .assistance-content {
    flex-direction: column;
    text-align: center;
  }

  .assistance-text h2 {
    font-size: 24px;
  }
}

/* @media (min-width: 768px) {
  .tac-login-wrap {
    margin-top: 60px
  }
}

@media (max-width: 768px) {
  .tac-login-wrap {
    margin-top: 45px
  }
} */



.tac-nav a,
.tac-nav .sep,
.tac-logo .version,
.hud-nav-threat .hud-mini-table th,
.hud-mini-table th, .hud-mini-table td,
.hud-nav-threat .hud-conf-lab,
.hud-conf-lab,
.hud-nav-threat .hud-links-row a,
.hud-map-foot,
.hud-mast,
.tac-sidebar-footer,
.hud-wx-day span,
.hud-vec-top,
.hud-prep-list li,
.hud-footnote,
.tac-page-sub,
.heat-zip-status,
.route-toolbar,
.map-tab,
.tac-btn,
.tac-btn.ghost,
.heat-legend .lg-group, 
.tac-table td,
.tac-table th,
.chaos-live-tracking,
.news-card .meta,
.news-card h3 a,
.news-card h3 a:hover,
.news-card p,
.bunker-file-name,
.hh-form label,
.ss-metric .ss-mk,
.ss-metric .ss-ms,
.ss-matrix-head,
.ss-empty,
.tc-hero.hud-nav-threat .tc-hero-blurb,
#hvm-tier-hint,
.cc-card .cc-tag,
.cc-card .cc-title,
.cc-banner p,
.cc-chat-id span,
.cc-msg .cc-bubble,
.cc-chat-disclaimer,
.cc-section-title small,
.cc-section-title,
.tac-support-hero__lead{color: white!important;},

.saved-pois-list span{color: white; opacity: 1 !important;}

/* Regra para botões em URLs partindo de /app */
.app-route button,
.app-route .tac-btn {
  font-size: 15px !important;
  font-weight: bold !important;
}

/* Ocultar botões de ajuda de todas as páginas */
.tac-page-help-btn {
  display: none !important;
}

/* ---------- BOTÃO DE EXPORTAÇÃO TÁTICO ---------- */
.tac-btn-export {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  height: 28px;
  padding: 0 10px;
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  cursor: pointer;
  border: 1px solid var(--color-tactical);
  background: rgba(52, 209, 127, 0.08);
  color: var(--color-tactical) !important;
  clip-path: polygon(0 0, calc(100% - 6px) 0, 100% 6px, 100% 100%, 6px 100%, 0 calc(100% - 6px));
  transition: all 0.15s;
}

.tac-btn-export:hover {
  background: var(--color-tactical);
  color: var(--color-bg-primary) !important;
  box-shadow: 0 0 8px rgba(52, 209, 127, 0.5);
}

@media (max-width: 767px) {
  .tac-btn-export {
    font-size: 9px;
    padding: 0 6px;
    min-height: 24px;
    height: 24px;
  }
}

/* Ocultar elementos desnecessários na exportação para PDF */
@media print {
  .no-print,
  .tac-sidebar,
  .tac-topbar,
  .assistance-banner,
  .tac-support-mail-btn,
  .tac-page-help-btn,
  .tac-bottom-nav-outer,
  #page-help-modal,
  #feature-announce-modal,
  .tac-page-help-modal {
    display: none !important;
  }
  
  body {
    background-color: #0c1310 !important;
    background-image: none !important;
  }
  
  .tac-main {
    padding: 0 !important;
    margin: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
  }
}





/* ===== De-militarised: rounded corners (softer, less square) ===== */
.tac-nav-link, .tac-bottom-nav a { border-radius: 10px; }
.hud-panel, .hud-panel--gauge, .hud-panel--news-block, .hud-nav-threat__status,
.hud-radar, .hud-wx-grid, .hud-ticker, .hud-mast, .hud-stat-panel, .hud-grid-top > * {
  border-radius: 16px;
}
.hud-status-pill, .hud-defcon, .hud-clock, .hud-chip { border-radius: 999px; }
/* ===================================================================
   LOVABLE LAYOUT BASE — component restyle (cards/buttons/badges/inputs)
   Overrides earlier military styling (later same-specificity wins).
   =================================================================== */
:root {
  --gradient-card: linear-gradient(180deg, #18241e 0%, #121c17 100%);
  --gradient-primary: linear-gradient(135deg, #46df8e, #2bbf70);
  --shadow-card: 0 1px 0 0 rgba(255,255,255,.04) inset, 0 10px 28px -14px rgba(0,0,0,.7);
  --shadow-glow: 0 0 36px rgba(52,209,127,.22);
}

/* Cards = Lovable rounded-xl gradient card */
.tac-card {
  background: var(--gradient-card);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  padding: 22px;
  box-shadow: var(--shadow-card);
}
.tac-card::before, .tac-card::after { display: none; } /* drop HUD corner brackets */

/* Buttons = Lovable solid primary, rounded, no clip-path / no UPPERCASE */
.tac-btn {
  min-height: 46px;
  padding: 12px 20px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0;
  text-transform: none;
  border: 0;
  border-radius: 11px;
  background: var(--gradient-primary);
  color: #06210f;
  clip-path: none;
  box-shadow: var(--shadow-glow);
}
.tac-btn:hover { filter: brightness(1.05); transform: translateY(-1px); background: var(--gradient-primary); color: #06210f; }
.tac-btn.ghost, .tac-btn.outline {
  background: transparent; border: 1.5px solid var(--color-border-solid);
  color: var(--color-text-primary); box-shadow: none; clip-path: none;
}

/* Badges = soft pill */
.tac-badge {
  padding: 5px 12px; border-width: 1px; border-radius: 999px;
  letter-spacing: .03em; font-weight: 600; box-shadow: none; text-transform: none;
  font-family: var(--font-sans); font-size: 12px;
}

/* Inputs = Lovable (sans font, bigger, clear focus ring) */
.tac-input, textarea.tac-input {
  font-family: var(--font-sans); font-size: 15px; padding: 12px 14px;
  border-radius: 11px; border: 1.5px solid var(--color-border-solid);
}
.tac-input:focus { border-color: var(--color-tactical); box-shadow: 0 0 0 4px rgba(52,209,127,.18); }
.tac-input::placeholder { color: var(--color-text-muted); opacity: 1; }
/* "Save for offline" export button */
.tac-btn-export {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px; border-radius: 11px;
  background: rgba(52,209,127,.12);
  border: 1.5px solid var(--color-tactical);
  color: var(--color-text-primary);
  font-family: var(--font-sans); font-weight: 600; font-size: 14px;
  cursor: pointer; transition: background .15s, transform .12s;
}
.tac-btn-export:hover { background: rgba(52,209,127,.22); transform: translateY(-1px); }
.tac-btn-export:disabled { opacity: .6; cursor: default; }
.tac-export-bar { display: flex; justify-content: flex-end; margin-bottom: 14px; }
/* ===== "How to use" floating launcher + modal (always visible, not in the way) ===== */
.howto-fab {
  position: fixed; right: 18px; bottom: 88px; z-index: 90;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 16px; border-radius: 999px;
  background: var(--gradient-primary, #34d17f); color: #06210f; border: 0; cursor: pointer;
  font-family: var(--font-display); font-weight: 700; font-size: 14px;
  box-shadow: 0 10px 26px -8px rgba(0,0,0,.65), var(--shadow-glow);
  transition: transform .12s, filter .12s;
}
.howto-fab:hover { filter: brightness(1.05); transform: translateY(-1px); }
.howto-fab svg { width: 20px; height: 20px; }
@media (min-width: 768px) { .howto-fab { bottom: 24px; right: 24px; } }

.howto-modal-backdrop {
  position: fixed; inset: 0; z-index: 200000;
  background: rgba(0,0,0,.72); -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
  display: flex; align-items: center; justify-content: center; padding: 16px;
}
.howto-modal-backdrop[hidden] { display: none; }
.howto-modal {
  width: 100%; max-width: 520px;
  background: var(--gradient-card, #141f1a);
  border: 1px solid var(--color-border); border-radius: 18px;
  box-shadow: 0 24px 60px -20px rgba(0,0,0,.8); overflow: hidden;
}
.howto-modal__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px; border-bottom: 1px solid var(--color-border);
}
.howto-modal__head h3 { margin: 0; font-family: var(--font-display); font-size: 17px; color: var(--color-text-primary); }
.howto-close {
  width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--color-border);
  background: transparent; color: var(--color-text-primary); font-size: 22px; line-height: 1; cursor: pointer;
}
.howto-close:hover { background: rgba(255,255,255,.06); }
.howto-video { padding: 16px; }
/* ===== Inline "How to use" video card (visible, responsive, tidy) ===== */
.howto-card {
  background: var(--gradient-card, #141f1a);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  box-shadow: var(--shadow-card);
  margin-bottom: 18px;
  overflow: hidden;
}
.howto-card__head {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-bottom: 1px solid var(--color-border);
}
.howto-card__ico {
  width: 30px; height: 30px; flex: none; display: grid; place-items: center;
  border-radius: 9px; background: rgba(52,209,127,.14); color: var(--color-tactical);
}
.howto-card__ico svg { width: 18px; height: 18px; }
.howto-card__head h3 {
  margin: 0; flex: 1; font-family: var(--font-display); font-size: 15px; color: var(--color-text-primary);
}
.howto-card__close {
  width: 30px; height: 30px; flex: none; border-radius: 8px; border: 1px solid var(--color-border);
  background: transparent; color: var(--color-text-muted); font-size: 20px; line-height: 1; cursor: pointer;
}
.howto-card__close:hover { color: var(--color-text-primary); background: rgba(255,255,255,.05); }
.howto-video { padding: 14px 16px; }
/* ===== Risk level bar (replaces the RISK color-square legend) ===== */
.risk-levels { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.risk-levels__label {
  font-family: var(--font-display); font-weight: 700; font-size: 12px;
  letter-spacing: .08em; text-transform: uppercase; color: var(--color-text-muted);
}
.risk-levels__bar {
  display: flex; flex: 1 1 240px; min-width: 220px; max-width: 460px;
  border-radius: 999px; overflow: hidden; border: 1px solid var(--color-border);
}
.risk-levels__seg {
  flex: 1; text-align: center; padding: 6px 4px;
  font-family: var(--font-display); font-weight: 700; font-size: 11px;
  letter-spacing: .02em; color: #07120c; white-space: nowrap;
}
.risk-low  { background: #34d17f; }
.risk-mod  { background: #f5c24a; }
.risk-high { background: #f5a524; }
.risk-crit { background: #f0594f; color: #fff; }
/* ===== Professional page header (Lovable style) ===== */
.tac-page-title-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 4px 0 22px;
  flex-wrap: wrap;
}
.tac-page-ico-chip {
  width: 46px; height: 46px; flex: none;
  display: grid; place-items: center;
  border-radius: 13px;
  background: rgba(52, 209, 127, 0.13);
  color: var(--color-tactical);
  border: 1px solid rgba(52, 209, 127, 0.25);
}
.tac-page-ico-chip .tac-svg-ico svg,
.tac-page-ico-chip svg { width: 24px; height: 24px; stroke: currentColor; filter: none; }
.tac-page-head-txt { flex: 1 1 auto; min-width: 0; }
.tac-page-head-txt .tac-page-title { margin: 0; }
.tac-page-sub--in-head { margin: 2px 0 0; }
.tac-page-actions {
  display: inline-flex; align-items: center; gap: 10px; margin-left: auto;
}
/* Export button slots into the actions row cleanly */
.tac-page-title-row .tac-btn-export { margin-left: 0 !important; }

/* Mobile topbar heading — clean (was green mono terminal style) */
.tac-topbar-title {
  font-family: var(--font-display) !important;
  font-weight: 700 !important;
  font-size: 16px !important;
  letter-spacing: 0 !important;
  text-transform: none !important;
  color: var(--color-text-primary) !important;
  text-shadow: none !important;
}

/* Subtitle directly after a header row sits closer */
.tac-page-title-row + .tac-page-sub { margin-top: -12px; }

/* Elegant, responsive and friendly subtitle */
.tac-page-sub {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-muted);
  letter-spacing: normal;
  text-transform: none;
  margin-bottom: 22px;
  line-height: 1.5;
  padding: 0 4px;
}
.tac-page-sub .bunker-subline-main,
.tac-page-sub .news-subline-main,
.tac-page-sub > span:first-child:not(.quota-box) {
  flex: 1 1 300px;
  min-width: 0;
  text-transform: none;
}
.tac-page-sub .quota-box {
  font-family: var(--font-mono);
  font-size: 11px !important;
  color: var(--color-text-muted) !important;
  background: rgba(0, 242, 116, 0.04) !important;
  border: 1px solid rgba(0, 242, 116, 0.12) !important;
  padding: 4px 10px !important;
  border-radius: 6px !important;
  letter-spacing: 0.05em !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
  flex: 0 0 auto !important;
  font-weight: 500 !important;
  text-transform: uppercase !important;
}
.tac-page-sub .quota-box b {
  color: var(--color-tactical) !important;
}

/* Mobile topbar logo */
.tac-topbar-logo {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Exibir logout-mobile-btn em todas as resoluções */
@media (min-width: 768px) {
  .logout-mobile-btn {
    display: inline-flex !important;
  }
}