:root {
  color-scheme: dark;
  --bg-0: #03060a;
  --bg-1: #081019;
  --bg-2: #0c141d;
  --bg-3: #101b27;
  --panel: rgba(10, 16, 24, 0.78);
  --panel-strong: rgba(11, 18, 26, 0.92);
  --line: rgba(126, 155, 190, 0.14);
  --line-strong: rgba(126, 155, 190, 0.24);
  --text: #e7edf4;
  --text-soft: #c4d0dd;
  --muted: #8ea0b5;
  --blue: #4ec3ff;
  --green: #4bf0a8;
  --blue-soft: rgba(78, 195, 255, 0.16);
  --green-soft: rgba(75, 240, 168, 0.12);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
  --radius-xl: 28px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 14px;
  --container: 1160px;
  --header-height: 82px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(78, 195, 255, 0.1), transparent 34%),
    radial-gradient(circle at top right, rgba(75, 240, 168, 0.07), transparent 26%),
    linear-gradient(180deg, var(--bg-1) 0%, var(--bg-0) 38%, #020509 100%);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.55;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(circle at center, rgba(0, 0, 0, 0.84), transparent 92%);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 18%),
    radial-gradient(circle at 50% 0%, rgba(78, 195, 255, 0.04), transparent 22%);
}

img {
  display: block;
  max-width: 100%;
}

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

button,
input,
textarea {
  font: inherit;
}

.container {
  width: min(calc(100% - 32px), var(--container));
  margin-inline: auto;
}

.page-shell {
  position: relative;
  min-height: 100vh;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(126, 155, 190, 0.08);
  background: linear-gradient(180deg, rgba(3, 6, 10, 0.94), rgba(3, 6, 10, 0.72));
  backdrop-filter: blur(18px);
}

.nav {
  position: relative;
  min-height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  border: 1px solid rgba(78, 195, 255, 0.24);
  background: linear-gradient(135deg, rgba(78, 195, 255, 0.14), rgba(75, 240, 168, 0.08)), rgba(10, 16, 24, 0.88);
  color: var(--blue);
  font: 700 0.92rem/1 "JetBrains Mono", monospace;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
}

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

.brand-title {
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.brand-subtitle {
  color: var(--muted);
  font: 500 0.74rem/1.25 "JetBrains Mono", monospace;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 18px;
}

.nav-panel {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  position: relative;
  padding: 12px 14px;
  border-radius: 14px;
  color: var(--muted);
  font-weight: 500;
  transition: color 0.28s ease, background-color 0.28s ease, transform 0.28s ease;
}

.nav-link:hover,
.nav-link:focus-visible {
  color: var(--text);
  background: rgba(255, 255, 255, 0.03);
}

.nav-link[aria-current="page"] {
  color: var(--text);
}

.nav-indicator {
  position: absolute;
  left: 0;
  bottom: 2px;
  height: 2px;
  width: 56px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--blue), var(--green));
  box-shadow: 0 0 14px rgba(78, 195, 255, 0.35);
  opacity: 0;
  transform: translateX(0);
  transition: transform 0.48s cubic-bezier(.22,1,.36,1), width 0.48s cubic-bezier(.22,1,.36,1), opacity 0.32s ease;
}

.nav-indicator.is-ready {
  opacity: 1;
}

.header-line {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  overflow: hidden;
  pointer-events: none;
}

.header-line::before {
  content: "";
  position: absolute;
  top: 0;
  left: -30%;
  width: 30%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(78, 195, 255, 0.95), rgba(75, 240, 168, 0.95), transparent);
  opacity: 0.95;
  animation: headerSweep 1.15s cubic-bezier(.22,1,.36,1);
}

.page-shell.is-leaving .header-line::before {
  animation: headerSweep 0.6s cubic-bezier(.22,1,.36,1);
}

.nav-toggle {
  display: none;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(10, 16, 24, 0.88);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 999px;
  background: var(--text);
}

.site-main {
  position: relative;
}

.page-intro {
  padding-top: 44px;
  padding-bottom: 14px;
}

.command-line,
.comment-text,
.small-code,
.panel-title,
.field-prefix,
.tag-code,
.loader-text,
.loader-command,
.main-name,
.page-transition__text {
  font-family: "JetBrains Mono", "Fira Code", monospace;
}

.command-line {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--blue);
  font-size: 0.88rem;
}

.command-line .symbol {
  color: var(--green);
}

.page-title-wrap {
  max-width: 760px;
}

