:root {
  --color-red: #e53935;
  --color-yellow: #ffd54f;
  --color-blue: #1e3a5f;
  --color-white: #ffffff;
  --color-background: #f8f9fb;
  --color-text: #202124;
  --color-muted: #6b7280;
  --color-success: #22c55e;
  --color-error: #ef4444;
  --shadow-soft: 0 12px 40px rgba(30, 58, 95, 0.12);
  --shadow-lift: 0 24px 60px rgba(30, 58, 95, 0.18);
  --radius-xs: 8px;
  --radius-s: 16px;
  --radius-m: 24px;
  --radius-l: 32px;
  --radius-xl: 48px;
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-5: 40px;
  --space-6: 48px;
  --space-7: 64px;
  --space-8: 80px;
  --space-9: 96px;
  --space-10: 128px;
  --space-11: 160px;
  --container: 1280px;
  --transition: 250ms ease-out;
  --header-offset: 96px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Nunito", sans-serif;
  color: var(--color-text);
  background: var(--color-background);
  min-height: 100vh;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

img {
  max-width: 100%;
}

.skip-link {
  position: fixed;
  top: -80px;
  left: 16px;
  z-index: 300;
  padding: 12px 20px;
  border-radius: 999px;
  background: var(--color-blue);
  color: var(--color-white);
  font-family: "Poppins", sans-serif;
  font-weight: 600;
  transition: top var(--transition);
}

.skip-link:focus {
  top: 16px;
}

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

.grain-overlay {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.45;
  background-image: radial-gradient(rgba(30, 58, 95, 0.07) 1px, transparent 1px);
  background-size: 26px 26px;
}

.page-shell {
  position: relative;
  isolation: isolate;
}

.container {
  width: min(calc(100% - 160px), var(--container));
  margin: 0 auto;
}

.section {
  padding: var(--space-10) 0;
  position: relative;
  scroll-margin-top: var(--header-offset);
}

.section--alt {
  background: #fff4e2;
}

.section--contact {
  padding-bottom: var(--space-11);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 var(--space-2);
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--color-white);
  border: 2px solid rgba(30, 58, 95, 0.12);
  font-family: "Poppins", sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-blue);
}

.eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--color-red), var(--color-yellow));
}

.section--contact .eyebrow {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--color-white);
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Fredoka", sans-serif;
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.03em;
}

h1 {
  font-size: clamp(3rem, 6.4vw, 5.4rem);
}

h2 {
  font-size: clamp(2.2rem, 4vw, 3.6rem);
}

h3 {
  font-size: clamp(1.3rem, 2vw, 1.6rem);
  font-weight: 600;
}

.section--contact h2 {
  color: var(--color-white);
}

.section--contact p {
  color: rgba(255, 255, 255, 0.78);
}

p {
  margin: 0;
  line-height: 1.65;
  color: var(--color-text);
}

.section-heading {
  position: relative;
  max-width: 760px;
  margin-bottom: var(--space-7);
}

.section-heading h2 {
  max-width: 16ch;
}


/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(248, 249, 251, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 3px solid;
  border-image: linear-gradient(90deg, var(--color-red), var(--color-yellow), var(--color-blue)) 1;
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: 16px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
}

.brand__logo {
  display: block;
  width: clamp(170px, 16vw, 220px);
  height: 38px;
  object-fit: cover;
  object-position: top;
}

.main-nav {
  display: inline-flex;
  align-items: center;
  gap: var(--space-4);
  font-family: "Poppins", sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.main-nav a {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  padding: 8px 2px;
  color: var(--color-blue);
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--color-red), var(--color-yellow));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition);
}

.main-nav a:hover::after,
.main-nav a:focus-visible::after {
  transform: scaleX(1);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 12px;
  background: rgba(30, 58, 95, 0.08);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: var(--color-blue);
  transition: transform var(--transition), opacity var(--transition);
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 0 0 var(--space-3);
}

.mobile-nav.is-open {
  display: flex;
}

.mobile-nav a {
  padding: 14px 20px;
  border-radius: 14px;
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--color-blue);
  transition: background-color var(--transition);
}

