/* ==============================================
   FAIZAN ALI — PORTFOLIO 2026
   Apple-Inspired Premium Design System
   ============================================== */

/* -----------------------------------------------
   1. CSS CUSTOM PROPERTIES (DESIGN TOKENS)
   ----------------------------------------------- */
:root {
  /* Core Palette */
  --white:       #FFFFFF;
  --gray-50:     #F5F5F7;
  --gray-100:    #E8E8ED;
  --gray-200:    #D2D2D7;
  --gray-300:    #AEAEB2;
  --gray-400:    #8E8E93;
  --gray-500:    #636366;
  --gray-600:    #48484A;
  --gray-700:    #3A3A3C;
  --gray-800:    #2C2C2E;
  --gray-900:    #1C1C1E;
  --dark:        #1D1D1F;
  --accent:      #0071E3;
  --accent-hover:#0077ED;
  --accent-light:#E8F1FB;
  --accent-glow: rgba(0, 113, 227, 0.25);

  /* Semantic */
  --bg:          var(--white);
  --bg-alt:      var(--gray-50);
  --bg-card:     var(--white);
  --text-primary:   var(--dark);
  --text-secondary: var(--gray-500);
  --text-tertiary:  var(--gray-400);
  --border:      rgba(0, 0, 0, 0.08);
  --shadow-sm:   0 2px 8px rgba(0,0,0,0.06);
  --shadow-md:   0 8px 32px rgba(0,0,0,0.08);
  --shadow-lg:   0 24px 64px rgba(0,0,0,0.10);
  --shadow-card: 0 4px 24px rgba(0,0,0,0.07);

  /* Nav */
  --nav-bg:      rgba(255,255,255,0.80);
  --nav-border:  rgba(0,0,0,0.08);

  /* Glass */
  --glass-bg:    rgba(255,255,255,0.70);
  --glass-border:rgba(255,255,255,0.50);
  --glass-blur:  20px;

  /* Typography */
  --font:        'Inter', -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', Helvetica, Arial, sans-serif;

  /* Spacing */
  --section-py:  100px;
  --container:   1140px;

  /* Radius */
  --radius-sm:   8px;
  --radius-md:   14px;
  --radius-lg:   20px;
  --radius-xl:   28px;
  --radius-pill: 999px;

  /* Transitions */
  --ease:        cubic-bezier(0.25, 0.1, 0.25, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --trans-fast:  0.15s var(--ease);
  --trans:       0.28s var(--ease);
  --trans-slow:  0.45s var(--ease);
}

/* DARK MODE TOKENS */
[data-theme="dark"] {
  --bg:          #000000;
  --bg-alt:      #111111;
  --bg-card:     #1C1C1E;
  --text-primary:   #F5F5F7;
  --text-secondary: #AEAEB2;
  --text-tertiary:  #636366;
  --border:      rgba(255,255,255,0.10);
  --shadow-sm:   0 2px 8px rgba(0,0,0,0.40);
  --shadow-md:   0 8px 32px rgba(0,0,0,0.50);
  --shadow-lg:   0 24px 64px rgba(0,0,0,0.60);
  --shadow-card: 0 4px 24px rgba(0,0,0,0.40);
  --nav-bg:      rgba(0,0,0,0.80);
  --nav-border:  rgba(255,255,255,0.10);
  --glass-bg:    rgba(28,28,30,0.80);
  --glass-border:rgba(255,255,255,0.12);
  --accent-light:#0A1929;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

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

/* Focus styles for accessibility */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

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

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

ul, ol {
  list-style: none;
}

button {
  cursor: pointer;
  font-family: var(--font);
  border: none;
  background: none;
}

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

.section {
  padding: var(--section-py) 0;
  position: relative;
}

.section-alt {
  background-color: var(--bg-alt);
}

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

.section-label {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 700;
  letter-spacing: -0.025em;
  color: var(--text-primary);
  line-height: 1.1;
}

.section-divider {
  width: 48px;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
  border-radius: var(--radius-pill);
  margin: 20px auto 0;
}

/* -----------------------------------------------
   4. LOADING SCREEN
   ----------------------------------------------- */
#loader {
  position: fixed;
  inset: 0;
  background: #000;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

#loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-logo {
  width: 72px;
  height: 72px;
  background: var(--accent);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  font-weight: 800;
  color: white;
  animation: loader-pulse 1.2s ease-in-out infinite alternate;
}

.loader-bar {
  width: 200px;
  height: 3px;
  background: rgba(255,255,255,0.15);
  border-radius: var(--radius-pill);
  overflow: hidden;
}

.loader-bar-fill {
  height: 100%;
  background: var(--accent);
  border-radius: var(--radius-pill);
  animation: loader-fill 1.8s ease-out forwards;
}

@keyframes loader-pulse {
  from { transform: scale(0.95); box-shadow: 0 0 0 0 var(--accent-glow); }
  to   { transform: scale(1.05); box-shadow: 0 0 0 20px transparent; }
}

@keyframes loader-fill {
  from { width: 0%; }
  to   { width: 100%; }
}

/* -----------------------------------------------
   5. NAVIGATION
   ----------------------------------------------- */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: var(--nav-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border-bottom: 1px solid var(--nav-border);
  transition: background var(--trans), border-color var(--trans), box-shadow var(--trans);
}

#navbar.scrolled {
  box-shadow: var(--shadow-sm);
}

