/* Design System - Modern Teal V3 (Refined) */

/* Tailwind Custom Layers */
@layer base {
  html {
    scroll-behavior: smooth;
  }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  background: #0d9488;
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: #0f766e;
}

/* Glassmorphism System */
.glass-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.dark .glass-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.gradient-text {
  background: linear-gradient(135deg, #0d9488, #14b8a6);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Floating Animation */
.floating-element {
  transition: transform 0.3s ease-out;
}

/* Video Modal Styles */
.video-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  z-index: 9999;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(8px);
}

.video-container {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  border-radius: 1rem;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.close-video {
  position: absolute;
  top: -2.5rem;
  right: 0;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border-radius: 50%;
  font-size: 1.5rem;
  transition: all 0.3s;
}

.close-video:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: rotate(90deg);
}

@media (max-width: 640px) {
  .close-video {
    top: -3rem;
    right: 0.5rem;
  }
}

/* Section Spacing Fix */
section {
  scroll-margin-top: 80px;
}

/* Hero Image Enhancement */
.image-aura {
  background: radial-gradient(circle, rgba(13, 148, 136, 0.3) 0%, rgba(20, 184, 166, 0) 70%);
  filter: blur(40px);
}

.rotating-border {
  background: conic-gradient(from 0deg, #0d9488, #14b8a6, transparent, #0d9488);
  animation: rotate-border 8s linear infinite;
}

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

.hero-blob {
  background: linear-gradient(135deg, rgba(13, 148, 136, 0.2), rgba(20, 184, 166, 0.2));
  filter: blur(40px);
  border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
}
/* Hero Stats Styles */
.hero-stats {
  perspective: 1000px;
}

.stat-item {
  transition: transform 0.3s ease;
}

.stat-item:hover {
  transform: translateY(-5px);
}

.stat-number {
  filter: drop-shadow(0 2px 4px rgba(13, 148, 136, 0.2));
}

@media (max-width: 640px) {
  .hero-stats {
    justify-content: center;
    gap: 2rem;
  }
}
/* Timeline System */
.timeline-container {
  position: relative;
  padding-left: 3rem;
}

.timeline-line {
  position: absolute;
  left: 0.75rem;
  top: 0;
  width: 2px;
  height: 100%;
  background: linear-gradient(to bottom, transparent, #0d9488 15%, #14b8a6 85%, transparent);
  opacity: 0.3;
}

.timeline-item {
  position: relative;
  margin-bottom: 4rem;
}

.timeline-marker {
  position: absolute;
  left: -3.05rem; /* Center on the 0.75rem line: 0.75 - 3.8 = -3.05 */
  top: 1.5rem;
  width: 1.5rem;
  height: 1.5rem;
  background: #0d9488;
  border: 4px solid #f8fafc; /* bg-slate-50 */
  border-radius: 50%;
  z-index: 10;
  transition: all 0.3s ease;
}

.dark .timeline-marker {
  border-color: #020617; /* bg-slate-950 */
}

.timeline-item:hover .timeline-marker {
  transform: scale(1.3);
  box-shadow: 0 0 15px rgba(13, 148, 136, 0.5);
}

.timeline-marker-pulse {
  position: absolute;
  inset: -8px;
  background: rgba(13, 148, 136, 0.2);
  border-radius: 50%;
  animation: pulse-ring 2s cubic-bezier(0.455, 0.03, 0.515, 0.955) infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.33); opacity: 1; }
  80%, 100% { transform: scale(1.2); opacity: 0; }
}

/* Experience Card Enhancements */
.experience-card {
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.experience-card:hover {
  transform: translateX(10px);
  border-color: rgba(13, 148, 136, 0.5) !important;
}

@media (max-width: 768px) {
  .timeline-container {
    padding-left: 2rem;
  }
  .timeline-line {
    left: 0.5rem;
  }
  .timeline-marker {
    left: -2.05rem;
    width: 1.25rem;
    height: 1.25rem;
  }
}

/* ================================
   Open Source Section Styles
   ================================ */

/* Contribution type badges */
.os-type-badge {
  border: 1px solid;
}

.os-type-feature {
  background: rgba(13, 148, 136, 0.12);
  color: #0d9488;
  border-color: rgba(13, 148, 136, 0.3);
}

.dark .os-type-feature {
  background: rgba(13, 148, 136, 0.18);
  color: #2dd4bf;
  border-color: rgba(45, 212, 191, 0.3);
}

.os-type-bugfix {
  background: rgba(239, 68, 68, 0.1);
  color: #dc2626;
  border-color: rgba(239, 68, 68, 0.25);
}

.dark .os-type-bugfix {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border-color: rgba(248, 113, 113, 0.3);
}

.os-type-docs {
  background: rgba(99, 102, 241, 0.1);
  color: #4f46e5;
  border-color: rgba(99, 102, 241, 0.25);
}

.dark .os-type-docs {
  background: rgba(99, 102, 241, 0.15);
  color: #a5b4fc;
  border-color: rgba(165, 180, 252, 0.3);
}

/* OS card lift on hover */
.os-card {
  transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275),
              box-shadow 0.35s ease,
              border-color 0.35s ease;
}

.os-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 60px -12px rgba(13, 148, 136, 0.2);
}

/* Stats bar subtle shimmer glow */
.os-stats-bar {
  position: relative;
  overflow: hidden;
}

.os-stats-bar::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 30%,
    rgba(13, 148, 136, 0.06) 50%,
    transparent 70%
  );
  background-size: 200% 100%;
  animation: shimmer-bar 4s ease-in-out infinite;
}

@keyframes shimmer-bar {
  0%   { background-position: -200% 0; }
  100% { background-position:  200% 0; }
}