.mobile-nav a:hover,
.mobile-nav a:focus-visible {
  background: rgba(255, 213, 79, 0.22);
}

@media (max-width: 1100px) {
  .nav-toggle {
    display: inline-flex;
  }
}

/* Buttons */

.button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 0 28px;
  overflow: hidden;
  border: none;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--color-red), #ff8365);
  color: var(--color-white);
  box-shadow: 0 12px 24px rgba(229, 57, 53, 0.22);
  font-family: "Poppins", sans-serif;
  font-weight: 600;
  transition:
    transform var(--transition),
    box-shadow var(--transition),
    filter var(--transition);
  cursor: pointer;
}

.button::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, 0.4) 45%, transparent 60%);
  transform: translateX(-130%);
  transition: transform 600ms ease-out;
}

.button:hover,
.button:focus-visible {
  transform: scale(1.05);
  box-shadow: 0 18px 32px rgba(229, 57, 53, 0.28);
  filter: saturate(1.05);
  outline: none;
}

.button:hover::before,
.button:focus-visible::before {
  transform: translateX(130%);
}

.button--small {
  min-height: 46px;
  padding: 0 22px;
}

.button--ghost {
  background: var(--color-white);
  color: var(--color-blue);
  border: 2px solid rgba(30, 58, 95, 0.14);
  box-shadow: var(--shadow-soft);
}

/* Hero */

.hero {
  position: relative;
  padding-top: var(--space-4);
  padding-bottom: var(--space-9);
  scroll-margin-top: var(--header-offset);
  /* .hero-spotlight intentionally bleeds past the right edge for the glow
     effect — clip it here (not on html/body) so it can't cause page-level
     horizontal scroll without breaking the header's position: sticky
     (which happens if html AND body both have non-visible overflow). */
  overflow-x: hidden;
}

.hero-spotlight {
  position: absolute;
  top: -140px;
  right: -10%;
  width: 620px;
  height: 620px;
  max-width: 70vw;
  max-height: 70vw;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(255, 213, 79, 0.55), rgba(255, 213, 79, 0) 70%);
  z-index: -1;
  transform: translate3d(var(--parallax-x, 0px), var(--parallax-y, 0px), 0);
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: var(--space-6);
  align-items: center;
}

.hero-head {
  max-width: 30ch;
}

