/* Arsenal OSINT — FusãoTechX Mz · modo escuro por omissão */
:root {
  --bg: #0a0e1a; --bg2: #0e1427; --panel: #121a30; --panel2: #16203a; --line: #1e2a47; --line2: #2a3a63;
  --text: #e6ecf7; --muted: #93a2c2; --dim: #64748f;
  --cyan: #22d3ee; --cyan2: #67e8f9; --indigo: #818cf8; --violet: #c084fc; --green: #34d399; --amber: #fbbf24; --red: #f87171; --pink: #f472b6;
  --radius: 14px; --shadow: 0 12px 34px rgba(0,0,0,.4);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --maxw: 1200px;
}
:root[data-theme="light"] {
  --bg: #f3f6fc; --bg2: #ffffff; --panel: #ffffff; --panel2: #f5f8fe; --line: #e1e8f5; --line2: #cdd8ec;
  --text: #0f172a; --muted: #4a5a76; --dim: #7c8aa6; --shadow: 0 10px 28px rgba(15,23,42,.1);
  --cyan: #0891b2; --indigo: #4f46e5; --violet: #9333ea;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--text); font: 15.5px/1.6 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--cyan); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.2; font-weight: 700; letter-spacing: -.01em; }
h1 { font-size: 2rem; } h2 { font-size: 1.4rem; } h3 { font-size: 1.1rem; }
p { margin: 0 0 1em; }
code, .mono { font-family: var(--mono); font-size: .9em; }
.muted { color: var(--muted); } .dim { color: var(--dim); } .small { font-size: .85rem; }
img { max-width: 100%; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 1.4rem 0; }

/* ---------- topo */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(10,14,26,.82); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
:root[data-theme="light"] .site-header { background: rgba(255,255,255,.85); }
.site-header .bar { display: flex; align-items: center; gap: 18px; height: 64px; }
.brand { display: flex; align-items: center; gap: 11px; color: var(--text); font-weight: 700; }
.brand img { width: 36px; height: 36px; border-radius: 9px; }
.brand b { font-size: 1.08rem; line-height: 1; } .brand span { display: block; font-size: .66rem; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; margin-top: 2px; }
.nav-links { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.nav-links a { padding: 8px 13px; border-radius: 9px; color: var(--muted); font-weight: 550; }
.nav-links a:hover, .nav-links a.on { background: var(--panel); color: var(--text); text-decoration: none; }
.icon-btn { background: var(--panel); border: 1px solid var(--line2); color: var(--text); width: 38px; height: 38px; border-radius: 9px; cursor: pointer; font-size: 1rem; display: inline-flex; align-items: center; justify-content: center; }
.menu-toggle { display: none; }

/* ---------- hero */
.hero { padding: 54px 0 30px; text-align: center; position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(700px 320px at 50% -40%, rgba(34,211,238,.16), transparent 70%), radial-gradient(600px 300px at 90% 0%, rgba(192,132,252,.12), transparent 70%); pointer-events: none; }
.hero h1 { font-size: 2.7rem; margin-bottom: 10px; }
.hero h1 .grad { background: linear-gradient(120deg, #22d3ee, #818cf8 55%, #c084fc); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero p { color: var(--muted); font-size: 1.1rem; max-width: 640px; margin: 0 auto 22px; }
.searchbar { max-width: 620px; margin: 0 auto; display: flex; gap: 8px; position: relative; }
.searchbar input { flex: 1; padding: 15px 18px; border-radius: 12px; border: 1px solid var(--line2); background: var(--panel); color: var(--text); font: inherit; font-size: 1.05rem; }
.searchbar input:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 4px rgba(34,211,238,.15); }
.hero-stats { display: flex; gap: 26px; justify-content: center; margin-top: 24px; flex-wrap: wrap; }
.hero-stats div { text-align: center; } .hero-stats b { display: block; font-size: 1.6rem; color: var(--cyan); } .hero-stats span { font-size: .82rem; color: var(--muted); }

/* ---------- botões, badges */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 18px; border-radius: 10px; border: 1px solid var(--line2); background: var(--panel2); color: var(--text); font: inherit; font-weight: 600; cursor: pointer; white-space: nowrap; }
.btn:hover { border-color: var(--cyan); text-decoration: none; }
.btn.primary { background: linear-gradient(120deg, #22d3ee, #818cf8); color: #06121f; border: 0; }
.btn.primary:hover { filter: brightness(1.08); }
.btn.sm { padding: 6px 12px; font-size: .85rem; border-radius: 8px; }
.btn.ghost { background: transparent; }
.btn.danger { border-color: rgba(248,113,113,.5); color: var(--red); background: transparent; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px; font-size: .74rem; font-weight: 700; border: 1px solid var(--line2); background: var(--panel2); color: var(--muted); }
.badge.green { color: var(--green); border-color: rgba(52,211,153,.4); background: rgba(52,211,153,.1); }
.badge.amber { color: var(--amber); border-color: rgba(251,191,36,.4); background: rgba(251,191,36,.1); }
.badge.red { color: var(--red); border-color: rgba(248,113,113,.4); background: rgba(248,113,113,.1); }
.badge.cyan { color: var(--cyan); border-color: rgba(34,211,238,.4); background: rgba(34,211,238,.1); }
.badge.violet { color: var(--violet); border-color: rgba(192,132,252,.4); background: rgba(192,132,252,.1); }
.dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; }
.dot.green { background: var(--green); } .dot.amber { background: var(--amber); } .dot.red { background: var(--red); }

/* ---------- grelhas / cards */
section { padding: 28px 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.section-head h2 { margin: 0; }
.grid { display: grid; gap: 16px; }
.cols-3 { grid-template-columns: repeat(3, 1fr); } .cols-4 { grid-template-columns: repeat(4, 1fr); } .cols-2 { grid-template-columns: repeat(2, 1fr); }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; }

/* categoria card */
.cat-card { display: block; color: var(--text); transition: transform .12s, border-color .12s; }
.cat-card:hover { border-color: var(--cyan); transform: translateY(-3px); text-decoration: none; }
.cat-card .emoji { font-size: 1.9rem; }
.cat-card h3 { margin: 8px 0 4px; }
.cat-card p { color: var(--muted); font-size: .88rem; margin: 0 0 10px; }
.cat-card .n { font-size: .78rem; color: var(--cyan); font-weight: 650; }

/* tool card */
.tool-card { display: flex; flex-direction: column; gap: 8px; color: var(--text); transition: transform .12s, border-color .12s; height: 100%; }
.tool-card:hover { border-color: var(--cyan); transform: translateY(-3px); text-decoration: none; }
.tool-card .top { display: flex; align-items: center; gap: 10px; }
.tool-card .emoji { font-size: 1.5rem; width: 42px; height: 42px; display: inline-flex; align-items: center; justify-content: center; background: var(--panel2); border: 1px solid var(--line); border-radius: 10px; flex: none; }
.tool-card h3 { margin: 0; font-size: 1.05rem; }
.tool-card .desc { color: var(--muted); font-size: .88rem; flex: 1; }
.tool-card .meta { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-top: auto; }
.plat { font-size: .74rem; color: var(--dim); }
.featured-tag { margin-left: auto; font-size: .7rem; color: var(--amber); }

/* category featured block on home */
.cat-block { margin-bottom: 30px; }
.cat-block .ch { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.cat-block .ch .emoji { font-size: 1.5rem; } .cat-block .ch h2 { margin: 0; font-size: 1.25rem; }
.cat-block .ch a { margin-left: auto; font-size: .85rem; }

/* ---------- filtros */
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 18px; }
.filters select, .filters input { padding: 9px 12px; border-radius: 9px; border: 1px solid var(--line2); background: var(--panel); color: var(--text); font: inherit; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { padding: 6px 13px; border-radius: 999px; border: 1px solid var(--line2); background: var(--panel); color: var(--muted); font-size: .85rem; cursor: pointer; }
.chip.on, .chip:hover { border-color: var(--cyan); color: var(--text); text-decoration: none; }

/* ---------- página da ferramenta */
.tool-hero { display: flex; gap: 18px; align-items: flex-start; flex-wrap: wrap; }
.tool-hero .big-emoji { font-size: 2.6rem; width: 72px; height: 72px; display: inline-flex; align-items: center; justify-content: center; background: var(--panel); border: 1px solid var(--line2); border-radius: 16px; flex: none; }
.tool-hero h1 { margin: 0 0 6px; }
.tool-hero .badges { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0; }
.tool-layout { display: grid; grid-template-columns: minmax(0,1fr) 300px; gap: 26px; margin-top: 24px; align-items: start; }
.tool-main > section { padding: 0 0 26px; }
.tool-main h2 { font-size: 1.25rem; border-bottom: 1px solid var(--line); padding-bottom: 8px; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.sidebar { position: sticky; top: 84px; display: flex; flex-direction: column; gap: 14px; }
.side-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.side-card h4 { margin: 0 0 10px; font-size: .78rem; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); }
.side-link { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.side-link:last-child { border-bottom: 0; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; font-size: .9rem; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; text-align: right; }

/* OS tabs */
.os-tabs { display: flex; gap: 4px; margin-bottom: 14px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.os-tabs button { background: none; border: 0; border-bottom: 2px solid transparent; color: var(--muted); padding: 9px 14px; font: inherit; font-weight: 600; cursor: pointer; }
.os-tabs button.on { color: var(--text); border-bottom-color: var(--cyan); }
.os-pane { display: none; } .os-pane.on { display: block; }

/* bloco de comando */
.step { margin-bottom: 16px; }
.step .label { font-weight: 600; margin-bottom: 6px; display: flex; align-items: center; gap: 8px; }
.cmd { position: relative; background: #060a16; border: 1px solid var(--line2); border-radius: 10px; }
:root[data-theme="light"] .cmd { background: #0b1020; }
.cmd pre { margin: 0; padding: 14px 44px 14px 16px; overflow-x: auto; color: #d7e3ff; font-family: var(--mono); font-size: .86rem; line-height: 1.6; white-space: pre; }
.cmd .copy { position: absolute; top: 8px; right: 8px; background: rgba(255,255,255,.06); border: 1px solid var(--line2); color: #aeb9d4; border-radius: 7px; padding: 4px 8px; font-size: .72rem; cursor: pointer; }
.cmd .copy:hover { color: #fff; border-color: var(--cyan); }
.cmd .copy.done { color: var(--green); border-color: var(--green); }
.step .note { font-size: .84rem; color: var(--muted); margin-top: 6px; }

/* ---------- pesquisa / descoberta */
.discover-box { border: 1px dashed var(--line2); background: linear-gradient(180deg, rgba(34,211,238,.05), transparent); border-radius: var(--radius); padding: 22px; text-align: center; }
.discover-box .spinner { width: 34px; height: 34px; border: 3px solid var(--line2); border-top-color: var(--cyan); border-radius: 50%; animation: spin 1s linear infinite; margin: 10px auto; }
@keyframes spin { to { transform: rotate(360deg); } }
.result-preview { text-align: left; margin-top: 16px; }
.search-links { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 12px; }

/* ---------- alertas / flash */
.alert { padding: 12px 16px; border-radius: 11px; margin-bottom: 14px; border: 1px solid; font-size: .92rem; }
.alert.success { background: rgba(52,211,153,.1); border-color: rgba(52,211,153,.4); color: #a7f3d0; }
.alert.error { background: rgba(248,113,113,.1); border-color: rgba(248,113,113,.4); color: #fecaca; }
.alert.info { background: rgba(34,211,238,.08); border-color: rgba(34,211,238,.35); color: var(--cyan2); }
:root[data-theme="light"] .alert.success { color: #065f46; } :root[data-theme="light"] .alert.error { color: #991b1b; } :root[data-theme="light"] .alert.info { color: #155e75; }
.empty { text-align: center; padding: 40px 16px; color: var(--muted); }

/* ---------- formulários */
label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 5px; }
.field { margin-bottom: 14px; }
.hint { color: var(--dim); font-size: .8rem; margin-top: 4px; }
input[type=text], input[type=url], input[type=password], input[type=number], input[type=search], select, textarea {
  width: 100%; padding: 10px 12px; border-radius: 9px; border: 1px solid var(--line2); background: var(--bg2); color: var(--text); font: inherit;
}
:root:not([data-theme="light"]) input, :root:not([data-theme="light"]) select, :root:not([data-theme="light"]) textarea { background: var(--panel2); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(34,211,238,.15); }
textarea { min-height: 80px; resize: vertical; }
.check { display: flex; gap: 9px; align-items: center; font-weight: 400; }
.check input { width: 17px; height: 17px; accent-color: var(--cyan); }

/* ---------- auth / admin */
.auth { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 30px 16px;
  background: radial-gradient(800px 500px at 10% -10%, rgba(34,211,238,.12), transparent 60%), radial-gradient(700px 500px at 110% 110%, rgba(192,132,252,.12), transparent 60%), var(--bg); }
.auth-box { width: 100%; max-width: 420px; }
.auth-box .card { box-shadow: var(--shadow); }
.auth-brand { text-align: center; margin-bottom: 18px; }
.auth-brand img { width: 64px; height: 64px; border-radius: 16px; }
.auth-brand h1 { font-size: 1.4rem; margin: 10px 0 2px; }
.admin { display: grid; grid-template-columns: 230px 1fr; min-height: 100vh; }
.admin-side { background: var(--bg2); border-right: 1px solid var(--line); padding: 18px 14px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.admin-side .brand { margin-bottom: 16px; }
.admin-side a { display: flex; gap: 10px; padding: 9px 12px; border-radius: 9px; color: var(--muted); font-weight: 550; }
.admin-side a:hover, .admin-side a.on { background: var(--panel); color: var(--text); text-decoration: none; }
.admin-main { min-width: 0; padding: 24px 28px 60px; }
.admin-main h1 { margin-bottom: 18px; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: .74rem; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); background: var(--panel2); }
tr:last-child td { border-bottom: 0; }
.stat-row { display: grid; grid-template-columns: repeat(4,1fr); gap: 14px; margin-bottom: 20px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; }
.stat b { font-size: 1.8rem; display: block; } .stat span { color: var(--muted); font-size: .85rem; }
.steps-editor .srow { display: grid; grid-template-columns: 90px 1fr 1fr auto; gap: 8px; margin-bottom: 8px; align-items: start; }
.steps-editor textarea { min-height: 40px; }

/* ---------- rodapé */
.site-footer { border-top: 1px solid var(--line); margin-top: 40px; padding: 26px 0; color: var(--muted); font-size: .88rem; }
.site-footer .bar { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; justify-content: space-between; }

/* ---------- responsivo */
@media (max-width: 960px) {
  .cols-4 { grid-template-columns: repeat(2,1fr); } .cols-3 { grid-template-columns: repeat(2,1fr); }
  .tool-layout { grid-template-columns: 1fr; } .sidebar { position: static; }
  .admin { grid-template-columns: 1fr; } .admin-side { position: fixed; z-index: 30; width: 250px; transform: translateX(-100%); transition: transform .2s; }
  .admin-side.open { transform: none; }
  .stat-row { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 680px) {
  .nav-links { position: fixed; inset: 64px 0 auto 0; background: var(--bg2); border-bottom: 1px solid var(--line); flex-direction: column; padding: 10px; display: none; }
  .nav-links.open { display: flex; } .nav-links a { width: 100%; }
  .menu-toggle { display: inline-flex; }
  .hero h1 { font-size: 2rem; } .hero p { font-size: 1rem; }
  .cols-4, .cols-3, .cols-2 { grid-template-columns: 1fr; }
  .steps-editor .srow { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: 1fr 1fr; }
}
