/* ==========================================================================
   DGB Planet
   Theme: dark-locked brand default, light variant via prefers-color-scheme.
   Token strategy: CSS custom properties. One accent (brand cyan). One radius
   scale (cards 14px, pills for interactive). All pairs verified WCAG AA.
   ========================================================================== */

:root {
  color-scheme: dark;

  /* surfaces */
  --surface:    #0D2634;
  --surface-2:  #13384C;
  --surface-3:  #0A1E2A;

  /* text */
  --text:       #FFFFFF;
  --text-muted: #A8BCC7;   /* 7.95 on surface */

  /* brand */
  --accent:       #3EACDE; /* 6.07 on surface, links and small text */
  --accent-solid: #249CD2; /* fills, rules, large graphics */
  --on-accent:    #0D2634; /* 5.03 on accent-solid */

  --border:        rgba(168, 188, 199, .18);
  --border-strong: rgba(168, 188, 199, .34);

  /* buttons */
  --btn-bg:   var(--accent-solid);
  --btn-fg:   var(--on-accent);
  --btn-bg-h: #3EACDE;

  /* type */
  --display: "Outfit", "Segoe UI", system-ui, sans-serif;
  --body:    "Inter Tight", "Segoe UI", system-ui, sans-serif;
  --mono:    "JetBrains Mono", ui-monospace, SFMono-Regular, monospace;

  /* rhythm */
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --radius: 14px;
  --section-y: clamp(5rem, 11vw, 9.5rem);

  /* z scale: 10 sticky nav, 20 mobile drawer, 30 skip link */
  --z-nav: 10;
  --z-drawer: 20;
  --z-skip: 30;
}

@media (prefers-color-scheme: light) {
  :root {
    color-scheme: light;
    --surface:    #FFFFFF;
    --surface-2:  #F4F8FA;
    --surface-3:  #E8F1F6;
    --text:       #0D2634;
    --text-muted: #526B79;   /* 5.62 on white */
    --accent:       #17739E; /* 5.27 on white */
    --accent-solid: #249CD2;
    --on-accent:    #0D2634;
    --border:        rgba(19, 56, 76, .14);
    --border-strong: rgba(19, 56, 76, .26);
    --btn-bg:   #0D2634;
    --btn-fg:   #FFFFFF;
    --btn-bg-h: #13384C;
  }
}

/* --------------------------------------------------------------- reset -- */

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--surface);
  color: var(--text);
  font-family: var(--body);
  font-size: clamp(1rem, .96rem + .18vw, 1.0625rem);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); }

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.08;
  margin: 0;
  text-wrap: balance;
}
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip {
  position: absolute; left: -9999px; top: 0; z-index: var(--z-skip);
  background: var(--btn-bg); color: var(--btn-fg);
  padding: .75rem 1.25rem; border-radius: 0 0 var(--radius) 0;
}
.skip:focus { left: 0; }

/* -------------------------------------------------------------- layout -- */

.wrap {
  width: min(1240px, 100% - (var(--gutter) * 2));
  margin-inline: auto;
}

.section { padding-block: var(--section-y); }
.section--tint { background: var(--surface-2); }

.eyebrow {
  font-family: var(--mono);
  font-size: .6875rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1.25rem;
}

.h-lead {
  font-size: clamp(2rem, 1.3rem + 3.1vw, 3.5rem);
  max-width: 20ch;
}

.lede {
  font-size: clamp(1.0625rem, 1rem + .35vw, 1.25rem);
  color: var(--text-muted);
  max-width: 58ch;
  margin-top: 1.5rem;
}

/* ------------------------------------------------------------- buttons -- */

