:root {
  --ink: #14181f;
  --ink-soft: #3d4756;
  --muted: #6b7687;
  --line: #c9d2dd;
  --line-strong: #9aabc0;
  --paper: #edf1f5;
  --surface: #f8fafc;
  --accent: #c45e12;
  --accent-ink: #3a1a05;
  --ok: #0f6b4c;
  --ok-soft: #d7f0e6;
  --danger: #a11d2e;
  --danger-soft: #f8d9de;
  --secret: #0b4a3d;
  --secret-soft: #d5f2ea;
  --display: "Fraunces", "Iowan Old Style", "Palatino Linotype", serif;
  --sans: "Public Sans", "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", "Cascadia Code", ui-monospace, monospace;
  --radius: 4px;
  --shadow: 0 1px 0 rgba(20, 24, 31, 0.04);
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  font-size: 15.5px;
  line-height: 1.5;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(1200px 480px at 8% -10%, rgba(196, 94, 18, 0.12), transparent 55%),
    radial-gradient(900px 520px at 100% 0%, rgba(20, 70, 110, 0.1), transparent 50%),
    linear-gradient(180deg, #f4f7fa 0%, var(--paper) 42%, #e7ecf2 100%);
  background-attachment: fixed;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.18;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
  z-index: 0;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.topbar,
.container,
.footer,
.login-shell {
  position: relative;
  z-index: 1;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 0.85rem clamp(1rem, 4vw, 3rem);
  border-bottom: 1px solid var(--line);
  background: rgba(248, 250, 252, 0.92);
  backdrop-filter: blur(12px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.03em;
}

.brand-mark {
  width: 1.7rem;
  height: 1.7rem;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: var(--surface);
  font-family: var(--sans);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.topbar nav {
  display: flex;
  gap: 1.25rem;
  flex: 1;
  min-width: 0;
}

.topbar > form {
  margin-left: auto;
  flex-shrink: 0;
}

.topbar nav a {
  color: var(--ink-soft);
  font-weight: 500;
  font-size: 0.92rem;
  position: relative;
  padding: 0.2rem 0;
}

.topbar nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -0.15rem;
  height: 2px;
  background: var(--accent);
  transition: right 180ms ease;
}

.topbar nav a:hover { color: var(--ink); }
.topbar nav a:hover::after { right: 0; }

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 2.4rem clamp(1rem, 4vw, 3rem) 1rem;
}

.footer {
  max-width: 1180px;
  margin: 2.5rem auto 0;
  padding: 1.25rem clamp(1rem, 4vw, 3rem) 2rem;
  color: var(--muted);
  font-size: 0.8rem;
  border-top: 1px solid var(--line);
}

.hero,
.page-head {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  align-items: end;
  margin-bottom: 2rem;
  animation: rise 520ms ease both;
}

.hero h1,
.page-head h1 {
  font-family: var(--display);
  font-size: clamp(2.1rem, 4.4vw, 3.5rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
  font-weight: 700;
  margin: 0.35rem 0 0.75rem;
}

.hero p,
.page-head p,
.muted {
  color: var(--muted);
  max-width: 42rem;
  margin: 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
}

.eyebrow::before {
  content: "";
  width: 0.45rem;
  height: 0.45rem;
  background: var(--accent);
  border-radius: 1px;
  animation: pulse 1.8s ease-in-out infinite;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin-bottom: 2.2rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  animation: rise 620ms ease both;
  animation-delay: 60ms;
}

.stats article {
  padding: 1.35rem 0.2rem 1.5rem;
  border-right: 1px solid var(--line);
  background: transparent;
}

.stats article:last-child { border-right: 0; }

.stats strong {
  display: block;
  font-family: var(--display);
  font-size: clamp(2.2rem, 3.5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
  margin-bottom: 0.45rem;
}

.stats span {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 500;
}

.panel {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
  border-radius: var(--radius);
  padding: 1.25rem 1.3rem;
  animation: rise 640ms ease both;
}

.panel h2,
.panel-head h2 {
  margin: 0 0 1rem;
  font-family: var(--display);
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

.panel-head,
.row,
.copy-line,
.actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1rem;
}

.cards { display: grid; gap: 0.75rem; }

.provider-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem;
  display: grid;
  gap: 0.85rem;
  background: #fff;
}

.badge {
  font-size: 0.68rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.18rem 0.45rem;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink-soft);
  border-radius: 2px;
}

.badge.ok {
  background: var(--ok-soft);
  border-color: #9ed6c0;
  color: var(--ok);
}

.stack { display: grid; gap: 1rem; }

label {
  display: grid;
  gap: 0.4rem;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--ink-soft);
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  padding: 0.72rem 0.8rem;
  font: inherit;
  outline: none;
  transition: border-color 140ms ease, box-shadow 140ms ease;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(196, 94, 18, 0.15);
}

textarea {
  font-family: var(--mono);
  font-size: 0.8rem;
  line-height: 1.45;
}

.check {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 500;
}

.check input { width: auto; }

fieldset {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.85rem;
}

legend {
  padding: 0 0.4rem;
  color: var(--ink-soft);
  font-weight: 600;
}

.hint,
.alert,
.secret-box {
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
}

.hint {
  background: var(--paper);
  border: 1px dashed var(--line-strong);
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 500;
}

.alert {
  background: var(--danger-soft);
  border: 1px solid #e7a8b1;
  color: var(--danger);
  margin-bottom: 1rem;
  font-weight: 600;
}

.secret-box {
  background: var(--secret-soft);
  border: 1px solid #8fceb8;
  color: var(--secret);
  margin-bottom: 1rem;
}

.secret-box code { word-break: break-all; }

.table-wrap { overflow: auto; }

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  text-align: left;
  padding: 0.8rem 0.55rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.88rem;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

code {
  font-family: var(--mono);
  font-size: 0.84em;
  color: #0d5c4a;
}

button,
.button,
a.button {
  border: 0;
  border-radius: var(--radius);
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  padding: 0.72rem 1.05rem;
  cursor: pointer;
  font: inherit;
  transition: transform 140ms ease, filter 140ms ease, background 140ms ease;
  text-decoration: none;
}

button:hover,
.button:hover,
a.button:hover { filter: brightness(1.05); }

button:active,
.button:active,
a.button:active { transform: translateY(1px); }

.button,
a.button { display: inline-flex; align-items: center; }

button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  filter: none;
  transform: none;
}

