:root {
  color-scheme: dark;
  --bg: #020406;
  --panel: rgba(3, 14, 18, 0.74);
  --panel-strong: rgba(5, 22, 28, 0.9);
  --text: #ecfff8;
  --muted: #87a8a1;
  --soft: #c9fff0;
  --line: rgba(57, 255, 136, 0.2);
  --line-strong: rgba(0, 229, 255, 0.34);
  --cyan: #00e5ff;
  --green: #39ff88;
  --yellow: #ffd166;
  --rose: #ff3d81;
  --indigo: #8a7dff;
  --shadow: 0 28px 90px rgba(0, 0, 0, 0.58);
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  font-family: "Inter", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 16% 8%, rgba(57, 255, 136, 0.18), transparent 25rem),
    radial-gradient(circle at 84% 12%, rgba(0, 229, 255, 0.2), transparent 27rem),
    radial-gradient(circle at 76% 60%, rgba(255, 61, 129, 0.1), transparent 24rem),
    linear-gradient(135deg, #020406 0%, #051014 44%, #02060a 100%);
  background-attachment: scroll;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  content: "";
  pointer-events: none;
  background:
    linear-gradient(rgba(57, 255, 136, 0.09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 229, 255, 0.08) 1px, transparent 1px),
    linear-gradient(115deg, transparent 0 48%, rgba(57, 255, 136, 0.05) 49%, transparent 50% 100%);
  background-size: 58px 58px, 58px 58px, 220px 220px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent 82%);
}

body::after {
  position: fixed;
  inset: 0;
  z-index: 100;
  content: "";
  pointer-events: none;
  background:
    repeating-linear-gradient(
      to bottom,
      rgba(236, 255, 248, 0.035) 0,
      rgba(236, 255, 248, 0.035) 1px,
      transparent 1px,
      transparent 5px
  );
  mix-blend-mode: screen;
  opacity: 0.12;
}

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

svg {
  width: 1.08em;
  height: 1.08em;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.page-shell {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 0;
  backdrop-filter: blur(20px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--soft);
  font-family: var(--mono);
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0;
  text-shadow: 0 0 18px rgba(57, 255, 136, 0.35);
}

.brand span {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid rgba(57, 255, 136, 0.48);
  border-radius: 8px;
  color: var(--green);
  background:
    linear-gradient(135deg, rgba(57, 255, 136, 0.15), rgba(0, 229, 255, 0.1)),
    #02090b;
  box-shadow:
    0 0 0 1px rgba(0, 229, 255, 0.12) inset,
    0 0 24px rgba(57, 255, 136, 0.26);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(2, 7, 10, 0.72);
  box-shadow:
    0 18px 58px rgba(0, 0, 0, 0.36),
    0 0 0 1px rgba(0, 229, 255, 0.08) inset;
}

.nav-links a {
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 800;
  transition: color 220ms ease, background 220ms ease, transform 220ms ease, text-shadow 220ms ease;
}

.nav-links a:hover {
  color: var(--green);
  background: rgba(57, 255, 136, 0.08);
  text-shadow: 0 0 16px rgba(57, 255, 136, 0.7);
  transform: translateY(-1px);
}

.section-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(330px, 0.92fr);
  gap: 30px;
  align-items: center;
}

.hero {
  min-height: calc(100vh - 88px);
  padding: 80px 0 72px;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.eyebrow,
.card-kicker {
  margin: 0 0 14px;
  color: var(--green);
  font-family: var(--mono);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  text-shadow: 0 0 16px rgba(57, 255, 136, 0.55);
}

.eyebrow::before,
.card-kicker::before {
  content: ">_ ";
  color: var(--cyan);
}

.terminal-line {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  width: max-content;
  max-width: 100%;
  min-height: 38px;
  padding: 8px 12px;
  margin: 0 0 20px;
  border: 1px solid rgba(57, 255, 136, 0.22);
  border-radius: 10px;
  color: var(--soft);
  background: rgba(2, 8, 10, 0.62);
  box-shadow: 0 0 22px rgba(57, 255, 136, 0.08);
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.4;
}

.terminal-prefix {
  color: var(--green);
}

#typing-text {
  color: var(--cyan);
}

