/* ═══════════════════════════════════════════════════════════════════════════
   WRKZCoin Block Explorer — Style Sheet
   Supports dark (default) and light themes via data-theme attribute on <html>
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── THEME TOKENS ────────────────────────────────────────────────────────── */

:root[data-theme="dark"] {
  --bg:              #0f172a;
  --bg-card:         #1e293b;
  --bg-card-2:       #263348;
  --bg-header:       #0b1120;
  --bg-settings:     #131f35;
  --bg-footer:       #0b1120;
  --bg-hover:        #293548;
  --bg-input:        #1e293b;
  --bg-code:         #162032;

  --text:            #e2e8f0;
  --text-muted:      #94a3b8;
  --text-faint:      #4a6080;
  --text-header:     #f1f5f9;
  --text-invert:     #0f172a;

  --border:          #2a3a52;
  --border-input:    #374a61;

  /* chrome = header + footer decorative colors */
  --chrome-border:   rgba(255,255,255,0.06);
  --chrome-text:     rgba(255,255,255,0.45);
  --chrome-link:     rgba(255,255,255,0.5);
  --chrome-link-hover: rgba(255,255,255,0.85);
  --chrome-sep:      rgba(255,255,255,0.2);
  --nav-text:        rgba(255,255,255,0.7);
  --nav-text-hover:  #ffffff;
  --nav-bg-hover:    rgba(255,255,255,0.08);
  --icon-btn-bg:     rgba(255,255,255,0.07);
  --icon-btn-border: rgba(255,255,255,0.12);
  --icon-btn-color:  rgba(255,255,255,0.75);
  --icon-btn-hover:  rgba(255,255,255,0.14);

  --accent:          #818cf8;
  --accent-dim:      rgba(99,102,241,0.18);
  --accent-hover:    #a5b4fc;

  --green:           #34d399;
  --green-dim:       rgba(52,211,153,0.15);
  --yellow:          #fbbf24;
  --yellow-dim:      rgba(251,191,36,0.15);
  --red:             #f87171;
  --red-dim:         rgba(248,113,113,0.15);

  --shadow:          0 4px 24px rgba(0,0,0,0.45);
  --shadow-sm:       0 2px 8px rgba(0,0,0,0.35);
  --radius:          10px;
  --radius-sm:       6px;
  --radius-lg:       14px;

  color-scheme: dark;
}

:root[data-theme="light"] {
  --bg:              #f1f5f9;
  --bg-card:         #ffffff;
  --bg-card-2:       #f8fafc;
  --bg-header:       #ffffff;
  --bg-settings:     #f8fafc;
  --bg-footer:       #f1f5f9;
  --bg-hover:        #f0f4f8;
  --bg-input:        #ffffff;
  --bg-code:         #f1f5f9;

  --text:            #1e293b;
  --text-muted:      #64748b;
  --text-faint:      #94a3b8;
  --text-header:     #1e293b;
  --text-invert:     #ffffff;

  --border:          #e2e8f0;
  --border-input:    #cbd5e1;

  /* chrome = header + footer decorative colors */
  --chrome-border:   #e2e8f0;
  --chrome-text:     #64748b;
  --chrome-link:     #475569;
  --chrome-link-hover: #1e293b;
  --chrome-sep:      #cbd5e1;
  --nav-text:        #475569;
  --nav-text-hover:  #1e293b;
  --nav-bg-hover:    rgba(0,0,0,0.06);
  --icon-btn-bg:     rgba(0,0,0,0.04);
  --icon-btn-border: #e2e8f0;
  --icon-btn-color:  #475569;
  --icon-btn-hover:  rgba(0,0,0,0.08);

  --accent:          #6366f1;
  --accent-dim:      rgba(99,102,241,0.10);
  --accent-hover:    #4f46e5;

  --green:           #16a34a;
  --green-dim:       rgba(22,163,74,0.12);
  --yellow:          #d97706;
  --yellow-dim:      rgba(217,119,6,0.12);
  --red:             #dc2626;
  --red-dim:         rgba(220,38,38,0.12);

  --shadow:          0 4px 24px rgba(0,0,0,0.10);
  --shadow-sm:       0 2px 8px rgba(0,0,0,0.07);
  --radius:          10px;
  --radius-sm:       6px;
  --radius-lg:       14px;

  color-scheme: light;
}

/* ─── RESET & BASE ────────────────────────────────────────────────────────── */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 15px;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Inter',
               'Helvetica Neue', Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background 0.25s, color 0.25s;
  line-height: 1.6;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.15s;
}
a:hover { color: var(--accent-hover); text-decoration: underline; }

