/* Shared light/dark surfaces. Client imagery retains its original colours. */
:root {
  color-scheme: light;
  --bg: #eeedf2;
  --bg-2: #e4dfea;
  --panel: #f8f6fa;
  --panel-2: #ded3ec;
  --ink: #231b2c;
  --muted: #5d5269;
  --soft: #5d5269;
  --line: #cbc0d6;
  --line-strong: #a18bb5;
  --violet: #7750b5;
  --violet-deep: #513182;
  --accent: #7041ab;
  --button-bg: #30203f;
  --button-ink: #faf6ff;
  --nav-bg: #eeedf2;
  --footer-bg: #d7c6eb;
  --scene-1: #eeedf2;
  --scene-2: #e3d8ee;
  --scene-3: #d7c5e9;
  --scene-4: #e2d7ee;
  --scene-5: #eeedf2;
  --logo-filter: none;
  --wordmark-filter: brightness(0.22);
  --symbol-filter: brightness(0.8);
  --shadow: #20132b14;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #15121b;
  --bg-2: #211b2b;
  --panel: #251e30;
  --panel-2: #30233f;
  --ink: #f1eaf8;
  --muted: #bfb1cd;
  --soft: #bfb1cd;
  --line: #45394f;
  --line-strong: #806a94;
  --violet: #b28ae8;
  --violet-deep: #cfb3f5;
  --accent: #c39af5;
  --button-bg: #c7a7ee;
  --button-ink: #21152f;
  --nav-bg: #15121b;
  --footer-bg: #251c32;
  --scene-1: #15121b;
  --scene-2: #20182a;
  --scene-3: #30233f;
  --scene-4: #261e31;
  --scene-5: #15121b;
  --logo-filter: brightness(0) invert(1);
  --wordmark-filter: none;
  --symbol-filter: brightness(1.2);
  --shadow: #0005;
}

/* A single control in the header is available at every breakpoint. */
.theme-toggle {
  flex: 0 0 44px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: transparent;
  color: var(--ink);
  position: relative;
  isolation: isolate;
}
.theme-toggle[hidden] {
  display: none;
}
.theme-toggle::before {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: inherit;
  background: var(--panel-2);
  transform: scale(0);
  transition: transform 0.35s var(--ease);
  z-index: -1;
}
.theme-toggle:hover::before {
  transform: scale(1);
}
.theme-toggle:active {
  transform: scale(0.94);
}
.theme-icon {
  overflow: visible;
  transform: rotate(0);
  transition: transform 0.65s var(--ease);
}
.theme-sun {
  transition: r 0.45s var(--ease);
}
.theme-rays {
  transform-origin: 12px 12px;
  transition:
    opacity 0.25s,
    transform 0.55s var(--ease);
}
.theme-moon-cutout {
  transition: transform 0.55s var(--ease);
}
[data-theme="dark"] .theme-icon {
  transform: rotate(-25deg);
}
[data-theme="dark"] .theme-sun {
  r: 7px;
}
[data-theme="dark"] .theme-rays {
  opacity: 0;
  transform: rotate(60deg) scale(0.4);
}
[data-theme="dark"] .theme-moon-cutout {
  transform: translate(-9px, 9px);
}
::view-transition-old(root),
::view-transition-new(root) {
  animation: none;
  mix-blend-mode: normal;
}
::view-transition-old(root) {
  z-index: 1;
}
::view-transition-new(root) {
  z-index: 2;
}
::view-transition,
::view-transition-group(root),
::view-transition-image-pair(root),
::view-transition-old(root),
::view-transition-new(root) {
  pointer-events: none;
}

