:root {
  --ink: #0B0D10;
  --panel: #15181D;
  --paper: #F2F0EA;
  --muted: #949BA6;
  --blue: #4D7CFE;
  --line: rgba(242, 240, 234, 0.12);
  --line-strong: rgba(242, 240, 234, 0.22);
  --paper-soft: rgba(242, 240, 234, 0.78);
  --panel-soft: rgba(21, 24, 29, 0.78);
  --blue-soft: rgba(77, 124, 254, 0.16);
  --shadow: 0 24px 90px rgba(11, 13, 16, 0.58);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(180deg, var(--ink) 0%, var(--panel) 48%, var(--ink) 100%);
  color: var(--paper);
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  letter-spacing: 0;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  content: "";
  background:
    linear-gradient(rgba(242, 240, 234, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(242, 240, 234, 0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(to bottom, #0B0D10, transparent 78%);
}

body::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  background:
    radial-gradient(circle at var(--spot-x, 50%) var(--spot-y, 20%), rgba(77, 124, 254, 0.2), transparent 22rem),
    linear-gradient(120deg, transparent 0%, rgba(77, 124, 254, 0.05) 48%, transparent 72%);
  opacity: 0.8;
  transition: opacity 240ms ease;
}

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

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

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

button {
  font: inherit;
}

.skip-link {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 20;
  padding: 0.75rem 1rem;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink);
  transform: translateY(-150%);
  transition: transform 180ms ease;
}

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

.site-shell {
  overflow: clip;
}

.site-header {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1180px, calc(100% - 2rem));
  margin: 1rem auto 0;
  padding: 0.7rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(11, 13, 16, 0.62);
  box-shadow: 0 12px 44px rgba(11, 13, 16, 0.34);
  backdrop-filter: blur(20px);
  transition:
    border-color 180ms ease,
    background 180ms ease,
    transform 240ms ease;
}

.site-header.scrolled {
  border-color: rgba(77, 124, 254, 0.4);
  background: rgba(11, 13, 16, 0.86);
}

.brand,
.site-nav,
.hero-actions,
.project-links,
.site-footer {
  display: flex;
  align-items: center;
}

.brand {
  gap: 0;
  padding-right: 0;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  width: 2.7rem;
  height: 2.7rem;
  place-items: center;
  border: 1px solid rgba(77, 124, 254, 0.58);
  border-radius: 8px;
  background: rgba(77, 124, 254, 0.16);
  color: var(--paper);
  font-size: 1rem;
}

.site-nav {
  gap: 0.25rem;
}

.site-nav a {
  position: relative;
  padding: 0.72rem 0.95rem;
  border-radius: 8px;
  color: var(--paper-soft);
  font-size: 0.93rem;
  transition:
    background 180ms ease,
    color 180ms ease,
    transform 180ms ease;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  background: rgba(242, 240, 234, 0.08);
  color: var(--paper);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 2.65rem;
  height: 2.65rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(242, 240, 234, 0.06);
  color: var(--paper);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 1rem;
  height: 2px;
  margin: 0.22rem auto;
  background: currentColor;
  transition:
    transform 180ms ease,
    opacity 180ms ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.section {
  position: relative;
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 7rem 0;
}

.hero {
  display: grid;
  min-height: 100vh;
  grid-template-columns: minmax(0, 1fr);
  align-items: end;
  padding-top: 9rem;
  padding-bottom: 3rem;
}

.hero-canvas,
.hero-grid {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.hero-canvas {
  width: 100%;
  height: 100%;
  border-radius: 8px;
}

.hero-grid {
  background:
    linear-gradient(180deg, transparent 0%, rgba(11, 13, 16, 0.2) 45%, rgba(11, 13, 16, 0.86) 100%),
    repeating-linear-gradient(90deg, transparent 0 7.5rem, rgba(242, 240, 234, 0.055) 7.55rem 7.6rem);
}

.hero-content {
  max-width: 760px;
  justify-self: center;
  padding-bottom: 4rem;
  text-align: center;
}

.eyebrow {
  margin: 0 0 1rem;
  color: var(--blue);
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 1.35rem;
  font-size: 5rem;
  line-height: 0.95;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 1rem;
  font-size: 3.2rem;
  line-height: 1.02;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 0.75rem;
  font-size: 1.35rem;
  line-height: 1.16;
  letter-spacing: 0;
}

p {
  color: var(--paper-soft);
  font-size: 1rem;
  line-height: 1.7;
}

.hero-lede {
  max-width: 660px;
  margin-right: auto;
  margin-bottom: 0;
  margin-left: auto;
  color: var(--paper);
  font-size: 1.35rem;
  line-height: 1.55;
}

.hero-actions {
  flex-wrap: wrap;
  gap: 0.75rem;
}

.button {
  position: relative;
  display: inline-flex;
  min-height: 3.1rem;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 0.9rem 1.15rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-weight: 800;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.button::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(110deg, transparent 20%, rgba(242, 240, 234, 0.24), transparent 80%);
  transform: translateX(-120%);
  transition: transform 520ms ease;
}

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

.button:hover::after,
.button:focus-visible::after {
  transform: translateX(120%);
}

.button-primary {
  border-color: rgba(77, 124, 254, 0.8);
  background: var(--blue);
  color: var(--paper);
}

.button-secondary {
  background: rgba(242, 240, 234, 0.06);
  color: var(--paper);
}

.hero-proof {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--line);
  box-shadow: var(--shadow);
}

.hero-proof > div {
  min-height: 8.5rem;
  padding: 1.35rem;
  background: rgba(21, 24, 29, 0.78);
}

.metric,
.metric-text {
  display: block;
  margin-bottom: 0.45rem;
  color: var(--paper);
  font-size: 2.2rem;
  font-weight: 900;
  line-height: 1;
}

.metric-label {
  display: block;
  color: var(--muted);
  font-size: 0.9rem;
}

.section-heading {
  max-width: 760px;
  margin-right: auto;
  margin-bottom: 1.3rem;
  margin-left: auto;
  text-align: center;
}

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

.project-card,
.skill-panel,
.cert-card,
.contact-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(242, 240, 234, 0.06), transparent 42%),
    rgba(21, 24, 29, 0.78);
  box-shadow: 0 16px 50px rgba(11, 13, 16, 0.42);
}

