:root {
  color-scheme: dark;
  --bg: #090a0f;
  --panel: rgba(255, 255, 255, 0.08);
  --panel-strong: rgba(255, 255, 255, 0.13);
  --text: #f7f2e8;
  --muted: #aeb7c8;
  --line: rgba(255, 255, 255, 0.14);
  --cyan: #6be8ff;
  --lime: #d7ff68;
  --coral: #ff6f61;
  --ink: #11131a;
  --shadow: 0 28px 90px rgba(0, 0, 0, 0.42);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 10% 8%, rgba(107, 232, 255, 0.18), transparent 30rem),
    radial-gradient(circle at 88% 18%, rgba(255, 111, 97, 0.15), transparent 28rem),
    linear-gradient(180deg, #090a0f 0%, #11131a 52%, #090a0f 100%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
p { color: var(--muted); line-height: 1.7; }
h1, h2, h3, p { margin-top: 0; }

#signalCanvas {
  position: fixed;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  opacity: 0.78;
}

.cursor-glow {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 20;
  width: 18rem;
  height: 18rem;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, rgba(107, 232, 255, 0.2), transparent 68%);
  transform: translate(-50%, -50%);
  mix-blend-mode: screen;
}

.profile-shell {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  width: min(1180px, calc(100% - 32px));
  min-height: calc(100vh - 32px);
  margin: 16px auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(9, 10, 15, 0.62);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  overflow: clip;
}

.profile-sidebar {
  position: sticky;
  top: 0;
  align-self: start;
  display: flex;
  min-height: calc(100vh - 32px);
  flex-direction: column;
  gap: 36px;
  padding: 42px 24px;
  border-right: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03)),
    rgba(9, 10, 15, 0.72);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  width: max-content;
  font-size: 30px;
  font-weight: 900;
}

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 50%;
  background: var(--lime);
  color: var(--ink);
  font-size: 15px;
  box-shadow: 0 0 28px rgba(215, 255, 104, 0.3);
}

.module-nav { display: grid; gap: 10px; }

.module-nav a {
  display: grid;
  grid-template-columns: 34px 1fr;
  align-items: center;
  min-height: 58px;
  padding: 10px 16px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--muted);
  transition: 180ms ease;
}

.module-nav a span { font-size: 22px; }
.module-nav a strong { font-size: 16px; }

.module-nav a:hover,
.module-nav a.active {
  border-color: rgba(215, 255, 104, 0.34);
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
  transform: translateX(4px);
}

.sidebar-card {
  margin-top: auto;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.07);
}

.sidebar-card p {
  margin-bottom: 8px;
  color: var(--lime);
  font-size: 13px;
  font-weight: 800;
}

.sidebar-card strong {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.profile-content {
  display: grid;
  gap: 84px;
  padding: 36px 64px 76px;
}

.module-section { scroll-margin-top: 24px; }

.eyebrow {
  margin-bottom: 12px;
  color: var(--lime);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

h1 {
  margin-bottom: 24px;
  font-size: clamp(28px, 3.2vw, 42px);
  line-height: 1.08;
}

h2 {
  margin-bottom: 10px;
  font-size: clamp(21px, 2.2vw, 28px);
  line-height: 1.22;
}

h3 {
  margin-bottom: 10px;
  font-size: 18px;
  line-height: 1.18;
}

p {
  font-size: 15px;
}

.intro-card,
.journey-card,
.project-card,
.destination-card,
.skill-card,
.side-card {
  border: 1px solid var(--line);
  border-radius: 10px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04)),
    rgba(255, 255, 255, 0.06);
  box-shadow: 0 16px 58px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(16px);
  transform-style: preserve-3d;
  transition: border-color 220ms ease, background 220ms ease, transform 220ms ease;
}

.intro-card:hover,
.journey-card:hover,
.project-card:hover,
.destination-card:hover,
.skill-card:hover,
.side-card:hover {
  border-color: rgba(215, 255, 104, 0.42);
  background:
    linear-gradient(135deg, rgba(107, 232, 255, 0.12), rgba(255, 255, 255, 0.05)),
    rgba(255, 255, 255, 0.08);
}

.intro-card {
  display: grid;
  grid-template-columns: 320px 1fr;
  align-items: center;
  gap: 32px;
  min-height: 330px;
  padding: 28px;
}

.command-stage {
  position: relative;
  min-height: 274px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.04)),
    rgba(255, 255, 255, 0.04);
  overflow: hidden;
}

.command-stage::before {
  content: "";
  position: absolute;
  inset: 58px 16px 16px;
  background:
    linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(to bottom, black, transparent);
}

.stage-toolbar {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.stage-toolbar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--coral);
}

.stage-toolbar span:nth-child(2) { background: var(--lime); }
.stage-toolbar span:nth-child(3) { background: var(--cyan); }

.stage-toolbar strong {
  margin-left: 8px;
  color: var(--muted);
  font-size: 14px;
}

.radar {
  position: relative;
  display: grid;
  width: min(210px, 58vw);
  aspect-ratio: 1;
  margin: 20px auto 0;
  place-items: center;
  border: 1px solid rgba(107, 232, 255, 0.28);
  border-radius: 50%;
  background:
    repeating-radial-gradient(circle, transparent 0 34px, rgba(107, 232, 255, 0.16) 35px 36px),
    radial-gradient(circle, rgba(107, 232, 255, 0.2), transparent 62%);
  overflow: hidden;
}