.nav-container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  gap: 32px;
}

/* Nav Logo */
.nav-logo {
  flex-shrink: 0;
  text-decoration: none;
}

.logo-text {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  transition: color var(--trans-fast);
}

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

/* Nav Links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  flex: 1;
  justify-content: center;
}

.nav-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: color var(--trans-fast), background var(--trans-fast);
  white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
  color: var(--accent);
  background: var(--accent-light);
}

/* Nav Controls */
.nav-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* Theme Button */
.theme-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  background: var(--bg-alt);
  border: 1px solid var(--border);
  transition: var(--trans);
}

.theme-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
  transform: rotate(15deg);
}

.sun-icon, .moon-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity var(--trans-fast), transform var(--trans-fast);
}

/* By default (light mode): show moon, hide sun */
body:not([data-theme="dark"]) .sun-icon { display: none; }
body:not([data-theme="dark"]) .moon-icon { display: flex; }
[data-theme="dark"] .sun-icon { display: flex; }
[data-theme="dark"] .moon-icon { display: none; }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 38px;
  height: 38px;
  padding: 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-alt);
}

.hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--trans);
  transform-origin: center;
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* -----------------------------------------------
   6. BUTTONS
   ----------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-pill);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: var(--trans);
  cursor: pointer;
  white-space: nowrap;
  border: none;
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0;
  transition: opacity var(--trans-fast);
}

.btn:hover::before { opacity: 1; }

/* Primary */
.btn-primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 4px 16px var(--accent-glow);
}

.btn-primary::before {
  background: rgba(255,255,255,0.12);
}

.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px var(--accent-glow);
}

.btn-primary:active { transform: translateY(0); }

/* Secondary */
.btn-secondary {
  background: var(--bg-alt);
  color: var(--text-primary);
  border: 1.5px solid var(--border);
}

.btn-secondary:hover {
  background: var(--bg-card);
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
}

/* Ghost */
.btn-ghost {
  background: transparent;
  color: var(--accent);
  border: 1.5px solid var(--accent);
}

.btn-ghost:hover {
  background: var(--accent);
  color: white;
  transform: translateY(-1px);
}

/* Small */
.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

/* Full Width */
.btn-full {
  width: 100%;
}

/* Project button */
.btn-project {
  background: var(--bg-alt);
  color: var(--text-primary);
  border: 1.5px solid var(--border);
  padding: 10px 20px;
  font-size: 14px;
  margin-top: auto;
}

.btn-project:hover {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
  transform: translateY(-1px);
}

/* Live Demo button */
.btn-live {
  background: rgba(52, 199, 89, 0.12);
  color: #30D158;
  border: 1.5px solid rgba(52, 199, 89, 0.30);
  padding: 10px 20px;
  font-size: 14px;
}

.btn-live:hover {
  background: #30D158;
  color: white;
  border-color: #30D158;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(52, 199, 89, 0.35);
}

/* Button group — Live + GitHub side by side */
.project-btn-group {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: auto;
}

/* Mini card link group */
.mini-link-group {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* Live link variant for mini cards */
.mini-link-live {
  background: rgba(52, 199, 89, 0.12);
  color: #30D158;
  border: 1px solid rgba(52, 199, 89, 0.30);
}

.mini-link-live:hover {
  background: #30D158;
  color: white;
}

/* Verify button */
.btn-verify {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-light);
  border: 1.5px solid transparent;
  border-radius: var(--radius-pill);
  transition: var(--trans);
  white-space: nowrap;
  margin-top: 16px;
}

