:root {
  color-scheme: dark;
  --bg-spread-x: clamp(140px, 18vmax, 260px);
  --bg-spread-top: clamp(190px, 24vmax, 360px);
  --bg-spread-bottom: clamp(120px, 16vmax, 220px);
  --bg: #06070a;
  --bg-soft: rgba(255, 255, 255, 0.03);
  --panel: rgba(10, 12, 16, 0.68);
  --panel-strong: rgba(14, 16, 22, 0.84);
  --text: rgba(255, 255, 255, 0.95);
  --muted: rgba(255, 255, 255, 0.68);
  --line: rgba(255, 255, 255, 0.12);
  --line-strong: rgba(255, 255, 255, 0.18);
  --accent: #8dd7cf;
  --accent-strong: #62bfb3;
  --gold: #c7a77a;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  padding: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 20% 15%, rgba(98, 191, 179, 0.16), transparent 28%),
    radial-gradient(circle at 80% 18%, rgba(199, 167, 122, 0.13), transparent 24%),
    linear-gradient(180deg, #050608 0%, #07090d 45%, #040507 100%);
  font-family: "Avenir Next", "Trebuchet MS", "Gill Sans", sans-serif;
  line-height: 1.5;
  overflow: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset:
    calc(-1 * var(--bg-spread-top))
    calc(-1 * var(--bg-spread-x))
    calc(-1 * var(--bg-spread-bottom))
    calc(-1 * var(--bg-spread-x));
  pointer-events: none;
  background-image:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.08), transparent 42%),
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: auto, 42px 42px, 42px 42px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.42), transparent 72%);
}

.fluid-flow {
  position: fixed;
  inset:
    calc(-1 * var(--bg-spread-top))
    calc(-1 * var(--bg-spread-x))
    calc(-1 * var(--bg-spread-bottom))
    calc(-1 * var(--bg-spread-x));
  width: calc(100% + (var(--bg-spread-x) * 2));
  height: calc(100% + var(--bg-spread-top) + var(--bg-spread-bottom));
  display: block;
  pointer-events: auto;
  z-index: 0;
}

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

.page-shell {
  position: relative;
  z-index: 1;
  width: min(1200px, calc(100% - 28px));
  min-height: 100vh;
  margin: 0 auto;
  padding:
    calc(22px + env(safe-area-inset-top))
    0
    calc(28px + env(safe-area-inset-bottom));
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 18px;
}

.page-shell::before {
  content: "";
  position: fixed;
  inset:
    calc(-1 * var(--bg-spread-top))
    calc(-1 * var(--bg-spread-x))
    calc(-1 * var(--bg-spread-bottom))
    calc(-1 * var(--bg-spread-x));
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(circle at 50% 45%, rgba(6, 7, 10, 0.08) 0 20%, rgba(6, 7, 10, 0.22) 42%, rgba(6, 7, 10, 0.55) 72%, rgba(6, 7, 10, 0.82) 100%),
    linear-gradient(180deg, rgba(6, 7, 10, 0.34), rgba(6, 7, 10, 0.2));
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-radius: 22px;
  background: transparent;
  backdrop-filter: none;
  box-shadow: none;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.eyebrow,
.card-label,
.company-card p {
  margin: 0;
}

.brand-logo {
  display: block;
  width: clamp(150px, 18vw, 220px);
  height: auto;
  filter: drop-shadow(0 14px 28px rgba(0, 0, 0, 0.28));
}

.ghost-link {
  appearance: none;
  font: inherit;
  cursor: pointer;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.015);
  color: var(--muted);
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.hero {
  position: relative;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: clamp(32px, 5vw, 72px);
  border-radius: 32px;
  background: transparent;
  backdrop-filter: none;
  box-shadow: none;
  text-align: center;
}

.eyebrow {
  color: rgba(141, 215, 207, 0.88);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.22em;
}

h1 {
  margin: 0;
  max-width: 13ch;
  font-size: clamp(3.4rem, 8vw, 7rem);
  line-height: 0.92;
  letter-spacing: -0.06em;
}

.lede {
  max-width: 30ch;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.2vw, 1.12rem);
}

.ghost-link:hover,
.ghost-link:focus-visible {
  transform: translateY(-1px);
}

.hero-contact {
  margin-top: 6px;
  padding: 9px 13px;
  border: 1px solid rgba(141, 215, 207, 0.24);
  background:
    linear-gradient(145deg, rgba(98, 191, 179, 0.9), rgba(199, 167, 122, 0.7));
  color: #051013;
  box-shadow:
    0 10px 22px rgba(98, 191, 179, 0.12),
    0 0 0 1px rgba(255, 255, 255, 0.04);
  font-weight: 600;
  letter-spacing: 0.01em;
}

.hero-contact:hover,
.hero-contact:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(141, 215, 207, 0.34);
  background:
    linear-gradient(145deg, rgba(114, 205, 194, 0.95), rgba(213, 185, 141, 0.84));
  box-shadow:
    0 12px 24px rgba(98, 191, 179, 0.14),
    0 0 0 1px rgba(255, 255, 255, 0.06);
}