.terminal-cursor {
  display: inline-block;
  width: 8px;
  height: 1.05em;
  margin-left: 2px;
  background: var(--green);
  box-shadow: 0 0 12px rgba(57, 255, 136, 0.72);
  animation: cursor-blink 1s steps(2, start) infinite;
}

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

h1 {
  max-width: 780px;
  margin-bottom: 16px;
  font-size: clamp(4rem, 11vw, 8.25rem);
  line-height: 0.9;
  letter-spacing: 0;
  text-shadow:
    0 0 18px rgba(0, 229, 255, 0.24),
    0 0 46px rgba(57, 255, 136, 0.14);
}

.role {
  max-width: 760px;
  margin-bottom: 22px;
  color: var(--cyan);
  font-family: var(--mono);
  font-size: clamp(1rem, 2.1vw, 1.58rem);
  font-weight: 900;
  line-height: 1.35;
  text-shadow: 0 0 18px rgba(0, 229, 255, 0.36);
}

.hero-description {
  max-width: 720px;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.82;
}

.hero-actions,
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}

.button,
.contact-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 48px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  font-family: var(--mono);
  font-weight: 900;
  transition:
    transform 220ms ease,
    border-color 220ms ease,
    background 220ms ease,
    box-shadow 220ms ease,
    color 220ms ease;
}

.button::before,
.contact-button::before {
  position: absolute;
  inset: 0 auto 0 -42%;
  width: 38%;
  content: "";
  background: linear-gradient(90deg, transparent, rgba(236, 255, 248, 0.24), transparent);
  transform: skewX(-18deg);
  transition: left 420ms ease;
}

.button:hover::before,
.contact-button:hover::before {
  left: 112%;
}

.button:hover,
.contact-button:hover,
.profile-card:hover,
.glass-card:hover {
  transform: translateY(-5px);
}

.button.primary {
  color: #00110b;
  border-color: transparent;
  background: linear-gradient(135deg, var(--green), var(--cyan));
  box-shadow:
    0 18px 42px rgba(57, 255, 136, 0.25),
    0 0 18px rgba(0, 229, 255, 0.18);
}

.button.secondary {
  color: var(--soft);
  background:
    linear-gradient(135deg, rgba(0, 229, 255, 0.1), rgba(57, 255, 136, 0.05)),
    rgba(2, 8, 10, 0.72);
}

.button.secondary:hover {
  border-color: rgba(0, 229, 255, 0.55);
  box-shadow: 0 0 24px rgba(0, 229, 255, 0.18);
}

.glass-card,
.profile-card {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(57, 255, 136, 0.075), rgba(0, 229, 255, 0.028)),
    var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.glass-card::before,
.profile-card::before {
  position: absolute;
  top: 0;
  left: 18px;
  right: 18px;
  height: 1px;
  content: "";
  background: linear-gradient(90deg, transparent, var(--green), var(--cyan), transparent);
  opacity: 0.7;
}

.profile-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 24px;
  min-height: 548px;
  padding: 22px;
  overflow: hidden;
  transition: transform 260ms ease, border-color 260ms ease, box-shadow 260ms ease;
}

.profile-card::after {
  position: absolute;
  inset: 22px;
  content: "";
  pointer-events: none;
  border: 1px solid rgba(0, 229, 255, 0.08);
  border-radius: 10px;
  background:
    linear-gradient(90deg, transparent 0 48%, rgba(57, 255, 136, 0.08) 49%, transparent 50% 100%);
  background-size: 180px 100%;
  opacity: 0.24;
}

