@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue:wght@400&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --background: #0a0e17;
  --foreground: #f4f4f5;
  --card: #10152280;
  --card-solid: #101522;
  --primary: #1aa3e8;
  --primary-foreground: #ffffff;
  --muted: #0d1220;
  --muted-foreground: #9aa5b8;
  --border: #202a3d;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-heading: "Bebas Neue", -apple-system, BlinkMacSystemFont, sans-serif;
  --max-width: 1280px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { margin: 0; font-family: var(--font-heading); letter-spacing: 0.01em; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { margin: 0; padding: 0; list-style: none; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}
@media (min-width: 1024px) {
  .container { padding: 0 32px; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 28px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  border: none;
  transition: background-color .2s ease, border-color .2s ease, opacity .2s ease;
  font-family: var(--font-sans);
}
.btn-primary { background: var(--primary); color: var(--primary-foreground); }
.btn-primary:hover { background: #1590cf; }
.btn-outline { background: transparent; color: var(--primary); border: 1px solid var(--primary); }
.btn-outline:hover { background: rgba(26,163,232,0.1); }
.btn:disabled { opacity: .6; cursor: not-allowed; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
.eyebrow .rule { width: 32px; height: 1px; background: var(--primary); }
.eyebrow span { color: var(--primary); font-size: 12px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; }

.section-heading { font-size: clamp(1.75rem, 3vw, 2.25rem); font-weight: 700; color: var(--foreground); }

.hairline {
  position: relative;
  height: 1px;
  width: 100%;
  background: var(--border);
  overflow: hidden;
}
.hairline::after {
  content: '';
  position: absolute;
  top: 0; left: 40%;
  height: 1px; width: 128px;
  background: linear-gradient(to right, transparent, var(--primary), transparent);
}

/* Header */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  background: rgba(10,14,23,0.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, background-color .2s ease;
}
.site-header.scrolled { border-bottom-color: var(--border); }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}
.logo-link { display: flex; align-items: center; gap: 12px; min-width: 0; }
.logo-link img { height: 40px; width: auto; max-width: 200px; object-fit: contain; }
.main-nav { display: none; align-items: center; gap: 32px; }
.main-nav a {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--muted-foreground);
  transition: color .2s ease;
}
.main-nav a:hover, .main-nav a.active { color: var(--foreground); }
.main-nav .btn { margin-left: 8px; }
.nav-toggle {
  display: flex;
  background: none;
  border: none;
  color: var(--muted-foreground);
  cursor: pointer;
  padding: 4px;
}
@media (min-width: 768px) {
  .main-nav { display: flex; }
  .nav-toggle { display: none; }
}
.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 16px 24px 24px;
  border-top: 1px solid var(--border);
  background: var(--background);
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  padding: 10px 0;
  font-size: 15px;
  color: var(--muted-foreground);
}
.mobile-menu a:hover { color: var(--foreground); }

/* Hero (inner pages) */
.page-hero {
  position: relative;
  padding: 150px 0 88px;
  overflow: hidden;
  background: var(--background);
}
.page-hero .dotgrid {
  position: absolute; inset: 0;
  background-image: radial-gradient(circle, rgba(26,163,232,0.10) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}
.page-hero .accent-rule {
  position: absolute; top: 0; right: 0; width: 1px; height: 100%;
  background: linear-gradient(to bottom, transparent, rgba(26,163,232,0.2), transparent);
}
.page-hero .accent-rule.left { right: auto; left: 0; }
.page-hero .content { position: relative; z-index: 1; max-width: 720px; }
.page-hero h1 { font-size: clamp(2.5rem, 6vw, 3.75rem); font-weight: 700; color: var(--foreground); margin-bottom: 20px; }
.page-hero p { color: var(--muted-foreground); font-size: 1.125rem; line-height: 1.7; max-width: 640px; }

/* Home hero */
.home-hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding-top: 96px;
  background: var(--background);
}
.home-hero .bg-image {
  position: absolute; inset: 0; z-index: 0;
}
.home-hero .bg-image img { width: 100%; height: 100%; object-fit: cover; opacity: 0.2; }
.home-hero .bg-image .fade {
  position: absolute; inset: 0;
  background: linear-gradient(to right, var(--background) 20%, rgba(10,14,23,0.8) 55%, rgba(10,14,23,0.35));
}
.home-hero .dotgrid {
  position: absolute; inset: 0; z-index: 0;
  background-image: radial-gradient(circle, rgba(26,163,232,0.12) 1px, transparent 1px);
  background-size: 40px 40px;
}
.home-hero .grid-wrap {
  position: relative; z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  padding: 96px 0;
  width: 100%;
}
@media (min-width: 1024px) {
  .home-hero .grid-wrap { grid-template-columns: 1fr 1fr; align-items: center; gap: 64px; }
}
.home-hero h1 { font-size: clamp(2.5rem, 6vw, 4rem); font-weight: 700; line-height: 1.1; color: var(--foreground); margin-bottom: 24px; }
.home-hero .sub { color: var(--muted-foreground); font-size: 1.125rem; line-height: 1.7; max-width: 560px; margin-bottom: 40px; }
.home-hero .cta-row { display: flex; flex-wrap: wrap; gap: 16px; }
.hero-visual { display: none; }
@media (min-width: 1024px) {
  .hero-visual {
    display: block; position: relative;
    border-radius: 16px;
    background: rgba(26,163,232,0.05);
    border: 1px solid rgba(26,163,232,0.2);
    padding: 40px;
    min-height: 280px;
  }
  .hero-visual svg { width: 100%; height: 100%; }
  .hero-visual .corner { position: absolute; width: 16px; height: 16px; border-color: rgba(26,163,232,0.6); }
  .hero-visual .corner.tl { top: 12px; left: 12px; border-top: 2px solid; border-left: 2px solid; }
  .hero-visual .corner.tr { top: 12px; right: 12px; border-top: 2px solid; border-right: 2px solid; }
  .hero-visual .corner.bl { bottom: 12px; left: 12px; border-bottom: 2px solid; border-left: 2px solid; }
  .hero-visual .corner.br { bottom: 12px; right: 12px; border-bottom: 2px solid; border-right: 2px solid; }
  .hero-visual .signal { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 8px; }
  .hero-visual .signal .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--primary); }
  .hero-visual .signal span { font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(26,163,232,0.7); font-family: var(--font-mono, monospace); }
}

