:root {
  --bg: #0b1020;
  --bg-soft: #121a2f;
  --panel: rgba(18, 26, 47, 0.68);
  --panel-strong: rgba(24, 34, 62, 0.78);
  --line: rgba(248, 250, 252, 0.14);
  --text: #f8fafc;
  --muted: #b7c2db;
  --muted-soft: #8290b4;
  --blue: #6c8cff;
  --violet: #a78bfa;
  --cyan: #61dafb;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
  color-scheme: dark;
}

body.light-theme {
  --bg: #f5f7ff;
  --bg-soft: #e9eefc;
  --panel: rgba(255, 255, 255, 0.72);
  --panel-strong: rgba(255, 255, 255, 0.88);
  --line: rgba(28, 43, 78, 0.16);
  --text: #101827;
  --muted: #53627e;
  --muted-soft: #6f7d98;
  --shadow: 0 22px 70px rgba(67, 83, 128, 0.2);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100%;
  margin: 0;
  font-family: Inter, "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 18% 18%, rgba(108, 140, 255, 0.26), transparent 28rem),
    radial-gradient(circle at 82% 12%, rgba(167, 139, 250, 0.2), transparent 24rem),
    linear-gradient(180deg, #070b16 0%, var(--bg) 48%, #080d1a 100%);
  overflow-x: hidden;
}

body.light-theme {
  background:
    radial-gradient(circle at 18% 18%, rgba(108, 140, 255, 0.18), transparent 28rem),
    radial-gradient(circle at 82% 12%, rgba(167, 139, 250, 0.16), transparent 24rem),
    linear-gradient(180deg, #f9fbff 0%, var(--bg) 50%, #eef3ff 100%);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -3;
  content: "";
  background:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: linear-gradient(to bottom, transparent 0%, #000 18%, #000 76%, transparent 100%);
}

body.light-theme::before {
  background:
    linear-gradient(rgba(38, 55, 95, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(38, 55, 95, 0.05) 1px, transparent 1px);
}

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

#starfield {
  position: fixed;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  background: transparent;
}

body.light-theme #starfield {
  opacity: 0.38;
}

#click-effects {
  position: fixed;
  inset: 0;
  z-index: 999;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.firefly-field {
  position: fixed;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
  mix-blend-mode: screen;
}

.firefly {
  position: absolute;
  top: var(--firefly-top);
  left: var(--firefly-left);
  width: var(--firefly-size);
  height: var(--firefly-size);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 248, 188, 0.95) 0%, rgba(166, 232, 159, 0.58) 36%, transparent 72%);
  box-shadow:
    0 0 12px rgba(255, 241, 163, 0.5),
    0 0 26px rgba(125, 222, 146, 0.28);
  opacity: 0;
  animation:
    fireflyDrift var(--firefly-duration) ease-in-out infinite alternate,
    fireflyGlow var(--firefly-pulse) ease-in-out infinite;
  animation-delay: var(--firefly-delay);
}

.home-page .firefly-field {
  z-index: 1;
  opacity: 0.44;
}

body:not(.home-page) .firefly-field {
  opacity: 0.72;
}

.page-shell {
  width: min(1160px, calc(100% - 40px));
  min-height: 100vh;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.site-header {
  position: sticky;
  top: 16px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 16px 0 0;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 26, 0.68);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(18px);
}

body.light-theme .site-header {
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 16px 48px rgba(67, 83, 128, 0.16);
}

.home-page .site-header {
  position: sticky;
  left: auto;
  width: auto;
  margin-top: 16px;
  transform: none;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: max-content;
  padding: 6px 8px 6px 0;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  position: relative;
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
}

.brand-mark::before {
  position: relative;
  z-index: 1;
  width: 30px;
  height: 30px;
  content: "";
  background: linear-gradient(135deg, #61dafb 0%, #6c8cff 54%, #a78bfa 100%);
  clip-path: polygon(
    50% 0%,
    60% 35%,
    94% 50%,
    60% 65%,
    50% 100%,
    40% 65%,
    6% 50%,
    40% 35%
  );
  filter: drop-shadow(0 0 12px rgba(97, 218, 251, 0.72));
}

.brand-mark::after {
  position: absolute;
  width: 54px;
  height: 54px;
  content: "";
  border-radius: 50%;
  background: radial-gradient(circle, rgba(97, 218, 251, 0.24), transparent 62%);
  transform: translate(-1px, 1px);
}

.site-nav {
  display: flex;
  flex: 1;
  flex-wrap: nowrap;
  justify-content: center;
  gap: clamp(18px, 3.6vw, 52px);
  overflow-x: auto;
  scrollbar-width: none;
}

.site-nav::-webkit-scrollbar {
  display: none;
}

.site-nav a {
  position: relative;
  flex: 0 0 auto;
  padding: 12px 2px;
  color: #e4ebff;
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
  transition:
    color 180ms ease,
    text-shadow 180ms ease;
}

body.light-theme .site-nav a {
  color: #263653;
}

.site-nav a::after {
  position: absolute;
  right: 0;
  bottom: 2px;
  left: 0;
  height: 3px;
  content: "";
  border-radius: 999px;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
  opacity: 0;
  transform: scaleX(0.42);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--text);
  text-shadow: 0 0 18px rgba(108, 140, 255, 0.36);
}

body.light-theme .site-nav a:hover,
body.light-theme .site-nav a[aria-current="page"] {
  color: #111827;
}

.theme-toggle {
  position: relative;
  flex: 0 0 auto;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid rgba(248, 250, 252, 0.16);
  border-radius: 50%;
  color: #e7ecff;
  background: rgba(248, 250, 252, 0.07);
  box-shadow: inset 0 0 24px rgba(108, 140, 255, 0.08);
  cursor: pointer;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    box-shadow 180ms ease;
}

.theme-toggle:hover {
  transform: translateY(-2px);
  border-color: rgba(108, 140, 255, 0.42);
  background: rgba(108, 140, 255, 0.12);
  box-shadow: 0 14px 34px rgba(108, 140, 255, 0.2);
}

.theme-toggle-sun,
.theme-toggle-moon {
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.theme-toggle-sun {
  opacity: 0;
  background: #facc15;
  box-shadow:
    0 -10px 0 -7px #facc15,
    0 10px 0 -7px #facc15,
    10px 0 0 -7px #facc15,
    -10px 0 0 -7px #facc15,
    7px 7px 0 -7px #facc15,
    -7px -7px 0 -7px #facc15,
    7px -7px 0 -7px #facc15,
    -7px 7px 0 -7px #facc15;
  transform: scale(0.72) rotate(-24deg);
}

.theme-toggle-moon {
  opacity: 1;
  background: #e7ecff;
  box-shadow:
    inset -6px -2px 0 #0b1020,
    0 0 16px rgba(231, 236, 255, 0.34);
  transform: scale(1) rotate(0deg);
}

body.light-theme .theme-toggle {
  border-color: rgba(38, 55, 95, 0.14);
  color: #172033;
  background: rgba(255, 255, 255, 0.72);
}

body.light-theme .theme-toggle-sun {
  opacity: 1;
  transform: scale(1) rotate(0deg);
}

body.light-theme .theme-toggle-moon {
  opacity: 0;
  transform: scale(0.72) rotate(24deg);
}

.site-nav a:hover::after,
.site-nav a[aria-current="page"]::after {
  opacity: 1;
  transform: scaleX(1);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.72fr);
  align-items: center;
  gap: clamp(28px, 6vw, 72px);
  min-height: calc(100vh - 96px);
  padding: clamp(70px, 10vw, 128px) 0 76px;
}

.hero-wallpaper {
  position: relative;
  width: 100vw;
  min-height: clamp(240px, 32vw, 430px);
  margin-left: calc(50% - 50vw);
  margin-top: 18px;
  padding: 0;
  background:
    linear-gradient(180deg, rgba(2, 6, 16, 0.06) 0%, rgba(2, 6, 16, 0.04) 48%, rgba(11, 16, 32, 0.62) 100%),
    url("earth-dawn-panorama.png") center 62% / cover no-repeat;
  border-bottom: 1px solid rgba(248, 250, 252, 0.12);
  box-shadow:
    inset 0 -52px 92px rgba(11, 16, 32, 0.76),
    0 28px 90px rgba(0, 0, 0, 0.32);
  overflow: hidden;
}

