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

/* === Design tokens === */
:root {
  --bg:           #0f172a;
  --bg-card:      #1e293b;
  --border:       #334155;
  --text-1:       #f8fafc;
  --text-2:       #94a3b8;
  --text-muted:   #475569;
  --accent:       #3b82f6;
  --accent-hi:    #60a5fa;
  --accent-glow:  rgba(59, 130, 246, 0.14);
  --font-display: 'Outfit', sans-serif;
  --font-body:    'DM Sans', sans-serif;
  --ease:         200ms ease;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text-2);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* === Scroll-reveal === */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

.reveal--delay-1 { transition-delay: 0.1s; }
.reveal--delay-2 { transition-delay: 0.2s; }
.reveal--delay-3 { transition-delay: 0.32s; }

/* === Navigation === */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid transparent;
  transition: border-color var(--ease), background var(--ease);
}

.nav.is-scrolled {
  background: rgba(15, 23, 42, 0.88);
  border-bottom-color: var(--border);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.nav__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1080px;
  margin: 0 auto;
  padding: 20px 48px;
}

.nav__brand {
  color: var(--text-1);
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.3px;
  line-height: 1.4;
  text-decoration: none;
  overflow: visible;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav__link {
  color: var(--text-2);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  position: relative;
  transition: color var(--ease);
}

.nav__link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 1px;
  background: currentColor;
  transition: width var(--ease);
}

.nav__link:hover { color: var(--text-1); }
.nav__link:hover::after { width: 100%; }

.nav__link.is-active {
  color: var(--accent);
}

.nav__link.is-active::after {
  width: 100%;
  background: var(--accent);
}

/* === Shared === */
.eyebrow {
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.section__inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 80px 48px;
}

.section__inner--narrow {
  max-width: 680px;
}

.section__heading {
  color: var(--text-1);
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 48px;
}

/* === Button === */
.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  padding: 13px 28px;
  border-radius: 7px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background var(--ease), transform var(--ease), box-shadow var(--ease);
}

.btn:hover {
  background: var(--accent-hi);
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(59, 130, 246, 0.4);
}

.btn:active {
  transform: none;
  box-shadow: none;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* === Hero === */
.hero {
  border-bottom: 1px solid var(--border);
  background: radial-gradient(ellipse at 0% 0%, rgba(59, 130, 246, 0.07) 0%, transparent 55%);
}

.hero__inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 104px 48px 100px;
}

.hero__headline {
  color: var(--text-1);
  font-family: var(--font-display);
  font-size: clamp(34px, 4.5vw, 50px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -1.5px;
  max-width: 640px;
  margin-bottom: 28px;
}

.hero__body {
  color: var(--text-2);
  font-size: 17px;
  line-height: 1.75;
  max-width: 560px;
  margin-bottom: 40px;
}

/* === Services === */
.services {
  border-bottom: 1px solid var(--border);
}

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

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 32px 28px;
  transition: border-color var(--ease), box-shadow var(--ease), transform var(--ease);
}

.card:hover {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent-glow), 0 8px 32px rgba(0, 0, 0, 0.3);
  transform: translateY(-2px);
}

/* Stagger card reveal */
.services__grid .card:nth-child(2).reveal { transition-delay: 0.1s; }
.services__grid .card:nth-child(3).reveal { transition-delay: 0.2s; }

.card__icon {
  color: var(--accent);
  font-size: 22px;
  line-height: 1;
  margin-bottom: 18px;
}

.card__title {
  color: var(--text-1);
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.2px;
  margin-bottom: 12px;
}

.card__body {
  color: var(--text-2);
  font-size: 14px;
  line-height: 1.7;
}

/* === Contact === */
.contact {
  border-bottom: 1px solid var(--border);
}

.contact__subtext {
  color: var(--text-2);
  font-size: 15px;
  margin-top: -32px;
  margin-bottom: 36px;
}

/* === Form === */
.form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form__group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form__label {
  color: var(--text-2);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.form__input {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-1);
  font-family: var(--font-body);
  font-size: 15px;
  padding: 13px 16px;
  width: 100%;
  outline: none;
  transition: border-color var(--ease), box-shadow var(--ease);
}

.form__input::placeholder {
  color: var(--text-muted);
}

.form__input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.form__textarea {
  resize: vertical;
  min-height: 120px;
}

.form__footer {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.form__success {
  display: none;
  color: #4ade80;
  font-size: 15px;
  padding: 14px 18px;
  background: rgba(74, 222, 128, 0.08);
  border: 1px solid rgba(74, 222, 128, 0.2);
  border-radius: 6px;
  margin-bottom: 8px;
}

.form__field-error {
  display: block;
  color: #f87171;
  font-size: 12px;
  min-height: 16px;
}

.form__status {
  font-size: 14px;
  line-height: 1.5;
  min-height: 20px;
}

.form__status--error { color: #f87171; }

/* === Footer === */
.footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1080px;
  margin: 0 auto;
  padding: 24px 48px;
}

.footer__copy,
.footer__email {
  color: var(--text-muted);
  font-size: 13px;
}

.footer__email {
  text-decoration: none;
  transition: color var(--ease);
}

.footer__email:hover {
  color: var(--text-2);
}

/* === Responsive === */
@media (max-width: 860px) {
  .services__grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .nav__inner,
  .hero__inner,
  .section__inner {
    padding-left: 24px;
    padding-right: 24px;
  }

  .footer__inner {
    padding-left: 24px;
    padding-right: 24px;
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }

  .hero__headline {
    letter-spacing: -0.8px;
  }
}
