:root {
  --bg: #0f141a;
  --bg-2: #131a21;
  --surface: #161c23;
  --text: #f2f4f8;
  --muted: #9aa6b2;
  --accent: #ff6f61;
  --divider: #262f39;
  --radius: 20px;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(1200px, 92%);
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(180deg, rgba(15, 20, 26, 0.96), rgba(15, 20, 26, 0.85));
  backdrop-filter: saturate(140%) blur(6px);
  border-bottom: 1px solid var(--divider);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
}

.brand {
  font-weight: 800;
  letter-spacing: 0.3px;
}

.nav {
  display: flex;
  gap: 28px;
  align-items: center;
}

.nav a {
  color: var(--muted);
  font-weight: 500;
}

.nav a:hover,
.nav a:focus {
  color: var(--text);
}

.nav-toggle {
  display: none;
}

.burger {
  display: none;
  cursor: pointer;
  width: 34px;
  height: 28px;
  position: relative;
}

.burger span {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--text);
  top: 6px;
  transition: 0.25s;
}

.burger span:nth-child(2) {
  top: 13px;
}

.burger span:nth-child(3) {
  top: 20px;
}

@media (max-width: 820px) {
  .burger {
    display: block;
  }
  .nav {
    position: fixed;
    inset: 64px 0 auto 0;
    background: var(--bg-2);
    display: grid;
    gap: 0;
    padding: 12px 20px 24px;
    border-bottom: 1px solid var(--divider);
    transform: translateY(-120%);
    transition: 0.25s ease;
  }
  #nav-toggle:checked ~ .burger span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }
  #nav-toggle:checked ~ .burger span:nth-child(2) {
    opacity: 0;
  }
  #nav-toggle:checked ~ .burger span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }
  #nav-toggle:checked ~ .nav {
    transform: translateY(0);
  }
}

.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 40px;
  padding: 72px 0 28px;
}

.eyebrow {
  color: var(--muted);
  margin: 0 0 6px;
  font-weight: 600;
}

.dot {
  color: var(--accent);
  font-size: 1.1em;
}

.hero h1 {
  font-size: clamp(38px, 6vw, 56px);
  line-height: 1.05;
  margin: 0;
}

.role {
  font-size: clamp(24px, 4vw, 36px);
  margin: 0.2em 0 10px;
  color: var(--text);
  font-weight: 800;
}

.lede {
  color: var(--muted);
  max-width: 56ch;
}

.cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.btn {
  position: relative;
  padding: 12px 18px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-weight: 600;
  display: inline-block;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.3s ease, transform 0.3s ease;
}

.btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.05);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
  border-radius: inherit;
}

.btn:hover::after {
  opacity: 1;
}

.btn-primary {
  background: var(--accent);
  color: #140a0a;
  transform: translateY(0);
}

.btn-primary:hover,
.btn-primary:focus {
  background: #ff5a4f;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 111, 97, 0.4);
}

.btn-outline {
  border-color: var(--accent);
  color: var(--text);
  background-color: transparent;
}

.btn-outline:hover,
.btn-outline:focus {
  background: rgba(255, 111, 97, 0.1);
  color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 111, 97, 0.2);
}

.hero-visual {
  display: flex;
  justify-content: center;
}

.portrait-wrap {
  position: relative;
  width: min(420px, 80vw);
  aspect-ratio: 0.8/1;
  display: grid;
  place-items: center;
}

.ring {
  position: absolute;
  width: 82%;
  aspect-ratio: 1/1;
  border-radius: 50%;
  background: radial-gradient(
      circle at 50% 50%,
      rgba(255, 111, 97, 0.35),
      rgba(255, 111, 97, 0.07) 45%,
      transparent 60%
    ),
    conic-gradient(
      from 0deg,
      rgba(255, 111, 97, 0.9),
      rgba(255, 111, 97, 0.25) 35%,
      rgba(255, 111, 97, 0.9)
    );
  filter: blur(14px) saturate(120%);
  z-index: 1;
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    padding-top: 56px;
  }
  .hero-visual {
    order: 2;
  }
}

.skills {
  border-top: 1px solid var(--divider);
  border-bottom: 1px solid var(--divider);
  background: var(--surface);
}

.skills .container {
  overflow-x: auto;
}