.profile-card:hover {
  border-color: rgba(0, 229, 255, 0.52);
  box-shadow:
    0 34px 96px rgba(0, 0, 0, 0.58),
    0 0 36px rgba(0, 229, 255, 0.16);
}

.hero-visual {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  max-height: 300px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: 50% 20%;
  border: 1px solid rgba(0, 229, 255, 0.26);
  border-radius: 10px;
  filter: contrast(1.08) saturate(0.9);
  box-shadow:
    0 0 0 1px rgba(57, 255, 136, 0.08) inset,
    0 22px 64px rgba(0, 0, 0, 0.45);
}

.profile-summary {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.avatar {
  display: grid;
  width: 72px;
  height: 72px;
  place-items: center;
  border: 1px solid rgba(57, 255, 136, 0.52);
  border-radius: 16px;
  color: var(--green);
  background:
    linear-gradient(135deg, rgba(57, 255, 136, 0.16), rgba(0, 229, 255, 0.09)),
    #02090b;
  font-family: var(--mono);
  font-size: 2.35rem;
  font-weight: 900;
  box-shadow: 0 0 26px rgba(57, 255, 136, 0.2);
}

.profile-card h2 {
  margin-bottom: 12px;
  font-size: clamp(1.6rem, 3vw, 2rem);
  line-height: 1.15;
}

.profile-card p,
.about-card p,
.contact-card p {
  color: var(--muted);
  line-height: 1.76;
}

.stats-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.stats-grid strong,
.stats-grid span {
  display: block;
}

.stats-grid strong {
  margin-bottom: 4px;
  color: var(--green);
  font-family: var(--mono);
  font-size: 1.45rem;
  text-shadow: 0 0 16px rgba(57, 255, 136, 0.5);
}

.stats-grid span {
  color: var(--muted);
  font-size: 0.88rem;
}

.content-section {
  content-visibility: auto;
  contain-intrinsic-size: 720px;
  padding: 76px 0;
}

.section-heading {
  max-width: 820px;
  margin-bottom: 26px;
}

.section-heading h2 {
  margin-bottom: 0;
  font-size: clamp(2rem, 4vw, 3.1rem);
  line-height: 1.12;
  text-shadow: 0 0 24px rgba(0, 229, 255, 0.12);
}

.about-card,
.contact-card {
  padding: 30px;
}

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

.skill-card {
  min-height: 310px;
  padding: 24px;
  overflow: hidden;
  transition:
    transform 260ms ease,
    border-color 260ms ease,
    background 260ms ease,
    box-shadow 260ms ease;
}

.skill-card::after {
  position: absolute;
  inset: auto -28px -48px auto;
  width: 132px;
  height: 132px;
  content: "";
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 229, 255, 0.22), transparent 68%);
  opacity: 0;
  transition: opacity 260ms ease, transform 260ms ease;
}

.skill-card:hover {
  border-color: rgba(57, 255, 136, 0.5);
  box-shadow:
    0 26px 74px rgba(0, 0, 0, 0.52),
    0 0 34px rgba(57, 255, 136, 0.12);
}

.skill-card:hover::after {
  opacity: 1;
  transform: translate(-12px, -12px);
}

.skill-icon {
  display: grid;
  width: 50px;
  height: 50px;
  place-items: center;
  margin-bottom: 20px;
  border: 1px solid rgba(0, 229, 255, 0.35);
  border-radius: 12px;
  color: var(--cyan);
  background: rgba(0, 229, 255, 0.08);
  box-shadow: 0 0 18px rgba(0, 229, 255, 0.12);
  transition: transform 260ms ease, color 260ms ease, border-color 260ms ease, box-shadow 260ms ease;
}

.skill-card:hover .skill-icon {
  color: var(--green);
  border-color: rgba(57, 255, 136, 0.54);
  box-shadow: 0 0 24px rgba(57, 255, 136, 0.2);
  transform: rotate(-3deg) scale(1.06);
}

.skill-card h3 {
  margin-bottom: 16px;
  font-size: 1.15rem;
  line-height: 1.3;
}

