﻿:root {
  --bg: #efe4d2;
  --bg-soft: #e7d8c1;
  --panel: rgba(255, 251, 245, 0.84);
  --panel-strong: rgba(255, 248, 238, 0.94);
  --text: #2f241b;
  --muted: #6f5d4d;
  --line: rgba(75, 56, 40, 0.14);
  --line-strong: rgba(75, 56, 40, 0.24);
  --accent: #9c7757;
  --accent-strong: #6d4f36;
  --shadow: 0 22px 70px rgba(106, 78, 54, 0.12);
  --ambient-glyph: rgba(83, 66, 51, 0.447);
  --ambient-mark: rgba(109, 79, 54, 0.24);
  --ambient-glow-1: rgba(255, 255, 255, 0.22);
  --ambient-glow-2: rgba(255, 255, 255, 0.12);
  --ambient-glow-3: rgba(207, 174, 136, 0.07);
  --theme-chip-bg: rgba(255, 251, 245, 0.82);
}

body[data-theme="dark"] {
  --bg: #1f1712;
  --bg-soft: #2b211a;
  --panel: rgba(39, 29, 22, 0.88);
  --panel-strong: rgba(46, 35, 27, 0.95);
  --text: #f0e3d3;
  --muted: #b8a18a;
  --line: rgba(214, 189, 162, 0.12);
  --line-strong: rgba(214, 189, 162, 0.22);
  --accent: #c49c73;
  --accent-strong: #e2b98a;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.34);
  --ambient-glyph: rgba(224, 199, 171, 0.12);
  --ambient-mark: rgba(238, 211, 178, 0.18);
  --ambient-glow-1: rgba(238, 220, 200, 0.11);
  --ambient-glow-2: rgba(196, 156, 115, 0.09);
  --ambient-glow-3: rgba(120, 87, 58, 0.08);
  --theme-chip-bg: rgba(51, 39, 30, 0.88);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 104px;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #f7efe3 0%, var(--bg) 42%, var(--bg-soft) 100%);
  transition: background 220ms ease, color 220ms ease;
}