.hero-pop {
  color: var(--color-red);
  text-shadow: 6px 6px 0 var(--color-yellow);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

.hero-scene {
  position: relative;
  min-height: 560px;
  display: grid;
  place-items: center;
}

.hero-scene__figure {
  position: relative;
  transform: translate3d(var(--parallax-x, 0px), var(--parallax-y, 0px), 0);
}

.hero-mascot {
  display: block;
  max-width: min(340px, 78%);
  height: auto;
  margin: 0 auto;
  filter: drop-shadow(0 30px 50px rgba(30, 58, 95, 0.3));
  animation: mascot-breathe 3.2s ease-out infinite;
}

.hero-score {
  position: absolute;
  top: 2%;
  right: -38%;
  z-index: 2;
  padding: 14px 22px;
  border-radius: 24px;
  background: var(--color-white);
  border: 2px solid var(--color-blue);
  box-shadow: var(--shadow-soft);
  display: grid;
  gap: 0;
  text-align: center;
  transform: translate3d(var(--parallax-x, 0px), var(--parallax-y, 0px), 0);
}

.hero-score::before,
.hero-score::after {
  content: "";
  position: absolute;
  width: 0;
  height: 0;
  border-style: solid;
}

.hero-score::before {
  bottom: -17px;
  left: 30px;
  border-width: 17px 11px 0 11px;
  border-color: var(--color-blue) transparent transparent transparent;
}

.hero-score::after {
  bottom: -13px;
  left: 32px;
  border-width: 13px 9px 0 9px;
  border-color: var(--color-white) transparent transparent transparent;
}

.hero-score strong {
  font-family: "Fredoka", sans-serif;
  font-size: 1.9rem;
  color: var(--color-red);
  font-variant-numeric: tabular-nums;
}

.hero-score__unit {
  display: block;
  font-family: "Poppins", sans-serif;
  font-size: 0.7rem;
  color: var(--color-muted);
}

.hero-chips {
  position: absolute;
  inset: 0;
  list-style: none;
  margin: 0;
  padding: 0;
  pointer-events: none;
}

.hero-chips li {
  position: absolute;
  padding: 10px 14px;
  border-radius: 999px;
  background: var(--color-white);
  border: 2px solid var(--color-blue);
  font-family: "Poppins", sans-serif;
  font-weight: 600;
  font-size: 0.76rem;
  color: var(--color-blue);
  box-shadow: var(--shadow-soft);
  transform: rotate(var(--rot, 0deg));
  white-space: nowrap;
  animation: chip-float 4.5s ease-in-out infinite;
}

.hero-chips li:nth-child(1) {
  top: 12%;
  left: 4%;
  animation-delay: 0s;
}

.hero-chips li:nth-child(2) {
  top: 4%;
  right: 10%;
  animation-delay: 0.5s;
}

.hero-chips li:nth-child(3) {
  top: 40%;
  left: -2%;
  animation-delay: 1s;
}

.hero-chips li:nth-child(4) {
  top: 44%;
  right: 0%;
  animation-delay: 1.5s;
}

.hero-chips li:nth-child(5) {
  bottom: 16%;
  left: 8%;
  animation-delay: 2s;
}

.hero-chips li:nth-child(6) {
  bottom: 10%;
  right: 6%;
  animation-delay: 2.5s;
}

/* Services */

.services-intro {
  display: grid;
  grid-template-columns: max-content minmax(0, 560px);
  align-items: start;
  gap: 14px;
  margin-bottom: -24px;
  position: relative;
  z-index: 2;
}

.services-intro .services-mascot {
  grid-column: 1;
  grid-row: 1;
}

.services-intro .section-heading {
  grid-column: 2;
  grid-row: 1;
}

.services-intro .section-heading {
  margin-bottom: 0;
}

.services-mascot {
  display: flex;
  justify-content: flex-start;
  align-items: end;
  position: relative;
  z-index: 3;
}

.services-mascot__image {
  display: block;
  width: auto;
  max-width: 380px;
  max-height: 460px;
  height: auto;
  filter: drop-shadow(0 30px 50px rgba(30, 58, 95, 0.14));
}

.services-list {
  border-top: 2px solid rgba(30, 58, 95, 0.12);
}

.service-row {
  padding: var(--space-4) var(--space-2);
  border-bottom: 2px solid rgba(30, 58, 95, 0.12);
  transition: background-color var(--transition), padding-left var(--transition);
}

.service-row:hover {
  background: rgba(255, 213, 79, 0.16);
  padding-left: var(--space-3);
}

.service-row__summary {
  display: grid;
  grid-template-columns: 14px 1fr auto;
  align-items: center;
  gap: var(--space-3);
  cursor: pointer;
  list-style: none;
}

.service-row__summary::marker,
.service-row__summary::-webkit-details-marker {
  display: none;
}

.service-row__dot {
  display: block;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: var(--color-red);
}

.service-row:nth-child(even) .service-row__dot {
  background: var(--color-blue);
}

.service-row__chevron {
  display: none;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: rgba(30, 58, 95, 0.08);
  position: relative;
}

.service-row__chevron::before,
.service-row__chevron::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  background: var(--color-blue);
  border-radius: 2px;
  transform: translate(-50%, -50%);
}

.service-row__chevron::before {
  width: 10px;
  height: 2px;
}

.service-row__chevron::after {
  width: 2px;
  height: 10px;
  transition: transform var(--transition);
}

.service-row[open] .service-row__chevron::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.service-row__desc {
  margin: 10px 0 0;
  max-width: 60ch;
  padding-left: calc(14px + var(--space-3));
  color: var(--color-muted);
}

/* Below 768px, .service-row (a <details>) becomes a real accordion — see
   the chevron toggle in the max-width:767px block, and the matching JS in
   script.js that keeps every row open at 768px+ (CSS alone can't reliably
   override a browser's native "hidden unless [open]" rendering for
   <details> content — it needs the actual open attribute/property set). */

