:root {
  --ink: #071b2f;
  --black: #151515;
  --black-2: #1f1f1f;
  --navy: #062b4f;
  --navy-2: #0b416f;
  --cyan: #05e5ed;
  --green: #00f230;
  --green-2: #00c72a;
  --mint: #dff8ec;
  --paper: #ffffff;
  --surface: #f5f8fb;
  --surface-2: #edf4f8;
  --line: #d9e5ed;
  --line-strong: #bfd2df;
  --text: #13283d;
  --muted: #627589;
  --danger: #b8333a;
  --warning: #b66a00;
  --shadow-sm: 0 8px 24px rgba(7, 27, 47, 0.08);
  --shadow-md: 0 22px 58px rgba(7, 27, 47, 0.18);
  --glow: 0 0 26px rgba(0, 242, 48, 0.36);
  --radius: 8px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  color: var(--text);
  background: #f7f7f5;
  font-size: 15px;
}

a { color: inherit; text-decoration: none; }

button,
input,
select,
textarea { font: inherit; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: #080808;
  border-top: 4px solid var(--green);
  border-bottom: 1px solid rgba(0, 229, 237, 0.18);
}

.topbar-inner {
  width: min(1180px, 100%);
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  gap: 18px;
  min-height: 128px;
  margin: 0 auto;
  padding: 13px clamp(18px, 4vw, 58px) 22px;
}

.admin-toplink {
  position: absolute;
  top: 18px;
  right: clamp(18px, 4vw, 58px);
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.82);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(5, 229, 237, 0.34);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: color 0.16s ease, border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.admin-toplink:hover {
  color: #071507;
  background: var(--green);
  border-color: var(--green);
  box-shadow: 0 0 18px rgba(0, 242, 48, 0.28);
}

.is-admin-route .admin-toplink {
  display: none;
}

.is-admin-route .topbar {
  display: none;
}

.is-admin-route main {
  min-height: 100vh;
}

.admin-lock {
  width: 12px;
  height: 10px;
  position: relative;
  display: inline-block;
  border: 2px solid currentColor;
  border-radius: 2px;
}

.admin-lock::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -9px;
  width: 10px;
  height: 9px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  transform: translateX(-50%);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0;
  min-width: 0;
}

.brand img {
  width: 246px;
  max-height: 70px;
  object-fit: contain;
  filter: drop-shadow(0 8px 18px rgba(0, 229, 237, 0.12));
}

nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: clamp(16px, 3vw, 38px);
  padding-bottom: 16px;
}

nav a {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  position: relative;
  padding: 0 2px;
  border-radius: 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  transition: color 0.16s ease, text-shadow 0.16s ease;
}

nav a:hover,
nav a.is-active {
  color: #fff;
  background: transparent;
}

nav a.is-active {
  color: var(--cyan);
  text-shadow: 0 0 14px rgba(5, 229, 237, 0.22);
}

nav a::after {
  content: "";
  position: absolute;
  left: 50%;
  top: -12px;
  width: 0;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--green), var(--cyan));
  transform: translateX(-50%);
  transition: width 0.16s ease;
}

nav a:hover::after,
nav a.is-active::after {
  width: 30px;
}

nav a::before {
  display: none;
  content: none;
}

nav a:hover::before {
  opacity: 0;
}

main { min-height: calc(100vh - 128px); }

.hero {
  color: #fff;
  background:
    linear-gradient(120deg, rgba(0, 0, 0, 0.86) 0%, rgba(18, 18, 18, 0.94) 45%, rgba(28, 28, 28, 0.98) 100%),
    radial-gradient(circle at 78% 38%, rgba(0, 229, 237, 0.14), transparent 34%),
    radial-gradient(circle at 58% 70%, rgba(0, 242, 48, 0.12), transparent 36%),
    #151515;
  border-bottom: 1px solid #e8e8e8;
}

.hero-inner {
  width: min(980px, calc(100% - 36px));
  min-height: 520px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  justify-items: center;
  padding: clamp(46px, 7vw, 82px) 0 clamp(58px, 8vw, 96px);
  text-align: center;
}

.eyebrow {
  margin: 0 0 16px;
  color: var(--cyan);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.36em;
  text-transform: uppercase;
}

.eyebrow.dark { color: var(--cyan); }

.hero h1 {
  max-width: 920px;
  margin: 0;
  color: var(--green);
  font-size: clamp(3.6rem, 7.2vw, 6.7rem);
  line-height: 1.05;
  letter-spacing: 0;
  text-transform: uppercase;
}

