/* ECHO45 ADVISORS — BI / analytics product */
:root {
  --bg-canvas: #f7f9fc;
  --bg-surface: #ffffff;
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --brand-primary: #1d4ed8;
  --brand-primary-hover: #1e40af;
  --accent-teal: #0d9488;
  --border: #e2e8f0;
  --font: "IBM Plex Sans", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
  --radius: 10px;
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.55;
  color: var(--text-primary);
  background-color: var(--bg-canvas);
  background-image: linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 48px 48px;
  background-position: center top;
  min-height: 100vh;
}

a {
  color: var(--brand-primary);
  text-underline-offset: 3px;
}

a:hover {
  color: var(--brand-primary-hover);
}

:focus-visible {
  outline: 2px solid var(--brand-primary);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0.5rem;
  z-index: 1000;
  padding: 0.5rem 1rem;
  background: var(--bg-surface);
  border-radius: 6px;
}

.skip-link:focus {
  left: 0.5rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.wrap {
  width: min(1080px, 100% - 2rem);
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 249, 252, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  color: var(--text-primary);
  text-decoration: none;
}

.brand__mark {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--brand-primary), var(--accent-teal));
}

.nav-toggle {
  display: none;
  min-width: 44px;
  min-height: 44px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg-surface);
  cursor: pointer;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.15rem;
  align-items: center;
}

.nav a {
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.9375rem;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--text-primary);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 1.1rem;
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: 9px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
}

.btn--primary {
  background: var(--brand-primary);
  color: #fff;
}

.btn--primary:hover {
  background: var(--brand-primary-hover);
}

.btn--outline {
  background: var(--bg-surface);
  color: var(--brand-primary);
  border-color: var(--border);
}

.btn--outline:hover {
  border-color: var(--brand-primary);
}

.hero {
  padding: clamp(2.75rem, 7vw, 4.5rem) 0;
}

.hero__title {
  font-size: clamp(2rem, 4.5vw, 2.75rem);
  line-height: 1.15;
  margin: 0 0 1rem;
  max-width: 18ch;
}

.hero__lead {
  margin: 0 0 1.5rem;
  color: var(--text-secondary);
  max-width: 58ch;
  font-size: 1.0625rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.section {
  padding: clamp(2rem, 5vw, 3rem) 0;
}

.section__title {
  font-size: 1.35rem;
  margin: 0 0 0.5rem;
}

.section__sub {
  margin: 0 0 1.5rem;
  color: var(--text-secondary);
  max-width: 62ch;
}

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

@media (min-width: 768px) {
  .pillars {
    grid-template-columns: repeat(3, 1fr);
  }
}

.pillar {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}

.pillar h3 {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
}

.pillar p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.arch {
  display: grid;
  gap: 1.25rem;
  align-items: center;
}

@media (min-width: 880px) {
  .arch {
    grid-template-columns: 1.1fr 0.9fr;
  }
}

.diagram {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-surface);
  padding: 1rem;
}

.diagram svg {
  width: 100%;
  height: auto;
  display: block;
}

.bullets {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--text-secondary);
}

.bullets li {
  margin-bottom: 0.5rem;
}

.band-dark {
  background: #0f172a;
  color: #f8fafc;
  padding: clamp(2rem, 5vw, 3rem) 0;
  margin-top: 1rem;
}

.band-dark a {
  color: #93c5fd;
}

.band-dark .section__sub {
  color: #cbd5e1;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-surface);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

th,
td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

th {
  background: #f1f5f9;
  font-weight: 600;
}

.site-footer {
  padding: 2.5rem 0;
  border-top: 1px solid var(--border);
  background: var(--bg-surface);
}

.footer-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 720px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr;
  }
}

.site-footer h2 {
  font-size: 0.9375rem;
  margin: 0 0 0.65rem;
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-footer li {
  margin-bottom: 0.45rem;
}

.site-footer a {
  color: var(--text-secondary);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--brand-primary);
}

.legal {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.page-hero {
  padding: 2.25rem 0 1rem;
}

.page-hero h1 {
  font-size: clamp(1.65rem, 3.5vw, 2.1rem);
  margin: 0 0 0.65rem;
}

.page-hero p {
  margin: 0;
  color: var(--text-secondary);
  max-width: 65ch;
}

.prose {
  max-width: 65ch;
}

.prose p {
  color: var(--text-secondary);
}

.prose h2 {
  margin-top: 1.75rem;
  font-size: 1.2rem;
}

.code {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  background: #f1f5f9;
  border: 1px solid var(--border);
  padding: 0.75rem 1rem;
  border-radius: 8px;
  overflow-x: auto;
}

.form {
  display: grid;
  gap: 1rem;
  max-width: 520px;
}

.form label {
  display: grid;
  gap: 0.35rem;
  font-weight: 500;
  font-size: 0.9375rem;
}

.form input,
.form select,
.form textarea {
  min-height: 44px;
  padding: 0 0.85rem;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: var(--bg-surface);
  font: inherit;
}

.form textarea {
  min-height: 130px;
  padding: 0.65rem 0.85rem;
}

.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.toast[hidden] {
  display: none;
}

.toast {
  padding: 0.75rem 1rem;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: #eff6ff;
  color: var(--text-primary);
}

@media (max-width: 900px) {
  .nav-toggle {
    display: inline-flex;
  }
  .nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    padding-bottom: 0.5rem;
  }
  .nav.is-open {
    display: flex;
  }
  .header-actions {
    margin-left: auto;
  }
  .site-header__inner {
    flex-wrap: nowrap;
  }
}