.page-title {
  margin: 18px 0 12px;
  font-size: clamp(2rem, 5vw, 4.1rem);
  line-height: 1;
  letter-spacing: -0.05em;
}

.page-lead {
  margin: 0;
  max-width: 720px;
  color: var(--text-soft);
  line-height: 1.8;
  font-size: 1.04rem;
}

.main-hero {
  min-height: calc(100vh - var(--header-height));
  display: grid;
  place-items: center;
  padding: 32px 0;
}

.main-stage {
  position: relative;
  width: min(100%, 900px);
  text-align: center;
  padding: 40px 20px;
}

.main-stage::before,
.main-stage::after {
  content: "";
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  border-radius: 50%;
}

.main-stage::before {
  width: min(70vw, 620px);
  aspect-ratio: 1;
  background: radial-gradient(circle, rgba(78, 195, 255, 0.09), transparent 62%);
  filter: blur(12px);
}

.main-stage::after {
  width: min(54vw, 420px);
  aspect-ratio: 1;
  background: radial-gradient(circle, rgba(75, 240, 168, 0.07), transparent 66%);
  filter: blur(8px);
}

.main-name-stack {
  position: relative;
  z-index: 1;
  display: grid;
  gap: clamp(2px, 1vw, 12px);
  justify-items: center;
}

.main-name {
  position: relative;
  display: inline-block;
  font-size: clamp(2.6rem, 11vw, 7.4rem);
  font-weight: 700;
  letter-spacing: -0.08em;
  line-height: 0.94;
  color: var(--text);
  text-transform: uppercase;
  padding: 0.02em 0.1em;
  transition: transform 0.35s ease, text-shadow 0.35s ease, color 0.35s ease;
}

.main-name::before {
  content: attr(data-ghost);
  position: absolute;
  inset: 0;
  z-index: -1;
  color: rgba(78, 195, 255, 0.12);
  transform: translate(7px, 6px);
  filter: blur(6px);
  opacity: 0.7;
}

.main-name:hover {
  transform: translateY(-3px) scale(1.01);
  text-shadow: 0 0 18px rgba(78, 195, 255, 0.14);
}

.main-name--accent:hover {
  color: #eef7ff;
  text-shadow: 0 0 18px rgba(75, 240, 168, 0.16);
}

.main-caret {
  width: min(100%, 430px);
  height: 18px;
  margin: 18px auto 0;
  position: relative;
  overflow: hidden;
  opacity: 0.85;
}

.main-caret::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(126,155,190,0.1), rgba(126,155,190,0.28), rgba(126,155,190,0.1), transparent);
}

.main-caret::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 80px;
  height: 2px;
  border-radius: 999px;
  transform: translateY(-50%);
  background: linear-gradient(90deg, transparent, var(--blue), var(--green), transparent);
  animation: coderPulse 3.8s ease-in-out infinite;
}

.main-subtle-enter {
  margin-top: 26px;
  color: var(--muted);
  font: 500 0.84rem/1.7 "JetBrains Mono", monospace;
  letter-spacing: 0.02em;
}

.main-subtle-enter a {
  color: var(--text-soft);
  transition: color 0.3s ease;
}

.main-subtle-enter a:hover {
  color: var(--text);
}

.about-layout,
.contact-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(24px, 5vw, 56px);
  align-items: start;
  padding-bottom: 72px;
}

.resume-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  padding-bottom: 72px;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  padding-bottom: 72px;
}

.panel,
.editor-shell,
.resume-column,
.project-card,
.contact-panel,
.contact-aside,
.info-strip {
  position: relative;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(13, 20, 28, 0.88), rgba(8, 13, 20, 0.76));
  box-shadow: var(--shadow);
}

.editor-shell,
.contact-panel,
.contact-aside,
.project-card {
  overflow: hidden;
}

.panel-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(126, 155, 190, 0.1);
  background: rgba(255, 255, 255, 0.02);
}

.panel-dots {
  display: inline-flex;
  gap: 8px;
}

.panel-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.24);
}

.panel-dots span:nth-child(1) { background: rgba(255, 111, 111, 0.9); }
.panel-dots span:nth-child(2) { background: rgba(255, 197, 92, 0.95); }
.panel-dots span:nth-child(3) { background: rgba(74, 222, 128, 0.95); }

.panel-title {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.2;
}

.editor-body,
.contact-panel-body,
.contact-aside-body,
.resume-column {
  padding: 22px;
}

.profile-frame {
  position: relative;
  width: min(100%, 240px);
  margin-inline: auto;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(126, 155, 190, 0.16);
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
}