/* Explicit semantic colours also cover the legacy page and checker templates. */
:root body {
  background: var(--bg);
  color: var(--ink);
}
:root .nav-shell {
  background: var(--nav-bg);
  color: var(--ink);
  border-color: var(--line);
  gap: 24px;
}
:root .nav-links a,
:root .nav-shell .lang-toggle a,
:root .mobile-menu a {
  color: var(--ink);
}
:root .nav-shell .lang-toggle a.active {
  color: var(--ink);
  border-color: var(--ink);
}
:root .nav-shell .brand img {
  filter: var(--logo-filter);
}
:root .menu-toggle span {
  background: var(--ink);
}
:root .nav-actions {
  gap: 18px;
}
:root .mobile-menu {
  background: var(--bg);
  color: var(--ink);
  border-color: var(--line);
}
:root .button,
:root .nav-shell .nav-button,
:root .footer-cta > .button {
  background: var(--button-bg);
  border-color: var(--button-bg);
  color: var(--button-ink);
}
:root .button:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--button-ink);
}
:root .button.secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
:root .text-link,
:root .card-text-link,
:root .case-link {
  color: inherit;
  border-color: var(--line-strong);
}
:root .text-link::after,
:root .card-text-link::after,
:root .button::after,
:root .case-link::after {
  content: none !important;
  display: none !important;
}

:root .statement,
:root .services,
:root .portfolio,
:root .why-webify,
:root .page-hero,
:root .faq,
:root .testimonials {
  background: var(--bg);
  color: var(--ink);
}
:root .services {
  --ink: inherit;
  --muted: inherit;
  --line: inherit;
}
:root .services .service-card > span {
  color: var(--accent);
}
:root .portfolio-detail-card > div:last-child {
  background: transparent;
  color: var(--ink);
}
:root .process-section,
:root .logo-strip,
:root .technology-section,
:root .page-cta {
  background: var(--bg-2);
  color: var(--ink);
  --muted: var(--soft);
  border-color: var(--line);
}
:root .section-heading > p,
:root .statement-sub,
:root .service-card p,
:root .project-card p,
:root .portfolio-detail-card p,
:root .process-step > p,
:root .technology-grid p,
:root .technology-grid .text-link,
:root .why-card p,
:root .testimonial-rating,
:root .testimonial-rating span,
:root .testimonial-rating small,
:root .testimonial-person,
:root .accordion details p,
:root .breadcrumbs,
:root .breadcrumbs a,
:root .page-hero p,
:root .guide-article,
:root .policy-content,
:root .case-meta span,
:root .case-meta p,
:root .case-gallery figcaption,
:root .contact-panel p,
:root .booking-note,
:root .booking-note a,
:root .calendly-booking-copy p,
:root .calendly-booking-copy > span,
:root .consent-popover p,
:root .consent-links,
:root .consent-links a {
  color: var(--muted);
}
:root .testimonial-person strong,
:root .accordion summary,
:root .logo-strip-heading,
:root .logo-strip-heading h2,
:root .vescun-wordmark,
:root .logo-item.logo-luovaillen > span {
  color: var(--ink);
}
:root .process-step,
:root .accordion details,
:root .guide-article td,
:root .guide-article th {
  border-color: var(--line);
}
:root .process-section .process-step > span,
:root .accordion summary::after,
:root .contact-panel a,
:root .seo-link-row {
  color: var(--accent);
}
:root .seo-copy-block a:not(.button),
:root .policy-content a:not(.button),
:root .guide-article a:not(.button) {
  color: var(--accent);
}
:root .booking-panel,
:root .seo-note-card,
:root .quick-facts,
:root .case-gallery figure,
:root .consent-popover {
  background: var(--panel);
  color: var(--ink);
  border-color: var(--line);
}
:root .seo-note-card p,
:root .quick-facts dt {
  color: var(--muted);
}
:root .project-filters button,
:root .logo-motion-toggle,
:root .testimonial-controls button {
  color: var(--ink);
  border-color: var(--line-strong);
}
:root .project-filters button[aria-pressed="true"] {
  background: var(--button-bg);
  color: var(--button-ink);
}
:root .project-filters sup {
  opacity: 1;
}
:root .portfolio-section-title h2 {
  color: var(--muted);
}
:root .portfolio-section-title::after,
:root .process-timeline::before {
  background: var(--line);
}
:root body[data-page="case"] .case-hero {
  background: var(--bg-2);
  color: var(--ink);
}
:root body[data-page="case"] .case-hero p {
  color: var(--muted);
}
:root .footer {
  background: var(--footer-bg);
  color: var(--ink);
  --muted: var(--soft);
}
:root .footer-cta {
  border-color: var(--line-strong);
}
:root .footer-cta > div > span,
:root .footer-cta p,
:root .footer-location,
:root .footer-location p,
:root .footer-location a,
:root .footer-bottom,
:root .footer-bottom a,
:root .footer-bottom strong {
  color: var(--ink);
}
[data-theme="dark"] .footer-logo img {
  filter: brightness(0) invert(1);
}
/* Transparent marks reverse with the theme instead of sitting on pale tiles. */
:root .logo-item {
  background: transparent;
}
:root .logo-item img {
  background: transparent;
  filter: brightness(0);
  opacity: 0.9;
}
:root .vescun-wordmark-name,
:root .vescun-wordmark-meta {
  color: inherit;
}
:root[data-theme="dark"] .logo-item img {
  filter: brightness(0) invert(1);
}
/* This original JPEG has a white backdrop. Blend it out in either theme. */
:root .logo-item.logo-light {
  isolation: isolate;
  background: var(--bg-2);
}
:root .logo-item.logo-light img {
  padding: 0;
  filter: grayscale(1) contrast(1.25);
  mix-blend-mode: multiply;
}
:root[data-theme="dark"] .logo-item.logo-light img {
  filter: grayscale(1) contrast(1.25) invert(1);
  mix-blend-mode: screen;
}

