:root {
  --bg: #111830;
  --bg-dark: #0a0f1f;
  --card: #151d38;
  --card-dark: #0d1328;
  --border: #26304f;
  --text: #f1f4fb;
  --muted: #9aa6c3;
  --cyan: #12b5d8;
  --blue: #4f7dfc;
  --blue-hover: #6a91ff;
  --chip: #1b2650;
  --radius: 14px;
  --container: 1200px;
  --font: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;

  /* Type scale */
  --fs-xs: 0.75rem;   /* 12px eyebrows, labels */
  --fs-sm: 0.875rem;  /* 14px small text, buttons */
  --fs-base: 1rem;    /* 16px body */
  --fs-md: 1.0625rem; /* 17px lead copy */
  --fs-lg: 1.25rem;   /* 20px card titles */
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: var(--fs-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font); line-height: 1.2; margin: 0; letter-spacing: -0.015em; }
h2 { font-size: clamp(1.75rem, 2.8vw, 2.375rem); font-weight: 700; margin-bottom: 0.875rem; }
h3 { font-size: var(--fs-lg); font-weight: 700; }
h4 { font-size: var(--fs-base); font-weight: 700; }
p { margin: 0 0 1rem; }

.container { width: min(100% - 48px, var(--container)); margin-inline: auto; }
.muted { color: var(--muted); }
.small { font-size: 0.8125rem; }
.c-cyan { color: var(--cyan); }
.c-blue { color: var(--blue); }

.eyebrow {
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 0.75rem;
}
.eyebrow span { color: var(--blue); margin: 0 0.3em; }
.eyebrow-muted { color: #c7cfe4; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.75rem 1.375rem;
  border-radius: 8px;
  font-weight: 600; font-size: var(--fs-sm);
  border: 1px solid transparent;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s, border-color 0.2s, transform 0.2s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--blue); color: #0a1230; }
