/* ============================================
   ANANT JOGLEKAR PORTFOLIO â€” DESIGN SYSTEM
   ============================================ */

/* --- Google Fonts Import --- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* ============================================
   DESIGN TOKENS — LIGHT MODE (DEFAULT)
   ============================================ */
:root {
  --bg:              #FFFFFF;
  --bg-alt:          #F7F7F7;
  --surface:         #FFFFFF;
  --surface-hover:   #F0F0F0;
  --text-primary:    #111111;
  --text-secondary:  #555555;
  --text-muted:      #888888;
  --accent:          #111111;
  --accent-dark:     #000000;
  --accent-light:    rgba(17, 17, 17, 0.05);
  --accent-glow:     rgba(17, 17, 17, 0.1);
  --border:          rgba(0, 0, 0, 0.08);
  --border-strong:   rgba(0, 0, 0, 0.16);
  --shadow-sm:       0 2px 8px rgba(0,0,0,0.04);
  --shadow-md:       0 8px 32px rgba(0,0,0,0.06);
  --shadow-lg:       0 24px 64px rgba(0,0,0,0.08);
  --shadow-card:     0 4px 24px rgba(0,0,0,0.04);
  --radius-sm:       8px;
  --radius-md:       16px;
  --radius-lg:       24px;
  --radius-xl:       32px;
  --transition:      0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  --nav-height:      72px;
}

/* ============================================
   DESIGN TOKENS — DARK MODE
   ============================================ */
[data-theme="dark"] {
  --bg:              #0A0A0A;
  --bg-alt:          #141414;
  --surface:         #1C1C1C;
  --surface-hover:   #282828;
  --text-primary:    #F5F5F5;
  --text-secondary:  #A0A0A0;
  --text-muted:      #666666;
  --accent:          #F5F5F5;
  --accent-dark:     #FFFFFF;
  --accent-light:    rgba(245, 245, 245, 0.1);
  --accent-glow:     rgba(245, 245, 245, 0.18);
  --border:          rgba(255, 255, 255, 0.08);
  --border-strong:   rgba(255, 255, 255, 0.16);
  --shadow-sm:       0 2px 8px rgba(0,0,0,0.3);
  --shadow-md:       0 8px 32px rgba(0,0,0,0.4);
  --shadow-lg:       0 24px 64px rgba(0,0,0,0.5);
  --shadow-card:     0 4px 24px rgba(0,0,0,0.3);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background-color: var(--bg);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
  transition: background-color var(--transition), color var(--transition);
}

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

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

button {
  border: none;
  background: none;
  font-family: inherit;
  cursor: pointer;
}

ul { list-style: none; }

/* ============================================
   PAGE LOADER
   ============================================ */
