/* ==========================================================================
   ABSG Ballogy — Homepage Stylesheet
   Dark theme · emerald accent · Computer Systems Design
   ========================================================================== */

:root {
  --bg: #0B0E14;
  --surface: #121722;
  --card: #161E2C;
  --card-2: #1B2434;
  --border: #253041;
  --border-strong: #34435A;
  --text: #E8EAED;
  --muted: #9FA8BA;
  --heading: #FFFFFF;
  --accent: #34D399;
  --accent-bright: #6EE7B7;
  --accent-dim: #1E3A2F;
  --danger: #F87171;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-size: 16px;
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--accent-bright);
}

h1, h2, h3, h4 {
  color: var(--heading);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 18px;
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 26px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.btn-accent {
  background-color: var(--accent);
  color: #06251A;
  border-color: var(--accent);
}

.btn-accent:hover {
  background-color: var(--accent-bright);
  color: #06251A;
  transform: translateY(-2px);
}

.btn-ghost {
  background-color: transparent;
  color: var(--heading);
  border-color: var(--border-strong);
}

.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

/* --------------------------------------------------------------------------
   Header / Navigation (class-scoped, never a bare element selector)
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: #0B0E14;
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.25s ease, background-color 0.25s ease;
}

.site-header.is-scrolled {
  background-color: #0D1119;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 76px;
}

.brand {
  font-size: 21px;
  font-weight: 800;
  color: var(--heading);
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.brand span {
  color: var(--accent);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.site-nav a {
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.site-nav a:hover {
  color: var(--heading);
}

.site-nav a .num {
  color: var(--accent);
  font-size: 12px;
  margin-right: 5px;
  font-variant-numeric: tabular-nums;
}

.nav-cta {
  padding: 11px 22px;
  font-size: 14px;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  width: 44px;
  height: 44px;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.nav-toggle .bar {
  display: block;
  width: 20px;
  height: 2px;
  background-color: var(--heading);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle.open .bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.open .bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle.open .bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* --------------------------------------------------------------------------
   Hero — asymmetric two-column with terminal visual
   -------------------------------------------------------------------------- */
.hero-section {
  position: relative;
  padding: 96px 0 80px;
  background-color: var(--bg);
  background-image:
    radial-gradient(circle at 82% 18%, #122A24 0%, #0B0E14 42%),
    radial-gradient(circle at 6% 90%, #101C2B 0%, #0B0E14 55%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 60px;
  align-items: center;
}

.hero-copy h1 {
  font-size: clamp(38px, 5vw, 60px);
  margin-bottom: 24px;
}

.hero-copy h1 .highlight {
  color: var(--accent);
}

.hero-copy .lead {
  font-size: 18px;
  color: var(--muted);
  max-width: 560px;
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 40px;
}

.hero-proof {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
}

.hero-proof li {
  font-size: 14px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-proof li::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--accent);
  flex: none;
}

/* Terminal visual */
.terminal {
  background-color: #0D1117;
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.terminal-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 18px;
  background-color: #141A24;
  border-bottom: 1px solid var(--border);
}

.terminal-bar .dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.dot.red { background-color: #F87171; }
.dot.yellow { background-color: #FBBF24; }
.dot.green { background-color: #34D399; }

.terminal-bar .term-title {
  margin-left: 8px;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.06em;
}

.terminal-body {
  padding: 22px 22px 26px;
  font-family: "SFMono-Regular", "Consolas", "Liberation Mono", monospace;
  font-size: 14px;
  line-height: 1.8;
}

.terminal-body .line {
  color: var(--muted);
}

.terminal-body .cmd {
  color: var(--heading);
}

.terminal-body .key {
  color: var(--accent-bright);
}

.terminal-body .val {
  color: var(--accent);
}

.terminal-body .comment {
  color: #5B6678;
}

.cursor {
  display: inline-block;
  width: 9px;
  height: 18px;
  background-color: var(--accent);
  vertical-align: -3px;
  animation: blink 1s steps(2, start) infinite;
}

@keyframes blink {
  to { visibility: hidden; }
}

/* --------------------------------------------------------------------------
   Metrics strip
   -------------------------------------------------------------------------- */
.metrics-section {
  background-color: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

.metric {
  padding: 44px 24px;
  text-align: center;
  border-right: 1px solid var(--border);
}

.metric:last-child {
  border-right: none;
}

.metric .value {
  font-size: 42px;
  font-weight: 800;
  color: var(--heading);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.metric .value .suffix {
  color: var(--accent);
}

.metric .label {
  margin-top: 12px;
  font-size: 14px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

/* --------------------------------------------------------------------------
   Capabilities — horizontal scroll row
   -------------------------------------------------------------------------- */
.capabilities-section {
  padding: 96px 0;
  background-color: var(--bg);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 48px;
}

.section-head h2 {
  font-size: clamp(30px, 4vw, 44px);
  max-width: 560px;
}

.section-head p {
  color: var(--muted);
  max-width: 420px;
  font-size: 16px;
}

.scroll-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 320px;
  gap: 22px;
  overflow-x: auto;
  padding: 8px 4px 20px;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}

.scroll-row::-webkit-scrollbar {
  height: 8px;
}

.scroll-row::-webkit-scrollbar-thumb {
  background-color: var(--border-strong);
  border-radius: 4px;
}

.capability-card {
  scroll-snap-align: start;
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 30px 28px;
  transition: border-color 0.25s ease, transform 0.25s ease;
}

.capability-card:hover {
  border-color: var(--accent);
  transform: translateY(-6px);
}

.capability-card .cap-num {
  font-size: 40px;
  font-weight: 800;
  color: var(--accent-dim);
  line-height: 1;
  margin-bottom: 18px;
  font-variant-numeric: tabular-nums;
}

.capability-card h3 {
  font-size: 20px;
  margin-bottom: 14px;
}

.capability-card p {
  color: var(--muted);
  font-size: 15px;
  margin-bottom: 18px;
}

.capability-card .tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-bright);
  background-color: var(--accent-dim);
  padding: 4px 12px;
  border-radius: 999px;
}

/* --------------------------------------------------------------------------
   Process — numbered methodology
   -------------------------------------------------------------------------- */
.process-section {
  padding: 96px 0;
  background-color: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.process-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.process-step {
  display: grid;
  grid-template-columns: 90px 1fr 1.2fr;
  gap: 32px;
  align-items: start;
  padding: 34px 0;
  border-top: 1px solid var(--border);
}

.process-step:first-child {
  border-top: none;
}

.process-step .step-num {
  font-size: 18px;
  font-weight: 800;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.05em;
}

.process-step h3 {
  font-size: 22px;
  margin-bottom: 8px;
}

.process-step p {
  color: var(--muted);
  font-size: 15px;
}

/* --------------------------------------------------------------------------
   Compare — comparison table
   -------------------------------------------------------------------------- */
.compare-section {
  padding: 96px 0;
  background-color: var(--bg);
}

.compare-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 16px;
  background-color: var(--card);
}

.compare-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  text-align: left;
}

.compare-table th,
.compare-table td {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
}

.compare-table thead th {
  font-size: 15px;
  color: var(--heading);
  background-color: var(--card-2);
  letter-spacing: 0.02em;
}

.compare-table thead th.ours {
  color: var(--accent);
}

.compare-table tbody tr:last-child td {
  border-bottom: none;
}

.compare-table td {
  font-size: 15px;
  color: var(--muted);
}

.compare-table td.feature {
  color: var(--heading);
  font-weight: 600;
}

.check {
  color: var(--accent);
  font-weight: 700;
}

.cross {
  color: var(--danger);
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   Statement — full-width band
   -------------------------------------------------------------------------- */
.statement-section {
  padding: 110px 0;
  background-color: var(--accent-dim);
  background-image: radial-gradient(circle at 20% 20%, #1E3A2F 0%, #10241C 60%);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.statement-section blockquote {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.statement-section blockquote p {
  font-size: clamp(24px, 3.4vw, 38px);
  line-height: 1.4;
  font-weight: 700;
  color: var(--heading);
}

.statement-section blockquote p em {
  color: var(--accent);
  font-style: normal;
}

.statement-section .attribution {
  margin-top: 24px;
  font-size: 15px;
  color: var(--muted);
  letter-spacing: 0.05em;
}

/* --------------------------------------------------------------------------
   Sectors — numbered list with big numerals
   -------------------------------------------------------------------------- */
.sectors-section {
  padding: 96px 0;
  background-color: var(--surface);
  border-top: 1px solid var(--border);
}

.sectors-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.sector {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 30px 28px;
}

.sector h3 {
  font-size: 19px;
  margin-bottom: 10px;
}

.sector p {
  color: var(--muted);
  font-size: 15px;
}

.sector .sector-icon {
  font-size: 30px;
  margin-bottom: 16px;
}

/* --------------------------------------------------------------------------
   Contact
   -------------------------------------------------------------------------- */
.contact-section {
  padding: 96px 0;
  background-color: var(--bg);
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 60px;
  align-items: start;
}

.contact-grid h2 {
  font-size: clamp(30px, 4vw, 44px);
  margin-bottom: 18px;
}

.contact-grid .contact-lead {
  color: var(--muted);
  font-size: 16px;
  margin-bottom: 32px;
}

.contact-list {
  list-style: none;
  display: grid;
  gap: 20px;
}

.contact-list li {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 16px;
  color: var(--muted);
}

.contact-list li a {
  color: var(--heading);
}

.contact-list li a:hover {
  color: var(--accent);
}

.contact-list .ci-icon {
  width: 44px;
  height: 44px;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background-color: var(--accent-dim);
  color: var(--accent-bright);
  font-weight: 700;
  font-size: 16px;
}

.contact-form {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 36px;
}

.form-field {
  margin-bottom: 22px;
}

.form-field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--heading);
  margin-bottom: 8px;
}

.form-field input,
.form-field textarea {
  width: 100%;
  background-color: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 13px 16px;
  font-size: 15px;
  font-family: inherit;
  color: var(--text);
  transition: border-color 0.2s ease;
}

.form-field input:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.form-field textarea {
  min-height: 130px;
  resize: vertical;
}

.form-note {
  display: none;
  margin-top: 16px;
  padding: 14px 18px;
  border-radius: 8px;
  background-color: var(--accent-dim);
  color: var(--accent-bright);
  font-size: 14px;
  font-weight: 600;
}

.form-note.show {
  display: block;
}

/* --------------------------------------------------------------------------
   Footer — newsletter band + multi-column
   -------------------------------------------------------------------------- */
.site-footer {
  background-color: #080B10;
  border-top: 1px solid var(--border);
}

.newsletter-band {
  padding: 48px 0;
  border-bottom: 1px solid var(--border);
}

.newsletter-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}

.newsletter-inner h3 {
  font-size: 24px;
  margin-bottom: 6px;
}

.newsletter-inner p {
  color: var(--muted);
  font-size: 15px;
}

.newsletter-form {
  display: flex;
  gap: 10px;
}

.newsletter-form input {
  width: 280px;
  max-width: 100%;
  background-color: var(--bg);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 13px 16px;
  font-size: 15px;
  color: var(--text);
}

.newsletter-form input:focus {
  outline: none;
  border-color: var(--accent);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  padding: 64px 0 48px;
}

.footer-brand p {
  color: var(--muted);
  font-size: 15px;
  margin: 18px 0 24px;
  max-width: 320px;
}

.footer-col h4 {
  font-size: 15px;
  margin-bottom: 18px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--heading);
}

.footer-col ul {
  list-style: none;
  display: grid;
  gap: 12px;
}

.footer-col ul a {
  color: var(--muted);
  font-size: 15px;
}

.footer-col ul a:hover {
  color: var(--accent);
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 26px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-bottom p {
  font-size: 14px;
  color: var(--muted);
}

.footer-legal-links {
  display: flex;
  gap: 24px;
}

.footer-legal-links a {
  font-size: 14px;
  color: var(--muted);
}

.footer-legal-links a:hover {
  color: var(--accent);
}

/* --------------------------------------------------------------------------
   Scroll reveal (safe without JS)
   -------------------------------------------------------------------------- */
.fade-up {
  opacity: 1;
  transform: none;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-up.pre-reveal {
  opacity: 0;
  transform: translateY(24px);
}

.fade-up.visible {
  opacity: 1;
  transform: none;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 960px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .metrics-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .metric {
    border-bottom: 1px solid var(--border);
  }

  .metric:nth-child(2) {
    border-right: none;
  }

  .metric:nth-child(3),
  .metric:nth-child(4) {
    border-bottom: none;
  }

  .sectors-grid {
    grid-template-columns: 1fr;
  }

  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .nav-cta {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background-color: #0D1119;
    border-bottom: 1px solid var(--border);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .site-nav.open {
    max-height: 420px;
  }

  .site-nav a {
    padding: 18px 24px;
    border-top: 1px solid var(--border);
    font-size: 16px;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .process-step {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .newsletter-form {
    flex-direction: column;
    width: 100%;
  }

  .newsletter-form input {
    width: 100%;
  }
}
