:root {
  color-scheme: light;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "Microsoft YaHei", sans-serif;
  --surface: #fbfcff;
  --surface-container-low: #ffffff;
  --surface-container: #f1f6fb;
  --surface-container-high: #eaf2f8;
  --on-surface: #171d27;
  --on-surface-variant: #566272;
  --outline: rgba(73, 85, 101, 0.18);
  --primary: #006d92;
  --on-primary: #ffffff;
  --primary-container: #c8e7ff;
  --on-primary-container: #002d3f;
  --secondary: #8d3e61;
  --secondary-container: #ffd8e6;
  --tertiary: #6550c8;
  --tertiary-container: #e8ddff;
  --trans-blue: #5bcffa;
  --trans-pink: #f5a9b8;
  --radius: 8px;
  --max: 1180px;
  --elevation-1: 0 1px 2px rgba(20, 28, 40, 0.08), 0 1px 3px rgba(20, 28, 40, 0.05);
  --elevation-2: 0 4px 12px rgba(20, 28, 40, 0.08);
  --elevation-3: 0 12px 30px rgba(20, 28, 40, 0.1);
  background: var(--surface);
  color: var(--on-surface);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: clip;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background:
    linear-gradient(135deg, rgba(91, 207, 250, 0.16), transparent 28rem),
    linear-gradient(225deg, rgba(245, 169, 184, 0.18), transparent 30rem),
    linear-gradient(180deg, #fbfcff 0%, #ffffff 48%, #f7fbff 100%);
  color: var(--on-surface);
}

body::selection {
  background: rgba(200, 231, 255, 0.9);
  color: var(--on-primary-container);
}

a {
  color: inherit;
}

img {
  max-width: 100%;
}

.progress {
  position: fixed;
  inset: 0 auto auto 0;
  z-index: 100;
  width: 0%;
  height: 3px;
  background: linear-gradient(90deg, var(--trans-blue), #fff, var(--trans-pink), var(--tertiary));
}

.ambient {
  position: fixed;
  inset: 0;
  z-index: -3;
  overflow: hidden;
  contain: paint;
  pointer-events: none;
}

.ambient::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(23, 29, 39, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 29, 39, 0.045) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), transparent 72%);
}

.ambient-ribbon {
  position: absolute;
  left: 0;
  right: 0;
  width: 100%;
  height: 34vh;
  min-height: 240px;
  opacity: 0.22;
  transform: skewY(-8deg);
  transform-origin: center;
}

.ribbon-one {
  top: -12vh;
  background:
    linear-gradient(
      95deg,
      var(--trans-blue) 0 20%,
      var(--trans-pink) 20% 38%,
      #fff 38% 52%,
      var(--trans-pink) 52% 70%,
      var(--trans-blue) 70% 100%
    );
}

.ribbon-two {
  bottom: -18vh;
  opacity: 0.14;
  background:
    linear-gradient(
      105deg,
      var(--trans-pink) 0 18%,
      #fff 18% 36%,
      var(--trans-blue) 36% 58%,
      var(--trans-pink) 58% 78%,
      #fff 78% 100%
    );
}

.topbar,
main,
.footer {
  width: min(var(--max), calc(100% - 48px));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 18px 0;
}

.topbar::before {
  content: "";
  position: absolute;
  inset: 8px -14px;
  z-index: -1;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: var(--radius);
  background: rgba(251, 252, 255, 0.94);
  box-shadow: var(--elevation-2);
  opacity: 0;
  transform: translateY(-8px);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

body.has-scrolled .topbar::before {
  opacity: 1;
  transform: translateY(0);
}

.brand,
.topnav,
.hero-actions,
.contact-actions {
  display: flex;
  align-items: center;
}

.brand {
  gap: 12px;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: var(--radius);
  background: var(--on-surface);
  color: #fff;
  font-size: 24px;
  font-weight: 950;
  line-height: 1;
  box-shadow: var(--elevation-2);
}

.brand-copy {
  display: grid;
  gap: 2px;
}

.brand strong {
  color: var(--on-surface);
  font-size: 16px;
  font-weight: 950;
}

.brand small {
  color: var(--on-surface-variant);
  font-size: 12px;
  font-weight: 800;
}

.topnav {
  gap: 4px;
  border: 1px solid var(--outline);
  border-radius: var(--radius);
  padding: 5px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--elevation-1);
}

