:root {
  --bg: #0b0c10;
  --bg-elev: #0f111a;
  --panel: rgba(255, 255, 255, 0.05);
  --panel-strong: rgba(255, 255, 255, 0.08);
  --border: rgba(255, 255, 255, 0.12);
  --text: rgba(255, 255, 255, 0.92);
  --muted: rgba(255, 255, 255, 0.72);
  --muted-2: rgba(255, 255, 255, 0.6);
  --shadow: 0 18px 45px rgba(0, 0, 0, 0.55);
  --radius: 18px;

  --accent-a: #c7c9ff;
  --accent-b: #d67eff;
  --accent-c: #da69ff;
  --accent: linear-gradient(135deg, var(--accent-a), var(--accent-b) 55%, var(--accent-c));

  --container: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  height: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  min-height: 100%;
  color: var(--text);
  overflow-x: hidden;
  background: var(--bg);
  position: relative;
  isolation: isolate;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  line-height: 1.45;
  letter-spacing: -0.01em;
}

/* Anchor the ambient gradients to the viewport for smoother transitions */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(
      1200px 820px at 18% -12%,
      rgba(214, 126, 255, 0.22) 0%,
      rgba(214, 126, 255, 0.1) 36%,
      rgba(214, 126, 255, 0) 73%
    ),
    radial-gradient(
      1200px 820px at 92% 8%,
      rgba(199, 201, 255, 0.18) 0%,
      rgba(199, 201, 255, 0.08) 38%,
      rgba(199, 201, 255, 0) 75%
    ),
    radial-gradient(
      1200px 920px at 60% 118%,
      rgba(218, 105, 255, 0.18) 0%,
      rgba(218, 105, 255, 0.07) 40%,
      rgba(218, 105, 255, 0) 75%
    ),
    radial-gradient(1000px 700px at 50% 38%, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0) 66%),
    linear-gradient(180deg, rgba(11, 12, 16, 0) 0%, rgba(11, 12, 16, 0.25) 55%, rgba(11, 12, 16, 0.6) 100%),
    var(--bg);
}

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

a:hover {
  opacity: 0.95;
}

/* Reduce tap highlight on touch devices */
a,
button,
[role="button"] {
  -webkit-tap-highlight-color: rgba(214, 126, 255, 0.2);
}

.container {
  width: min(var(--container), calc(100% - 40px));
  margin: 0 auto;
  padding-left: env(safe-area-inset-left, 0);
  padding-right: env(safe-area-inset-right, 0);
}

.skip {
  position: absolute;
  left: -999px;
  top: 10px;
  padding: 10px 12px;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 12px;
  z-index: 1000;
}

.skip:focus {
  left: 12px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11, 12, 16, 0.65);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 240px;
}

.brand__logo {
  display: block;
}

.brand__text {
  display: grid;
  gap: 2px;
}

.brand__name {
  font-weight: 720;
  letter-spacing: -0.02em;
}

.brand__sub {
  font-size: 12px;
  color: var(--muted-2);
}

.topbar .nav__contact {
  min-height: 44px;
  font-size: 14px;
}

.hero {
  padding: 72px 0 40px;
  position: relative;
}

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -40px;
  height: 96px;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(11, 12, 16, 0) 0%, rgba(11, 12, 16, 0.22) 55%, rgba(11, 12, 16, 0) 100%);
  opacity: 0.75;
}

.hero__inner {
  display: grid;
  gap: 28px;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
  padding: 8px 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.kicker::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(214, 126, 255, 0.12);
}

