/* ===== RESET & BASE ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --bg: #0a0a0f;
  --bg2: #0f0f1a;
  --bg3: #13131f;
  --card: #141420;
  --card2: #1a1a2e;
  --border: rgba(255,255,255,0.07);
  --accent: #6c63ff;
  --accent2: #a78bfa;
  --accent3: #38bdf8;
  --green: #4ade80;
  --text: #e2e8f0;
  --muted: #94a3b8;
  --radius: 16px;
}
html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--text); font-family: 'Inter', sans-serif; line-height: 1.7; overflow-x: hidden; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
strong { color: #fff; }

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

/* ===== NAV ===== */
#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 4rem;
  background: rgba(10,10,15,0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s;
}
#navbar.scrolled { padding: 0.7rem 4rem; }
.nav-logo { font-size: 1.5rem; font-weight: 800; color: #fff; letter-spacing: -1px; }
.nav-logo .dot { color: var(--accent); }
.nav-links { display: flex; gap: 2rem; }
.nav-links a { font-size: 0.9rem; color: var(--muted); font-weight: 500; transition: color 0.2s; position: relative; }
.nav-links a::after { content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 2px; background: var(--accent); transition: width 0.3s; }
.nav-links a:hover { color: #fff; }
.nav-links a:hover::after { width: 100%; }
.btn-nav { background: var(--accent); color: #fff; padding: 0.5rem 1.4rem; border-radius: 8px; font-size: 0.9rem; font-weight: 600; transition: all 0.2s; }
.btn-nav:hover { background: var(--accent2); transform: translateY(-1px); }
.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; }
.hamburger span { display: block; width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: all 0.3s; }

/* ===== HERO ===== */
#hero {
  min-height: 100vh; display: flex; align-items: center;
  padding: 8rem 4rem 4rem;
  position: relative; overflow: hidden;
  gap: 4rem;
}
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.grid-overlay {
  position: absolute; inset: 0;
  background-image: linear-gradient(rgba(108,99,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(108,99,255,0.05) 1px, transparent 1px);
  background-size: 60px 60px;
}
.glow { position: absolute; border-radius: 50%; filter: blur(120px); opacity: 0.15; }
.glow-1 { width: 600px; height: 600px; background: var(--accent); top: -200px; right: -100px; }
.glow-2 { width: 400px; height: 400px; background: var(--accent3); bottom: -100px; left: 10%; }
.hero-content { position: relative; z-index: 1; flex: 1; max-width: 640px; min-height: 520px; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(74,222,128,0.1); border: 1px solid rgba(74,222,128,0.3);
  color: var(--green); padding: 0.4rem 1rem; border-radius: 50px;
  font-size: 0.85rem; font-weight: 500; margin-bottom: 1.5rem;
}
.pulse-dot {
  width: 8px; height: 8px; background: var(--green); border-radius: 50%;
  animation: pulse 2s infinite;
}
@keyframes pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:0.5;transform:scale(1.3)} }
#hero h1 { font-size: clamp(3rem, 6vw, 5rem); font-weight: 800; line-height: 1.1; margin-bottom: 1rem; color: #fff; }
.gradient-text { background: linear-gradient(135deg, var(--accent), var(--accent3)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-title { font-size: 1.2rem; color: var(--accent2); font-weight: 600; margin-bottom: 1rem; min-height: 1.8rem; display: block; overflow: hidden; white-space: nowrap; }
.hero-sub { color: var(--muted); font-size: 1rem; max-width: 520px; margin-bottom: 2rem; min-height: 3.4rem; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 3rem; }
.btn-primary {
  background: linear-gradient(135deg, var(--accent), #8b5cf6);
  color: #fff; padding: 0.8rem 2rem; border-radius: 10px;
  font-weight: 600; font-size: 0.95rem; border: none; cursor: pointer;
  transition: all 0.3s; display: inline-flex; align-items: center; gap: 8px;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgba(108,99,255,0.4); }
.btn-outline {
  border: 1px solid var(--border); color: var(--text);
  padding: 0.8rem 2rem; border-radius: 10px; font-weight: 600;
  font-size: 0.95rem; transition: all 0.3s;
}
.btn-outline:hover { border-color: var(--accent); color: var(--accent); background: rgba(108,99,255,0.05); }
.hero-stats { display: flex; align-items: center; gap: 2rem; }
.stat { display: flex; flex-direction: column; }
.stat-num { font-size: 1.8rem; font-weight: 800; color: #fff; line-height: 1; }
.stat-label { font-size: 0.75rem; color: var(--muted); margin-top: 2px; }
.stat-divider { width: 1px; height: 40px; background: var(--border); }

/* CODE CARD */
.hero-visual { position: relative; z-index: 1; flex: 1; display: flex; justify-content: center; align-items: center; }

/* ===== HERO PHOTO ===== */
.hero-photo-wrapper {
  position: relative; width: 360px; height: 420px;
  display: flex; align-items: center; justify-content: center;
}
.photo-ring {
  position: absolute; inset: -16px; border-radius: 50%;
  border: 2px solid transparent;
  background: linear-gradient(135deg, var(--accent), var(--accent3)) border-box;
  -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: destination-out; mask-composite: exclude;
  animation: spin 8s linear infinite;
}
.ring2 { inset: -28px; border-width: 1px; opacity: 0.4; animation-duration: 14s; animation-direction: reverse; }
@keyframes spin { to { transform: rotate(360deg); } }
.profile-photo-container {
  width: 300px; height: 360px; border-radius: 40% 40% 40% 40% / 30% 30% 50% 50%;
  overflow: hidden;
  border: 3px solid rgba(108,99,255,0.4);
  box-shadow: 0 0 60px rgba(108,99,255,0.3), 0 0 120px rgba(56,189,248,0.1);
  position: relative; background: var(--card2);
}
.profile-photo { width: 100%; height: 100%; object-fit: cover; object-position: center 15%; display: block; }
.profile-photo.loaded { display: block; }
.photo-placeholder {
  width: 100%; height: 100%; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 8px;
}
.photo-placeholder span {
  font-size: 4rem; font-weight: 800; color: var(--accent);
  background: linear-gradient(135deg, var(--accent), var(--accent3));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.photo-placeholder p { font-size: 0.7rem; color: var(--muted); text-align: center; padding: 0 1rem; }
.floating-badge {
  position: absolute; background: var(--card2); border: 1px solid var(--border);
  color: var(--text); padding: 0.5rem 1rem; border-radius: 50px;
  font-size: 0.78rem; font-weight: 600; white-space: nowrap;
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
  animation: float 3s ease-in-out infinite;
}
.floating-badge i { color: var(--accent); margin-right: 5px; }
.fb1 { top: 10px; right: -20px; animation-delay: 0s; }
.fb2 { bottom: 30px; right: -30px; animation-delay: 1s; }
.fb3 { bottom: 10px; left: -20px; animation-delay: 2s; }
@keyframes float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-8px)} }

.code-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; width: 100%; max-width: 420px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.5);
}
.code-header {
  display: flex; align-items: center; gap: 6px;
  padding: 0.8rem 1rem; background: var(--card2); border-bottom: 1px solid var(--border);
}
.code-header .dot { width: 12px; height: 12px; border-radius: 50%; }
.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }
.code-filename { margin-left: auto; font-size: 0.8rem; color: var(--muted); font-family: 'Fira Code', monospace; }
.code-body { padding: 1.5rem; font-family: 'Fira Code', monospace; font-size: 0.85rem; line-height: 1.8; }
.c-keyword { color: #c792ea; }
.c-var { color: #82aaff; }
.c-prop { color: #f07178; }
.c-str { color: #c3e88d; }
.c-num { color: #f78c6c; }
.c-bool { color: #ff5370; }

/* ===== SECTIONS COMMON ===== */
section { padding: 6rem 0; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 2rem; }
.section-label { font-family: 'Fira Code', monospace; font-size: 0.8rem; color: var(--accent); letter-spacing: 2px; text-transform: uppercase; margin-bottom: 0.5rem; }
.section-title { font-size: clamp(1.8rem, 3vw, 2.5rem); font-weight: 800; color: #fff; margin-bottom: 3rem; }
section:nth-child(even) { background: var(--bg2); }

/* ===== ABOUT ===== */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.about-text p { color: var(--muted); margin-bottom: 1rem; font-size: 1rem; text-align: justify; }
.about-links { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 1.5rem; }
.about-link {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--accent2); font-size: 0.9rem; font-weight: 500;
  border: 1px solid rgba(167,139,250,0.2); padding: 0.4rem 1rem; border-radius: 8px;
  transition: all 0.2s;
}
.about-link:hover { background: rgba(167,139,250,0.1); border-color: var(--accent2); }
.about-cards { display: flex; flex-direction: column; gap: 1.2rem; }
.info-cards-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.8rem; }
.info-card {
  display: flex; align-items: center; gap: 1rem;
  background: var(--card); border: 1px solid var(--border);
  padding: 1rem 1.2rem; border-radius: 14px;
  transition: all 0.3s; position: relative; overflow: hidden;
}
.info-card::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0;
  width: 3px; background: var(--accent); opacity: 0; transition: opacity 0.3s;
}
.info-card:hover { border-color: rgba(108,99,255,0.3); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.2); }
.info-card:hover::before { opacity: 1; }
.info-card.highlight { border-color: rgba(108,99,255,0.25); background: linear-gradient(135deg, rgba(108,99,255,0.08), var(--card)); }
.info-card.highlight::before { opacity: 1; background: linear-gradient(180deg, var(--accent), var(--accent3)); }
.info-card.available { border-color: rgba(74,222,128,0.2); }
.info-card.available::before { opacity: 1; background: var(--green); }
.info-card.available .info-card-icon { background: rgba(74,222,128,0.1); border-color: rgba(74,222,128,0.2); color: var(--green); }
.info-card.available .info-card-icon i { animation: pulse 2s infinite; }
.info-card-icon {
  width: 40px; height: 40px; min-width: 40px;
  background: rgba(108,99,255,0.1); border: 1px solid rgba(108,99,255,0.2);
  border-radius: 10px; display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-size: 0.95rem;
}
.info-card.highlight .info-card-icon { background: rgba(108,99,255,0.15); color: var(--accent2); }
.info-card-body { display: flex; flex-direction: column; gap: 2px; }
.info-label { font-size: 0.7rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }
.info-card-body strong { font-size: 0.88rem; color: #fff; font-weight: 600; }

.soft-skills {
  background: var(--card); border: 1px solid var(--border);
  padding: 1.4rem; border-radius: 14px;
  transition: border-color 0.3s;
}
.soft-skills:hover { border-color: rgba(108,99,255,0.3); }
.soft-skills-header { display: flex; align-items: center; gap: 8px; margin-bottom: 1rem; }
.soft-skills-header i { color: var(--accent); font-size: 0.9rem; }
.soft-skills h4 { font-size: 0.75rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1.5px; font-weight: 600; }
.tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tags span {
  display: inline-flex; align-items: center; gap: 5px;
  background: rgba(108,99,255,0.08); border: 1px solid rgba(108,99,255,0.18);
  color: var(--accent2); padding: 0.35rem 0.85rem; border-radius: 50px;
  font-size: 0.78rem; font-weight: 500; transition: all 0.2s;
}
.tags span i { font-size: 0.7rem; opacity: 0.8; }
.tags span:hover { background: rgba(108,99,255,0.18); border-color: var(--accent); color: #fff; transform: translateY(-1px); }

/* ===== TIMELINE ===== */
.timeline { position: relative; padding-left: 2rem; }
.timeline::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--border); }
.timeline-item { position: relative; margin-bottom: 2.5rem; }
.timeline-dot {
  position: absolute; left: -2.45rem; top: 1.5rem;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--border);
  transition: all 0.3s;
}
.timeline-item.active .timeline-dot { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 12px rgba(108,99,255,0.5); }
.timeline-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.5rem 2rem;
  transition: all 0.3s;
}
.timeline-card:hover { border-color: rgba(108,99,255,0.3); transform: translateX(4px); }
.timeline-item.active .timeline-card { border-color: rgba(108,99,255,0.3); }
.tl-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 1rem; flex-wrap: wrap; gap: 0.5rem; }
.tl-header h3 { font-size: 1.1rem; color: #fff; font-weight: 700; }
.company { display: block; color: var(--accent2); font-size: 0.9rem; margin-top: 2px; }
.badge { background: rgba(74,222,128,0.1); color: var(--green); padding: 0.1rem 0.5rem; border-radius: 4px; font-size: 0.75rem; margin-left: 6px; }
.tl-date { font-size: 0.8rem; color: var(--muted); font-family: 'Fira Code', monospace; white-space: nowrap; }
.timeline-card ul { padding-left: 1.2rem; list-style: disc; }
.timeline-card ul li { color: var(--muted); font-size: 0.9rem; margin-bottom: 0.4rem; }
.tl-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1rem; }
.tl-tags span { background: rgba(56,189,248,0.08); border: 1px solid rgba(56,189,248,0.2); color: var(--accent3); padding: 0.2rem 0.7rem; border-radius: 6px; font-size: 0.75rem; }