.page-loader {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 99990;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

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

.loader-text {
  font-size: clamp(32px, 5vw, 64px);
  font-weight: 800;
  letter-spacing: -2px;
  color: var(--text-primary);
  overflow: hidden;
}

.loader-text span {
  display: inline-block;
  animation: loaderReveal 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  transform: translateY(100%);
}

.loader-bar {
  position: absolute;
  bottom: 0; left: 0;
  height: 3px;
  background: var(--accent);
  animation: loaderBar 1.2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes loaderReveal {
  to { transform: translateY(0); }
}

@keyframes loaderBar {
  from { width: 0; }
  to   { width: 100%; }
}

/* ============================================
   TYPOGRAPHY
   ============================================ */
.display-xl {
  font-size: clamp(60px, 9vw, 130px);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -3px;
}

.display-lg {
  font-size: clamp(40px, 6vw, 80px);
  font-weight: 800;
  line-height: 1.0;
  letter-spacing: -2px;
}

.display-md {
  font-size: clamp(28px, 4vw, 52px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -1px;
}

.text-lg { font-size: clamp(18px, 2.2vw, 22px); font-weight: 400; line-height: 1.65; }
.text-md { font-size: 16px; line-height: 1.7; }
.text-sm { font-size: 14px; line-height: 1.6; }
.text-xs { font-size: 12px; line-height: 1.5; letter-spacing: 0.04em; }

.text-accent    { color: var(--accent); }
.text-secondary { color: var(--text-secondary); }
.text-muted     { color: var(--text-muted); }
.font-medium    { font-weight: 500; }
.font-semibold  { font-weight: 600; }
.font-bold      { font-weight: 700; }
.font-black     { font-weight: 800; }
.uppercase      { text-transform: uppercase; letter-spacing: 0.1em; }

/* ============================================
   LAYOUT UTILITIES
   ============================================ */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 40px;
}

.section {
  padding: 120px 0;
}

.section-sm {
  padding: 80px 0;
}

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-sm { gap: 12px; }
.gap-md { gap: 24px; }
.gap-lg { gap: 40px; }

/* ============================================
   NAVIGATION
   ============================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-height);
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition);
}

[data-theme="dark"] .nav {
  background: rgba(10, 10, 10, 0.95);
  border-bottom-color: var(--border);
}

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

.nav-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: opacity var(--transition);
}

.nav-logo:hover { opacity: 0.7; }

.nav-logo-dot {
  width: 8px; height: 8px;
  background: var(--accent);
  border-radius: 50%;
  display: inline-block;
}

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

.nav-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
  transition: color var(--transition);
  letter-spacing: 0.01em;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 0; height: 1.5px;
  background: var(--accent);
  transition: width var(--transition);
}

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

.nav-link:hover::after { width: 100%; }

.nav-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* Theme Toggle */
.theme-toggle {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: background var(--transition), border-color var(--transition), transform var(--transition);
  position: relative;
  overflow: hidden;
}

.theme-toggle:hover {
  background: var(--surface-hover);
  transform: rotate(20deg);
}

.theme-toggle svg {
  width: 18px; height: 18px;
  fill: var(--text-primary);
  position: absolute;
  transition: transform 0.4s cubic-bezier(0.4,0,0.2,1), opacity 0.3s ease;
}

.icon-sun  { opacity: 1; transform: rotate(0deg) scale(1); }
.icon-moon { opacity: 0; transform: rotate(-90deg) scale(0.5); }

[data-theme="dark"] .icon-sun  { opacity: 0; transform: rotate(90deg) scale(0.5); }
[data-theme="dark"] .icon-moon { opacity: 1; transform: rotate(0deg) scale(1); }

/* Mobile Menu */
.hamburger {
  display: none;
  width: 44px; height: 44px;
  align-items: center; justify-content: center;
  flex-direction: column;
  gap: 5px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.hamburger span {
  display: block;
  width: 20px; height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

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

.mobile-menu {
  position: fixed;
  top: var(--nav-height); left: 0; right: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 24px 40px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  transform: translateY(-110%);
  transition: transform var(--transition);
  z-index: 999;
}

.mobile-menu.open { transform: translateY(0); }

.mobile-link {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: color var(--transition);
}
.mobile-link:hover { color: var(--accent); }

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: calc(var(--nav-height) + 140px);
  padding-bottom: 100px;
  position: relative;
  overflow: hidden;
}

/* Design Blueprint Grid Overlay */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(to right, var(--border) 1px, transparent 1px),
    linear-gradient(to bottom, var(--border) 1px, transparent 1px);
  background-size: 100px 100px;
  background-position: center;
  mask-image: radial-gradient(circle at center, black 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(circle at center, black 30%, transparent 80%);
  opacity: 0.35;
  pointer-events: none;
  z-index: 0;
}

.hero-bg-text {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  font-size: clamp(120px, 20vw, 280px);
  font-weight: 900;
  letter-spacing: -8px;
  color: var(--bg-alt);
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  line-height: 1;
  z-index: 0;
  transition: color var(--transition-slow);
  opacity: 0.4;
}

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

.hero-eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  opacity: 0;
  animation: fadeUp 0.8s 0.3s cubic-bezier(0.16,1,0.3,1) forwards;
}

.hero-eyebrow-line {
  width: 40px; height: 1.5px;
  background: var(--text-primary);
}

.hero-eyebrow-text {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-secondary);
}

.hero-headline {
  opacity: 0;
  animation: fadeUp 0.9s 0.45s cubic-bezier(0.16,1,0.3,1) forwards;
  margin-bottom: 32px;
}

.hero-headline-italic {
  font-style: italic;
  font-weight: 300;
  color: var(--text-secondary);
}

.hero-sub {
  max-width: 540px;
  opacity: 0;
  animation: fadeUp 0.9s 0.6s cubic-bezier(0.16,1,0.3,1) forwards;
  margin-bottom: 48px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 24px;
  opacity: 0;
  animation: fadeUp 0.9s 0.75s cubic-bezier(0.16,1,0.3,1) forwards;
  flex-wrap: wrap;
}

.hero-scroll {
  position: absolute;
  bottom: 40px; right: 40px;
  display: flex;
  align-items: center;
  gap: 12px;
  opacity: 0;
  animation: fadeUp 0.9s 1s cubic-bezier(0.16,1,0.3,1) forwards;
}

.hero-scroll-line {
  width: 40px; height: 1px;
  background: var(--text-muted);
}

.hero-scroll-text {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  writing-mode: horizontal-tb;
}

/* Stats Row */
.hero-stats {
  display: flex;
  gap: 64px;
  margin-top: 64px;
  padding-top: 40px;
  border-top: 1px solid var(--border);
  opacity: 0;
  animation: fadeUp 0.9s 0.9s cubic-bezier(0.16,1,0.3,1) forwards;
  flex-wrap: wrap;
}

.hero-stats > div {
  position: relative;
}

.hero-stats > div:not(:last-child)::after {
  content: '';
  position: absolute;
  right: -32px;
  top: 15%;
  height: 70%;
  width: 1px;
  background: var(--border);
}

@media (max-width: 640px) {
  .hero-stats > div::after {
    display: none !important;
  }
}

.stat-num {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 800;
  letter-spacing: -2px;
  line-height: 1;
  color: var(--text-primary);
}

.stat-num span { color: var(--text-primary); }

.stat-label {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 8px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.1);
  transform: translateX(-100%);
  transition: transform 0.3s ease;
}

