/* ===== DESIGN TOKENS ===== */
:root {
  /* Colors */
  --bg-primary: #0a0a0f;
  --bg-secondary: #12121a;
  --bg-tertiary: #1a1a2e;
  --bg-card: rgba(255, 255, 255, 0.03);
  --bg-card-hover: rgba(255, 255, 255, 0.06);
  --bg-glass: rgba(255, 255, 255, 0.05);
  --border-glass: rgba(255, 255, 255, 0.08);
  --border-glass-hover: rgba(255, 255, 255, 0.15);

  --accent-blue: #3b82f6;
  --accent-purple: #8b5cf6;
  --accent-cyan: #06b6d4;
  --accent-pink: #ec4899;
  --accent-green: #10b981;
  --accent-orange: #f97316;

  --gradient-primary: linear-gradient(135deg, #3b82f6, #8b5cf6);
  --gradient-secondary: linear-gradient(135deg, #06b6d4, #3b82f6);
  --gradient-accent: linear-gradient(135deg, #8b5cf6, #ec4899);
  --gradient-warm: linear-gradient(135deg, #f97316, #ec4899);

  --text-primary: #ffffff;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-accent: #3b82f6;

  /* Typography */
  --font-heading: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Spacing */
  --section-padding: 120px;
  --container-max: 1200px;
  --card-radius: 20px;
  --border-radius-sm: 10px;
  --border-radius-lg: 24px;

  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Shadows */
  --shadow-glow-blue: 0 0 30px rgba(59, 130, 246, 0.15);
  --shadow-glow-purple: 0 0 30px rgba(139, 92, 246, 0.15);
  --shadow-card: 0 4px 30px rgba(0, 0, 0, 0.3);
  --shadow-elevated: 0 20px 60px rgba(0, 0, 0, 0.5);
}

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

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

body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition-fast);
}

ul,
ol {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  line-height: 1.2;
  font-weight: 700;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--bg-tertiary);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-blue);
}

/* ===== UTILITIES ===== */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

.section-header {
  text-align: center;
  margin-bottom: 72px;
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--accent-blue);
  margin-bottom: 16px;
  font-family: var(--font-mono);
}

.section-label::before {
  content: '';
  width: 24px;
  height: 2px;
  background: var(--gradient-primary);
  border-radius: 1px;
}

.section-title {
  font-size: clamp(2rem, 5vw, 3rem);
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-glass);
  border-radius: var(--card-radius);
  transition: all var(--transition-base);
}

.glass-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-glass-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-card);
}

.gradient-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ===== BACKGROUND EFFECTS ===== */
.bg-grid {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 60px 60px;
  z-index: 0;
  pointer-events: none;
}

.bg-orbs {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.4;
  animation: orbFloat 20s ease-in-out infinite;
}

.orb-1 {
  width: 400px;
  height: 400px;
  background: var(--accent-blue);
  top: -100px;
  right: -100px;
  opacity: 0.12;
  animation-delay: 0s;
}

.orb-2 {
  width: 350px;
  height: 350px;
  background: var(--accent-purple);
  bottom: 20%;
  left: -100px;
  opacity: 0.1;
  animation-delay: -7s;
}

.orb-3 {
  width: 300px;
  height: 300px;
  background: var(--accent-cyan);
  top: 50%;
  right: 20%;
  opacity: 0.08;
  animation-delay: -14s;
}

@keyframes orbFloat {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }

  25% {
    transform: translate(30px, -40px) scale(1.05);
  }

  50% {
    transform: translate(-20px, 20px) scale(0.95);
  }

  75% {
    transform: translate(40px, 30px) scale(1.02);
  }
}