.hero-wallpaper::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 34%;
  content: "";
  pointer-events: none;
  background: linear-gradient(180deg, transparent, var(--bg));
}

.intro-hero {
  grid-template-columns: minmax(0, 760px);
  justify-content: center;
  min-height: auto;
  padding: clamp(48px, 7vw, 86px) 0 40px;
  text-align: center;
}

.intro-hero .hero-copy {
  margin-right: auto;
  margin-left: auto;
}

.intro-hero .hero-actions {
  justify-content: center;
}

.hero-content {
  max-width: 730px;
}

.eyebrow,
.feature-kicker {
  margin: 0 0 12px;
  color: var(--cyan);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

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

h1 {
  margin-bottom: 18px;
  font-size: clamp(48px, 8vw, 92px);
  line-height: 1.02;
  letter-spacing: 0;
}

.subtitle {
  margin-bottom: 22px;
  font-size: clamp(20px, 3vw, 32px);
  font-weight: 700;
  color: #dfe6ff;
}

.hero-copy,
.page-hero p,
.feature-card p,
.project-card p,
.knowledge-card p {
  color: var(--muted);
  line-height: 1.8;
}

.hero-copy {
  max-width: 620px;
  margin-bottom: 32px;
  font-size: 17px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button,
.card-link,
.backup-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 8px;
  font-weight: 800;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    box-shadow 180ms ease;
}

.button-primary,
.card-link {
  color: #061022;
  background: linear-gradient(135deg, #dbe5ff, #b9c6ff 46%, #d9ccff);
  box-shadow: 0 18px 46px rgba(108, 140, 255, 0.28);
}

.button-ghost {
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(248, 250, 252, 0.07);
}

body.light-theme .button-ghost,
body.light-theme .backup-link,
body.light-theme .link-list a {
  color: #172033;
  background: rgba(255, 255, 255, 0.66);
}

.project-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.backup-link {
  border: 1px solid rgba(248, 250, 252, 0.14);
  color: #e7ecff;
  background: rgba(248, 250, 252, 0.07);
}

.button:hover,
.card-link:hover,
.backup-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 56px rgba(108, 140, 255, 0.34);
}

.orbit-panel {
  position: relative;
  aspect-ratio: 1;
  min-height: 330px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 50%, rgba(97, 218, 251, 0.16), transparent 28%),
    rgba(18, 26, 47, 0.34);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
  overflow: hidden;
}

.orbit-panel::before,
.orbit-panel::after {
  position: absolute;
  inset: 13%;
  content: "";
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 50%;
}

.orbit-panel::after {
  inset: 27%;
  border-color: rgba(108, 140, 255, 0.22);
}

.orbit-core {
  position: absolute;
  inset: 50% auto auto 50%;
  display: grid;
  width: 116px;
  height: 116px;
  place-items: center;
  border: 1px solid rgba(248, 250, 252, 0.2);
  border-radius: 50%;
  background: rgba(11, 16, 32, 0.76);
  box-shadow:
    inset 0 0 42px rgba(108, 140, 255, 0.22),
    0 20px 60px rgba(0, 0, 0, 0.34);
  transform: translate(-50%, -50%);
}

.orbit-core span {
  align-self: end;
  color: var(--muted-soft);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.orbit-core strong {
  align-self: start;
  font-size: 46px;
}

.orbit-dot {
  position: absolute;
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid rgba(248, 250, 252, 0.16);
  border-radius: 50%;
  background: rgba(248, 250, 252, 0.09);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.28);
  font-weight: 900;
}

.orbit-dot-a {
  top: 15%;
  left: 50%;
  transform: translateX(-50%);
}

.orbit-dot-b {
  top: 50%;
  right: 13%;
  transform: translateY(-50%);
}

.orbit-dot-c {
  bottom: 15%;
  left: 50%;
  transform: translateX(-50%);
}

.orbit-dot-d {
  top: 50%;
  left: 13%;
  transform: translateY(-50%);
}

.section-block {
  padding: 54px 0;
}

.section-heading {
  margin-bottom: 24px;
}

.section-heading h2,
.page-hero h1 {
  margin-bottom: 12px;
}

.project-grid,
.knowledge-grid,
.practice-grid,
.split-section {
  display: grid;
  gap: 18px;
}

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

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

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

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

.recent-card {
  display: block;
  min-height: 180px;
  padding: 24px;
  text-decoration: none;
}

.recent-date {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(103, 232, 249, 0.24);
  border-radius: 999px;
  color: var(--cyan);
  background: rgba(103, 232, 249, 0.08);
  font-size: 13px;
  font-weight: 900;
}

.recent-card h3 {
  margin: 16px 0 10px;
  color: var(--text);
  font-size: clamp(22px, 2.2vw, 30px);
}

.recent-card p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.8;
}

.knowledge-section + .knowledge-section {
  margin-top: 34px;
}

.knowledge-section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.knowledge-section-heading h2 {
  margin: 0;
  color: var(--text);
  font-size: clamp(28px, 4vw, 44px);
}

.knowledge-section-heading span {
  color: var(--muted);
  font-weight: 800;
}

.knowledge-card {
  position: relative;
}

.knowledge-card.is-locked {
  border-color: rgba(167, 139, 250, 0.22);
}

