:root {
  --bg-main: #f3f8ff;
  --bg-soft: #e7effa;
  --ink: #0e243b;
  --ink-soft: #47607a;
  --accent: #0fd6c8;
  --accent-strong: #08aaa0;
  --accent-warm: #ff8a4c;
  --panel: #ffffff;
  --line: rgba(14, 36, 59, 0.12);
  --radius-lg: 1.25rem;
  --radius-md: 0.95rem;
  --shadow-lg: 0 24px 44px rgba(12, 37, 64, 0.16);
  --shadow-md: 0 12px 28px rgba(12, 37, 64, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Chakra Petch", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(
      circle at 10% 15%,
      rgba(15, 214, 200, 0.2),
      transparent 38%
    ),
    radial-gradient(
      circle at 90% 88%,
      rgba(255, 138, 76, 0.18),
      transparent 35%
    ),
    linear-gradient(180deg, #f9fcff 0%, var(--bg-main) 45%, #f2f7ff 100%);
  min-height: 100vh;
}

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

p {
  margin-bottom: 0;
}

h1,
h2,
h3,
h4 {
  margin-bottom: 0;
  line-height: 1.2;
}

.noise-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
  background-size: 24px 24px;
  mix-blend-mode: soft-light;
  opacity: 0.2;
}

.site-header {
  position: relative;
  overflow: hidden;
  padding-bottom: clamp(4rem, 8vw, 6rem);
  background: linear-gradient(135deg, #0e2134 0%, #1a3c5f 55%, #195f78 100%);
  color: #f3fbff;
  z-index: 1;
}

.site-header::before {
  content: "";
  position: absolute;
  width: 24rem;
  height: 24rem;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(15, 214, 200, 0.35) 0%,
    transparent 70%
  );
  right: -6rem;
  top: -8rem;
}

.site-header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 5.5rem;
  background: var(--bg-main);
  clip-path: polygon(0 100%, 100% 42%, 100% 100%);
}

.container {
  position: relative;
  z-index: 1;
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.25rem;
}

.brand {
  font-family: "Orbitron", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
}

.brand-dot {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 14px rgba(15, 214, 200, 0.8);
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1.4rem;
  margin: 0;
  padding: 0;
}