.topnav a {
  border-radius: 6px;
  padding: 10px 13px;
  color: var(--on-surface-variant);
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
  text-decoration: none;
  transition:
    background 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

.topnav a:hover,
.topnav a.is-active {
  background: var(--primary-container);
  color: var(--on-primary-container);
}

.topnav a:hover {
  transform: translateY(-1px);
}

.toc {
  position: fixed;
  top: 118px;
  left: max(22px, calc((100vw - var(--max)) / 2 - 168px));
  z-index: 20;
  display: grid;
  gap: 7px;
  width: 140px;
}

.toc span {
  margin-bottom: 4px;
  color: var(--secondary);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.toc a {
  border-left: 2px solid rgba(23, 29, 39, 0.12);
  padding: 8px 0 8px 12px;
  color: rgba(23, 29, 39, 0.58);
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
  transition:
    border-color 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

.toc a:hover,
.toc a.is-active {
  border-color: var(--secondary);
  color: var(--on-surface);
  transform: translateX(2px);
}

main {
  display: grid;
  gap: 28px;
}

.section-panel {
  position: relative;
  scroll-margin-top: 96px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(360px, 0.82fr);
  gap: 52px;
  align-items: center;
  min-height: calc(100vh - 82px);
  padding: 58px 0 96px;
}

.label-line {
  margin: 0 0 15px;
  color: var(--secondary);
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
h4,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 24px;
  color: var(--on-surface);
  font-size: clamp(46px, 7vw, 88px);
  line-height: 0.98;
  font-weight: 950;
  letter-spacing: 0;
  text-wrap: balance;
}

.hero-lead {
  max-width: 720px;
  margin-bottom: 34px;
  color: #304056;
  font-size: clamp(18px, 1.9vw, 21px);
  line-height: 1.82;
}

.hero-actions,
.contact-actions {
  flex-wrap: wrap;
  gap: 14px;
}

.btn {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: var(--radius);
  padding: 0 20px;
  font-size: 15px;
  font-weight: 950;
  line-height: 1.1;
  text-decoration: none;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    background 160ms ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-icon {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.2);
  font-size: 13px;
}

.btn-primary {
  border: 1px solid rgba(0, 0, 0, 0.04);
  background: var(--primary);
  color: var(--on-primary);
  box-shadow: var(--elevation-2);
}

.btn-primary:hover {
  box-shadow: var(--elevation-3);
}

.btn-soft {
  border: 1px solid var(--outline);
  background: var(--surface-container-low);
  color: var(--on-surface);
  box-shadow: var(--elevation-1);
}

.btn-soft .btn-icon {
  background: var(--primary-container);
  color: var(--on-primary-container);
}

.flag-orbit {
  position: relative;
  min-height: 560px;
  display: grid;
  place-items: center;
  overflow: hidden;
  perspective: 1200px;
}

.flag-card {
  position: relative;
  z-index: 3;
  width: min(100%, 470px);
  border: 1px solid var(--outline);
  border-radius: var(--radius);
  padding: 16px;
  background: var(--surface-container-low);
  box-shadow: var(--elevation-3);
  transform: rotateY(-7deg) rotateX(4deg);
}

.flag-card::before {
  content: "";
  position: absolute;
  inset: 16px;
  z-index: 2;
  border-radius: var(--radius);
  background: linear-gradient(110deg, transparent 8%, rgba(255, 255, 255, 0.52) 45%, transparent 62%);
  mix-blend-mode: screen;
  opacity: 0.58;
  pointer-events: none;
}

.flag-card img {
  display: block;
  width: 100%;
  border-radius: var(--radius);
  box-shadow: inset 0 0 0 1px rgba(23, 29, 39, 0.08);
}

.flag-reflection {
  position: absolute;
  inset: auto 18% -42px;
  height: 56px;
  border-radius: 50%;
  background: rgba(0, 109, 146, 0.08);
}

.orbit-ring {
  position: absolute;
  z-index: 1;
  border: 1px solid rgba(23, 29, 39, 0.08);
  border-radius: 50%;
  transform: rotateX(64deg) rotateZ(-12deg);
}

.ring-a {
  width: 540px;
  height: 540px;
}

.ring-b {
  width: 390px;
  height: 390px;
  border-color: rgba(141, 62, 97, 0.16);
}

.orbit-note {
  position: absolute;
  z-index: 4;
  display: grid;
  gap: 4px;
  min-width: 142px;
  border: 1px solid var(--outline);
  border-radius: var(--radius);
  padding: 14px 16px;
  background: var(--surface-container-low);
  box-shadow: var(--elevation-2);
}

.orbit-note span {
  color: var(--on-surface-variant);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.orbit-note strong {
  color: var(--on-surface);
  font-size: 21px;
  font-weight: 950;
}

.note-a {
  top: 74px;
  right: 4px;
}

.note-b {
  bottom: 76px;
  left: 2px;
}

.hero-marquee {
  position: absolute;
  left: 0;
  bottom: 20px;
  width: 100%;
  overflow: hidden;
  color: rgba(23, 29, 39, 0.42);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
  pointer-events: none;
}

.hero-marquee div {
  display: flex;
  width: 100%;
  flex-wrap: wrap;
  justify-content: center;
  gap: 28px;
}

.hero-marquee span {
  display: inline-flex;
  align-items: center;
  gap: 28px;
}

.hero-marquee span::after {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--trans-pink);
}

.profile,
.grok,
.social,
.contact {
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: var(--radius);
  padding: clamp(24px, 4vw, 46px);
  background: var(--surface-container-low);
  box-shadow: var(--elevation-2);
}

.section-heading {
  max-width: 810px;
  margin-bottom: 26px;
}

.section-heading.grok-heading {
  max-width: 980px;
}

h2 {
  margin-bottom: 14px;
  color: var(--on-surface);
  font-size: clamp(32px, 4.4vw, 54px);
  line-height: 1.05;
  font-weight: 950;
  letter-spacing: 0;
  text-wrap: balance;
}

.section-heading p:not(.label-line),
.contact-copy p {
  color: var(--on-surface-variant);
  font-size: 17px;
  line-height: 1.76;
}

.profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
  gap: 18px;
}

.intro-card,
.facts article,
.safety-callout,
.report,
.link-card {
  border: 1px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-container-low);
}

.intro-card {
  position: relative;
  overflow: hidden;
  padding: 32px;
}

.intro-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 6px;
  background: linear-gradient(90deg, var(--trans-blue), var(--trans-pink), #fff, var(--trans-pink), var(--trans-blue));
}

.intro-card h3 {
  margin-bottom: 18px;
  color: var(--on-surface);
  font-size: 28px;
  font-weight: 950;
}

.intro-card p {
  color: #2f3d55;
  font-size: 20px;
  line-height: 1.85;
}

.intro-card .love-line {
  margin-bottom: 0;
  color: var(--secondary);
  font-weight: 950;
}

.facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.facts article {
  min-height: 162px;
  display: grid;
  align-content: space-between;
  padding: 22px;
  background: var(--surface-container);
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    border-color 160ms ease;
}

.facts article:hover {
  border-color: rgba(0, 109, 146, 0.36);
  box-shadow: var(--elevation-2);
  transform: translateY(-2px);
}

.facts span {
  width: max-content;
  border-radius: 6px;
  padding: 7px 9px;
  background: var(--primary-container);
  color: var(--on-primary-container);
  font-size: 12px;
  font-weight: 950;
}

.facts strong {
  display: block;
  color: var(--on-surface);
  font-size: 28px;
  font-weight: 950;
}

.facts p {
  margin-bottom: 0;
  color: var(--on-surface-variant);
  line-height: 1.55;
}

.grok {
  overflow: hidden;
}

.safety-callout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 20px;
  align-items: center;
  margin-bottom: 18px;
  padding: 22px 24px;
  background: linear-gradient(95deg, rgba(255, 216, 230, 0.66), rgba(200, 231, 255, 0.5));
}

