/* ============ Design tokens ============ */
:root {
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
  --accent-2: #7c3aed;
  --accent-soft: #eff4ff;
  --grad: linear-gradient(135deg, #2563eb, #7c3aed);
  --grad-soft: linear-gradient(135deg, rgba(37, 99, 235, .1), rgba(124, 58, 237, .1));
  --ink: #0f172a;
  --body: #475569;
  --muted: #94a3b8;
  --line: #e6eaf2;
  --bg: #ffffff;
  --bg-alt: #f7f9fc;
  --white: #ffffff;

  --radius: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, .05), 0 1px 6px rgba(15, 23, 42, .04);
  --shadow: 0 4px 12px rgba(15, 23, 42, .05), 0 12px 32px rgba(15, 23, 42, .09);
  --shadow-lg: 0 8px 24px rgba(15, 23, 42, .08), 0 28px 70px rgba(37, 99, 235, .16);
  --shadow-btn: 0 4px 12px rgba(37, 99, 235, .3), 0 10px 28px rgba(124, 58, 237, .22);

  --space: clamp(1rem, 3vw, 2.5rem);
  --maxw: 1440px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: var(--font);
}

/* ============ Base ============ */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--body);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { color: var(--ink); line-height: 1.12; margin: 0; font-family: var(--font-display); }
h4 { font-family: var(--font-display); }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--space); }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: .78rem;
  font-weight: 700;
  color: var(--accent);
  margin: 0 0 .6rem;
}

.grad-text { color: var(--accent); }

/* ============ Buttons ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .7rem 1.25rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: .95rem;
  font-family: var(--font);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .25s ease, filter .25s ease, border-color .2s ease, color .2s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn--primary {
  background: var(--grad);
  color: var(--white);
  box-shadow: var(--shadow-btn);
}
.btn--primary:hover { filter: brightness(1.08); box-shadow: 0 6px 16px rgba(37, 99, 235, .38), 0 14px 36px rgba(124, 58, 237, .3); }
.btn--ghost { background: var(--white); color: var(--ink); border-color: var(--line); box-shadow: var(--shadow-sm); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--light { background: var(--white); color: var(--accent-dark); box-shadow: 0 8px 24px rgba(2, 6, 23, .25); }
.btn--light:hover { filter: brightness(1.03); }
.btn--lg { padding: .9rem 1.7rem; font-size: 1rem; }
.btn--block { width: 100%; }

/* ============ Nav ============ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: box-shadow .25s ease, border-color .25s ease;
}
.nav.is-scrolled { border-color: var(--line); box-shadow: var(--shadow-sm); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }

.brand { display: flex; align-items: center; gap: .65rem; font-weight: 700; color: var(--ink); font-family: var(--font-display); }
.brand__mark {
  display: grid; place-items: center;
  width: 60px; height: 60px;
}
/* logo-mark.png is pre-trimmed to the glyph — show it whole, no cropping */
.brand__mark img { width: 100%; height: 100%; object-fit: contain; }
.brand__text { font-size: 1.05rem; letter-spacing: -.01em; }