.skill-card ul,
.timeline-item ul {
  display: grid;
  gap: 9px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.skill-card li,
.timeline-item li {
  position: relative;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.55;
}

.skill-card li::before,
.timeline-item li::before {
  position: absolute;
  top: 0.72em;
  left: 0;
  width: 6px;
  height: 6px;
  content: "";
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green), var(--cyan));
  box-shadow: 0 0 10px rgba(57, 255, 136, 0.55);
  transform: translateY(-50%);
}

.timeline {
  position: relative;
  display: grid;
  gap: 18px;
  padding-left: 28px;
}

.timeline::before {
  position: absolute;
  top: 14px;
  bottom: 14px;
  left: 8px;
  width: 2px;
  content: "";
  background: linear-gradient(to bottom, var(--green), var(--cyan), rgba(255, 61, 129, 0.26));
  box-shadow: 0 0 18px rgba(57, 255, 136, 0.35);
}

.timeline-item {
  padding: 24px;
  transition:
    transform 260ms ease,
    border-color 260ms ease,
    box-shadow 260ms ease;
}

.timeline-item:hover {
  border-color: rgba(0, 229, 255, 0.5);
  box-shadow:
    0 26px 74px rgba(0, 0, 0, 0.5),
    0 0 34px rgba(0, 229, 255, 0.13);
}

.timeline-marker {
  position: absolute;
  top: 30px;
  left: -27px;
  width: 16px;
  height: 16px;
  border: 3px solid #02090b;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green), var(--cyan));
  box-shadow:
    0 0 0 6px rgba(57, 255, 136, 0.12),
    0 0 26px rgba(0, 229, 255, 0.34);
}

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

.timeline-head h3 {
  margin-bottom: 6px;
  font-size: 1.24rem;
}

.timeline-head p {
  margin-bottom: 0;
  color: var(--muted);
  font-weight: 700;
}

.timeline-head span {
  flex: 0 0 auto;
  padding: 8px 12px;
  border: 1px solid rgba(57, 255, 136, 0.36);
  border-radius: 999px;
  color: var(--green);
  background: rgba(57, 255, 136, 0.08);
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 900;
  text-shadow: 0 0 14px rgba(57, 255, 136, 0.52);
}

.contact-section {
  padding-bottom: 42px;
}

.contact-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
}

.contact-card p {
  margin-bottom: 0;
}

.contact-actions {
  justify-content: flex-end;
  margin-top: 0;
}

.contact-button {
  min-width: 112px;
  color: var(--soft);
  background:
    linear-gradient(135deg, rgba(57, 255, 136, 0.08), rgba(0, 229, 255, 0.05)),
    rgba(2, 8, 10, 0.76);
}

.contact-button.whatsapp:hover {
  border-color: rgba(57, 255, 136, 0.76);
  background: rgba(57, 255, 136, 0.11);
}

.contact-button.email:hover {
  border-color: rgba(0, 229, 255, 0.76);
  background: rgba(0, 229, 255, 0.11);
}

.contact-button.github:hover {
  border-color: rgba(236, 255, 248, 0.62);
  background: rgba(236, 255, 248, 0.1);
}

.contact-button.linkedin:hover {
  border-color: rgba(138, 125, 255, 0.8);
  background: rgba(138, 125, 255, 0.14);
}

.site-footer {
  padding: 28px 0 44px;
  color: var(--muted);
  text-align: center;
}

.site-footer p {
  display: inline-flex;
  max-width: 100%;
  padding: 14px 18px;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(2, 8, 10, 0.76);
  box-shadow: 0 0 24px rgba(57, 255, 136, 0.08);
  backdrop-filter: blur(14px);
}

@keyframes scanline {
  from {
    transform: translateY(0);
  }

  to {
    transform: translateY(20px);
  }
}

@keyframes cursor-blink {
  50% {
    opacity: 0;
  }
}

@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;
  }
}