.project-card {
  position: relative;
  display: grid;
  min-height: 420px;
  overflow: hidden;
  padding: 1rem;
  transform-style: preserve-3d;
  transition:
    border-color 220ms ease,
    transform 220ms ease,
    box-shadow 220ms ease;
}

.project-card::before {
  position: absolute;
  inset: 0;
  pointer-events: none;
  content: "";
  background: linear-gradient(110deg, transparent 0%, rgba(77, 124, 254, 0.16) 45%, transparent 70%);
  opacity: 0;
  transform: translateX(-28%);
  transition:
    opacity 220ms ease,
    transform 620ms ease;
}

.project-card:hover {
  border-color: rgba(77, 124, 254, 0.5);
  box-shadow: 0 24px 80px rgba(11, 13, 16, 0.58);
}

.project-card:hover::before {
  opacity: 1;
  transform: translateX(18%);
}

.project-card-large {
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1.1fr);
  gap: 1rem;
  min-height: 520px;
}

.project-copy {
  position: relative;
  z-index: 1;
  align-self: end;
  padding: 1.1rem;
}

.project-topline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1rem;
  color: var(--muted);
  font-size: 0.86rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 1.8rem;
  padding: 0.35rem 0.6rem;
  border: 1px solid rgba(77, 124, 254, 0.46);
  border-radius: 8px;
  background: var(--blue-soft);
  color: var(--paper);
  font-size: 0.78rem;
  font-weight: 900;
}

.project-points {
  display: grid;
  gap: 0.55rem;
  margin: 1rem 0 1.1rem;
  padding-left: 1.05rem;
  color: var(--paper-soft);
  line-height: 1.55;
}

.stack-list,
.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.stack-list span,
.skill-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  padding: 0.42rem 0.62rem;
  border: 1px solid rgba(242, 240, 234, 0.13);
  border-radius: 8px;
  background: rgba(242, 240, 234, 0.06);
  color: var(--paper-soft);
  font-size: 0.82rem;
}

.project-links {
  gap: 0.75rem;
  margin-top: 1.25rem;
}

.project-links a {
  position: relative;
  color: var(--paper);
  font-size: 0.92rem;
  font-weight: 800;
}

.project-links a::after {
  position: absolute;
  right: 0;
  bottom: -0.24rem;
  left: 0;
  height: 1px;
  content: "";
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 180ms ease;
}

.project-links a:hover::after,
.project-links a:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

.project-visual {
  position: relative;
  display: grid;
  min-height: 210px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(242, 240, 234, 0.1);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(77, 124, 254, 0.16), transparent 45%),
    rgba(11, 13, 16, 0.46);
}

.media-visual {
  isolation: isolate;
  padding: 0;
}

.media-visual::after {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  content: "";
  background:
    linear-gradient(180deg, rgba(11, 13, 16, 0.08), transparent 44%, rgba(11, 13, 16, 0.38)),
    linear-gradient(120deg, rgba(77, 124, 254, 0.2), transparent 34%);
}