.btn-verify:hover {
  background: var(--accent);
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px var(--accent-glow);
}

/* -----------------------------------------------
   7. GLASS CARD
   ----------------------------------------------- */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  transition: transform var(--trans), box-shadow var(--trans);
}

.glass-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* -----------------------------------------------
   8. HERO SECTION
   ----------------------------------------------- */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: 120px 0 80px;
}

/* Gradient Background */
.hero-bg-gradient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 60% -10%, rgba(0,113,227,0.10) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 100% 80%, rgba(0,113,227,0.06) 0%, transparent 60%),
    var(--bg);
  z-index: 0;
}

[data-theme="dark"] .hero-bg-gradient {
  background:
    radial-gradient(ellipse 80% 60% at 60% -10%, rgba(0,113,227,0.18) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 100% 80%, rgba(0,113,227,0.12) 0%, transparent 60%),
    var(--bg);
}

/* Orbs */
.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
}

.hero-orb-1 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(0,113,227,0.12), transparent);
  top: -100px; right: 200px;
  animation: orb-float 12s ease-in-out infinite alternate;
}

.hero-orb-2 {
  width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(0,113,227,0.08), transparent);
  bottom: 50px; left: -50px;
  animation: orb-float 9s ease-in-out infinite alternate-reverse;
}

.hero-orb-3 {
  width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(0,200,150,0.07), transparent);
  top: 50%; right: 50px;
  animation: orb-float 14s ease-in-out infinite alternate;
}

@keyframes orb-float {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(30px, -20px) scale(1.05); }
}

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

/* Hero Text */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-light);
  border: 1px solid rgba(0,113,227,0.20);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  margin-bottom: 24px;
}

.badge-dot {
  width: 7px;
  height: 7px;
  background: #30D158;
  border-radius: 50%;
  animation: dot-pulse 2s ease-in-out infinite;
}

@keyframes dot-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50%       { transform: scale(1.3); opacity: 0.7; }
}

.hero-name {
  font-size: clamp(44px, 7vw, 80px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.0;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.hero-roles {
  margin-bottom: 20px;
  height: 36px;
  display: flex;
  align-items: center;
}

.role-tag {
  font-size: clamp(18px, 2.5vw, 26px);
  font-weight: 500;
  color: var(--accent);
  letter-spacing: -0.02em;
}

.hero-intro {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-secondary);
  max-width: 520px;
  margin-bottom: 36px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 40px;
}

.hero-socials {
  display: flex;
  align-items: center;
  gap: 12px;
}

.social-link {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--text-secondary);
  background: var(--bg-alt);
  border: 1px solid var(--border);
  transition: var(--trans);
}

.social-link:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-light);
  transform: translateY(-2px);
}

/* Profile Image */
.hero-image {
  display: flex;
  align-items: center;
  justify-content: center;
}

.profile-frame {
  position: relative;
  width: 380px;
  height: 380px;
}

.profile-ring {
  position: absolute;
  inset: -12px;
  border-radius: 50%;
  background: conic-gradient(var(--accent) 0%, var(--accent) 70%, transparent 70%);
  animation: ring-rotate 8s linear infinite;
}

.profile-ring::before {
  content: '';
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  background: var(--bg);
}

@keyframes ring-rotate {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

.profile-photo {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  object-position: top;
  border: 4px solid var(--bg);
  box-shadow: var(--shadow-lg);
}

/* Floating Badges */
.float-badge {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 600;
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-md);
  color: var(--text-primary);
  white-space: nowrap;
  z-index: 3;
}

.float-badge span { font-size: 16px; }

.float-badge-1 {
  top: 10%;
  right: -20px;
  animation: badge-float 4s ease-in-out infinite alternate;
}

.float-badge-2 {
  bottom: 15%;
  left: -20px;
  animation: badge-float 5s ease-in-out infinite alternate-reverse;
}

@keyframes badge-float {
  from { transform: translateY(0px); }
  to   { transform: translateY(-8px); }
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-tertiary);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  transition: color var(--trans-fast);
  z-index: 1;
}

.scroll-indicator:hover { color: var(--accent); }

.scroll-mouse {
  width: 22px;
  height: 36px;
  border: 2px solid currentColor;
  border-radius: 11px;
  display: flex;
  justify-content: center;
  padding-top: 6px;
}