.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .9rem 1.6rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-family: var(--display);
  font-size: .9375rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease, transform .12s ease;
}
.btn--primary { background: var(--btn-bg); color: var(--btn-fg); }
.btn--primary:hover { background: var(--btn-bg-h); }
.btn--ghost { background: transparent; color: var(--text); border-color: var(--border-strong); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn:active { transform: translateY(1px); }
.btn__arrow { transition: transform .18s ease; }
.btn:hover .btn__arrow { transform: translateX(3px); }

@media (prefers-reduced-motion: reduce) {
  .btn, .btn__arrow { transition: none; }
  .btn:active { transform: none; }
}

/* ----------------------------------------------------------------- nav -- */

.nav {
  position: sticky; top: 0; z-index: var(--z-nav);
  height: 72px;
  display: flex; align-items: center;
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
@supports not (backdrop-filter: blur(1px)) { .nav { background: var(--surface); } }

.nav__inner {
  display: flex; align-items: center; gap: 2rem;
  width: min(1240px, 100% - (var(--gutter) * 2));
  margin-inline: auto;
}
.nav__links { display: flex; align-items: center; gap: 1.75rem; margin-left: auto; }
.nav__links a {
  color: var(--text); text-decoration: none;
  font-size: .9375rem; font-family: var(--display); font-weight: 400;
  white-space: nowrap;
  transition: color .16s ease;
}
.nav__links a:hover { color: var(--accent); }
/* .nav__links a would otherwise out-specify .btn--primary and paint the CTA
   label in body-text colour, which is invisible on the dark pill in light mode. */
.nav__links a.btn--primary { color: var(--btn-fg); }
.nav__links a.btn--primary:hover { color: var(--btn-fg); }
.nav__cta { margin-left: .5rem; }
.nav__toggle { display: none; }

/* ---------------------------------------------------------------- logo -- */

.logo {
  display: inline-flex; align-items: baseline; gap: .28em;
  text-decoration: none; color: var(--text); line-height: 1;
}
.logo__dgb {
  font-family: "Bodoni Moda", Didot, Georgia, serif;
  font-weight: 500;
  font-size: 1.6rem;
  letter-spacing: .02em;
}
.logo__planet {
  font-family: "Pinyon Script", "Snell Roundhand", cursive;
  font-size: 1.5rem;
  color: var(--accent);
  transform: translateY(.06em);
}
.logo--lg .logo__dgb { font-size: 2.4rem; }
.logo--lg .logo__planet { font-size: 2.25rem; }

/* ---------------------------------------------------------------- hero -- */

/* Full-viewport video hero. The page nav is sticky at 72px, so the hero is
   pulled up underneath it and pads the same amount back. The video is always
   dark, so the hero keeps its own fixed palette in both colour schemes. */
.hero {
  --hero-text: #FFFFFF;
  --hero-muted: #D3DEE4;
  --hero-accent: #3EACDE;

  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 100vh;
  min-height: 100svh;
  margin-top: -72px;
  padding-top: 72px;
  display: flex;
  align-items: center;
  background: #0A1E2A url("../img/hero-poster.jpg") 65% 50% / cover no-repeat;
  color: var(--hero-text);
}

.hero__video {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 65% 50%; /* keeps the tower in frame on portrait screens */
}

.hero__scrim {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg,
      rgba(10, 30, 42, .90) 0%,
      rgba(10, 30, 42, .78) 34%,
      rgba(10, 30, 42, .30) 62%,
      rgba(10, 30, 42, .10) 100%),
    linear-gradient(0deg, rgba(10, 30, 42, .65) 0%, rgba(10, 30, 42, 0) 30%),
    linear-gradient(180deg, rgba(10, 30, 42, .55) 0%, rgba(10, 30, 42, 0) 18%);
}

.hero__content { padding-block: clamp(3rem, 8vh, 6rem); }
.hero h1 {
  font-size: clamp(2.5rem, 1.5rem + 4.4vw, 4.75rem);
  font-weight: 500;
  max-width: 14ch;
  color: var(--hero-text);
  text-shadow: 0 2px 24px rgba(10, 30, 42, .35);
}
.hero h1 em { font-style: normal; color: var(--hero-accent); }
.hero__sub {
  margin-top: 1.75rem; max-width: 44ch;
  color: var(--hero-muted);
  font-size: clamp(1.0625rem, 1rem + .4vw, 1.3125rem);
}
.hero__cta { display: flex; flex-wrap: wrap; gap: .875rem; margin-top: 2.5rem; }

/* the hero is dark in both schemes, so its buttons are too */
.hero .btn--primary { background: #249CD2; color: #0D2634; }
.hero .btn--primary:hover { background: #3EACDE; }
.hero .btn--ghost { color: #FFFFFF; border-color: rgba(255, 255, 255, .45); background: rgba(10, 30, 42, .25); }
.hero .btn--ghost:hover { color: #FFFFFF; border-color: #FFFFFF; }


/* portrait phones: text sits over the middle of the frame, so darken evenly */
@media (max-width: 767px) {
  .hero__scrim {
    background:
      linear-gradient(0deg, rgba(10, 30, 42, .92) 0%, rgba(10, 30, 42, .62) 55%, rgba(10, 30, 42, .45) 100%);
  }
  .hero { align-items: flex-end; }
  .hero__content { padding-bottom: 5.5rem; }
}

/* the sticky nav sits over the video; give it a darker, fixed tint there */
.nav { background: color-mix(in srgb, var(--surface) 72%, transparent); }

/* --------------------------------------------------------------- strip -- */

.strip { border-block: 1px solid var(--border); padding-block: 2.25rem; background: var(--surface-3); }
.strip__label {
  font-family: var(--mono); font-size: .6875rem; letter-spacing: .2em;
  text-transform: uppercase; color: var(--text-muted); margin-bottom: 1.5rem;
}
.strip__logos { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(1.75rem, 4vw, 3.5rem); }
.strip__logos img { height: 26px; width: auto; opacity: .62; transition: opacity .2s ease; }
.strip__logos img:hover { opacity: 1; }
.strip__logos span {
  font-family: var(--display); font-weight: 500; font-size: 1.05rem;
  letter-spacing: .01em; color: var(--text-muted);
}

/* -------------------------------------------------------------- method -- */

.method__grid {
  display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr);
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: start;
}
.method__aside { position: sticky; top: 108px; }
.method__list { border-top: 1px solid var(--border); }
.step {
  display: grid; grid-template-columns: 3.5rem minmax(0, 1fr);
  gap: clamp(1rem, 2.5vw, 2rem);
  padding-block: clamp(1.75rem, 3.5vw, 2.75rem);
  border-bottom: 1px solid var(--border);
}
.step__n {
  font-family: var(--mono); font-size: .8125rem; color: var(--accent);
  padding-top: .45rem; letter-spacing: .06em;
}
.step h3 { font-size: clamp(1.375rem, 1.15rem + .9vw, 1.875rem); }
.step p { color: var(--text-muted); margin-top: .75rem; max-width: 56ch; }

@media (max-width: 860px) {
  .method__grid { grid-template-columns: 1fr; }
  .method__aside { position: static; }
  .step { grid-template-columns: 2.5rem minmax(0, 1fr); }
}

/* ------------------------------------------------------------------ ai -- */

.ai__head { max-width: 62ch; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: clamp(.875rem, 1.6vw, 1.25rem); }
.tile {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 2.6vw, 2.25rem);
  display: flex; flex-direction: column; gap: .75rem;
}
.tile h3 { font-size: 1.3125rem; }
.tile p { color: var(--text-muted); font-size: .96875rem; }
.tile__icon { color: var(--accent); font-size: 1.6rem; line-height: 1; margin-bottom: .35rem; }

.tile--wide { grid-column: span 4; }
.tile--half { grid-column: span 2; }

.tile--feature {
  grid-column: span 6;
  background: var(--surface-3);
  border-color: var(--border-strong);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 0; align-items: stretch;
  padding: 0; overflow: hidden;
}
.tile--feature .tile__body {
  padding: clamp(1.75rem, 3vw, 2.75rem);
  display: flex; flex-direction: column; justify-content: center; gap: .75rem;
}
.tile--feature img { height: 100%; width: 100%; object-fit: cover; min-height: 260px; }

@media (max-width: 900px) {
  .bento { grid-template-columns: repeat(2, 1fr); }
  .tile--wide, .tile--half { grid-column: span 2; }
  .tile--feature { grid-column: span 2; grid-template-columns: 1fr; }
  .tile--feature img { order: -1; min-height: 200px; }
}

/* --------------------------------------------------------------- split -- */

.split {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4.5rem); align-items: center;
}
.split + .split { margin-top: clamp(3.5rem, 7vw, 6rem); }
.split--flip .split__media { order: -1; }
.split__media img {
  border-radius: var(--radius); aspect-ratio: 5 / 4;
  object-fit: cover; width: 100%; filter: saturate(.92);
}
.split h3 { font-size: clamp(1.625rem, 1.3rem + 1.3vw, 2.25rem); }
.split p { color: var(--text-muted); margin-top: 1.125rem; max-width: 52ch; }
.split ul { margin-top: 1.5rem; display: grid; gap: .625rem; }
.split li { display: flex; gap: .7rem; align-items: flex-start; color: var(--text-muted); font-size: .96875rem; }
.split li::before {
  content: ""; flex: none; width: 6px; height: 6px;
  margin-top: .62em; border-radius: 50%; background: var(--accent-solid);
}

@media (max-width: 860px) {
  .split { grid-template-columns: 1fr; }
  .split--flip .split__media { order: 0; }
}

/* ---------------------------------------------------------- industries -- */

.industries { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--border); }
.industry {
  padding: clamp(2rem, 3.5vw, 3rem) clamp(1.25rem, 2.4vw, 2rem);
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
}
.industry:last-child { border-right: 0; }
.industry h3 { font-size: 1.25rem; }
.industry p { color: var(--text-muted); font-size: .9375rem; margin-top: .625rem; }

@media (max-width: 880px) {
  .industries { grid-template-columns: repeat(2, 1fr); }
  .industry:nth-child(2n) { border-right: 0; }
}
@media (max-width: 520px) {
  .industries { grid-template-columns: 1fr; }
  .industry { border-right: 0; }
}

/* --------------------------------------------------------------- about -- */

.about__body p + p { margin-top: 1.25rem; }
.about__body p { color: var(--text-muted); max-width: 62ch; }
.about__body p:first-child {
  color: var(--text);
  font-size: clamp(1.375rem, 1.1rem + 1.2vw, 2rem);
  font-family: var(--display); font-weight: 400;
  line-height: 1.25; letter-spacing: -0.02em;
  max-width: 30ch;
}

.team {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
  margin-top: clamp(3rem, 6vw, 4.5rem);
}
.person {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 3vw, 2.5rem);
  display: flex; flex-direction: column; gap: 1.25rem;
}
.person__head { display: flex; align-items: center; gap: 1.125rem; }
.person__mark {
  flex: none;
  display: grid; place-items: center;
  width: 64px; height: 64px;
  border-radius: var(--radius);
  background: var(--surface-3);
  border: 1px solid var(--border-strong);
  color: var(--accent);
  font-family: "Bodoni Moda", Didot, Georgia, serif;
  font-size: 1.5rem; font-weight: 500; letter-spacing: .02em;
}
.person__name { font-size: 1.3125rem; }
.person__role { color: var(--text-muted); font-size: .9375rem; margin-top: .2rem; }
.person__bio { color: var(--text-muted); }
.person__langs { color: var(--text-muted); font-size: .875rem; margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--border); }