.knowledge-card.is-locked .card-icon {
  box-shadow:
    0 14px 34px rgba(167, 139, 250, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.access-badge {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
}

.access-public {
  color: #082016;
  background: linear-gradient(135deg, #dffbe8, #a8f3ce);
}

.access-private {
  color: #1e1738;
  background: linear-gradient(135deg, #e1e8ff, #dccdff);
}

.knowledge-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.knowledge-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(248, 250, 252, 0.06);
  font-size: 13px;
  font-weight: 900;
}

.knowledge-card:not(.is-locked) .knowledge-tags span {
  border-color: rgba(103, 232, 249, 0.22);
  color: #dff8ff;
  background: rgba(103, 232, 249, 0.08);
}

.knowledge-card.is-locked .knowledge-tags span {
  border-color: rgba(167, 139, 250, 0.24);
  color: #e8ddff;
  background: rgba(167, 139, 250, 0.08);
}

.about-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 0.8fr);
  align-items: start;
  gap: clamp(24px, 5vw, 56px);
}

.about-intro {
  padding-top: clamp(14px, 4vw, 46px);
}

.about-intro h1 {
  margin-bottom: 18px;
  font-size: clamp(42px, 6vw, 76px);
}

.about-intro p {
  max-width: 620px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.85;
}

.about-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.about-tags span {
  padding: 9px 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #e7ecff;
  font-size: 14px;
  font-weight: 800;
  background: rgba(248, 250, 252, 0.08);
  backdrop-filter: blur(14px);
}

.code-card {
  overflow: hidden;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  background: rgba(18, 21, 39, 0.82);
  box-shadow:
    0 24px 70px rgba(0, 0, 0, 0.36),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(18px);
}

.code-titlebar {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 52px;
  padding: 0 18px;
  background: rgba(16, 18, 34, 0.9);
}

.code-titlebar .traffic-close,
.code-titlebar .traffic-minimize,
.code-titlebar .traffic-zoom {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
}

.code-filename {
  margin-left: 14px;
  color: rgba(231, 236, 255, 0.68);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 15px;
}

.code-screen {
  min-height: 320px;
  margin: 0;
  padding: 28px 30px 34px;
  color: #e7ecff;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 15px;
  line-height: 1.85;
  white-space: pre-wrap;
}

.code-cursor {
  display: inline-block;
  width: 10px;
  height: 20px;
  margin-left: 3px;
  border-radius: 3px;
  background: #61dafb;
  vertical-align: -4px;
  animation: cursorBlink 900ms steps(2, start) infinite;
}

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

.contact-card {
  display: grid;
  border: 1px solid var(--line);
  min-height: 150px;
  padding: 22px;
  align-content: space-between;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.contact-card strong {
  color: var(--text);
  font-size: 20px;
}

.contact-card small {
  overflow-wrap: anywhere;
  color: var(--muted);
  line-height: 1.5;
}

.contact-icon {
  --icon-bg: #dbe5ff;
  --icon-fg: #061022;
  display: inline-grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--icon-fg);
  background: var(--icon-bg);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
}

.contact-icon::before {
  width: 25px;
  height: 25px;
  content: "";
  background: currentColor;
}

.social-github {
  --icon-bg: #f8fafc;
  --icon-fg: #111827;
}

.social-github::before {
  border-radius: 50% 50% 45% 45%;
  clip-path: path("M12.5 1.8C6.6 1.8 1.8 6.6 1.8 12.6c0 4.8 3.1 8.9 7.4 10.3.5.1.7-.2.7-.5v-2c-3 .7-3.6-1.3-3.6-1.3-.5-1.2-1.2-1.5-1.2-1.5-1-.7.1-.7.1-.7 1.1.1 1.7 1.2 1.7 1.2 1 .1.7 2.6 3.1 1.8.1-.7.4-1.2.7-1.5-2.4-.3-5-1.2-5-5.4 0-1.2.4-2.2 1.1-3-.1-.3-.5-1.5.1-3 0 0 .9-.3 3 1.1.9-.2 1.8-.4 2.7-.4s1.8.1 2.7.4c2.1-1.4 3-1.1 3-1.1.6 1.5.2 2.7.1 3 .7.8 1.1 1.8 1.1 3 0 4.2-2.6 5.1-5 5.4.4.4.8 1 .8 2.1v3c0 .3.2.6.8.5 4.3-1.4 7.4-5.5 7.4-10.3C23.2 6.6 18.4 1.8 12.5 1.8Z");
}

.social-qq {
  --icon-bg: #eff6ff;
  --icon-fg: #111827;
}

.social-qq::before {
  width: 28px;
  height: 28px;
  border-radius: 50% 50% 44% 44%;
  clip-path: polygon(50% 0, 68% 9%, 78% 29%, 76% 54%, 91% 76%, 70% 71%, 58% 91%, 42% 91%, 30% 71%, 9% 76%, 24% 54%, 22% 29%, 32% 9%);
}

.social-weibo {
  --icon-bg: #fff1f2;
  --icon-fg: #e6162d;
}

.social-weibo::before {
  width: 29px;
  height: 22px;
  border-radius: 48% 54% 44% 46%;
  transform: rotate(-12deg);
  clip-path: ellipse(48% 39% at 50% 58%);
  box-shadow:
    9px -10px 0 -7px #f59e0b,
    12px -13px 0 -9px #e6162d;
}

.social-xiaohongshu {
  --icon-bg: #ff2442;
  --icon-fg: #fff;
}

.social-xiaohongshu::before {
  width: 26px;
  height: 22px;
  border-radius: 5px;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
  background:
    linear-gradient(currentColor 0 0) 5px 5px / 16px 3px no-repeat,
    linear-gradient(currentColor 0 0) 5px 11px / 16px 3px no-repeat,
    linear-gradient(currentColor 0 0) 5px 17px / 16px 3px no-repeat;
}

.social-mail {
  --icon-bg: linear-gradient(135deg, #dbe5ff, #b9c6ff 46%, #d9ccff);
  --icon-fg: #061022;
}

.social-mail::before {
  width: 28px;
  height: 20px;
  border: 3px solid currentColor;
  border-radius: 4px;
  background:
    linear-gradient(35deg, transparent 46%, currentColor 47%, currentColor 54%, transparent 55%),
    linear-gradient(-35deg, transparent 46%, currentColor 47%, currentColor 54%, transparent 55%);
}

.account-dialog {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: none;
  place-items: center;
  padding: 20px;
}

.account-dialog.is-open {
  display: grid;
}

.account-dialog-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 16, 0.62);
  backdrop-filter: blur(8px);
}

.account-dialog-panel {
  position: relative;
  z-index: 1;
  width: min(520px, 100%);
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(18, 26, 47, 0.9);
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.42);
}

.account-dialog-title {
  margin: 0 0 14px;
  color: var(--text);
  font-size: 24px;
}

.account-dialog-value {
  overflow-wrap: anywhere;
  margin: 0 0 20px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(248, 250, 252, 0.07);
  line-height: 1.7;
}

.account-dialog-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.account-dialog-actions .button {
  min-height: 44px;
}

.account-close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--text);
  background: rgba(248, 250, 252, 0.08);
  cursor: pointer;
}

.giscus-panel {
  padding: clamp(22px, 4vw, 34px);
}

.giscus-panel .section-heading {
  margin-bottom: 18px;
}

.giscus-panel h2 {
  margin-bottom: 0;
}

.giscus-fallback {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.06);
}

.giscus-fallback p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.giscus-box {
  min-height: 280px;
}

.giscus-setup {
  padding: 24px;
  border: 1px dashed rgba(248, 250, 252, 0.22);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(248, 250, 252, 0.06);
}

.giscus-setup strong {
  display: block;
  margin-bottom: 10px;
  color: var(--text);
  font-size: 22px;
}

.giscus-setup p {
  max-width: 760px;
  margin-bottom: 0;
  line-height: 1.8;
}

.giscus-setup code {
  padding: 2px 6px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: #e7ecff;
  background: rgba(8, 13, 26, 0.5);
}

@keyframes cursorBlink {
  50% {
    opacity: 0;
  }
}

@keyframes fireflyDrift {
  0% {
    transform: translate3d(0, 0, 0) scale(0.82);
  }

  50% {
    transform: translate3d(calc(var(--firefly-x) * 0.42), calc(var(--firefly-y) * 0.58), 0) scale(1.08);
  }

  100% {
    transform: translate3d(var(--firefly-x), var(--firefly-y), 0) scale(0.9);
  }
}

@keyframes fireflyGlow {
  0%,
  100% {
    opacity: 0.14;
  }

  42% {
    opacity: 0.86;
  }

  68% {
    opacity: 0.34;
  }
}

.article-list {
  display: grid;
  gap: 18px;
  max-width: 920px;
  margin: 0 auto;
}

.article-loading,
.article-empty {
  color: var(--muted);
  text-align: center;
}

.article-card {
  display: block;
}

.article-card a {
  position: relative;
  z-index: 1;
  display: block;
  padding: 26px;
}

.article-card h2 {
  margin-bottom: 12px;
  line-height: 1.28;
}

.article-card p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.75;
}

.article-card-meta,
.article-meta {
  color: var(--muted-soft);
  font-size: 14px;
  font-weight: 700;
}

.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.article-tags span {
  padding: 5px 9px;
  border: 1px solid rgba(97, 218, 251, 0.22);
  border-radius: 999px;
  color: var(--cyan);
  background: rgba(97, 218, 251, 0.08);
  font-size: 13px;
  font-weight: 800;
}

.article-page {
  max-width: 900px;
  margin: 0 auto;
  padding: 54px 0;
}

.article-back {
  display: inline-flex;
  margin-bottom: 18px;
  color: var(--muted);
  font-weight: 800;
}

.article-back:hover {
  color: var(--text);
}

.article-shell {
  padding: clamp(24px, 5vw, 48px);
}

.article-header {
  position: relative;
  z-index: 1;
  margin-bottom: 28px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}

.article-header h1 {
  margin-bottom: 14px;
  font-size: clamp(34px, 6vw, 58px);
}

.markdown-body {
  position: relative;
  z-index: 1;
  color: var(--text);
  font-size: 17px;
  line-height: 1.9;
}

.markdown-body h1,
.markdown-body h2,
.markdown-body h3 {
  margin: 1.6em 0 0.55em;
  line-height: 1.28;
}

.markdown-body h1:first-child {
  margin-top: 0;
}

.markdown-body p,
.markdown-body li {
  color: var(--muted);
}

.markdown-body a {
  color: var(--cyan);
  font-weight: 800;
}

.markdown-body blockquote {
  margin: 22px 0;
  padding: 14px 18px;
  border-left: 3px solid var(--cyan);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(97, 218, 251, 0.08);
}

.markdown-body code {
  padding: 2px 6px;
  border-radius: 6px;
  color: #dbeafe;
  background: rgba(8, 13, 26, 0.72);
}

.markdown-body pre {
  overflow-x: auto;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 26, 0.78);
}

.finder-window {
  margin: 30px 0 72px;
  border: 1px solid rgba(248, 250, 252, 0.14);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(248, 250, 252, 0.1), transparent 36%),
    rgba(12, 18, 34, 0.72);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
  overflow: hidden;
}