/* Generic sections */
.section { padding: 96px 0; }
.section.bg-muted { background: var(--muted); }
.section-head { margin-bottom: 56px; }
.section-head.center { text-align: center; }

/* Cards grid */
.cards-2 { display: grid; grid-template-columns: 1fr; gap: 32px; }
@media (min-width: 768px) { .cards-2 { grid-template-columns: 1fr 1fr; } }

.service-card {
  position: relative;
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 32px;
  padding-left: 40px;
  transition: border-color .3s ease;
}
.service-card:hover { border-color: rgba(26,163,232,0.5); }
.service-card::before {
  content: '';
  position: absolute; left: 0; top: 32px; bottom: 32px; width: 3px;
  background: var(--primary); border-radius: 4px;
}
.service-card .num { font-size: 2.75rem; font-weight: 700; color: rgba(26,163,232,0.2); line-height: 1; display: block; margin-bottom: 16px; font-family: var(--font-heading); }
.service-card h3 { font-size: 1.25rem; font-weight: 700; color: var(--foreground); margin-bottom: 12px; }
.service-card p { color: var(--muted-foreground); font-size: 0.9375rem; line-height: 1.7; }

.stat-grid { display: grid; grid-template-columns: 1fr; gap: 24px; }
@media (min-width: 640px) { .stat-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .stat-grid { grid-template-columns: repeat(4, 1fr); } }
.stat-card {
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 24px;
  transition: border-color .3s ease;
}
.stat-card:hover { border-color: rgba(26,163,232,0.4); }
.stat-card .stat { font-size: 2.25rem; font-weight: 700; color: var(--primary); display: block; margin-bottom: 8px; font-family: var(--font-heading); }
.stat-card .label { font-size: 0.9375rem; font-weight: 600; color: var(--foreground); display: block; margin-bottom: 8px; }
.stat-card .detail { font-size: 0.8125rem; color: var(--muted-foreground); line-height: 1.5; }