@media (min-width: 1101px) {
  .services-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: var(--space-6);
    border-top: none;
  }

  .service-row {
    border-top: 2px solid rgba(30, 58, 95, 0.12);
  }

  .services-list .service-row:nth-child(6),
  .services-list .service-row:nth-child(7) {
    border-bottom: 2px solid rgba(30, 58, 95, 0.12);
  }
}

/* Réalisations */

.projects-shelf {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-4);
  align-items: start;
  padding-top: var(--space-3);
}

.project-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  background: var(--color-white);
  box-shadow: var(--shadow-soft);
  transform: rotate(var(--tilt, 0deg));
  transition: transform var(--transition), box-shadow var(--transition);
}

.project-card:hover {
  transform: rotate(0deg) translateY(-10px);
  box-shadow: var(--shadow-lift);
  z-index: 2;
}

.project-card__ribbon {
  position: absolute;
  top: 20px;
  right: -38px;
  z-index: 3;
  width: 160px;
  padding: 6px 0;
  background: var(--color-red);
  color: var(--color-white);
  text-align: center;
  transform: rotate(45deg);
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.66rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.18);
}

.project-card__media {
  position: relative;
  display: grid;
  place-items: end start;
  min-height: 240px;
  padding: var(--space-4);
  color: var(--color-white);
}

.project-card__title {
  position: relative;
  z-index: 1;
  font-family: "Fredoka", sans-serif;
  font-weight: 700;
  font-size: 1.3rem;
}

.project-card__media--photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.project-card__media--photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(15, 42, 70, 0.78));
}

.project-card__body {
  padding: var(--space-4);
}

.project-card__body h3 {
  margin-bottom: 10px;
}

.project-card__cta {
  width: 100%;
  margin-top: var(--space-3);
  gap: 8px;
}

.project-card__cta span {
  transition: transform var(--transition);
}

.project-card__cta:hover span,
.project-card__cta:focus-visible span {
  transform: translateX(4px);
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: var(--space-3) 0 0;
  padding: 0;
  list-style: none;
}

.project-meta li {
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--color-background);
  border: 1px solid rgba(30, 58, 95, 0.12);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--color-blue);
}

.text-link {
  display: inline-flex;
  margin-top: var(--space-3);
  border: none;
  background: none;
  padding: 0;
  color: var(--color-red);
  font-family: "Poppins", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

/* Clients */

.clients-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--space-7);
  align-items: center;
}

.clients-layout .section-heading {
  margin-bottom: 0;
}

.logo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-6) var(--space-5);
}

.logo-tile {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-2);
}

.logo-tile img {
  max-width: 100%;
  height: auto;
  max-height: 130px;
  object-fit: contain;
  filter: grayscale(1) opacity(0.68);
  transition: filter var(--transition), transform var(--transition);
}

.logo-tile:hover img {
  filter: grayscale(0) opacity(1);
  transform: scale(1.08);
}

/* À propos */

.story {
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: var(--space-7);
  align-items: start;
  margin-top: var(--space-6);
}

.story__kicker {
  margin: 0 0 var(--space-3);
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-red);
}

.story__copy p {
  max-width: 62ch;
  margin-bottom: var(--space-3);
}

.story__copy p:last-child {
  margin-bottom: 0;
}

.story__quote {
  margin: var(--space-4) 0;
  padding: var(--space-3) var(--space-4);
  border: none;
  border-left: 4px solid var(--color-red);
  border-radius: 0 var(--radius-m) var(--radius-m) 0;
  background: rgba(255, 213, 79, 0.18);
  font-family: "Fredoka", sans-serif;
  font-weight: 700;
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  line-height: 1.35;
  color: var(--color-blue);
}

.story__tagline {
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--color-muted);
}

.story__media {
  position: sticky;
  top: 120px;
}

.story__portrait {
  display: grid;
  place-items: center;
}

.story__portrait img {
  max-width: 320px;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 24px 36px rgba(30, 58, 95, 0.22));
}

.story__credit {
  margin-top: var(--space-3);
  text-align: center;
  font-family: "Poppins", sans-serif;
  font-size: 0.8rem;
  color: var(--color-muted);
}

