/* ===== CSS VARIABLES ===== */
:root {
  --font-sans: 'Inter', system-ui, sans-serif;
  --font-heading: 'Space Grotesk', 'Inter', sans-serif;

  /* Spacing 8px grid */
  --s1: 8px;
  --s2: 16px;
  --s3: 24px;
  --s4: 32px;
  --s5: 40px;
  --s6: 48px;
  --s8: 64px;
  --s10: 80px;
  --s12: 96px;

  /* Colors — shared */
  --accent: #0ea5e9;
  --accent-2: #38bdf8;
  --success: #22c55e;
  --warning: #f59e0b;
  --error: #ef4444;

  /* Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  /* Transitions */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --dur: 0.3s;
}

/* ===== DARK THEME (default) ===== */
[data-theme="dark"] {
  --bg: #080d14;
  --bg-2: #0d1420;
  --bg-3: #111827;
  --bg-card: rgba(255,255,255,0.04);
  --bg-card-hover: rgba(255,255,255,0.07);
  --border: rgba(255,255,255,0.08);
  --border-hover: rgba(14,165,233,0.4);
  --text-1: #f0f6ff;
  --text-2: #94a3b8;
  --text-3: #64748b;
  --glow: 0 0 60px rgba(14,165,233,0.15);
  --shadow-card: 0 4px 24px rgba(0,0,0,0.4);
  --nav-bg: rgba(8,13,20,0.85);
  --skill-track: rgba(255,255,255,0.06);
}

/* ===== LIGHT THEME ===== */
[data-theme="light"] {
  --bg: #f0f6ff;
  --bg-2: #e8f0fe;
  --bg-3: #ffffff;
  --bg-card: rgba(255,255,255,0.7);
  --bg-card-hover: rgba(255,255,255,0.95);
  --border: rgba(0,0,0,0.08);
  --border-hover: rgba(14,165,233,0.5);
  --text-1: #0f172a;
  --text-2: #475569;
  --text-3: #94a3b8;
  --glow: 0 0 60px rgba(14,165,233,0.1);
  --shadow-card: 0 4px 24px rgba(0,0,0,0.08);
  --nav-bg: rgba(240,246,255,0.88);
  --skill-track: rgba(0,0,0,0.08);
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text-1);
  line-height: 1.6;
  font-size: 16px;
  overflow-x: hidden;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease);
}

img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { cursor: pointer; font-family: var(--font-sans); }

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

/* ===== CANVAS PARTICLES ===== */
#particles {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
}

/* ===== CONTAINER ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--s3);
  position: relative;
  z-index: 1;
}

/* ===== NAVBAR ===== */
#navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}
#navbar.scrolled { border-bottom-color: var(--border); }

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--s3);
  height: 68px;
  display: flex;
  align-items: center;
  gap: var(--s3);
}

.nav-logo {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-1);
  margin-right: auto;
  transition: color var(--dur) var(--ease);
}
.nav-logo:hover { color: var(--accent); }

.nav-links {
  display: flex;
  gap: var(--s1);
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-2);
  padding: var(--s1) 14px;
  border-radius: var(--radius-full);
  transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
  white-space: nowrap;
}
.nav-link:hover,
.nav-link.active {
  color: var(--accent);
  background: rgba(14,165,233,0.1);
}

.nav-actions { display: flex; align-items: center; gap: var(--s2); }

.theme-toggle {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--border);
  background: var(--bg-3);
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--dur) var(--ease);
  flex-shrink: 0;
  color: var(--text-1);
}
.theme-toggle:hover { border-color: var(--accent); background: rgba(14,165,233,0.1); color: var(--accent); }

[data-theme="dark"] .sun-icon { display: inline; }
[data-theme="dark"] .moon-icon { display: none; }
[data-theme="light"] .sun-icon { display: none; }
[data-theme="light"] .moon-icon { display: inline; }

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  padding: 6px;
}
.hamburger span {
  display: block;
  height: 2px;
  background: var(--text-2);
  border-radius: 2px;
  transition: all var(--dur) var(--ease);
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  display: none;
  flex-direction: column;
  padding: var(--s2) var(--s3) var(--s3);
  border-top: 1px solid var(--border);
  gap: var(--s1);
}
.mobile-menu.open { display: flex; }
.mobile-menu .nav-link { font-size: 1rem; padding: 10px 14px; }

/* ===== SECTION BASE ===== */
.section {
  position: relative;
  z-index: 1;
  padding: var(--s12) 0;
}