.area-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 768px) { .area-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .area-grid { grid-template-columns: repeat(3, 1fr); } }
.area-card {
  position: relative;
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 24px;
  padding-left: 32px;
  transition: border-color .3s ease;
}
.area-card:hover { border-color: rgba(26,163,232,0.4); }
.area-card::before {
  content: '';
  position: absolute; left: 0; top: 24px; bottom: 24px; width: 2px;
  background: rgba(26,163,232,0.4); border-radius: 4px;
}
.area-card h3 { font-size: 0.9375rem; font-weight: 600; color: var(--foreground); margin-bottom: 8px; }
.area-card p { font-size: 0.8125rem; color: var(--muted-foreground); line-height: 1.6; }

/* Process steps */
.process-grid { display: grid; grid-template-columns: 1fr; gap: 32px; }
@media (min-width: 768px) { .process-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .process-grid { grid-template-columns: repeat(4, 1fr); } }
.process-step .step-num { font-size: 1rem; font-weight: 700; color: var(--primary); font-family: var(--font-heading); display: block; margin-bottom: 12px; }
.process-step h3 { font-size: 1.125rem; font-weight: 700; color: var(--foreground); margin-bottom: 10px; }
.process-step p { font-size: 0.875rem; color: var(--muted-foreground); line-height: 1.65; }

/* Principles */
.principle-card {
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px;
}
.principle-card .step-num { color: var(--primary); font-family: var(--font-heading); font-size: 1.5rem; display: block; margin-bottom: 12px; }
.principle-card h3 { font-size: 1.0625rem; font-weight: 700; margin-bottom: 10px; color: var(--foreground); }
.principle-card p { font-size: 0.875rem; color: var(--muted-foreground); line-height: 1.65; }
.principle-grid { display: grid; grid-template-columns: 1fr; gap: 24px; }
@media (min-width: 768px) { .principle-grid { grid-template-columns: repeat(3, 1fr); } }

/* Case studies */
.case-article {
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  transition: border-color .3s ease;
}
.case-article:hover { border-color: rgba(26,163,232,0.4); }
.case-article .top-rule { height: 3px; background: linear-gradient(to right, rgba(26,163,232,0.8), rgba(26,163,232,0.3), transparent); }
.case-article .inner { padding: 40px; }
.case-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 32px; }
.case-head-left { display: flex; align-items: center; gap: 16px; }
.case-num { font-size: 2.5rem; font-weight: 700; color: rgba(26,163,232,0.15); line-height: 1; font-family: var(--font-heading); }
.case-tag { padding: 4px 14px; font-size: 0.75rem; font-weight: 600; color: var(--primary); border: 1px solid rgba(26,163,232,0.3); border-radius: 999px; background: rgba(26,163,232,0.05); }
.case-article h2 { font-size: 1.375rem; font-weight: 700; color: var(--foreground); margin-bottom: 32px; max-width: 700px; }
.case-details { display: grid; grid-template-columns: 1fr; gap: 28px; margin-bottom: 40px; }
@media (min-width: 768px) { .case-details { grid-template-columns: repeat(3, 1fr); } }
.case-details .kicker { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.case-details .kicker .rule { width: 16px; height: 1px; background: rgba(26,163,232,0.6); }
.case-details .kicker span { font-size: 0.75rem; font-weight: 600; color: rgba(26,163,232,0.8); letter-spacing: 0.2em; text-transform: uppercase; }
.case-details p { font-size: 0.875rem; color: var(--muted-foreground); line-height: 1.7; }
.case-metrics { border-top: 1px solid var(--border); padding-top: 24px; display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 640px) { .case-metrics { grid-template-columns: repeat(3, 1fr); } }
.metric { display: flex; align-items: baseline; gap: 12px; }
.metric .value { font-size: 1.5rem; font-weight: 700; color: var(--primary); font-family: var(--font-heading); }
.metric .label { font-size: 0.75rem; color: var(--muted-foreground); line-height: 1.4; }
.case-list { display: flex; flex-direction: column; gap: 48px; }

/* CTA band */
.cta-band {
  padding: 88px 0;
  background: var(--background);
  position: relative;
  overflow: hidden;
}
.cta-band .dotgrid {
  position: absolute; inset: 0;
  background-image: radial-gradient(circle, rgba(26,163,232,0.08) 1px, transparent 1px);
  background-size: 32px 32px;
}
.cta-inner { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; gap: 32px; }
@media (min-width: 1024px) { .cta-inner { flex-direction: row; align-items: center; } }
.cta-inner h2 { font-size: clamp(1.75rem, 3.5vw, 2.25rem); font-weight: 700; color: var(--foreground); margin-bottom: 12px; max-width: 560px; }
.cta-inner p { color: var(--muted-foreground); }

@media (min-width: 1024px) {
  .about-story-grid { grid-template-columns: 1fr 1fr !important; gap: 64px !important; }
}

/* Contact page */
.contact-grid { display: grid; grid-template-columns: 1fr; gap: 56px; }
@media (min-width: 1024px) { .contact-grid { grid-template-columns: 2fr 3fr; } }
.contact-info h2 { font-size: 1.5rem; font-weight: 700; margin-bottom: 28px; color: var(--foreground); }
.contact-item { display: flex; flex-direction: column; gap: 4px; margin-bottom: 22px; }
.contact-item .label { font-size: 0.75rem; font-weight: 600; color: var(--primary); letter-spacing: 0.2em; text-transform: uppercase; }
.contact-item .value { font-size: 0.9375rem; color: var(--foreground); }
.contact-item .value a { color: var(--foreground); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--border); }
.contact-item .value a:hover { color: var(--primary); text-decoration-color: var(--primary); }

