/* Zatoshi.dev redesign — professional, compact, readable */

:root {
  --bg: #0b0e13;
  --bg-elev: #12171f;
  --bg-card: #151b25;
  --bg-alt: #0e1219;
  --border: rgba(148, 163, 184, 0.12);
  --border-strong: rgba(148, 163, 184, 0.22);
  --text: #e8edf5;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --accent: #38bdf8;
  --accent-2: #22d3ee;
  --accent-soft: rgba(56, 189, 248, 0.12);
  --ok: #34d399;
  --warn: #fbbf24;
  --danger: #f87171;
  --trade: #38bdf8;
  --ai: #a78bfa;
  --biz: #34d399;
  --mad: #a3ff12;
  --mad-soft: rgba(163, 255, 18, 0.12);
  --nexo: #2dd4bf;
  --arena: #f59e0b;
  --arena-soft: rgba(245, 158, 11, 0.12);
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  --font: "DM Sans", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --header-h: 64px;
  --max: 1120px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }

.skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
  background: var(--accent);
  color: #041018;
  padding: 8px 12px;
  border-radius: 6px;
  z-index: 1000;
}
.skip-link:focus { left: 8px; }

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: rgba(11, 14, 19, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.98rem;
  letter-spacing: -0.01em;
}
.brand:hover { text-decoration: none; color: var(--text); }
.brand-dot { color: var(--accent); font-weight: 500; }

.brand-mark {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background:
    radial-gradient(circle at 30% 30%, #7dd3fc, transparent 45%),
    linear-gradient(135deg, #0ea5e9, #0369a1);
  box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.35), 0 0 18px rgba(14, 165, 233, 0.25);
  flex-shrink: 0;
}
.brand-mark.sm { width: 18px; height: 18px; border-radius: 5px; }

.nav {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  margin-left: auto;
}
.nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.4rem 0.65rem;
  border-radius: 6px;
  transition: color 0.15s, background 0.15s;
}
.nav a:hover {
  color: var(--text);
  background: rgba(148, 163, 184, 0.08);
  text-decoration: none;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: transparent;
  padding: 0;
}
.menu-toggle span {
  display: block;
  width: 16px;
  height: 1.5px;
  margin-inline: auto;
  background: var(--text);
  border-radius: 2px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border-radius: 8px;
  border: 1px solid transparent;
  padding: 0.55rem 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, color 0.15s, transform 0.1s;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-sm { padding: 0.42rem 0.8rem; font-size: 0.85rem; }
.btn-block { width: 100%; }

.btn-primary {
  background: linear-gradient(180deg, #38bdf8 0%, #0ea5e9 100%);
  color: #041018;
  border-color: rgba(125, 211, 252, 0.4);
}
.btn-primary:hover {
  background: linear-gradient(180deg, #7dd3fc 0%, #38bdf8 100%);
  color: #041018;
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text);
  border-color: var(--border-strong);
}
.btn-secondary:hover {
  border-color: rgba(56, 189, 248, 0.45);
  background: var(--bg-elev);
  color: var(--text);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border-color: var(--border);
}
.btn-ghost:hover {
  color: var(--text);
  border-color: var(--border-strong);
  background: rgba(148, 163, 184, 0.06);
}

.btn-danger {
  background: rgba(248, 113, 113, 0.12);
  color: #fecaca;
  border-color: rgba(248, 113, 113, 0.35);
}
.btn-danger:hover {
  background: rgba(248, 113, 113, 0.2);
  color: #fff;
}

/* Hero */
.hero {
  padding: 3.25rem 0 3.5rem;
  background:
    radial-gradient(ellipse 80% 50% at 15% -10%, rgba(14, 165, 233, 0.14), transparent 55%),
    radial-gradient(ellipse 50% 40% at 90% 20%, rgba(34, 211, 238, 0.06), transparent 50%),
    var(--bg);
  border-bottom: 1px solid var(--border);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.95fr;
  gap: 2.5rem;
  align-items: start;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.85rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.2);
  animation: pulse 2s ease infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.55; }
}

.hero h1 {
  margin: 0 0 0.9rem;
  font-size: clamp(1.45rem, 2.4vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.28;
  color: var(--text);
  max-width: 34ch;
}

.lead {
  margin: 0 0 1.35rem;
  color: var(--text-muted);
  font-size: 0.98rem;
  max-width: 48ch;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1.35rem;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.hero-tags li {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-dim);
  background: rgba(148, 163, 184, 0.07);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.28rem 0.65rem;
}

/* Hero status panel */
.hero-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.15rem 1rem;
  box-shadow: var(--shadow);
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.95rem;
}
.panel-kicker {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
}
.panel-title {
  margin: 0.15rem 0 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
}