.section-header {
  text-align: center;
  margin-bottom: var(--s8);
}
.section-tag {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--s2);
}
.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  color: var(--text-1);
  line-height: 1.2;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--s1);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 13px 28px;
  border-radius: var(--radius-full);
  border: none;
  transition: all var(--dur) var(--ease);
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 4px 20px rgba(14,165,233,0.35);
}
.btn-primary:hover {
  background: var(--accent-2);
  box-shadow: 0 6px 28px rgba(14,165,233,0.5);
  transform: translateY(-2px);
}
.btn-outline {
  background: transparent;
  color: var(--text-1);
  border: 1.5px solid var(--border);
}
.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(14,165,233,0.07);
  transform: translateY(-2px);
}
.btn-full { width: 100%; justify-content: center; }

/* ===== HERO ===== */
.hero-section {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: var(--s6);
  padding: 100px var(--s3) var(--s8);
  max-width: 1200px;
  margin: 0 auto;
}

.hero-greeting {
  font-size: 1rem;
  color: var(--text-2);
  margin-bottom: var(--s2);
  font-weight: 500;
}
.hero-name {
  font-family: var(--font-heading);
  font-size: clamp(2.8rem, 6vw, 4.5rem);
  font-weight: 700;
  line-height: 1.1;
  color: var(--text-1);
  margin-bottom: var(--s2);
  background: linear-gradient(135deg, var(--text-1) 30%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-role {
  font-size: 1.3rem;
  color: var(--text-2);
  margin-bottom: var(--s3);
  min-height: 2rem;
  display: flex;
  align-items: center;
  gap: 6px;
}
.typed-text { color: var(--accent); font-weight: 600; }
.cursor {
  color: var(--accent);
  animation: blink 1s infinite;
  font-weight: 300;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

.hero-desc {
  font-size: 1rem;
  color: var(--text-2);
  line-height: 1.7;
  max-width: 500px;
  margin-bottom: var(--s5);
}
.hero-cta {
  display: flex;
  gap: var(--s2);
  flex-wrap: wrap;
  margin-bottom: var(--s5);
}
.hero-social { display: flex; gap: var(--s2); }
.social-icon-link {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-2);
  transition: all var(--dur) var(--ease);
}
.social-icon-link:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: rgba(14,165,233,0.1);
  transform: translateY(-3px);
}

.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.avatar-wrapper {
  position: relative;
  width: 340px;
  height: 340px;
}
.avatar-img {
  width: 300px;
  height: 300px;
  border-radius: 40% 60% 60% 40% / 40% 40% 60% 60%;
  object-fit: cover;
  position: relative;
  z-index: 2;
  margin: 20px;
  animation: morphing 8s ease-in-out infinite;
}
@keyframes morphing {
  0%,100% { border-radius: 40% 60% 60% 40% / 40% 40% 60% 60%; }
  25% { border-radius: 60% 40% 40% 60% / 60% 60% 40% 40%; }
  50% { border-radius: 50% 50% 60% 40% / 50% 50% 40% 60%; }
  75% { border-radius: 40% 60% 50% 50% / 40% 60% 50% 50%; }
}

.avatar-glow {
  position: absolute;
  inset: -20px;
  background: radial-gradient(circle, rgba(14,165,233,0.25) 0%, transparent 70%);
  border-radius: 50%;
  animation: pulseGlow 3s ease-in-out infinite alternate;
  z-index: 1;
}
@keyframes pulseGlow {
  from { opacity: 0.5; transform: scale(0.95); }
  to   { opacity: 1;   transform: scale(1.05); }
}

.avatar-ring {
  position: absolute;
  inset: 0;
  border: 2px dashed rgba(14,165,233,0.3);
  border-radius: 50%;
  animation: spin 20s linear infinite;
  z-index: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

.floating-badge {
  position: absolute;
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-1);
  animation: float 3s ease-in-out infinite;
  z-index: 5;
  white-space: nowrap;
}
.badge-1 { top: 10%;  left: -10%; animation-delay: 0s; }
.badge-2 { bottom: 20%; right: -8%; animation-delay: 1s; }
.badge-3 { bottom: 5%; left: 5%; animation-delay: 2s; }
@keyframes float {
  0%,100% { transform: translateY(0); }
  50%       { transform: translateY(-10px); }
}

.scroll-indicator {
  position: absolute;
  bottom: var(--s5);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s1);
  color: var(--text-3);
  font-size: 0.75rem;
  animation: fadeInUp 1s 2s both;
}
.scroll-mouse {
  width: 24px;
  height: 38px;
  border: 2px solid var(--text-3);
  border-radius: var(--radius-full);
  display: flex;
  justify-content: center;
  padding-top: 6px;
}
.scroll-dot {
  width: 4px;
  height: 8px;
  background: var(--accent);
  border-radius: var(--radius-full);
  animation: scrollBounce 1.5s ease-in-out infinite;
}
@keyframes scrollBounce {
  0%,100% { transform: translateY(0); opacity: 1; }
  50%      { transform: translateY(8px); opacity: 0.3; }
}