.btn:hover::before { transform: translateX(0); }

.btn-primary {
  background: var(--text-primary);
  color: var(--bg);
  border: 1.5px solid var(--text-primary);
}

.btn-primary:hover {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--text-primary);
  transform: translateY(-2px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border-strong);
}

.btn-ghost:hover {
  background: var(--text-primary);
  color: var(--bg);
  border-color: var(--text-primary);
  transform: translateY(-2px);
}

.btn-sm {
  padding: 10px 20px;
  font-size: 13px;
}

.btn-lg {
  padding: 18px 36px;
  font-size: 16px;
}

.btn-icon {
  width: 20px; height: 20px;
  transition: transform var(--transition);
}

.btn:hover .btn-icon { transform: translateX(3px); }

/* ============================================
   SECTION HEADER
   ============================================ */
.section-header {
  margin-bottom: 72px;
}

.section-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.section-label::before {
  content: '';
  display: block;
  width: 32px; height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

.section-title {
  margin-bottom: 20px;
}

.section-desc {
  max-width: 520px;
  color: var(--text-secondary);
}

/* ============================================
   ABOUT / SKILLS SECTION
   ============================================ */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.about-skills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 40px;
}

.skill-tag {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  transition: all var(--transition);
  color: var(--text-primary);
}

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

.skill-dot {
  width: 6px; height: 6px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
}

.tools-section {
  margin-top: 40px;
}

.tools-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.tools-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tool-chip {
  padding: 6px 14px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition);
}

.tool-chip:hover {
  background: var(--accent-light);
  border-color: var(--accent);
  color: var(--accent);
}

/* ============================================
   PORTFOLIO GRID
   ============================================ */
.portfolio {
  background: var(--bg);
  border-top: 1px solid var(--border);
  padding: 120px 0;
}

