:root {
  color-scheme: dark;
  --bg: #090814;
  --bg-alt: #111022;
  --surface: rgba(16, 15, 29, 0.78);
  --surface-strong: rgba(22, 20, 38, 0.92);
  --surface-soft: rgba(255, 255, 255, 0.03);
  --text: #f7f3ff;
  --muted: #b8b0cd;
  --muted-soft: #8e87a9;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.14);
  --accent: #bd8cff;
  --accent-strong: #e7c0ff;
  --accent-alt: #8698ff;
  --accent-soft: rgba(189, 140, 255, 0.14);
  --accent-glow: rgba(189, 140, 255, 0.24);
  --interactive-start: #c6a5ff;
  --interactive-mid: #ba9bf0;
  --interactive-end: #efc9dd;
  --interactive-surface: rgba(189, 140, 255, 0.08);
  --interactive-border: rgba(231, 192, 255, 0.16);
  --interactive-glow: rgba(198, 165, 255, 0.24);
  --interactive-glow-strong: rgba(239, 201, 221, 0.2);
  --focus-ring: rgba(214, 174, 255, 0.34);
  --link-highlight: rgba(189, 140, 255, 0.14);
  --shadow: 0 20px 60px rgba(1, 0, 8, 0.45);
  --shadow-strong: 0 28px 90px rgba(0, 0, 0, 0.55);
  --hover-shadow: 0 22px 56px rgba(6, 2, 18, 0.28);
  --hover-glow: 0 0 0 1px rgba(189, 140, 255, 0.22), 0 18px 46px rgba(189, 140, 255, 0.1);
  --radius-xl: 30px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 14px;
  --content-width: min(1220px, calc(100% - 2rem));
  --section-space: clamp(4.5rem, 8vh, 7rem);
  --reveal-distance: 24px;
  --reveal-duration: 720ms;
  --reveal-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --section-opacity: 1;
  --section-scale: 1;
  --section-blur: 0px;
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #f9f6fc;
  --bg-alt: #f3edf7;
  --surface: rgba(255, 255, 255, 0.78);
  --surface-strong: rgba(255, 255, 255, 0.96);
  --surface-soft: rgba(100, 67, 160, 0.03);
  --text: #191326;
  --muted: #6f6784;
  --muted-soft: #8f85a4;
  --line: rgba(52, 31, 92, 0.09);
  --line-strong: rgba(52, 31, 92, 0.16);
  --accent: #b77ae8;
  --accent-strong: #d89bff;
  --accent-alt: #7c8cf4;
  --accent-soft: rgba(183, 122, 232, 0.1);
  --accent-glow: rgba(183, 122, 232, 0.15);
  --interactive-start: #c49aef;
  --interactive-mid: #cea8f3;
  --interactive-end: #f1cfde;
  --interactive-surface: rgba(183, 122, 232, 0.08);
  --interactive-border: rgba(183, 122, 232, 0.16);
  --interactive-glow: rgba(183, 122, 232, 0.18);
  --interactive-glow-strong: rgba(241, 207, 222, 0.18);
  --focus-ring: rgba(183, 122, 232, 0.24);
  --link-highlight: rgba(183, 122, 232, 0.1);
  --shadow: 0 18px 54px rgba(69, 39, 111, 0.1);
  --shadow-strong: 0 24px 80px rgba(69, 39, 111, 0.16);
  --hover-shadow: 0 18px 50px rgba(69, 39, 111, 0.12);
  --hover-glow: 0 0 0 1px rgba(183, 122, 232, 0.18), 0 18px 44px rgba(183, 122, 232, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(216, 148, 255, 0.1), transparent 30rem),
    radial-gradient(circle at 82% 10%, rgba(119, 138, 255, 0.1), transparent 28rem),
    linear-gradient(180deg, var(--bg) 0%, color-mix(in srgb, var(--bg), black 8%) 100%);
  color: var(--text);
  font-family: "Manrope", sans-serif;
  font-size: 16px;
  line-height: 1.72;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 220ms ease, background-color 220ms ease, box-shadow 220ms ease;
}

button,
input,
textarea {
  font: inherit;
}

input,
textarea {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--surface-strong), transparent 3%);
  color: var(--text);
  transition:
    border-color 250ms ease,
    box-shadow 250ms ease,
    background 250ms ease,
    transform 250ms ease;
}