.scroll-wheel {
  width: 3px;
  height: 8px;
  background: currentColor;
  border-radius: 2px;
  animation: scroll-bounce 2s ease-in-out infinite;
}

@keyframes scroll-bounce {
  0%, 100% { transform: translateY(0); opacity: 1; }
  50%       { transform: translateY(8px); opacity: 0.3; }
}

/* -----------------------------------------------
   9. ABOUT SECTION
   ----------------------------------------------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-para {
  font-size: 16px;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.about-para strong {
  color: var(--text-primary);
  font-weight: 600;
}

.about-actions {
  display: flex;
  gap: 12px;
  margin-top: 36px;
  flex-wrap: wrap;
}

.about-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 20px;
  text-align: center;
  transition: var(--trans);
  box-shadow: var(--shadow-card);
  cursor: default;
}

.stat-card:hover {
  border-color: var(--accent);
  box-shadow: 0 8px 32px var(--accent-glow);
  transform: translateY(-4px);
}

.stat-icon {
  font-size: 28px;
  margin-bottom: 8px;
  display: block;
}

.stat-value {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.stat-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}

/* -----------------------------------------------
   10. EDUCATION / TIMELINE
   ----------------------------------------------- */
.timeline {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
}

/* Central vertical line */
.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  transform: translateX(-50%);
}

.timeline-item {
  display: grid;
  grid-template-columns: 1fr 40px 1fr;
  gap: 0 20px;
  margin-bottom: 48px;
  align-items: start;
}

/* Left item: card on left, dot in center */
.timeline-item .timeline-card { grid-column: 1; }
.timeline-item .timeline-dot  { grid-column: 2; }

/* Right item: dot in center, card on right */
.timeline-item-right .timeline-card {
  grid-column: 3;
  grid-row: 1;
}
.timeline-item-right .timeline-dot {
  grid-column: 2;
  grid-row: 1;
}

.timeline-dot {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 28px;
  z-index: 1;
}

.dot-inner {
  width: 16px;
  height: 16px;
  background: var(--accent);
  border-radius: 50%;
  border: 3px solid var(--bg);
  box-shadow: 0 0 0 3px var(--accent), 0 0 16px var(--accent-glow);
  flex-shrink: 0;
}

.timeline-card {
  padding: 28px;
}

.timeline-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  margin-bottom: 14px;
}

.current-badge {
  background: rgba(52, 199, 89, 0.15);
  color: #30D158;
  border: 1px solid rgba(52,199,89,0.25);
}

.completed-badge {
  background: var(--accent-light);
  color: var(--accent);
  border: 1px solid rgba(0,113,227,0.2);
}

.edu-icon { font-size: 28px; margin-bottom: 10px; }

.timeline-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.timeline-institution {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 8px;
}

.timeline-duration {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  color: var(--text-tertiary);
  font-weight: 500;
  margin-bottom: 12px;
}

.timeline-desc {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* -----------------------------------------------
   11. SKILLS SECTION
   ----------------------------------------------- */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.skill-category {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-card);
  transition: var(--trans);
  animation-delay: var(--delay, 0s);
}

.skill-category:hover {
  border-color: var(--accent);
  box-shadow: 0 8px 32px var(--accent-glow);
  transform: translateY(-2px);
}

.skill-category-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
}

.skill-cat-icon { font-size: 22px; }

.skill-category-header h3 {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
}

/* Progress bars */
.skill-items { display: flex; flex-direction: column; gap: 16px; }

.skill-item { cursor: default; }

.skill-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.skill-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.skill-pct {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
}

.skill-bar {
  height: 6px;
  background: var(--bg-alt);
  border-radius: var(--radius-pill);
  overflow: hidden;
  border: 1px solid var(--border);
}

.skill-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--accent), #34AADC);
  border-radius: var(--radius-pill);
  transition: width 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.3s;
}

.skill-fill.animated { width: var(--pct); }

/* Skill Chips */
.skill-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.skill-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  transition: var(--trans);
  cursor: default;
}

.skill-chip:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-light);
  transform: translateY(-2px);
}

.chip-icon { font-size: 15px; }

/* -----------------------------------------------
   12. EXPERIENCE SECTION
   ----------------------------------------------- */
.experience-card {
  max-width: 860px;
  margin: 0 auto;
  padding: 36px 40px;
}