:root .checker-form-panel,
:root .checker-score,
:root .checker-category,
:root .checker-finding,
:root .checker-summary,
:root .checker-report-header {
  background: var(--panel) !important;
  color: var(--ink) !important;
  border-color: var(--line) !important;
}
:root .checker-results {
  --ink: inherit;
  --muted: var(--soft);
  --panel: inherit;
  --line: inherit;
}
:root .checker-form-panel input {
  background: var(--bg) !important;
  color: var(--ink) !important;
  border-color: var(--line-strong) !important;
}
:root .checker-facts span,
:root .checker-cta {
  background: var(--panel-2) !important;
  color: var(--ink) !important;
}
:root .checker-small,
:root .checker-disclaimer,
:root .checker-privacy,
:root .checker-cta p,
:root .checker-method strong,
:root #checker-status {
  color: var(--muted) !important;
  border-color: var(--line) !important;
}
:root #checker-error {
  color: #b32d3c;
}
[data-theme="dark"] #checker-error {
  color: #ff9aa6;
}

/* Theme changes repaint the current cinematic composition, never reset scroll. */
:root .cinematic-wrap,
:root .cinematic-story,
:root .cinema-sticky {
  background: var(--scene-1);
  color: var(--ink);
}
:root .cinema-panel {
  color: var(--ink);
}
:root .cinema-panel .cinema-accent {
  color: var(--accent);
}
:root .cinema-intro,
:root .cinema-link,
:root .cinema-business-intro p {
  color: var(--muted);
}
:root .cinematic-story:not(.cinema-enhanced) .cinema-panel {
  background: var(--bg);
}
:root .cinematic-story:not(.cinema-enhanced) .cinema-arrival {
  background: transparent;
}
:root .cinematic-story:not(.cinema-enhanced) .cinema-design,
:root .cinematic-story:not(.cinema-enhanced) .cinema-results {
  background: var(--bg-2);
}
:root .cinema-brand-reveal img.cinema-brand-wordmark {
  filter: var(--wordmark-filter);
}
:root .cinema-brand-reveal > img:not(.cinema-brand-wordmark),
:root .technology-graphic .technology-mark {
  filter: var(--symbol-filter);
}
:root .helmet-fallback img {
  object-fit: contain;
}
:root .cinema-project {
  background: var(--panel);
  color: var(--ink);
  border-color: var(--line-strong);
}
:root .cinema-project-picker button {
  color: var(--muted);
  border-color: var(--line);
}
:root .cinema-project-picker button[aria-pressed="true"] {
  color: var(--ink);
  border-color: var(--ink);
}
:root .cinema-chapters button,
:root .cinema-chapters button[aria-current] {
  color: var(--ink);
}
:root .cinema-controls,
:root .cinematic-story .cinema-skip {
  background: var(--panel);
  color: var(--ink);
  border-color: var(--line-strong);
}
:root .cinema-skip {
  top: 110px;
}
:root .cinema-controls button {
  color: var(--ink);
}
:root .cinema-controls button:hover {
  background: var(--panel-2);
}
:root .cinema-business-intro {
  display: block;
  padding-block: clamp(45px, 6vw, 90px);
}
:root .cinema-business-intro p {
  max-width: 900px;
  margin-left: auto;
  font-size: clamp(16px, 1.7vw, 25px);
}
.cinema-chapters {
  gap: 2px;
}
.cinema-chapters button {
  justify-content: center;
  width: 40px;
  min-height: 44px;
}
.cinema-chapters button i {
  width: 6px;
  height: 6px;
  border-radius: 5px;
  opacity: 0.4;
  transition:
    width 0.3s,
    opacity 0.3s;
}
.cinema-chapters button[aria-current] i {
  width: 24px;
  height: 6px;
  opacity: 1;
}