/* ===== ABOUT ===== */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s8);
  align-items: center;
}
.about-img-wrapper {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.about-img-wrapper img {
  width: 100%;
  height: 480px;
  object-fit: cover;
  border-radius: var(--radius-lg);
  transition: transform 0.5s var(--ease);
}
.about-img-wrapper:hover img { transform: scale(1.04); }

.about-img-tag {
  position: absolute;
  bottom: var(--s3);
  right: var(--s3);
  background: var(--accent);
  color: #fff;
  padding: var(--s2) var(--s3);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: var(--s1);
  font-size: 0.9rem;
}
.about-img-tag strong { font-size: 1.8rem; font-family: var(--font-heading); line-height: 1; }

.about-text h3 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: var(--s3);
  line-height: 1.3;
}
.about-text p {
  color: var(--text-2);
  margin-bottom: var(--s3);
  line-height: 1.75;
}

.about-facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s3);
  margin: var(--s5) 0;
  padding: var(--s4) 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.fact-item { text-align: center; }
.fact-number-wrap {
  display: flex;
  justify-content: center;
  align-items: baseline;
  gap: 2px;
}
.fact-number {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--accent);
}
.fact-plus {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent);
}
.fact-item p { font-size: 0.85rem; color: var(--text-2); margin-top: 4px; }

/* ===== SKILLS ===== */
.skills-section { background: var(--bg-2); }
.skills__container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--s6);
}
.skills__card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--s6);
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.skills__card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-card);
}
.skills__card h3 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: var(--s4);
  text-align: center;
}
.skills__tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
  justify-content: center;
}
.skills__tags span {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  padding: 6px 14px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-2);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all var(--dur) var(--ease);
}
.skills__tags span:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(14,165,233,0.08);
}

/* ===== PROJECTS ===== */
.projects-filter {
  display: flex;
  gap: var(--s2);
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: var(--s6);
}
.filter-btn {
  font-size: 0.875rem;
  font-weight: 600;
  padding: 8px 22px;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--border);
  background: var(--bg-card);
  color: var(--text-2);
  transition: all var(--dur) var(--ease);
}
.filter-btn:hover,
.filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 4px 14px rgba(14,165,233,0.3);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s4);
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--dur) var(--ease);
}
.project-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-6px);
  box-shadow: var(--shadow-card), var(--glow);
}
.project-card.hidden {
  display: none;
}
.project-img {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/10;
}
.project-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease);
}
.project-card:hover .project-img img { transform: scale(1.08); }

.project-overlay {
  position: absolute;
  inset: 0;
  background: rgba(8,13,20,0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--s2);
  opacity: 0;
  transition: opacity var(--dur) var(--ease);
}
.project-card:hover .project-overlay { opacity: 1; }
.project-link {
  background: var(--accent);
  color: #fff;
  padding: 9px 18px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  transition: all var(--dur) var(--ease);
}
.project-link:hover { background: var(--accent-2); transform: scale(1.05); }

.project-info { padding: var(--s3); }
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: var(--s2);
}
.project-tags span {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--accent);
  background: rgba(14,165,233,0.1);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(14,165,233,0.2);
}
.project-info h3 {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: var(--s1);
  line-height: 1.3;
}
.project-info p {
  font-size: 0.85rem;
  color: var(--text-2);
  line-height: 1.6;
}

/* ===== ACHIEVEMENTS ===== */
.achievements-section { background: var(--bg-2); }

