/* ===== VARIABLES ===== */
:root{
  --bg: #ffffff;
  --bg-alt: #f4f6fb;
  --surface: #ffffff;
  --border: #e2e6f0;
  --text: #1a1f36;
  --text-muted: #6b7280;
  --accent: #4f8cff;
  --accent-2: #7c5cff;
}

*{ scroll-behavior: smooth; }

body{
  background: var(--bg);
  color: var(--text);
  font-family: 'Poppins', sans-serif;
  overflow-x: hidden;
}

h1,h2,h3,h4,h5,h6{ font-weight: 700; }

.text-accent{ color: var(--accent); }

a{ text-decoration: none; }

/* ===== NAVBAR ===== */
#mainNav{
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: all .3s ease;
  padding: 1rem 0;
}
#mainNav.scrolled{
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--border);
  padding: .6rem 0;
  box-shadow: 0 4px 20px rgba(20,30,60,.06);
}
.navbar-brand{
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--text) !important;
}
.navbar-nav .nav-link{
  color: var(--text-muted) !important;
  font-weight: 500;
  margin: 0 .6rem;
  position: relative;
  transition: color .2s;
}
.navbar-nav .nav-link::after{
  content:"";
  position:absolute;
  left:0; bottom:-4px;
  width:0; height:2px;
  background: var(--accent);
  transition: width .25s ease;
}
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active{ color: var(--text) !important; }
.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after{ width: 100%; }

.navbar-toggler{ border-color: var(--border); }

/* ===== BUTTONS ===== */
.btn-accent{
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  border: none;
  font-weight: 600;
  padding: .7rem 1.6rem;
  border-radius: 8px;
  transition: transform .2s ease, box-shadow .2s ease;
}
.btn-accent:hover{
  color:#fff;
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(79,140,255,.35);
}
.btn-outline-light{
  border-radius: 8px;
  padding: .7rem 1.6rem;
  font-weight: 600;
  color: var(--text);
  border: 1.5px solid var(--border);
}
.btn-outline-light:hover{
  color: #fff;
  background: var(--text);
  border-color: var(--text);
}

/* ===== HERO ===== */
.hero{
  min-height: 100vh;
  position: relative;
  padding-top: 6rem;
  background:
    radial-gradient(circle at 15% 20%, rgba(79,140,255,.15), transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(124,92,255,.15), transparent 40%),
    var(--bg);
}
.hero-eyebrow{
  color: var(--accent);
  font-weight: 600;
  letter-spacing: 1px;
  margin-bottom: .5rem;
}
.hero-title{
  font-size: clamp(3rem, 8vw, 5rem);
  font-weight: 800;
  margin-bottom: .3rem;
  background: linear-gradient(135deg, #1a1f36, var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-subtitle{
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  color: var(--text-muted);
  font-family: 'JetBrains Mono', monospace;
  margin-bottom: 1.5rem;
  min-height: 2.2rem;
}
.cursor{
  color: var(--accent);
  animation: blink 1s step-start infinite;
}
@keyframes blink{ 50%{ opacity: 0; } }
.hero-text{
  color: var(--text-muted);
  max-width: 560px;
  margin-bottom: 2rem;
  line-height: 1.8;
}
.social-links{ display:flex; gap: .8rem; }
.social-links a{
  width: 42px; height: 42px;
  display:flex; align-items:center; justify-content:center;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text-muted);
  transition: all .25s ease;
}
.social-links a:hover{
  color:#fff;
  background: var(--accent);
  border-color: var(--accent);
  transform: translateY(-3px);
}
.scroll-down{
  position: absolute;
  bottom: 30px; left: 50%;
  transform: translateX(-50%);
  color: var(--text-muted);
  font-size: 1.5rem;
  animation: bounce 2s infinite;
}
@keyframes bounce{
  0%,20%,50%,80%,100%{ transform: translate(-50%,0); }
  40%{ transform: translate(-50%,-10px); }
  60%{ transform: translate(-50%,-5px); }
}

