/* 
 * Modern glassmorphism and enhanced styling 
 * 
 * This stylesheet defines the custom styles used throughout the website, 
 * focusing on glassmorphism effects, gradients, and responsive design.
 * It complements the Tailwind CSS utility classes used in the HTML.
 */

/* 
 * Section Divider
 * Creates a visual separation between sections with a glowing gradient effect.
 */
.section-divider {
  width: 100%;
  height: 4px;
  margin: 3rem 0 2rem 0;
  border-radius: 9999px;
  background: linear-gradient(90deg, #c0c0c0, #e5e7eb, #f3f4f6);
  box-shadow: 0 0 20px 6px rgba(192, 192, 192, 0.3);
  opacity: 0.9;
}

@media (max-width: 640px) {
  .section-divider {
    margin: 2rem 0 1.5rem 0;
    height: 3px;
  }
}

/* 
 * Glassmorphism Cards
 * These styles create a frosted glass effect for content containers.
 */
.glass-card {
  background: rgba(28, 28, 30, 0.8);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-card:hover {
  background: rgba(28, 28, 30, 0.9);
  border-color: rgba(192, 192, 192, 0.3);
  box-shadow:
    0 12px 40px rgba(0, 0, 0, 0.4),
    0 0 20px rgba(192, 192, 192, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
}

/* 
 * Utility Shadows
 * Specific shadow effects for different elements.
 */
.apple-shadow {
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.2);
}

.accent-glow {
  box-shadow: 0 0 20px rgba(192, 192, 192, 0.4);
}

/* 
 * Typography Enhancements
 * Custom text styles for gradients and modern headings.
 */
.gradient-text {
  background: linear-gradient(135deg, #c0c0c0, #e5e7eb, #f9fafb);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 600;
  letter-spacing: -0.025em;
}

.modern-heading {
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 1.1;
}

.modern-text {
  letter-spacing: 0.01em;
  line-height: 1.6;
}

/* 
 * Animated Gradient Background
 * Creates a subtle moving gradient background effect.
 */
.animated-gradient {
  background: linear-gradient(-45deg, #1f2937, #374151, #4b5563, #1f2937);
  background-size: 400% 400%;
  animation: gradient 20s ease infinite;
}

@keyframes gradient {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

/* 
 * Skill Badges
 * Styles for the tags listed in the skills section.
 */
.skill-badge {
  display: inline-block;
  background: rgba(192, 192, 192, 0.1);
  border: 1px solid rgba(192, 192, 192, 0.2);
  color: #d1d5db;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  margin: 0.25rem;
  transition: all 0.2s ease;
}

.skill-badge:hover {
  background: rgba(192, 192, 192, 0.2);
  border-color: rgba(192, 192, 192, 0.4);
  color: #e5e7eb;
  transform: translateY(-1px);
}

/* 
 * Project Cards
 * interactive cards for displaying portfolio projects.
 */
.project-card {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.project-card:hover {
  border-color: rgba(192, 192, 192, 0.3);
  transform: translateY(-4px);
  box-shadow:
    0 20px 40px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(192, 192, 192, 0.15);
}

/* 
 * General Utilities
 */
html {
  scroll-behavior: smooth;
}


/* Enhanced focus states for accessibility */
.focus-ring:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(192, 192, 192, 0.5), 0 0 0 4px rgba(0, 0, 0, 0.1);
}

/* 
 * Carousel Component Styles
 */
.carousel-container {
  width: 100%;
  max-width: 1200px;
  margin: 2rem auto 0;
  /* Removed bottom margin to reduce gap */
  overflow: hidden;
  position: relative;
  background: #fff;
  border-radius: 0.75rem;
  /* rounded-xl equivalent */
  padding: 20px 0;
  -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
  mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.carousel-track {
  display: flex;
  align-items: center;
  /* gap: 60px; REMOVED to fix animation jump */
  width: max-content;
  animation: scroll 40s linear infinite;
}

.carousel-track:hover {
  animation-play-state: paused;
}

.logo-item {
  width: 160px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 60px;
  /* Added proper spacing for infinite scroll calculation around 50% translate */
}

.logo-item img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  -webkit-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
  /* Optional: Add a subtle grayscale filter that lifts on hover for a premium feel */
  /* filter: grayscale(100%); */
  /* opacity: 0.7; */
  /* transition: all 0.3s ease; */
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-50%);
  }
}

.carousel-pause-btn {
  position: absolute;
  bottom: 5px;
  right: 5px;
  background: rgba(0, 0, 0, 0.5);
  border: none;
  border-radius: 50%;
  width: 30px;
  height: 30px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  z-index: 10;
  transition: background 0.3s;
}

.carousel-pause-btn:hover {
  background: rgba(0, 0, 0, 0.8);
}

.carousel-pause-btn span {
  font-size: 14px;
  line-height: 1;
}

.carousel-track.paused {
  animation-play-state: paused !important;
}