.safety-callout span {
  display: block;
  margin-bottom: 8px;
  color: var(--secondary);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.safety-callout strong {
  color: var(--on-surface);
  font-size: 22px;
  font-weight: 950;
}

.safety-callout p {
  margin: 0;
  color: #4f5d73;
  line-height: 1.78;
}

.report {
  position: relative;
  max-height: 820px;
  overflow: auto;
  padding: clamp(24px, 3.4vw, 42px);
  background: linear-gradient(180deg, #fff, var(--surface-container-low));
  scroll-padding: 24px;
}

.report::before {
  content: "";
  position: sticky;
  top: -42px;
  z-index: 2;
  display: block;
  height: 8px;
  margin: -42px -42px 28px;
  background: linear-gradient(90deg, var(--trans-blue), var(--trans-pink), #fff, var(--trans-pink), var(--trans-blue));
}

.report::-webkit-scrollbar {
  width: 10px;
}

.report::-webkit-scrollbar-track {
  background: rgba(23, 29, 39, 0.06);
}

.report::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: var(--primary-container);
}

.report-title {
  margin-bottom: 22px;
}

.report-title span {
  display: inline-block;
  margin-bottom: 10px;
  border-radius: 6px;
  padding: 7px 10px;
  background: var(--secondary-container);
  color: var(--secondary);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.report h3 {
  margin-bottom: 0;
  color: var(--on-surface);
  font-size: clamp(24px, 2.7vw, 34px);
  line-height: 1.22;
  font-weight: 950;
  text-wrap: balance;
}

.report h4 {
  margin: 36px 0 12px;
  color: var(--on-surface);
  font-size: 21px;
  font-weight: 950;
}

.report p {
  margin-bottom: 14px;
  color: #435068;
  font-size: 16.5px;
  line-height: 1.86;
}

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

.link-card {
  position: relative;
  min-height: 230px;
  display: grid;
  align-content: space-between;
  overflow: hidden;
  padding: 26px;
  background: var(--surface-container);
  text-decoration: none;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    border-color 160ms ease;
}

.link-card::before {
  content: "";
  position: absolute;
  inset: auto -16% -42% -16%;
  height: 120px;
  background: linear-gradient(90deg, rgba(91, 207, 250, 0.32), rgba(245, 169, 184, 0.36));
  transform: rotate(-5deg);
  transition: transform 180ms ease;
}

.link-card:hover {
  border-color: rgba(141, 62, 97, 0.28);
  box-shadow: var(--elevation-2);
  transform: translateY(-3px);
}

.link-card:hover::before {
  transform: rotate(-2deg) translateY(-16px);
}

.link-icon {
  position: relative;
  z-index: 1;
  display: grid;
  width: 48px;
  height: 40px;
  place-items: center;
  border-radius: 6px;
  background: var(--primary-container);
  color: var(--on-primary-container);
  font-size: 13px;
  font-weight: 950;
}

.link-card strong {
  position: relative;
  z-index: 1;
  display: block;
  margin-top: 40px;
  color: var(--on-surface);
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.15;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.link-card p {
  position: relative;
  z-index: 1;
  margin-bottom: 0;
  color: var(--on-surface-variant);
  line-height: 1.6;
}

.contact {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 510px);
  gap: 30px;
  align-items: center;
}

.contact h2 {
  margin-bottom: 14px;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 34px 0 58px;
  color: var(--on-surface-variant);
  font-size: 13px;
  font-weight: 900;
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 420ms ease,
    transform 420ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

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

@media (max-width: 1460px) {
  .toc {
    display: none;
  }
}

@media (max-width: 1040px) {
  .hero,
  .profile-grid,
  .contact {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 46px;
  }

  .flag-orbit {
    min-height: 460px;
    max-width: 620px;
  }

  .note-a {
    right: 26px;
  }

  .note-b {
    left: 20px;
  }
}

@media (max-width: 760px) {
  .topbar,
  main,
  .footer {
    width: min(100% - 28px, 620px);
  }

  .topbar {
    align-items: flex-start;
    flex-direction: column;
    padding: 14px 0;
  }

  .topbar::before {
    inset: 6px -8px;
  }

  .topnav {
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .topnav::-webkit-scrollbar {
    display: none;
  }

  .topnav a {
    flex: 0 0 auto;
  }

  .hero {
    gap: 26px;
    padding: 34px 0 64px;
  }

  .flag-orbit {
    min-height: 390px;
  }

  .flag-card {
    width: min(100%, 390px);
    transform: none;
  }

  .ring-a {
    width: 420px;
    height: 420px;
  }

  .ring-b {
    width: 310px;
    height: 310px;
  }

  .orbit-note {
    min-width: 126px;
    padding: 12px 14px;
  }

  .orbit-note strong {
    font-size: 18px;
  }

  .note-a {
    top: 30px;
    right: 0;
  }

  .note-b {
    bottom: 36px;
    left: 0;
  }

  .profile,
  .grok,
  .social,
  .contact {
    padding: 24px;
  }

  .facts,
  .link-grid,
  .safety-callout {
    grid-template-columns: 1fr;
  }

  .report {
    max-height: none;
  }

  .hero-marquee {
    display: none;
  }

  .footer {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 470px) {
  .brand-mark {
    width: 40px;
    height: 40px;
  }

  .hero-lead,
  .section-heading p:not(.label-line),
  .contact-copy p {
    font-size: 16px;
  }

  .hero-actions,
  .contact-actions,
  .btn {
    width: 100%;
  }

  .flag-orbit {
    min-height: 330px;
  }

  .orbit-note {
    display: none;
  }

  .orbit-ring {
    display: none;
  }

  .ring-a {
    width: 330px;
    height: 330px;
  }

  .ring-b {
    width: 250px;
    height: 250px;
  }

  .intro-card,
  .report {
    padding: 22px;
  }

  .intro-card p {
    font-size: 17px;
  }

  .facts article,
  .link-card {
    min-height: auto;
  }

  .report p {
    font-size: 15.5px;
  }
}