.media-visual > img,
.media-visual video,
.carousel-track img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-visual > img,
.media-visual video {
  min-height: inherit;
  transform: scale(1.01);
  transition:
    transform 720ms ease,
    filter 220ms ease;
}

.media-visual:hover > img,
.media-visual:hover video {
  transform: scale(1.045);
  filter: saturate(1.06);
}

.media-carousel {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: inherit;
  overflow: hidden;
}

.carousel-track {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: inherit;
}

.carousel-track img {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.025);
  transition:
    opacity 420ms ease,
    transform 820ms ease;
}

.carousel-track img.active {
  opacity: 1;
  transform: scale(1);
}

.carousel-button {
  position: absolute;
  top: 50%;
  z-index: 4;
  display: grid;
  width: 2.6rem;
  height: 2.6rem;
  place-items: center;
  border: 1px solid rgba(242, 240, 234, 0.2);
  border-radius: 8px;
  background: rgba(11, 13, 16, 0.72);
  color: var(--paper);
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
  transform: translateY(-50%);
  backdrop-filter: blur(14px);
  transition:
    border-color 180ms ease,
    background 180ms ease,
    transform 180ms ease;
}

.carousel-button:hover,
.carousel-button:focus-visible {
  border-color: rgba(77, 124, 254, 0.78);
  background: rgba(77, 124, 254, 0.36);
  transform: translateY(-50%) scale(1.05);
}

.carousel-prev {
  left: 0.85rem;
}

.carousel-next {
  right: 0.85rem;
}

.carousel-dots {
  position: absolute;
  right: 0;
  bottom: 1rem;
  left: 0;
  z-index: 4;
  display: flex;
  justify-content: center;
  gap: 0.45rem;
}

.carousel-dots button {
  width: 0.55rem;
  height: 0.55rem;
  padding: 0;
  border: 1px solid rgba(242, 240, 234, 0.38);
  border-radius: 999px;
  background: rgba(242, 240, 234, 0.28);
  cursor: pointer;
  transition:
    width 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.carousel-dots button.active {
  width: 1.5rem;
  border-color: rgba(77, 124, 254, 0.86);
  background: var(--blue);
}

.video-visual video {
  display: block;
}

.project-card:not(.project-card-large) .project-visual {
  margin-bottom: 1rem;
}

.project-card-large .project-visual {
  min-height: 100%;
}

.skills-section,
.about-section {
  width: 100%;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(21, 24, 29, 0.54);
}

.skills-section > *,
.about-section > * {
  width: min(1180px, calc(100% - 2rem));
  margin-right: auto;
  margin-left: auto;
}

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

.skill-panel {
  min-height: 240px;
  padding: 1.2rem;
}

.skill-panel h3 {
  margin-bottom: 1.25rem;
}

.certifications-section {
  padding-bottom: 4rem;
}

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

.cert-card {
  display: grid;
  min-height: 240px;
  align-content: end;
  overflow: hidden;
  padding: 0.85rem;
  transition:
    opacity 200ms ease,
    transform 220ms ease,
    border-color 220ms ease;
}

.cert-card[hidden] {
  display: none;
}

.cert-card:hover,
.cert-card:focus-visible {
  border-color: rgba(77, 124, 254, 0.62);
  transform: translateY(-4px);
}

.cert-card img,
.cert-document {
  width: 100%;
  height: 150px;
  margin-bottom: 0.9rem;
  border: 1px solid rgba(242, 240, 234, 0.1);
  border-radius: 8px;
  background: rgba(11, 13, 16, 0.52);
  object-fit: cover;
}

.cert-document {
  display: grid;
  place-items: center;
  color: var(--blue);
  font-size: 2rem;
  font-weight: 900;
}

.cert-name {
  display: block;
}

.cert-name {
  color: var(--paper);
  font-weight: 850;
  line-height: 1.3;
}

.about-wrap {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 4rem;
}

.about-copy {
  display: grid;
  gap: 1rem;
}

.about-copy p {
  margin-bottom: 0;
}

.contact-section {
  padding-top: 5rem;
}

.contact-card {
  display: grid;
  max-width: 920px;
  min-height: 340px;
  align-content: center;
  gap: 1.2rem;
  padding: 2rem;
  overflow: hidden;
}

.contact-card h2 {
  max-width: 680px;
}

.contact-card p {
  max-width: 620px;
}

.phone-link {
  display: flex;
  width: fit-content;
  flex-wrap: wrap;
  gap: 0.45rem;
  color: var(--paper);
  font-size: 1.35rem;
  font-weight: 900;
  line-height: 1.2;
}

.phone-link span {
  color: var(--muted);
  font-size: 1rem;
}

.contact-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.contact-button {
  position: relative;
  display: grid;
  min-height: 6rem;
  align-content: space-between;
  overflow: hidden;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(242, 240, 234, 0.08), transparent 48%),
    rgba(11, 13, 16, 0.42);
  transition:
    border-color 180ms ease,
    background 180ms ease,
    transform 180ms ease;
}