.story__closing {
  max-width: 24ch;
  margin: var(--space-8) auto;
  font-family: "Fredoka", sans-serif;
  font-weight: 700;
  font-size: clamp(1.7rem, 3.2vw, 2.6rem);
  line-height: 1.22;
  color: var(--color-blue);
  text-align: center;
}

.story__closing span {
  color: var(--color-red);
}

/* Contact */

.contact-shell {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-7);
  align-items: center;
  padding: var(--space-6);
  border-radius: 40px;
  background: linear-gradient(160deg, #0f2a46, #1e3a5f);
  box-shadow: var(--shadow-lift);
}

.contact-form {
  display: grid;
  gap: var(--space-3);
}

.contact-form label {
  display: grid;
  gap: 10px;
  font-weight: 700;
  color: var(--color-white);
}

.contact-form__optional {
  font-weight: 400;
  color: rgba(255, 255, 255, 0.5);
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 18px 20px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-white);
  transition: border-color var(--transition), transform var(--transition);
}

.contact-form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 20px center;
  background-size: 18px;
}

.contact-form select option {
  color: var(--color-text);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: rgba(255, 255, 255, 0.48);
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  border-color: var(--color-yellow);
  transform: translateY(-2px);
  outline: none;
}

.contact-form__note {
  min-height: 1.4em;
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  color: var(--color-yellow);
}

/* Footer */

.site-footer {
  padding: var(--space-6) 0;
}

.footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  border-radius: 36px;
  background: var(--color-blue);
  color: var(--color-white);
  box-shadow: var(--shadow-lift);
}

.footer-logo {
  height: 26px;
  width: auto;
  margin-bottom: 8px;
}

.footer-row p {
  color: rgba(255, 255, 255, 0.72);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  font-family: "Poppins", sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
}

.footer-nav a {
  opacity: 0.78;
  transition: opacity var(--transition);
}

.footer-nav a:hover,
.footer-nav a:focus-visible {
  opacity: 1;
}

.footer-wave {
  display: inline-flex;
  align-items: flex-end;
  margin-right: -16px;
}

.mascot-image--footer {
  display: block;
  position: relative;
  z-index: 2;
  height: 190px;
  width: auto;
  margin-top: -130px;
  filter: drop-shadow(0 20px 24px rgba(0, 0, 0, 0.35));
}

/* Request modal */

.request-modal {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: grid;
  place-items: center;
  padding: var(--space-4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 250ms ease-out;
}

.request-modal.is-open {
  opacity: 1;
  pointer-events: auto;
}

.request-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(7, 15, 28, 0.72);
  backdrop-filter: blur(6px);
}

.request-modal__panel {
  position: relative;
  width: min(100%, 560px);
  max-height: 90vh;
  overflow-y: auto;
  padding: var(--space-6);
  border-radius: var(--radius-xl);
  background: linear-gradient(160deg, #0f2a46, #1e3a5f);
  color: var(--color-white);
  box-shadow: var(--shadow-lift);
  transform: scale(0.96);
  transition: transform 250ms ease-out;
}

.request-modal.is-open .request-modal__panel {
  transform: scale(1);
}

.request-modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 999px;
  background: var(--color-white);
  color: var(--color-blue);
  font-size: 1rem;
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition);
}

.request-modal__close:hover,
.request-modal__close:focus-visible {
  transform: scale(1.08);
  outline: none;
}

.request-modal__kicker {
  margin: 0 0 6px;
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-yellow);
}

.request-modal h3 {
  margin: 0 0 var(--space-4);
  max-width: 90%;
  color: var(--color-white);
}

.request-step {
  display: grid;
  gap: var(--space-3);
}

.request-step[hidden] {
  display: none;
}

.contact-form[hidden] {
  display: none;
}

.form-success {
  display: grid;
  justify-items: center;
  gap: var(--space-3);
  padding: var(--space-4) 0;
  text-align: center;
}

.form-success[hidden] {
  display: none;
}

.form-success__mascot {
  width: clamp(220px, 32vw, 320px);
  height: auto;
  filter: drop-shadow(0 20px 32px rgba(0, 0, 0, 0.35));
}

.form-success__text {
  max-width: 380px;
  margin: 0;
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  line-height: 1.4;
  color: var(--color-yellow);
}