body.light-theme .finder-window {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.76), transparent 38%),
    rgba(255, 255, 255, 0.68);
}

.finder-titlebar {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  min-height: 62px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  background: rgba(248, 250, 252, 0.06);
}

.finder-traffic {
  display: flex;
  gap: 8px;
}

.finder-traffic span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.16);
}

.traffic-close {
  background: #ff5f57;
}

.traffic-minimize {
  background: #febc2e;
}

.traffic-zoom {
  background: #28c840;
}

.finder-title {
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
  text-align: center;
}

.finder-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.finder-view-button {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(248, 250, 252, 0.06);
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  transition:
    color 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    transform 180ms ease;
}

.finder-view-button:hover,
.finder-view-button.is-active {
  color: var(--text);
  border-color: rgba(108, 140, 255, 0.44);
  background: rgba(108, 140, 255, 0.16);
}

.finder-view-button:hover {
  transform: translateY(-1px);
}

.tool-filterbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(248, 250, 252, 0.035);
}

.tool-filter-button {
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(248, 250, 252, 0.055);
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  transition:
    color 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    transform 180ms ease;
}

.tool-filter-button:hover,
.tool-filter-button.is-active {
  color: #122033;
  border-color: rgba(206, 255, 239, 0.5);
  background: linear-gradient(135deg, #dff7ff, #d9ffe9);
}

.tool-filter-button:hover {
  transform: translateY(-1px);
}

.finder-columns {
  display: none;
  grid-template-columns: minmax(240px, 1fr) 120px 130px 190px;
  gap: 16px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
  color: var(--muted-soft);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.finder-projects {
  display: grid;
  gap: 16px;
  padding: 18px;
}

.finder-project-card {
  position: relative;
  display: grid;
  gap: 18px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(248, 250, 252, 0.12), transparent 34%),
    rgba(18, 26, 47, 0.68);
  box-shadow: 0 18px 56px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(18px);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    box-shadow 180ms ease;
  overflow: hidden;
}

.finder-project-card.is-hidden {
  display: none;
}

body.light-theme .finder-project-card {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), transparent 38%),
    rgba(255, 255, 255, 0.7);
  box-shadow: 0 18px 56px rgba(67, 83, 128, 0.16);
}

.finder-project-card:hover {
  transform: translateY(-4px);
  border-color: rgba(108, 140, 255, 0.34);
  box-shadow: 0 26px 76px rgba(0, 0, 0, 0.34);
}

.project-preview {
  position: relative;
  display: grid;
  min-height: 150px;
  place-items: center;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 24% 18%, rgba(97, 218, 251, 0.22), transparent 26%),
    linear-gradient(135deg, rgba(108, 140, 255, 0.28), rgba(18, 26, 47, 0.34));
  overflow: hidden;
}

.project-preview::after {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(to bottom, #000, transparent 88%);
}

.preview-learning {
  background:
    radial-gradient(circle at 28% 24%, rgba(132, 204, 22, 0.34), transparent 24%),
    linear-gradient(135deg, rgba(108, 140, 255, 0.3), rgba(18, 26, 47, 0.42));
}

.preview-weread {
  background:
    radial-gradient(circle at 64% 22%, rgba(97, 218, 251, 0.34), transparent 24%),
    linear-gradient(135deg, rgba(167, 139, 250, 0.26), rgba(18, 26, 47, 0.44));
}

.preview-wallpaper {
  background:
    linear-gradient(180deg, rgba(2, 6, 16, 0.1), rgba(11, 16, 32, 0.55)),
    url("earth-dawn-panorama.png") center 62% / cover no-repeat;
}

.project-icon {
  position: relative;
  z-index: 1;
  display: grid;
  width: 64px;
  height: 64px;
  place-items: center;
  border: 1px solid rgba(248, 250, 252, 0.18);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.12);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.26);
  font-size: 30px;
  backdrop-filter: blur(12px);
}

.project-main,
.project-meta,
.finder-project-card .project-actions {
  position: relative;
  z-index: 1;
}

.project-main h2 {
  margin-bottom: 10px;
  line-height: 1.25;
}

.project-main p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.75;
}

.project-kind {
  margin-bottom: 8px;
  color: var(--cyan) !important;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted-soft);
  font-size: 13px;
  font-weight: 800;
}

.project-meta span {
  padding: 5px 8px;
  border: 1px solid rgba(248, 250, 252, 0.1);
  border-radius: 999px;
  background: rgba(248, 250, 252, 0.06);
}

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

.finder-card-view .finder-project-card,
.finder-grid-view .finder-project-card,
.finder-image-view .finder-project-card {
  padding-bottom: 22px;
}

.finder-card-view .project-main,
.finder-card-view .project-meta,
.finder-card-view .project-actions,
.finder-grid-view .project-main,
.finder-grid-view .project-meta,
.finder-grid-view .project-actions,
.finder-image-view .project-main,
.finder-image-view .project-meta,
.finder-image-view .project-actions {
  padding: 0 22px;
}

.finder-list-view {
  gap: 10px;
}

.finder-window.is-list-view .finder-columns {
  display: grid;
}

.finder-list-view .finder-project-card {
  grid-template-columns: minmax(260px, 1fr) 120px 130px 190px;
  align-items: center;
  gap: 16px;
  min-height: 76px;
  padding: 12px 18px;
}

.finder-list-view .project-preview {
  display: none;
}

.finder-list-view .project-kind,
.finder-list-view .project-main p {
  display: none;
}

.finder-list-view .project-main h2 {
  margin-bottom: 0;
  font-size: 18px;
}

.finder-list-view .project-meta {
  display: contents;
}

.finder-list-view .project-meta span {
  padding: 0;
  border: 0;
  background: transparent;
}

.finder-list-view .project-actions {
  justify-content: flex-end;
}

.finder-list-view .backup-link {
  display: none;
}

.finder-grid-view {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.finder-grid-view .project-preview {
  min-height: 128px;
}

.finder-grid-view .project-main h2 {
  font-size: 20px;
}

.finder-grid-view .project-meta {
  display: none;
}

.finder-grid-view .project-actions {
  align-items: stretch;
  flex-direction: column;
}

.finder-image-view {
  grid-template-columns: 1fr;
}

.finder-image-view .finder-project-card {
  grid-template-columns: minmax(280px, 0.9fr) minmax(0, 1fr);
  align-items: center;
  min-height: 260px;
}

.finder-image-view .project-preview {
  align-self: stretch;
  min-height: 260px;
  border-right: 1px solid var(--line);
  border-bottom: 0;
}

.finder-image-view .project-main,
.finder-image-view .project-meta,
.finder-image-view .project-actions {
  padding-right: 28px;
  padding-left: 0;
}

.practice-board {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.practice-folder {
  position: relative;
  display: grid;
  gap: 18px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(248, 250, 252, 0.12), transparent 34%),
    rgba(18, 26, 47, 0.66);
  box-shadow: 0 18px 56px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(18px);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
  overflow: hidden;
}

body.light-theme .practice-folder {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), transparent 38%),
    rgba(255, 255, 255, 0.7);
  box-shadow: 0 18px 56px rgba(67, 83, 128, 0.16);
}

.practice-folder:hover {
  transform: translateY(-3px);
  border-color: rgba(108, 140, 255, 0.34);
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.32);
}

.practice-folder-icon {
  display: grid;
  width: 62px;
  height: 62px;
  place-items: center;
  border: 1px solid rgba(248, 250, 252, 0.18);
  border-radius: 8px;
  background:
    radial-gradient(circle at 28% 18%, rgba(97, 218, 251, 0.22), transparent 36%),
    rgba(248, 250, 252, 0.1);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.24);
  font-size: 28px;
}

.practice-folder-main h2 {
  margin-bottom: 8px;
  line-height: 1.24;
}

.practice-folder-main h2 a:hover {
  color: var(--cyan);
}

.practice-folder-main p {
  margin-bottom: 16px;
  color: var(--muted);
  line-height: 1.75;
}