.achievements-section .section-header {
  margin-bottom: var(--s6);
}
.achievements-section .section-title {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.achievements-section .section-title::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -10px;
  width: 72px;
  height: 3px;
  border-radius: var(--radius-full);
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform: translateX(-50%);
}
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s4);
  max-width: 940px;
  margin: 0 auto;
}
.achievement-card {
  overflow: hidden;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-card);
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.achievement-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-6px);
  box-shadow: 0 16px 38px rgba(0,0,0,0.18);
}
.certificate-img {
  width: 100%;
  height: 210px;
  padding: 10px;
  object-fit: contain;
  background: #fff;
  border-bottom: 1px solid #e5e7eb;
}
.certificate-info {
  min-height: 86px;
  display: flex;
  align-items: flex-start;
  padding: var(--s3);
}
.certificate-title {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-1);
  line-height: 1.45;
}

/* Timeline */
.timeline {
  position: relative;
  max-width: 720px;
  margin: 0 auto;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 20px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), transparent);
}

.timeline-item {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: var(--s3);
  margin-bottom: var(--s4);
  align-items: start;
}
.timeline-dot {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-3);
  border: 2px solid var(--accent);
  box-shadow: 0 0 12px rgba(14,165,233,0.3);
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}
.timeline-dot::after {
  content: '';
  position: absolute;
  inset: 8px;
  background: var(--accent);
  border-radius: 50%;
}

.timeline-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--s3) var(--s4);
  transition: all var(--dur) var(--ease);
}
.timeline-card:hover { border-color: var(--border-hover); transform: translateX(4px); }

.timeline-year {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
  background: rgba(14,165,233,0.1);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  margin-bottom: var(--s1);
  border: 1px solid rgba(14,165,233,0.2);
}
.timeline-card h4 {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: 2px;
}
.timeline-card p {
  font-size: 0.875rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: var(--s1);
}
.timeline-card small {
  font-size: 0.82rem;
  color: var(--text-2);
  line-height: 1.5;
}

/* ===== CONTACT ===== */
.contact {
  padding-bottom: var(--s10);
}
.contact .section-header {
  margin-bottom: var(--s6);
}
.contact .section-title {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.contact .section-title::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -10px;
  width: 72px;
  height: 3px;
  border-radius: var(--radius-full);
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform: translateX(-50%);
}
.contact__intro {
  max-width: 560px;
  margin: var(--s4) auto 0;
  color: var(--text-2);
  font-size: 1rem;
  line-height: 1.7;
}
.contact__container {
  display: flex;
  justify-content: center;
}
.contact__form {
  width: min(100%, 460px);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: var(--s3);
}
.contact__input {
  width: 100%;
  min-height: 54px;
  padding: 15px 18px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text-1);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 500;
  outline: none;
  resize: vertical;
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease), background var(--dur) var(--ease);
}
.contact__input::placeholder {
  color: var(--text-3);
  opacity: 1;
}
.contact__input:focus {
  border-color: var(--accent);
  background: var(--bg-3);
  box-shadow: 0 0 0 4px rgba(14,165,233,0.12);
}
textarea.contact__input {
  min-height: 210px;
  line-height: 1.6;
}
.contact__button {
  align-self: flex-end;
  min-width: 136px;
  justify-content: center;
  border-radius: var(--radius-sm);
}
.contact__button:disabled {
  cursor: not-allowed;
  opacity: 0.7;
  transform: none;
}
.form-success {
  display: none;
  background: rgba(34,197,94,0.1);
  border: 1px solid rgba(34,197,94,0.3);
  color: var(--success);
  padding: var(--s2) var(--s3);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  text-align: center;
}
.form-success.visible { display: block; }

/* ===== FOOTER ===== */
.footer {
  padding: var(--s6) 0 var(--s4);
  background: var(--bg-2);
  border-top: 1px solid rgba(14,165,233,0.16);
  position: relative;
  z-index: 1;
  overflow: hidden;
}
.footer::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 0%, rgba(14,165,233,0.14), transparent 42%);
  pointer-events: none;
}
.footer__inner {
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  gap: var(--s4);
  text-align: center;
}
.footer__title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 3vw, 2.35rem);
  line-height: 1;
  font-weight: 700;
  color: var(--text-1);
}
.footer__nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: var(--s2) var(--s3);
}
.footer__nav a {
  color: var(--text-2);
  font-size: 0.9rem;
  font-weight: 700;
  transition: color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.footer__nav a:hover {
  color: var(--accent-2);
  transform: translateY(-2px);
}
.footer__social {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--s2);
}
.footer__social a {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(14,165,233,0.18);
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-1);
  background: var(--bg-card);
  transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease), background var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.footer__social a:hover {
  color: #fff;
  border-color: var(--accent);
  background: var(--accent);
  transform: translateY(-3px);
}
.footer__copy {
  color: var(--text-2);
  font-size: 0.85rem;
  font-weight: 600;
}
.back-to-top {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  font-weight: 700;
  transition: all var(--dur) var(--ease);
  box-shadow: 0 4px 14px rgba(14,165,233,0.3);
}
.back-to-top:hover { transform: translateY(-3px); box-shadow: 0 6px 20px rgba(14,165,233,0.45); }

