/* ── Design tokens ───────────────────────────────────────────── */
:root {
  --navy-950: #070d18;
  --navy-900: #0b1220;
  --navy-800: #111827;
  --navy-700: #1a2744;
  --navy-600: #1a4d7a;
  --slate-400: #94a3b8;
  --slate-300: #cbd5e1;
  --white: #f8fafc;
  --teal: #48b693;
  --teal-bright: #5fd4ad;
  --orange: #f97316;
  --orange-bright: #fb923c;

  --font: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
  --header-h: 72px;
  --container: min(1120px, 100% - 2rem);
  --transition: 0.2s ease;
}

/* ── Reset & base ────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--slate-300);
  background: var(--navy-900);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--teal-bright);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--white);
}

ul {
  list-style: none;
}

h1, h2, h3 {
  color: var(--white);
  line-height: 1.2;
  font-weight: 700;
}

h1 {
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.625rem, 3.5vw, 2.375rem);
  letter-spacing: -0.015em;
}

h3 {
  font-size: 1.125rem;
  font-weight: 600;
}

.container {
  width: var(--container);
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 9999;
  padding: 0.75rem 1rem;
  background: var(--teal);
  color: var(--navy-900);
  font-weight: 600;
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 1rem;
}

/* ── Header ──────────────────────────────────────────────────── */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  height: var(--header-h);
  background: rgba(11, 18, 32, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(72, 182, 147, 0.08);
  transition: background var(--transition), box-shadow var(--transition);
}

.site-header.scrolled {
  background: rgba(11, 18, 32, 0.95);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  height: 32px;
  width: auto;
}

.logo-footer {
  height: 28px;
  margin-bottom: 0.75rem;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 110;
}

