/* Capital AI Solutions - quiet gray studio */

:root {
  --paper: #f2f2f0;
  --paper-deep: #e6e6e2;
  --ink: #111111;
  --ink-soft: #5c5c5c;
  --ink-faint: #8a8a8a;
  --accent: #0b6efd;
  --accent-hover: #0958d0;
  --rust: #d15a12;
  --line: #d4d4d0;
  --sans: "IBM Plex Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --max: 1080px;
  --radius: 4px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.55;
  color: var(--ink);
  background:
    linear-gradient(180deg, #f7f7f5 0%, var(--paper) 28%, var(--paper) 100%);
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: color-mix(in srgb, var(--accent) 22%, #fff);
  color: var(--ink);
}

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

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

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

a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.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;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--ink);
  color: #fff;
  padding: 0.5rem 1rem;
}

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

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

@media (min-width: 720px) {
  .wrap {
    width: min(100% - 3rem, var(--max));
  }
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 90%, transparent);
  border-bottom: 1px solid transparent;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
  background: color-mix(in srgb, var(--paper) 94%, transparent);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 0.85rem 0;
}

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

.logo-mark {
  width: 1.85rem;
  height: 1.85rem;
  flex-shrink: 0;
}

.wordmark:hover {
  color: var(--ink);
}

.nav {
  display: none;
  align-items: center;
  gap: 1.35rem;
}

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

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

.nav-cta {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 0.95rem;
  background: var(--accent);
  color: #fff !important;
  border: 0;
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 600 !important;
  cursor: pointer;
  transition: background 0.15s var(--ease);
}

.nav-cta:hover {
  background: var(--accent-hover);
  color: #fff !important;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 2.4rem;
  height: 2.4rem;
  padding: 0;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 1rem;
  height: 1.5px;
  margin-inline: auto;
  background: var(--ink);
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  padding: 0 1rem 1rem;
  border-top: 1px solid var(--line);
  background: var(--paper);
}

.mobile-nav[hidden] {
  display: none;
}

.mobile-nav a,
.mobile-nav button {
  color: var(--ink);
  text-decoration: none;
  padding: 0.8rem 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
}

.mobile-nav button:last-child {
  border-bottom: none;
  color: var(--accent);
  font-weight: 600;
}

@media (min-width: 900px) {
  .nav {
    display: flex;
  }

  .nav-toggle,
  .mobile-nav {
    display: none !important;
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 1.4rem;
  border-radius: var(--radius);
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.15s var(--ease), border-color 0.15s var(--ease),
    color 0.15s var(--ease);
}

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

.btn-primary:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: #fff;
}

.btn-secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink);
}

.btn-secondary:hover {
  background: var(--paper-deep);
}

.btn:disabled {
  opacity: 0.65;
  cursor: wait;
}

/* Hero */
.hero {
  position: relative;
  padding: 3rem 0 0;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 55% at 85% 15%, color-mix(in srgb, var(--accent) 12%, transparent) 0%, transparent 72%),
    radial-gradient(ellipse 50% 45% at 8% 70%, color-mix(in srgb, var(--rust) 9%, transparent) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.hero .wrap {
  position: relative;
  z-index: 1;
  padding-bottom: 3rem;
  border-bottom: 2px solid var(--ink);
}

.hero-body {
  display: grid;
  gap: 1.5rem;
  max-width: none;
  padding: 0;
  border-top: 0;
}

@media (min-width: 800px) {
  .hero {
    padding-top: 4rem;
  }

  .hero .wrap {
    padding-bottom: 3.75rem;
  }

  .hero-body {
    grid-template-columns: 1.2fr 0.8fr;
    gap: 3rem;
    align-items: end;
  }

  .hero-copy {
    max-width: 34rem;
  }

  .hero-actions {
    justify-content: flex-end;
    padding-bottom: 0.15rem;
  }
}

.locale {
  margin: 0 0 0.7rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ink-faint);
}

.hero h1 {
  margin: 0 0 0.85rem;
  font-weight: 700;
  font-size: clamp(2.1rem, 5vw, 3.15rem);
  line-height: 1.08;
  letter-spacing: -0.04em;
  text-wrap: balance;
}

.lead {
  margin: 0;
  font-size: 1.12rem;
  font-weight: 300;
  color: var(--ink-soft);
  line-height: 1.5;
  text-wrap: pretty;
  max-width: 30rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* Bands */
.band {
  padding: 3.5rem 0;
  border-top: 1px solid var(--line);
}

.band--tint {
  background: var(--paper-deep);
  border-top-color: transparent;
}

.band-title {
  margin: 0 0 1.75rem;
  font-size: clamp(1.55rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

/* Service ledger */
.ledger {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--ink);
}

.ledger li {
  display: grid;
  gap: 0.35rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--line);
}

@media (min-width: 720px) {
  .ledger li {
    grid-template-columns: minmax(12rem, 0.42fr) 1fr;
    gap: 2rem;
    align-items: baseline;
    padding: 1.55rem 0;
  }
}

.ledger h3 {
  margin: 0;
  font-size: 1.12rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.ledger p {
  margin: 0;
  color: var(--ink-soft);
  max-width: 38rem;
}

/* Steps */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 860px) {
  .steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.75rem;
  }
}