/* ===== REVEAL ANIMATIONS ===== */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.reveal-right {
  transform: translateX(40px);
}
.reveal.visible {
  opacity: 1;
  transform: translate(0, 0);
}

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

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .projects-grid { grid-template-columns: repeat(2, 1fr); }
  .achievements-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }

  .hero-section {
    grid-template-columns: 1fr;
    text-align: center;
    padding-top: 90px;
    min-height: auto;
    padding-bottom: var(--s10);
  }
  .hero-visual { order: -1; }
  .avatar-wrapper { width: 240px; height: 240px; }
  .avatar-img { width: 210px; height: 210px; }
  .hero-cta { justify-content: center; }
  .hero-social { justify-content: center; }
  .hero-desc { margin: 0 auto var(--s5); }
  .floating-badge { display: none; }
  .scroll-indicator { display: none; }

  .about-grid { grid-template-columns: 1fr; }
  .about-img-wrapper img { height: 300px; }

  .skills__container { grid-template-columns: 1fr; }
  .tech-grid { grid-template-columns: repeat(3, 1fr); }

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

  .contact__form { width: min(100%, 420px); }
  .contact__button { align-self: stretch; }
  .footer__nav { gap: var(--s2); }

  .section { padding: var(--s8) 0; }
}

@media (max-width: 480px) {
  .achievements-grid { grid-template-columns: 1fr; }
  .about-facts { grid-template-columns: 1fr 1fr 1fr; }
  .hero-name { font-size: 2.5rem; }
  .tech-grid { grid-template-columns: repeat(2, 1fr); }
  .certificate-img { height: 190px; }
  .contact__form { gap: var(--s2); }
  .footer__inner { gap: var(--s3); }
  .footer__nav { flex-direction: column; }
}


.skills__container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.8rem;
  margin-top: 3rem;
}

.skills__card {
  position: relative;
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(10px);
  border-radius: 24px;
  padding: 1.8rem;
  overflow: hidden;
  transition: all .4s ease;
  border: 1px solid rgba(255,255,255,0.08);
}

/* Animated Gradient Border */
.skills__card::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 24px;
  padding: 2px;
  background: linear-gradient(
    135deg,
    #6d28d9,
    #8b5cf6,
    #3b82f6,
    #6d28d9
  );
  background-size: 300% 300%;
  animation: borderMove 6s linear infinite;

  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
}

@keyframes borderMove {
  0% { background-position: 0% 50%; }
  100% { background-position: 300% 50%; }
}

.skills__card:hover {
  transform: translateY(-10px);
  box-shadow:
    0 20px 40px rgba(109,40,217,.2),
    0 0 40px rgba(99,102,241,.15);
}

.skills__card h3 {
  margin-bottom: 1.25rem;
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
  position: relative;
}

.skills__card h3::after {
  content: "";
  display: block;
  width: 45px;
  height: 3px;
  border-radius: 999px;
  margin-top: .6rem;
  background: linear-gradient(90deg,#6d28d9,#3b82f6);
}

.skills__tags {
  display: flex;
  flex-wrap: wrap;
  gap: .8rem;
}

.skills__tags span {
  display: flex;
  align-items: center;
  gap: .45rem;

  padding: .7rem 1rem;
  border-radius: 999px;

  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);

  transition: all .3s ease;
  cursor: default;
}

.skills__tags span i {
  font-size: 1.1rem;
}

.skills__tags span:hover {
  transform: translateY(-4px) scale(1.05);
  background: linear-gradient(
    135deg,
    #6d28d9,
    #4f46e5
  );
  color: white;
  box-shadow: 0 10px 20px rgba(109,40,217,.3);
}


.project-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: rgba(255,255,255,.05);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,.08);
  transition: all .4s ease;
}

.project-card::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 24px;
  padding: 2px;
  background: linear-gradient(
    135deg,
    #6d28d9,
    #8b5cf6,
    #3b82f6,
    #6d28d9
  );
  background-size: 300% 300%;
  animation: borderMove 6s linear infinite;

  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);

  -webkit-mask-composite: xor;
          mask-composite: exclude;
}