/* ===== NAVIGATION ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 16px 0;
  transition: all var(--transition-base);
}

.navbar.scrolled {
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-glass);
  padding: 10px 0;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}

.nav-logo span {
  -webkit-text-fill-color: var(--text-primary);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  position: relative;
  padding: 8px 16px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--border-radius-sm);
  transition: all var(--transition-fast);
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  border-radius: 1px;
  transition: width var(--transition-base);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 24px;
}

.nav-cta {
  margin-left: 8px;
  padding: 10px 24px;
  background: var(--gradient-primary);
  color: var(--text-primary) !important;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  transition: all var(--transition-base);
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
}

.nav-cta::after {
  display: none;
}

/* Mobile menu toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  z-index: 1001;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all var(--transition-base);
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== HERO SECTION ===== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 1;
  padding-top: 80px;
  overflow: hidden;
}

.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--bg-glass);
  border: 1px solid var(--border-glass);
  border-radius: 50px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
  backdrop-filter: blur(10px);
}

.hero-badge .dot {
  width: 8px;
  height: 8px;
  background: var(--accent-green);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
  }

  50% {
    opacity: 0.8;
    box-shadow: 0 0 0 8px rgba(16, 185, 129, 0);
  }
}

.hero-greeting {
  font-size: 1.1rem;
  color: var(--text-secondary);
  font-weight: 500;
  margin-bottom: 8px;
}

.hero-name {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 8px;
  letter-spacing: -1.5px;
}

.hero-title {
  font-size: clamp(1.2rem, 3vw, 1.6rem);
  margin-bottom: 24px;
  color: var(--text-secondary);
  font-weight: 400;
}

.hero-title .typed-text {
  color: var(--accent-blue);
  font-weight: 600;
}

.hero-title .cursor {
  display: inline-block;
  width: 3px;
  height: 1.2em;
  background: var(--accent-blue);
  margin-left: 2px;
  vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}

@keyframes blink {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }
}

.hero-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 520px;
  margin-bottom: 36px;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  transition: all var(--transition-base);
  border: none;
  font-family: var(--font-body);
}

.btn-primary {
  background: var(--gradient-primary);
  color: var(--text-primary);
  box-shadow: 0 4px 20px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(59, 130, 246, 0.4);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-glass-hover);
}

.btn-outline:hover {
  background: var(--bg-glass);
  border-color: var(--accent-blue);
  transform: translateY(-3px);
}

.hero-social {
  display: flex;
  align-items: center;
  gap: 16px;
}

.hero-social-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

.hero-social-links {
  display: flex;
  gap: 12px;
}

.social-link {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-glass);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
  color: var(--text-secondary);
  font-size: 1.2rem;
  transition: all var(--transition-base);
}

.social-link:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-blue);
  color: var(--accent-blue);
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow-blue);
}

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

.hero-image-wrapper {
  position: relative;
  width: 380px;
  height: 380px;
}

.hero-image-border {
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  background: var(--gradient-primary);
  animation: rotateBorder 8s linear infinite;
  opacity: 0.6;
}

@keyframes rotateBorder {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.hero-image {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-secondary);
  border: 4px solid var(--bg-primary);
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-image .placeholder-avatar {
  font-size: 8rem;
  color: var(--accent-blue);
  opacity: 0.3;
}

/* Floating tech badges */
.floating-badge {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: rgba(10, 10, 15, 0.9);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-glass);
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  z-index: 5;
  animation: float 6s ease-in-out infinite;
  white-space: nowrap;
}

.floating-badge .badge-icon {
  font-size: 1.2rem;
}

.badge-1 {
  top: 10%;
  right: -10%;
  animation-delay: 0s;
}

.badge-2 {
  bottom: 15%;
  left: -15%;
  animation-delay: -2s;
}

.badge-3 {
  top: 55%;
  right: -20%;
  animation-delay: -4s;
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-12px);
  }
}

/* Section components CSS have been moved to css/ directory */

/* ===== FOOTER ===== */
.footer {
  padding: 32px 0;
  border-top: 1px solid var(--border-glass);
  position: relative;
  z-index: 1;
}

.footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-text {
  font-size: 0.88rem;
  color: var(--text-muted);
}

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

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-link {
  font-size: 0.88rem;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.footer-link:hover {
  color: var(--accent-blue);
}

/* ===== SCROLL ANIMATIONS ===== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 {
  transition-delay: 0.1s;
}

.reveal-delay-2 {
  transition-delay: 0.2s;
}

.reveal-delay-3 {
  transition-delay: 0.3s;
}

.reveal-delay-4 {
  transition-delay: 0.4s;
}

.reveal-delay-5 {
  transition-delay: 0.5s;
}

/* Stagger children */
.stagger-children .reveal {
  transition-delay: calc(var(--i) * 0.1s);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  :root {
    --section-padding: 80px;
  }

  .hero .container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-content {
    order: 2;
  }

  .hero-visual {
    order: 1;
  }

  .hero-description {
    margin: 0 auto 36px;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-social {
    justify-content: center;
  }

  .hero-image-wrapper {
    width: 280px;
    height: 280px;
  }

  .floating-badge {
    display: none;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

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

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

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

@media (max-width: 768px) {
  :root {
    --section-padding: 60px;
  }

  html {
    font-size: 15px;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: rgba(10, 10, 15, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    padding: 24px;
    transition: right var(--transition-base);
    border-left: 1px solid var(--border-glass);
  }

  .nav-links.active {
    right: 0;
  }

  .nav-link {
    font-size: 1.1rem;
    padding: 14px 20px;
    width: 100%;
    text-align: center;
  }

  .nav-cta {
    margin-left: 0;
    margin-top: 16px;
    width: 100%;
    text-align: center;
    justify-content: center;
  }

  .nav-toggle {
    display: flex;
  }

  .projects-grid,
  .skills-grid,
  .certificates-grid,
  .courses-grid {
    grid-template-columns: 1fr;
  }

  .about-stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }

  .stat-card {
    padding: 16px;
  }

  .stat-number {
    font-size: 1.8rem;
  }

  .section-header {
    margin-bottom: 48px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .edu-details {
    grid-template-columns: 1fr;
  }

  .footer .container {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .hero-image-wrapper {
    width: 220px;
    height: 220px;
  }

  .education-card {
    padding: 28px;
  }

  .contact-info-card,
  .contact-form-card {
    padding: 28px;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: center;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }

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

  .hero-social {
    flex-direction: column;
    gap: 12px;
  }

  .timeline-item {
    padding-left: 56px;
  }

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

  .timeline-dot {
    left: 7px;
    width: 20px;
    height: 20px;
  }
}

/* ===== OVERLAY for mobile nav ===== */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
}

.nav-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* ===== BACK TO TOP ===== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-primary);
  border-radius: 14px;
  color: white;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 100;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition-base);
  border: none;
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}