body[data-theme="dark"] {
  background: linear-gradient(180deg, #17110d 0%, var(--bg) 42%, var(--bg-soft) 100%);
}

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

.noise,
.ambient-glyphs,
.ambient-glyph {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

.noise {
  z-index: 0;
  opacity: 0.1;
  background-image:
    radial-gradient(circle, rgba(72, 53, 38, 0.14) 0.75px, transparent 0.9px),
    linear-gradient(rgba(72, 53, 38, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(72, 53, 38, 0.06) 1px, transparent 1px);
  background-position: 0 0, 11px 11px, 11px 11px;
  background-size: 22px 22px, 88px 88px, 88px 88px;
}

body[data-theme="dark"] .noise {
  opacity: 0.08;
  background-image:
    radial-gradient(circle, rgba(238, 211, 178, 0.18) 0.75px, transparent 0.9px),
    linear-gradient(rgba(238, 211, 178, 0.09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(238, 211, 178, 0.07) 1px, transparent 1px);
}

.ambient-glyphs {
  z-index: 0;
  overflow: hidden;
  background:
    radial-gradient(circle at 9% 18%, var(--ambient-glow-1), transparent 28%),
    radial-gradient(circle at 91% 42%, var(--ambient-glow-2), transparent 31%),
    radial-gradient(circle at 48% 92%, var(--ambient-glow-3), transparent 34%);
}

.ambient-glyphs::before,
.ambient-glyphs::after {
  position: absolute;
  color: var(--ambient-glyph);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 5.2rem;
  letter-spacing: 0.14em;
  white-space: pre;
  opacity: 0.42;
  text-shadow: 0 0 18px var(--ambient-glow-1);
}

.ambient-glyphs::before {
  content: "0x\A{ }\A[ ]\A//\A01\Atx\A< >";
  top: 9vh;
  left: clamp(18px, 3vw, 52px);
}

.ambient-glyphs::after {
  content: "rpc\A=>\Aweb3\A#\Adefi\A{}\A/";
  top: 16vh;
  right: clamp(18px, 3vw, 52px);
  text-align: right;
}

.ambient-glyph {
  inset: auto;
  color: var(--ambient-glyph);
  font-size: clamp(0.95rem, 1.26vw, 1.14rem);
  letter-spacing: 0.08em;
  user-select: none;
  opacity: 0.52;
  transform: translate3d(0, 0, 0) rotate(0deg);
  transform-origin: center;
  animation: glyphFloat var(--duration, 18s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}

.ambient-glyph-mark {
  color: var(--ambient-mark);
  font-size: clamp(1.05rem, 1.52vw, 1.42rem);
  text-shadow: 0 0 18px rgba(255, 255, 255, 0.08);
}

.site-shell {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100% - 30px));
  margin: 0 auto;
  padding: 18px 0 44px;
}

.navbar,
.about-card,
.stat-card,
.project-card,
.commits-block,
.contact-card,
.side-card,
.timeline-content,
.footer-bar {
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  transition: background 220ms ease, border-color 220ms ease, color 220ms ease, box-shadow 220ms ease;
}

.navbar {
  position: sticky;
  top: 14px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  border-radius: 22px;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.brand,
.section-label,
.hero-kicker,
.project-topline,
.live-pill,
.lang-btn,
.timeline-type,
.skill-item-label,
.skills-card-badge,
.theme-toggle {
  text-transform: lowercase;
  letter-spacing: 0.08em;
}

.brand {
  font-weight: 700;
}

.nav-links,
.nav-actions,
.lang-switch,
.tag-row,
.project-grid,
.split-section,
.commit-line,
.hero,
.contact-grid,
.timeline-head,
.github-link,
.project-headline-row,
.skills-card-head,
.skills-grid {
  display: flex;
}

.nav-links,
.nav-actions {
  align-items: center;
  gap: 18px;
}

.nav-links a {
  color: var(--muted);
  transition: color 180ms ease;
}

.nav-links a:hover,
.icon-link:hover,
.github-footer-link:hover,
.commit-line:hover .commit-repo,
.project-card:hover h3,
.theme-toggle:hover {
  color: var(--accent);
}

.lang-switch {
  gap: 6px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--theme-chip-bg);
}

.lang-btn,
.theme-toggle {
  border: 0;
  background: transparent;
  color: var(--muted);
  border-radius: 999px;
  padding: 7px 10px;
  font: inherit;
  cursor: pointer;
}

.lang-btn.is-active {
  background: var(--accent-strong);
  color: #fff8f0;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  min-height: 38px;
  padding: 0;
  border: 1px solid var(--line);
  background: var(--theme-chip-bg);
}


.theme-icon {
  width: 16px;
  height: 16px;
  transition: opacity 180ms ease, transform 180ms ease;
}

.theme-icon-moon {
  display: none;
}

body[data-theme="dark"] .theme-icon-sun {
  display: none;
}

body[data-theme="dark"] .theme-icon-moon {
  display: block;
}
.icon-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
}

.github-link {
  gap: 8px;
}

.github-link svg {
  width: 16px;
  height: 16px;
}

.hero {
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  min-height: auto;
  padding: 72px 0 18px;
}

.hero-copy {
  flex: 1.2;
}

.hero-side {
  flex: 0.8;
  min-width: 280px;
}

.hero-kicker,
.section-label,
.project-topline,
.live-pill,
.block-head span,
.timeline-type,
.skill-item-label,
.skills-card-badge {
  color: var(--muted);
  font-size: 0.82rem;
}

.hero-title {
  display: grid;
  gap: 8px;
  max-width: 11ch;
  margin: 0 0 22px;
  font-size: clamp(3.4rem, 10vw, 6.9rem);
  line-height: 0.9;
}

.name-shine {
  position: relative;
  display: inline-block;
  overflow: hidden;
}

.name-shine::after {
  content: "";
  position: absolute;
  top: 0;
  left: -34%;
  width: 24%;
  height: 100%;
  background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.1) 15%, rgba(255, 255, 255, 0.95) 50%, rgba(255, 255, 255, 0.1) 85%, transparent 100%);
  transform: skewX(-18deg);
  animation: shine 5s ease-in-out infinite;
}

.hero-text,
.hero-note,
.about-card p,
.project-card p,
.github-summary,
.commit-message,
.side-card p,
.timeline-list,
.contact-card strong,
.contact-intro,
.skills-note {
  color: var(--muted);
  line-height: 1.85;
}

.hero-text {
  max-width: 58ch;
  margin: 0 0 18px;
  font-size: 1.02rem;
}

.hero-note {
  font-style: italic;
}

.hero-actions {
  display: flex;
  margin-top: 24px;
}