.badge {
  display: inline-flex;
  align-items: center;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.22rem 0.5rem;
  border-radius: 6px;
  background: rgba(148, 163, 184, 0.1);
  color: var(--text-muted);
  border: 1px solid var(--border);
  white-space: nowrap;
}
.badge-live {
  background: rgba(52, 211, 153, 0.12);
  color: #6ee7b7;
  border-color: rgba(52, 211, 153, 0.28);
}

.status-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
}
.status-card {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.55rem 0.65rem;
}
.status-label {
  display: block;
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-bottom: 0.15rem;
}
.status-value {
  font-size: 0.88rem;
  font-weight: 600;
}
.status-value.ok { color: var(--ok); }
.status-value.ready { color: var(--accent); }
.status-value.mad { color: var(--mad); }
.status-value.biz { color: var(--nexo); }
.status-value.arena { color: var(--arena); }

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.85rem;
}
.chip-row span {
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--accent-soft);
  border: 1px solid rgba(56, 189, 248, 0.18);
  border-radius: 999px;
  padding: 0.2rem 0.5rem;
}

.mini-log {
  background: #0a0d12;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.55rem 0.65rem;
  font-family: var(--mono);
  font-size: 0.72rem;
  max-height: 88px;
  overflow: hidden;
}
.log-line {
  display: flex;
  gap: 0.55rem;
  color: var(--text-dim);
  padding: 0.12rem 0;
}
.log-time { color: var(--text-dim); flex-shrink: 0; }
.log-msg { color: #cbd5e1; }

/* Sections */
.section {
  padding: 3.5rem 0;
}
.section-alt {
  background: var(--bg-alt);
  border-block: 1px solid var(--border);
}

.section-head {
  max-width: 40rem;
  margin-bottom: 2rem;
}
.section-head-left { margin-bottom: 1.5rem; }

.section-label {
  margin: 0 0 0.5rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
}

.section-head h2 {
  margin: 0 0 0.65rem;
  font-size: clamp(1.2rem, 2vw, 1.45rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.section-lead {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Service cards */
.card-grid {
  display: grid;
  gap: 0.9rem;
}
.services-grid {
  grid-template-columns: repeat(3, 1fr);
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem 1.2rem;
  transition: border-color 0.15s, transform 0.15s;
}
.card:hover {
  border-color: rgba(56, 189, 248, 0.28);
}
.card-num {
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 0.55rem;
}
.card h3 {
  margin: 0 0 0.45rem;
  font-size: 1rem;
  font-weight: 650;
  letter-spacing: -0.015em;
}
.card p {
  margin: 0 0 0.75rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}
.card-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.card-list li {
  position: relative;
  padding-left: 0.9rem;
  font-size: 0.82rem;
  color: var(--text-dim);
  margin-bottom: 0.28rem;
}
.card-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.7;
}

/* Work */
.work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.9rem;
}
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.9rem;
}
.product-card {
  position: relative;
  overflow: hidden;
  min-height: 100%;
}
.product-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--accent);
}
.product-goat {
  border-color: rgba(56, 189, 248, 0.28);
}
.product-goat::before {
  background: linear-gradient(90deg, #38bdf8, #0ea5e9);
}
.product-nexo {
  border-color: rgba(45, 212, 191, 0.28);
}
.product-nexo::before {
  background: linear-gradient(90deg, #2dd4bf, #34d399);
}
.product-arena {
  border-color: rgba(245, 158, 11, 0.3);
  background:
    linear-gradient(180deg, rgba(245, 158, 11, 0.05), transparent 44%),
    var(--bg-card);
}
.product-arena::before {
  background: linear-gradient(90deg, #f59e0b, #facc15);
}
.product-mad {
  border-color: rgba(163, 255, 18, 0.34);
  background:
    linear-gradient(180deg, rgba(163, 255, 18, 0.055), transparent 42%),
    var(--bg-card);
}
.product-mad::before {
  background: linear-gradient(90deg, #a3ff12, #65a30d);
}
.product-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1rem;
}
.product-mad .btn-primary {
  background: linear-gradient(180deg, #c8ff34 0%, #8fff1f 100%);
  color: #071004;
  border-color: rgba(200, 255, 52, 0.5);
}
.product-mad .btn-primary:hover {
  background: linear-gradient(180deg, #dcff72 0%, #b8ff36 100%);
  color: #071004;
}
.product-nexo .btn-primary {
  background: linear-gradient(180deg, #5eead4 0%, #2dd4bf 100%);
  color: #041210;
  border-color: rgba(94, 234, 212, 0.45);
}
.product-nexo .btn-primary:hover {
  background: linear-gradient(180deg, #99f6e4 0%, #5eead4 100%);
  color: #041210;
}
.product-arena .btn-primary {
  background: linear-gradient(180deg, #facc15 0%, #f59e0b 100%);
  color: #151004;
  border-color: rgba(250, 204, 21, 0.45);
}
.product-arena .btn-primary:hover {
  background: linear-gradient(180deg, #fde047 0%, #fbbf24 100%);
  color: #151004;
}
.work-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem 1.25rem;
}
.work-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.65rem;
}
.tag {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.18rem 0.48rem;
  border-radius: 5px;
  background: rgba(148, 163, 184, 0.1);
  color: var(--text-muted);
  border: 1px solid var(--border);
}
.tag-trade {
  background: rgba(56, 189, 248, 0.12);
  color: #7dd3fc;
  border-color: rgba(56, 189, 248, 0.25);
}
.tag-ai {
  background: rgba(167, 139, 250, 0.12);
  color: #c4b5fd;
  border-color: rgba(167, 139, 250, 0.25);
}
.tag-biz {
  background: rgba(52, 211, 153, 0.1);
  color: #6ee7b7;
  border-color: rgba(52, 211, 153, 0.25);
}
.tag-mad {
  background: var(--mad-soft);
  color: #d9ff7a;
  border-color: rgba(163, 255, 18, 0.28);
}
.tag-arena {
  background: var(--arena-soft);
  color: #fcd34d;
  border-color: rgba(245, 158, 11, 0.3);
}
.work-card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.02rem;
  font-weight: 650;
}
.work-card > p {
  margin: 0 0 0.75rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}
.work-points {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.25rem;
}
.work-points li {
  font-size: 0.82rem;
  color: var(--text-dim);
  padding-left: 0.85rem;
  position: relative;
}
.work-points li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-size: 0.75rem;
}

/* Demos */
.demo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem;
}
.demo-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem 1.25rem;
}
.demo-card-wide {
  grid-column: 1 / -1;
}
.demo-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.demo-head h3 {
  margin: 0 0 0.25rem;
  font-size: 1rem;
  font-weight: 650;
}
.demo-desc {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.field-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
}
.field-input {
  width: 100%;
  background: #0a0d12;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 0.55rem 0.7rem;
  color: var(--text);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field-input:focus {
  border-color: rgba(56, 189, 248, 0.55);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12);
}
.field-input.mono,
.mono {
  font-family: var(--mono);
  font-size: 0.8rem;
  line-height: 1.45;
}
textarea.field-input { resize: vertical; min-height: 90px; }
select.field-input { cursor: pointer; }

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
  margin-bottom: 0.85rem;
}
.field { margin-bottom: 0; }

.demo-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.85rem 0 0.75rem;
}

.demo-result {
  background: #0a0d12;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.75rem;
}
.result-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.45rem;
}
.result-item {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.45rem 0.55rem;
}
.result-item .k {
  display: block;
  font-size: 0.68rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.1rem;
}
.result-item .v {
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--accent-2);
  word-break: break-word;
}
.result-note {
  margin: 0.65rem 0 0;
  font-size: 0.8rem;
  color: var(--text-dim);
}
.result-note.warn { color: var(--warn); }
.result-note.ok { color: var(--ok); }

