:root {
  --accent: #4b5563;
  --accent-hover: #374151;
  --accent-pressed: #111827;
  --focus-ring: rgba(31, 41, 55, 0.24);
  --text: rgba(255, 255, 255, 0.92);
  --text-muted: rgba(235, 239, 248, 0.68);
  --control-text: rgba(17, 24, 39, 0.74);
  --control-muted: rgba(17, 24, 39, 0.66);
  --control-shadow: 0 1px 18px rgba(255, 255, 255, 0.72);
  --control-muted-shadow: 0 1px 18px rgba(255, 255, 255, 0.78);
  --glass-bg: rgba(255, 255, 255, 0.16);
  --glass-border: rgba(255, 255, 255, 0.28);
  --shadow: 0 24px 80px rgba(2, 6, 23, 0.28);
  --page-inset: clamp(18px, 4vw, 48px);
  --nav-x-padding: clamp(22px, 4.8vw, 64px);
  --nav-font-size: clamp(1.15rem, 1rem + 0.45vw, 1.56rem);
  --nav-control-height: calc(var(--nav-font-size) + 1.44rem);
  --header-height: clamp(68px, 5.2vw, 82px);
  --header-side-padding: calc((var(--header-height) - var(--nav-control-height)) / 2);
  color-scheme: dark;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
  font-size: 16px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: #0b0f1a;
}

body {
  min-height: 100svh;
  margin: 0;
  overflow: hidden;
  background: #0b0f1a;
  color: var(--text);
  text-rendering: geometricPrecision;
  -webkit-font-smoothing: antialiased;
}

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

.background-slideshow {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: #0b0f1a;
  isolation: isolate;
}

.background-slideshow::after {
  position: absolute;
  inset: 0;
  z-index: 2;
  content: "";
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(3, 7, 18, 0.14) 0%, rgba(3, 7, 18, 0.04) 44%, rgba(3, 7, 18, 0.34) 100%),
    radial-gradient(circle at 50% 18%, rgba(255, 255, 255, 0.16), transparent 34%);
}

.background-slide {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1800ms ease;
  will-change: opacity;
}

.background-slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--slide-position, center center);
  transform: translateZ(0) scale(1);
  transition: transform 6200ms ease-out;
  will-change: transform;
  backface-visibility: hidden;
}

.background-slide.is-position-top img {
  object-position: center top;
}

.background-slide.is-position-bottom img {
  object-position: center bottom;
}

.background-slide.is-position-left img {
  object-position: left center;
}

.background-slide.is-position-right img {
  object-position: right center;
}

.background-slide.is-active {
  opacity: 1;
}

.background-slide.is-active img,
.background-slide.is-leaving img {
  transform: translateZ(0) scale(1.1);
}

.background-slide.is-leaving {
  opacity: 0;
}

.background-slide.is-resetting img {
  transform: translateZ(0) scale(1);
  transition: none;
}

.site-header {
  position: fixed;
  top: var(--page-inset);
  right: var(--page-inset);
  left: var(--page-inset);
  z-index: 10;
  height: var(--header-height);
  overflow: hidden;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.09)),
    var(--glass-bg);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.32);
  backdrop-filter: blur(26px) saturate(180%);
  -webkit-backdrop-filter: blur(26px) saturate(180%);
}

.site-header::before {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.34), transparent 42%),
    linear-gradient(270deg, rgba(255, 255, 255, 0.14), transparent 32%);
  opacity: 0.72;
}

.site-nav {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 0 var(--header-side-padding);
}

.brand-link,
.contact-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  border-radius: 999px;
  color: var(--control-text);
  font-size: var(--nav-font-size);
  font-weight: 500;
  line-height: 1;
  outline: none;
  transition:
    color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease,
    text-shadow 180ms ease,
    transform 120ms ease;
  text-shadow: var(--control-shadow);
}

.brand-link,
.contact-link {
  padding: 0.72rem 1rem;
}

.brand-link:hover,
.contact-link:hover {
  color: rgba(255, 255, 255, 0.98);
  background: var(--accent-hover);
  text-shadow: none;
}