.text-link,
.print-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.34);
  color: var(--accent-strong);
  font: inherit;
  cursor: pointer;
  transition: border-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.text-link:hover,
.print-btn:hover {
  border-color: var(--line-strong);
  color: var(--accent);
  transform: translateY(-2px);
}

.side-card,
.about-card,
.stat-card,
.project-card,
.timeline-content,
.contact-card,
.commits-block,
.footer-bar {
  border-radius: 24px;
}

.side-card {
  padding: 24px;
  background: linear-gradient(180deg, var(--panel-strong), rgba(243, 231, 214, 0.72));
}

body[data-theme="dark"] .side-card {
  background: linear-gradient(180deg, rgba(54, 41, 32, 0.95), rgba(42, 31, 24, 0.82));
}

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

.skills-card-head {
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.skills-card-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
}

.skills-grid {
  flex-wrap: wrap;
  gap: 12px;
}

.skill-item {
  flex: 1 1 calc(50% - 6px);
  min-width: 130px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.35);
}

body[data-theme="dark"] .skill-item,
body[data-theme="dark"] .skills-card-badge,
body[data-theme="dark"] .tag-row span,
body[data-theme="dark"] .live-pill {
  background: rgba(255, 255, 255, 0.04);
}

.skill-item strong {
  display: block;
  margin-top: 8px;
  font-size: 1rem;
  color: var(--text);
}

.skills-note {
  margin: 0;
}

.split-section {
  gap: 18px;
  margin-top: 18px;
  margin-bottom: 18px;
  align-items: stretch;
}

.about-card,
.stat-card {
  flex: 1;
  min-width: 0;
  padding: 26px;
}

.about-card {
  display: block;
}

.about-card p {
  margin: 1em 0;
  max-width: none;
  line-height: 1.85;
}

.stat-card {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 14px;
  padding: 26px;
}

.stat-card .section-label {
  display: inline-flex;
  margin: 0;
}

.location {
  display: inline-block;
  margin-top: 18px;
  color: var(--accent);
}

.focus-list,
.timeline-list {
  margin: 14px 0 0;
  padding-left: 18px;
}

.focus-list {
  margin: 14px 0 0;
  padding-left: 18px;
}

.focus-list li {
  padding-left: 2px;
  line-height: 1.75;
}

.focus-list li::marker {
  color: var(--accent-strong);
}

.content-block {
  margin-top: 24px;
}

#projects {
  margin-top: 160px;
}

.block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.block-head h2 {
  margin: 0;
  font-size: clamp(1.25rem, 3vw, 1.9rem);
}

.project-grid {
  gap: 18px;
}

.project-card {
  flex: 1;
  min-width: 0;
  padding: 20px;
  overflow: hidden;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.project-image-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  margin: -8px -8px 18px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 17px;
  background: var(--bg-soft);
}

.project-image-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  pointer-events: none;
}

.project-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 420ms cubic-bezier(0.2, 0.7, 0.2, 1), filter 220ms ease;
}

.project-card:hover .project-image {
  transform: scale(1.035);
  filter: saturate(1.06) contrast(1.02);
}

.project-image-kebpro {
  object-position: center 42%;
}

.project-card:hover,
.contact-card:hover {
  transform: translateY(-3px);
  border-color: var(--line-strong);
}

.featured-card {
  background: linear-gradient(180deg, rgba(255, 252, 247, 0.94), rgba(247, 237, 223, 0.86));
}

body[data-theme="dark"] .featured-card {
  background: linear-gradient(180deg, rgba(59, 45, 35, 0.96), rgba(43, 32, 25, 0.9));
}