.risk-output {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-top: 0.25rem;
}
.risk-stat {
  background: #0a0d12;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.7rem;
}
.risk-stat-label {
  display: block;
  font-size: 0.7rem;
  color: var(--text-dim);
  margin-bottom: 0.2rem;
}
.risk-stat-value {
  font-family: var(--mono);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
}
.risk-output .result-note {
  grid-column: 1 / -1;
}

/* Hub demo */
.hub-layout {
  display: grid;
  grid-template-columns: 1fr 1fr 1.2fr;
  gap: 0.85rem;
  align-items: start;
}
.hub-modules {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  background: #0a0d12;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.65rem;
}

.toggle-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.4rem 0.45rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--text-muted);
  user-select: none;
}
.toggle-row:hover { background: rgba(148, 163, 184, 0.06); color: var(--text); }
.toggle-row input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.toggle-ui {
  width: 32px;
  height: 18px;
  border-radius: 999px;
  background: #1e293b;
  border: 1px solid var(--border-strong);
  position: relative;
  flex-shrink: 0;
  transition: background 0.15s;
}
.toggle-ui::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #94a3b8;
  transition: transform 0.15s, background 0.15s;
}
.toggle-row input:checked + .toggle-ui {
  background: rgba(56, 189, 248, 0.25);
  border-color: rgba(56, 189, 248, 0.45);
}
.toggle-row input:checked + .toggle-ui::after {
  transform: translateX(14px);
  background: var(--accent);
}
.toggle-row input:focus-visible + .toggle-ui {
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2);
}