.profile-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(78, 195, 255, 0.08), transparent 36%);
  pointer-events: none;
}

.profile-image {
  width: 100%;
  aspect-ratio: 0.84;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.02) brightness(0.96);
}

.profile-note {
  margin-top: 16px;
  color: var(--muted);
  line-height: 1.8;
  font-size: 0.95rem;
}

.side-tags,
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.side-tags {
  margin-top: 18px;
}

.tag {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(126, 155, 190, 0.16);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-soft);
  font-size: 0.84rem;
  font-weight: 500;
}

.tag-code {
  color: var(--blue);
}

.about-copy,
.contact-copy,
.resume-copy {
  padding-top: 6px;
}

.section-title {
  margin: 14px 0 14px;
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.section-lead,
.body-copy p,
.contact-copy p {
  color: var(--text-soft);
  line-height: 1.9;
}

.body-copy {
  display: grid;
  gap: 18px;
  margin-top: 22px;
}

.info-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 30px;
  padding: 22px;
}

.info-item {
  display: grid;
  gap: 6px;
}

.info-item .label {
  color: var(--muted);
  font: 500 0.8rem/1.3 "JetBrains Mono", monospace;
}

.info-item .value {
  font-size: 0.98rem;
  font-weight: 600;
  line-height: 1.65;
}

.column-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
}

.column-title {
  margin: 8px 0 0;
  font-size: 1.42rem;
  line-height: 1.1;
}

.timeline {
  position: relative;
  display: grid;
  gap: 22px;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 2px;
  bottom: 2px;
  left: 12px;
  width: 1px;
  background: linear-gradient(180deg, rgba(78, 195, 255, 0.26), rgba(75, 240, 168, 0.18));
}

.timeline-item {
  position: relative;
  padding-left: 38px;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 10px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--green));
  box-shadow: 0 0 12px rgba(78, 195, 255, 0.35);
}

.timeline-card {
  border-radius: 20px;
  padding: 18px 18px 18px 20px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(126, 155, 190, 0.12);
}

.timeline-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 12px;
}

.timeline-top h3 {
  margin: 0 0 6px;
  font-size: 1.08rem;
}

.timeline-role {
  color: var(--blue);
  font: 500 0.84rem/1.4 "JetBrains Mono", monospace;
}

.timeline-date {
  min-width: max-content;
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(126, 155, 190, 0.12);
  color: var(--text-soft);
  font: 500 0.78rem/1.2 "JetBrains Mono", monospace;
}

.timeline-card p {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.85;
}

.timeline-meta {
  margin-top: 12px !important;
  color: var(--muted) !important;
  font-size: 0.92rem;
}

.project-card {
  transition: transform 0.34s ease, border-color 0.34s ease, box-shadow 0.34s ease;
}

.project-card:hover,
.project-card:focus-within {
  transform: translateY(-4px);
  border-color: rgba(78, 195, 255, 0.24);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.34), 0 0 0 1px rgba(78, 195, 255, 0.06) inset;
}

.project-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(126, 155, 190, 0.1);
}

.project-path {
  color: var(--muted);
  font: 500 0.78rem/1.3 "JetBrains Mono", monospace;
}

.project-body {
  padding: 20px 18px 18px;
}

.project-title {
  margin: 0 0 10px;
  font-size: 1.24rem;
}

.project-desc {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.85;
}

.project-tags {
  margin-top: 16px;
}

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

.link-button,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 50px;
  padding: 0 18px;
  border-radius: 16px;
  transition: transform 0.28s ease, border-color 0.28s ease, background-color 0.28s ease, color 0.28s ease, box-shadow 0.28s ease;
}

.link-button {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(126, 155, 190, 0.14);
  color: var(--text-soft);
  font-weight: 500;
}

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

.link-button:hover,
.link-button:focus-visible {
  border-color: rgba(78, 195, 255, 0.22);
  color: var(--text);
}

.button {
  border: 1px solid transparent;
  cursor: pointer;
}

.button-primary {
  background: linear-gradient(135deg, rgba(78, 195, 255, 0.18), rgba(75, 240, 168, 0.14));
  border-color: rgba(78, 195, 255, 0.28);
  color: var(--text);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.26);
}

.button-secondary {
  background: rgba(255, 255, 255, 0.02);
  border-color: var(--line);
  color: var(--text-soft);
}

.button-secondary:hover,
.button-secondary:focus-visible {
  border-color: rgba(78, 195, 255, 0.22);
}

.contact-list {
  display: grid;
  gap: 14px;
}