input::placeholder,
textarea::placeholder {
  color: var(--muted-soft);
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

p,
ul,
figure {
  margin: 0;
}

ul {
  padding: 0;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Fraunces", serif;
  font-weight: 700;
  letter-spacing: -0.035em;
}

h1 {
  font-size: clamp(2.95rem, 5.7vw, 4.4rem);
  line-height: 0.98;
  max-width: 8.8ch;
}

h2 {
  font-size: clamp(1.85rem, 3.5vw, 2.65rem);
  line-height: 1.08;
  max-width: 12ch;
}

h3 {
  font-size: clamp(1.18rem, 1.8vw, 1.42rem);
  line-height: 1.16;
}

.skip-link {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 20;
  padding: 0.8rem 1rem;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  transform: translateY(-160%);
  transition: transform 180ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.page-shell {
  position: relative;
  overflow: hidden;
}

.ambient,
.grid-overlay {
  position: fixed;
  pointer-events: none;
  z-index: 0;
}

.ambient {
  border-radius: 999px;
  filter: blur(32px);
  opacity: 0.8;
  animation: drift 16s ease-in-out infinite;
}

.ambient-one {
  top: 4rem;
  right: -4rem;
  width: 20rem;
  height: 20rem;
  background: rgba(173, 120, 255, 0.18);
}

.ambient-two {
  left: -8rem;
  top: 36%;
  width: 24rem;
  height: 24rem;
  background: rgba(255, 178, 219, 0.14);
  animation-delay: -4s;
}

.ambient-three {
  right: 14%;
  bottom: 8rem;
  width: 16rem;
  height: 16rem;
  background: rgba(122, 160, 255, 0.14);
  animation-delay: -8s;
}

.grid-overlay {
  inset: 0;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 4.2rem 4.2rem;
  opacity: 0.12;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.95), transparent 95%);
}

.site-header,
main {
  position: relative;
  z-index: 1;
}

.site-header {
  position: sticky;
  top: 1rem;
  width: var(--content-width);
  margin: 1rem auto 0;
  padding: 0.95rem 1.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface-strong), transparent 10%);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(22px);
}

.brand {
  display: inline-flex;
  align-items: center;
  min-width: 0;
}

.brand-name {
  font-family: "Fraunces", serif;
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.04em;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem;
}

.site-nav a {
  position: relative;
  padding: 0.7rem 0.92rem;
  border-radius: 999px;
  font-size: 0.9rem;
  color: var(--muted);
  transition:
    color 250ms ease,
    background 250ms ease,
    border-color 250ms ease,
    box-shadow 250ms ease,
    transform 250ms ease;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0.92rem;
  right: 0.92rem;
  bottom: 0.34rem;
  height: 1.5px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--interactive-start), var(--interactive-mid), var(--interactive-end));
  opacity: 0;
  transform: scaleX(0.65);
  transform-origin: center;
  transition: opacity 250ms ease, transform 250ms ease;
}

.site-nav a:hover,
.site-nav a.is-active {
  color: var(--text);
  background: color-mix(in srgb, var(--interactive-surface), transparent 10%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--interactive-border), transparent 35%), 0 0 18px rgba(189, 140, 255, 0.08);
}

.site-nav a:hover::after,
.site-nav a.is-active::after {
  opacity: 1;
  transform: scaleX(1);
}

.theme-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  width: 5rem;
  min-height: 2.8rem;
  padding: 0.3rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface), transparent 3%);
  color: var(--muted);
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition:
    transform 250ms ease,
    border-color 250ms ease,
    box-shadow 250ms ease,
    background 250ms ease;
}

.theme-toggle:hover {
  transform: translateY(-1px);
  border-color: color-mix(in srgb, var(--interactive-start), var(--line) 62%);
  box-shadow: 0 10px 24px rgba(12, 7, 26, 0.22), 0 0 0 1px rgba(198, 165, 255, 0.08);
}

.theme-toggle-knob {
  position: absolute;
  left: 0.35rem;
  width: 2.05rem;
  height: 2.05rem;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 32%, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.22) 38%, transparent 42%),
    linear-gradient(135deg, var(--interactive-start), var(--interactive-mid), var(--interactive-end));
  box-shadow: 0 10px 22px rgba(136, 93, 212, 0.28), 0 0 18px rgba(214, 174, 255, 0.18);
  transition: transform 250ms ease, box-shadow 250ms ease;
}