.request-step__bubble {
  align-self: flex-start;
  max-width: 92%;
  margin: 0;
  padding: 12px 18px;
  border-radius: 18px;
  border-bottom-left-radius: 4px;
  background: rgba(255, 255, 255, 0.1);
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--color-white);
}

.request-step__actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.request-step__actions [data-step-next],
.request-step__actions button[type="submit"] {
  margin-left: auto;
}

.request-step__actions .text-link {
  color: rgba(255, 255, 255, 0.7);
  font-weight: 700;
  font-size: 0.85rem;
}

.request-step__actions .text-link:hover,
.request-step__actions .text-link:focus-visible {
  color: var(--color-yellow);
}

.pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill-choice {
  padding: 10px 16px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-white);
  font-family: "Poppins", sans-serif;
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition), transform var(--transition);
}

.pill-choice:hover,
.pill-choice:focus-visible {
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-2px);
  outline: none;
}

.pill-choice.is-selected {
  background: var(--color-yellow);
  border-color: var(--color-yellow);
  color: var(--color-blue);
}

/* Game demo modal */

.game-modal {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: grid;
  place-items: center;
  padding: var(--space-4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 250ms ease-out;
}

.game-modal.is-open {
  opacity: 1;
  pointer-events: auto;
}

.game-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(7, 15, 28, 0.82);
  backdrop-filter: blur(6px);
}

.game-modal__panel {
  position: relative;
  width: min(100%, 960px);
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-l);
  overflow: hidden;
  background: #02020a;
  box-shadow: var(--shadow-lift);
  transform: scale(0.96);
  transition: transform 250ms ease-out;
}

.game-modal.is-open .game-modal__panel {
  transform: scale(1);
}

.game-modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 999px;
  background: var(--color-white);
  color: var(--color-blue);
  font-size: 1rem;
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition);
}

.game-modal__close:hover,
.game-modal__close:focus-visible {
  transform: scale(1.08);
  outline: none;
}

.game-modal__frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  flex-shrink: 0;
}

.game-modal__frame iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.game-modal__hint {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 20px;
  z-index: 3;
  display: grid;
  place-items: center;
  pointer-events: none;
  opacity: 1;
  transition: opacity 250ms ease-out;
}

.game-modal__hint.is-hidden {
  opacity: 0;
}

.game-modal__hint span {
  padding: 10px 20px;
  border-radius: 999px;
  background: rgba(12, 29, 50, 0.85);
  color: var(--color-white);
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  box-shadow: var(--shadow-soft);
}

.game-modal__notice {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px 20px;
  padding: 14px 20px;
  background: #12141c;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.game-modal__notice[hidden] {
  display: none;
}

.game-modal__notice-badge {
  margin: 0;
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  color: var(--color-yellow);
  white-space: nowrap;
}

.game-modal__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-family: "Poppins", sans-serif;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.85);
}

.game-modal__controls li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.game-modal__controls kbd {
  display: inline-grid;
  place-items: center;
  min-width: 24px;
  height: 24px;
  padding: 0 6px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  font-family: "Poppins", sans-serif;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--color-white);
}

.project-card__play {
  position: absolute;
  right: var(--space-3);
  bottom: var(--space-3);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  border: none;
  border-radius: 999px;
  background: var(--color-white);
  color: var(--color-blue);
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.82rem;
  cursor: pointer;
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition), box-shadow var(--transition);
}

.project-card__play:hover,
.project-card__play:focus-visible {
  transform: translateY(-3px) scale(1.04);
  box-shadow: var(--shadow-lift);
  outline: none;
}

/* Background scene */

.background-scene {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
}

.scene-pixel,
.scene-star,
.scene-confetti {
  position: absolute;
}

.scene-pixel {
  width: 18px;
  height: 18px;
  border-radius: 5px;
  background: rgba(30, 58, 95, 0.12);
  animation: float 7s ease-out infinite;
}

.scene-pixel--one {
  top: 22%;
  left: 18%;
}

.scene-pixel--two {
  top: 70%;
  right: 22%;
  animation-delay: 1.2s;
}

.scene-pixel--three {
  top: 38%;
  right: 12%;
  animation-delay: 2s;
}