.lead {
  max-width: 760px;
  margin: 26px auto 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(0.98rem, 1.55vw, 1.1rem);
  font-weight: 700;
  line-height: 1.75;
}

.hero-actions,
.actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 34px;
}

.btn,
button {
  border: 0;
  border-radius: 7px;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 20px;
  color: var(--text);
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.hero-actions .primary {
  min-height: 58px;
  padding: 0 34px;
  font-size: 1.02rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-actions .secondary {
  min-height: 54px;
  padding: 0 28px;
}

.btn:hover,
button:hover {
  transform: translateY(-1px);
}

button:disabled {
  cursor: wait;
  opacity: 0.72;
  transform: none;
}

.btn-icon {
  width: 22px;
  height: 22px;
  display: inline-grid;
  place-items: center;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.22);
  font-weight: 900;
}

.primary {
  color: #071507;
  background: var(--green);
  box-shadow: 0 12px 24px rgba(0, 242, 48, 0.18);
}

.secondary {
  color: #111;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 0 22px rgba(255, 235, 0, 0.2);
}

.ghost {
  color: var(--navy);
  background: #e7f0f6;
  border: 1px solid #ccdae5;
}

.danger {
  color: var(--danger);
  background: #fff0f1;
  border: 1px solid #f0c8cc;
}

.section-title-home,
.trust-band,
.process-strip,
.policy-callout,
.content {
  width: min(1220px, calc(100% - 36px));
  margin: 0 auto;
}

.section-title-home {
  padding: 56px 0 28px;
  text-align: center;
}

.section-title-home p {
  margin: 0 0 18px;
  color: #050505;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.36em;
  text-transform: uppercase;
}

.section-title-home h2 {
  max-width: 1080px;
  margin: 0 auto;
  color: #050505;
  font-size: clamp(2.25rem, 4.8vw, 4.1rem);
  line-height: 1.08;
}

.section-title-home h2::first-letter {
  color: var(--cyan);
}

.trust-band {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 40px;
  overflow: visible;
  margin-top: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.trust-band article {
  min-height: 410px;
  position: relative;
  overflow: hidden;
  padding: 48px 44px 42px;
  border-radius: 8px;
  background: var(--black-2);
  box-shadow: 0 20px 42px rgba(0, 0, 0, 0.12);
}

.trust-band article::after {
  content: "0" counter(card);
  counter-increment: card;
  position: absolute;
  right: 28px;
  top: 64px;
  color: rgba(255, 255, 255, 0.04);
  font-size: 6.6rem;
  font-weight: 900;
  line-height: 1;
}

.trust-band { counter-reset: card; }

.line-icon {
  width: 64px;
  height: 64px;
  display: inline-grid;
  place-items: center;
  position: relative;
  margin-bottom: 22px;
  border-radius: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.line-icon svg {
  width: 58px;
  height: 58px;
  overflow: visible;
  fill: none;
  stroke: var(--cyan);
  stroke-width: 3.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 10px rgba(5, 229, 237, 0.24));
}

.trust-band h2,
.policy-callout h2,
.content h1,
.panel h1,
.panel h2,
.record h3 {
  margin: 0;
  color: var(--ink);
  letter-spacing: 0;
}

.trust-band h2 {
  color: var(--green);
  font-size: 1.38rem;
}

.trust-band h2::before {
  content: "";
  display: inline-block;
  width: 3px;
  height: 19px;
  margin-right: 12px;
  vertical-align: -3px;
  background: var(--cyan);
}

.trust-band p {
  color: rgba(255, 255, 255, 0.88);
  font-weight: 700;
}

.policy-callout p,
.content-head p,
.hint,
.muted {
  color: var(--muted);
}

p { line-height: 1.62; }

.process-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  padding: 34px 0 0;
}

.process-strip div {
  padding: 18px 18px 20px;
  border-left: 3px solid var(--cyan);
  background: #fff;
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.06);
}

.process-strip span {
  display: block;
  margin-bottom: 10px;
  color: var(--cyan);
  font-size: 0.76rem;
  font-weight: 900;
}

.process-strip b {
  color: #111;
}