.contact-form-card {
  position: relative;
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 40px;
}
.contact-form-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(to right, rgba(26,163,232,0.8), rgba(26,163,232,0.3), transparent);
  border-radius: 8px 8px 0 0;
}
.contact-form-card h2 { font-size: 1.25rem; font-weight: 700; margin-bottom: 4px; color: var(--foreground); }
.contact-form-card > p { font-size: 0.875rem; color: var(--muted-foreground); margin-bottom: 28px; }
.form-row { display: grid; grid-template-columns: 1fr; gap: 20px; margin-bottom: 20px; }
@media (min-width: 640px) { .form-row.two { grid-template-columns: 1fr 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 0.75rem; font-weight: 600; color: var(--muted-foreground); letter-spacing: 0.05em; text-transform: uppercase; }
.field label .req { color: var(--primary); }
.field input, .field select, .field textarea {
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 11px 14px;
  font-size: 0.875rem;
  color: var(--foreground);
  font-family: var(--font-sans);
}
.field input::placeholder, .field textarea::placeholder { color: rgba(154,165,184,0.5); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--primary); }
.field textarea { resize: vertical; min-height: 120px; }
.field select { appearance: none; cursor: pointer; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1 1L6 6L11 1' stroke='%239aa5b8' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
.form-status { font-size: 0.875rem; margin-top: 4px; display: none; }
.form-status.success { color: #34d399; display: block; }
.form-status.error { color: #f87171; display: block; }

/* Footer */
.site-footer { background: var(--background); border-top: 1px solid var(--border); }
.footer-top { padding: 48px 0; display: flex; flex-direction: column; align-items: center; gap: 32px; text-align: center; }
@media (min-width: 768px) { .footer-top { flex-direction: row; align-items: flex-start; justify-content: space-between; text-align: left; } }
.footer-brand { display: flex; flex-direction: column; align-items: center; gap: 12px; }
@media (min-width: 768px) { .footer-brand { align-items: flex-start; } }
.footer-brand img { height: 36px; width: auto; max-width: 180px; object-fit: contain; }
.footer-brand p { font-size: 0.75rem; color: var(--muted-foreground); letter-spacing: 0.02em; }
.footer-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 24px; }
@media (min-width: 768px) { .footer-nav { justify-content: flex-end; } }
.footer-nav a { font-size: 0.875rem; color: var(--muted-foreground); }
.footer-nav a:hover { color: var(--foreground); }
.footer-bottom {
  margin-top: 8px;
  padding: 24px 0 40px;
  border-top: 1px solid var(--border);
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  text-align: center;
}
@media (min-width: 768px) { .footer-bottom { flex-direction: row; justify-content: space-between; text-align: left; } }
.footer-bottom p { font-size: 0.75rem; color: var(--muted-foreground); }

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