html[data-theme="light"] .theme-toggle-knob {
  transform: translateX(0);
}

html[data-theme="dark"] .theme-toggle-knob {
  transform: translateX(2.15rem);
}

.theme-toggle-copy {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

main {
  width: var(--content-width);
  margin: 0 auto;
  padding-bottom: 5rem;
}

.section {
  padding: var(--section-space) 0;
  min-height: clamp(44rem, 94vh, 72rem);
  opacity: var(--section-opacity);
  transform: scale(var(--section-scale));
  filter: blur(var(--section-blur));
  transform-origin: center top;
  transition:
    opacity 520ms var(--reveal-ease),
    transform 520ms var(--reveal-ease),
    filter 520ms var(--reveal-ease);
}

.section + .section {
  margin-top: clamp(1rem, 3vh, 2.25rem);
}

section[id] {
  scroll-margin-top: 6.5rem;
}

.hero {
  min-height: max(calc(100vh - 6rem), 46rem);
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(25rem, 1.05fr);
  gap: clamp(2rem, 4vw, 4rem);
  align-items: center;
}

.intro-pill,
.eyebrow,
.summary-kicker,
.summary-label,
.card-label,
.project-kicker,
.project-meta,
.timeline-date,
.timeline-org {
  color: var(--muted);
}

.intro-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  width: fit-content;
  padding: 0.6rem 0.9rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface-soft), transparent 2%);
  font-size: 0.84rem;
  margin-bottom: 1rem;
}

.intro-pill-dot {
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  box-shadow: 0 0 12px var(--accent-glow);
}

.eyebrow,
.summary-kicker,
.card-label {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero-copy .eyebrow {
  margin-bottom: 0.65rem;
}

.gradient-text {
  background: linear-gradient(135deg, var(--accent-strong), var(--accent), #f9d0ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lead,
.section-intro,
.project-problem,
.project-impact,
.contact-details a,
.contact-details p,
.summary-grid p {
  font-size: 0.95rem;
  color: var(--muted);
}

.hero-title-line {
  margin-top: 1rem;
  max-width: 34rem;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.55;
  color: color-mix(in srgb, var(--text), var(--muted) 24%);
}

.hero-lead {
  max-width: 36rem;
  margin-top: 0.9rem;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 2rem;
}

.button,
.project-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.2rem;
  padding: 0.9rem 1.3rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.96rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition:
    transform 250ms ease,
    box-shadow 250ms ease,
    background 250ms ease,
    border-color 250ms ease,
    color 250ms ease,
    filter 250ms ease;
}

.button:hover,
.project-link:hover,
.skill-badges span:hover,
.tech-badges span:hover {
  transform: translateY(-2px);
}

.button-primary {
  border-color: color-mix(in srgb, var(--interactive-border), transparent 20%);
  background: linear-gradient(135deg, var(--interactive-start) 0%, var(--interactive-mid) 52%, var(--interactive-end) 100%);
  color: #1d1431;
  box-shadow:
    0 12px 26px rgba(108, 72, 184, 0.26),
    0 18px 38px rgba(239, 201, 221, 0.08),
    0 0 0 1px rgba(255, 255, 255, 0.04);
}

.button-secondary,
.button-ghost,
.project-link {
  background: color-mix(in srgb, var(--surface), transparent 6%);
  border-color: color-mix(in srgb, var(--interactive-start), var(--line) 72%);
  color: var(--text);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.button:hover,
.button:focus-visible,
.project-link:hover,
.project-link:focus-visible {
  border-color: color-mix(in srgb, var(--interactive-start), var(--line) 42%);
  box-shadow: var(--hover-glow);
}

.button-primary:hover,
.button-primary:focus-visible {
  transform: translateY(-2px);
  filter: brightness(1.04);
  box-shadow:
    0 14px 28px rgba(108, 72, 184, 0.28),
    0 22px 48px rgba(239, 201, 221, 0.14),
    0 0 0 1px rgba(255, 255, 255, 0.08);
}

.button-secondary:hover,
.button-secondary:focus-visible,
.button-ghost:hover,
.button-ghost:focus-visible,
.project-link:hover,
.project-link:focus-visible {
  transform: translateY(-2px);
  background: color-mix(in srgb, var(--interactive-surface), var(--surface) 72%);
  box-shadow:
    0 14px 30px rgba(10, 5, 22, 0.18),
    0 0 0 1px rgba(198, 165, 255, 0.1);
}

html[data-theme="light"] .button-primary {
  color: #2a1641;
}

.hero-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
  margin-top: 2rem;
}

.hero-facts article,
.summary-card,
.panel-card,
.project-card,
.contact-card,
.hero-preview,
.floating-chip {
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: color-mix(in srgb, var(--surface), transparent 2%);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
  transition:
    transform 250ms ease,
    border-color 250ms ease,
    box-shadow 250ms ease,
    background 250ms ease;
}

.hero-facts article {
  display: grid;
  gap: 0.3rem;
  padding: 1rem 1.1rem;
  border-radius: var(--radius-lg);
}

.hero-facts article:hover,
.hero-facts article:focus-within,
.summary-card:hover,
.summary-card:focus-within,
.panel-card:hover,
.panel-card:focus-within,
.contact-card:hover,
.contact-card:focus-within {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--interactive-start), var(--line) 56%);
  box-shadow:
    0 20px 42px rgba(6, 2, 18, 0.22),
    0 0 0 1px rgba(198, 165, 255, 0.12);
}