@media (max-width: 980px) {
  .page-shell {
    width: min(100% - 28px, 760px);
  }

  .site-header,
  .section-grid,
  .contact-card {
    grid-template-columns: 1fr;
  }

  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
  }

  .nav-links {
    width: 100%;
    justify-content: space-between;
    overflow-x: auto;
  }

  .nav-links a {
    white-space: nowrap;
  }

  .hero {
    min-height: auto;
    padding: 46px 0 50px;
  }

  .profile-card {
    min-height: auto;
  }

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

  .contact-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 22px, 440px);
  }

  .nav-links {
    gap: 4px;
    padding: 5px;
  }

  .nav-links a {
    padding: 9px 10px;
    font-size: 0.72rem;
  }

  h1 {
    font-size: clamp(3rem, 21vw, 4.8rem);
  }

  .role {
    font-size: 0.88rem;
    line-height: 1.55;
  }

  .hero-description {
    font-size: 0.94rem;
    line-height: 1.75;
  }

  .terminal-line {
    width: 100%;
    gap: 6px;
    padding: 7px 10px;
    font-size: 0.72rem;
  }

  .terminal-cursor {
    width: 6px;
  }

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

  .button,
  .contact-button {
    width: 100%;
  }

  .profile-summary,
  .timeline-head {
    grid-template-columns: 1fr;
  }

  .profile-summary {
    display: block;
  }

  .avatar {
    margin-bottom: 18px;
  }

  .profile-card,
  .about-card,
  .skill-card,
  .timeline-item,
  .contact-card {
    padding: 22px;
  }

  .skill-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .timeline {
    padding-left: 18px;
  }

  .timeline::before {
    left: 4px;
  }

  .timeline-marker {
    left: -25px;
  }

  .timeline-head {
    display: grid;
  }

  .timeline-head span {
    width: max-content;
  }

  .site-footer p {
    border-radius: 14px;
  }
}

@media (max-width: 768px), (hover: none) and (pointer: coarse) {
  html {
    scroll-behavior: auto;
  }

  body {
    background:
      radial-gradient(circle at 18% 4%, rgba(57, 255, 136, 0.12), transparent 20rem),
      radial-gradient(circle at 90% 10%, rgba(0, 229, 255, 0.12), transparent 18rem),
      linear-gradient(135deg, #020406 0%, #051014 48%, #02060a 100%);
  }

  body::before {
    position: absolute;
    background:
      linear-gradient(rgba(57, 255, 136, 0.045) 1px, transparent 1px),
      linear-gradient(90deg, rgba(0, 229, 255, 0.04) 1px, transparent 1px);
    background-size: 82px 82px;
    mask-image: none;
    opacity: 0.5;
  }

  body::after,
  .profile-card::after,
  .skill-card::after,
  .button::before,
  .contact-button::before {
    display: none;
  }

  .site-header,
  .glass-card,
  .profile-card,
  .site-footer p {
    backdrop-filter: none;
  }

  .glass-card,
  .profile-card {
    box-shadow: 0 14px 38px rgba(0, 0, 0, 0.36);
  }

  .brand,
  .eyebrow,
  .card-kicker,
  h1,
  .role,
  .stats-grid strong,
  .timeline-head span {
    text-shadow: none;
  }

  .hero-visual {
    max-height: 320px;
    filter: none;
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.34);
  }

  .nav-links a,
  .button,
  .contact-button,
  .profile-card,
  .glass-card,
  .skill-card,
  .skill-icon,
  .timeline-item {
    transition-duration: 120ms;
  }

  .button:hover,
  .contact-button:hover,
  .profile-card:hover,
  .glass-card:hover,
  .nav-links a:hover,
  .skill-card:hover .skill-icon {
    transform: none;
  }

  .profile-card:hover,
  .skill-card:hover,
  .timeline-item:hover {
    box-shadow: 0 14px 38px rgba(0, 0, 0, 0.36);
  }
}
