/* ============================================================
   VARIABLES
   ============================================================ */
:root {
  --bg-primary:    #0a0e1a;
  --bg-secondary:  #0d1117;
  --bg-card:       #111827;
  --bg-card-hover: #161f30;
  --neon-green:    #00ff88;
  --neon-cyan:     #00d4ff;
  --neon-purple:   #a855f7;
  --text-primary:  #e2e8f0;
  --text-secondary:#94a3b8;
  --text-dim:      #4a5568;
  --border:        #1e2a3a;
  --border-bright: #2d3f55;
  --font-mono:     'JetBrains Mono', 'Fira Code', monospace;
  --font-sans:     'Inter', system-ui, sans-serif;
  --radius:        8px;
  --transition:    0.3s ease;
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-sans);
  line-height: 1.6;
  overflow-x: hidden;
}

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

ul { list-style: none; }

img { max-width: 100%; height: auto; }

/* ============================================================
   SCROLLBAR
   ============================================================ */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); }
::-webkit-scrollbar-thumb { background: var(--border-bright); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--neon-green); }

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 100;
  padding: 1rem 0;
  background: transparent;
  transition: background var(--transition), backdrop-filter var(--transition);
}

.nav.scrolled {
  background: rgba(10, 14, 26, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__logo {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--neon-green);
  letter-spacing: -0.02em;
}

.nav__logo-bracket { color: var(--text-dim); }

.nav__logo-cursor {
  display: inline-block;
  animation: blink 1s step-end infinite;
  color: var(--neon-green);
}

.nav__links {
  display: flex;
  gap: 2rem;
}

.nav__link {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-secondary);
  transition: color var(--transition);
  position: relative;
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--neon-green);
  transition: width var(--transition);
}

.nav__link:hover { color: var(--neon-green); }
.nav__link:hover::after { width: 100%; }

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-secondary);
  transition: var(--transition);
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--bg-primary);
}

.hero__canvas {
  position: absolute;
  inset: 0;
  opacity: 0.15;
  pointer-events: none;
}

.hero__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  padding: 2rem;
  text-align: center;
}

.hero__terminal {
  background: var(--bg-card);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius);
  width: 100%;
  max-width: 620px;
  overflow: hidden;
  box-shadow: 0 0 40px rgba(0, 255, 136, 0.08), 0 20px 60px rgba(0, 0, 0, 0.5);
}

.hero__terminal-bar {
  background: var(--bg-secondary);
  padding: 0.6rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.dot--red    { background: #ff5f57; }
.dot--yellow { background: #ffbd2e; }
.dot--green  { background: #28c840; }

.hero__terminal-title {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-left: 0.5rem;
}

.hero__terminal-body {
  padding: 1.5rem;
  text-align: left;
}

.hero__terminal-line {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.4rem;
}

.hero__terminal-line--dim { color: var(--text-dim); margin-top: 0.8rem; }

.hero__prompt { color: var(--neon-green); margin-right: 0.25rem; }
.hero__cmd    { color: var(--neon-cyan); }

.hero__name {
  font-family: var(--font-mono);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--neon-green);
  text-shadow: 0 0 20px rgba(0, 255, 136, 0.4);
  margin-bottom: 0.8rem;
  padding-left: 0;
}

.hero__role {
  font-family: var(--font-mono);
  font-size: 1.05rem;
  color: var(--neon-cyan);
  min-height: 1.6rem;
  margin-bottom: 0.4rem;
}

.hero__cursor {
  animation: blink 0.8s step-end infinite;
  color: var(--neon-cyan);
}

.hero__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: center;
}

.badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 0.35rem 0.9rem;
  border-radius: 2rem;
  border: 1px solid;
  letter-spacing: 0.03em;
}

.badge--cloud   { color: var(--neon-cyan);   border-color: var(--neon-cyan);   background: rgba(0,212,255,0.07); }
.badge--devops  { color: var(--neon-green);  border-color: var(--neon-green);  background: rgba(0,255,136,0.07); }
.badge--sre     { color: var(--neon-purple); border-color: var(--neon-purple); background: rgba(168,85,247,0.07); }
.badge--platform{ color: #f59e0b;            border-color: #f59e0b;            background: rgba(245,158,11,0.07); }

.hero__scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
}

.hero__scroll-arrow {
  display: block;
  width: 20px;
  height: 20px;
  border-right: 2px solid var(--neon-green);
  border-bottom: 2px solid var(--neon-green);
  transform: rotate(45deg);
  animation: scrollBounce 1.5s ease-in-out infinite;
  opacity: 0.6;
}

/* ============================================================
   SECTIONS
   ============================================================ */
.section {
  padding: 5rem 0;
}

.section--dark {
  background: var(--bg-secondary);
}

.section__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section__title {
  font-family: var(--font-mono);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 3rem;
}

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

/* ============================================================
   ABOUT
   ============================================================ */
.about__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 4rem;
  align-items: start;
}