.nav__links { display: flex; align-items: center; gap: 1.6rem; }
.nav__link { font-weight: 600; color: var(--body); transition: color .2s ease; }
.nav__link:hover { color: var(--accent); }
.nav__cta { color: #fff; }

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none; border: 0; cursor: pointer;
  padding: 8px;
}
.nav__toggle span {
  width: 24px; height: 2px; background: var(--ink); border-radius: 2px;
  transition: transform .25s ease, opacity .25s ease;
}
.nav__toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle.is-open span:nth-child(2) { opacity: 0; }
.nav__toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ============ Hero ============ */
.hero { position: relative; padding: clamp(3rem, 7vw, 6rem) 0; overflow: hidden; }
.hero__glow {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(900px 420px at 85% -10%, rgba(37, 99, 235, .14), transparent 60%),
    radial-gradient(700px 380px at -10% 40%, rgba(124, 58, 237, .1), transparent 60%);
}
.hero__inner { position: relative; display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.hero__title {
  font-size: clamp(2rem, 4.4vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.02em;
  max-width: 17ch;
  margin-bottom: 1.1rem;
}
.hero__lead { font-size: 1.08rem; max-width: 46ch; margin: 0 0 1.8rem; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-bottom: 1.6rem; }
.hero__meta { display: flex; flex-wrap: wrap; gap: 1.2rem; color: var(--muted); font-size: .9rem; font-weight: 600; }

/* Hero visual composition */
.hero__visual { position: relative; min-height: 400px; }
.orb { position: absolute; border-radius: 50%; filter: blur(10px); opacity: .5; }
.orb--1 { width: 260px; height: 260px; background: radial-gradient(circle at 30% 30%, #93c5fd, #2563eb); top: -4%; right: 2%; }
.orb--2 { width: 190px; height: 190px; background: radial-gradient(circle at 30% 30%, #c4b5fd, #7c3aed); bottom: 2%; left: 0; }

.mock-browser {
  position: absolute; top: 8%; left: 4%;
  width: min(340px, 78%);
  background: rgba(255, 255, 255, .85);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, .9);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.mock-browser__bar {
  display: flex; align-items: center; gap: .4rem;
  padding: .7rem .9rem;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, .7);
}
.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot--r { background: #f87171; }
.dot--y { background: #fbbf24; }
.dot--g { background: #34d399; }
.mock-browser__url { flex: 1; height: 10px; margin-left: .5rem; border-radius: 6px; background: var(--line); }
.mock-browser__body { width: 100%; height: auto; display: block; background: #fff; }

.mock-phone {
  position: absolute; right: 4%; bottom: 4%;
  width: 118px;
  background: rgba(255, 255, 255, .92);
  border: 1px solid rgba(255, 255, 255, .95);
  border-radius: 22px;
  box-shadow: var(--shadow-lg);
  padding: 8px;
  z-index: 2;
}
.mock-phone__notch {
  width: 40%; height: 6px; margin: 2px auto 4px;
  border-radius: 4px; background: var(--line);
}
.mock-phone__body { width: 100%; height: auto; display: block; border-radius: 14px; background: #fff; }

.chip {
  position: absolute; z-index: 3;
  padding: .38rem .8rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, .92);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  font-size: .8rem; font-weight: 700; color: var(--ink);
  font-family: var(--font-display);
}
.chip--1 { top: 2%; left: 0; }
.chip--2 { top: 30%; right: 0; }
.chip--3 { bottom: 26%; left: 2%; }
.chip--4 { bottom: 0; left: 38%; }

/* Floating animations */
@keyframes floatY { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.float-slow { animation: floatY 7s ease-in-out infinite; }
.float-mid  { animation: floatY 5.5s ease-in-out infinite .6s; }
.float-fast { animation: floatY 4.5s ease-in-out infinite .3s; }

/* ============ Sections ============ */
.section { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.about { background: var(--bg-alt); }
.section__head { max-width: 640px; margin: 0 auto 2.6rem; text-align: center; }
.section__title { font-size: clamp(1.7rem, 3.5vw, 2.4rem); letter-spacing: -.02em; margin-bottom: .6rem; }
.section__sub { font-size: 1.05rem; margin: 0; }

/* ============ Stats ============ */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
.stat {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.6rem 1.4rem; text-align: center;
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .25s ease;
}
.stat:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.stat__num {
  font-size: 1.7rem; font-weight: 700; margin-bottom: .3rem;
  color: var(--accent);
}
.stat__label { font-size: .92rem; color: var(--body); }

/* ============ Tabs / Services ============ */
.tabs {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: .6rem; margin-bottom: 2.4rem;
}
.tab {
  border: 1px solid var(--line); background: var(--white);
  color: var(--body); font-weight: 600; font-size: .92rem; font-family: var(--font);
  padding: .6rem 1.1rem; border-radius: 999px; cursor: pointer;
  transition: all .2s ease;
}
.tab:hover { border-color: var(--accent); color: var(--accent); }
.tab.is-active { background: var(--grad); border-color: transparent; color: #fff; box-shadow: var(--shadow-btn); }

.panel { animation: fade .35s ease; }
.panel[hidden] { display: none; }
@keyframes fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.4rem; }
.card {
  position: relative;
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.6rem;
  box-shadow: var(--shadow-sm);
  transition: transform .22s ease, box-shadow .25s ease, border-color .25s ease;
  overflow: hidden;
}
.card::before {
  content: "";
  position: absolute; inset: 0 0 auto 0; height: 3px;
  background: var(--grad);
  opacity: 0; transition: opacity .25s ease;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow); border-color: #d6def0; }
.card:hover::before { opacity: 1; }
.card__icon {
  width: 48px; height: 48px; display: grid; place-items: center;
  border-radius: 12px; background: var(--grad-soft); color: var(--accent);
  margin-bottom: 1rem;
}
.card__icon svg { width: 24px; height: 24px; }
.card__title { font-size: 1.12rem; margin-bottom: .5rem; }
.card__text { margin: 0; font-size: .95rem; }

/* ============ CTA band ============ */
.cta-band {
  position: relative;
  background: linear-gradient(120deg, #1d4ed8, #6d28d9);
  overflow: hidden;
}
.cta-band::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(500px 240px at 15% 0%, rgba(255, 255, 255, .16), transparent 60%),
    radial-gradient(420px 220px at 90% 100%, rgba(255, 255, 255, .1), transparent 60%);
}
.cta-band__inner {
  position: relative;
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 1.4rem;
  padding-top: clamp(2.4rem, 5vw, 3.6rem);
  padding-bottom: clamp(2.4rem, 5vw, 3.6rem);
}
.cta-band__title { color: #fff; font-size: clamp(1.5rem, 3vw, 2.1rem); }
.cta-band__sub { color: rgba(255, 255, 255, .85); margin: .4rem 0 0; }

/* ============ Contact ============ */
.contact { background: radial-gradient(800px 400px at 50% 0%, var(--accent-soft), transparent 65%); }
.contact__inner { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.contact .section__head, .contact .eyebrow { text-align: left; }
.contact__info .section__sub { margin-bottom: 1.6rem; }
.contact__list { list-style: none; padding: 0; margin: 0; display: grid; gap: .9rem; }
.contact__list li { display: flex; align-items: flex-start; gap: .7rem; font-weight: 600; color: var(--ink); line-height: 1.5; }
.contact__list a:hover { color: var(--accent); }
.contact__ico {
  display: grid; place-items: center; width: 38px; height: 38px;
  border-radius: 10px; background: var(--grad-soft); color: var(--accent);
  flex-shrink: 0;
}
.contact__ico svg { width: 18px; height: 18px; }
.contact__list em { font-weight: 500; font-style: italic; color: var(--muted); font-size: .82rem; }

.contact__form {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 1.8rem; box-shadow: var(--shadow-lg);
}
.field { margin-bottom: 1.1rem; }
.field label { display: block; font-weight: 600; color: var(--ink); margin-bottom: .4rem; font-size: .92rem; }
.field input, .field textarea {
  width: 100%; padding: .8rem 1rem; font: inherit; color: var(--ink);
  border: 1px solid var(--line); border-radius: 10px; background: var(--bg-alt);
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.field input:focus, .field textarea:focus {
  outline: none; border-color: var(--accent); background: #fff;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .12);
}
.field textarea { resize: vertical; }
.field.has-error input, .field.has-error textarea { border-color: #ef4444; background: #fef2f2; }
.error { display: block; color: #ef4444; font-size: .82rem; margin-top: .35rem; min-height: 1em; }
.form__success {
  margin: 1rem 0 0; padding: .8rem 1rem; border-radius: 10px;
  background: #ecfdf5; color: #047857; font-weight: 600; text-align: center;
}

/* ============ Footer ============ */
.footer { background: #0b1120; color: #cbd5e1; padding: 3.4rem 0 1.6rem; }
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 2.2rem;
}
.footer__brand-row { display: flex; align-items: center; gap: .8rem; margin-bottom: .8rem; }
.footer__brand-row strong { color: #fff; font-family: var(--font-display); font-size: 1.05rem; }
.footer__brand p { margin: 0 0 1.1rem; font-size: .9rem; color: var(--muted); max-width: 34ch; }
.footer__social { display: flex; gap: .6rem; }
.footer__social a {
  width: 38px; height: 38px; display: grid; place-items: center;
  border-radius: 10px; background: rgba(255, 255, 255, .07);
  transition: background .2s ease, transform .2s ease;
}
.footer__social a:hover { background: var(--accent); color: #fff; transform: translateY(-2px); }
.footer__social svg { width: 17px; height: 17px; }

.footer__col { display: flex; flex-direction: column; gap: .55rem; }
.footer__col h4 {
  margin: 0 0 .4rem; color: #fff; font-size: .95rem;
  letter-spacing: .02em;
}
.footer__col a { font-size: .92rem; color: #b6c2d4; transition: color .2s ease; }
.footer__col a:hover { color: #fff; }
.footer__col address { font-style: normal; font-size: .92rem; color: #b6c2d4; line-height: 1.6; }

.footer__bottom { margin-top: 2.4rem; padding-top: 1.4rem; border-top: 1px solid rgba(255, 255, 255, .09); }
.footer__bottom p { margin: 0; font-size: .85rem; color: var(--muted); }

/* ============ Scroll reveal ============ */
/* Hidden state only applies when JS is running (html.js set by script.js),
   so content is never invisible if the script fails to load. */
html.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }
html.js .reveal.is-visible { opacity: 1; transform: none; }

/* ============ Responsive ============ */
@media (max-width: 900px) {
  .hero__inner { grid-template-columns: 1fr; }
  .hero__visual { order: -1; min-height: 330px; max-width: 460px; margin: 0 auto; width: 100%; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .contact__inner { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .nav__toggle { display: flex; }
  .nav__links {
    position: absolute; top: 72px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: .3rem;
    background: #fff; padding: 1rem var(--space) 1.4rem;
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    transform: translateY(-140%); opacity: 0; pointer-events: none;
    transition: transform .3s ease, opacity .3s ease;
  }
  .nav__links.is-open { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .nav__link { padding: .7rem .2rem; border-bottom: 1px solid var(--line); }
  .nav__cta { margin-top: .5rem; text-align: center; }
  .section__head { text-align: center; }
  .cta-band__inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 460px) {
  .stats { grid-template-columns: 1fr; }
  .brand__text { display: none; }
  .footer__grid { grid-template-columns: 1fr; gap: 1.8rem; }
  .mock-phone { width: 96px; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto; animation: none !important; transition: none !important; }
  html.js .reveal { opacity: 1; transform: none; }
}