.practice-subcards {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.practice-subcard {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  color: #e7ecff;
  background: rgba(248, 250, 252, 0.06);
  font-weight: 800;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

body.light-theme .practice-subcard {
  color: #172033;
  background: rgba(255, 255, 255, 0.66);
}

.practice-subcard:hover {
  transform: translateY(-2px);
  border-color: rgba(108, 140, 255, 0.42);
  background: rgba(108, 140, 255, 0.14);
}

.practice-list-view .practice-folder {
  grid-template-columns: 76px minmax(0, 1fr);
  align-items: start;
  padding: 18px;
}

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

.practice-grid-view .practice-folder {
  padding: 22px;
}

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

.practice-image-view .practice-folder {
  min-height: 330px;
  padding: 24px;
}

.practice-image-view .practice-folder::before {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(180deg, rgba(2, 6, 16, 0.06), rgba(11, 16, 32, 0.72)),
    url("earth-dawn-panorama.png") center 62% / cover no-repeat;
  opacity: 0.46;
}

.practice-image-view .practice-folder > * {
  position: relative;
  z-index: 1;
}

.practice-image-view .practice-folder-icon {
  width: 74px;
  height: 74px;
  font-size: 34px;
}

.practice-image-view .practice-folder-main {
  align-self: end;
}

.practice-image-view .practice-folder-main p {
  color: #d5def4;
}

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

.glass-card {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(248, 250, 252, 0.1), transparent 34%),
    var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    box-shadow 180ms ease;
  overflow: hidden;
}

.glass-card::before {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
  background: radial-gradient(circle at 22% 0%, rgba(108, 140, 255, 0.2), transparent 34%);
  opacity: 0.86;
}

.glass-card:hover {
  transform: translateY(-6px);
  border-color: rgba(248, 250, 252, 0.26);
  background:
    linear-gradient(145deg, rgba(248, 250, 252, 0.13), transparent 36%),
    var(--panel-strong);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.42);
}

.project-card,
.knowledge-card,
.practice-card,
.feature-card {
  min-height: 100%;
  padding: 26px;
}

.project-card > *,
.knowledge-card > *,
.practice-card > *,
.feature-card > * {
  position: relative;
  z-index: 1;
}

.card-icon {
  display: inline-grid;
  width: 52px;
  height: 52px;
  place-items: center;
  margin-bottom: 18px;
  border: 1px solid rgba(248, 250, 252, 0.16);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.08);
  font-size: 24px;
}

.project-card h3,
.knowledge-card h2,
.practice-card h2,
.feature-card h2 {
  margin-bottom: 10px;
  line-height: 1.25;
  letter-spacing: 0;
}

.project-card p {
  min-height: 58px;
  margin-bottom: 22px;
}

.page-hero {
  max-width: 780px;
  padding: clamp(78px, 12vw, 132px) 0 36px;
}

.page-hero h1 {
  font-size: clamp(44px, 7vw, 78px);
}

.knowledge-card {
  display: block;
}

.knowledge-card p {
  margin-bottom: 0;
}

.practice-card {
  display: grid;
  gap: 16px;
}

.link-list {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.link-list a {
  display: flex;
  align-items: center;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  color: #e7ecff;
  background: rgba(248, 250, 252, 0.06);
  font-weight: 700;
  transition:
    background 180ms ease,
    border-color 180ms ease,
    transform 180ms ease;
}

.link-list a:hover {
  transform: translateY(-2px);
  border-color: rgba(108, 140, 255, 0.42);
  background: rgba(108, 140, 255, 0.14);
}

.feature-card {
  display: block;
  min-height: 230px;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  padding: 32px 0 42px;
  color: var(--muted-soft);
  font-size: 14px;
}

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

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

@media (max-width: 880px) {
  .page-shell {
    width: min(100% - 28px, 720px);
  }

  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .home-page .site-header {
    position: static;
    width: auto;
    transform: none;
  }

  .hero-wallpaper {
    min-height: 270px;
  }

  .site-nav {
    width: 100%;
    justify-content: flex-start;
    gap: 18px;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding-top: 72px;
  }

  .orbit-panel {
    min-height: 290px;
  }

  .project-grid,
  .knowledge-grid,
  .recent-grid,
  .practice-grid,
  .about-hero,
  .article-list,
  .finder-card-view,
  .finder-grid-view,
  .practice-grid-view,
  .practice-image-view,
  .split-section {
    grid-template-columns: 1fr;
  }

  .finder-titlebar {
    grid-template-columns: 1fr;
  }

  .finder-title {
    text-align: left;
  }

  .finder-toolbar {
    justify-content: flex-start;
  }

  .finder-window.is-list-view .finder-columns {
    display: none;
  }

  .finder-list-view .finder-project-card,
  .finder-image-view .finder-project-card {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .finder-list-view .project-preview {
    display: grid;
  }

  .finder-list-view .project-kind,
  .finder-list-view .project-main p {
    display: block;
  }

  .finder-list-view .project-meta {
    display: flex;
  }

  .finder-list-view .project-meta span {
    padding: 5px 8px;
    border: 1px solid rgba(248, 250, 252, 0.1);
    background: rgba(248, 250, 252, 0.06);
  }

  .finder-list-view .project-actions {
    justify-content: flex-start;
  }

  .finder-list-view .backup-link {
    display: inline-flex;
  }

  .finder-image-view .project-preview {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .finder-image-view .project-main,
  .finder-image-view .project-meta,
  .finder-image-view .project-actions {
    padding-right: 22px;
    padding-left: 22px;
  }

  .practice-list-view .practice-folder {
    grid-template-columns: 1fr;
  }

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

  .project-card p {
    min-height: auto;
  }
}

@media (max-width: 520px) {
  .page-shell {
    width: min(100% - 22px, 440px);
  }

  .brand {
    width: 100%;
  }

  .home-page .site-header {
    width: auto;
  }

  .hero-wallpaper {
    min-height: 230px;
  }

  .site-nav a {
    flex: 0 0 auto;
    text-align: center;
  }

  .hero {
    padding-bottom: 42px;
  }

  .hero-actions,
  .button,
  .card-link,
  .backup-link {
    width: 100%;
  }

  .link-list {
    grid-template-columns: 1fr;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .project-card,
  .knowledge-card,
  .practice-card,
  .feature-card,
  .article-card a {
    padding: 22px;
  }

  .finder-projects {
    padding: 12px;
  }

  .practice-board {
    padding: 12px;
  }

  .finder-card-view .project-main,
  .finder-card-view .project-meta,
  .finder-card-view .project-actions,
  .finder-grid-view .project-main,
  .finder-grid-view .project-meta,
  .finder-grid-view .project-actions,
  .finder-image-view .project-main,
  .finder-image-view .project-meta,
  .finder-image-view .project-actions {
    padding-right: 18px;
    padding-left: 18px;
  }

  .site-footer {
    flex-direction: column;
  }
}

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

/* Cozy wallpaper desktop theme */
body,
body.light-theme {
  background:
    linear-gradient(180deg, rgba(20, 34, 42, 0.18), rgba(20, 34, 42, 0.08)),
    url("cozy-wallpaper.png") center center / cover fixed no-repeat;
}

body::before,
body.light-theme::before {
  z-index: -2;
  background:
    radial-gradient(circle at 18% 8%, rgba(255, 255, 255, 0.2), transparent 18rem),
    linear-gradient(180deg, rgba(15, 31, 40, 0.18), rgba(15, 31, 40, 0.06) 42%, rgba(15, 31, 40, 0.2));
  background-size: auto;
  mask-image: none;
  pointer-events: none;
}

#starfield {
  z-index: -1;
  opacity: 0.22;
  mix-blend-mode: screen;
}

body.light-theme #starfield {
  opacity: 0.12;
}

.site-header,
body.light-theme .site-header {
  border-color: rgba(255, 255, 255, 0.22);
  background: rgba(61, 78, 78, 0.52);
  box-shadow: 0 18px 48px rgba(31, 45, 48, 0.22);
  backdrop-filter: blur(22px) saturate(1.22);
}

.brand,
.site-nav a,
body.light-theme .site-nav a {
  color: rgba(255, 255, 255, 0.92);
  text-shadow: 0 2px 14px rgba(25, 39, 42, 0.22);
}

.brand-mark::before {
  background: linear-gradient(135deg, #b6e7ff 0%, #70b7ff 54%, #87d39d 100%);
}

.theme-toggle,
body.light-theme .theme-toggle {
  border-color: rgba(255, 255, 255, 0.22);
  color: #f8fafc;
  background: rgba(61, 78, 78, 0.42);
  backdrop-filter: blur(18px);
}

.hero-wallpaper {
  display: none;
}

.intro-hero,
.page-hero,
.finder-window,
.glass-card,
.article-shell,
body.light-theme .finder-window,
body.light-theme .glass-card,
body.light-theme .article-shell {
  border: 1px solid rgba(255, 255, 255, 0.24);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.12), transparent 42%),
    rgba(67, 88, 88, 0.54);
  box-shadow: 0 24px 74px rgba(30, 48, 50, 0.25);
  backdrop-filter: blur(22px) saturate(1.18);
}

.intro-hero,
.page-hero {
  max-width: 900px;
  margin: 28px auto 0;
  padding: clamp(34px, 6vw, 64px);
  border-radius: 8px;
}

.intro-hero h1,
.intro-hero .subtitle,
.page-hero h1,
.section-heading h2,
.project-main h2,
.practice-folder-main h2,
.article-card h2,
.markdown-body h1,
.markdown-body h2,
.markdown-body h3 {
  color: rgba(255, 255, 255, 0.96);
  text-shadow: 0 2px 18px rgba(25, 39, 42, 0.34);
}

.intro-hero .hero-copy,
.page-hero p,
.project-main p,
.practice-folder-main p,
.article-card p,
.markdown-body p,
.markdown-body li,
.knowledge-card p,
.feature-card p,
.project-card p {
  color: rgba(241, 245, 249, 0.84);
}

.eyebrow,
.feature-kicker,
.project-kind,
.article-tags span {
  color: #dff7ff !important;
}

.finder-titlebar,
.finder-columns {
  background: rgba(58, 76, 76, 0.32);
}

.finder-project-card,
.practice-folder,
body.light-theme .finder-project-card,
body.light-theme .practice-folder {
  border-color: rgba(255, 255, 255, 0.2);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.12), transparent 40%),
    rgba(67, 88, 88, 0.5);
  box-shadow: 0 18px 56px rgba(30, 48, 50, 0.2);
}