.hero-preview:hover,
.floating-chip:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--interactive-start), var(--line) 54%);
  box-shadow:
    0 24px 54px rgba(4, 1, 12, 0.3),
    0 0 0 1px rgba(198, 165, 255, 0.14),
    0 0 28px rgba(214, 174, 255, 0.12);
}

.hero-facts strong {
  font-size: 0.95rem;
  font-weight: 800;
}

.hero-facts span {
  font-size: 0.88rem;
  color: var(--muted);
}

.hero-visual {
  position: relative;
  min-height: 36rem;
}

.hero-glow {
  position: absolute;
  inset: 15% 10% 10% 15%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(191, 126, 255, 0.18), transparent 68%);
  filter: blur(22px);
  animation: pulseGlow 7s ease-in-out infinite;
}

.hero-orbit {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.66;
}

.hero-orbit path {
  stroke: color-mix(in srgb, var(--accent), white 18%);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 5 10;
  fill: none;
  animation: orbitDrift 14s linear infinite;
}

.sparkle-cluster {
  position: absolute;
  inset: 0;
}

.sparkle {
  position: absolute;
  display: inline-block;
  transform: rotate(45deg);
  filter: drop-shadow(0 0 10px var(--accent-glow));
}

.sparkle::before,
.sparkle::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  transform: translate(-50%, -50%);
}

.sparkle::before {
  width: 2px;
  height: 100%;
}

.sparkle::after {
  width: 100%;
  height: 2px;
}

.sparkle {
  width: 1rem;
  height: 1rem;
  opacity: 0.82;
  animation: twinkle 3.8s ease-in-out infinite;
}

.sparkle-one {
  right: 12%;
  top: 14%;
}

.sparkle-two {
  right: 26%;
  top: 22%;
  animation-delay: -1s;
}

.sparkle-three {
  right: 20%;
  top: 40%;
  animation-delay: -2s;
}

.sparkle-four {
  left: 18%;
  top: 31%;
  animation-delay: -3s;
}

.sparkle-five {
  right: 34%;
  top: 10%;
  animation-delay: -1.7s;
}

.sparkle-six {
  right: 8%;
  top: 33%;
  animation-delay: -2.7s;
}

.hero-preview {
  position: absolute;
  right: 6%;
  bottom: 10%;
  z-index: 2;
  width: min(25.5rem, 67%);
  padding: 0.9rem;
  border-radius: 28px;
  overflow: hidden;
  border-color: color-mix(in srgb, var(--interactive-start), var(--line) 72%);
  box-shadow:
    0 18px 50px rgba(0, 0, 0, 0.24),
    0 0 0 1px rgba(198, 165, 255, 0.08),
    0 0 34px rgba(189, 140, 255, 0.1);
  animation: floatCard 10s ease-in-out infinite, previewGlow 6s ease-in-out infinite;
}

.preview-topbar {
  display: flex;
  gap: 0.35rem;
  margin-bottom: 0.85rem;
}

.preview-topbar span {
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
}