.contact-item {
  padding: 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(126, 155, 190, 0.12);
}

.contact-item .k {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font: 500 0.8rem/1.4 "JetBrains Mono", monospace;
}

.contact-item .v {
  color: var(--text);
  line-height: 1.75;
}

.inline-code-block {
  margin-top: 18px;
  padding: 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(126, 155, 190, 0.12);
  color: var(--text-soft);
  font: 500 0.86rem/1.8 "JetBrains Mono", monospace;
  overflow-x: auto;
}

.contact-form {
  display: grid;
  gap: 16px;
}

.field-group {
  display: grid;
  gap: 8px;
}

.field-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-soft);
  font-size: 0.92rem;
  font-weight: 500;
}

.field-prefix {
  color: var(--blue);
}

.input,
.textarea {
  width: 100%;
  padding: 15px 16px;
  border-radius: 16px;
  border: 1px solid rgba(126, 155, 190, 0.16);
  background: rgba(5, 9, 14, 0.76);
  color: var(--text);
  outline: none;
  transition: border-color 0.28s ease, box-shadow 0.28s ease;
}

.input::placeholder,
.textarea::placeholder {
  color: #73879c;
}

.input:focus,
.textarea:focus {
  border-color: rgba(78, 195, 255, 0.35);
  box-shadow: 0 0 0 4px rgba(78, 195, 255, 0.08);
}

.textarea {
  min-height: 170px;
  resize: vertical;
}

.form-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.form-status {
  min-height: 24px;
  margin: 2px 0 0;
  line-height: 1.6;
  color: var(--muted);
}

.form-status.is-success {
  color: #9ae8c3;
}

.form-status.is-error {
  color: #ffb5b5;
}

.site-footer {
  padding: 20px 0 28px;
  border-top: 1px solid rgba(126, 155, 190, 0.08);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.footer-inner p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.comment-text {
  color: var(--green);
  font-size: 0.84rem;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.65s ease, transform 0.65s ease, filter 0.65s ease;
  filter: blur(6px);
}

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

.loader,
.page-transition {
  position: fixed;
  inset: 0;
  z-index: 110;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at top left, rgba(78, 195, 255, 0.08), transparent 32%),
    radial-gradient(circle at top right, rgba(75, 240, 168, 0.06), transparent 28%),
    rgba(3, 6, 10, 0.96);
  transition: opacity 0.55s ease, visibility 0.55s ease;
}

.loader {
  visibility: visible;
  opacity: 1;
}

body.is-loaded .loader {
  opacity: 0;
  visibility: hidden;
}

.page-transition {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.page-shell.is-leaving .page-transition {
  visibility: visible;
  opacity: 1;
}

.loader-box,
.page-transition__box {
  width: min(92vw, 540px);
  padding: 26px;
  border-radius: 24px;
  border: 1px solid var(--line);
  background: rgba(10, 16, 24, 0.86);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.38);
}

.loader-command,
.page-transition__text {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--blue);
  font-size: 0.86rem;
}

.loader-command .symbol,
.page-transition__text .symbol {
  color: var(--green);
}

.loader-text {
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.8;
  font-size: 0.95rem;
}

.loader-bar,
.page-transition__bar {
  position: relative;
  height: 8px;
  margin-top: 18px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05);
}

.loader-bar::before,
.page-transition__bar::before {
  content: "";
  position: absolute;
  inset: 0;
  width: 42%;
  background: linear-gradient(90deg, transparent, var(--blue), var(--green), transparent);
  animation: progressMove 1.6s ease-in-out infinite;
}

@keyframes progressMove {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(320%); }
}

@keyframes coderPulse {
  0%, 100% { transform: translate(-120%, -50%); opacity: 0.35; }
  50% { transform: translate(540%, -50%); opacity: 1; }
}

@keyframes headerSweep {
  0% { transform: translateX(0); }
  100% { transform: translateX(460%); }
}