code, .mono {
  font-family: 'Fira Code', 'Cascadia Code', 'JetBrains Mono',
               'Courier New', Courier, monospace;
  font-size: 0.85em;
}

/* ─── HEADER ──────────────────────────────────────────────────────────────── */

.site-header {
  background: var(--bg-header);
  border-bottom: 1px solid var(--chrome-border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.header-inner {
  max-width: 1800px;
  margin: 0 auto;
  padding: 0 1.5rem;
  height: 64px;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

/* Brand */
.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  flex-shrink: 0;
}
.brand-icon {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
}
.brand-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-header);
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.brand-sub {
  color: var(--accent);
  font-weight: 400;
}
.brand:hover { text-decoration: none; }

/* Search */
.search-form { flex: 1; max-width: 560px; }

.search-wrap {
  display: flex;
  align-items: center;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px;
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}
[data-theme="light"] .search-wrap {
  background: rgba(0,0,0,0.04);
  border-color: rgba(0,0,0,0.12);
}
.search-wrap:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.search-icon {
  width: 16px;
  height: 16px;
  margin-left: 0.75rem;
  color: rgba(255,255,255,0.35);
  flex-shrink: 0;
  pointer-events: none;
}
[data-theme="light"] .search-icon { color: var(--text-muted); }

.search-wrap input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  color: var(--text-header);
  padding: 0.55rem 0.6rem;
  font-size: 0.875rem;
  min-width: 0;
}
[data-theme="light"] .search-wrap input { color: var(--text); }
.search-wrap input::placeholder { color: rgba(255,255,255,0.3); }
[data-theme="light"] .search-wrap input::placeholder { color: var(--text-muted); }

.search-btn {
  border-radius: 0 !important;
  border-left: 1px solid rgba(255,255,255,0.1) !important;
  padding: 0.55rem 1rem !important;
  font-size: 0.825rem !important;
  height: 100%;
}

/* Header right actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.nav-link {
  color: var(--nav-text);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.35rem 0.65rem;
  border-radius: var(--radius-sm);
  transition: color 0.15s, background 0.15s;
  white-space: nowrap;
}
.nav-link:hover {
  color: var(--nav-text-hover);
  background: var(--nav-bg-hover);
  text-decoration: none;
}
.nav-link.active { color: var(--accent); }

/* Theme toggle */
.icon-btn {
  background: var(--icon-btn-bg);
  border: 1px solid var(--icon-btn-border);
  border-radius: var(--radius-sm);
  color: var(--icon-btn-color);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}
.icon-btn:hover { background: var(--icon-btn-hover); color: var(--nav-text-hover); }
.icon-btn svg { width: 16px; height: 16px; }

.theme-icon { display: block; }
.theme-icon.hidden { display: none; }

/* Sun icon strokes */
#iconSun line { stroke: currentColor; stroke-width: 2; stroke-linecap: round; fill: none; }
#iconSun circle { fill: currentColor; stroke: none; }

/* ─── SETTINGS BAR ────────────────────────────────────────────────────────── */

.settings-bar {
  background: var(--bg-settings);
  border-bottom: 1px solid var(--border);
  padding: 0.55rem 1.5rem;
}

.settings-inner {
  max-width: 1800px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.settings-label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.settings-input {
  flex: 1;
  max-width: 340px;
  min-width: 200px;
  padding: 0.35rem 0.7rem;
  background: var(--bg-input);
  border: 1px solid var(--border-input);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.85rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.settings-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.conn-status {
  font-size: 0.78rem;
  font-weight: 600;
}
.conn-status.ok  { color: var(--green); }
.conn-status.err { color: var(--red); }

/* ─── ALERTS ─────────────────────────────────────────────────────────────── */

.alert {
  max-width: 1800px;
  margin: 0.75rem auto 0;
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.875rem;
  line-height: 1.5;
}

.alert-error {
  background: var(--red-dim);
  border: 1px solid rgba(248,113,113,0.25);
  color: var(--red);
}
[data-theme="light"] .alert-error { color: var(--red); }

.alert code {
  background: rgba(0,0,0,0.15);
  padding: 0.05em 0.35em;
  border-radius: 3px;
  font-size: 0.82em;
}

.alert-close {
  margin-left: auto;
  background: none;
  border: none;
  color: inherit;
  cursor: pointer;
  font-size: 1rem;
  opacity: 0.6;
  line-height: 1;
  padding: 0 0.2rem;
  flex-shrink: 0;
}
.alert-close:hover { opacity: 1; }

/* ─── LOADING OVERLAY ────────────────────────────────────────────────────── */

.loading-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  backdrop-filter: blur(2px);
}

.spinner {
  width: 44px;
  height: 44px;
  border: 3px solid rgba(255,255,255,0.15);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ─── MAIN CONTENT ───────────────────────────────────────────────────────── */

.main-content {
  flex: 1;
  max-width: 1800px;
  width: 100%;
  margin: 0 auto;
  padding: 1.5rem 1.5rem 2rem;
}

/* Pages */
.page { display: none; }
.page.active { display: block; }

/* ─── STAT CARDS ─────────────────────────────────────────────────────────── */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 0.875rem;
  margin-bottom: 1.75rem;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, transform 0.2s;
  position: relative;
  overflow: hidden;
}
.stat-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: 0.6;
}
.stat-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }

.stat-label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  margin-bottom: 0.45rem;
}

.stat-value {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
  word-break: break-all;
}

/* ─── SECTION ─────────────────────────────────────────────────────────────── */

.section { margin-bottom: 2rem; }

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.875rem;
  gap: 1rem;
  flex-wrap: wrap;
}

.section-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
}

.section-meta {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.refresh-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ─── TABLES ─────────────────────────────────────────────────────────────── */

.table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.data-table thead {
  background: var(--bg-card-2);
  border-bottom: 1px solid var(--border);
}

.data-table th {
  padding: 0.7rem 1rem;
  text-align: left;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  white-space: nowrap;
}

.data-table td {
  padding: 0.7rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  vertical-align: middle;
}

.data-table tbody tr:last-child td { border-bottom: none; }

.data-table tbody tr {
  transition: background 0.12s;
}
.data-table tbody tr:hover { background: var(--bg-hover); }

.empty-cell {
  text-align: center;
  color: var(--text-muted);
  padding: 2.5rem 1rem !important;
  font-size: 0.9rem;
}

/* ─── BADGES ─────────────────────────────────────────────────────────────── */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3em;
  padding: 0.2em 0.65em;
  border-radius: 99px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.badge-green   { background: var(--green-dim);  color: var(--green); }
.badge-yellow  { background: var(--yellow-dim); color: var(--yellow); }
.badge-red     { background: var(--red-dim);    color: var(--red); }
.badge-accent  { background: var(--accent-dim); color: var(--accent); }

/* ─── BUTTONS ─────────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4em;
  padding: 0.5rem 1.1rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.15s, color 0.15s, border-color 0.15s, box-shadow 0.15s;
  text-decoration: none !important;
  white-space: nowrap;
  font-family: inherit;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }

.btn-outline {
  background: transparent;
  color: var(--text-muted);
  border-color: var(--border);
}
.btn-outline:hover { background: var(--bg-hover); color: var(--text); }

.btn-sm { padding: 0.3rem 0.75rem; font-size: 0.8rem; }

/* ─── BREADCRUMB ─────────────────────────────────────────────────────────── */

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.83rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--accent); }
.breadcrumb-sep { color: var(--text-faint); }

/* ─── DETAIL PAGES ───────────────────────────────────────────────────────── */

.detail-root { }

.detail-heading {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}

.detail-heading h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text);
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 1rem;
}

@media (max-width: 820px) {
  .detail-grid { grid-template-columns: 1fr; }
}

.detail-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
}

.detail-card h3 {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  margin-bottom: 0.875rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--border);
}

.detail-card.full { grid-column: 1 / -1; }

.mt { margin-top: 1rem; }

/* Key-value table */
.kv-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
.kv-table tr + tr td,
.kv-table tr + tr th { border-top: 1px solid var(--border); }

.kv-table th {
  width: 1%;
  padding: 0.5rem 1.5rem 0.5rem 0;
  font-weight: 600;
  color: var(--text-muted);
  font-size: 0.825rem;
  vertical-align: top;
  white-space: nowrap;
  text-align: left;
}

.kv-table td {
  padding: 0.5rem 0;
  color: var(--text);
  word-break: break-all;
}

.kv-table .break { word-break: break-all; }