.hero-preview img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: calc(var(--radius-lg) - 2px);
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg-alt), black 10%);
  box-shadow: 0 0 0 1px rgba(231, 192, 255, 0.05), 0 18px 36px rgba(0, 0, 0, 0.16);
  object-fit: contain;
  object-position: center center;
  image-rendering: auto;
}

.floating-chip {
  position: absolute;
  z-index: 3;
  width: fit-content;
  max-width: 20rem;
  padding: 0.85rem 1rem;
  border-radius: 20px;
  border-color: color-mix(in srgb, var(--interactive-start), var(--line) 76%);
  background:
    linear-gradient(160deg, color-mix(in srgb, var(--surface-strong), transparent 6%), color-mix(in srgb, var(--interactive-surface), transparent 58%));
  box-shadow:
    0 18px 42px rgba(5, 2, 14, 0.24),
    0 0 0 1px rgba(198, 165, 255, 0.06);
}

.floating-chip p:last-child {
  font-size: 0.83rem;
  color: color-mix(in srgb, var(--text), var(--muted) 22%);
}

.floating-chip-top {
  right: 1%;
  top: 8%;
  animation: floatCard 9s ease-in-out infinite, chipGlow 5.5s ease-in-out infinite;
}

.floating-chip-bottom {
  left: -1%;
  bottom: 7%;
  animation: floatCard 11s ease-in-out infinite, chipGlow 6.5s ease-in-out infinite;
  animation-delay: -3s;
}

.hero-tech-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.45rem;
}

.hero-tech-badges span {
  padding: 0.4rem 0.68rem;
  border: 1px solid color-mix(in srgb, var(--interactive-start), var(--line) 62%);
  border-radius: 999px;
  background: color-mix(in srgb, var(--interactive-surface), transparent 12%);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: color-mix(in srgb, var(--text), var(--accent-strong) 10%);
  transition:
    transform 250ms ease,
    border-color 250ms ease,
    background 250ms ease,
    box-shadow 250ms ease,
    color 250ms ease;
}

.recruiter-strip {
  min-height: clamp(26rem, 56vh, 36rem);
  padding-top: clamp(2rem, 4vh, 3rem);
  justify-content: center;
}

.summary-card,
.panel-card,
.contact-card {
  padding: 1.45rem;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.15rem;
  margin-top: 1rem;
}

.summary-grid div {
  display: grid;
  gap: 0.25rem;
}

.summary-label {
  font-size: 0.73rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.section-heading {
  display: grid;
  gap: 0.65rem;
  margin-bottom: 1.85rem;
}

.section-intro {
  max-width: 41rem;
  line-height: 1.78;
}

.split-layout,
.skills-layout,
.education-grid,
.achievement-grid,
.contact-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  align-items: start;
}

.accent-card {
  background:
    linear-gradient(145deg, color-mix(in srgb, var(--accent-soft), transparent 8%), color-mix(in srgb, var(--surface-strong), transparent 0%));
}

.feature-list,
.card-list,
.project-points {
  list-style: none;
  display: grid;
  gap: 0.8rem;
}

.feature-list li,
.card-list li,
.project-points li {
  position: relative;
  padding-left: 1rem;
  font-size: 0.93rem;
  color: color-mix(in srgb, var(--text), var(--muted) 18%);
}

.feature-list-compact li,
.project-points li {
  font-size: 0.9rem;
}

.feature-list li::before,
.card-list li::before,
.project-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.68rem;
  width: 0.38rem;
  height: 0.38rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  box-shadow: 0 0 10px var(--accent-glow);
}

.skill-group h3 {
  margin-bottom: 0.8rem;
}

.skill-badges,
.tech-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.skill-badges span,
.tech-badges span {
  padding: 0.58rem 0.88rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface-soft), transparent 2%);
  font-size: 0.83rem;
  color: var(--muted);
  transition:
    transform 250ms ease,
    border-color 250ms ease,
    background 250ms ease,
    color 250ms ease,
    box-shadow 250ms ease;
}

.skill-badges span:hover,
.tech-badges span:hover {
  transform: translateY(-1px);
  border-color: color-mix(in srgb, var(--interactive-start), var(--line) 48%);
  background: color-mix(in srgb, var(--interactive-surface), transparent 16%);
  color: color-mix(in srgb, var(--text), var(--accent-strong) 12%);
  box-shadow: 0 12px 22px rgba(8, 4, 20, 0.12), 0 0 0 1px rgba(198, 165, 255, 0.08);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 1rem;
}