.contact-modal {
  width: min(720px, calc(100dvw - 24px));
  max-width: calc(100dvw - 24px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 28px;
  background:
    radial-gradient(circle at top left, rgba(98, 191, 179, 0.1), transparent 38%),
    linear-gradient(180deg, rgba(8, 10, 14, 0.96), rgba(5, 6, 9, 0.98));
  color: var(--text);
  padding: 0;
  box-shadow: 0 30px 120px rgba(0, 0, 0, 0.6);
}

.contact-modal::backdrop {
  background: rgba(3, 4, 6, 0.72);
  backdrop-filter: blur(8px);
}

.contact-modal-shell {
  display: grid;
  gap: 20px;
  padding: 24px;
  min-width: 0;
}

.contact-modal-close {
  justify-self: end;
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  padding: 8px 12px;
  font: inherit;
  cursor: pointer;
}

.contact-modal-copy h2 {
  margin: 10px 0 8px;
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  line-height: 1;
  letter-spacing: -0.04em;
}

.contact-form {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.contact-form label {
  display: grid;
  gap: 8px;
  font-size: 0.92rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.86);
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  min-width: 0;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font: inherit;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: 2px solid rgba(98, 191, 179, 0.22);
  outline-offset: 2px;
  border-color: rgba(98, 191, 179, 0.42);
}

.submit-button {
  justify-self: start;
  appearance: none;
  border: 1px solid rgba(141, 215, 207, 0.28);
  background: linear-gradient(145deg, rgba(98, 191, 179, 0.95), rgba(199, 167, 122, 0.82));
  color: #051013;
  font: inherit;
  font-weight: 700;
  letter-spacing: 0.02em;
  border-radius: 999px;
  padding: 12px 18px;
  box-shadow:
    0 14px 28px rgba(98, 191, 179, 0.18),
    0 0 0 1px rgba(255, 255, 255, 0.06);
  cursor: pointer;
}

.form-status {
  min-height: 1.2em;
  margin: 0;
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.86rem;
}

.footer-meta {
  position: absolute;
  right: 8px;
  bottom: 8px;
  margin: 0;
  padding: 0;
  text-align: right;
  z-index: 2;
}

.footer-meta > summary {
  list-style: none;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.36);
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 6px 0;
  outline: none;
}

.footer-meta > summary::-webkit-details-marker {
  display: none;
}

.footer-meta > summary::after {
  content: " +";
  color: rgba(255, 255, 255, 0.22);
}

.footer-meta[open] > summary::after {
  content: " -";
}

.footer-meta-panel {
  margin-top: 8px;
  display: grid;
  gap: 3px;
}

.footer-meta-panel p {
  margin: 0;
  color: rgba(255, 255, 255, 0.56);
  font-size: 0.54rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  line-height: 1.35;
}

.footer-meta[open] .footer-meta-panel {
  animation: footerReveal 180ms ease-out;
}

.hero,
.topbar {
  text-shadow: 0 1px 18px rgba(0, 0, 0, 0.18);
}

.hero p,
.ghost-link,
.brand span {
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.22);
}

.modal-open {
  overflow: hidden;
}

@media (max-width: 820px) {
  html {
    overflow-x: clip;
    overflow-y: auto;
    height: auto;
    overscroll-behavior-y: auto;
  }

  body {
    overflow-x: clip;
    overflow-y: auto;
    position: relative;
    width: 100%;
    height: auto;
    -webkit-touch-callout: none;
    touch-action: pan-y;
    overscroll-behavior-y: auto;
  }

  .page-shell {
    position: relative;
    inset: auto;
    height: auto;
    min-height: calc(var(--app-height, 100dvh) - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    width: min(100% - 18px, 1200px);
    padding: calc(10px + env(safe-area-inset-top)) 0
      calc(18px + env(safe-area-inset-bottom));
    overflow: visible;
  }

  .topbar {
    padding: calc(18px + env(safe-area-inset-top)) 14px 10px;
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }

  .brand-logo {
    width: clamp(112px, 36vw, 160px);
  }

  .hero {
    padding: 28px 16px calc(22px + env(safe-area-inset-bottom));
    justify-content: flex-start;
    min-height: 0;
    gap: 10px;
  }

  .hero-contact {
    margin-top: 2px;
    padding: 8px 12px;
  }

  .footer-meta {
    position: static;
    align-self: flex-end;
    margin-top: auto;
    margin-right: 2px;
    z-index: 5;
  }

  .footer-meta > summary {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 10px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.09);
    background: rgba(6, 7, 10, 0.38);
    backdrop-filter: blur(12px);
    color: rgba(255, 255, 255, 0.62);
    font-size: 0.54rem;
    letter-spacing: 0.16em;
  }

  .contact-form input,
  .contact-form textarea {
    -webkit-user-select: text;
    user-select: text;
    -webkit-touch-callout: default;
  }
}