.finder-project-card:hover,
.practice-folder:hover,
.glass-card:hover {
  border-color: rgba(255, 255, 255, 0.34);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.16), transparent 42%),
    rgba(67, 88, 88, 0.62);
}

.finder-view-button,
.backup-link,
.practice-subcard,
.link-list a,
body.light-theme .backup-link,
body.light-theme .practice-subcard,
body.light-theme .link-list a {
  border-color: rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.1);
}

.finder-view-button:hover,
.finder-view-button.is-active,
.backup-link:hover,
.practice-subcard:hover,
.link-list a:hover {
  border-color: rgba(223, 247, 255, 0.48);
  background: rgba(255, 255, 255, 0.18);
}

.button-primary,
.card-link {
  color: #263238;
  background: linear-gradient(135deg, #f4fbff, #d9f1ff 48%, #d9f7de);
  box-shadow: 0 18px 46px rgba(67, 88, 88, 0.24);
}

.project-preview,
.practice-image-view .practice-folder::before {
  filter: saturate(0.96) brightness(1.03);
}

.site-footer {
  color: rgba(255, 255, 255, 0.74);
  text-shadow: 0 2px 14px rgba(25, 39, 42, 0.22);
}

/* Home keeps the original cosmic landing style */
body.home-page,
body.home-page.light-theme {
  --bg: #0b1020;
  --bg-soft: #121a2f;
  --panel: rgba(18, 26, 47, 0.68);
  --panel-strong: rgba(24, 34, 62, 0.78);
  --line: rgba(248, 250, 252, 0.14);
  --text: #f8fafc;
  --muted: #b7c2db;
  --muted-soft: #8290b4;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
  color: var(--text);
  color-scheme: dark;
  background:
    radial-gradient(circle at 18% 18%, rgba(108, 140, 255, 0.26), transparent 28rem),
    radial-gradient(circle at 82% 12%, rgba(167, 139, 250, 0.2), transparent 24rem),
    linear-gradient(180deg, #070b16 0%, var(--bg) 48%, #080d1a 100%);
}

body.home-page::before,
body.home-page.light-theme::before {
  z-index: -3;
  background:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.028) 1px, transparent 1px),
    radial-gradient(circle at 50% 18%, rgba(108, 140, 255, 0.18), transparent 32rem);
  background-size: 72px 72px, 72px 72px, auto;
  mask-image: linear-gradient(to bottom, transparent 0%, #000 12%, #000 88%, transparent 100%);
}

/* Compact page heading panels for inner pages */
body:not(.home-page) .page-hero {
  max-width: 900px;
  margin: 18px auto 0;
  padding: clamp(18px, 3vw, 30px) clamp(22px, 4vw, 46px);
  border-radius: 8px;
}

body:not(.home-page) .page-hero .eyebrow {
  margin-bottom: 8px;
}

body:not(.home-page) .page-hero h1 {
  margin-bottom: 8px;
  font-size: clamp(34px, 4.8vw, 54px);
  line-height: 1;
}

body:not(.home-page) .page-hero p {
  max-width: 760px;
  margin-bottom: 0;
  font-size: clamp(15px, 1.8vw, 18px);
  line-height: 1.62;
}

/* Personal calendar workspace */
.calendar-dashboard {
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(360px, 1.05fr);
  gap: 18px;
  align-items: start;
}

.calendar-side {
  display: grid;
  gap: 14px;
}

.calendar-panel {
  padding: clamp(18px, 2.2vw, 26px);
}

.calendar-month {
  min-height: 100%;
}

.calendar-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.calendar-toolbar h2,
.calendar-section-title h2 {
  margin: 0;
  line-height: 1.15;
}

.calendar-toolbar h2 {
  font-size: clamp(24px, 3vw, 34px);
}

.calendar-section-title {
  margin-bottom: 14px;
}

.calendar-section-title .eyebrow {
  margin-bottom: 6px;
}

.calendar-nav {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: rgba(248, 250, 252, 0.07);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition:
    transform 0.2s ease,
    border-color 0.2s ease,
    background 0.2s ease;
}

.calendar-nav:hover {
  transform: translateY(-2px);
  border-color: rgba(248, 250, 252, 0.28);
  background: rgba(248, 250, 252, 0.12);
}

.calendar-weekdays,
.calendar-grid-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}

.calendar-weekdays {
  margin-bottom: 8px;
}

.calendar-weekdays span {
  color: var(--muted-soft);
  font-size: 13px;
  font-weight: 800;
  text-align: center;
}

.calendar-day {
  position: relative;
  min-height: 58px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  color: var(--text);
  font: inherit;
  font-weight: 800;
  background: rgba(248, 250, 252, 0.055);
  cursor: default;
}

.calendar-day.is-muted {
  opacity: 0.42;
}

.calendar-day.is-today {
  color: #061022;
  background: linear-gradient(135deg, #dbe5ff, #b9c6ff 48%, #d9ccff);
  box-shadow:
    0 14px 34px rgba(108, 140, 255, 0.26),
    0 0 0 1px rgba(255, 255, 255, 0.22) inset;
}

.calendar-day.has-record::after {
  position: absolute;
  right: 9px;
  bottom: 8px;
  width: 6px;
  height: 6px;
  content: "";
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 12px rgba(97, 218, 251, 0.7);
}

.calendar-overview {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  background:
    radial-gradient(circle at 16% 8%, rgba(97, 218, 251, 0.13), transparent 30%),
    rgba(248, 250, 252, 0.045);
}

.calendar-clock {
  display: grid;
  gap: 6px;
  margin-bottom: 16px;
  padding: 16px;
  border: 1px solid rgba(97, 218, 251, 0.14);
  border-radius: 8px;
  background: rgba(7, 12, 24, 0.22);
}

.calendar-clock span {
  color: var(--muted);
  font-weight: 700;
}

.calendar-clock strong {
  color: var(--text);
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1;
  letter-spacing: 0.02em;
}

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

.calendar-stat {
  min-height: 86px;
  padding: 14px;
  border: 1px solid rgba(248, 250, 252, 0.1);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.055);
}