@media (max-width: 800px) {
  .team { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------------- contact -- */

.contact { background: var(--surface-3); border-top: 1px solid var(--border); }
.contact__grid {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2.5rem, 6vw, 5rem); align-items: start;
}
.contact__lines { margin-top: 2.5rem; display: grid; gap: 1.5rem; }
.contact__line { display: grid; gap: .2rem; }
.contact__k {
  font-family: var(--mono); font-size: .6875rem; letter-spacing: .18em;
  text-transform: uppercase; color: var(--text-muted);
}
.contact__v { font-family: var(--display); font-size: 1.125rem; color: var(--text); text-decoration: none; }
a.contact__v:hover { color: var(--accent); }

.form { display: grid; gap: 1.125rem; }
.form .btn { justify-self: start; }
.field { display: grid; gap: .5rem; }
.field label { font-size: .875rem; font-weight: 500; color: var(--text); }
.field input, .field textarea, .field select {
  width: 100%;
  font: inherit; font-size: .96875rem;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  padding: .8rem .95rem;
  transition: border-color .16s ease, box-shadow .16s ease;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: var(--text-muted); opacity: 1; }
.field input:focus, .field textarea:focus, .field select:focus {
  border-color: var(--accent); outline: none;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
}
.field__help { font-size: .8125rem; color: var(--text-muted); }
.field__error { font-size: .8125rem; color: var(--danger, #FF9A9A); display: none; }
.field[data-invalid="true"] input,
.field[data-invalid="true"] textarea { border-color: var(--danger, #FF9A9A); }
.field[data-invalid="true"] .field__error { display: block; }
.form__status { font-size: .9375rem; color: var(--text-muted); min-height: 1.5em; }
.form__status[data-state="ok"] { color: var(--accent); }
.form__status[data-state="error"] { color: var(--danger); }
.form .btn[disabled] { opacity: .6; cursor: progress; }
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

:root { --danger: #FF9A9A; }
@media (prefers-color-scheme: light) { :root { --danger: #B3261E; } }

@media (max-width: 860px) { .contact__grid { grid-template-columns: 1fr; } }

/* -------------------------------------------------------------- footer -- */

.footer { border-top: 1px solid var(--border); padding-block: 3rem 2.25rem; }
.footer__top { display: flex; flex-wrap: wrap; gap: 2rem; justify-content: space-between; align-items: flex-start; }
.footer__nav { display: flex; flex-wrap: wrap; gap: 1.5rem; }
.footer__nav a { color: var(--text-muted); text-decoration: none; font-size: .9375rem; }
.footer__nav a:hover { color: var(--accent); }
.footer__legal {
  margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--border);
  color: var(--text-muted); font-size: .8125rem;
  display: flex; flex-wrap: wrap; gap: .5rem 1.5rem;
}

/* ---------------------------------------------------------- mobile nav -- */

@media (max-width: 1000px) {
  .nav__links {
    position: fixed; inset: 72px 0 auto; z-index: var(--z-drawer);
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: .5rem var(--gutter) 1.5rem;
    margin-left: 0;
  }
  /* an author `display` declaration beats the UA [hidden] rule, so restate it */
  .nav__links[hidden] { display: none; }
  .nav__links a { padding: .9rem 0; border-bottom: 1px solid var(--border); font-size: 1.0625rem; }
  .nav__cta { margin: 1rem 0 0; justify-content: center; }
  .nav__toggle {
    display: inline-flex; align-items: center; justify-content: center;
    margin-left: auto;
    width: 44px; height: 44px;
    background: transparent; border: 1px solid var(--border-strong);
    border-radius: 10px; color: var(--text); cursor: pointer;
    font-size: 1.25rem;
  }
}

/* ------------------------------------------------------------- reveal -- */

@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(18px); transition: opacity .55s ease, transform .55s ease; }
  .reveal.is-in { opacity: 1; transform: none; }
}