.exp-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.exp-logo {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #0071E3, #34AADC);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 800;
  color: white;
  flex-shrink: 0;
  box-shadow: 0 4px 16px var(--accent-glow);
}

.exp-info { flex: 1; }

.exp-role {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.exp-company {
  font-size: 15px;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 6px;
}

.exp-duration {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  color: var(--text-tertiary);
  font-weight: 500;
}

.exp-badge {
  padding: 6px 14px;
  background: var(--accent-light);
  color: var(--accent);
  border: 1px solid rgba(0,113,227,0.20);
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  flex-shrink: 0;
}

.exp-responsibilities {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
}

.exp-responsibilities li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.exp-responsibilities li svg {
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 2px;
}

.exp-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.exp-tag {
  padding: 5px 12px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

/* -----------------------------------------------
   13. PROJECTS SECTION
   ----------------------------------------------- */

/* Filter Tabs */
.filter-tabs {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 48px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 9px 20px;
  border-radius: var(--radius-pill);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  background: var(--bg-alt);
  border: 1.5px solid var(--border);
  cursor: pointer;
  transition: var(--trans);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
  box-shadow: 0 4px 16px var(--accent-glow);
}

/* Featured Cards */
.featured-projects {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-bottom: 64px;
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: var(--trans);
  box-shadow: var(--shadow-card);
  display: flex;
}

.project-card:hover {
  border-color: var(--accent);
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.project-card-inner {
  padding: 28px;
  display: flex;
  flex-direction: column;
  width: 100%;
}

.project-icon-wrap {
  position: relative;
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.project-icon-bg {
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.project-icon {
  font-size: 28px;
  position: relative;
  z-index: 1;
}

.project-number {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-tertiary);
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}

.project-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 10px;
}

.project-desc {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 16px;
  flex: 1;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 20px;
}

.project-tag {
  padding: 4px 10px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
}

/* Mini Projects */
.mini-projects-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 24px;
  text-align: center;
}

.mini-projects {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.mini-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  transition: var(--trans);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 8px;
  animation-delay: var(--delay, 0s);
}

.mini-card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px var(--accent-glow);
}

.mini-icon { font-size: 28px; }

.mini-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.mini-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  flex: 1;
}

.mini-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-light);
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  transition: var(--trans-fast);
  width: fit-content;
}

.mini-link:hover {
  background: var(--accent);
  color: white;
}

/* Hidden (filtered out) cards */
.project-card.hidden,
.mini-card.hidden { display: none; }

/* -----------------------------------------------
   14. CERTIFICATIONS
   ----------------------------------------------- */
.cert-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.cert-card {
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 0;
  animation-delay: var(--delay, 0s);
}

.cert-icon-wrap {
  margin-bottom: 16px;
}

.cert-icon {
  font-size: 36px;
  display: inline-block;
  width: 64px;
  height: 64px;
  background: var(--bg-alt);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
}

.cert-content { flex: 1; }

.cert-issuer {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 8px;
}

.cert-title {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 10px;
  line-height: 1.3;
}

.cert-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* -----------------------------------------------
   15. CONTACT SECTION
   ----------------------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.contact-intro {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 32px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
  transition: var(--trans);
  cursor: default;
}

.contact-item:hover {
  border-color: var(--accent);
  background: var(--accent-light);
}

.contact-icon {
  width: 44px;
  height: 44px;
  background: var(--accent);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
}

.contact-detail { display: flex; flex-direction: column; gap: 2px; }

.contact-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-tertiary);
}

.contact-value {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  text-decoration: none;
  transition: color var(--trans-fast);
}

.contact-value:hover { color: var(--accent); }

.contact-socials {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.contact-social-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: var(--trans);
}

.contact-social-link:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-light);
  transform: translateY(-2px);
}

/* Contact Form */
.contact-form-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 36px;
  box-shadow: var(--shadow-card);
}

.form-group { margin-bottom: 20px; }

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.form-input,
.form-textarea {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-alt);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  font-family: var(--font);
  font-size: 15px;
  color: var(--text-primary);
  transition: border-color var(--trans-fast), box-shadow var(--trans-fast);
  outline: none;
  resize: vertical;
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--text-tertiary);
}

.form-input:focus,
.form-textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
  background: var(--bg-card);
}

.form-note {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 12px;
}

/* -----------------------------------------------
   16. FOOTER
   ----------------------------------------------- */
.footer {
  background: var(--dark);
  color: #F5F5F7;
  padding: 60px 0 36px;
}