/* Hash navigation arrows */
.nav-arrows {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

/* ─── HASH CELL (full 64-char hashes in tables) ─────────────────────────── */

.hash-cell {
  word-break: break-all;
  white-space: normal;
  font-size: 0.78rem;
  max-width: 520px;
}

/* ─── CODE / HASH DISPLAY ────────────────────────────────────────────────── */

.hash-full {
  font-family: 'Fira Code', 'Cascadia Code', 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  color: var(--text-muted);
  word-break: break-all;
  background: var(--bg-code);
  padding: 0.2em 0.45em;
  border-radius: 4px;
  border: 1px solid var(--border);
}

/* ─── INLINE CODE ─────────────────────────────────────────────────────────── */

code {
  background: var(--bg-code);
  border: 1px solid var(--border);
  padding: 0.1em 0.4em;
  border-radius: 4px;
  font-size: 0.83em;
  color: var(--accent);
}

/* ─── FOOTER ──────────────────────────────────────────────────────────────── */

.site-footer {
  background: var(--bg-footer);
  border-top: 1px solid var(--chrome-border);
  padding: 1.25rem 1.5rem;
  margin-top: auto;
}

.footer-inner {
  max-width: 1800px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: var(--chrome-text);
}

.footer-copy { font-weight: 500; }

.footer-links {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.footer-links a { color: var(--chrome-link); }
.footer-links a:hover { color: var(--chrome-link-hover); }
.sep { color: var(--chrome-sep); }

/* ─── TRANSACTION I/O ────────────────────────────────────────────────────── */

.io-section {
  margin-top: 1rem;
}

.io-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.875rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0;
}

.io-tab {
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  border: none;
  background: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.15s, border-color 0.15s;
  font-family: inherit;
}
.io-tab.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}
.io-tab:hover { color: var(--text); }

.io-panel { display: none; }
.io-panel.active { display: block; }

/* ─── POOL BANNER ─────────────────────────────────────────────────────────── */

.pool-banner {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.pool-stat { text-align: center; }
.pool-stat-label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  margin-bottom: 0.2rem;
}
.pool-stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text);
}

/* ─── PAGINATION ─────────────────────────────────────────────────────────── */

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1rem;
  flex-wrap: wrap;
  background: var(--bg-card);
  border-top: 1px solid var(--border);
}

.pagination-info {
  font-size: 0.82rem;
  color: var(--text-muted);
  padding: 0 0.5rem;
  white-space: nowrap;
}

.btn:disabled {
  opacity: 0.38;
  cursor: not-allowed;
  pointer-events: none;
}

/* ─── RESPONSIVE ─────────────────────────────────────────────────────────── */

@media (max-width: 900px) {
  .header-inner {
    flex-wrap: wrap;
    height: auto;
    padding: 0.65rem 1rem;
    gap: 0.65rem;
  }
  .search-form {
    order: 3;
    max-width: 100%;
    width: 100%;
    flex: 0 0 100%;
  }
  .header-actions {
    margin-left: auto;
  }
  .brand-sub { display: none; }
}

@media (max-width: 600px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .main-content { padding: 1rem; }
  .data-table th, .data-table td { padding: 0.55rem 0.65rem; }
  .detail-heading h2 { font-size: 1.15rem; }
  .kv-table th { font-size: 0.78rem; padding-right: 0.75rem; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
  .footer-note { font-size: 0.72rem; }
}

@media (max-width: 400px) {
  .stats-grid { grid-template-columns: 1fr; }
}

/* ─── CHECK TRANSACTION ─────────────────────────────────────────────────── */

.check-form {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.check-row {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  flex-wrap: wrap;
}

.check-label {
  width: 160px;
  flex-shrink: 0;
  font-size: 0.825rem;
  font-weight: 600;
  color: var(--text-muted);
  padding-top: 0.45rem;
}

.check-radio {
  font-size: 0.875rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  cursor: pointer;
  margin-right: 1.25rem;
}

.check-input {
  flex: 1;
  min-width: 0;
  padding: 0.4rem 0.7rem;
  background: var(--bg-input);
  border: 1px solid var(--border-input);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.85rem;
  font-family: 'Fira Code', 'Cascadia Code', monospace;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.check-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.check-result-ok {
  padding: 0.65rem 0.9rem;
  background: var(--green-dim);
  border: 1px solid rgba(52,211,153,.25);
  color: var(--green);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
}

.check-result-none {
  padding: 0.65rem 0.9rem;
  background: var(--yellow-dim);
  border: 1px solid rgba(251,191,36,.25);
  color: var(--yellow);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
}

.output-matched {
  background: var(--green-dim) !important;
  outline: 2px solid var(--green);
  outline-offset: -2px;
}

.output-nomatch { opacity: 0.4; }

/* ─── SCROLL ─────────────────────────────────────────────────────────────── */

::-webkit-scrollbar { width: 7px; height: 7px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* ─── ANIMATIONS ─────────────────────────────────────────────────────────── */

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.page.active { animation: fadeIn 0.2s ease; }

.detail-root > * { animation: fadeIn 0.2s ease; }