.brand-link:active,
.contact-link:active {
  color: rgba(255, 255, 255, 0.98);
  background: var(--accent-pressed);
  text-shadow: none;
  transform: translateY(1px);
}

.site-main {
  position: relative;
  z-index: 1;
  min-height: 100svh;
}

.site-footer {
  position: fixed;
  left: 50%;
  bottom: clamp(16px, 2.8vw, 34px);
  z-index: 10;
  display: flex;
  gap: clamp(8px, 1.2vw, 14px);
  align-items: center;
  width: max-content;
  max-width: calc(100vw - (var(--page-inset) * 2));
  padding: 8px;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.08)),
    var(--glass-bg);
  box-shadow: 0 18px 56px rgba(2, 6, 23, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.32);
  font-size: clamp(0.78rem, 0.72rem + 0.15vw, 0.9rem);
  font-weight: 450;
  color: var(--control-muted);
  text-shadow: var(--control-muted-shadow);
  transform: translateX(-50%);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
}

.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0.34rem 0.62rem;
  border-radius: 999px;
  color: var(--control-muted);
  text-shadow: var(--control-muted-shadow);
  outline: none;
  transition:
    color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease,
    text-shadow 180ms ease,
    transform 120ms ease;
}

.site-footer a:hover {
  color: rgba(255, 255, 255, 0.98);
  background: var(--accent-hover);
  text-shadow: none;
}

.site-footer a:active {
  color: rgba(255, 255, 255, 0.98);
  background: var(--accent-pressed);
  text-shadow: none;
  transform: translateY(1px);
}

.brand-link:focus-visible,
.contact-link:focus-visible,
.site-footer a:focus-visible {
  box-shadow: 0 0 0 4px var(--focus-ring);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.legal-page {
  min-height: 100svh;
  overflow: auto;
  padding: calc(var(--page-inset) + var(--header-height) + 72px)
    var(--page-inset) 112px;
  background:
    linear-gradient(135deg, rgba(15, 98, 254, 0.22), transparent 38%),
    linear-gradient(180deg, #8fa1bb 0%, #e7edf7 34%, #f8fafc 100%);
  color: #101828;
}


.legal-content {
  width: min(100%, 820px);
  margin: 0 auto;
}

.legal-content h1 {
  margin: 0 0 44px;
  font-size: clamp(2rem, 1.5rem + 1.6vw, 3.25rem);
  font-weight: 600;
  line-height: 1.08;
}

.legal-content section {
  padding: 28px 0;
  border-top: 1px solid rgba(16, 24, 40, 0.12);
}

.legal-content h2 {
  margin: 0 0 12px;
  color: rgba(16, 24, 40, 0.92);
  font-size: clamp(1.05rem, 0.98rem + 0.22vw, 1.22rem);
  font-weight: 600;
  line-height: 1.24;
}

.legal-content p {
  max-width: 58ch;
  margin: 0 0 14px;
  color: rgba(16, 24, 40, 0.68);
  font-size: 1rem;
  line-height: 1.65;
}

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

.legal-content a {
  color: var(--accent);
  outline: none;
  transition:
    color 180ms ease,
    box-shadow 180ms ease;
}

.legal-content a:hover,
.legal-content a:focus-visible {
  color: var(--accent-pressed);
}

.legal-content a:active {
  color: #000;
}

.legal-content a:focus-visible {
  border-radius: 4px;
  box-shadow: 0 0 0 4px var(--focus-ring);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header {
    background: rgba(16, 22, 35, 0.86);
  }
}

@media (max-width: 640px) {
  :root {
    --header-height: 72px;
    --header-side-padding: 14px;
  }

  .site-nav {
    padding: 0 var(--header-side-padding);
  }

  .contact-link {
    padding-right: 0.76rem;
    padding-left: 0.76rem;
  }

  .site-footer {
    bottom: 18px;
  }

  .site-footer a {
    min-height: 30px;
    padding: 0.34rem 0.58rem;
  }

  .legal-page {
    padding-top: calc(var(--page-inset) + var(--header-height) + 56px);
    padding-bottom: 96px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
  }

  .background-slide,
  .brand-link,
  .contact-link,
  .site-footer a {
    transition-duration: 1ms !important;
  }
}