.contact-button::before {
  position: absolute;
  inset: 0;
  pointer-events: none;
  content: "";
  background: linear-gradient(120deg, transparent, rgba(77, 124, 254, 0.24), transparent);
  opacity: 0;
  transform: translateX(-60%);
  transition:
    opacity 180ms ease,
    transform 520ms ease;
}

.contact-button span,
.contact-button strong {
  position: relative;
  z-index: 1;
}

.contact-button span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.contact-button strong {
  color: var(--paper);
  font-size: 0.9rem;
  line-height: 1.35;
  word-break: break-word;
}

.contact-button:hover,
.contact-button:focus-visible {
  border-color: rgba(77, 124, 254, 0.72);
  background:
    linear-gradient(145deg, rgba(77, 124, 254, 0.18), transparent 58%),
    rgba(21, 24, 29, 0.88);
  transform: translateY(-4px);
}

.contact-button:hover::before,
.contact-button:focus-visible::before {
  opacity: 1;
  transform: translateX(60%);
}

.contact-button-gmail {
  border-color: rgba(234, 67, 53, 0.72);
  background:
    linear-gradient(145deg, rgba(234, 67, 53, 0.78), rgba(251, 188, 5, 0.2) 52%, rgba(52, 168, 83, 0.16)),
    rgba(21, 24, 29, 0.9);
}

.contact-button-linkedin {
  border-color: rgba(10, 102, 194, 0.78);
  background:
    linear-gradient(145deg, rgba(10, 102, 194, 0.9), rgba(0, 119, 181, 0.3)),
    rgba(21, 24, 29, 0.9);
}

.contact-button-instagram {
  border-color: rgba(225, 48, 108, 0.76);
  background:
    linear-gradient(145deg, rgba(131, 58, 180, 0.82), rgba(225, 48, 108, 0.68) 48%, rgba(252, 175, 69, 0.32)),
    rgba(21, 24, 29, 0.9);
}

.contact-button-github {
  border-color: rgba(242, 240, 234, 0.38);
  background:
    linear-gradient(145deg, rgba(36, 41, 46, 0.95), rgba(88, 96, 105, 0.5)),
    rgba(11, 13, 16, 0.95);
}

.site-footer {
  justify-content: space-between;
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.92rem;
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 620ms ease,
    transform 620ms ease;
  transition-delay: var(--delay, 0ms);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  .section {
    padding: 5.5rem 0;
  }

  h1 {
    font-size: 3.8rem;
  }

  h2 {
    font-size: 2.35rem;
  }

  .project-card-large,
  .about-wrap {
    grid-template-columns: 1fr;
  }

  .project-card-large .project-visual {
    min-height: 360px;
    order: -1;
  }

  .skills-grid,
  .cert-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .site-header {
    align-items: flex-start;
    width: calc(100% - 1rem);
    margin-top: 0.5rem;
  }

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: calc(100% + 0.45rem);
    right: 0;
    left: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 0.55rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(11, 13, 16, 0.94);
    box-shadow: var(--shadow);
  }

  .site-nav.open {
    display: flex;
  }

  .site-nav a {
    padding: 0.9rem 1rem;
  }

  .section {
    width: min(100% - 1rem, 1180px);
    padding: 4.5rem 0;
  }

  .hero {
    min-height: 92vh;
    padding-top: 8rem;
  }

  h1 {
    font-size: 3rem;
  }

  h2 {
    font-size: 2rem;
  }

  .hero-lede {
    font-size: 1.08rem;
  }

  .hero-proof,
  .projects-grid,
  .skills-grid,
  .cert-grid {
    grid-template-columns: 1fr;
  }

  .hero-proof > div {
    min-height: 7rem;
  }

  .project-card {
    min-height: 380px;
  }

  .project-card-large .project-visual {
    min-height: 280px;
  }

  .contact-card {
    min-height: 300px;
    padding: 1.25rem;
  }

  .contact-actions {
    grid-template-columns: 1fr;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
}

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

  .reveal {
    opacity: 1;
    transform: none;
  }
}