.secondary {
  background: var(--ink);
  color: #fff;
}

.ghost {
  background: transparent;
  color: var(--ink-soft);
  border: 1px solid var(--line-strong);
}

.danger {
  background: var(--danger);
  color: #fff;
}

.upload-panel { margin-bottom: 1.2rem; }

.upload-form {
  display: grid;
  grid-template-columns: 1fr 1fr 2fr auto;
  gap: 0.85rem;
  align-items: end;
}

.asset-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 0.4rem;
}

.asset-card {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  animation: rise 700ms ease both;
}

.asset-card img {
  width: 100%;
  height: 168px;
  object-fit: cover;
  background: #d9e1ea;
}

.asset-body {
  padding: 0.95rem;
  display: grid;
  gap: 0.65rem;
}

.asset-body > strong {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 0.95rem;
}

.asset-body small { color: var(--muted); }

.copy-line input { min-width: 0; }

.empty {
  grid-column: 1 / -1;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: 3rem 1.5rem;
  text-align: center;
  color: var(--muted);
  background: rgba(248, 250, 252, 0.7);
}

.empty h3 {
  margin: 0 0 0.4rem;
  font-family: var(--display);
  color: var(--ink);
}

.login-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 460px);
  align-items: stretch;
}

.login-stage {
  position: relative;
  display: grid;
  align-content: end;
  padding: clamp(2rem, 6vw, 4.5rem);
  color: #f4f7fa !important;
  overflow: hidden;
  background:
    linear-gradient(160deg, rgba(12, 18, 28, 0.15), rgba(12, 18, 28, 0.72)),
    radial-gradient(900px 500px at 20% 20%, rgba(196, 94, 18, 0.5), transparent 55%),
    linear-gradient(145deg, #243246 0%, #121925 52%, #1f332c 100%);
}

.login-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      -18deg,
      transparent 0 14px,
      rgba(255, 255, 255, 0.025) 14px 15px
    );
  pointer-events: none;
}

.login-stage-inner {
  position: relative;
  z-index: 1;
  max-width: 34rem;
  animation: rise 700ms ease both;
}

.login-stage .eyebrow {
  color: #f0a56a;
}

.login-stage .eyebrow::before {
  background: #f0a56a;
}

.login-stage .brand-word {
  font-family: var(--display);
  font-size: clamp(3rem, 7vw, 5.4rem);
  line-height: 0.92;
  letter-spacing: -0.05em;
  margin: 0.4rem 0 1rem;
  font-weight: 700;
  color: #f7fafc;
}

.login-stage p {
  margin: 0;
  color: rgba(247, 250, 252, 0.9);
  font-size: 1.05rem;
  max-width: 28rem;
}

.login-panel {
  display: grid;
  place-items: center;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  background: rgba(248, 250, 252, 0.92);
  border-left: 1px solid var(--line);
}

