:root {
  color-scheme: dark;
  --page: #17191a;
  --stage: #070909;
  --stage-soft: #0b0e0f;
  --line: rgba(255, 255, 255, 0.16);
  --line-strong: rgba(255, 255, 255, 0.24);
  --text: #f6f1e7;
  --muted: rgba(246, 241, 231, 0.7);
  --ink: #0b0b0a;
  --radius-stage: 34px;
  --radius-card: 18px;
  --shadow-card: 0 18px 52px rgba(0, 0, 0, 0.2);
  --page-pad: clamp(22px, 5.2vw, 84px);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  background: var(--stage);
  color: var(--text);
}

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

.page-shell {
  min-height: 100svh;
  display: block;
}

.stage {
  width: 100%;
  min-height: 100svh;
  border: 0;
  border-radius: 0;
  overflow: hidden;
  background: var(--stage);
  box-shadow: none;
}

.site-header,
.site-footer {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 24px;
  padding-inline: var(--page-pad);
}

.hero {
  max-width: 1680px;
  margin-inline: auto;
}

.site-header {
  min-height: 66px;
}

.brand {
  justify-self: start;
  font-size: clamp(22px, 2vw, 30px);
  font-weight: 760;
  letter-spacing: 0;
}

.contact-link,
.primary-cta,
.card-button,
.card-arrow {
  transition:
    transform 180ms ease,
    opacity 180ms ease,
    background-color 180ms ease;
}

.site-footer a:hover {
  opacity: 0.72;
}

.contact-link {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 8px 7px 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: white;
  font-size: 15px;
  font-weight: 700;
}

.contact-link:hover,
.primary-cta:hover,
.card-button:hover,
.card-arrow:hover {
  transform: translateY(-2px);
}

.round-icon {
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: var(--text);
  color: var(--ink);
  font-weight: 900;
  line-height: 1;
}

.round-icon.dark {
  background: var(--ink);
  color: var(--text);
}

.hero {
  padding: clamp(14px, 3vw, 38px) 24px 8px;
  text-align: center;
}

.hero h1 {
  margin: 0;
  font-size: clamp(60px, 7.1vw, 102px);
  line-height: 0.92;
  letter-spacing: -0.045em;
  font-weight: 830;
  text-wrap: balance;
}

.hero-title {
  margin: clamp(14px, 1.7vw, 22px) 0 0;
  font-family:
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Inter, sans-serif;
  font-size: clamp(31px, 3.9vw, 55px);
  line-height: 1.04;
  font-weight: 820;
  letter-spacing: 0.12em;
}

.hero-subtitle {
  margin: 16px 0 0;
  color: var(--muted);
  font-family:
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Inter, sans-serif;
  font-size: clamp(16px, 1.5vw, 21px);
  letter-spacing: 0.18em;
}

.primary-cta {
  margin-top: 20px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 8px 24px 8px 8px;
  border-radius: 999px;
  background: var(--text);
  color: var(--ink);
  font-weight: 760;
  box-shadow: 0 12px 28px rgba(255, 255, 255, 0.06);
}

.noscript-fallback {
  min-height: 100svh;
}

.noscript-content {
  max-width: 860px;
  margin: 0 auto;
  padding: 24px var(--page-pad) clamp(42px, 4.8vw, 68px);
  color: var(--muted);
  font-size: clamp(16px, 1.45vw, 20px);
  line-height: 1.75;
}

.noscript-content p {
  margin: 0 0 16px;
}

.noscript-content ul {
  margin: 0;
  padding-left: 1.25em;
}

.noscript-content li + li {
  margin-top: 10px;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: end;
  gap: 16px;
  padding: 18px var(--page-pad) clamp(42px, 4.8vw, 68px);
}

.portal-card {
  min-height: 460px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid rgba(0, 0, 0, 0.16);
  border-radius: var(--radius-card);
  background: var(--card-color, #f2a177);
  color: var(--ink);
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow-card);
}