@media (max-width: 520px) {
  .page-shell {
    width: min(100% - 16px, 1200px);
    padding: calc(18px + env(safe-area-inset-top)) 0
      calc(20px + env(safe-area-inset-bottom));
    position: relative;
    inset: auto;
    height: auto;
    min-height: calc(var(--app-height, 100dvh) - env(safe-area-inset-top) - env(safe-area-inset-bottom));
  }

  .topbar {
    padding: calc(18px + env(safe-area-inset-top)) 12px 8px;
  }

  .footer-meta {
    position: static;
    align-self: flex-end;
    margin-top: auto;
    margin-right: 1px;
    z-index: 5;
    max-width: calc(100dvw - 16px);
  }

  .footer-meta-panel p,
  .footer-meta > summary {
    font-size: 0.5rem;
    letter-spacing: 0.11em;
  }

  h1 {
    max-width: 11ch;
    font-size: clamp(2.05rem, 9.4vw, 3.3rem);
  }

  .lede {
    max-width: 24ch;
    font-size: 0.9rem;
  }

  .contact-modal {
    width: min(340px, calc(100dvw - 18px));
    max-width: calc(100dvw - 18px);
    max-height: calc(100svh - 10px);
  }

  .contact-modal-shell {
    padding: 10px;
    gap: 8px;
    min-width: 0;
  }

  .contact-modal-copy h2 {
    margin: 6px 0 0;
    font-size: clamp(1.1rem, 4.8vw, 1.45rem);
  }

  .contact-form {
    gap: 8px;
    min-width: 0;
  }

  .footer-meta-panel p {
    letter-spacing: 0.1em;
  }

  .contact-form input,
  .contact-form textarea {
    -webkit-user-select: text;
    user-select: text;
  }

  .contact-form input,
  .contact-form textarea {
    padding: 11px 12px;
    border-radius: 12px;
    max-width: 100%;
  }

  .submit-button {
    padding: 10px 14px;
  }
}

@media (max-width: 520px) and (orientation: portrait) {
  :root {
    --bg-spread-top: clamp(280px, 34vmax, 520px);
    --bg-spread-bottom: clamp(220px, 28vmax, 420px);
  }

  html {
    overflow: hidden;
    height: 100%;
    overscroll-behavior: none;
  }

  body {
    overflow: hidden;
    position: fixed;
    inset: 0;
    width: 100%;
    height: var(--app-height, 100dvh);
    touch-action: none;
    overscroll-behavior: none;
  }

  .page-shell {
    position: fixed;
    inset: 0;
    width: min(100% - 16px, 1200px);
    height: var(--app-height, 100dvh);
    min-height: var(--app-height, 100dvh);
    padding-top: calc(30px + env(safe-area-inset-top));
    padding-bottom: calc(14px + env(safe-area-inset-bottom));
    overflow: hidden;
  }

  .topbar {
    padding-top: calc(32px + env(safe-area-inset-top));
  }

  .hero {
    padding-top: clamp(56px, 14vh, 112px);
  }
}

@media (max-width: 820px) {
  :root {
    --bg-spread-x: clamp(180px, 24vmax, 360px);
    --bg-spread-top: clamp(240px, 30vmax, 460px);
    --bg-spread-bottom: clamp(130px, 18vmax, 240px);
  }
}

@media (hover: none) and (pointer: coarse) and (orientation: landscape) {
  html {
    overflow-x: clip;
    overflow-y: auto;
    height: auto;
    overscroll-behavior-y: auto;
  }

  body {
    overflow-x: clip;
    overflow-y: auto;
    position: relative;
    width: 100%;
    height: auto;
    -webkit-touch-callout: none;
    touch-action: pan-y;
    overscroll-behavior-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .page-shell {
    position: relative;
    inset: auto;
    width: min(100% - 20px, 1200px);
    min-height: auto;
    padding: calc(10px + env(safe-area-inset-top)) 0
      calc(14px + env(safe-area-inset-bottom));
    overflow: visible;
    gap: 12px;
  }

  .topbar {
    padding: calc(8px + env(safe-area-inset-top)) 14px 6px;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .brand-logo {
    width: clamp(100px, 18vw, 140px);
  }

  .hero {
    justify-content: flex-start;
    padding: 14px 18px 18px;
    min-height: 0;
    gap: 8px;
  }

  h1 {
    max-width: 11ch;
    font-size: clamp(2rem, 5vw, 3.25rem);
  }

  .lede {
    max-width: 34ch;
    font-size: 0.92rem;
  }

  .hero-contact {
    padding: 7px 11px;
    margin-top: 0;
  }

  .footer-meta {
    position: static;
    align-self: flex-end;
    margin-top: auto;
    margin-right: 2px;
  }
}

@media (hover: none) and (pointer: coarse) {
  body {
    -webkit-user-select: none;
    user-select: none;
  }

  .topbar,
  .hero,
  .footer-meta,
  .footer-meta-panel,
  .ghost-link,
  .hero-contact,
  .footer-meta > summary,
  .contact-modal-close,
  .submit-button,
  .brand-logo {
    -webkit-user-select: none;
    user-select: none;
  }

  .contact-form input,
  .contact-form textarea,
  .contact-form select,
  [contenteditable="true"] {
    -webkit-user-select: text;
    user-select: text;
  }
}

@keyframes footerReveal {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

  .button,
  .ghost-link {
    transition: none;
  }
}