.project-headline-row {
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.project-card h3,
.timeline-content h3 {
  margin: 14px 0 10px;
  font-size: 1.18rem;
}

.project-card-icon {
  color: var(--accent-strong);
  font-size: 1.1rem;
}

.tag-row {
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.tag-row span,
.live-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
}

.timeline {
  display: grid;
  gap: 20px;
}

.alt-timeline .timeline-item {
  position: relative;
}

.alt-timeline .timeline-content {
  position: relative;
  padding: 22px 96px 22px 22px;
  overflow: hidden;
}

.alt-timeline .timeline-content::before {
  content: "";
  position: absolute;
  top: 20px;
  right: 34px;
  bottom: 20px;
  width: 2px;
  background: linear-gradient(180deg, rgba(156, 119, 87, 0.16), rgba(156, 119, 87, 0.65), rgba(156, 119, 87, 0.16));
}

.alt-timeline .timeline-content::after {
  content: "";
  position: absolute;
  top: 30px;
  right: 28px;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: rgba(255, 250, 244, 0.95);
  border: 1px solid rgba(156, 119, 87, 0.6);
  box-shadow: 0 0 0 7px rgba(156, 119, 87, 0.07), 0 180px 0 -1px rgba(156, 119, 87, 0.45), 0 180px 0 6px rgba(156, 119, 87, 0.06);
}

.timeline-content {
  padding: 20px;
}

.timeline-head {
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 10px;
}

.timeline-company {
  color: var(--accent-strong);
}

.timeline-meta {
  display: grid;
  gap: 6px;
  text-align: right;
  color: var(--muted);
}

.commits-block {
  padding: 16px 18px 14px;
}

.github-summary {
  padding: 8px 0 12px;
  border-bottom: 1px solid var(--line);
  font-size: 0.94rem;
  line-height: 1.55;
}

.commit-list {
  display: grid;
  gap: 0;
  padding-top: 4px;
}

.commit-line {
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.commit-main {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.commit-repo {
  color: var(--text);
  font-size: 0.98rem;
  line-height: 1.2;
}

.commit-message {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.35;
}

.commit-date {
  white-space: nowrap;
  color: var(--accent);
  font-size: 0.84rem;
  line-height: 1.2;
}

.github-footer-link {
  display: inline-block;
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.94rem;
}

.contact-intro {
  max-width: 64ch;
  margin: 0 0 18px;
}

.contact-grid {
  gap: 18px;
  flex-wrap: wrap;
}

.contact-card {
  flex: 1 1 240px;
  min-width: 0;
  padding: 18px 20px;
}

.contact-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.contact-card strong {
  margin-top: 10px;
  color: var(--text);
  line-height: 1.35;
}

.contact-value {
  display: block;
  font-size: 0.96rem;
  white-space: nowrap;
}

.contact-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.36);
  color: var(--accent-strong);
}

body[data-theme="dark"] .contact-icon {
  background: rgba(255, 255, 255, 0.05);
}

.contact-icon svg {
  width: 12px;
  height: 12px;
}

.footer-bar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 18px 28px;
  margin-top: 28px;
  padding: 18px 20px;
  color: var(--muted);
}

.footer-copy {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.footer-copy-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 0.82rem;
  color: var(--accent-strong);
  line-height: 1;
}

.footer-status {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #18b87a;
  box-shadow: 0 0 0 4px rgba(24, 184, 122, 0.12);
  animation: pulseDot 1.8s ease-in-out infinite;
}


@keyframes glyphFloat {
  0%,
  100% {
    transform: translate3d(0, 0, 0) rotate(calc(var(--tilt, 0deg) * -0.35));
    opacity: 0.34;
  }
  30% {
    transform: translate3d(calc(var(--float-x, 10px) * 0.6), calc(var(--float-y, -8px) * 0.35), 0) rotate(calc(var(--tilt, 0deg) * 0.35));
    opacity: 0.5;
  }
  65% {
    transform: translate3d(var(--float-x, 10px), var(--float-y, -8px), 0) rotate(var(--tilt, 0deg));
    opacity: 0.75;
  }
  82% {
    transform: translate3d(calc(var(--float-x, 10px) * -0.22), calc(var(--float-y, -8px) * 0.42), 0) rotate(calc(var(--tilt, 0deg) * -0.2));
    opacity: 0.46;
  }
}

@keyframes pulseDot {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 4px rgba(24, 184, 122, 0.12);
  }
  50% {
    transform: scale(1.18);
    box-shadow: 0 0 0 8px rgba(24, 184, 122, 0.08);
  }
}

@keyframes shine {
  0% {
    left: -34%;
  }
  35% {
    left: 118%;
  }
  100% {
    left: 118%;
  }
}