.portal-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.18), transparent 44%);
  opacity: 0.38;
  pointer-events: none;
}

.portal-card > * {
  position: relative;
  z-index: 1;
}

.portal-card.tall {
  min-height: 460px;
}

.card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 34px;
}

.chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 50px;
  height: 31px;
  padding-inline: 12px;
  border: 1.5px solid rgba(0, 0, 0, 0.58);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 780;
  background: rgba(255, 255, 255, 0.13);
}

.chip.ghost {
  min-width: auto;
}

.card-arrow {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border: 1.5px solid rgba(0, 0, 0, 0.7);
  border-radius: 50%;
  font-size: 21px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.08);
}

.doodle {
  height: 126px;
  display: grid;
  place-items: center;
  margin: 8px 0 14px;
}

.doodle svg {
  width: min(100%, 230px);
  height: 100%;
  fill: none;
  stroke: #050505;
  stroke-width: 4.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.app-mark {
  height: 126px;
  display: grid;
  place-items: center;
  margin: 8px 0 14px;
}

.app-mark img {
  width: 112px;
  height: 112px;
  border-radius: 26px;
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.18);
}

.card-copy {
  margin-top: auto;
  display: grid;
  grid-template-rows: 18px minmax(34px, auto) minmax(64px, auto);
  align-content: end;
}

.card-kicker {
  min-height: 18px;
  margin: 0;
  display: flex;
  align-items: end;
  font-size: 11px;
  font-weight: 780;
  line-height: 1.1;
}

.card-copy h2 {
  min-height: 34px;
  margin: 8px 0 0;
  font-size: clamp(23px, 2vw, 28px);
  line-height: 1.08;
  letter-spacing: -0.025em;
}

.card-copy p:not(.card-kicker) {
  max-width: 25ch;
  min-height: 64px;
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.45;
  font-weight: 520;
}

.card-button {
  width: fit-content;
  min-width: 136px;
  height: 42px;
  margin-top: 26px;
  padding: 0 14px 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-radius: 999px;
  background: #080909;
  color: white;
  font-size: 14px;
  font-weight: 760;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.2);
}

.site-footer {
  min-height: 58px;
  margin-top: 0;
  color: rgba(255, 255, 255, 0.56);
  font-size: 15px;
  position: relative;
}

.site-footer::before {
  content: none;
}

.site-footer > :first-child {
  justify-self: start;
}

.site-footer > :last-child {
  justify-self: end;
}

@media (max-width: 1180px) {
  .project-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
  }

  .portal-card,
  .portal-card.tall {
    min-height: 440px;
  }

}

@media (max-width: 760px) {
  .page-shell {
    padding: 0;
  }

  .stage {
    min-height: 100svh;
  }

  .site-header {
    grid-template-columns: 1fr auto;
    min-height: auto;
    padding: 16px 18px;
  }

  .contact-link {
    padding-left: 14px;
    font-size: 0;
  }

  .hero {
    padding: 42px 18px 12px;
  }

  .hero h1 {
    font-size: clamp(56px, 18vw, 82px);
    letter-spacing: -0.06em;
  }

  .hero-title {
    font-size: clamp(32px, 9vw, 48px);
    letter-spacing: 0.08em;
  }

  .hero-subtitle {
    font-size: 17px;
    letter-spacing: 0.08em;
  }

  .project-grid {
    grid-template-columns: 1fr;
    padding: 22px 18px 18px;
  }

  .portal-card,
  .portal-card.tall {
    min-height: 424px;
    padding: 22px;
  }

  .doodle {
    height: 128px;
  }

  .app-mark {
    height: 128px;
  }

  .app-mark img {
    width: 104px;
    height: 104px;
    border-radius: 24px;
  }

  .site-footer {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 12px;
    padding: 20px;
    text-align: center;
  }

  .site-footer > :first-child,
  .site-footer > :last-child {
    justify-self: center;
  }

}

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