.project-card {
  display: grid;
  gap: 0.88rem;
  padding: 1.45rem;
  align-content: start;
  min-height: 100%;
  grid-auto-rows: max-content;
}

.project-card:hover {
  transform: translateY(-2px);
  box-shadow:
    0 24px 52px rgba(4, 1, 12, 0.28),
    0 0 0 1px rgba(198, 165, 255, 0.12);
  border-color: color-mix(in srgb, var(--interactive-start), var(--line) 54%);
}

.project-card-featured {
  grid-column: span 7;
  background:
    linear-gradient(150deg, color-mix(in srgb, var(--accent-soft), transparent 6%), color-mix(in srgb, var(--surface-strong), transparent 0%));
}

.projects-grid > :not(.project-card-featured) {
  grid-column: span 5;
}

.projects-grid > .project-card:last-child {
  grid-column: span 12;
}

.project-topline,
.timeline-topline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.project-kicker,
.project-meta,
.timeline-date,
.timeline-org,
.summary-label,
.card-label {
  font-size: 0.74rem;
}

.project-meta,
.timeline-date {
  color: var(--muted-soft);
}

.project-problem {
  font-size: 0.92rem;
}

.project-media {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius-lg) - 2px);
  background: color-mix(in srgb, var(--surface-strong), transparent 6%);
}

.project-media img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  object-fit: contain;
  background: color-mix(in srgb, var(--bg-alt), black 10%);
}

.project-impact {
  font-size: 0.91rem;
}

.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: auto;
}

.project-link {
  min-height: 2.9rem;
  font-size: 0.87rem;
}

.timeline-grid {
  display: grid;
  gap: 1rem;
}

.timeline-item {
  position: relative;
  overflow: hidden;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0.36rem;
  background: linear-gradient(180deg, var(--accent), var(--accent-alt));
}

.timeline-role {
  font-size: 1.02rem;
  font-weight: 800;
}

.contact-shell {
  display: grid;
}

.contact-card {
  background:
    linear-gradient(150deg, color-mix(in srgb, var(--surface-strong), transparent 8%), color-mix(in srgb, var(--accent-soft), transparent 72%));
}

.contact-details {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.35rem;
}

.contact-details a,
.contact-details p {
  width: fit-content;
}

.contact-details a {
  border-radius: 0.55rem;
  padding: 0.08rem 0.22rem;
  margin-left: -0.22rem;
  transition:
    color 250ms ease,
    background 250ms ease,
    box-shadow 250ms ease,
    border-color 250ms ease;
}

.contact-details a:hover {
  color: color-mix(in srgb, var(--text), white 8%);
  background: color-mix(in srgb, var(--link-highlight), transparent 10%);
  box-shadow: 0 0 0 1px rgba(198, 165, 255, 0.08);
}

.contact-side {
  background: color-mix(in srgb, var(--surface-strong), transparent 3%);
}

.js [data-reveal] {
  opacity: 0;
  translate: 0 var(--reveal-distance);
  transition:
    opacity var(--reveal-duration) var(--reveal-ease),
    translate var(--reveal-duration) var(--reveal-ease);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, translate;
}

.js [data-reveal].is-visible {
  opacity: 1;
  translate: 0 0;
}

:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--interactive-mid), white 8%);
  outline-offset: 3px;
  box-shadow: 0 0 0 5px var(--focus-ring);
}

input:focus-visible,
textarea:focus-visible {
  border-color: color-mix(in srgb, var(--interactive-mid), var(--line) 36%);
  background: color-mix(in srgb, var(--surface-strong), var(--interactive-surface) 12%);
  transform: translateY(-1px);
}

@keyframes drift {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(0, 20px, 0) scale(1.03);
  }
}