@media (max-width: 980px) {
  .hero,
  .split-section,
  .project-grid,
  .navbar,
  .timeline-head,
  .footer-bar {
    display: grid;
  }

  .site-shell {
    width: min(100% - 22px, 1180px);
    padding-top: 14px;
  }

  .navbar {
    gap: 14px;
    padding: 14px 16px;
  }

  .nav-links {
    flex-wrap: wrap;
    gap: 10px 16px;
  }

  .nav-actions {
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 12px;
  }

  .hero {
    min-height: auto;
    padding: 48px 0 10px;
    gap: 22px;
  }

  .hero-copy,
  .hero-side {
    width: 100%;
  }

  .hero-side {
    min-width: 0;
  }

  .split-section {
    margin-top: 14px;
    margin-bottom: 14px;
    gap: 16px;
  }

  #projects {
    margin-top: 112px;
  }

  .timeline-meta {
    text-align: left;
  }

  .alt-timeline .timeline-content {
    padding-right: 22px;
  }

  .alt-timeline .timeline-content::before,
  .alt-timeline .timeline-content::after,
  .ambient-glyph,
  .ambient-glyphs::before,
  .ambient-glyphs::after {
    display: none;
  }
}

@media (max-width: 640px) {
  .site-shell {
    width: min(100% - 16px, 1180px);
    padding-top: 10px;
    padding-bottom: 28px;
  }

  .navbar {
    position: static;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 18px;
  }

  .brand {
    font-size: 0.94rem;
  }

  .nav-links,
  .block-head,
  .commit-line,
  .footer-bar,
  .skills-card-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav-links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: 8px 14px;
  }

  .nav-links a {
    font-size: 0.95rem;
  }

  .nav-actions {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 8px;
  }

  .lang-switch {
    order: 0;
  }

  .lang-btn,
  .theme-toggle {
    padding: 6px 9px;
  }

  .theme-toggle,
  .icon-link {
    width: 36px;
    height: 36px;
    min-height: 36px;
  }

  .github-link {
    width: 36px;
    padding: 0;
  }

  .github-link span {
    display: none;
  }

  .hero {
    min-height: auto;
    padding: 28px 0 2px;
    gap: 16px;
  }

  .hero-title {
    max-width: none;
    font-size: clamp(2.45rem, 16vw, 4.3rem);
    margin-bottom: 12px;
    gap: 2px;
  }

  .hero-kicker {
    font-size: 0.75rem;
  }

  .hero-text,
  .hero-note,
  .contact-intro,
  .about-card p,
  .skills-note,
  .timeline-list,
  .commit-message {
    font-size: 0.95rem;
    line-height: 1.68;
  }

  .side-card,
  .about-card,
  .stat-card,
  .project-card,
  .timeline-content,
  .contact-card,
  .commits-block,
  .footer-bar {
    border-radius: 20px;
  }

  .side-card,
  .about-card,
  .stat-card,
  .timeline-content,
  .contact-card,
  .commits-block {
    padding: 16px;
  }

  .stat-card {
    gap: 14px;
    padding: 18px;
  }

  .split-section {
    margin-top: 10px;
    margin-bottom: 10px;
  }

  .about-card {
    display: block;
  }

  .about-card p,
  .focus-list li {
    line-height: 1.65;
  }

  .focus-list {
    padding-left: 18px;
  }

  #projects {
    margin-top: 64px;
  }

  .block-head {
    gap: 8px;
    margin-bottom: 12px;
  }

  .project-card {
    padding: 16px;
  }

  .contact-grid {
    gap: 14px;
  }

  .contact-value {
    font-size: 0.92rem;
    white-space: normal;
  }

  .contact-icon {
    width: 22px;
    height: 22px;
    flex-basis: 22px;
  }

  .contact-icon svg {
    width: 11px;
    height: 11px;
  }
}

@media (max-width: 1180px) {
  .contact-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-card {
    min-width: 0;
  }
}

@media (max-width: 720px) {
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .footer-bar {
    gap: 12px;
    padding: 16px;
  }

  .footer-status {
    margin-left: 0;
  }

  .commit-date {
    white-space: normal;
    font-size: 0.8rem;
  }

  .skill-item {
    flex-basis: 100%;
    min-width: 0;
  }
}

.cv-shell {
  position: relative;
  width: min(1040px, calc(100% - 30px));
  margin: 0 auto;
  padding: 18px 0 48px;
}

.cv-topbar,
.cv-page {
  backdrop-filter: blur(12px);
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.cv-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
  padding: 14px 18px;
  border-radius: 22px;
}

.cv-topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.cv-page {
  padding: clamp(24px, 4vw, 46px);
  border-radius: 28px;
}

