/* Rastro: base visual compartilhada (site, painel e admin) */
@font-face { font-family: 'Inter Tight'; src: url('/fonts/inter-tight-latin-wght-normal.woff2') format('woff2'); font-weight: 100 900; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter Tight'; src: url('/fonts/inter-tight-latin-ext-wght-normal.woff2') format('woff2'); font-weight: 100 900; font-display: swap; unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'JetBrains Mono'; src: url('/fonts/jetbrains-mono-latin-400-normal.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'JetBrains Mono'; src: url('/fonts/jetbrains-mono-latin-500-normal.woff2') format('woff2'); font-weight: 500; font-display: swap; }

:root {
  --bg: #0b0b0c;
  --bg-2: #0f0f11;
  --surface: #121214;
  --surface-2: #17171a;
  --surface-3: #1d1d21;
  --line: #232327;
  --line-2: #2e2e33;
  --text: #f4f4f5;
  --text-2: #c9c9cf;
  --muted: #8e8e96;
  --faint: #5d5d65;
  --pink: #ff0054;
  --pink-2: #e0004a;
  --pink-soft: rgba(255, 0, 84, .12);
  --green: #3dd68c;
  --green-soft: rgba(61, 214, 140, .12);
  --red: #ff6369;
  --red-soft: rgba(255, 99, 105, .12);
  --amber: #f5b544;
  --amber-soft: rgba(245, 181, 68, .13);
  --blue: #6aa8ff;
  --blue-soft: rgba(106, 168, 255, .13);
  --violet: #b18cff;
  --paper: #f3f2ee;
  --ink: #111113;
  --radius: 12px;
  --radius-sm: 8px;
  --font: 'Inter Tight', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.5 var(--font); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; font-feature-settings: 'ss01', 'cv11'; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; letter-spacing: -.02em; line-height: 1.15; font-weight: 650; }
p { margin: 0; }
::selection { background: var(--pink); color: #fff; }
:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; border-radius: 6px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.tnum { font-variant-numeric: tabular-nums; }
.ico { width: 18px; height: 18px; flex: none; }
.ico.sm { width: 15px; height: 15px; }
.ico.lg { width: 22px; height: 22px; }
.brand-ico { width: 18px; height: 18px; flex: none; }

/* botões */
.btn { --b: var(--surface-2); display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--b); color: var(--text); font-weight: 600; font-size: 14px; cursor: pointer; white-space: nowrap; transition: background .15s, border-color .15s, transform .15s var(--ease); text-decoration: none; }
.btn:hover { background: var(--surface-3); border-color: #3a3a40; }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--pink); border-color: var(--pink); color: #fff; }
.btn.primary:hover { background: var(--pink-2); border-color: var(--pink-2); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--text-2); }
.btn.ghost:hover { background: var(--surface-2); color: var(--text); }
.btn.danger { color: var(--red); }
.btn.danger:hover { border-color: var(--red); }
.btn.sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.btn.lg { height: 48px; padding: 0 22px; font-size: 15px; border-radius: 12px; }
.btn.block { width: 100%; }
.btn[disabled], .btn.disabled { opacity: .45; pointer-events: none; }
.link { color: var(--pink); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.link:hover { color: #ff3a7a; }

/* formulários */
.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field > label, .label { font-size: 13px; font-weight: 600; color: var(--text-2); }
.hint { font-size: 12.5px; color: var(--muted); }
.input, select.input, textarea.input { width: 100%; height: 42px; padding: 0 13px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 10px; color: var(--text); outline: none; transition: border-color .15s, box-shadow .15s; }
textarea.input { height: auto; min-height: 96px; padding: 11px 13px; resize: vertical; line-height: 1.5; }
.input::placeholder { color: var(--faint); }
.input:focus { border-color: var(--pink); box-shadow: 0 0 0 3px var(--pink-soft); }
select.input { appearance: none; padding-right: 36px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23a1a1aa' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 13px center; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--text-2); cursor: pointer; }
.check input { margin-top: 3px; accent-color: var(--pink); width: 16px; height: 16px; }
.row { display: flex; gap: 12px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 760px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }
.switch { position: relative; display: inline-flex; width: 38px; height: 22px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span { position: absolute; inset: 0; background: var(--line-2); border-radius: 99px; transition: background .2s; cursor: pointer; }
.switch span::after { content: ''; position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .2s var(--ease); }
.switch input:checked + span { background: var(--pink); }
.switch input:checked + span::after { transform: translateX(16px); }

/* selos */
.badge { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 9px; border-radius: 7px; font-size: 12.5px; font-weight: 600; background: var(--surface-3); color: var(--text-2); white-space: nowrap; }
.badge.dot::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.green { background: var(--green-soft); color: var(--green); }
.badge.red { background: var(--red-soft); color: var(--red); }
.badge.amber { background: var(--amber-soft); color: var(--amber); }
.badge.blue { background: var(--blue-soft); color: var(--blue); }
.badge.pink { background: var(--pink-soft); color: #ff4d86; }
.badge.gray { background: var(--surface-3); color: var(--muted); }

/* cartões e tabelas */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
.card-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 20px 20px 0; }
.card-h h2, .card-h h3 { font-size: 15px; font-weight: 650; letter-spacing: -.01em; }
.card-b { padding: 20px; }
.table-wrap { overflow-x: auto; }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; }
table.t th { text-align: left; font-weight: 500; color: var(--muted); font-size: 12.5px; padding: 12px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.t td { padding: 13px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.t tr:last-child td { border-bottom: 0; }
table.t tbody tr { transition: background .12s; }
table.t tbody tr.click { cursor: pointer; }
table.t tbody tr:hover { background: rgba(255, 255, 255, .018); }
table.t .r, .r { text-align: right; }
.empty { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 48px 20px; color: var(--muted); }
.empty h3 { color: var(--text); font-size: 17px; }
.empty .ico { width: 28px; height: 28px; color: var(--faint); }

.avatar { width: 32px; height: 32px; border-radius: 9px; background: var(--surface-3); display: grid; place-items: center; font-size: 12px; font-weight: 700; color: var(--text-2); flex: none; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.flash { padding: 12px 14px; border-radius: 10px; font-size: 14px; margin-bottom: 16px; border: 1px solid; }
.flash.ok { background: var(--green-soft); border-color: rgba(61, 214, 140, .3); color: #8ff0c0; }
.flash.err { background: var(--red-soft); border-color: rgba(255, 99, 105, .3); color: #ffb0b3; }
.flash.info { background: var(--blue-soft); border-color: rgba(106, 168, 255, .3); color: #b9d5ff; }
.kbd { font-family: var(--mono); font-size: 12px; padding: 2px 6px; border: 1px solid var(--line-2); border-radius: 6px; background: var(--bg-2); }
.code { font-family: var(--mono); font-size: 13px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 10px; padding: 12px 14px; overflow-x: auto; white-space: nowrap; color: var(--text-2); }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; } }
[hidden] { display: none !important; }
.card { min-width: 0; }
.card-b > *, .row > .grow { min-width: 0; }
.hint code, .hint .kbd { white-space: normal; overflow-wrap: anywhere; }