.filter-tabs {
  display: flex;
  gap: 32px;
  margin-bottom: 56px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 16px;
  flex-wrap: wrap;
}

.filter-tab {
  background: transparent;
  border: none;
  padding: 0 0 16px 0;
  border-radius: 0;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
  transition: color var(--transition);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.filter-tab:hover {
  color: var(--text-primary);
}

.filter-tab::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0;
  width: 0; height: 2px;
  background: var(--accent);
  transition: width var(--transition);
}

.filter-tab.active {
  color: var(--text-primary);
  font-weight: 700;
}

.filter-tab.active::after {
  width: 100%;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 80px 48px;
  counter-reset: project-counter;
}

/* Project Card */
.project-card {
  background: transparent;
  border: none;
  border-radius: 0;
  overflow: hidden;
  transition: opacity 0.4s ease;
  display: block;
  text-decoration: none;
  position: relative;
}

.project-card.hidden {
  display: none !important;
}

.project-card:not(.hidden) {
  counter-increment: project-counter;
}

.card-image-wrap {
  position: relative;
  overflow: hidden;
  background: var(--bg-alt);
  border-radius: var(--radius-md);
  margin-bottom: 20px;
  aspect-ratio: 16 / 11;
}

.card-image-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.16,1,0.3,1);
}

.project-card:hover .card-image-wrap img {
  transform: scale(1.04);
}

/* Image screen overlay */
.card-image-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.02);
  transition: background var(--transition);
  pointer-events: none;
}

[data-theme="dark"] .card-image-wrap::after {
  background: rgba(0, 0, 0, 0.25);
}

.project-card:hover .card-image-wrap::after {
  background: rgba(0, 0, 0, 0);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.15) 0%, transparent 60%);
  opacity: 0;
  transition: opacity var(--transition);
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 24px;
}

.project-card:hover .card-overlay { opacity: 1; }

.card-cta {
  background: var(--surface);
  color: var(--text-primary);
  border-radius: 100px;
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 700;
  transform: translateY(10px);
  transition: transform var(--transition), background var(--transition), color var(--transition);
}

.project-card:hover .card-cta {
  transform: translateY(0);
}

.card-body {
  padding: 0;
}

.card-category {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-secondary);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
}

.card-category::before {
  content: counter(project-counter, decimal-leading-zero) " — ";
  font-family: monospace;
  font-weight: 500;
  color: var(--text-muted);
  margin-right: 8px;
}

.card-title {
  display: inline-block;
  position: relative;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.3px;
  color: var(--text-primary);
  transition: color var(--transition);
}

.card-title::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 0; height: 1.5px;
  background: var(--text-primary);
  transition: width var(--transition);
}

.project-card:hover .card-title::after {
  width: 100%;
}

/* Remove arrow and placeholder old classes */
.card-arrow { display: none; }
.card-placeholder { display: none; }

/* ============================================
   EXPERIENCE / TIMELINE
   ============================================ */
.timeline-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.timeline-column-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-muted);
  margin-bottom: 32px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.timeline-column-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.timeline-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
}

.timeline-list::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, var(--accent), var(--border));
}

.timeline-item {
  padding: 0 0 36px 28px;
  position: relative;
}

.timeline-item:last-child { padding-bottom: 0; }

.timeline-dot {
  position: absolute;
  left: -4px; top: 6px;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--accent);
  transition: transform var(--transition), background var(--transition);
}

.timeline-item:hover .timeline-dot {
  background: var(--accent);
  transform: scale(1.4);
}

.timeline-item:first-child .timeline-dot {
  background: var(--accent);
}

.timeline-date {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 4px;
}

.timeline-role {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.2px;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.timeline-company {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

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

/* Education item */
.edu-item {
  padding: 20px 0 28px 28px;
  position: relative;
  border-bottom: 1px solid var(--border);
}

.edu-item:last-child { border-bottom: none; padding-bottom: 0; }

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--bg-alt);
  color: var(--text-primary);
  border-top: 1px solid var(--border);
  padding: 80px 0 40px;
}