[data-theme="dark"] .footer { background: #050505; }

.footer-container {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 40px;
  align-items: center;
  margin-bottom: 40px;
}

.footer-logo {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #F5F5F7;
  display: block;
  margin-bottom: 8px;
}

.footer-tagline {
  font-size: 13px;
  color: #86868B;
  font-style: italic;
  line-height: 1.4;
  max-width: 260px;
}

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

.footer-links a {
  font-size: 14px;
  color: #86868B;
  transition: color var(--trans-fast);
}

.footer-links a:hover { color: #F5F5F7; }

.footer-socials {
  display: flex;
  gap: 12px;
}

.footer-socials a {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.10);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #86868B;
  transition: var(--trans);
}

.footer-socials a:hover {
  color: white;
  background: var(--accent);
  border-color: var(--accent);
  transform: translateY(-2px);
}

.footer-copy {
  text-align: center;
  font-size: 13px;
  color: #48484A;
  padding-top: 36px;
  border-top: 1px solid rgba(255,255,255,0.08);
}

/* -----------------------------------------------
   17. SCROLL-TO-TOP BUTTON
   ----------------------------------------------- */
#scroll-top {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 48px;
  height: 48px;
  background: var(--accent);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px var(--accent-glow);
  z-index: 999;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: var(--trans);
  border: none;
  cursor: pointer;
}

#scroll-top.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

#scroll-top:hover {
  background: var(--accent-hover);
  transform: translateY(-3px);
  box-shadow: 0 8px 28px var(--accent-glow);
}

/* -----------------------------------------------
   18. ANIMATION UTILITIES
   ----------------------------------------------- */
[data-animate] {
  opacity: 0;
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
  transition-delay: var(--delay, 0s);
}

[data-animate="fade-up"]    { transform: translateY(40px); }
[data-animate="fade-right"] { transform: translateX(-40px); }
[data-animate="fade-left"]  { transform: translateX(40px); }

[data-animate].visible {
  opacity: 1;
  transform: translate(0, 0);
}

/* -----------------------------------------------
   19. RESPONSIVE — TABLET (max 1024px)
   ----------------------------------------------- */
@media (max-width: 1024px) {
  :root { --section-py: 80px; }

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

  .hero-image {
    order: -1;
  }

  .profile-frame {
    width: 300px;
    height: 300px;
  }

  .hero-intro { max-width: 100%; }
  .hero-cta   { justify-content: center; }
  .hero-socials { justify-content: center; }

  .float-badge-1 { right: -8px; }
  .float-badge-2 { left: -8px; }

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

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

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

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

  .footer-container {
    grid-template-columns: 1fr;
    gap: 24px;
    text-align: center;
  }

  .footer-tagline { max-width: 100%; margin: 0 auto; }
  .footer-links   { justify-content: center; }
  .footer-socials { justify-content: center; }
}

/* -----------------------------------------------
   20. RESPONSIVE — MOBILE (max 768px)
   ----------------------------------------------- */