h1 {
  margin: 14px 0 12px;
  font-size: clamp(36px, 4.2vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.lede {
  margin: 0;
  font-size: 16px;
  color: var(--muted);
  max-width: 62ch;
}

main {
  overflow-wrap: break-word;
}

/* 404 page: stick footer to bottom of viewport when content is short */
.page-404 {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}
.page-404 #main {
  flex: 1;
}

.hero__cta {
  display: flex;
  gap: 12px;
  margin-top: 22px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 20px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-size: 14px;
  font-weight: 620;
  letter-spacing: -0.01em;
  background: rgba(255, 255, 255, 0.04);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  font-family: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

@media (hover: hover) {
  .btn:hover {
    transform: translateY(-1px);
  }
  .product__links a:hover {
    transform: translateY(-1px);
  }
}

.btn:focus-visible {
  outline: 2px solid var(--accent-b);
  outline-offset: 2px;
}

.btn--primary {
  border-color: rgba(255, 255, 255, 0.12);
  background: var(--accent);
  color: rgba(10, 10, 14, 0.92);
  box-shadow: 0 14px 30px rgba(214, 126, 255, 0.18);
}

.btn--primary:hover {
  box-shadow: 0 18px 36px rgba(214, 126, 255, 0.26);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.9);
  border-color: rgba(255, 255, 255, 0.18);
}

a.btn[aria-disabled="true"] {
  opacity: 0.5;
  pointer-events: none;
  cursor: not-allowed;
}

.card {
  position: relative;
  padding: 18px;
  border-radius: calc(var(--radius) + 4px);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.card--glow::before {
  content: "";
  position: absolute;
  inset: -2px;
  background: radial-gradient(
      800px 420px at 30% 10%,
      rgba(214, 126, 255, 0.22) 0%,
      rgba(214, 126, 255, 0.11) 38%,
      rgba(214, 126, 255, 0) 74%
    ),
    radial-gradient(
      900px 450px at 90% 30%,
      rgba(199, 201, 255, 0.18) 0%,
      rgba(199, 201, 255, 0.09) 38%,
      rgba(199, 201, 255, 0) 74%
    ),
    radial-gradient(
      600px 420px at 40% 120%,
      rgba(218, 105, 255, 0.16) 0%,
      rgba(218, 105, 255, 0.07) 40%,
      rgba(218, 105, 255, 0) 76%
    );
  filter: blur(18px);
  opacity: 0.9;
  pointer-events: none;
}

.card > * {
  position: relative;
}

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

.pill {
  font-size: 12px;
  color: var(--muted);
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
}

.card__logo {
  display: grid;
  place-items: center;
  padding: 14px 0 6px;
}

.card__logo img {
  width: min(270px, 100%);
  height: auto;
  display: block;
  filter: drop-shadow(0 18px 45px rgba(0, 0, 0, 0.45));
}

.card__note {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.section {
  padding: 54px 0;
  position: relative;
}

/* Use a subtle, non-blocky divider without adding repeating glow bands */
.section {
  background-image: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0),
    rgba(255, 255, 255, 0.065),
    rgba(255, 255, 255, 0)
  );
  background-repeat: no-repeat;
  background-size: min(60%, 480px) 1px;
  background-position: 50% 0;
}

.section--alt {
  background: none;
  isolation: isolate;
}

.section--alt::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.9;
  background: radial-gradient(1100px 460px at 50% 0%, rgba(214, 126, 255, 0.12) 0%, rgba(214, 126, 255, 0) 64%),
    radial-gradient(1000px 440px at 50% 100%, rgba(199, 201, 255, 0.09) 0%, rgba(199, 201, 255, 0) 68%),
    radial-gradient(900px 420px at 12% 58%, rgba(218, 105, 255, 0.06) 0%, rgba(218, 105, 255, 0) 72%),
    linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.012) 50%, rgba(255, 255, 255, 0) 100%);

  /* Fade the effect at the edges so the section doesn't read as a hard block */
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 1) 18%, rgba(0, 0, 0, 1) 82%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 1) 18%, rgba(0, 0, 0, 1) 82%, transparent 100%);
}

.section > .container {
  position: relative;
  z-index: 1;
}
.section__head {
  display: grid;
  gap: 8px;
  margin-bottom: 22px;
}

h2 {
  margin: 0;
  font-size: 24px;
  letter-spacing: -0.02em;
}

.section__head p {
  margin: 0;
  color: var(--muted);
  max-width: 72ch;
}

.grid {
  display: grid;
  gap: 16px;
}

.grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.panel {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  border-radius: var(--radius);
  padding: 18px;
}

.panel h3 {
  margin: 0 0 8px;
  font-size: 16px;
  letter-spacing: -0.01em;
}

.panel p {
  margin: 0;
  color: var(--muted);
}

.panel p + p {
  margin-top: 10px;
}

.cards {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.product {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 17, 26, 0.38);
  border-radius: var(--radius);
  padding: 18px;
  overflow: hidden;
  position: relative;
}

.product::before {
  content: "";
  position: absolute;
  inset: -1px;
  background: radial-gradient(
    600px 240px at 30% 0%,
    rgba(214, 126, 255, 0.14) 0%,
    rgba(214, 126, 255, 0.06) 40%,
    rgba(214, 126, 255, 0) 76%
  );
  opacity: 0.8;
  pointer-events: none;
}