.nav-links a {
  font-weight: 600;
  position: relative;
  padding-bottom: 0.25rem;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

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

.nav-toggle {
  display: none;
  width: 2.8rem;
  height: 2.8rem;
  border: 1px solid rgba(243, 251, 255, 0.35);
  border-radius: 0.75rem;
  background: rgba(255, 255, 255, 0.06);
  padding: 0.45rem;
  flex-direction: column;
  justify-content: center;
  gap: 0.35rem;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: #f3fbff;
}

.hero {
  padding-top: clamp(2.4rem, 5vw, 4.2rem);
}

.eyebrow {
  display: inline-block;
  font-family: "Orbitron", sans-serif;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-size: 0.78rem;
  margin-bottom: 0.8rem;
  color: var(--accent);
}

.hero h1 {
  font-family: "Orbitron", sans-serif;
  font-size: clamp(1.85rem, 4.2vw, 3.15rem);
  max-width: 18ch;
  margin-bottom: 0.9rem;
}

.hero-role {
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

#typed-role {
  color: var(--accent);
  font-weight: 700;
  border-right: 2px solid currentColor;
  padding-right: 0.2rem;
  animation: cursorBlink 0.8s steps(1) infinite;
}

.hero-copy {
  max-width: 62ch;
  color: rgba(243, 251, 255, 0.85);
}

.hero-cta {
  margin-top: 1.7rem;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.btn-tech {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-width: 11rem;
  padding: 0.72rem 1.1rem;
  border-radius: 999px;
  font-weight: 700;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    background-color 0.2s ease;
}

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

.btn-primary-tech {
  background: linear-gradient(90deg, var(--accent), #32efe2);
  color: #032328;
  box-shadow: 0 10px 22px rgba(15, 214, 200, 0.36);
}

.btn-outline-tech {
  border: 1px solid rgba(243, 251, 255, 0.42);
  color: #f3fbff;
}

.btn-outline-tech:hover,
.btn-outline-tech:focus-visible {
  background: rgba(243, 251, 255, 0.12);
}

.hero-metrics {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem;
  max-width: 53rem;
}

.hero-metrics li {
  border: 1px solid rgba(243, 251, 255, 0.18);
  background: rgba(243, 251, 255, 0.06);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
}

.metric-value {
  display: block;
  font-family: "Orbitron", sans-serif;
  font-size: 1.35rem;
  color: var(--accent);
}

.metric-label {
  font-size: 0.94rem;
  color: rgba(243, 251, 255, 0.84);
}

main {
  position: relative;
  z-index: 1;
}

.section {
  padding: clamp(3.5rem, 6vw, 5.5rem) 0;
}

.section-alt {
  background: linear-gradient(180deg, #f7fbff 0%, var(--bg-soft) 100%);
  border-block: 1px solid var(--line);
}

.section-heading {
  max-width: 43rem;
  margin-bottom: 2rem;
}

.section-heading h2 {
  font-family: "Orbitron", sans-serif;
  font-size: clamp(1.4rem, 2.4vw, 2rem);
}

.glass-card {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.4rem;
  box-shadow: var(--shadow-md);
}

.about-copy {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.about-copy p {
  color: var(--ink-soft);
  line-height: 1.65;
}

.glass-card h3,
.timeline h3,
.skill-card h3,
.project-card h3 {
  font-family: "Orbitron", sans-serif;
  font-size: 1rem;
}

.tag-list {
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.tag-list li {
  border: 1px solid rgba(8, 170, 160, 0.35);
  color: var(--ink);
  background: rgba(15, 214, 200, 0.12);
  border-radius: 999px;
  padding: 0.32rem 0.7rem;
  font-size: 0.9rem;
}

.stack-note {
  margin-top: 0.9rem;
  color: var(--ink-soft);
}

.cert-list {
  margin: 0.7rem 0 0;
  padding-left: 1.1rem;
  color: var(--ink-soft);
  display: grid;
  gap: 0.4rem;
}

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

.skill-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1.1rem;
  box-shadow: var(--shadow-md);
}

.skill-card p {
  margin-top: 0.72rem;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.skill-meter {
  width: 100%;
  height: 0.6rem;
  margin-top: 0.95rem;
  border-radius: 999px;
  background: rgba(14, 36, 59, 0.1);
  overflow: hidden;
}

.skill-meter span {
  display: block;
  width: var(--level);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--accent-warm));
}

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

.project-card {
  height: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1.2rem;
  background: var(--panel);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.project-type {
  margin-bottom: 0.35rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-strong);
  font-weight: 700;
}

.project-card p {
  color: var(--ink-soft);
  line-height: 1.55;
}

.tech-badges {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.tech-badges li {
  background: rgba(255, 138, 76, 0.14);
  border: 1px solid rgba(255, 138, 76, 0.3);
  color: #823f1b;
  border-radius: 999px;
  padding: 0.26rem 0.65rem;
  font-size: 0.82rem;
  font-weight: 600;
}

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

.project-links a {
  font-weight: 700;
  color: var(--ink);
}

.project-links a:hover,
.project-links a:focus-visible {
  color: var(--accent-strong);
}

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

.timeline {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--panel);
  box-shadow: var(--shadow-md);
  padding: 1.2rem;
}

.timeline h3 {
  margin-bottom: 1rem;
}

.timeline-item {
  position: relative;
  border-left: 2px solid rgba(8, 170, 160, 0.35);
  padding-left: 1rem;
  margin-left: 0.3rem;
}

.timeline-item + .timeline-item {
  margin-top: 1rem;
}

.timeline-item::before {
  content: "";
  width: 0.58rem;
  height: 0.58rem;
  border-radius: 50%;
  background: var(--accent-strong);
  position: absolute;
  left: -0.38rem;
  top: 0.1rem;
}

.time-range {
  color: var(--accent-strong);
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.timeline-item h4 {
  font-size: 1rem;
  margin-bottom: 0.45rem;
}

.timeline-item p {
  color: var(--ink-soft);
  line-height: 1.55;
}

.contact-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--panel);
  box-shadow: var(--shadow-lg);
  padding: clamp(1.2rem, 2.5vw, 2rem);
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 1.3rem;
}

.contact-panel h2 {
  font-family: "Orbitron", sans-serif;
  margin-bottom: 0.95rem;
}

.contact-panel p {
  color: var(--ink-soft);
  line-height: 1.6;
}

.contact-panel .btn-tech {
  margin-top: 1.25rem;
}

.contact-list {
  margin: 0;
  display: grid;
  gap: 0.7rem;
}

.contact-list li {
  border: 1px solid var(--line);
  border-radius: 0.8rem;
  padding: 0.75rem 0.9rem;
  background: #f8fcff;
  display: grid;
  gap: 0.35rem;
}

.contact-list span {
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--accent-strong);
}

.contact-list a,
.contact-list strong {
  color: var(--ink);
  font-weight: 600;
}

.site-footer {
  padding: 1.7rem 0 2.2rem;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.65);
}

.site-footer p {
  color: var(--ink-soft);
  font-size: 0.95rem;
}

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

.js-enabled .reveal {
  opacity: 0;
  transform: translateY(28px);
}

.js-enabled .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.55s ease,
    transform 0.55s ease;
}

@keyframes cursorBlink {
  50% {
    border-right-color: transparent;
  }
}

@media (max-width: 991px) {
  .nav-toggle {
    display: flex;
  }

  .nav-shell {
    position: relative;
  }

  .nav-links {
    position: absolute;
    top: calc(100% + 0.7rem);
    left: 0;
    right: 0;
    flex-direction: column;
    background: rgba(9, 25, 40, 0.96);
    border: 1px solid rgba(243, 251, 255, 0.18);
    border-radius: var(--radius-md);
    max-height: 0;
    overflow: hidden;
    padding: 0;
    transition:
      max-height 0.3s ease,
      padding 0.3s ease;
    box-shadow: var(--shadow-md);
  }

  .nav-links.is-open {
    max-height: 18rem;
    padding: 0.85rem;
  }

  .hero-metrics {
    grid-template-columns: 1fr 1fr;
  }

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

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

@media (max-width: 767px) {
  .hero h1 {
    max-width: 100%;
  }

  .hero-copy {
    font-size: 0.98rem;
  }

  .hero-metrics,
  .skills-grid,
  .project-grid,
  .timeline-grid {
    grid-template-columns: 1fr;
  }

  .hero-cta {
    gap: 0.6rem;
  }

  .btn-tech {
    min-width: 100%;
  }

  .section-heading {
    margin-bottom: 1.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }

  #typed-role {
    border-right: 0;
  }
}