.nav-toggle-bar {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.site-nav {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(7, 13, 24, 0.97);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.site-nav.open {
  opacity: 1;
  visibility: visible;
}

.nav-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.nav-list a {
  color: var(--slate-300);
  font-size: 1.25rem;
  font-weight: 500;
}

.nav-list a:hover {
  color: var(--teal-bright);
}

.nav-cta {
  padding: 0.625rem 1.5rem;
  background: var(--orange);
  color: var(--white) !important;
  border-radius: 999px;
  font-weight: 600 !important;
}

.nav-cta:hover {
  background: var(--orange-bright);
  color: var(--white) !important;
}

@media (min-width: 768px) {
  .nav-toggle {
    display: none;
  }

  .site-nav {
    position: static;
    opacity: 1;
    visibility: visible;
    background: none;
    inset: auto;
  }

  .nav-list {
    flex-direction: row;
    align-items: center;
    gap: 2rem;
  }

  .nav-list a {
    font-size: 0.9375rem;
  }

  .nav-cta {
    font-size: 0.9375rem !important;
  }
}

/* ── Buttons ─────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.875rem 1.75rem;
  font-family: var(--font);
  font-size: 0.9375rem;
  font-weight: 600;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--orange), var(--orange-bright));
  color: var(--white);
  box-shadow: 0 4px 20px rgba(249, 115, 22, 0.35);
}

.btn-primary:hover {
  color: var(--white);
  box-shadow: 0 8px 28px rgba(249, 115, 22, 0.45);
}

.btn-secondary {
  background: transparent;
  color: var(--white);
  border: 1px solid rgba(72, 182, 147, 0.4);
}

.btn-secondary:hover {
  border-color: var(--teal);
  color: var(--teal-bright);
  background: rgba(72, 182, 147, 0.08);
}

.btn-full {
  width: 100%;
}

/* ── Hero ────────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 3rem) 0 4rem;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 70% 20%, rgba(72, 182, 147, 0.12), transparent),
    radial-gradient(ellipse 50% 40% at 20% 80%, rgba(249, 115, 22, 0.06), transparent),
    linear-gradient(180deg, var(--navy-950) 0%, var(--navy-900) 100%);
  pointer-events: none;
}

.hero-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(72, 182, 147, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(72, 182, 147, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 70% at 50% 40%, black, transparent);
}

.hero-inner {
  position: relative;
  display: grid;
  gap: 3rem;
  align-items: center;
}

.hero-eyebrow {
  display: inline-block;
  margin-bottom: 1rem;
  padding: 0.375rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--teal-bright);
  background: rgba(72, 182, 147, 0.1);
  border: 1px solid rgba(72, 182, 147, 0.2);
  border-radius: 999px;
}

.hero-lead {
  margin-top: 1.25rem;
  max-width: 36rem;
  font-size: 1.0625rem;
  color: var(--slate-400);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.875rem;
  margin-top: 2rem;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.hero-stats li {
  text-align: left;
}

.stat-value {
  display: block;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--teal-bright);
}

.stat-label {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.75rem;
  color: var(--slate-400);
  line-height: 1.3;
}

.hero-visual {
  display: flex;
  justify-content: center;
}

.edge-card,
.device-card {
  width: 100%;
  max-width: 380px;
  padding: 1.5rem;
  background: rgba(17, 24, 39, 0.8);
  border: 1px solid rgba(72, 182, 147, 0.15);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.edge-card-header,
.device-card-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--slate-400);
}

.context-switch {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  margin-bottom: 1.25rem;
  padding: 0.75rem;
  background: rgba(11, 18, 32, 0.6);
  border-radius: var(--radius);
  overflow-x: auto;
}

.context {
  flex-shrink: 0;
  padding: 0.5rem 0.625rem;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  opacity: 0.5;
  transition: opacity var(--transition), border-color var(--transition);
}

.context.active {
  opacity: 1;
  border-color: var(--teal);
  background: rgba(72, 182, 147, 0.08);
}

.context-label {
  display: block;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--teal-bright);
}

.context-type {
  display: block;
  margin-top: 0.125rem;
  font-size: 0.75rem;
  color: var(--slate-400);
}

.context-switch-arrow {
  flex-shrink: 0;
  font-size: 0.75rem;
  color: var(--slate-400);
  opacity: 0.5;
}

.edge-metrics,
.device-metrics {
  display: grid;
  gap: 0.875rem;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background: var(--teal);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(72, 182, 147, 0.5); }
  50% { opacity: 0.8; box-shadow: 0 0 0 6px rgba(72, 182, 147, 0); }
}

.metric {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.625rem 0.875rem;
  background: rgba(11, 18, 32, 0.6);
  border-radius: var(--radius);
}

.metric-label {
  font-size: 0.8125rem;
  color: var(--slate-400);
}

.metric-value {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--white);
}

.metric-ok {
  color: var(--teal-bright);
}

@media (min-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }

  .hero-visual {
    justify-content: flex-end;
  }
}

/* ── Sections ────────────────────────────────────────────────── */
.section {
  padding: 5rem 0;
}

.section-header {
  max-width: 640px;
  margin-bottom: 3rem;
}

.section-eyebrow {
  display: inline-block;
  margin-bottom: 0.75rem;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--teal);
}

.section-lead {
  margin-top: 1rem;
  color: var(--slate-400);
}

.section-header-center {
  text-align: center;
  margin-inline: auto;
}

/* ── About ─────────────────────────────────────────────────────── */
.about {
  background: var(--navy-800);
  border-block: 1px solid rgba(255, 255, 255, 0.04);
}

.about-grid {
  display: grid;
  gap: 3rem;
}

.about-copy p + p {
  margin-top: 1rem;
}

.about-quote {
  padding: 2rem;
  background: rgba(11, 18, 32, 0.5);
  border-left: 3px solid var(--teal);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}

.about-quote p {
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.5;
  color: var(--white);
  font-style: italic;
}

@media (min-width: 768px) {
  .about-grid {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

/* ── What We Do ────────────────────────────────────────────────── */
.what-we-do {
  background: var(--navy-900);
}

.card-grid {
  display: grid;
  gap: 1.25rem;
}

.card {
  padding: 1.75rem;
  background: var(--navy-800);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
  transition: border-color var(--transition), transform var(--transition);
}

.card:hover {
  border-color: rgba(72, 182, 147, 0.25);
  transform: translateY(-2px);
}

.card-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 1.25rem;
  padding: 10px;
  color: var(--teal-bright);
  background: rgba(72, 182, 147, 0.1);
  border-radius: var(--radius);
}

.card-icon svg {
  width: 100%;
  height: 100%;
}

.card h3 {
  margin-bottom: 0.625rem;
}

.card p {
  font-size: 0.9375rem;
  color: var(--slate-400);
}

@media (min-width: 640px) {
  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

/* ── Why Xerge pillars ─────────────────────────────────────────── */
.why-pillars {
  display: grid;
  gap: 1rem;
}

.pillar {
  padding: 1.5rem;
  background: rgba(11, 18, 32, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
  transition: border-color var(--transition);
}

.pillar:hover {
  border-color: rgba(72, 182, 147, 0.2);
}

.pillar-value {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--teal-bright);
}

.pillar h3 {
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.pillar p {
  font-size: 0.875rem;
  color: var(--slate-400);
}

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

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

  .pillar:last-child {
    grid-column: auto;
  }
}

/* ── Industries ────────────────────────────────────────────────── */
.industries {
  background:
    radial-gradient(ellipse 60% 50% at 50% 100%, rgba(26, 77, 122, 0.15), transparent),
    var(--navy-900);
  border-block: 1px solid rgba(255, 255, 255, 0.04);
}

.industry-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.875rem;
}

.industry-tile {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 72px;
  padding: 1rem 1.25rem;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--white);
  text-align: center;
  background: rgba(17, 24, 39, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius);
  transition: border-color var(--transition), background var(--transition);
}

.industry-tile:hover {
  border-color: rgba(72, 182, 147, 0.25);
  background: rgba(72, 182, 147, 0.06);
}

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

@media (min-width: 900px) {
  .industry-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

/* ── IT & Tech Services ────────────────────────────────────────── */
.services {
  background: var(--navy-800);
  border-block: 1px solid rgba(255, 255, 255, 0.04);
}

.services-layout {
  display: grid;
  gap: 2.5rem;
}

.services-intro p:last-of-type {
  margin-top: 1rem;
  color: var(--slate-400);
}

.services-list {
  display: grid;
  gap: 1rem;
}

.services-list li {
  padding: 1.25rem 1.5rem;
  background: rgba(11, 18, 32, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius);
}

.services-list strong {
  display: block;
  margin-bottom: 0.375rem;
  color: var(--white);
  font-weight: 600;
}

.services-list span {
  font-size: 0.9375rem;
  color: var(--slate-400);
}

@media (min-width: 768px) {
  .services-layout {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

/* ── Why Xerge ─────────────────────────────────────────────────── */
.why {
  background: var(--navy-800);
  border-block: 1px solid rgba(255, 255, 255, 0.04);
}

/* ── Contact ───────────────────────────────────────────────────── */
.contact-layout {
  display: grid;
  gap: 3rem;
}

.contact-info > p {
  margin-top: 1rem;
  color: var(--slate-400);
}

.contact-details {
  margin-top: 2rem;
  display: grid;
  gap: 1.25rem;
}

.contact-details li {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.contact-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--slate-400);
}

.contact-details a {
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--white);
}

.contact-details a:hover {
  color: var(--teal-bright);
}

.contact-form {
  padding: 2rem;
  background: var(--navy-800);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
}

.form-row {
  margin-bottom: 1.25rem;
}

.form-row label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--white);
}