.scene-star {
  width: 14px;
  height: 14px;
  background: rgba(30, 58, 95, 0.18);
  clip-path: polygon(50% 0%, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0% 50%, 39% 39%);
  opacity: 0.8;
  animation: twinkle 3.6s ease-out infinite;
}

.scene-star--one {
  top: 12%;
  left: 10%;
}

.scene-star--two {
  top: 58%;
  left: 48%;
  animation-delay: 1.4s;
}

.scene-star--three {
  bottom: 14%;
  right: 8%;
  animation-delay: 2.4s;
}

.scene-confetti {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  opacity: 0.6;
  animation: confetti-spin 9s ease-in-out infinite;
}

.scene-confetti--one {
  top: 30%;
  left: 40%;
  background: var(--color-red);
}

.scene-confetti--two {
  top: 64%;
  left: 14%;
  background: var(--color-yellow);
  animation-delay: 2.4s;
}

.scene-confetti--three {
  top: 18%;
  right: 30%;
  background: var(--color-blue);
  animation-delay: 4.8s;
}

/* Intro */

.intro-screen {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at top, rgba(255, 213, 79, 0.2), transparent 18%),
    linear-gradient(180deg, #0c1d32 0%, #142b46 100%);
  color: var(--color-white);
  transition: opacity 600ms ease-out, visibility 600ms ease-out;
}

.intro-screen.is-hidden {
  opacity: 0;
  visibility: hidden;
}

.intro-panel {
  width: min(calc(100% - 48px), 560px);
  padding: var(--space-6);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 40px;
  background: rgba(7, 15, 28, 0.72);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.32);
}

.intro-panel h1 {
  margin-top: 10px;
  font-size: clamp(3rem, 8vw, 4.8rem);
}

.intro-kicker,
.intro-line,
.intro-log p {
  color: rgba(255, 255, 255, 0.82);
  font-family: "Poppins", sans-serif;
}

.intro-progress {
  width: 100%;
  height: 18px;
  margin: var(--space-4) 0;
  padding: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
}

.intro-progress span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--color-yellow), var(--color-red));
  animation: load-bar 2.3s ease-out forwards;
}

.intro-log {
  display: grid;
  gap: 8px;
  margin-top: var(--space-3);
  font-family: "Poppins", sans-serif;
}

.intro-mascot {
  display: flex;
  justify-content: flex-end;
  margin-top: var(--space-4);
}

.intro-mascot__image {
  width: auto;
  height: 88px;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.28));
}

/* Reveal */

.reveal {
  opacity: 0;
  transform: translateY(32px) scale(0.98);
  transition:
    opacity 700ms ease-out,
    transform 700ms ease-out;
  transition-delay: var(--reveal-delay, 0ms);
}

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

/* Keyframes */

@keyframes mascot-breathe {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-6px) scale(1.01);
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-18px);
  }
}

@keyframes chip-float {
  0%,
  100% {
    transform: translateY(0) rotate(var(--rot, 0deg));
  }
  50% {
    transform: translateY(-10px) rotate(var(--rot, 0deg));
  }
}

@keyframes twinkle {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.8;
  }
  50% {
    transform: scale(1.35);
    opacity: 1;
  }
}

@keyframes confetti-spin {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-26px) rotate(180deg);
  }
}

@keyframes load-bar {
  from {
    width: 0;
  }
  to {
    width: 100%;
  }
}

/* Responsive */

@media (max-width: 1100px) {
  .main-nav {
    display: none;
  }

  .hero-layout {
    grid-template-columns: 1fr;
  }

  .hero-head {
    max-width: none;
  }

  .hero-scene {
    min-height: 500px;
  }

  .contact-shell,
  .story,
  .clients-layout,
  .services-intro {
    grid-template-columns: 1fr;
  }

  .story__media {
    position: static;
  }

  /* Stacked single-column: put the heading first so the services mascot
     doesn't land right under the hero mascot — back-to-back mascots read
     as redundant with nothing else between them. */
  .services-intro .section-heading {
    grid-column: 1;
    grid-row: 1;
  }

  .services-intro .services-mascot {
    grid-column: 1;
    grid-row: 2;
    justify-content: center;
  }

  .services-mascot__image {
    max-width: 260px;
    max-height: 300px;
  }

  .services-list {
    grid-template-columns: 1fr;
  }

  .projects-shelf {
    grid-template-columns: 1fr;
  }

  .project-card {
    transform: none;
  }
}