.cv-header {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 28px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.cv-identity {
  display: flex;
  align-items: center;
  gap: 22px;
  min-width: 0;
}

.cv-photo-placeholder {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: clamp(96px, 13vw, 136px);
  aspect-ratio: 1;
  flex: 0 0 auto;
  border: 1px solid var(--line-strong);
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.5), rgba(156, 119, 87, 0.08)),
    var(--panel-strong);
  color: rgba(109, 79, 54, 0.56);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  box-shadow: inset 0 0 0 8px rgba(255, 255, 255, 0.16);
}

.cv-photo-placeholder img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cv-photo-placeholder img:not([hidden]) + span {
  opacity: 0;
}

.cv-header h1 {
  margin: 8px 0 12px;
  font-size: clamp(2.4rem, 7vw, 5rem);
  line-height: 0.94;
}

.cv-role {
  margin: 0;
  color: var(--accent-strong);
  font-size: 1.05rem;
  font-weight: 700;
}

.cv-contact {
  display: grid;
  gap: 10px;
  align-content: start;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.5;
  word-break: break-word;
}

.cv-contact a:hover,
.cv-project-list a:hover strong {
  color: var(--accent);
}

.cv-section {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 26px;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}

.cv-section:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.cv-section h2 {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: lowercase;
}

.cv-summary p,
.cv-entry p,
.cv-entry li,
.cv-project-list span {
  color: var(--muted);
  line-height: 1.75;
}

.cv-summary p {
  margin: 0;
}

.cv-entry-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
}

.cv-entry-head h3 {
  margin: 0;
  font-size: 1.08rem;
}

.cv-entry-head span,
.cv-entry-place {
  color: var(--accent);
}

.cv-entry-place {
  margin: 8px 0 12px;
}

.cv-entry ul {
  margin: 0;
  padding-left: 18px;
}

.cv-strength-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding-left: 18px;
}

.cv-strength-list li {
  color: var(--muted);
  line-height: 1.75;
}

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

.cv-entry-spaced {
  margin-top: 0;
}

.cv-skill-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cv-skill-grid span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.34);
}

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