.steps li {
  display: grid;
  gap: 0.75rem;
  padding: 0;
  border: 0;
  background: transparent;
}

.steps-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
}

.steps h3 {
  margin: 0 0 0.35rem;
  font-size: 1.12rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.steps p {
  margin: 0;
  color: var(--ink-soft);
  max-width: 22rem;
}

/* FAQ */
.faq-stack {
  border-top: 1px solid var(--ink);
}

.faq-item {
  border-bottom: 1px solid var(--line);
}

.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 1.15rem 2rem 1.15rem 0;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  position: relative;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.2rem;
  font-weight: 400;
  color: var(--accent);
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item summary:hover {
  color: var(--accent);
}

.faq-item p {
  margin: 0 0 1.15rem;
  color: var(--ink-soft);
  max-width: 36rem;
  padding-right: 1.5rem;
}

/* Contact */
.contact {
  padding: 3.25rem 0;
  background: var(--ink);
  color: #fff;
}

.contact-row {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  align-items: flex-start;
}

@media (min-width: 720px) {
  .contact-row {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
  }
}

.contact h2 {
  margin: 0 0 0.55rem;
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  letter-spacing: -0.025em;
  color: #fff;
}

.contact p {
  margin: 0;
}

.contact a {
  color: #fff;
  font-weight: 600;
}

.contact a:hover {
  color: #cfe0ff;
}

/* Footer */
.site-footer {
  padding: 1.5rem 0 2rem;
  background: var(--paper);
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  align-items: baseline;
  justify-content: space-between;
}

.footer-mark {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--ink);
}

.footer-mark .logo-mark {
  width: 1.4rem;
  height: 1.4rem;
}

.footer-inner p:last-child {
  margin: 0;
  font-size: 0.88rem;
  color: var(--ink-faint);
}

/* Soft reveal */
.reveal {
  opacity: 0.35;
  transform: translateY(12px);
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Lead dialog */
.lead-dialog {
  width: min(100% - 1.5rem, 28.5rem);
  max-height: min(90vh, 42rem);
  overflow: auto;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--ink);
  box-shadow: none;
}

.lead-dialog::backdrop {
  background: color-mix(in srgb, var(--ink) 45%, transparent);
}

.lead-dialog__panel {
  position: relative;
  padding: 1.5rem 1.4rem 1.35rem;
}

.lead-dialog__close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  padding: 0.2rem 0;
  border: 0;
  background: transparent;
  color: var(--ink-soft);
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
}

.lead-dialog__close:hover {
  color: var(--ink);
}

.lead-dialog h2 {
  margin: 0 1.5rem 0.4rem 0;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.lead-dialog__lede {
  margin: 0 0 1.15rem;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

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

.lead-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin: 0 0 0.7rem;
  padding: 0;
  border: 0;
  min-inline-size: 0;
}

.lead-field[hidden] {
  display: none;
}

.lead-field span,
.lead-field legend {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink);
  padding: 0;
}

.lead-field em,
.lead-hint {
  font-style: normal;
  font-weight: 500;
  color: var(--ink-faint);
}

.lead-field input,
.lead-field textarea {
  width: 100%;
  padding: 0.65rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  font-family: inherit;
  font-size: 1rem;
}

.lead-field textarea {
  resize: vertical;
  min-height: 4.25rem;
}

.lead-slots {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.lead-actions {
  position: sticky;
  bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.7rem;
  margin-top: 0.25rem;
  padding-top: 0.65rem;
  background: var(--paper);
}

.lead-slot {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0;
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  cursor: pointer;
  font-size: 0.9rem;
}

.lead-slot:has(input:checked) {
  border-color: var(--ink);
}

.lead-slot input {
  width: auto;
  accent-color: var(--accent);
}

.lead-error {
  margin: 0 0 0.85rem;
  color: #9b1c1c;
  font-size: 0.9rem;
}

.lead-mail-fallback {
  font-size: 0.88rem;
  color: var(--ink-soft);
}

.lead-success p {
  margin: 0 0 1rem;
}

@media (min-width: 720px) {
  .lead-dialog__panel {
    padding: 1.7rem 1.6rem 1.5rem;
  }
}

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

  .reveal {
    animation: none !important;
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .btn,
  .nav-cta {
    transition: none !important;
  }
}