.login-card {
  width: min(380px, 100%);
  animation: rise 620ms ease both;
  animation-delay: 80ms;
}

.login-card h2 {
  font-family: var(--display);
  font-size: 1.85rem;
  letter-spacing: -0.03em;
  margin: 0 0 0.35rem;
}

.login-card > p {
  margin: 0 0 1.4rem;
  color: var(--muted);
}

.login-card .stack { margin-top: 0.4rem; }

.login-card button { width: 100%; margin-top: 0.35rem; }

.login-meta {
  margin-top: 1.4rem;
  font-size: 0.78rem;
  color: var(--muted);
}

/* —— Admin console shell —— */
body:has(.admin-shell) {
  background: #e4e9ef;
  background-attachment: initial;
}

body:has(.admin-shell)::before {
  display: none;
}

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

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.1rem 0.9rem 1rem;
  background: #151a22;
  color: #e8eef6;
  border-right: 1px solid #0d1117;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.35rem 0.45rem 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand .brand-mark {
  background: var(--accent);
  color: #fff;
}

.sidebar-brand strong {
  display: block;
  font-family: var(--display);
  font-size: 1rem;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.sidebar-brand small {
  color: rgba(232, 238, 246, 0.55);
  font-size: 0.72rem;
}

.sidebar-nav {
  display: grid;
  gap: 0.2rem;
  flex: 1;
  align-content: start;
}

.sidebar-label {
  margin: 0.85rem 0.55rem 0.35rem;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(232, 238, 246, 0.42);
  font-weight: 700;
}

.sidebar-nav a {
  display: block;
  padding: 0.62rem 0.7rem;
  border-radius: 3px;
  color: rgba(232, 238, 246, 0.78);
  font-weight: 560;
  font-size: 0.92rem;
}

.sidebar-nav a:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
}

.sidebar-nav a.is-active {
  background: rgba(196, 94, 18, 0.22);
  color: #fff;
  box-shadow: inset 3px 0 0 var(--accent);
}

.sidebar-foot {
  display: grid;
  gap: 0.65rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-user {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.2rem 0.35rem;
}

.sidebar-user-mark {
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border-radius: 3px;
  background: #2a3340;
  font-weight: 700;
  font-size: 0.85rem;
}

.sidebar-user strong {
  display: block;
  font-size: 0.78rem;
  line-height: 1.2;
  word-break: break-all;
}

.sidebar-user small {
  color: rgba(232, 238, 246, 0.5);
  font-size: 0.7rem;
}

.sidebar-logout {
  width: 100%;
  border-color: rgba(255, 255, 255, 0.18);
  color: #d7deea;
}

.sidebar-logout:hover {
  filter: none;
  background: rgba(255, 255, 255, 0.06);
}

.admin-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: #e8edf3;
}

.admin-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 1.35rem;
  background: #f7f9fb;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}

.admin-top-kicker {
  margin: 0;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
}

.admin-top-title {
  margin: 0.15rem 0 0;
  font-weight: 700;
  font-size: 1rem;
}

.admin-top-actions {
  display: flex;
  gap: 0.5rem;
}

.admin-content {
  flex: 1;
  padding: 1.25rem 1.35rem 2rem;
  max-width: 1200px;
  width: 100%;
}

.admin-footer {
  padding: 0.85rem 1.35rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.75rem;
  background: #f3f6f9;
}

.admin-page-head {
  margin-bottom: 1.1rem;
}

.admin-page-head h1 {
  margin: 0 0 0.3rem;
  font-family: var(--sans);
  font-size: 1.45rem;
  letter-spacing: -0.02em;
  font-weight: 750;
}

.admin-page-head p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  max-width: 46rem;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.kpi {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.95rem 1rem;
}

.kpi-label {
  display: block;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 0.45rem;
}

.kpi-value {
  font-family: var(--sans);
  font-size: 1.85rem;
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1;
}

.panel-dense {
  padding: 0.95rem 1rem 1.05rem;
  animation: none;
}

.panel-dense .panel-head {
  justify-content: space-between;
  margin-bottom: 0.75rem;
  gap: 0.75rem;
}

.panel-dense .panel-head h2 {
  margin: 0;
  font-family: var(--sans);
  font-size: 0.98rem;
  font-weight: 750;
}

.panel-meta {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 550;
}

.table-admin th,
.table-admin td {
  padding: 0.65rem 0.5rem;
  font-size: 0.84rem;
}

.table-admin tbody tr:hover {
  background: #f3f6f9;
}