[data-theme="dark"] .footer {
  background: var(--bg-alt);
  color: var(--text-primary);
  border-top-color: var(--border);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 60px;
  align-items: start;
  margin-bottom: 64px;
}

.footer-logo {
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -1.5px;
  margin-bottom: 16px;
  opacity: 0.9;
}

.footer-tagline {
  font-size: 16px;
  opacity: 0.5;
  font-weight: 400;
  margin-bottom: 36px;
  max-width: 360px;
  line-height: 1.6;
}

.footer-contact-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  opacity: 0.7;
  transition: opacity var(--transition);
  font-weight: 400;
}

.footer-contact-item:hover { opacity: 1; }

.footer-contact-icon {
  width: 20px; height: 20px;
  opacity: 0.6;
}

.footer-links-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  opacity: 0.5;
  margin-bottom: 20px;
}

.footer-links-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.footer-link {
  font-size: 16px;
  font-weight: 500;
  opacity: 0.7;
  transition: opacity var(--transition), color var(--transition);
  display: flex;
  align-items: center;
  gap: 8px;
}

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

.footer-bottom {
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

[data-theme="dark"] .footer-bottom {
  border-top-color: var(--border);
}

.footer-copy {
  font-size: 13px;
  opacity: 0.4;
}

.footer-made {
  font-size: 13px;
  opacity: 0.4;
  display: flex;
  align-items: center;
  gap: 4px;
}

.footer-heart {
  color: var(--accent);
  opacity: 1;
}

/* ============================================
   SCROLL REVEAL ANIMATIONS
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.16,1,0.3,1), transform 0.8s cubic-bezier(0.16,1,0.3,1);
}

.reveal.revealed {
  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; }
.reveal-delay-6 { transition-delay: 0.6s; }

.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.8s cubic-bezier(0.16,1,0.3,1), transform 0.8s cubic-bezier(0.16,1,0.3,1);
}
.reveal-left.revealed { opacity: 1; transform: translateX(0); }

.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.8s cubic-bezier(0.16,1,0.3,1), transform 0.8s cubic-bezier(0.16,1,0.3,1);
}
.reveal-right.revealed { opacity: 1; transform: translateX(0); }

/* ============================================
   KEYFRAMES
   ============================================ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes slideInLeft {
  from { transform: translateX(-60px); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

/* ============================================
   PROJECT DETAIL PAGE STYLES
   ============================================ */
.back-arrow {
  position: fixed;
  top: 32px; left: 32px;
  z-index: 1001;
  width: 48px; height: 48px;
  border-radius: 50%;
  background: var(--surface);
  border: 1.5px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  color: var(--text-primary);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  text-decoration: none;
  animation: slideInLeft 0.6s 0.2s cubic-bezier(0.16,1,0.3,1) both;
}

.back-arrow:hover {
  background: var(--text-primary);
  color: var(--bg);
  border-color: var(--text-primary);
  transform: scale(1.05) translateX(-2px);
}

.theme-toggle-fixed {
  position: fixed;
  top: 32px; right: 32px;
  z-index: 1001;
  width: 48px; height: 48px;
  border-radius: 50%;
  background: var(--surface);
  border: 1.5px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-primary);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  cursor: pointer;
  animation: fadeIn 0.6s 0.2s cubic-bezier(0.16,1,0.3,1) both;
}

.theme-toggle-fixed:hover {
  background: var(--text-primary);
  color: var(--bg);
  border-color: var(--text-primary);
  transform: scale(1.05) rotate(15deg);
}

.theme-toggle-fixed svg {
  width: 18px; height: 18px;
  fill: currentColor;
  transition: transform 0.4s cubic-bezier(0.4,0,0.2,1);
}

.project-hero {
  padding-top: 120px;
  padding-bottom: 60px;
}

.project-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.project-category-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  background: var(--accent-light);
  border: 1px solid var(--border-strong);
  border-radius: 100px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-primary);
}

.project-year {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
}

.project-hero-image {
  margin-top: 40px;
  border-radius: var(--radius-xl);
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 16/9;
  background: var(--bg-alt);
}

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