.hub-controls {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  background: #0a0d12;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.75rem;
}
.mode-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.3rem;
  background: var(--bg-elev);
  border-radius: 8px;
  padding: 0.25rem;
  border: 1px solid var(--border);
}
.mode-btn {
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.4rem;
  border-radius: 6px;
}
.mode-btn.is-active {
  background: rgba(56, 189, 248, 0.15);
  color: var(--accent);
}
.mode-btn[data-mode="live"].is-active {
  background: rgba(248, 113, 113, 0.15);
  color: #fecaca;
}
.hub-state {
  margin: 0.25rem 0 0;
  font-size: 0.8rem;
  color: var(--text-dim);
}
.hub-state strong { color: var(--text); font-weight: 600; }

.hub-log {
  background: #07090c;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.75rem;
  min-height: 180px;
  max-height: 220px;
  overflow-y: auto;
  font-size: 0.72rem;
  line-height: 1.5;
  color: #94a3b8;
}
.hub-log .entry { margin-bottom: 0.2rem; }
.hub-log .t { color: #64748b; }
.hub-log .ok { color: #6ee7b7; }
.hub-log .warn { color: #fcd34d; }
.hub-log .err { color: #fca5a5; }
.hub-log .info { color: #7dd3fc; }

/* How */
.how-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 1.5rem;
  align-items: center;
}
.how-diagram {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem;
  text-align: center;
}
.hub-node {
  display: inline-block;
  background: linear-gradient(180deg, rgba(56, 189, 248, 0.16), rgba(56, 189, 248, 0.05));
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 10px;
  padding: 0.85rem 1.25rem;
  font-size: 0.92rem;
  font-weight: 650;
  margin-bottom: 1.1rem;
  box-shadow: 0 0 30px rgba(14, 165, 233, 0.12);
}
.hub-node small {
  display: block;
  margin-top: 0.2rem;
  font-weight: 500;
  font-size: 0.75rem;
  color: var(--text-muted);
}
.spoke-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}
.spoke {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.55rem 0.5rem;
}

.how-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.85rem;
}
.how-list li {
  display: grid;
  gap: 0.2rem;
  padding: 0.85rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.how-list strong {
  font-size: 0.92rem;
  font-weight: 650;
}
.how-list span {
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}
.contact-cards {
  display: grid;
  gap: 0.65rem;
}
.contact-card {
  display: grid;
  gap: 0.15rem;
  padding: 0.9rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: inherit;
  text-decoration: none;
  transition: border-color 0.15s;
}
.contact-card:hover {
  border-color: rgba(56, 189, 248, 0.35);
  text-decoration: none;
}
.contact-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-dim);
}
.contact-value {
  font-size: 1rem;
  font-weight: 650;
  color: var(--text);
}
.contact-hint {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.contact-form {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  display: grid;
  gap: 0.75rem;
  box-shadow: var(--shadow);
}
.contact-form .field { margin: 0; }
.form-note {
  margin: 0;
  font-size: 0.78rem;
  color: var(--text-dim);
  line-height: 1.45;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.75rem 0 2rem;
  background: var(--bg-alt);
}
.footer-inner {
  display: grid;
  gap: 1rem;
}
.footer-brand {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
}
.footer-brand strong {
  display: block;
  font-size: 0.92rem;
  margin-bottom: 0.15rem;
}
.footer-brand p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--text-muted);
  max-width: 36ch;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
}
.footer-links a {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-decoration: none;
}
.footer-links a:hover { color: var(--text); }
.footer-copy {
  margin: 0;
  font-size: 0.78rem;
  color: var(--text-dim);
}

/* Utilities */
.hide-sm { display: inline-flex; }

/* Responsive */
@media (max-width: 960px) {
  .hero-grid,
  .how-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }
  .services-grid {
    grid-template-columns: 1fr 1fr;
  }
  .product-grid {
    grid-template-columns: 1fr 1fr;
  }
  .hub-layout {
    grid-template-columns: 1fr 1fr;
  }
  .hub-log {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .hide-sm { display: none !important; }

  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin: 0;
    padding: 0.5rem;
    background: rgba(11, 14, 19, 0.97);
    border-bottom: 1px solid var(--border);
    display: none;
  }
  .nav.is-open { display: flex; }
  .nav a {
    padding: 0.75rem 0.85rem;
    border-radius: 8px;
  }
  .menu-toggle { display: flex; }

  .hero { padding: 2.25rem 0 2.5rem; }
  .hero h1 { max-width: none; }
  .section { padding: 2.5rem 0; }

  .services-grid,
  .product-grid,
  .work-grid,
  .demo-grid,
  .form-grid,
  .result-grid,
  .risk-output,
  .hub-layout,
  .status-grid {
    grid-template-columns: 1fr;
  }
  .demo-card-wide { grid-column: auto; }
  .spoke-row { grid-template-columns: 1fr 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .status-dot { animation: none; }
  .btn:active { transform: none; }
}