/* Text stays in document flow. Mask padding protects accents and descenders. */
:root h1,
:root h2,
:root h3,
:root h4 {
  overflow-wrap: break-word;
  letter-spacing: -0.035em;
}
:root h3,
:root h4 {
  letter-spacing: -0.025em;
}
:root .section-heading > *,
:root .statement-grid > *,
:root .service-card > *,
:root .process-step,
:root .case-hero-grid > *,
:root .footer-cta > * {
  min-width: 0;
}
:root .statement-grid,
:root.section-motion-enabled .sm-home-statement .statement-grid {
  display: block;
}
:root .statement-grid h2 {
  max-width: 1100px;
}
:root .statement-sub {
  margin-top: 30px;
}
:root .cinema-line {
  line-height: 1.08;
  padding-bottom: 0.1em;
  margin-bottom: -0.06em;
}
:root .cinema-panel h1,
:root .cinema-panel h2 {
  line-height: 1.08;
  letter-spacing: -0.045em;
}
:root .cinema-arrival h1 {
  max-width: 54%;
}
:root .cinema-panel h2 {
  overflow-wrap: normal;
}
:root .cinema-design h2 {
  font-size: clamp(38px, 4.5vw, 88px);
}
:root .cinema-engineering h2 {
  font-size: clamp(40px, 5.3vw, 100px);
}
:root .cinema-panel p {
  line-height: 1.7;
}
:root .cinema-project-caption {
  flex-wrap: wrap;
  gap: 8px 18px;
}
:root .cinema-project-caption strong {
  line-height: 1.25;
}
:root .cinema-project-caption > span {
  white-space: nowrap;
}
:root .sm-home-project h3 {
  line-height: 1.12;
  margin-bottom: 0;
}
:root .sm-home-project > div:last-child {
  align-items: start;
}
:root .sm-home-project > div:last-child > p {
  grid-row: 1;
}
:root .process-step h3 {
  line-height: 1.2;
  margin-top: 26px;
}
:root .process-timeline {
  align-items: start;
  row-gap: 56px;
}
:root .page-hero h1,
:root .case-hero h1 {
  line-height: 1.12;
  letter-spacing: -0.04em;
}
:root .page-hero p,
:root .case-hero p {
  margin-top: 0;
}
:root
  body[data-page="case"][data-route*="black-eagle"]
  .case-hero-grid
  > div
  > :not(h1) {
  grid-column: 2;
}
:root body[data-page="case"][data-route*="black-eagle"] .case-hero h1 {
  grid-row: 1 / span 5;
}