@media (max-width: 1080px) {
  .about-layout,
  .resume-layout,
  .projects-grid,
  .contact-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  :root {
    --header-height: 74px;
  }

  .nav-toggle {
    display: inline-block;
  }

  .nav-right {
    gap: 10px;
  }

  .nav-panel {
    position: absolute;
    top: calc(100% + 10px);
    left: 16px;
    right: 16px;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border-radius: 22px;
    border: 1px solid var(--line);
    background: rgba(6, 10, 15, 0.96);
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.35);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity 0.28s ease, transform 0.28s ease;
  }

  .nav-panel.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .nav-link {
    padding: 14px 16px;
  }

  .nav-indicator {
    display: none;
  }

  .info-strip {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(calc(100% - 22px), var(--container));
  }

  .main-stage {
    padding: 20px 8px;
  }

  .main-name {
    letter-spacing: -0.07em;
  }

  .editor-body,
  .contact-panel-body,
  .contact-aside-body,
  .resume-column,
  .project-body {
    padding: 18px;
  }

  .panel-topbar,
  .project-head {
    padding: 14px 16px;
  }

  .timeline-top,
  .footer-inner,
  .form-actions,
  .project-actions {
    flex-direction: column;
    align-items: flex-start;
  }

  .button,
  .link-button {
    width: 100%;
  }
}

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

  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
    filter: none;
  }
}
.main-name-stack {
  perspective: 1000px;
  transform-style: preserve-3d;
}

.main-name {
  position: relative;
  will-change: transform, opacity, text-shadow, filter;
  transition:
    transform 0.18s ease,
    opacity 0.28s ease,
    text-shadow 0.28s ease,
    filter 0.28s ease,
    color 0.28s ease;
}

.main-name--focus {
  font-size: clamp(3.2rem, 12vw, 8.3rem);
  color: #f3f8ff;
  text-shadow:
    0 0 18px rgba(78, 195, 255, 0.12),
    0 0 36px rgba(78, 195, 255, 0.05);
  z-index: 2;
}

.main-name--ghost {
  opacity: 0.32;
  color: rgba(231, 237, 244, 0.72);
  filter: blur(0.15px);
  text-shadow: none;
  z-index: 1;
  animation: ghostErrorFlicker 4.8s steps(1) infinite;
}

.main-name--ghost::before {
  content: attr(data-ghost);
  position: absolute;
  inset: 0;
  z-index: -1;
  color: rgba(255, 95, 95, 0.18);
  transform: translate(8px, 3px);
  filter: blur(7px);
  opacity: 0.9;
}

.main-name--ghost::after {
  content: attr(data-ghost);
  position: absolute;
  inset: 0;
  z-index: -2;
  color: rgba(255, 95, 95, 0.10);
  transform: translate(-5px, 0);
  opacity: 0.8;
  animation: ghostErrorShift 2.6s steps(1) infinite;
}

.main-name-stack:hover .main-name--ghost {
  opacity: 0.42;
}

.main-name-stack:hover .main-name--focus {
  text-shadow:
    0 0 20px rgba(78, 195, 255, 0.16),
    0 0 42px rgba(78, 195, 255, 0.06);
}

@keyframes ghostErrorFlicker {
  0%, 100% {
    opacity: 0.32;
  }
  8% {
    opacity: 0.20;
  }
  10% {
    opacity: 0.38;
  }
  12% {
    opacity: 0.28;
  }
  34% {
    opacity: 0.32;
  }
  36% {
    opacity: 0.18;
  }
  38% {
    opacity: 0.40;
  }
  60% {
    opacity: 0.32;
  }
  62% {
    opacity: 0.24;
  }
  64% {
    opacity: 0.36;
  }
}

@keyframes ghostErrorShift {
  0%, 100% {
    transform: translate(-5px, 0);
  }
  18% {
    transform: translate(-7px, 1px);
  }
  20% {
    transform: translate(-2px, -1px);
  }
  22% {
    transform: translate(-5px, 0);
  }
  58% {
    transform: translate(-6px, 0);
  }
  60% {
    transform: translate(-1px, 1px);
  }
  62% {
    transform: translate(-5px, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .main-name--ghost,
  .main-name--ghost::after {
    animation: none !important;
  }
}
.about-copy .body-copy p {
  position: relative;
  color: var(--text-soft);
  line-height: 1.9;
}

.about-copy .body-copy .about-char {
  display: inline-block;
  opacity: 0.12;
  transform: translateY(0.08em);
  transition:
    opacity 0.18s ease,
    transform 0.18s ease,
    color 0.18s ease;
}

.about-copy .body-copy .about-char.is-visible {
  opacity: 1;
  transform: translateY(0);
  color: var(--text-soft);
}

.about-copy .body-copy .about-char.about-space {
  width: 0.34em;
}

@media (max-width: 640px) {
  .about-copy .body-copy .about-char {
    transform: translateY(0.12em);
  }
}

@media (prefers-reduced-motion: reduce) {
  .about-copy .body-copy .about-char {
    opacity: 1 !important;
    filter: none !important;
    transform: none !important;
  }
}