.calendar-stat span {
  display: block;
  margin-bottom: 10px;
  color: var(--muted-soft);
  font-size: 13px;
  font-weight: 800;
}

.calendar-stat strong {
  display: block;
  overflow: hidden;
  color: rgba(248, 250, 252, 0.94);
  font-size: 20px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calendar-inline-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.calendar-countdown .calendar-inline-form {
  grid-template-columns: minmax(0, 1fr) 156px auto;
}

.calendar-panel input,
.calendar-panel textarea,
.diary-lock-dialog input {
  width: 100%;
  border: 1px solid rgba(248, 250, 252, 0.14);
  border-radius: 8px;
  color: var(--text);
  background: rgba(7, 12, 24, 0.38);
  font: inherit;
  line-height: 1.6;
  outline: none;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}

.calendar-panel input,
.diary-lock-dialog input {
  min-height: 44px;
  padding: 0 14px;
}

.calendar-panel textarea {
  resize: vertical;
  padding: 12px 14px;
}

.calendar-panel input:focus,
.calendar-panel textarea:focus,
.diary-lock-dialog input:focus {
  border-color: rgba(108, 140, 255, 0.62);
  background: rgba(7, 12, 24, 0.52);
  box-shadow: 0 0 0 4px rgba(108, 140, 255, 0.12);
}

.calendar-list {
  display: grid;
  gap: 8px;
  padding: 0;
  margin: 14px 0 0;
  list-style: none;
}

.calendar-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(248, 250, 252, 0.1);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.055);
}

.calendar-list label {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  gap: 9px;
}

.calendar-list input[type="checkbox"] {
  width: 16px;
  min-width: 16px;
  height: 16px;
  min-height: 16px;
  padding: 0;
}

.calendar-list span {
  overflow-wrap: anywhere;
}

.calendar-list li.is-done span {
  opacity: 0.62;
  text-decoration: line-through;
}

.calendar-list button[data-delete-task] {
  display: grid;
  width: 28px;
  min-width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(248, 250, 252, 0.06);
  cursor: pointer;
}

.countdown-result {
  margin-top: 12px;
  padding: 13px 14px;
  border: 1px solid rgba(97, 218, 251, 0.16);
  border-radius: 8px;
  color: rgba(232, 240, 255, 0.92);
  background: rgba(97, 218, 251, 0.075);
}

.calendar-diary-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

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

.recent-record {
  min-height: 124px;
  padding: 16px;
  border: 1px solid rgba(248, 250, 252, 0.12);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.055);
}

.recent-record time {
  display: block;
  margin-bottom: 10px;
  color: var(--cyan);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.recent-record strong {
  display: block;
  margin-bottom: 8px;
}

.recent-record p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.calendar-empty {
  color: var(--muted);
}

.diary-lock-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(3, 7, 18, 0.68);
  backdrop-filter: blur(12px);
}

.diary-lock-dialog {
  position: relative;
  width: min(440px, 100%);
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(248, 250, 252, 0.12), transparent 42%),
    rgba(18, 26, 47, 0.88);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.5);
}

.diary-lock-dialog h2 {
  margin: 0 0 8px;
  font-size: 30px;
}

.diary-lock-dialog p:not(.eyebrow) {
  margin: 0 0 16px;
  color: var(--muted);
}

.diary-lock-dialog input {
  margin-bottom: 10px;
}

.diary-lock-dialog .button {
  width: 100%;
  margin-top: 6px;
}

.diary-lock-error {
  min-height: 22px;
  color: #fecaca;
  font-weight: 700;
}

.diary-lock-close {
  position: absolute;
  top: 12px;
  right: 12px;
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid rgba(248, 250, 252, 0.14);
  border-radius: 8px;
  color: var(--text);
  background: rgba(248, 250, 252, 0.06);
  cursor: pointer;
}

@media (max-width: 880px) {
  .calendar-dashboard {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 620px) {
  .calendar-inline-form,
  .calendar-countdown .calendar-inline-form {
    grid-template-columns: 1fr;
  }

  .calendar-day {
    min-height: 44px;
  }

  .calendar-stat-grid {
    grid-template-columns: 1fr;
  }

  .recent-records {
    grid-template-columns: 1fr;
  }
}

body.home-page #starfield {
  z-index: -2;
  opacity: 0.38;
  mix-blend-mode: screen;
}

.home-page .page-shell {
  width: 100%;
}

.home-page .site-header {
  position: absolute;
  top: 24px;
  left: 50%;
  width: min(1450px, calc(100% - 96px));
  margin: 0;
  transform: translateX(-50%);
}

.home-page .hero-wallpaper {
  margin-top: 0;
  padding-top: 126px;
}

.home-page main {
  position: relative;
  width: 100vw;
  margin-top: -1px;
  margin-left: calc(50% - 50vw);
  background:
    linear-gradient(180deg, rgba(6, 10, 24, 0.96) 0%, rgba(6, 10, 24, 0.78) 8%, rgba(6, 10, 24, 0.34) 26%, rgba(6, 10, 24, 0.62) 100%),
    url("earth-starry-panorama.png") center 30% / cover fixed no-repeat;
}