.about__paragraph {
  color: var(--text-secondary);
  margin-bottom: 1rem;
  font-size: 0.95rem;
  line-height: 1.8;
}

.highlight {
  color: var(--neon-green);
  font-weight: 600;
}

.about__stats {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.stat {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--neon-green);
  padding: 1.2rem 1.5rem;
  border-radius: var(--radius);
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.2rem;
}

.stat__number {
  font-family: var(--font-mono);
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--neon-green);
  text-shadow: 0 0 15px rgba(0,255,136,0.3);
}

.stat__plus,
.stat__percent {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  color: var(--neon-green);
  margin-right: 0.5rem;
}

.stat__label {
  font-size: 0.8rem;
  color: var(--text-dim);
  width: 100%;
  font-family: var(--font-mono);
  letter-spacing: 0.05em;
}

/* ============================================================
   SKILLS
   ============================================================ */
.skills__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 2rem;
}

.skills__category {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.skills__category:hover {
  border-color: var(--border-bright);
  box-shadow: 0 0 20px rgba(0,255,136,0.05);
}

.skills__category-title {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--neon-cyan);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.skills__icon { font-size: 1rem; }

.skill-list { display: flex; flex-direction: column; gap: 1rem; }

.skill__header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.35rem;
}

.skill__name {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-primary);
}

.skill__pct {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--neon-green);
}

.skill__bar {
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}

.skill__fill {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--neon-green), var(--neon-cyan));
  border-radius: 2px;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 8px rgba(0, 255, 136, 0.4);
}

/* ============================================================
   TECH STACK
   ============================================================ */
.stack__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 1rem;
}

.stack__item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem 0.8rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  cursor: default;
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}

.stack__item:hover {
  border-color: var(--neon-green);
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(0,255,136,0.1);
}

.stack__icon {
  font-size: 1.5rem;
  color: var(--neon-cyan);
}

.stack__label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-secondary);
  text-align: center;
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact__wrapper {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2rem;
}

.contact__tagline {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 2;
}

.contact__commit {
  color: var(--neon-green);
  font-size: 1.2rem;
  font-weight: 600;
}

.contact__links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.contact__link {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  padding: 0.7rem 1.5rem;
  border-radius: var(--radius);
  border: 1px solid;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  transition: all var(--transition);
}

.contact__link-icon { font-size: 1rem; }

.contact__link--github {
  color: var(--text-primary);
  border-color: var(--border-bright);
  background: var(--bg-card);
}
.contact__link--github:hover {
  border-color: var(--neon-green);
  color: var(--neon-green);
  box-shadow: 0 0 15px rgba(0,255,136,0.15);
}

.contact__link--linkedin {
  color: var(--text-primary);
  border-color: var(--border-bright);
  background: var(--bg-card);
}
.contact__link--linkedin:hover {
  border-color: var(--neon-cyan);
  color: var(--neon-cyan);
  box-shadow: 0 0 15px rgba(0,212,255,0.15);
}

.contact__link--email {
  color: var(--text-primary);
  border-color: var(--border-bright);
  background: var(--bg-card);
}
.contact__link--email:hover {
  border-color: var(--neon-purple);
  color: var(--neon-purple);
  box-shadow: 0 0 15px rgba(168,85,247,0.15);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 2rem 0;
}

.footer__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer__text {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-dim);
}

.footer__bracket { color: var(--neon-green); }

.footer__sub {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  opacity: 0.6;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

@keyframes scrollBounce {
  0%, 100% { transform: rotate(45deg) translateY(0); }
  50%       { transform: rotate(45deg) translateY(6px); }
}

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

.animate-in {
  animation: fadeInUp 0.6s ease forwards;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
  .nav__links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(10, 14, 26, 0.97);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    align-items: center;
    padding: 1.5rem 0;
    gap: 1.2rem;
  }

  .nav__links.open { display: flex; }

  .nav__toggle { display: flex; }

  .hero__name { font-size: 1.2rem; }

  .about__grid { grid-template-columns: 1fr; gap: 2rem; }

  .skills__grid { grid-template-columns: 1fr; }

  .stack__grid { grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)); }

  .section__title { font-size: 1.2rem; }

  .contact__links { flex-direction: column; }

  .contact__link { justify-content: center; }
}

@media (max-width: 480px) {
  .hero__terminal-body { padding: 1rem; }
  .hero__name { font-size: 1rem; }
  .badge { font-size: 0.7rem; padding: 0.3rem 0.7rem; }
}