.cv-project-list a {
  display: grid;
  gap: 6px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.cv-project-list a:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

@media (max-width: 760px) {
  .cv-shell {
    width: min(100% - 16px, 1040px);
    padding-top: 10px;
  }

  .cv-topbar,
  .cv-header,
  .cv-section {
    display: grid;
    grid-template-columns: 1fr;
  }

  .cv-topbar {
    gap: 12px;
    align-items: start;
  }

  .cv-topbar-actions {
    width: 100%;
  }

  .cv-page {
    padding: 20px;
    border-radius: 22px;
  }

  .cv-section {
    gap: 14px;
    padding: 22px 0;
  }

  .cv-entry-head {
    display: grid;
    gap: 6px;
  }

  .cv-identity {
    align-items: flex-start;
  }

  .cv-photo-placeholder {
    width: 88px;
    border-radius: 20px;
  }
}

@media print {
  body {
    background: #ffffff;
    color: #1f1f1f;
  }

  .noise,
  .cv-topbar {
    display: none;
  }

  .cv-shell {
    width: 100%;
    padding: 0;
  }

  .cv-page {
    box-shadow: none;
    border: 0;
    padding: 0;
  }

  .cv-section {
    break-inside: avoid;
  }

  .cv-photo-placeholder {
    background: #ffffff;
    box-shadow: none;
  }
}

/* Portfolio visual refresh */
button, .brand, .nav-links, .hero-kicker, .section-label, .skills-card-badge,
.skill-item-label, .project-topline, .tag-row, .timeline-type, .live-pill,
.commit-list, .github-footer-link, .footer-bar {
  font-family: "JetBrains Mono", monospace;
}

:focus-visible { outline: 3px solid var(--accent-strong); outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.menu-toggle { display: none; }

.nav-links a { position: relative; }
.nav-links a::after { content: ""; position: absolute; left: 0; right: 100%; bottom: -7px; height: 2px; background: var(--accent-strong); transition: right 180ms ease; }
.nav-links a:hover::after, .nav-links a.is-current::after { right: 0; }
.nav-links a.is-current { color: var(--text); }

.availability-pill { display: inline-flex; align-items: center; gap: 10px; margin: 4px 0 20px; padding: 8px 12px; border: 1px solid rgba(24,184,122,.28); border-radius: 999px; background: rgba(24,184,122,.08); color: var(--text); font-family: "JetBrains Mono", monospace; font-size: .78rem; }
.availability-pill .status-dot { animation: none; }
.hero-actions { gap: 10px; flex-wrap: wrap; }
.primary-link, .secondary-link { min-height: 46px; padding-inline: 18px; }
.primary-link { padding-inline: 20px; border-color: var(--accent-strong); background: var(--accent-strong); color: #fffaf5; box-shadow: 0 12px 30px rgba(109,79,54,.22); }
.primary-link:hover { border-color: var(--text); background: var(--text); color: var(--panel-strong); }
body[data-theme="dark"] .primary-link { background: var(--accent); color: #1f1712; }
body[data-theme="dark"] .primary-link:hover { background: var(--accent-strong); color: #1f1712; }

#projects { margin-top: 96px; }
.project-card:nth-child(1) { --project-accent: #9c7757; }
.project-card:nth-child(2) { --project-accent: #6d8eff; }
.project-card:nth-child(3) { --project-accent: #35c995; }
.project-card:hover { border-color: color-mix(in srgb, var(--project-accent) 55%, var(--line)); }
.project-card .project-image-wrap::before { content: ""; position: absolute; z-index: 1; inset: auto 0 0; height: 3px; background: var(--project-accent); }
.project-cta { display: inline-flex; align-items: center; gap: 8px; margin-top: 20px; color: var(--project-accent); font-family: "JetBrains Mono", monospace; font-size: .82rem; font-weight: 700; }
.project-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.project-actions .project-cta { min-height: 36px; margin-top: 0; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; transition: transform 180ms ease, border-color 180ms ease, background 180ms ease; }
.project-actions .project-cta:hover { transform: translateY(-2px); border-color: var(--project-accent); }
.project-actions .project-demo { border-color: color-mix(in srgb,var(--project-accent) 50%,var(--line)); background: color-mix(in srgb,var(--project-accent) 10%,transparent); }
.project-actions .project-demo-unavailable { color: var(--muted); cursor: default; }
.project-actions .project-demo-unavailable:hover { transform: none; border-color: var(--line); }

.commits-block { position: relative; overflow: hidden; padding: 0; border-color: rgba(255,255,255,.08); border-radius: 10px; background: #111; color: #e8e8e8; box-shadow: 0 20px 50px rgba(8,8,8,.18); }
.commits-block::before { display: none; }
.commits-block .block-head { min-height: 50px; margin: 0; padding: 0 15px; border-bottom: 1px solid rgba(255,255,255,.09); }
.commits-block .block-head h2 { font-family: "JetBrains Mono", monospace; font-size: .88rem; font-weight: 500; }
.commits-block .block-head h2, .commits-block .commit-repo { color: #effff7; }
.commits-block .block-head span, .commits-block .github-summary, .commits-block .commit-message, .commits-block .github-footer-link { color: #bfc5c9; }
.commits-block .github-summary { padding: 11px 15px; border-bottom: 1px solid rgba(255,255,255,.07); font-size: .76rem; }
.commits-block .commit-list { gap: 0; padding: 12px 15px 10px; }
.commits-block .commit-line { min-height: 35px; padding: 7px 0; border: 0; }
.commits-block .commit-main { display: flex; align-items: baseline; gap: 9px; min-width: 0; overflow: hidden; }
.commits-block .commit-repo { flex: 0 0 auto; font-size: .84rem; font-weight: 700; }
.commits-block .commit-separator { color: #566069; }
.commits-block .commit-message { min-width: 0; overflow: hidden; color: #c5ccd1; font-size: .82rem; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.commits-block .commit-date { flex: 0 0 auto; color: #15b981; font-size: .75rem; }
.commits-block .commit-stats { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 10px; min-width: 82px; justify-content: flex-end; font-size: .78rem; font-weight: 700; }
.commits-block .commit-additions { color: #10b981; }
.commits-block .commit-deletions { color: #ff5353; }
.commits-block .commit-stats-separator { color: #566069; }
.commits-block .commit-line:hover { background: rgba(255,255,255,.025); }
.commits-block .github-footer-link { margin: 0; padding: 10px 15px 14px; color: #7f8a90; font-size: .76rem; }
.commits-block .github-footer-link:hover, .commits-block .commit-line:hover .commit-repo { color: #15b981; }
.commits-block .live-pill { width: 7px; height: 7px; min-height: 7px; padding: 0; overflow: hidden; border: 0; border-radius: 50%; background: #0a9b6b; color: transparent; box-shadow: none; }

@media (max-width: 640px) {
  .commits-block .block-head { flex-direction: row; align-items: center; }
  .commits-block .commit-line { display: grid; grid-template-columns: minmax(0,1fr); gap: 4px; }
  .commits-block .commit-date { padding-left: 0; }
  .commits-block .commit-stats { justify-content: flex-start; }
}

#contact { margin-top: 72px; padding: clamp(24px,5vw,52px); border: 1px solid var(--line); border-radius: 30px; background: linear-gradient(135deg,rgba(255,250,243,.88),rgba(109,79,54,.08)); box-shadow: var(--shadow); }
body[data-theme="dark"] #contact { background: linear-gradient(135deg,rgba(43,33,26,.94),rgba(196,156,115,.08)); }
.contact-primary { flex-grow: 1.4; border-color: rgba(109,79,54,.24); }
.contact-primary .contact-icon { background: var(--accent-strong); color: white; }
body[data-theme="dark"] .contact-primary .contact-icon { color: #1f1712; }
.contact-secondary { flex-grow: .72; box-shadow: none; background: color-mix(in srgb,var(--panel) 72%,transparent); }

@media (max-width: 980px) { #projects { margin-top: 76px; } }

@media (max-width: 640px) {
  .navbar { position: sticky; }
  .menu-toggle { display: inline-grid; gap: 4px; place-content: center; width: 40px; height: 40px; margin-left: auto; padding: 0; border: 1px solid var(--line); border-radius: 999px; background: var(--theme-chip-bg); color: var(--text); cursor: pointer; }
  .menu-toggle span:not(.sr-only) { display: block; width: 16px; height: 2px; border-radius: 2px; background: currentColor; transition: transform 180ms ease, opacity 180ms ease; }
  .menu-open .menu-toggle span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  .menu-open .menu-toggle span:nth-child(2) { opacity: 0; }
  .menu-open .menu-toggle span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
  .nav-links { display: none; }
  .menu-open .nav-links { display: grid; }
  .nav-actions { width: auto; }
  .menu-open .nav-actions { width: 100%; }
  .hero-actions { display: grid; grid-template-columns: 1fr; }
  #projects { margin-top: 58px; }
  #contact { margin-top: 52px; padding: 20px 16px; border-radius: 22px; }
}

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

/* Motion and responsive navigation */
.scroll-progress {
  position: fixed;
  z-index: 100;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  pointer-events: none;
}

.scroll-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-strong));
  box-shadow: 0 0 14px rgba(109, 79, 54, 0.24);
  transform: scaleX(0);
  transform-origin: left center;
  will-change: transform;
}

.motion-ready .hero-kicker,
.motion-ready .availability-pill,
.motion-ready .hero-title,
.motion-ready .hero-text,
.motion-ready .hero-note,
.motion-ready .hero-actions,
.motion-ready .hero-side {
  animation: heroEnter 680ms cubic-bezier(.2,.75,.25,1) both;
}

.motion-ready .availability-pill { animation-delay: 60ms; }
.motion-ready .hero-title { animation-delay: 110ms; }
.motion-ready .hero-text { animation-delay: 180ms; }
.motion-ready .hero-note { animation-delay: 230ms; }
.motion-ready .hero-actions { animation-delay: 280ms; }
.motion-ready .hero-side { animation-delay: 190ms; }

.motion-ready .reveal-item {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 480ms cubic-bezier(.2,.75,.25,1) var(--reveal-delay, 0ms),
              transform 480ms cubic-bezier(.2,.75,.25,1) var(--reveal-delay, 0ms);
}

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

.motion-ready .project-card.reveal-item.is-visible:hover,
.motion-ready .contact-card.reveal-item.is-visible:hover {
  transform: translateY(-3px);
}

@keyframes heroEnter {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes menuDrop {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 640px) {
  .navbar {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
  }

  .brand {
    grid-column: 1;
    grid-row: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .menu-toggle {
    grid-column: 2;
    grid-row: 1;
    margin-left: 0;
  }

  .nav-links {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .nav-actions {
    display: none;
    grid-column: 1 / -1;
    grid-row: 3;
    width: 100%;
  }

  .menu-open .nav-links {
    display: grid;
    animation: menuDrop 220ms ease both;
  }

  .menu-open .nav-actions {
    display: flex;
    width: 100%;
    animation: menuDrop 220ms 45ms ease both;
  }
}