@media (max-width: 767px) {
  :root {
    --header-offset: 160px;
  }

  .container {
    width: min(calc(100% - 40px), var(--container));
  }

  /* Desktop's spacing scale carries a lot of open-air whitespace that reads
     fine at 1440px but turns a single-column mobile layout into an
     endless scroll — tighten the rhythm across the board. */
  .section {
    padding: var(--space-6) 0;
  }

  .section-heading {
    margin-bottom: var(--space-4);
  }

  /* Decorative floating shapes are fixed to the viewport and positioned by
     percentage, tuned for desktop's spare whitespace — on a narrow, denser
     mobile layout they land on top of text instead. */
  .background-scene {
    display: none;
  }

  .header-row {
    justify-content: space-between;
    padding: 12px 0;
  }

  .brand {
    width: auto;
  }

  .brand__logo {
    width: min(58vw, 240px);
    height: auto;
    object-fit: contain;
  }

  .header-row > .button {
    display: none;
  }

  .hero {
    padding-top: var(--space-6);
    padding-bottom: var(--space-6);
  }

  .hero-actions {
    display: none;
  }

  .button,
  .button--ghost {
    width: 100%;
  }

  .hero-scene {
    min-height: auto;
    padding: var(--space-6) 0;
  }

  .hero-scene__figure {
    margin-left: -20%;
  }

  .hero-score {
    top: 2%;
    right: -30%;
    padding: 10px 16px;
  }

  .hero-score strong {
    font-size: 1.5rem;
  }

  /* The pills scattered around the mascot on desktop are tuned for a lot of
     open space — on mobile they'd just clutter a tighter composition. */
  .hero-chips {
    display: none;
  }

  .services-intro {
    gap: var(--space-3);
    margin-bottom: var(--space-5);
  }

  .services-mascot__image {
    max-width: 220px;
    max-height: 260px;
  }

  .logo-grid {
    row-gap: var(--space-2);
  }

  .logo-tile {
    padding: 8px;
  }

  .logo-tile img {
    max-height: 76px;
  }

  .service-row {
    padding: var(--space-3) var(--space-1);
  }

  .service-row__summary {
    gap: var(--space-2);
  }

  .service-row__chevron {
    display: block;
  }

  .service-row__desc {
    font-size: 0.92rem;
    line-height: 1.5;
  }

  .story {
    margin-top: var(--space-4);
  }

  .story__copy p {
    margin-bottom: var(--space-2);
  }

  .story__closing {
    margin: var(--space-5) auto;
  }

  /* Full-bleed: break out of .container's side margins so the box reaches
     the viewport edges, restoring some of that margin as inner padding. */
  .contact-shell {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    padding: var(--space-4) 20px;
    border-radius: 0;
  }

  .site-footer {
    padding-top: 0;
    padding-bottom: 0;
  }

  .footer-row {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    border-radius: 0;
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-nav {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-wave {
    display: none;
  }

  /* Glue the full-bleed contact box straight to the full-bleed footer bar —
     no gap, and a distinct lead-gray tone instead of repeating the contact
     box's blue so the two don't blur into one shape. */
  .section--contact {
    padding-bottom: 0;
  }

  .footer-row {
    background: #34383e;
  }

  /* The 16:9 aspect-ratio panel works on desktop but fights mobile screens:
     tiny in portrait, taller than the viewport in landscape (clipping the
     game's own top/bottom UI). Go edge-to-edge instead and let the embedded
     game's own responsive layout fill whatever space it actually gets. */
  .game-modal {
    padding: 0;
  }

  .game-modal__panel {
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    border-radius: 0;
  }

  .game-modal__frame {
    aspect-ratio: auto;
    flex: 1;
    min-height: 0;
  }

  .game-modal__controls {
    gap: 8px 14px;
    font-size: 0.78rem;
  }
}

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

  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 1ms !important;
    transition-delay: 0ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  .intro-screen {
    display: none;
  }
}