.policy-callout {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 34px;
  margin-bottom: 52px;
  padding: 30px;
  border-radius: var(--radius);
  background:
    linear-gradient(90deg, #ffffff, #f7f7f5);
  border: 1px solid #e3e3df;
}

.policy-callout h2 {
  max-width: 840px;
  margin: 0 auto;
  text-align: center;
  font-size: clamp(1.35rem, 2vw, 2rem);
  line-height: 1.24;
}

.policy-callout .eyebrow {
  text-align: center;
}

.admin-link {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 15px;
  border-radius: 7px;
  color: #111;
  background: linear-gradient(90deg, var(--green), var(--cyan));
  border: 0;
  font-weight: 800;
  white-space: nowrap;
}

.content {
  padding: 38px 0 56px;
}

.content-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.content-head h1 {
  font-size: clamp(1.8rem, 3vw, 2.55rem);
}

.content-head p {
  max-width: 720px;
  margin: 8px 0 0;
}

.panel,
.metric,
.record,
.choice {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow-sm);
}

.panel {
  padding: clamp(20px, 3vw, 30px);
}

.choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.choice {
  position: relative;
  min-height: 220px;
  padding: 28px;
  text-align: left;
}

.choice::before {
  content: "";
  width: 48px;
  height: 48px;
  display: block;
  margin-bottom: 22px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--mint), #f3fbf7);
  border: 1px solid #c4ebd7;
}

.choice::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  left: 44px;
  top: 44px;
  border-radius: 50%;
  border: 3px solid var(--green-2);
}

.choice:hover {
  border-color: #9edabb;
  box-shadow: var(--shadow-md);
}

.choice strong {
  display: block;
  margin-bottom: 10px;
  color: var(--ink);
  font-size: 1.32rem;
}

.choice span {
  color: var(--muted);
  line-height: 1.6;
}

.form-shell {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 22px;
}

.form-aside {
  padding: 22px;
  border-radius: var(--radius);
  color: #fff;
  background: linear-gradient(180deg, var(--navy), #08243e);
  align-self: start;
}

.form-aside b {
  display: block;
  margin-bottom: 12px;
  font-size: 1.08rem;
}

.form-aside p {
  margin: 0 0 18px;
  color: rgba(255, 255, 255, 0.74);
}

.aside-step {
  display: flex;
  gap: 10px;
  padding: 12px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.78);
  font-weight: 700;
}

.aside-step span {
  color: #9fe8c2;
  font-weight: 900;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.section-title {
  grid-column: 1 / -1;
  margin: 10px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 900;
  text-transform: uppercase;
}

.full { grid-column: 1 / -1; }

label {
  display: grid;
  gap: 8px;
  color: var(--navy);
  font-size: 0.9rem;
  font-weight: 800;
}

input,
select,
textarea {
  width: 100%;
  min-height: 46px;
  padding: 11px 13px;
  border: 1px solid #c8d7e2;
  border-radius: 7px;
  background: #fff;
  color: var(--text);
  outline: none;
}

textarea {
  min-height: 138px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--green-2);
  box-shadow: 0 0 0 4px rgba(25, 181, 107, 0.14);
}

.checkbox {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 14px;
  border-radius: 7px;
  color: var(--text);
  background: #f6fafc;
  border: 1px solid var(--line);
}

.checkbox input {
  width: 20px;
  min-height: 20px;
  margin-top: 1px;
}

.hint {
  margin: 0;
  font-size: 0.92rem;
}

.error {
  color: var(--danger);
  font-weight: 800;
}

.success {
  color: var(--green-2);
  font-weight: 900;
}