@media (max-width: 1100px) {
  :root .nav-shell {
    gap: 16px;
  }
  :root .nav-actions {
    gap: 12px;
    margin-left: auto;
  }
  :root .nav-links {
    gap: 20px;
  }
}
@media (max-width: 899px) {
  :root .sm-home-project h3 {
    margin: 0 0 22px;
  }
  :root .section-heading {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  :root .section-heading > p {
    margin-top: 0;
  }
}
@media (max-width: 759px) {
  :root .nav-shell {
    padding-inline: 20px;
    gap: 12px;
  }
  :root .nav-actions {
    gap: 10px;
  }
  :root .nav-shell .brand {
    gap: 3px;
  }
  :root .nav-shell .brand img {
    width: 35px;
    margin-right: 5px;
    transform: scale(1.35);
  }
  :root .brand-wordmark {
    font-size: 24px;
  }
  :root .nav-lang {
    gap: 9px;
  }
  :root .theme-toggle,
  :root .menu-toggle {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
  }
  :root .cinema-enhanced .cinema-arrival,
  :root .cinema-eligible .cinema-arrival,
  :root .cinema-enhanced .cinema-design,
  :root .cinema-enhanced .cinema-engineering,
  :root .cinema-enhanced .cinema-results {
    padding-top: 145px;
  }
  :root .cinema-arrival h1 {
    font-size: clamp(40px, min(15.2vw, 8.8svh), 84px);
  }
  :root .cinema-arrival h1 {
    max-width: 100%;
  }
  :root .cinema-skip {
    top: 90px;
  }
  :root .cinema-design h2,
  :root .cinema-engineering h2 {
    font-size: clamp(34px, min(10.7vw, 7svh), 70px);
    max-width: 100%;
  }
  :root .cinema-results h2 {
    font-size: min(14vw, 7.7svh);
  }
  :root .cinema-outro h2 {
    font-size: min(12.5vw, 8svh);
  }
  :root .cinema-outro .hero-actions {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
  }
  :root .cinema-chapters {
    gap: 0;
  }
  :root .cinema-chapters button {
    width: 28px;
  }
  :root .cinema-chapters button i {
    width: 5px;
    height: 5px;
  }
  :root .cinema-chapters button[aria-current] i {
    width: 16px;
    height: 5px;
  }
  :root .cinema-enhanced .cinema-engineering p,
  :root .cinema-enhanced .cinema-design p {
    bottom: 135px;
  }
  :root .cinema-enhanced .cinema-project-picker {
    bottom: 106px;
  }
  :root .cinema-project-picker button {
    font-size: 10px;
  }
  :root .process-timeline {
    grid-template-columns: 1fr;
    gap: 38px;
  }
  :root .process-step h3 {
    font-size: 28px;
    margin: 20px 0 18px;
  }
  :root .process-step > p:last-child {
    font-size: 14px;
  }
  :root .cinema-business-intro p {
    margin: 0;
  }
}
@media (max-width: 759px) and (max-height: 740px) {
  :root .cinema-enhanced .cinema-arrival,
  :root .cinema-eligible .cinema-arrival,
  :root .cinema-enhanced .cinema-design,
  :root .cinema-enhanced .cinema-engineering,
  :root .cinema-enhanced .cinema-results {
    padding-top: 130px;
  }
  :root .cinema-arrival h1 {
    font-size: min(13vw, 7.7svh);
  }
  :root .cinema-enhanced .cinema-projects {
    top: 42%;
  }
  :root .cinema-project-caption strong {
    font-size: 14px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .theme-icon,
  .theme-sun,
  .theme-rays,
  .theme-moon-cutout,
  .theme-toggle::before {
    transition: none;
  }
}
@media print {
  :root body,
  :root .footer,
  :root .section {
    background: white;
    color: black;
  }
  .theme-toggle {
    display: none;
  }
}