@keyframes floatCard {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

@keyframes twinkle {
  0%,
  100% {
    opacity: 0.42;
    transform: rotate(45deg) scale(0.88);
  }
  50% {
    opacity: 1;
    transform: rotate(45deg) scale(1.28);
  }
}

@keyframes pulseGlow {
  0%,
  100% {
    opacity: 0.5;
    transform: scale(0.96);
  }
  50% {
    opacity: 0.9;
    transform: scale(1.04);
  }
}

@keyframes orbitDrift {
  0% {
    stroke-dashoffset: 0;
    opacity: 0.45;
  }
  50% {
    opacity: 1;
  }
  100% {
    stroke-dashoffset: -180;
    opacity: 0.45;
  }
}

@keyframes previewGlow {
  0%,
  100% {
    box-shadow:
      0 18px 46px rgba(0, 0, 0, 0.22),
      0 0 0 1px rgba(198, 165, 255, 0.08),
      0 0 26px rgba(189, 140, 255, 0.08);
  }
  50% {
    box-shadow:
      0 28px 76px rgba(8, 3, 20, 0.28),
      0 0 0 1px rgba(198, 165, 255, 0.14),
      0 0 42px rgba(189, 140, 255, 0.18);
  }
}

@keyframes chipGlow {
  0%,
  100% {
    box-shadow:
      0 18px 42px rgba(0, 0, 0, 0.22),
      0 0 0 1px rgba(198, 165, 255, 0.06);
  }
  50% {
    box-shadow:
      0 22px 54px rgba(8, 3, 20, 0.24),
      0 0 0 1px rgba(198, 165, 255, 0.1),
      0 0 26px rgba(189, 140, 255, 0.12);
  }
}

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

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

  .js [data-reveal] {
    opacity: 1;
    translate: 0 0;
    will-change: auto;
  }

  .section {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }
}

@media (max-width: 1100px) {
  :root {
    --section-space: clamp(3.5rem, 7vh, 5.25rem);
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .hero-visual {
    min-height: 33rem;
  }

  .project-card-featured,
  .projects-grid > :not(.project-card-featured) {
    grid-column: span 6;
  }

  .projects-grid > .project-card:last-child {
    grid-column: span 12;
  }

  .summary-grid,
  .hero-facts,
  .split-layout,
  .skills-layout,
  .education-grid,
  .achievement-grid,
  .contact-layout {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .site-header {
    border-radius: 30px;
    padding: 1rem;
    align-items: flex-start;
    flex-direction: column;
  }

  .header-actions {
    width: 100%;
    align-items: stretch;
    flex-direction: column;
  }

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

  .theme-toggle {
    align-self: flex-start;
  }

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

  .hero-preview {
    right: 4%;
    width: min(23rem, 72%);
  }

  .floating-chip-top {
    right: 0;
    top: 3%;
  }

  .floating-chip-bottom {
    left: 0;
    bottom: 3%;
    max-width: 16rem;
  }

  .project-card-featured,
  .projects-grid > :not(.project-card-featured),
  .projects-grid > .project-card:last-child,
  .summary-grid,
  .hero-facts,
  .split-layout,
  .skills-layout,
  .education-grid,
  .achievement-grid,
  .contact-layout {
    grid-column: auto;
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  :root {
    --content-width: min(100% - 1rem, 1220px);
    --section-space: clamp(3rem, 7vh, 4.25rem);
  }

  .section {
    min-height: auto;
  }

  .section + .section {
    margin-top: 0.75rem;
  }

  h1 {
    font-size: clamp(2.45rem, 11vw, 3.45rem);
  }

  h2 {
    font-size: clamp(1.62rem, 7vw, 2rem);
    max-width: 14ch;
  }

  .site-nav {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.3rem;
  }

  .site-nav a {
    min-width: 0;
    text-align: center;
    font-size: 0.84rem;
    padding-inline: 0.6rem;
  }

  .hero-actions,
  .project-links {
    flex-direction: row;
  }

  .button,
  .project-link {
    flex: 1 1 12rem;
    width: auto;
  }

  .hero-visual {
    min-height: auto;
    padding-top: 1rem;
    padding-bottom: 6rem;
  }

  .hero-preview {
    position: relative;
    right: auto;
    left: auto;
    width: 100%;
    bottom: auto;
    margin: 0 auto;
  }

  .floating-chip-top {
    top: 0;
    right: 0;
  }

  .floating-chip-bottom {
    left: 0;
    bottom: 0;
    max-width: 100%;
  }

  .hero-tech-badges span {
    font-size: 0.68rem;
  }

  .summary-card,
  .panel-card,
  .project-card,
  .contact-card {
    padding: 1.2rem;
  }
}