@media (max-width: 768px) {
  :root { --section-py: 64px; }

  /* ── Navbar ──────────────────────────────────────
     The dropdown slides DOWN from below the navbar.
     Key fix: use top: 60px (navbar height), start
     hidden with opacity + pointer-events so it does
     NOT appear above the page content.
  ────────────────────────────────────────────────── */
  .nav-links {
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    background: var(--nav-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border-bottom: 1px solid var(--nav-border);
    box-shadow: var(--shadow-md);
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 12px 16px 16px;
    /* Hidden state: slide up + invisible */
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
    transition: transform 0.25s var(--ease),
                opacity   0.25s var(--ease),
                visibility 0s linear 0.25s;
    z-index: 998;
  }

  /* Open state: slide into place + visible */
  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
    transition: transform 0.25s var(--ease),
                opacity   0.25s var(--ease),
                visibility 0s linear 0s;
  }

  .nav-link {
    padding: 13px 16px;
    border-radius: var(--radius-md);
    font-size: 15px;
  }

  .hamburger { display: flex; }

  /* Remove Resume button from navbar on mobile */
  #nav-resume-btn { display: none; }

  /* ── Navbar layout on mobile:
     Logo → left   |   Theme toggle + Hamburger → right
  ────────────────────────────────────────────────────── */
  .nav-container {
    gap: 0;                   /* Remove gap so logo sits flush left */
  }

  .nav-controls {
    margin-left: auto;        /* Push controls all the way to the right */
    gap: 8px;
  }

  /* ── Scroll indicator: hide on mobile ───────── */
  .scroll-indicator { display: none; }

  /* ── Hero ────────────────────────────────────── */
  .hero-section {
    padding: 90px 0 56px;
    text-align: center;
  }

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

  .hero-image { order: -1; }

  .profile-frame  { width: 220px; height: 220px; }
  .hero-intro     { max-width: 100%; font-size: 15px; }
  .hero-badge     { margin-left: auto; margin-right: auto; }
  .hero-roles     { justify-content: center; }
  .hero-cta       { justify-content: center; }
  .hero-socials   { justify-content: center; }

  /* Float badges: keep inside frame */
  .float-badge-1  { right: -4px;  font-size: 11px; padding: 6px 10px; }
  .float-badge-2  { left: -4px;   font-size: 11px; padding: 6px 10px; }

  /* ── About ───────────────────────────────────── */
  .about-grid     { grid-template-columns: 1fr; gap: 32px; }
  .about-actions  { justify-content: center; }

  /* ── Education Timeline ─ single column ───────── */
  .timeline::before { display: none; }
  .timeline-item,
  .timeline-item-right {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap: 0;
  }
  .timeline-item .timeline-card,
  .timeline-item-right .timeline-card { grid-column: 1; grid-row: 2; }
  .timeline-item .timeline-dot,
  .timeline-item-right .timeline-dot  {
    grid-column: 1;
    grid-row: 1;
    padding-top: 0;
    padding-bottom: 10px;
    justify-content: flex-start;
  }

  /* ── Skills ──────────────────────────────────── */
  .skills-grid    { grid-template-columns: 1fr; }

  /* ── Projects ────────────────────────────────── */
  .featured-projects { grid-template-columns: 1fr; }
  .filter-tabs       { gap: 6px; }
  .filter-btn        { padding: 8px 14px; font-size: 13px; }

  /* ── Experience ──────────────────────────────── */
  .experience-card  { padding: 24px 20px; }
  .exp-header       { flex-wrap: wrap; gap: 14px; }

  /* ── Certifications ──────────────────────────── */
  .cert-grid        { grid-template-columns: 1fr; }

  /* ── Contact ─────────────────────────────────── */
  .contact-grid     { grid-template-columns: 1fr; gap: 32px; }
  .contact-form-wrap{ padding: 22px 18px; }
  .contact-socials  { gap: 8px; }
  .contact-social-link { padding: 8px 12px; font-size: 12px; }

  /* ── Footer ──────────────────────────────────── */
  .footer-container {
    grid-template-columns: 1fr;
    gap: 20px;
    text-align: center;
  }
  .footer-tagline { max-width: 100%; margin: 0 auto; }
  .footer-links   { justify-content: center; flex-wrap: wrap; gap: 16px; }
  .footer-socials { justify-content: center; }

  /* ── Scroll top ──────────────────────────────── */
  #scroll-top { bottom: 20px; right: 20px; width: 42px; height: 42px; }
}

/* -----------------------------------------------
   21. MOBILE SMALL (max 480px)
   ----------------------------------------------- */
@media (max-width: 480px) {
  .container { padding: 0 16px; }

  .section-title  { font-size: 28px; }
  .section-header { margin-bottom: 36px; }

  /* Hero */
  .hero-name      { font-size: 38px; }
  .profile-frame  { width: 190px; height: 190px; }
  .hero-cta       { flex-direction: column; align-items: stretch; }
  .hero-cta .btn  { width: 100%; justify-content: center; }

  /* About stats */
  .about-stats    { grid-template-columns: 1fr 1fr; gap: 12px; }
  .stat-card      { padding: 20px 14px; }

  /* Skills chips */
  .skill-chip     { font-size: 12px; padding: 7px 12px; }

  /* Mini projects */
  .mini-projects  { grid-template-columns: 1fr; }

  /* Experience */
  .exp-tags       { gap: 6px; }
  .exp-tag        { font-size: 11px; }

  /* Filter tabs wrap */
  .filter-tabs    { justify-content: center; }
}

/* -----------------------------------------------
   22. PRINT STYLES
   ----------------------------------------------- */
@media print {
  #loader, #navbar, #scroll-top, .hero-socials,
  .hero-cta, .footer-socials { display: none !important; }
  body { background: white; color: black; }
  .section { padding: 40px 0; }
}