/* Code window */
.code-window{
  background: #131a2e;
  border: 1px solid #232b45;
  border-radius: 12px;
  overflow: hidden;
  text-align: left;
  box-shadow: 0 25px 60px rgba(20,30,60,.18);
  transform: rotate(-2deg);
  transition: transform .3s ease;
}
.code-window:hover{ transform: rotate(0deg); }
.code-window-header{
  background: #1a2138;
  padding: .7rem 1rem;
  display:flex;
  align-items:center;
  gap: .4rem;
  border-bottom: 1px solid #232b45;
}
.dot{ width:11px; height:11px; border-radius:50%; display:inline-block; }
.dot.red{ background:#ff5f56; }
.dot.yellow{ background:#ffbd2e; }
.dot.green{ background:#27c93f; }
.code-title{
  margin-left: .6rem;
  color: #9aa3bd;
  font-size: .8rem;
  font-family: 'JetBrains Mono', monospace;
}
.code-body{
  margin:0;
  padding: 1.2rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: .8rem;
  line-height: 1.6;
  color: #cdd6f4;
  max-height: 420px;
  overflow: auto;
}
.c-kw{ color:#c792ea; }
.c-type{ color:#82aaff; }
.c-str{ color:#c3e88d; }

/* ===== SECTIONS ===== */
.section-py{ padding: 6rem 0; }
.bg-alt{ background: var(--bg-alt); }
.section-heading{ text-align:center; margin-bottom: 3.5rem; }
.section-heading .eyebrow{
  color: var(--accent);
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-size: .85rem;
  margin-bottom: .5rem;
}
.section-heading h2{ font-size: clamp(1.8rem, 4vw, 2.5rem); }

/* ===== ABOUT ===== */
.about-photo{ display:flex; justify-content:center; }
.about-photo-inner{
  width: 280px; height: 280px;
  border-radius: 30px;
  background: linear-gradient(135deg, rgba(79,140,255,.15), rgba(124,92,255,.15));
  border: 1px solid var(--border);
  display:flex; align-items:center; justify-content:center;
}
.about-photo-inner i{
  font-size: 8rem;
  color: var(--accent);
}
.info-item{
  display:flex; flex-direction:column;
  padding: .8rem 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: .5rem;
}
.info-item span{ color: var(--text-muted); font-size: .8rem; }
.info-item strong{ color: var(--text); }

/* ===== SKILLS ===== */
.skill-card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.8rem 1.2rem;
  text-align:center;
  height: 100%;
  box-shadow: 0 6px 20px rgba(20,30,60,.05);
  transition: transform .25s ease, border-color .25s ease;
}
.skill-card:hover{
  transform: translateY(-6px);
  border-color: var(--accent);
}
.skill-card i{ font-size: 2.2rem; color: var(--accent); margin-bottom: .8rem; }
.skill-card h5{ font-size: 1rem; margin-bottom: 1rem; }
.progress{
  height: 8px;
  background: var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.progress-bar{
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  font-size: 0;
  border-radius: 10px;
}
.tech-badge{
  display:inline-flex;
  align-items:center;
  gap: .5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: .5rem 1rem;
  border-radius: 30px;
  font-size: .85rem;
  transition: all .25s ease;
}
.tech-badge:hover{
  color: #fff;
  border-color: var(--accent);
  background: rgba(79,140,255,.1);
}

/* ===== PROJECTS ===== */
.project-card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2rem;
  height: 100%;
  box-shadow: 0 6px 20px rgba(20,30,60,.05);
  transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
}
.project-card:hover{
  transform: translateY(-8px);
  border-color: var(--accent);
  box-shadow: 0 20px 40px rgba(20,30,60,.12);
}
.project-icon{
  width: 56px; height: 56px;
  display:flex; align-items:center; justify-content:center;
  border-radius: 12px;
  background: rgba(79,140,255,.12);
  color: var(--accent);
  font-size: 1.6rem;
  margin-bottom: 1.2rem;
}
.project-card h5{ margin-bottom: .6rem; }
.project-card p{ font-size: .92rem; }
.project-tags{ margin-top: 1rem; display:flex; gap:.5rem; flex-wrap:wrap; }
.project-tags span{
  font-size: .72rem;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: .25rem .7rem;
  border-radius: 20px;
}

/* ===== TIMELINE ===== */
.timeline{ position: relative; padding-left: 2rem; }
.timeline::before{
  content:"";
  position:absolute;
  left: 6px; top: 6px; bottom: 6px;
  width: 2px;
  background: var(--border);
}
.timeline-item{ position: relative; padding-bottom: 2rem; }
.timeline-item:last-child{ padding-bottom: 0; }
.timeline-item::before{
  content:"";
  position:absolute;
  left: -2rem;
  top: 4px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--bg);
  box-shadow: 0 0 0 2px var(--accent);
}
.timeline-date{
  display:inline-block;
  color: var(--accent);
  font-family: 'JetBrains Mono', monospace;
  font-size: .8rem;
  margin-bottom: .3rem;
}
.timeline-item h6{ margin-bottom: .4rem; font-size: 1.05rem; }
.timeline-item p{ font-size: .9rem; margin-bottom: 0; }

/* ===== CONTACT ===== */
.contact-info-item{
  display:flex;
  align-items:center;
  gap: 1rem;
  margin-bottom: 1.3rem;
}
.contact-info-item i{
  width: 46px; height: 46px;
  display:flex; align-items:center; justify-content:center;
  border-radius: 50%;
  background: rgba(79,140,255,.12);
  color: var(--accent);
  font-size: 1.1rem;
  flex-shrink: 0;
}
.contact-info-item span{ display:block; font-size: .8rem; color: var(--text-muted); }
.contact-info-item strong{ color: var(--text); }

.form-label{ color: var(--text-muted); font-size: .9rem; }
.form-control{
  background: var(--bg-alt);
  border: 1px solid var(--border);
  color: var(--text);
  padding: .7rem 1rem;
  border-radius: 8px;
}
.form-control:focus{
  background: #fff;
  color: var(--text);
  border-color: var(--accent);
  box-shadow: 0 0 0 .2rem rgba(79,140,255,.2);
}
.form-control::placeholder{ color: #a0a6ba; }

/* ===== FOOTER ===== */
.footer{
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 2.2rem 0;
  color: var(--text-muted);
}
.footer .social-links{ display:flex; gap: .8rem; margin-top: 1rem; }

/* ===== BACK TO TOP ===== */
#backToTop{
  position: fixed;
  bottom: 25px; right: 25px;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color:#fff;
  font-size: 1.1rem;
  display:flex; align-items:center; justify-content:center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all .3s ease;
  z-index: 999;
  cursor: pointer;
}
#backToTop.show{
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* ===== REVEAL ANIMATION ===== */
[data-aos]{
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .6s ease, transform .6s ease;
}
[data-aos].aos-visible{
  opacity: 1;
  transform: translateY(0);
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar{ width: 10px; }
::-webkit-scrollbar-track{ background: var(--bg); }
::-webkit-scrollbar-thumb{ background: var(--border); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover{ background: var(--accent); }