.home-page main::before {
  position: absolute;
  inset: 0 0 auto;
  z-index: 0;
  height: clamp(140px, 18vw, 260px);
  content: "";
  pointer-events: none;
  background:
    radial-gradient(ellipse at center top, rgba(38, 89, 148, 0.18), transparent 58%),
    linear-gradient(180deg, #070b16 0%, rgba(7, 11, 22, 0.92) 32%, rgba(7, 11, 22, 0.34) 74%, transparent 100%);
}

.home-page main > * {
  position: relative;
  z-index: 1;
}

.home-page main > .split-section,
.home-page main > .recent-section {
  width: min(1160px, calc(100% - 40px));
  margin-right: auto;
  margin-left: auto;
}

.home-page main > .intro-hero,
.home-page main > .intro-hero.hero {
  width: 100vw;
  margin-right: 0;
  margin-left: calc(50% - 50vw);
}

.home-page main > .hero-wallpaper {
  width: 100vw;
  margin-left: 0;
}

.home-page .site-header,
body.home-page.light-theme .site-header {
  z-index: 20;
  border-color: rgba(248, 250, 252, 0.14);
  background: rgba(8, 13, 26, 0.68);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(18px);
}

.home-page .brand,
.home-page .site-nav a,
body.home-page.light-theme .site-nav a {
  color: #e4ebff;
  text-shadow: none;
}

.home-page .hero-wallpaper {
  display: block;
}

.home-page .intro-hero,
.home-page .intro-hero.hero,
body.home-page.light-theme .intro-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  max-width: none;
  margin: 0;
  padding: clamp(48px, 7vw, 86px) 0 40px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.home-page .intro-hero .hero-content {
  position: relative;
  left: 50vw;
  width: min(820px, calc(100vw - 40px));
  max-width: 820px;
  margin: 0;
  justify-self: start;
  text-align: center;
  transform: translateX(-50%);
}

.home-page .intro-hero .hero-actions {
  display: none;
}

.home-page .intro-hero h1,
.home-page .intro-hero .subtitle,
.home-page .section-heading h2 {
  color: var(--text);
  text-shadow: 0 12px 34px rgba(0, 0, 0, 0.42);
}

.home-page .intro-hero .hero-copy,
.home-page .feature-card p {
  color: var(--muted);
}

.home-page .intro-hero .hero-copy {
  margin-bottom: 0;
}

.home-page .glass-card,
body.home-page.light-theme .glass-card {
  border: 1px solid var(--line);
  background:
    linear-gradient(145deg, rgba(248, 250, 252, 0.1), transparent 34%),
    var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.home-page .glass-card:hover {
  border-color: rgba(248, 250, 252, 0.26);
  background:
    linear-gradient(145deg, rgba(248, 250, 252, 0.13), transparent 36%),
    var(--panel-strong);
}

.home-page .button-primary,
.home-page .card-link {
  color: #061022;
  background: linear-gradient(135deg, #dbe5ff, #b9c6ff 46%, #d9ccff);
  box-shadow: 0 18px 46px rgba(108, 140, 255, 0.28);
}

.home-page .button-ghost {
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(248, 250, 252, 0.07);
}

@media (max-width: 880px) {
  .home-page .site-header {
    position: absolute;
    top: 14px;
    width: min(100% - 28px, 720px);
  }

  .home-page .hero-wallpaper {
    padding-top: 188px;
  }
}

@media (max-width: 520px) {
  .home-page .site-header {
    width: min(100% - 22px, 440px);
  }

  .home-page .hero-wallpaper {
    padding-top: 230px;
  }
}

/* NASA documentary home upgrade */
body.home-page,
body.home-page.light-theme {
  background: #05070d;
}

.home-page main {
  isolation: isolate;
  min-height: 100vh;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 28%, rgba(255, 221, 159, 0.2), transparent 12rem),
    radial-gradient(ellipse at 50% 28%, rgba(92, 175, 255, 0.34), transparent 34rem),
    linear-gradient(180deg, rgba(5, 7, 13, 0.14) 0%, rgba(5, 7, 13, 0.5) 28%, rgba(5, 7, 13, 0.78) 100%),
    url("earth-starry-panorama.png") center 58% / cover fixed no-repeat;
}

.home-page .hero-wallpaper {
  min-height: clamp(430px, 54vh, 620px);
  border-bottom: 0;
  background:
    radial-gradient(ellipse at 50% 58%, rgba(255, 255, 255, 0.42), transparent 17rem),
    linear-gradient(180deg, rgba(2, 6, 16, 0.08) 0%, rgba(2, 6, 16, 0.02) 46%, rgba(5, 7, 13, 0.6) 88%, transparent 100%),
    url("earth-dawn-panorama.png") center 58% / cover no-repeat;
  box-shadow: none;
  mask-image: linear-gradient(to bottom, #000 0%, #000 58%, rgba(0, 0, 0, 0.82) 72%, transparent 100%);
}

.home-page .hero-wallpaper::before {
  position: absolute;
  right: 0;
  bottom: 14%;
  left: 0;
  height: clamp(78px, 9vw, 138px);
  content: "";
  pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 45%, rgba(255, 255, 255, 0.72), transparent 24%),
    linear-gradient(180deg, transparent 0%, rgba(95, 190, 255, 0.34) 32%, rgba(17, 94, 170, 0.28) 54%, transparent 100%);
  filter: blur(10px);
  opacity: 0.88;
  animation: horizonBreath 7s ease-in-out infinite;
}

.home-page .hero-wallpaper::after {
  right: 0;
  bottom: clamp(-210px, -14vw, -120px);
  left: 0;
  height: clamp(250px, 26vw, 420px);
  background:
    radial-gradient(ellipse at 50% 4%, rgba(255, 255, 255, 0.28), transparent 19%),
    radial-gradient(ellipse at 50% 16%, rgba(93, 180, 255, 0.28), transparent 36%),
    linear-gradient(180deg, rgba(28, 118, 190, 0.18) 0%, rgba(9, 28, 58, 0.66) 38%, rgba(5, 7, 13, 0.92) 72%, transparent 100%);
  filter: blur(18px);
  opacity: 0.98;
}

.home-page .intro-hero,
.home-page .intro-hero.hero,
body.home-page.light-theme .intro-hero {
  position: relative;
  z-index: 2;
  min-height: clamp(470px, 52vh, 620px);
  margin-top: clamp(-150px, -10vw, -90px);
  padding: clamp(118px, 12vw, 178px) 0 clamp(54px, 7vw, 84px);
}

.home-page .intro-hero::before {
  position: absolute;
  inset: clamp(-190px, -14vw, -118px) 0 auto;
  z-index: -1;
  height: clamp(260px, 28vw, 440px);
  content: "";
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(5, 7, 13, 0) 0%, rgba(24, 97, 164, 0.2) 18%, rgba(7, 16, 35, 0.72) 46%, rgba(5, 7, 13, 0.2) 100%),
    radial-gradient(ellipse at 50% 14%, rgba(152, 209, 255, 0.24), transparent 44%);
  filter: blur(10px);
}

.home-page .intro-hero::after {
  position: absolute;
  inset: 0;
  z-index: -2;
  content: "";
  pointer-events: none;
  background:
    linear-gradient(rgba(164, 207, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(164, 207, 255, 0.035) 1px, transparent 1px);
  background-size: 96px 96px;
  mask-image: radial-gradient(ellipse at center, #000 0%, transparent 74%);
}

.home-page .intro-hero .hero-content {
  width: min(860px, calc(100vw - 40px));
  max-width: 860px;
}

.home-page .intro-hero .eyebrow {
  color: rgba(216, 239, 255, 0.9);
  letter-spacing: 0.16em;
  text-shadow: 0 0 22px rgba(118, 190, 255, 0.44);
}

.home-page .intro-hero h1 {
  font-size: clamp(62px, 8.8vw, 116px);
  letter-spacing: 0.02em;
  text-shadow:
    0 0 34px rgba(120, 180, 255, 0.16),
    0 24px 60px rgba(0, 0, 0, 0.62);
}

.home-page .intro-hero .subtitle {
  color: rgba(248, 250, 252, 0.96);
  letter-spacing: 0.03em;
  text-shadow: 0 0 24px rgba(118, 190, 255, 0.18);
}

.home-page .intro-hero .hero-copy {
  color: rgba(216, 226, 246, 0.86);
  text-shadow: 0 12px 32px rgba(0, 0, 0, 0.48);
}

.home-page main > .split-section {
  position: relative;
  z-index: 2;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(18px, 2vw, 24px);
  padding-bottom: clamp(52px, 8vw, 96px);
}

.home-page .feature-card {
  min-height: clamp(210px, 20vw, 270px);
  border-color: rgba(120, 180, 255, 0.12);
  background:
    linear-gradient(145deg, rgba(152, 204, 255, 0.12), transparent 36%),
    rgba(20, 25, 40, 0.46);
  box-shadow:
    0 24px 72px rgba(0, 0, 0, 0.52),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(20px);
}

.home-page .feature-card:hover {
  border-color: rgba(152, 204, 255, 0.26);
  background:
    linear-gradient(145deg, rgba(152, 204, 255, 0.17), transparent 38%),
    rgba(20, 25, 40, 0.56);
}

.home-page .feature-kicker {
  color: #8ed8ff;
  letter-spacing: 0.14em;
}

.meteor-field {
  position: fixed;
  inset: 0;
  z-index: 3;
  overflow: hidden;
  pointer-events: none;
}

.meteor {
  position: absolute;
  top: var(--meteor-top);
  left: var(--meteor-left);
  width: var(--meteor-length);
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, rgba(174, 220, 255, 0.82), #f8fafc);
  filter: drop-shadow(0 0 10px rgba(118, 190, 255, 0.7));
  opacity: 0;
  transform: rotate(-24deg) translate3d(0, 0, 0);
  transform-origin: right center;
  animation: meteorFly var(--meteor-duration) cubic-bezier(0.16, 0.78, 0.34, 1) forwards;
}

.meteor::after {
  position: absolute;
  right: -2px;
  top: 50%;
  width: 5px;
  height: 5px;
  content: "";
  border-radius: 50%;
  background: #fff;
  box-shadow:
    0 0 14px rgba(255, 255, 255, 0.9),
    0 0 28px rgba(118, 190, 255, 0.65);
  transform: translateY(-50%);
}

@keyframes horizonBreath {
  0%,
  100% {
    opacity: 0.72;
    transform: scaleX(0.98);
  }

  50% {
    opacity: 0.98;
    transform: scaleX(1.02);
  }
}

@keyframes meteorFly {
  0% {
    opacity: 0;
    transform: rotate(-24deg) translate3d(0, 0, 0);
  }

  10% {
    opacity: var(--meteor-opacity);
  }

  72% {
    opacity: var(--meteor-opacity);
  }

  100% {
    opacity: 0;
    transform: rotate(-24deg) translate3d(-58vw, 34vh, 0);
  }
}

@media (max-width: 880px) {
  .home-page .hero-wallpaper {
    min-height: 420px;
  }

  .home-page .intro-hero,
  .home-page .intro-hero.hero {
    margin-top: -92px;
  }

  .home-page main > .split-section {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .home-page .hero-wallpaper {
    min-height: 360px;
  }

  .home-page .intro-hero h1 {
    font-size: clamp(48px, 16vw, 68px);
  }
}