.optional {
  font-weight: 400;
  color: var(--slate-400);
}

.form-row input,
.form-row textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: var(--font);
  font-size: 0.9375rem;
  color: var(--white);
  background: var(--navy-900);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-row input:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(72, 182, 147, 0.15);
}

.form-row input.error,
.form-row textarea.error {
  border-color: var(--orange);
}

.form-row textarea {
  resize: vertical;
  min-height: 100px;
}

.form-status {
  margin-top: 1rem;
  font-size: 0.875rem;
  text-align: center;
  min-height: 1.25rem;
}

.form-status.success {
  color: var(--teal-bright);
}

.form-status.error {
  color: var(--orange-bright);
}

@media (min-width: 768px) {
  .contact-layout {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

/* ── Footer ────────────────────────────────────────────────────── */
.site-footer {
  padding: 3rem 0 2rem;
  background: var(--navy-950);
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.footer-inner {
  display: grid;
  gap: 2rem;
}

.footer-brand p {
  font-size: 0.875rem;
  color: var(--slate-400);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--slate-400);
}

.footer-links a:hover {
  color: var(--teal-bright);
}

.footer-copy {
  font-size: 0.8125rem;
  color: var(--slate-400);
  opacity: 0.7;
}

@media (min-width: 640px) {
  .footer-inner {
    grid-template-columns: 1fr auto;
    align-items: start;
  }

  .footer-copy {
    grid-column: 1 / -1;
  }
}