.radar::before,
.radar::after {
  content: "";
  position: absolute;
  background: rgba(107, 232, 255, 0.25);
}

.radar::before {
  width: 1px;
  height: 100%;
}

.radar::after {
  width: 100%;
  height: 1px;
}

.radar-sweep {
  position: absolute;
  inset: 0;
  background: conic-gradient(from 0deg, rgba(107, 232, 255, 0.55), transparent 76deg);
  animation: sweep 4s linear infinite;
  transform-origin: center;
}

.radar-core {
  position: relative;
  z-index: 1;
  display: grid;
  width: 92px;
  height: 92px;
  place-items: center;
  border-radius: 50%;
  background: var(--text);
  color: var(--ink);
  font-size: 17px;
  font-weight: 950;
  box-shadow: 0 0 34px rgba(107, 232, 255, 0.52);
}

.metric-row,
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.metric-row { margin-top: 22px; }

.metric-row span,
.chips span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(9, 10, 15, 0.36);
  color: var(--muted);
  font-size: 14px;
  font-weight: 750;
}

.metric-row b {
  margin-right: 6px;
  color: var(--lime);
}

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

.skill-card,
.side-card {
  min-height: 210px;
  padding: 22px;
}

.skill-card span {
  display: block;
  margin-bottom: 42px;
  font-size: 34px;
}

.journey-list {
  display: grid;
  gap: 22px;
}

.journey-card {
  display: grid;
  grid-template-columns: 150px 1fr;
  align-items: center;
  gap: 36px;
  min-height: 198px;
  padding: 26px 32px;
}

.company-mark {
  display: grid;
  width: 92px;
  height: 92px;
  place-items: center;
  justify-self: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background:
    linear-gradient(145deg, rgba(215, 255, 104, 0.2), rgba(107, 232, 255, 0.12)),
    rgba(255, 255, 255, 0.08);
  color: var(--text);
  font-size: 30px;
  font-weight: 950;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.26);
}

.journey-main p { margin-bottom: 14px; }

.project-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 150px;
  align-items: center;
  gap: 24px;
  min-height: 186px;
  padding: 26px 32px;
}

.project-tag {
  display: inline-flex;
  margin-bottom: 16px;
  color: var(--cyan);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.project-card strong {
  justify-self: end;
  color: var(--lime);
  font-size: 23px;
  line-height: 1.1;
  text-align: right;
}

.side-card h2 { margin-top: 54px; }

.destination-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  align-items: center;
  gap: 28px;
  min-height: 250px;
  padding: 30px;
  background:
    linear-gradient(120deg, rgba(215, 255, 104, 0.18), transparent 48%),
    linear-gradient(300deg, rgba(107, 232, 255, 0.16), transparent 46%),
    rgba(255, 255, 255, 0.08);
}

.contact-panel {
  display: grid;
  gap: 12px;
}

.primary,
.secondary {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 13px 18px;
  border-radius: 24px;
  font-weight: 850;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.primary {
  background: var(--lime);
  color: var(--ink);
  box-shadow: 0 18px 50px rgba(215, 255, 104, 0.24);
}

.secondary {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.primary:hover,
.secondary:hover { transform: translateY(-2px); }

.reveal {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition: opacity 700ms ease, transform 700ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

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

@keyframes sweep {
  to { transform: rotate(360deg); }
}

@media (max-width: 980px) {
  .profile-shell { grid-template-columns: 1fr; }
  .profile-sidebar {
    position: relative;
    min-height: auto;
    gap: 22px;
    padding: 24px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .module-nav { grid-template-columns: repeat(3, 1fr); }
  .module-nav a { grid-template-columns: 28px 1fr; }
  .sidebar-card { display: none; }
  .profile-content { padding: 36px 28px 64px; }
  .skill-grid, .side-grid { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .cursor-glow { display: none; }
  .profile-shell {
    width: calc(100% - 20px);
    margin: 10px auto;
  }
  .profile-sidebar {
    gap: 14px;
    padding: 18px;
  }
  .brand {
    font-size: 24px;
  }
  .brand-mark {
    width: 38px;
    height: 38px;
  }
  .module-nav {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
  }
  .module-nav::-webkit-scrollbar {
    display: none;
  }
  .module-nav a {
    display: flex;
    flex: 0 0 auto;
    gap: 8px;
    min-height: 44px;
    padding: 8px 12px;
    border-radius: 22px;
  }
  .module-nav a span {
    font-size: 18px;
  }
  .module-nav a strong {
    font-size: 14px;
    white-space: nowrap;
  }
  .profile-content {
    gap: 64px;
    padding: 24px 16px 48px;
  }
  h1 { font-size: 36px; }
  h2 { font-size: 25px; }
  .intro-card,
  .journey-card,
  .project-card,
  .destination-card {
    grid-template-columns: 1fr;
    padding: 22px;
  }
  .command-stage,
  .company-mark { justify-self: start; }
  .command-stage {
    width: 100%;
    min-height: 260px;
  }
  .project-card strong {
    justify-self: start;
    text-align: left;
  }
  .contact-panel a { width: 100%; }
}

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