/* ===== PROJECTS ===== */
.projects-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem; margin-bottom: 1.5rem; }
.projects-header .section-title { margin-bottom: 0; }
.project-counter { background: rgba(108,99,255,0.1); border: 1px solid rgba(108,99,255,0.3); color: var(--accent2); padding: 0.4rem 1rem; border-radius: 50px; font-size: 0.85rem; font-weight: 600; }
.filter-tabs { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-bottom: 2.5rem; }
.filter-btn {
  background: var(--card); border: 1px solid var(--border);
  color: var(--muted); padding: 0.5rem 1.2rem; border-radius: 50px;
  font-size: 0.85rem; font-weight: 500; cursor: pointer;
  transition: all 0.2s; font-family: 'Inter', sans-serif;
}
.filter-btn:hover { border-color: var(--accent); color: var(--accent); }
.filter-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.projects-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.5rem; }
.project-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.8rem;
  transition: all 0.3s; position: relative; overflow: hidden;
}
.project-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent3));
  opacity: 0; transition: opacity 0.3s;
}
.project-card:hover { border-color: rgba(108,99,255,0.3); transform: translateY(-4px); box-shadow: 0 20px 50px rgba(0,0,0,0.3); }
.project-card:hover::before { opacity: 1; }
.project-card.hide { display: none; }
.project-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.project-icon { width: 44px; height: 44px; background: rgba(108,99,255,0.1); border: 1px solid rgba(108,99,255,0.2); border-radius: 10px; display: flex; align-items: center; justify-content: center; color: var(--accent); font-size: 1.1rem; }
.project-links a { color: var(--muted); font-size: 1.1rem; transition: color 0.2s; }
.project-links a:hover { color: var(--accent); }
.project-featured-badge { display: inline-flex; align-items: center; gap: 5px; background: linear-gradient(135deg, rgba(108,99,255,0.2), rgba(56,189,248,0.1)); border: 1px solid rgba(108,99,255,0.4); color: var(--accent2); padding: 0.25rem 0.8rem; border-radius: 6px; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.8rem; }
.project-featured-badge i { color: #f97316; }
.project-card h3 { font-size: 1.05rem; color: #fff; font-weight: 700; margin-bottom: 0.7rem; }
.project-card p { color: var(--muted); font-size: 0.88rem; line-height: 1.6; margin-bottom: 1.2rem; }
.project-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.project-tags span { background: rgba(56,189,248,0.08); border: 1px solid rgba(56,189,248,0.15); color: var(--accent3); padding: 0.2rem 0.6rem; border-radius: 6px; font-size: 0.72rem; }

/* ===== SKILLS ===== */
.skills-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.5rem; }
.skill-group { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; transition: border-color 0.3s; }
.skill-group:hover { border-color: rgba(108,99,255,0.3); }
.skill-group h4 { font-size: 0.85rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 1rem; display: flex; align-items: center; gap: 8px; }
.skill-group h4 i { color: var(--accent); }
.skill-pills { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.skill-pills span {
  background: rgba(108,99,255,0.08); border: 1px solid rgba(108,99,255,0.2);
  color: var(--text); padding: 0.35rem 0.9rem; border-radius: 8px;
  font-size: 0.82rem; font-weight: 500; transition: all 0.2s;
}
.skill-pills span:hover { background: rgba(108,99,255,0.2); border-color: var(--accent); color: #fff; }

/* ===== EDUCATION ===== */
.edu-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.5rem; }
.edu-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.8rem;
  display: flex; gap: 1.2rem; align-items: flex-start;
  transition: all 0.3s; position: relative; overflow: hidden;
}
.edu-card::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent3));
  opacity: 0; transition: opacity 0.3s;
}
.edu-card:hover { border-color: rgba(108,99,255,0.3); transform: translateY(-3px); box-shadow: 0 12px 40px rgba(0,0,0,0.25); }
.edu-card:hover::after { opacity: 1; }
.edu-card.primary {
  border-color: rgba(108,99,255,0.3);
  background: linear-gradient(135deg, rgba(108,99,255,0.07), var(--card));
  grid-column: span 2;
}
.edu-card.primary::after { opacity: 1; }
.edu-icon {
  width: 48px; height: 48px; min-width: 48px;
  background: rgba(108,99,255,0.1); border: 1px solid rgba(108,99,255,0.25);
  border-radius: 12px; display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-size: 1.2rem;
}
.edu-card.primary .edu-icon {
  background: linear-gradient(135deg, rgba(108,99,255,0.2), rgba(56,189,248,0.1));
  border-color: rgba(108,99,255,0.4); color: var(--accent2);
}
.edu-date {
  font-size: 0.72rem; color: var(--accent); font-family: 'Fira Code', monospace;
  display: inline-block; background: rgba(108,99,255,0.1);
  border: 1px solid rgba(108,99,255,0.2); padding: 0.15rem 0.6rem;
  border-radius: 4px; margin-bottom: 0.6rem; letter-spacing: 0.5px;
}
.edu-info h3 { font-size: 1rem; color: #fff; font-weight: 700; margin-bottom: 0.3rem; line-height: 1.4; }
.edu-spec { font-size: 0.82rem; color: var(--accent2); margin-bottom: 0.4rem; font-weight: 500; }
.edu-school { font-size: 0.8rem; color: var(--muted); display: flex; align-items: center; gap: 5px; }
.edu-school i { font-size: 0.7rem; color: var(--accent); opacity: 0.7; }
.gpa-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: linear-gradient(135deg, var(--accent), #8b5cf6);
  color: #fff; padding: 0.35rem 1rem; border-radius: 8px;
  font-size: 0.82rem; font-weight: 700; margin-top: 1rem;
  box-shadow: 0 4px 14px rgba(108,99,255,0.35);
}
.gpa-badge i { font-size: 0.75rem; color: #fbbf24; }
@media (max-width: 700px) { .edu-card.primary { grid-column: span 1; } }

/* ===== REFERENCES ===== */
.ref-intro { color: var(--muted); font-size: 0.9rem; margin-bottom: 2rem; margin-top: -1.5rem; }
.ref-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1.5rem; }
.ref-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 2rem;
  transition: all 0.3s; position: relative; overflow: hidden;
}
.ref-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent3));
  opacity: 0; transition: opacity 0.3s;
}
.ref-card:hover { border-color: rgba(108,99,255,0.3); transform: translateY(-3px); box-shadow: 0 16px 40px rgba(0,0,0,0.25); }
.ref-card:hover::before { opacity: 1; }
.ref-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.2rem; }
.ref-avatar {
  width: 56px; height: 56px;
  background: linear-gradient(135deg, rgba(108,99,255,0.15), rgba(56,189,248,0.1));
  border: 2px solid rgba(108,99,255,0.3); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-size: 1.3rem;
}
.ref-avatar.academic {
  background: linear-gradient(135deg, rgba(56,189,248,0.15), rgba(108,99,255,0.1));
  border-color: rgba(56,189,248,0.3); color: var(--accent3);
}
.ref-badge {
  font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px;
  background: rgba(108,99,255,0.1); border: 1px solid rgba(108,99,255,0.25);
  color: var(--accent2); padding: 0.25rem 0.7rem; border-radius: 50px;
}
.ref-badge.academic {
  background: rgba(56,189,248,0.08); border-color: rgba(56,189,248,0.25); color: var(--accent3);
}
.ref-card h3 { font-size: 1.05rem; color: #fff; font-weight: 700; margin-bottom: 0.25rem; }
.ref-role { color: var(--accent2); font-size: 0.85rem; font-weight: 500; margin-bottom: 0.3rem; }
.ref-company { color: var(--muted); font-size: 0.82rem; display: flex; align-items: center; gap: 6px; }
.ref-company i { color: var(--accent); font-size: 0.72rem; opacity: 0.7; }
.ref-divider { height: 1px; background: var(--border); margin: 1.2rem 0; }
.ref-contacts { display: flex; flex-direction: column; gap: 0.6rem; margin-bottom: 1rem; }
.ref-contacts.hidden { display: none; }
.ref-contacts a {
  display: flex; align-items: center; gap: 8px;
  color: var(--muted); font-size: 0.83rem; padding: 0.5rem 0.8rem;
  background: rgba(255,255,255,0.03); border: 1px solid var(--border);
  border-radius: 8px; transition: all 0.2s;
}
.ref-contacts a:hover { color: var(--accent2); border-color: rgba(108,99,255,0.3); background: rgba(108,99,255,0.05); }
.ref-contacts a i { color: var(--accent); font-size: 0.8rem; width: 14px; }
.ref-reveal-btn {
  width: 100%; padding: 0.6rem; border-radius: 8px; border: 1px dashed rgba(108,99,255,0.3);
  background: transparent; color: var(--accent2); font-size: 0.82rem; font-weight: 600;
  cursor: pointer; font-family: 'Inter', sans-serif; transition: all 0.2s;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}
.ref-reveal-btn:hover { background: rgba(108,99,255,0.08); border-color: var(--accent); color: #fff; }
.ref-reveal-btn.revealed { border-style: solid; background: rgba(108,99,255,0.05); color: var(--muted); }

/* ===== CONTACT ===== */
.contact-sub { color: var(--muted); max-width: 500px; margin-bottom: 3rem; }
.contact-grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: 3rem; align-items: start; }
.contact-info { display: flex; flex-direction: column; gap: 1rem; }
.contact-item {
  display: flex; align-items: center; gap: 1rem;
  background: var(--card); border: 1px solid var(--border);
  padding: 1rem 1.2rem; border-radius: 12px; transition: all 0.2s;
}
.contact-item:not(.no-link):hover { border-color: rgba(108,99,255,0.3); transform: translateX(4px); }
.contact-icon { width: 40px; height: 40px; min-width: 40px; background: rgba(108,99,255,0.1); border-radius: 10px; display: flex; align-items: center; justify-content: center; color: var(--accent); }
.contact-item div { display: flex; flex-direction: column; }
.contact-item strong { font-size: 0.82rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.5px; }
.contact-item span { font-size: 0.9rem; color: var(--text); }
.contact-form { display: flex; flex-direction: column; gap: 1rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.contact-form input, .contact-form textarea {
  background: var(--card); border: 1px solid var(--border);
  color: var(--text); padding: 0.9rem 1.2rem; border-radius: 10px;
  font-family: 'Inter', sans-serif; font-size: 0.9rem; outline: none;
  transition: border-color 0.2s; resize: vertical;
}
.contact-form input:focus, .contact-form textarea:focus { border-color: var(--accent); }
.contact-form input::placeholder, .contact-form textarea::placeholder { color: var(--muted); }
.contact-form .btn-primary { align-self: flex-start; }

/* ===== FOOTER ===== */
footer { background: var(--bg); border-top: 1px solid var(--border); padding: 2rem; }
.footer-inner { max-width: 1100px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem; }
.footer-logo { font-size: 1.3rem; font-weight: 800; color: #fff; }
footer p { color: var(--muted); font-size: 0.85rem; }
.footer-socials { display: flex; gap: 1rem; }
.footer-socials a { color: var(--muted); font-size: 1.1rem; transition: color 0.2s; }
.footer-socials a:hover { color: var(--accent); }

/* ===== ANIMATIONS ===== */
.fade-up { opacity: 0; transform: translateY(30px); transition: opacity 0.6s ease, transform 0.6s ease; }
.fade-up.visible { opacity: 1; transform: translateY(0); }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  #navbar { padding: 1rem 2rem; }
  #navbar.scrolled { padding: 0.7rem 2rem; }
  .nav-links, .btn-nav { display: none; }
  .hamburger { display: flex; }
  .nav-links.open { display: flex; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0; background: var(--bg2); padding: 1.5rem 2rem; border-bottom: 1px solid var(--border); gap: 1.2rem; }
  #hero { flex-direction: column; padding: 7rem 2rem 4rem; text-align: center; }
  .hero-actions { justify-content: center; }
  .hero-stats { justify-content: center; }
  .hero-visual { width: 100%; }
  .hero-photo-wrapper { width: 260px; height: 320px; }
  .profile-photo-container { width: 220px; height: 280px; }
  .fb1 { right: -10px; } .fb2 { right: -10px; } .fb3 { left: -10px; }
  .about-grid { grid-template-columns: 1fr; gap: 2rem; }
  .contact-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; text-align: center; }
}
@media (max-width: 600px) {
  section { padding: 4rem 0; }
  .projects-grid { grid-template-columns: 1fr; }
  .skills-grid { grid-template-columns: 1fr; }
  .edu-grid { grid-template-columns: 1fr; }
  .ref-grid { grid-template-columns: 1fr; }
  .hero-photo-wrapper { width: 220px; height: 270px; }
  .profile-photo-container { width: 180px; height: 230px; }
  .floating-badge { display: none; }
}

/* ===== SUCCESS OVERLAY ===== */
.overlay {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,0.7); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.3s;
}
.overlay.show { opacity: 1; pointer-events: all; }
.overlay-card {
  background: var(--card); border: 1px solid rgba(108,99,255,0.3);
  border-radius: 20px; padding: 3rem 2.5rem; text-align: center;
  max-width: 380px; width: 90%;
  transform: scale(0.9); transition: transform 0.3s;
  box-shadow: 0 30px 80px rgba(0,0,0,0.5);
}
.overlay.show .overlay-card { transform: scale(1); }
.overlay-icon {
  width: 72px; height: 72px; border-radius: 50%; margin: 0 auto 1.5rem;
  background: linear-gradient(135deg, rgba(74,222,128,0.2), rgba(34,197,94,0.1));
  border: 2px solid rgba(74,222,128,0.4);
  display: flex; align-items: center; justify-content: center;
  font-size: 2rem; color: var(--green);
  animation: popIn 0.4s ease;
}
@keyframes popIn { 0%{transform:scale(0)} 70%{transform:scale(1.1)} 100%{transform:scale(1)} }
.overlay-card h3 { font-size: 1.4rem; color: #fff; font-weight: 700; margin-bottom: 0.5rem; }
.overlay-card p { color: var(--muted); font-size: 0.9rem; margin-bottom: 1.5rem; }
