:root {
  color-scheme: dark light;
  --bg: #070502;
  --surface: rgba(255, 255, 255, 0.08);
  --surface-strong: rgba(255, 255, 255, 0.12);
  --text: #f3ece2;
  --muted: #d4c4b3;
  --accent: #c99f74;
  --accent-strong: #a9652a;
  --border: rgba(255, 255, 255, 0.12);
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.28);
  --panel: rgba(12, 8, 4, 0.72);
  --font: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f8f2eb;
    --surface: rgba(24, 20, 18, 0.06);
    --surface-strong: rgba(24, 20, 18, 0.12);
    --text: #1d1812;
    --muted: #5f4c3c;
    --accent: #7e5e47;
    --accent-strong: #5b3c23;
    --border: rgba(29, 24, 18, 0.12);
    --shadow: 0 28px 80px rgba(29, 24, 18, 0.14);
    --panel: rgba(255, 255, 255, 0.88);
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  background: radial-gradient(circle at top left, rgba(201, 159, 116, 0.18), transparent 18%), radial-gradient(circle at bottom right, rgba(46, 32, 22, 0.3), transparent 22%), linear-gradient(180deg, var(--bg) 0%, #1f1910 100%);
  color: var(--text);
  line-height: 1.75;
}

body::selection {
  background: rgba(201, 159, 116, 0.22);
  color: var(--text);
}

.cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.95) 0%, rgba(255, 226, 175, 0.65) 35%, rgba(201, 159, 116, 0.28) 62%, transparent 90%);
  box-shadow: 0 0 24px rgba(255, 221, 141, 0.55), 0 0 60px rgba(218, 147, 87, 0.28), 0 0 120px rgba(255, 255, 255, 0.1);
  pointer-events: none;
  transform: translate(-50%, -50%);
  transition: width 0.24s ease, height 0.24s ease, filter 0.24s ease, box-shadow 0.24s ease;
  z-index: 9999;
}

.cursor.active {
  width: 50px;
  height: 50px;
  filter: blur(0.3px);
  box-shadow: 0 0 42px rgba(255, 221, 141, 0.85), 0 0 96px rgba(218, 147, 87, 0.45);
}

.cursor-trail {
  position: fixed;
  top: 0;
  left: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.85) 0%, rgba(255, 179, 111, 0.4) 35%, transparent 70%);
  pointer-events: none;
  transform: translate(-50%, -50%);
  mix-blend-mode: screen;
  filter: blur(1px);
  z-index: 9998;
}

.cursor-trail::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: inherit;
  opacity: 0.8;
}

.smoke-particle {
  position: fixed;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, rgba(255, 247, 226, 0.75) 0%, rgba(214, 184, 143, 0.25) 45%, transparent 70%);
  mix-blend-mode: screen;
  filter: blur(2px);
  z-index: 9997;
}

.site-header {
  position: sticky;
  top: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 22px 36px;
  background: rgba(15, 11, 8, 0.78);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border);
  z-index: 10;
}

.logo {
  font-size: 1rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
}

.site-nav {
  display: flex;
  gap: 24px;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

.site-nav a:hover,
.site-nav a:focus {
  color: var(--text);
}

.hero {
  min-height: calc(100vh - 92px);
  display: grid;
  align-items: center;
  gap: 48px;
  padding: 0 32px 80px;
  position: relative;
  overflow: hidden;
}

.hero-copy {
  max-width: 720px;
  text-align: left;
}

.hero .eyebrow {
  margin: 0 0 18px;
  text-transform: uppercase;
  letter-spacing: 0.3em;
  color: var(--accent);
  font-size: 0.82rem;
}

.hero h1 {
  margin: 0;
  font-size: clamp(3.2rem, 5vw, 5rem);
  line-height: 0.95;
  max-width: 10ch;
}

.hero h1 span {
  color: var(--accent-strong);
}

.hero-text {
  margin: 24px 0 32px;
  max-width: 720px;
  color: var(--muted);
  font-size: 1.05rem;
}

.hero-blob {
  position: absolute;
  right: -6vw;
  top: 10vh;
  width: min(42vw, 440px);
  height: min(42vw, 440px);
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(32px);
}

.blob-large {
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 15% 20%, rgba(201, 159, 116, 0.35), transparent 40%), radial-gradient(circle at 80% 35%, rgba(255, 255, 255, 0.18), transparent 32%);
}

.blob-small {
  width: 60%;
  height: 60%;
  bottom: -18%;
  right: 0;
  background: radial-gradient(circle at 45% 30%, rgba(33, 24, 18, 0.46), transparent 42%), radial-gradient(circle at 40% 75%, rgba(255, 255, 255, 0.12), transparent 48%);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 30px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(201, 159, 116, 1), rgba(169, 101, 42, 1));
  color: #121107;
  text-decoration: none;
  font-weight: 700;
  box-shadow: 0 18px 60px rgba(201, 159, 116, 0.22);
}

.btn.secondary {
  background: transparent;
  color: var(--accent);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.section {
  padding: 88px 32px;
}

.section h2 {
  margin: 0 0 20px;
  font-size: clamp(2rem, 3vw, 3rem);
}

.section p {
  color: var(--muted);
  max-width: 760px;
}

.section-content {
  max-width: 900px;
  margin: 0 auto;
}

.about-grid,
.stats-grid,
.skill-grid,
.project-grid,
.experience-list {
  display: grid;
  gap: 22px;
}

.about-grid {
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  margin: 28px 0 32px;
}

.about-card,
.stats-grid div,
.skill-grid div,
.project-grid article,
.experience-list article {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: 28px;
  box-shadow: var(--shadow);
}

.about-card h3,
.project-grid article h3,
.experience-list article h3 {
  margin: 0 0 14px;
  color: var(--text);
}

.about-card p,
.project-grid article p,
.experience-list article p {
  margin: 0 0 14px;
  color: var(--muted);
}

.stats-grid {
  grid-template-columns: repeat(3, minmax(140px, 1fr));
}

.stats-grid strong,
.skill-grid strong {
  display: block;
  font-size: 1.85rem;
  color: var(--text);
}

.stats-grid span,
.skill-grid span,
.project-grid span,
.experience-list span {
  display: block;
  margin-top: 12px;
  color: var(--muted);
}

.skill-grid {
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  margin-top: 32px;
}

.project-grid {
  grid-template-columns: repeat(3, minmax(240px, 1fr));
  margin-top: 32px;
}

.footer {
  text-align: center;
  padding: 24px 32px 44px;
  color: var(--muted);
}

.notfound-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 40px 20px;
  background: linear-gradient(180deg, rgba(7, 5, 2, 0.95), rgba(31, 25, 17, 0.95));
}

.notfound-page div {
  text-align: center;
  max-width: 520px;
  padding: 40px;
  border-radius: 32px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: var(--shadow);
}

.notfound-page h1 {
  margin: 0 0 18px;
  font-size: clamp(4rem, 8vw, 6rem);
  color: var(--accent);
}

.notfound-page p {
  margin: 0 0 28px;
  color: var(--text);
  font-size: 1.1rem;
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    text-align: left;
  }
  .hero-blob {
    position: relative;
    width: 100%;
    height: 300px;
    margin-top: 28px;
    right: unset;
    top: unset;
  }
  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .about-grid,
  .project-grid,
  .skill-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .site-nav {
    flex-wrap: wrap;
  }
  .section {
    padding: 64px 20px;
  }
}