.skills-list {
  display: flex;
  gap: 26px;
  padding: 14px 0;
  margin: 0;
  list-style: none;
  white-space: nowrap;
}

.skills-list li {
  color: #c7d2dc;
  position: relative;
  padding-left: 22px;
}

.skills-list li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--accent);
}

.services {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, 1fr);
  padding: 56px 0 10px;
}

.service-card {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--surface);
  border: 1px solid var(--divider);
  padding: 18px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.service-card .icon {
  color: var(--accent);
  margin-top: 2px;
}

.service-card h3 {
  margin: 2px 0 6px;
}

.service-card p {
  margin: 0;
  color: var(--muted);
}

@media (max-width: 980px) {
  .services {
    grid-template-columns: 1fr;
  }
}

.projects {
  padding: 18px 0 52px;
}

.projects h2 {
  margin-bottom: 12px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

@media (max-width: 1024px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 680px) {
  .grid {
    grid-template-columns: 1fr;
  }
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--divider);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease;
}

.project-card:hover {
  transform: translateY(-2px);
}

.project-thumb .thumb {
  width: 100%;
  aspect-ratio: 16/9;
  background: linear-gradient(
      135deg,
      rgba(255, 111, 97, 0.2),
      rgba(255, 111, 97, 0.06)
    ),
    linear-gradient(180deg, #18212b, #121921);
  border-bottom: 1px solid var(--divider);
}

.project-body {
  padding: 16px;
}

.project-body p {
  color: var(--muted);
  margin: 0.3em 0 1em;
}

.project-link,
.github-link {
  transition: color 0.3s ease, transform 0.3s ease;
  display: inline-block;
  cursor: pointer;
}

.project-link:hover,
.project-link:focus {
  color: var(--accent);
  transform: translateX(4px);
}

.github-link:hover,
.github-link:focus {
  color: var(--accent);
  transform: scale(1.15) rotate(2deg);
}

.contact {
  padding: 24px 0 80px;
}

.contact-card {
  background: var(--surface);
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  padding: 22px;
  display: grid;
  gap: 8px;
  place-items: start;
}

.contact .cta {
  margin-top: 6px;
}

.socials {
  display: flex;
  gap: 10px;
  margin-top: 6px;
}

.socials a {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
  font-size: 1.4em;
  overflow: hidden;
  transition: width 0.35s ease, background 0.35s ease, color 0.35s ease;
  white-space: nowrap;
  padding: 0 16px;
}

.socials a span {
  margin-left: 12px;
  font-size: 0.95rem;
  font-weight: 600;
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.socials a.github:hover {
  width: 160px;
  background: #181717;
  color: #fff;
}

.socials a.linkedin:hover {
  width: 160px;
  background: #0A66C2;
  color: #fff;
}

.socials a:hover span {
  opacity: 1;
  transform: translateX(0);
}

.site-footer {
  border-top: 1px solid var(--divider);
  background: var(--bg-2);
}

.site-footer .container {
  padding: 14px 0;
  text-align: center;
}

.site-footer p {
  color: var(--muted);
  margin: 10px 0;
}

a:focus-visible,
.btn:focus-visible,
.burger:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 10px;
}

.cursor {
  display: inline-block;
  width: 10px;
  height: 0.8em;
  background-color: #fff;
  margin-left: 5px;
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

.github-link {
  display: inline-block;
  margin-left: 1.5rem;
}

.thumb {
  position: relative;
  width: 100%;
  height: 220px;
  overflow: hidden;
  background-color: #0f1113;
  display: grid;
  place-items: center;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  opacity: 1;
  transition: opacity 900ms cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity;
}

.thumb img.fade-out {
  opacity: 0;
}
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(180deg, rgba(15, 20, 26, 0.96), rgba(15, 20, 26, 0.85));
  backdrop-filter: saturate(140%) blur(6px);
  border-bottom: 1px solid var(--divider);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  position: relative;
}

@media (max-width: 820px) {
  .burger {
    display: block;
    z-index: 60;
  }
  
  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-2);
    display: grid;
    gap: 0;
    padding: 12px 20px 24px;
    border-bottom: 1px solid var(--divider);
    transform: translateY(-100%);
    transition: 0.25s ease;
    opacity: 0;
    visibility: hidden;
  }
  
  #nav-toggle:checked ~ .nav {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  
  .nav a {
    padding: 8px 0;
  }
}
