:root {
  color-scheme: dark;
  --bg: #0c111b;
  --panel: #151d2b;
  --panel2: #1b2636;
  --border: #293648;
  --text: #f2f5fa;
  --muted: #9aaabe;
  --accent: #46c8ad;
  --accent-text: #081b18;
  --error: #ff8f96;
}
@media (prefers-color-scheme: light) {
  :root {
    color-scheme: light;
    --bg: #f3f6fa;
    --panel: #fff;
    --panel2: #f5f8fa;
    --border: #dce4ec;
    --text: #172334;
    --muted: #617286;
    --accent: #087d70;
    --accent-text: #fff;
    --error: #bd3344;
  }
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.6 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
.shell { min-height: 100vh; display: flex; }
.sidebar {
  width: 246px;
  min-width: 246px;
  border-right: 1px solid var(--border);
  background: var(--panel);
  padding: 28px 18px;
  display: flex;
  flex-direction: column;
}
.brand-mark {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  background: var(--accent);
  color: var(--accent-text);
  border-radius: 12px;
  font-weight: 800;
  letter-spacing: -.5px;
  margin-bottom: 14px;
}
.brand-name { font-size: 18px; font-weight: 750; line-height: 1.3; }
.brand-name span { display: block; }
.brand-sub,.eyebrow { color: var(--muted); font-size: 11px; letter-spacing: 1.2px; font-weight: 700; }
.brand-sub { margin-top: 8px; }
nav { display: grid; gap: 5px; margin-top: 42px; }
nav a,.ghost {
  color: var(--muted);
  padding: 11px 14px;
  text-decoration: none;
  border-radius: 10px;
  font: inherit;
}
nav a:hover,nav a[aria-current="page"] {
  background: var(--panel2);
  color: var(--text);
}
.logout { margin-top: auto; }
.ghost { background: transparent; border: 1px solid var(--border); cursor: pointer; }
.content { flex: 1; min-width: 0; padding: 36px max(30px,4vw); }
.topbar { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 28px; }
h1 { font-size: clamp(25px,3vw,35px); letter-spacing: -.9px; margin: 4px 0 0; line-height: 1.3; }
h2 { font-size: 19px; margin: 0 0 12px; letter-spacing: -.3px; }
p { color: var(--muted); }
.intro { margin: 0 0 27px; }
.environment { color: var(--muted); font-size: 12px; }
.metrics { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 18px; }
.metric,.panel,.login-panel {
  border: 1px solid var(--border);
  background: var(--panel);
  border-radius: 16px;
  padding: 25px;
}
.metric-label { color: var(--muted); font-size: 13px; }
.metric-value { font-size: 35px; font-weight: 750; margin-top: 12px; font-variant-numeric: tabular-nums; }
.panel { margin-top: 24px; }
.primary {
  background: var(--accent);
  color: var(--accent-text);
  border: 0;
  padding: 12px 19px;
  border-radius: 9px;
  font-weight: 750;
  cursor: pointer;
  font-size: 14px;
}
.action-link { display: inline-block; text-decoration: none; margin-top: 10px; }
label { display: block; font-weight: 650; font-size: 13px; margin: 18px 0 8px; }
input,textarea {
  width: 100%;
  background: var(--panel2);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  font: inherit;
}
textarea { font: 12px/1.6 ui-monospace,SFMono-Regular,Consolas,monospace; resize: vertical; }
input:focus,textarea:focus,button:focus-visible,a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.full { width: 100%; margin-top: 24px; }
.login-panel { max-width: 440px; width: 100%; margin: min(12vh,110px) auto 0; }
.login-panel p { margin-bottom: 25px; }
.alert {
  color: var(--error);
  background: var(--panel);
  border: 1px solid var(--error);
  padding: 12px 16px;
  border-radius: 10px;
  margin-bottom: 22px;
}
footer { color: var(--muted); font-size: 12px; margin-top: 45px; }
@media (max-width: 760px) {
  .shell { display: block; }
  .sidebar { width: 100%; min-width: 0; padding: 16px 18px; border-right: 0; border-bottom: 1px solid var(--border); }
  .sidebar .brand-mark { margin-bottom: 8px; }
  .brand-name { font-size: 16px; }
  nav { display: flex; flex-wrap: wrap; margin-top: 18px; gap: 6px; }
  nav a { padding: 9px 12px; }
  .logout { margin-top: 12px; }
  .content { padding: 25px 17px; }
  .topbar { align-items: flex-start; }
  .environment { display: none; }
  .metrics { grid-template-columns: 1fr; gap: 12px; }
  .metric,.panel,.login-panel { padding: 20px; }
  .metric-value { font-size: 29px; margin-top: 5px; }
}

/* Validation-service administrative select controls */
select {
  display: block;
  width: 100%;
  min-height: 46px;
  background: var(--panel2);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  font: inherit;
  cursor: pointer;
}

select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (max-width: 760px) {
  select {
    min-height: 48px;
    font-size: 16px;
  }
}