.project-body {
  padding: 60px 0;
}

.project-content-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 60px;
  align-items: start;
}

.project-description {
  font-size: clamp(16px, 1.8vw, 18px);
  line-height: 1.75;
  color: var(--text-secondary);
  margin-bottom: 40px;
}

.project-sidebar {
  position: sticky;
  top: 100px;
}

.sidebar-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px;
  margin-bottom: 16px;
}

.sidebar-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-muted);
  margin-bottom: 8px;
}

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

.behance-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 40px;
  background: var(--text-primary);
  color: var(--bg);
  border-radius: var(--radius-md);
  text-align: center;
  margin-top: 48px;
}

.behance-cta-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--bg);
}

.behance-cta-desc {
  font-size: 14px;
  color: var(--bg);
  opacity: 0.8;
  margin-bottom: 4px;
}

.btn-behance {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  background: var(--bg);
  color: var(--text-primary);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 700;
  transition: all var(--transition);
}

.btn-behance:hover {
  transform: translateY(-2px);
  background: var(--surface-hover);
}

.related-projects {
  padding: 80px 0;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 40px;
}

.related-projects .card-category::before {
  display: none;
}

/* ============================================
   DIVIDER
   ============================================ */
.divider {
  height: 1px;
  background: var(--border);
  margin: 0;
}

/* ============================================
   MARQUEE
   ============================================ */
.marquee-section {
  overflow: hidden;
  padding: 28px 0;
  background: var(--accent);
  position: relative;
}

.marquee-track {
  display: flex;
  white-space: nowrap;
  animation: marquee 20s linear infinite;
}

.marquee-item {
  display: inline-flex;
  align-items: center;
  gap: 32px;
  padding-right: 48px;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--bg);
}

.marquee-item::after {
  content: '◆';
  font-size: 10px;
  opacity: 0.5;
}

@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* Project Case Study Images */
.project-case-study-images {
  display: flex;
  flex-direction: column;
  gap: 32px;
  margin-top: 48px;
}

.project-case-study-images img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  display: block;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.project-case-study-images img:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

/* Back to Top Button */
.back-to-top {
  position: fixed;
  bottom: 40px;
  right: 40px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--text-primary);
  color: var(--bg);
  border: 1.5px solid var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: opacity 0.4s ease, transform 0.4s ease, visibility 0.4s ease, background 0.3s ease, color 0.3s ease;
  box-shadow: var(--shadow-sm);
}

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

.back-to-top:hover {
  background: transparent;
  color: var(--text-primary);
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

/* ============================================
   RESPONSIVE — TABLET
   ============================================ */
@media (max-width: 1024px) {
  .container { padding: 0 32px; }
  .about-grid { gap: 48px; }
  .projects-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .timeline-grid { gap: 28px; }
  .project-content-grid { grid-template-columns: 1fr; gap: 48px; }
  .project-sidebar { position: static; }
  .related-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { gap: 40px; }
}

@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 48px; }
  .timeline-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .hero-stats { gap: 32px; }
}

/* ============================================
   RESPONSIVE â€” MOBILE
   ============================================ */
@media (max-width: 640px) {
  .container { padding: 0 20px; }
  .section { padding: 80px 0; }
  .projects-grid { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr; }
  .about-skills-grid { grid-template-columns: 1fr; }
  .hero-stats { flex-direction: column; gap: 24px; }
  .filter-tabs { gap: 6px; }
  .filter-tab { padding: 8px 16px; font-size: 12px; }
  .footer-grid { grid-template-columns: 1fr; gap: 40px; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
  .hero-scroll { display: none; }
  .mobile-menu { padding: 24px 20px; }
  .behance-cta { padding: 28px; }
  .back-arrow { width: 44px; height: 44px; font-size: 17px; top: 16px; left: 16px; }
  .back-to-top { bottom: 24px; right: 24px; width: 40px; height: 40px; }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
  .nav, .page-loader { display: none; }
  .section { padding: 40px 0; }
}