.protocol {
  display: inline-flex;
  align-items: center;
  min-height: 54px;
  padding: 0 18px;
  border-radius: 8px;
  color: var(--ink);
  background: var(--mint);
  border: 1px solid #bce8d0;
  font-size: clamp(1.08rem, 3vw, 1.55rem);
  font-weight: 900;
  letter-spacing: 0;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.result-item {
  padding: 14px;
  border-radius: 7px;
  background: #f7fbfd;
  border: 1px solid var(--line);
}

.result-item b {
  display: block;
  margin-bottom: 6px;
  color: var(--navy);
}

.public-timeline {
  display: grid;
  gap: 0;
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.timeline-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.timeline-head .eyebrow {
  margin: 0;
}

.timeline-head span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.timeline-item {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 14px;
  position: relative;
  padding: 0 0 18px;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 20px;
  bottom: -2px;
  width: 2px;
  background: #d9e5ed;
}

.timeline-item:last-child::before {
  display: none;
}

.timeline-dot {
  width: 22px;
  height: 22px;
  margin-top: 2px;
  border-radius: 50%;
  background: #fff;
  border: 4px solid var(--cyan);
  box-shadow: 0 0 0 5px rgba(5, 229, 237, 0.12);
}

.timeline-item.is-current .timeline-dot {
  border-color: var(--green);
  box-shadow: 0 0 0 5px rgba(0, 242, 48, 0.14);
}

.timeline-item strong {
  display: block;
  color: var(--ink);
  font-size: 1rem;
}

.timeline-item time {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.timeline-item p {
  margin: 7px 0 0;
  color: var(--text);
}

.admin-shell {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  min-height: 100vh;
  align-self: start;
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 28px;
  color: #fff;
  background:
    linear-gradient(180deg, #061f36, var(--navy) 58%, #082238),
    linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  align-items: center;
  gap: 13px;
}

.sidebar-brand > span {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #071507;
  background: var(--green);
  font-weight: 900;
  box-shadow: 0 0 22px rgba(0, 242, 48, 0.22);
}

.sidebar h2 {
  margin: 0 0 4px;
  color: #fff;
  font-size: 1.35rem;
}

.sidebar p {
  margin: 0;
  color: rgba(255, 255, 255, 0.68);
}

.sidebar-summary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.sidebar-summary div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 50px;
  padding: 0 14px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-summary strong {
  color: var(--green);
  font-size: 1.25rem;
}

.sidebar-summary span,
.sidebar-flow span {
  color: rgba(255, 255, 255, 0.8);
  font-weight: 800;
}

.sidebar-flow {
  display: grid;
  gap: 10px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.sidebar-flow b {
  margin-bottom: 2px;
  color: #fff;
}

.sidebar-flow span {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sidebar-flow i {
  min-width: 28px;
  color: var(--cyan);
  font-style: normal;
  font-weight: 900;
}

.sidebar .ghost {
  width: 100%;
  margin-top: auto;
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.18);
}

.admin-main {
  padding: clamp(20px, 3vw, 34px);
  overflow: auto;
}

.admin-head {
  align-items: stretch;
}

.admin-head-note {
  max-width: 330px;
  padding: 16px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}

.admin-head-note b {
  display: block;
  margin-bottom: 6px;
  color: var(--ink);
}

.admin-head-note span {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.5;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(6, minmax(120px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.metric {
  position: relative;
  overflow: hidden;
  padding: 17px;
}

.metric::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 3px;
  background: linear-gradient(90deg, var(--green), transparent);
}

.metric strong {
  display: block;
  color: var(--ink);
  font-size: 1.8rem;
  line-height: 1;
}

.metric span {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.filters {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.bot-panel {
  margin-bottom: 16px;
}

.bot-panel[open] {
  box-shadow: var(--shadow-md);
}

.bot-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
  list-style: none;
}

.bot-summary::-webkit-details-marker {
  display: none;
}

.bot-summary .eyebrow {
  margin-bottom: 8px;
}

.bot-summary h2 {
  margin: 0;
  color: var(--ink);
}

.bot-summary span {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 0 14px;
  border-radius: 7px;
  color: #071507;
  background: var(--green);
  font-weight: 900;
}

.bot-panel[open] .bot-summary {
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.bot-panel[open] .bot-summary span {
  background: #e7f0f6;
  color: var(--navy);
  font-size: 0;
}

.bot-panel[open] .bot-summary span::after {
  content: "Fechar";
  font-size: 0.9rem;
}

.bot-body {
  padding-top: 16px;
}

.bot-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.bot-head h2,
.bot-form h3 {
  margin: 0;
  color: var(--ink);
}

.bot-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.bot-grid.alert-only {
  grid-template-columns: minmax(280px, 520px);
}

.bot-form {
  display: grid;
  gap: 11px;
  align-content: start;
  padding: 16px;
  border-radius: 8px;
  background: #f7fbfd;
  border: 1px solid var(--line);
}

.bot-form .primary {
  width: 100%;
  min-height: 42px;
}

.mini-list {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

.mini-list.horizontal {
  display: flex;
  flex-wrap: wrap;
}

.mini-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 10px;
  border-radius: 7px;
  background: #fff;
  border: 1px solid var(--line);
}

.mini-row strong,
.mini-row span {
  display: block;
}

.mini-row span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.82rem;
  overflow-wrap: anywhere;
}

.mini-action {
  min-height: 34px;
  padding: 0 10px;
  font-size: 0.78rem;
}

.mini-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.bot-foot {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.compact-history > details > summary {
  cursor: pointer;
  color: var(--navy);
  font-weight: 900;
}

.compact-history .mini-list {
  margin-top: 10px;
}

.bot-foot b {
  display: block;
  margin-bottom: 8px;
  color: var(--ink);
}

.admin-detail-anchor {
  scroll-margin-top: 18px;
}

.records {
  display: grid;
  gap: 10px;
}

.record {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 16px;
}

.record h3 {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 7px;
  font-size: 1.05rem;
}

.record p {
  margin: 0 0 10px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  color: var(--navy);
  background: #e7f0f6;
  border: 1px solid #cfdeea;
  font-size: 0.78rem;
  font-weight: 900;
}

.tag.risk {
  color: #7b4100;
  background: #fff2df;
  border-color: #f3d4a9;
}

.tag.severity-low {
  color: #0f5a35;
  background: #e6f8ee;
  border-color: #bfe8d0;
}

.tag.severity-medium {
  color: #665100;
  background: #fff8d7;
  border-color: #eadc89;
}

.tag.severity-high {
  color: #8a3500;
  background: #fff0df;
  border-color: #efc49a;
}

.tag.severity-critical {
  color: #8d1620;
  background: #fff0f2;
  border-color: #edb8bf;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.85fr);
  gap: 16px;
}

.history {
  display: grid;
  gap: 10px;
}

.history-item {
  padding: 14px;
  border-radius: 7px;
  background: #f7fbfd;
  border: 1px solid var(--line);
  border-left: 4px solid var(--green);
}

.history-item p {
  margin: 8px 0 0;
}

.attachments {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.attachments a {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 6px;
  color: var(--navy);
  background: #e7f0f6;
  font-weight: 800;
}

@media (max-width: 1080px) {
  .hero-inner,
  .admin-shell,
  .detail-grid,
  .form-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    min-height: auto;
  }

  .sidebar-summary {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .sidebar .ghost {
    margin-top: 0;
  }

  .metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .topbar-inner {
    align-items: center;
    flex-direction: column;
    gap: 14px;
    min-height: 126px;
    padding: 12px 14px 18px;
  }

  .admin-toplink {
    position: absolute;
    top: 12px;
    right: 12px;
    min-height: 34px;
    margin-top: 0;
    padding: 0 12px;
    font-size: 0.58rem;
  }

  .brand img {
    width: 190px;
  }

  nav {
    width: 100%;
    overflow: visible;
    justify-content: center;
    gap: 12px;
    padding-bottom: 0;
    order: 2;
  }

  nav a {
    white-space: nowrap;
    min-height: 32px;
  }

  .hero-inner {
    min-height: auto;
    padding: 44px 0 72px;
  }

  .trust-band,
  .process-strip,
  .choice-grid,
  .form-grid,
  .result-grid {
    grid-template-columns: 1fr;
  }

  .trust-band {
    gap: 18px;
  }

  .policy-callout,
  .content-head {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: stretch;
  }

  .admin-head-note {
    max-width: none;
  }

  .filters {
    grid-template-columns: 1fr 1fr;
  }

  .bot-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  body { font-size: 14px; }

  .topbar {
    position: sticky;
  }

  .topbar-inner {
    min-height: auto;
    padding-bottom: 16px;
  }

  .brand img {
    width: 168px;
  }

  .admin-toplink span:last-child {
    display: none;
  }

  .admin-toplink {
    width: 38px;
    justify-content: center;
    padding: 0;
  }

  .hero h1 {
    font-size: clamp(2.35rem, 13vw, 3rem);
  }

  nav a {
    font-size: 0.64rem;
    letter-spacing: 0.12em;
  }

  nav {
    gap: 9px;
  }

  .hero-actions,
  .actions {
    flex-direction: column;
  }

  .btn,
  button {
    width: 100%;
  }

  .metrics,
  .sidebar-summary,
  .filters,
  .record {
    grid-template-columns: 1fr;
  }

  .hero-brief,
  .panel,
  .policy-callout,
  .trust-band article,
  .choice {
    padding: 20px;
  }

  .content,
  .section-title-home,
  .trust-band,
  .process-strip,
  .policy-callout {
    width: min(100% - 24px, 1220px);
  }

  .section-title-home {
    padding-top: 38px;
  }

  .section-title-home h2 {
    font-size: clamp(1.75rem, 10vw, 2.45rem);
  }

  .trust-band article {
    min-height: auto;
  }

  .form-aside {
    padding: 18px;
  }

  .aside-step {
    padding: 10px 0;
  }

  input,
  select,
  textarea {
    min-height: 50px;
    font-size: 16px;
  }
}