.project-card:hover {
  transform: translateY(-12px);
  box-shadow:
    0 20px 40px rgba(109,40,217,.2),
    0 0 40px rgba(99,102,241,.15);
}

.project-glow {
  position: absolute;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: rgba(109,40,217,.15);
  filter: blur(60px);
  top: -100px;
  right: -100px;
  pointer-events: none;
}

.project-img {
  overflow: hidden;
}

.project-img img {
  width: 100%;
  transition: transform .6s ease;
}

.project-card:hover .project-img img {
  transform: scale(1.08);
}

.project-info {
  padding: 1.4rem;
}

.project-info h3 {
  margin: 1rem 0 .8rem;
  font-size: 1.3rem;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}

.project-tags span {
  padding: .45rem .9rem;
  border-radius: 999px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  transition: .3s;
}

.project-tags span:hover {
  background: linear-gradient(
    135deg,
    #6d28d9,
    #4f46e5
  );
  color: #fff;
  transform: translateY(-2px);
}

.project-overlay {
  backdrop-filter: blur(8px);
}

.project-link {
  transition: .3s;
}

.project-link:hover {
  transform: translateY(-2px);
}


.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 2rem;
}

.certificate-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: rgba(255,255,255,.04);
  backdrop-filter: blur(12px);
  transition: .4s ease;
}

/* Animated Border */
.certificate-card::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 24px;
  padding: 2px;
  background: linear-gradient(
    135deg,
    #6d28d9,
    #8b5cf6,
    #3b82f6,
    #6d28d9
  );
  background-size: 300% 300%;
  animation: borderMove 6s linear infinite;

  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);

  -webkit-mask-composite: xor;
          mask-composite: exclude;
}

.certificate-card:hover {
  transform: translateY(-10px);
  box-shadow:
    0 20px 40px rgba(109,40,217,.18),
    0 0 40px rgba(59,130,246,.12);
}

.certificate-image-wrapper {
  width: 100%;
  height: 260px;
  overflow: hidden;
}

.certificate-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .6s ease;
}

.certificate-card:hover .certificate-img {
  transform: scale(1.08);
}

.certificate-info {
  padding: 1.25rem;
}

.certificate-title {
  font-size: 1.1rem;
  margin-bottom: .6rem;
  font-weight: 700;
}

.certificate-desc {
  font-size: .92rem;
  opacity: .8;
  line-height: 1.6;
}


/* =========================
   MOBILE CONTACT SECTION
========================= */

@media screen and (max-width: 768px) {

  .contact {
    padding: 4rem 0 2rem;
  }

  .contact .container {
    padding-inline: 1rem;
  }

  .contact__intro {
    text-align: center;
    max-width: 300px;
    margin: 0 auto 2rem;
    font-size: 0.95rem;
    line-height: 1.6;
  }

  .contact__container {
    display: block;
  }

  .contact__form {
    width: 100%;
    padding: 1.25rem;
    border-radius: 20px;
    background: rgba(255,255,255,0.04);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow:
      0 10px 30px rgba(0,0,0,.25),
      0 0 30px rgba(123,44,191,.12);
  }

  .contact__input {
    width: 100%;
    padding: 14px 16px;
    margin-bottom: 1rem;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,.15);
    background: rgba(255,255,255,.03);
    color: #fff;
    font-size: 0.95rem;
    transition: .3s;
  }

  .contact__input:focus {
    outline: none;
    border-color: #a855f7;
    box-shadow: 0 0 15px rgba(168,85,247,.25);
  }

  textarea.contact__input {
    min-height: 120px;
    resize: none;
  }

  .contact__button {
    width: 100%;
    height: 52px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    margin-top: .5rem;
  }

  .form-success {
    text-align: center;
    margin-bottom: 1rem;
    font-size: .9rem;
  }

  /* Footer */

  .footer {
    margin-top: 0;
    padding: 2.5rem 0;
  }

  .footer__title {
    font-size: 1.4rem;
    margin-bottom: 1rem;
  }

  .footer__nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .8rem;
    margin: 1rem 0;
  }

  .footer__nav a {
    font-size: .85rem;
  }

  .footer__social {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 1.25rem 0;
  }

  .footer__social a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255,255,255,.06);
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .footer__copy {
    font-size: .8rem;
    line-height: 1.6;
  }
}