.table-empty {
  color: var(--muted);
  text-align: center;
  padding: 1.4rem 0.5rem !important;
}

.admin-shell .asset-card,
.admin-shell .provider-card {
  animation: none;
}

.admin-shell .panel {
  animation: none;
}

.field-hint {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--muted);
}

.form-polished label {
  gap: 0.35rem;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0 0 1rem;
}

.chip {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.7rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: #fff;
  color: var(--ink-soft);
  font-size: 0.82rem;
  font-weight: 600;
}

.chip:hover { border-color: var(--accent); color: var(--ink); }

.chip.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

.upload-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

.dropzone {
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius);
  background: #f3f6f9;
  padding: 1.6rem 1rem;
  text-align: center;
  cursor: pointer;
  transition: border-color 140ms ease, background 140ms ease;
}

.dropzone:hover,
.dropzone.is-dragover {
  border-color: var(--accent);
  background: #fff7f0;
}

.dropzone.has-file {
  border-style: solid;
  border-color: var(--ok);
  background: var(--ok-soft);
}

.dropzone-title {
  margin: 0 0 0.35rem;
  font-weight: 700;
}

.dropzone-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.asset-thumb {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #d9e1ea;
  cursor: zoom-in;
}

.asset-thumb img {
  width: 100%;
  height: 168px;
  object-fit: cover;
}

.button-link {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 0.8rem;
  text-decoration: none;
}

.help-dialog,
.lightbox-dialog {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0;
  max-width: min(640px, 94vw);
  width: 100%;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 24px 60px rgba(20, 24, 31, 0.2);
}

.help-dialog::backdrop,
.lightbox-dialog::backdrop {
  background: rgba(12, 16, 24, 0.55);
}

.help-dialog-inner,
.lightbox-inner {
  margin: 0;
  padding: 1rem 1.1rem 1.2rem;
  display: grid;
  gap: 0.85rem;
}

.help-dialog-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 1rem;
}

.help-dialog-head h2 {
  margin: 0.2rem 0 0;
  font-family: var(--sans);
  font-size: 1.2rem;
}

.help-lead {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.help-steps {
  margin: 0;
  padding-left: 1.15rem;
  display: grid;
  gap: 0.35rem;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.help-block h3 {
  margin: 0 0 0.35rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.help-block pre,
.docs-panel pre {
  margin: 0;
  padding: 0.75rem 0.85rem;
  background: #11161f;
  color: #d7e6df;
  border-radius: var(--radius);
  overflow: auto;
  font-size: 0.78rem;
  line-height: 1.45;
}

.lightbox-dialog {
  max-width: min(720px, 94vw);
}

.lightbox-dialog img {
  width: 100%;
  max-height: 55vh;
  object-fit: contain;
  background: #0f141c;
  border-radius: var(--radius);
}

.lightbox-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.docs-panel + .docs-panel {
  margin-top: 0.85rem;
}

.docs-dl {
  display: grid;
  grid-template-columns: 8rem 1fr;
  gap: 0.55rem 1rem;
  margin: 0;
}

.docs-dl dt {
  font-weight: 700;
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.docs-dl dd {
  margin: 0;
}

.docs-endpoint {
  padding: 0.85rem 0;
  border-top: 1px solid var(--line);
}

.docs-endpoint:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.docs-endpoint h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.4rem;
  font-size: 1rem;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.85); }
}

@media (max-width: 900px) {
  .login-shell {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
  }
  .login-panel {
    order: -1;
    border-left: 0;
    border-bottom: 1px solid var(--line);
    min-height: 58vh;
  }
  .login-stage {
    min-height: 34vh;
    align-content: center;
  }
  .grid-2,
  .asset-grid { grid-template-columns: 1fr; }
  .upload-form { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr; }
  .stats article {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .stats article:last-child { border-bottom: 0; }
  .hero,
  .page-head {
    align-items: start;
    flex-direction: column;
  }
  .actions { flex-wrap: wrap; }
}

@media (max-width: 760px) {
  .admin-shell {
    grid-template-columns: 1fr;
  }
  .sidebar {
    position: sticky;
    top: 0;
    z-index: 30;
    padding: 0.75rem;
  }
  .sidebar-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
  }
  .sidebar-label { display: none; }
  .sidebar-foot {
    grid-template-columns: 1fr auto;
    align-items: center;
  }
  .sidebar-logout {
    width: auto;
  }
  .admin-top {
    position: static;
  }
  .kpi-grid {
    grid-template-columns: 1fr;
  }
  .upload-grid {
    grid-template-columns: 1fr;
  }
  .docs-dl {
    grid-template-columns: 1fr;
    gap: 0.2rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