.btn-primary:hover { background: var(--blue-hover); }
.btn-outline { border-color: #3a4566; color: var(--text); background: transparent; }
.btn-outline:hover { border-color: var(--muted); }
.btn-sm { padding: 0.5rem 0.95rem; font-weight: 600; }
.btn-mini {
  display: inline-block;
  font: 600 var(--fs-xs) var(--font);
  color: var(--text);
  background: transparent;
  border: 1px solid #3a4566;
  border-radius: 6px;
  padding: 0.2rem 0.6rem;
  margin-left: 0.5rem;
  cursor: pointer;
  vertical-align: middle;
}
.btn-mini:hover { border-color: var(--muted); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(17, 24, 48, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.logo {
  display: flex; align-items: center; gap: 0.5rem;
  background: #fff; color: #0b1020;
  padding: 0.45rem 1.1rem;
  border-radius: 6px;
}
.logo img { width: 32px; height: 32px; }
.logo-text { display: flex; flex-direction: column; line-height: 1.1; }
.logo-text strong { font-size: 0.85rem; font-weight: 800; letter-spacing: 0.02em; }
.logo-text small { font-size: 0.45rem; color: #3b55c9; }
.site-nav { display: flex; align-items: center; gap: 1.75rem; }
.site-nav a:not(.btn) { color: #c7cfe4; font-size: var(--fs-sm); font-weight: 500; transition: color 0.2s; }
.site-nav a:not(.btn):hover, .site-nav a.active { color: #fff; }
.nav-toggle { display: none; }

/* Hero */
.hero { position: relative; overflow: hidden; padding: 5.5rem 0 5rem; }
.hero-orb {
  position: absolute; right: -170px; top: -150px;
  width: 500px; height: 500px; border-radius: 50%;
  background: #1c2a5c; opacity: 0.85;
}
.hero-grid { position: relative; display: grid; grid-template-columns: 1.35fr 1fr; gap: 4rem; align-items: center; }
.hero-title {
  font-weight: 800;
  font-size: clamp(2.125rem, 3.8vw, 3.25rem);
  line-height: 1.1;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}
.hero-title span { display: block; }
.lead { font-size: var(--fs-md); color: #b9c3dc; max-width: 46ch; line-height: 1.7; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.support-card { padding: 1.75rem; background: rgba(28, 37, 70, 0.75); backdrop-filter: blur(6px); }
.support-card .muted { font-size: var(--fs-sm); margin: 0; }
.chips { list-style: none; padding: 0; margin: 0 0 1.25rem; display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chips li {
  background: var(--chip);
  border: 1px solid #2c3a6e;
  border-radius: 999px;
  padding: 0.4rem 0.85rem;
  font-size: var(--fs-sm);
  font-weight: 600;
}

/* Sections */
.section { padding: 5.5rem 0; border-top: 1px solid var(--border); }
.section-dark { background: var(--bg-dark); }
.section-dark .card { background: var(--card-dark); }
.section-lead { font-size: var(--fs-md); color: var(--muted); max-width: 56ch; margin-bottom: 2.5rem; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; }
.prose p { font-size: var(--fs-md); color: var(--muted); line-height: 1.75; }
.prose strong { color: #fff; }

.grid { display: grid; gap: 1.25rem; list-style: none; padding: 0; margin: 0; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }

.layer-card { padding: 1.75rem; }
.layer-card h3 { margin-bottom: 0.75rem; }
.layer-card .muted { font-size: 0.9375rem; margin: 0; }
.tagline { font-weight: 700; font-size: var(--fs-lg); line-height: 1.45; margin-top: 2.5rem; max-width: 60ch; }

.step { padding: 1.25rem; }
.step-num {
  display: inline-grid; place-items: center;
  width: 30px; height: 30px; border-radius: 50%;
  background: #1c2a5c; color: var(--blue);
  font-size: var(--fs-sm); font-weight: 700; margin-bottom: 0.6rem;
}
.step h4 { margin-bottom: 0.4rem; }
.step .muted { margin: 0; font-size: var(--fs-sm); }
.callout {
  margin-top: 1.5rem;
  background: #111a36;
  border-radius: 12px;
  padding: 1.1rem 1.4rem;
  font-size: var(--fs-base); font-weight: 500;
}
.callout .c-cyan { font-weight: 700; }
.expertise-title { margin-top: 4rem; }
.expertise { gap: 1rem; }
.expertise li {
  padding: 1.1rem 1.25rem 1.1rem 2.5rem;
  position: relative;
  font-weight: 600; font-size: 0.9375rem;
}
.expertise li::before {
  content: ""; position: absolute; left: 1.25rem; top: 1.6rem;
  width: 7px; height: 7px; border-radius: 50%; background: var(--blue);
}

.talent-card { padding: 1.75rem; }
.talent-card h3 { margin-bottom: 1.1rem; }
.talent-card .muted { font-size: 0.9375rem; margin: 0; }
.skills { margin: 0; }
.skills dt { font-weight: 600; font-size: var(--fs-base); }
.skills dd { margin: 0.15rem 0 1rem; color: var(--muted); font-size: 0.9375rem; }
.skills dd:last-child { margin-bottom: 0; }
.subhead { font-size: 1.5rem; margin: 4rem 0 1.4rem; }
.model-card { padding: 1.75rem 1.5rem; border-top: 3px solid var(--blue); }
.model-card h3 { margin-bottom: 0.3rem; }
.model-card .eyebrow { margin-bottom: 1rem; }
.model-card .muted { font-size: 0.9375rem; margin: 0; }

/* Compare */
.compare { overflow: hidden; }
.compare-row {
  display: grid; grid-template-columns: 1fr 1.4fr 1.6fr;
  gap: 1.5rem; padding: 1.1rem 1.75rem;
  border-top: 1px solid var(--border);
  font-size: 0.9375rem;
}
.compare-row:first-child { border-top: 0; }
.compare-row [role="rowheader"] { font-weight: 600; }
.compare-row [role="cell"]:nth-child(2) { color: var(--muted); }
.compare-head { font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: #c7cfe4; background: #111a36; }

/* Contact */
.contact-grid { align-items: start; }
.contact-list { margin: 0 0 2rem; }
.contact-list dt { font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: #c7cfe4; margin-top: 1.25rem; }
.contact-list dd { margin: 0.3rem 0 0; font-size: var(--fs-base); }
.contact-list dd a:hover { color: var(--cyan); }
.join { border-top: 1px solid var(--border); padding-top: 1.75rem; }
.join h3 { margin-bottom: 0.6rem; }
.join .muted { font-size: 0.9375rem; }
.form-card { padding: 2rem; }
.form-card > .muted { font-size: 0.9375rem; margin-bottom: 1.5rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem 1rem; }
.form-grid label { display: flex; flex-direction: column; gap: 0.4rem; font-weight: 600; font-size: var(--fs-sm); }
.form-grid .full { grid-column: 1 / -1; }
input, select, textarea {
  font: 400 0.9375rem var(--font);
  color: var(--text);
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.65rem 0.85rem;
  width: 100%;
}
select { cursor: pointer; }
textarea { resize: vertical; min-height: 120px; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--blue); outline-offset: 1px; }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; margin-top: 1.4rem; }
.form-error { color: #ff8a8a; margin: 0.8rem 0 0; min-height: 1em; font-size: var(--fs-sm); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-success h3 { margin-bottom: 0.7rem; }
.form-success .muted { font-size: 0.9375rem; }
.form-success .btn { margin-top: 0.5rem; }
.btn:disabled { opacity: 0.6; cursor: wait; transform: none; }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 1.75rem 0; background: var(--bg); font-size: var(--fs-sm); }
.footer-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem; }
.footer-inner p { margin: 0; }
.footer-inner strong { letter-spacing: 0.08em; margin-right: 0.75rem; }
.footer-inner a:hover { color: var(--cyan); }

.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 20px);
  background: var(--blue); color: #0a1230; font-size: var(--fs-sm); font-weight: 600;
  padding: 0.55rem 1.1rem; border-radius: 8px;
  opacity: 0; pointer-events: none; transition: 0.25s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Reveal animation */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* Responsive */
@media (max-width: 1100px) {
  .grid-5 { grid-template-columns: repeat(3, 1fr); }
  .site-nav { gap: 1.25rem; }
}
@media (max-width: 900px) {
  .nav-toggle {
    display: flex; flex-direction: column; gap: 5px;
    background: none; border: 0; cursor: pointer; padding: 8px;
  }
  .nav-toggle span { width: 22px; height: 2px; background: #fff; border-radius: 2px; }
  .site-nav {
    position: absolute; top: 72px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border);
    padding: 0.5rem 24px 1.2rem;
    display: none;
  }
  .site-nav.open { display: flex; }
  .site-nav a:not(.btn) { padding: 0.75rem 0; border-bottom: 1px solid var(--border); font-size: var(--fs-base); }
  .site-nav .btn { margin-top: 1rem; }
  .hero-grid, .two-col, .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .hero-grid, .two-col { gap: 2.5rem; }
  .grid-5 { grid-template-columns: repeat(2, 1fr); }
  .compare-row { grid-template-columns: 1fr; gap: 0.3rem; padding: 1rem 1.25rem; }
  .compare-head { display: none; }
  .compare-row [role="cell"]:nth-child(2)::before { content: "Typical agency: "; font-weight: 600; }
  .compare-row [role="cell"]:nth-child(3)::before { content: "TalTech: "; font-weight: 600; color: var(--cyan); }
}
@media (max-width: 560px) {
  .header-inner { height: 64px; }
  .site-nav { top: 64px; }
  .logo { padding: 0.4rem 0.8rem; }
  .hero { padding: 3.5rem 0; }
  .section { padding: 4rem 0; }
  .grid-5, .form-grid { grid-template-columns: 1fr; }
  .hero-actions .btn { width: 100%; }
}
