/* ==========================================================================
   Liu Hanwen (刘翰文) Personal Portfolio & Resume Website
   Clean, Comfortable, Responsive & Modern Styling
   ========================================================================== */

/* Root CSS Variables for comfort & typography */
:root {
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
  scroll-behavior: smooth;
  font-family: var(--font-sans);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}
.dark ::-webkit-scrollbar-thumb {
  background: #334155;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Glassmorphism effects */
.glass-header {
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

/* Clean card hover elevations */
.card-hover {
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.card-hover:hover {
  transform: translateY(-2px);
}

/* Subtle badge pulse */
@keyframes pulse-subtle {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.6;
    transform: scale(1.15);
  }
}
.badge-pulse {
  animation: pulse-subtle 2s infinite ease-in-out;
}

/* Gradient text accent */
.gradient-text {
  background: linear-gradient(135deg, #1e293b 0%, #2563eb 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.dark .gradient-text {
  background: linear-gradient(135deg, #f8fafc 0%, #60a5fa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Timeline line connector */
.timeline-stem {
  position: absolute;
  top: 14px;
  bottom: 0;
  left: 19px;
  width: 2px;
  background: linear-gradient(to bottom, #94a3b8 0%, #e2e8f0 100%);
}
.dark .timeline-stem {
  background: linear-gradient(to bottom, #475569 0%, #1e293b 100%);
}

/* Toast Notification */
#toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  transform: translateY(120%);
  opacity: 0;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}
#toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* Image gallery modal overlay */
.modal-overlay {
  transition: opacity 0.25s ease, visibility 0.25s ease;
}