.product > * {
  position: relative;
}

.product__logo {
  height: 56px;
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.product__logo img {
  max-height: 56px;
  max-width: 100%;
  width: auto;
  height: auto;
  display: block;
}

.product h3 {
  margin: 0 0 8px;
  font-size: 18px;
  letter-spacing: -0.01em;
}

.product p {
  margin: 0;
  color: var(--muted);
}

.product__links {
  margin-top: 14px !important;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.product__links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 560;
  letter-spacing: -0.01em;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.9);
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.product__links a:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(214, 126, 255, 0.35);
  color: #fff;
  transform: translateY(-1px);
}

.product__links a:focus-visible {
  outline: 2px solid var(--accent-b);
  outline-offset: 2px;
}

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

.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  padding-left: max(20px, env(safe-area-inset-left));
  padding-right: max(20px, env(safe-area-inset-right));
  padding-bottom: max(20px, env(safe-area-inset-bottom));
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.modal--open {
  opacity: 1;
  visibility: visible;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(6px);
  cursor: pointer;
}

.modal__dialog {
  position: relative;
  width: min(560px, 100%);
  max-height: calc(100vh - 40px);
  background: var(--bg-elev);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  min-width: 44px;
  min-height: 44px;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease;
}

.modal__close:hover {
  background: rgba(255, 255, 255, 0.18);
}

.modal__close:focus-visible {
  outline: 2px solid var(--accent-b);
  outline-offset: 2px;
}

.modal__iframe {
  width: 100%;
  height: min(80vh, 640px);
  min-height: 400px;
  border: none;
  display: block;
}

.footer {
  position: relative;
  padding: 20px 0 calc(26px + env(safe-area-inset-bottom, 0));
  background: linear-gradient(180deg, rgba(11, 12, 16, 0) 0%, rgba(11, 12, 16, 0.55) 34%, rgba(11, 12, 16, 0.65) 100%);
  backdrop-filter: blur(10px);
}

.footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  max-width: 480px;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0));
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer__name {
  font-weight: 650;
}

.footer__muted,
.footer__meta {
  font-size: 12px;
  color: var(--muted-2);
}

.footer__meta {
  display: inline-flex;
  gap: 8px;
  align-items: center;
}

@media (max-width: 920px) {
  .container {
    width: calc(100% - 32px);
  }
  .topbar__inner {
    padding-top: 12px;
    padding-bottom: 12px;
  }
  .hero {
    padding: 48px 0 36px;
  }
  .hero__inner {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .hero__cta {
    margin-top: 18px;
    gap: 10px;
  }
  .brand {
    min-width: unset;
  }
  .topbar .nav__contact {
    padding: 10px 14px;
    font-size: 13px;
  }
  .section {
    padding: 40px 0;
  }
  .section__head {
    margin-bottom: 18px;
  }
  h2 {
    font-size: 22px;
  }
  .cards {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .grid--2,
  .grid--3 {
    grid-template-columns: 1fr;
  }
  .grid {
    gap: 14px;
  }
  .panel,
  .product {
    padding: 16px;
  }
  .modal {
    padding: 0;
    padding-left: 0;
    padding-right: 0;
    padding-bottom: 0;
    align-items: stretch;
  }
  .modal__dialog {
    width: 100%;
    max-height: none;
    border-radius: 0;
    border-left: none;
    border-right: none;
  }
  .modal__close {
    top: max(12px, env(safe-area-inset-top, 12px));
    right: max(12px, env(safe-area-inset-right, 12px));
  }
  .modal__iframe {
    min-height: 70vh;
  }
}

@media (max-width: 640px) {
  .container {
    width: calc(100% - 24px);
  }
  .brand__sub {
    font-size: 11px;
  }
  .hero {
    padding: 36px 0 28px;
  }
  h1 {
    font-size: clamp(28px, 8vw, 36px);
  }
  .lede {
    font-size: 15px;
  }
  .hero__cta {
    flex-direction: column;
    width: 100%;
  }
  .hero__cta .btn {
    width: 100%;
    justify-content: center;
  }
  .card__logo img {
    width: min(220px, 100%);
  }
  .section {
    padding: 32px 0;
  }
  h2 {
    font-size: 20px;
  }
  .footer__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}

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