/* ===== CSS CUSTOM PROPERTIES ===== */

:root {
  --primary-dark: #258feb;
  --neon-blue: #00f3ff;
  --neon-purple: #8b5cf6;
  --neon-pink: #ec4899;
  --gray-200: #e5e7eb;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  /* Enhanced Shadow System */
  --shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg:
    0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl:
    0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
  --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
  /* Neon Shadows */
  --neon-shadow: 0 0 20px rgba(0, 243, 255, 0.5);
  --neon-shadow-purple: 0 0 20px rgba(139, 92, 246, 0.5);
  --neon-shadow-pink: 0 0 20px rgba(236, 72, 153, 0.5);
  /* Glass Effect */
  --glass-bg: rgba(255, 255, 255, 0.1);
  --glass-border: rgba(255, 255, 255, 0.2);
  --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
  /* Tilt Effect Variables */
  --tilt-shadow-light: rgba(0, 0, 0, 0.1);
  --tilt-shadow-dark: rgba(0, 0, 0, 0.3);
  --tilt-glare-light: rgba(255, 255, 255, 0.1);
  --tilt-glare-dark: rgba(255, 255, 255, 0.05);
  --card-shadow-light: rgba(0, 0, 0, 0.1);
  --card-shadow-dark: rgba(0, 0, 0, 0.2);
}

/* ===== LIVE BACKGROUND ===== */

.hero-section {
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
    radial-gradient(
      circle at 25% 75%,
      rgba(59, 130, 246, 0.15) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 75% 25%,
      rgba(139, 92, 246, 0.12) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 50% 50%,
      rgba(0, 243, 255, 0.08) 0%,
      transparent 60%
    );
  animation: backgroundFloat 25s ease-in-out infinite;
  z-index: -1;
}

.hero-section::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    transparent 30%,
    rgba(59, 130, 246, 0.06) 50%,
    transparent 70%
  );
  animation: backgroundShimmer 30s linear infinite;
  z-index: -1;
}

@keyframes backgroundFloat {
  0%,
  100% {
    transform: translateY(0px) rotate(0deg) scale(1);
  }
  33% {
    transform: translateY(-20px) rotate(0.8deg) scale(1.03);
  }
  66% {
    transform: translateY(12px) rotate(-0.8deg) scale(0.97);
  }
}

@keyframes backgroundShimmer {
  0% {
    transform: translateX(-100%) translateY(-100%) rotate(0deg);
  }
  100% {
    transform: translateX(100%) translateY(100%) rotate(360deg);
  }
}

/* ===== GLOBAL ANIMATIONS ===== */

@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Alternative animation without transform for better button compatibility */

@keyframes fadeInUpSimple {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

/* ===== BUTTON INTERACTION FIXES ===== */

.project-card a,
.skill-card a,
.certificate-card a {
  position: relative;
  z-index: 10;
  pointer-events: auto !important;
  cursor: pointer !important;
}

.project-card a:hover,
.skill-card a:hover,
.certificate-card a:hover {
  transform: none !important;
}

/* Ensure project buttons are always clickable */

.project-card .flex.space-x-4 a {
  display: inline-flex !important;
  pointer-events: auto !important;
  cursor: pointer !important;
  position: relative;
  z-index: 20;
}

@keyframes fadeInDown {
  0% {
    opacity: 0;
    transform: translateY(-30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInLeft {
  0% {
    opacity: 0;
    transform: translateX(-50px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInRight {
  0% {
    opacity: 0;
    transform: translateX(50px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes bounceIn {
  0% {
    opacity: 0;
    transform: scale(0.3);
  }
  50% {
    opacity: 1;
    transform: scale(1.05);
  }
  70% {
    transform: scale(0.9);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes slideInUp {
  0% {
    opacity: 0;
    transform: translateY(60px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInScale {
  0% {
    opacity: 0;
    transform: scale(0.9) translateY(20px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@keyframes slideInFromBottom {
  0% {
    opacity: 0;
    transform: translateY(100px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes rotateIn {
  0% {
    opacity: 0;
    transform: rotate(-180deg) scale(0.3);
  }
  100% {
    opacity: 1;
    transform: rotate(0deg) scale(1);
  }
}

@keyframes zoomIn {
  0% {
    opacity: 0;
    transform: scale(0.5);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes slideInFromTop {
  0% {
    opacity: 0;
    transform: translateY(-50px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

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

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

/* ===== PROFESSIONAL NEON NAME EFFECT ===== */

.neon-name {
  color: var(--primary-color);
  text-shadow:
    0 0 1px rgba(59, 130, 246, 0.3),
    0 0 2px rgba(59, 130, 246, 0.2),
    0 0 4px rgba(59, 130, 246, 0.1),
    0 0 8px rgba(59, 130, 246, 0.05);
  animation: professionalNeon 3s ease-in-out infinite;
  position: relative;
  z-index: 1;
  --primary-color: #3b95f6;
}

.dark .neon-name {
  color: var(--primary-color);
  text-shadow:
    0 0 1px rgba(59, 130, 246, 0.4),
    0 0 2px rgba(59, 130, 246, 0.3),
    0 0 4px rgba(59, 130, 246, 0.2),
    0 0 8px rgba(59, 130, 246, 0.1);
}

@keyframes professionalNeon {
  0%,
  100% {
    text-shadow:
      0 0 1px rgba(59, 130, 246, 0.3),
      0 0 2px rgba(59, 130, 246, 0.2),
      0 0 4px rgba(59, 130, 246, 0.1),
      0 0 8px rgba(59, 130, 246, 0.05);
  }
  50% {
    text-shadow:
      0 0 2px rgba(59, 130, 246, 0.4),
      0 0 4px rgba(59, 130, 246, 0.3),
      0 0 8px rgba(59, 130, 246, 0.2),
      0 0 12px rgba(59, 130, 246, 0.1);
  }
}

.dark .neon-name {
  animation: professionalNeonDark 5s ease-in-out infinite;
}

@keyframes professionalNeonDark {
  0%,
  100% {
    text-shadow:
      0 0 1px rgba(59, 130, 246, 0.4),
      0 0 2px rgba(59, 130, 246, 0.3),
      0 0 4px rgba(59, 130, 246, 0.2),
      0 0 8px rgba(59, 130, 246, 0.1);
  }
  50% {
    text-shadow:
      0 0 2px rgba(59, 130, 246, 0.5),
      0 0 4px rgba(59, 130, 246, 0.4),
      0 0 8px rgba(59, 130, 246, 0.3),
      0 0 12px rgba(59, 130, 246, 0.2);
  }
}

/* ===== TIMELINE STYLES ===== */

.timeline-item:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 7px;
  top: 24px;
  height: calc(100% - 24px);
  width: 2px;
  background: linear-gradient(180deg, var(--neon-blue), var(--neon-purple));
  z-index: 1;
  box-shadow: var(--neon-shadow);
}

.dark .timeline-item:not(:last-child)::after {
  background: linear-gradient(180deg, var(--neon-purple), var(--neon-blue));
  box-shadow: var(--neon-shadow-purple);
}

/* ===== TRANSITION UTILITIES ===== */

.transition-bg {
  transition: background-color var(--transition-normal);
}

.transition-all {
  transition: all var(--transition-normal);
}

.transition-transform {
  transition: transform var(--transition-normal);
}

.transition-shadow {
  transition: box-shadow var(--transition-normal);
}

/* ===== CUSTOM SCROLLBAR ===== */

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--primary-color), var(--neon-blue));
  border-radius: 4px;
  transition: background-color var(--transition-fast);
  box-shadow: var(--neon-shadow);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--primary-dark), var(--neon-blue));
  box-shadow: var(--neon-shadow-purple);
}

.dark ::-webkit-scrollbar-track {
  background: var(--gray-800);
}

.dark ::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--primary-dark), var(--neon-blue));
  box-shadow: var(--neon-shadow-pink);
}

/* ===== NAVIGATION STYLES ===== */

.nav-link {
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--neon-blue), var(--neon-purple));
  transition: width var(--transition-normal);
  box-shadow: var(--neon-shadow);
}

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

.nav-link:hover {
  transform: translateY(-2px);
}

/* ===== SOCIAL ICON STYLES (NO HOVER COLOR CHANGES) ===== */

.social-icon {
  transition: all var(--transition-normal);
  cursor: pointer;
  position: relative;
  display: inline-block;
}

.social-icon:hover {
  transform: translateY(-5px) scale(1.1);
}

.social-icon:active {
  transform: scale(0.95);
}

.social-icon::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: radial-gradient(circle, var(--primary-color), transparent);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: all var(--transition-normal);
  z-index: -1;
}

.social-icon:hover::before {
  width: 100%;
  height: 100%;
}

/* ===== FOLLOW ME SECTION ICONS (NO HOVER COLORS) ===== */

.contact-section .social-icon {
  transition: transform var(--transition-normal);
}

.contact-section .social-icon:hover {
  transform: translateY(-5px) scale(1.1);
}

.contact-section .social-icon:active {
  transform: scale(0.95);
}

.contact-section .social-icon::before {
  display: none;
}

/* ===== HOME SECTION SOCIAL ICONS (MATCH CONTACT SECTION) ===== */

.hero-section .social-icon {
  transition: transform var(--transition-normal);
  display: inline-block;
  position: relative;
}

.hero-section .social-icon:hover {
  transform: translateY(-5px) scale(1.1);
}

.hero-section .social-icon:active {
  transform: scale(0.95);
}

/* Disable the background effect for home section social icons */

.hero-section .social-icon::before {
  display: none;
}

/* Ensure LinkedIn image styling matches contact section */

.hero-section .social-icon img {
  width: 2rem;
  height: 2rem;
  transition: all var(--transition-normal);
}

/* GitHub icon styling to match contact section */

.hero-section .social-icon i.fab.fa-github {
  font-size: 2rem;
  transition: all var(--transition-normal);
}

/* ===== ANIMATION UTILITIES ===== */

.animate-on-scroll {
  opacity: 0;
  transform: translateY(20px);
  transition: all var(--transition-slow);
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== HERO SECTION ANIMATIONS ===== */

.hero-title {
  animation: fadeInScale 1.2s ease-out forwards;
  text-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  opacity: 1 !important;
}

.hero-subtitle {
  animation: slideInUp 1s ease-out 0.3s both;
  opacity: 1 !important;
}

.hero-button {
  animation: fadeInUp 0.8s ease-out 0.8s both;
  opacity: 1 !important;
}

.hero-button:nth-child(2) {
  animation-delay: 1s;
}

/* ===== SKILL CARDS ===== */

.skill-card {
  transition: all var(--transition-slow);
  position: relative;
  overflow: hidden;
  animation: fadeInUp 0.8s ease-out;
  border: 1px solid transparent;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.1),
    rgba(255, 255, 255, 0.05)
  );
  backdrop-filter: blur(10px);
}

.skill-card:nth-child(1) {
  animation-delay: 0.1s;
}

.skill-card:nth-child(2) {
  animation-delay: 0.2s;
}

.skill-card:nth-child(3) {
  animation-delay: 0.3s;
}

.skill-card:nth-child(4) {
  animation-delay: 0.4s;
}

.skill-card:nth-child(5) {
  animation-delay: 0.5s;
}

.skill-card:nth-child(6) {
  animation-delay: 0.6s;
}

.skill-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(59, 130, 246, 0.1),
    transparent
  );
  transition: left var(--transition-slow);
}

.skill-card:hover::before {
  left: 100%;
}

.skill-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-2xl);
  border-color: var(--primary-color);
}

.skill-card .skill-icon {
  transition: all var(--transition-slow);
}

.skill-card:hover .skill-icon {
  transform: rotate(360deg) scale(1.2);
  color: var(--primary-color);
}

/* ===== PROJECT CARDS ===== */

.project-card {
  transition: all var(--transition-slow);
  position: relative;
  animation: scaleIn 0.8s ease-out;
  overflow: hidden;
  border: 1px solid transparent;
}

.project-card:nth-child(1) {
  animation-delay: 0.1s;
}

.project-card:nth-child(2) {
  animation-delay: 0.2s;
}

.project-card:nth-child(3) {
  animation-delay: 0.3s;
}

.project-card:nth-child(4) {
  animation-delay: 0.4s;
}

.project-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, transparent, rgba(59, 130, 246, 0.05));
  opacity: 0;
  transition: opacity var(--transition-normal);
}

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

.project-card:hover {
  transform: translateY(-12px);
  box-shadow: var(--shadow-2xl);
  border-color: var(--primary-color);
}

.project-card img {
  transition: transform var(--transition-normal);
}

.project-card:hover img {
  transform: scale(1.03);
}

/* ===== CERTIFICATE CARDS ===== */

.certificate-card {
  transition: all var(--transition-slow);
  position: relative;
  overflow: hidden;
  border: 1px solid transparent;
  animation: bounceIn 0.8s ease-out;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.1),
    rgba(255, 255, 255, 0.05)
  );
  backdrop-filter: blur(10px);
}

.certificate-card:nth-child(1) {
  animation-delay: 0.1s;
}

.certificate-card:nth-child(2) {
  animation-delay: 0.2s;
}

.certificate-card:nth-child(3) {
  animation-delay: 0.3s;
}

.certificate-card:nth-child(4) {
  animation-delay: 0.4s;
}

.certificate-card:nth-child(5) {
  animation-delay: 0.5s;
}

.certificate-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, var(--primary-color), var(--primary-dark));
  opacity: 0;
  transition: opacity var(--transition-normal);
  z-index: -1;
}

.certificate-card:hover::before {
  opacity: 0.05;
}

.certificate-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: var(--primary-color);
  box-shadow: var(--shadow-2xl);
}

.certificate-card .certificate-icon {
  transition: all var(--transition-bounce);
}

.certificate-card:hover .certificate-icon {
  transform: rotate(5deg) scale(1.2);
  color: var(--primary-color);
}

/* ===== TIMELINE STYLES ===== */

.timeline-dot {
  animation: scaleIn 0.6s ease-out;
  transition: all var(--transition-normal);
}

.timeline-dot:hover {
  transform: scale(1.2);
  box-shadow: var(--neon-shadow);
}

.timeline-item {
  animation: fadeInLeft 0.8s ease-out;
  transition: all var(--transition-normal);
}

.timeline-item:nth-child(1) {
  animation-delay: 0.1s;
}

.timeline-item:nth-child(2) {
  animation-delay: 0.2s;
}

.timeline-item:nth-child(3) {
  animation-delay: 0.3s;
}

.timeline-item:hover {
  transform: translateX(5px);
}

.timeline-item .bg-white,
.timeline-item .dark\\:bg-gray-800 {
  transition: all var(--transition-normal);
}

.timeline-item:hover .bg-white,
.timeline-item:hover .dark\\:bg-gray-800 {
  box-shadow: var(--shadow-xl);
  transform: translateY(-2px);
}

/* ===== BACK TO TOP BUTTON ===== */

.back-to-top {
  animation: fadeInUp 0.7s ease-out;
  transition: all var(--transition-normal);
  backdrop-filter: blur(10px);
  background: linear-gradient(
    135deg,
    var(--primary-color),
    var(--primary-dark)
  );
  border-radius: 50%;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-2xl);
  background: linear-gradient(135deg, var(--primary-dark), var(--neon-blue));
}

/* ===== SECTION ANIMATIONS ===== */

.about-section {
  animation: slideInFromBottom 0.4s ease-out;
}

.skills-section {
  animation: slideInFromBottom 0.4s ease-out 0.05s both;
}

.projects-section {
  animation: slideInFromBottom 0.4s ease-out 0.1s both;
}

.experience-section {
  animation: slideInFromBottom 0.4s ease-out 0.15s both;
}

.education-section {
  animation: slideInFromBottom 0.4s ease-out 0.2s both;
}

.certificates-section {
  animation: slideInFromBottom 0.4s ease-out 0.25s both;
}

.contact-section {
  animation: slideInFromBottom 0.4s ease-out 0.3s both;
}

/* ===== PROFILE PHOTO ANIMATION ===== */

.profile-photo {
  animation: photoFloat 6s ease-in-out infinite;
  transition: all var(--transition-normal);
}

.profile-photo:hover {
  animation: photoPulse 0.6s ease-out;
  transform: scale(1.02);
}

@keyframes photoFloat {
  0%,
  100% {
    transform: translateY(0px) rotate(0deg);
  }
  25% {
    transform: translateY(-3px) rotate(0.3deg);
  }
  50% {
    transform: translateY(-2px) rotate(-0.2deg);
  }
  75% {
    transform: translateY(-4px) rotate(0.2deg);
  }
}

@keyframes photoPulse {
  0% {
    transform: scale(1.02);
  }
  50% {
    transform: scale(1.04);
  }
  100% {
    transform: scale(1.02);
  }
}

/* ===== ENHANCED HOVER EFFECTS ===== */

.skill-card:hover .skill-icon {
  animation: float 3s ease-in-out infinite;
}

.project-card:hover img {
  animation: none;
}

.certificate-card:hover .certificate-icon {
  animation: bounceIn 0.6s ease-out;
}

/* ===== GLASS MORPHISM EFFECTS ===== */

.glass-effect {
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
}

/* ===== ENHANCED HEADER GLASS EFFECT ===== */

header {
  background: rgba(255, 255, 255, 0.8) !important;
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.dark header {
  background: rgba(17, 24, 39, 0.8) !important;
  border-bottom: 1px solid rgba(59, 130, 246, 0.2);
}

/* ===== ENHANCED BUTTON EFFECTS ===== */

.btn-primary {
  position: relative;
  overflow: hidden;
  transition: all var(--transition-normal);
}

.btn-primary::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: left var(--transition-slow);
}

.btn-primary:hover::before {
  left: 100%;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
}

/* ===== ENHANCED CARD HOVER EFFECTS ===== */

.skill-card:hover,
.project-card:hover,
.certificate-card:hover {
  border-color: var(--primary-color);
  box-shadow:
    var(--shadow-2xl),
    0 0 20px rgba(59, 130, 246, 0.1);
}

/* ===== LOADING ANIMATIONS ===== */

.loading-animation {
  opacity: 0;
  animation: fadeInUp 0.8s ease-out forwards;
}

.loading-animation:nth-child(1) {
  animation-delay: 0.1s;
}

.loading-animation:nth-child(2) {
  animation-delay: 0.2s;
}

.loading-animation:nth-child(3) {
  animation-delay: 0.3s;
}

.loading-animation:nth-child(4) {
  animation-delay: 0.4s;
}

.loading-animation:nth-child(5) {
  animation-delay: 0.5s;
}

.loading-animation:nth-child(6) {
  animation-delay: 0.6s;
}

.loading-animation:nth-child(7) {
  animation-delay: 0.7s;
}

.loading-animation:nth-child(8) {
  animation-delay: 0.8s;
}

/* ===== RESPONSIVE UTILITIES ===== */

@media (max-width: 768px) {
  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  .skill-card:hover {
    transform: translateY(-4px) scale(1.01);
  }
  .project-card:hover {
    transform: translateY(-6px);
  }
  .certificate-card:hover {
    transform: translateY(-4px) scale(1.01);
  }
}

/* ===== ACCESSIBILITY IMPROVEMENTS ===== */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ===== FOCUS STYLES ===== */

button:focus,
a:focus,
input:focus,
textarea:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
  box-shadow: var(--shadow-md);
}

/* ===== PRINT STYLES ===== */

@media print {
  .no-print {
    display: none !important;
  }
}

/* ===== SMOOTH SCROLL BEHAVIOR ===== */

html {
  scroll-behavior: smooth;
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */

* {
  will-change: auto;
}

.animate-on-scroll {
  will-change: transform, opacity;
}

.skill-card,
.project-card,
.certificate-card {
  will-change: transform, box-shadow;
}

/* ===== DARK MODE ENHANCEMENTS ===== */

.dark .skill-card,
.dark .project-card,
.dark .certificate-card {
  background: linear-gradient(
    135deg,
    rgba(31, 41, 55, 0.8),
    rgba(17, 24, 39, 0.9)
  );
  border-color: rgba(59, 130, 246, 0.2);
}

.dark .skill-card:hover,
.dark .project-card:hover,
.dark .certificate-card:hover {
  border-color: var(--primary-color);
  background: linear-gradient(
    135deg,
    rgba(31, 41, 55, 0.9),
    rgba(17, 24, 39, 1)
  );
}

/* ===== PROJECTS CAROUSEL STYLES ===== */

.project-carousel {
  position: relative;
  max-width: 100%;
  margin: 0 auto;
}

/* Carousel navigation buttons */ /*

:root
  --
  --
  --

.carousel-nav-button {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.dark .carousel-nav-button {
  background: rgba(31, 41, 55, 0.9);
  border: 1px solid rgba(75, 85, 99, 0.3);
}

.carousel-nav-button:hover {
  background: rgba(255, 255, 255, 1);
  transform: scale(1.1);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.dark .carousel-nav-button:hover {
  background: rgba(31, 41, 55, 1);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

/* Project indicators */

.project-indicator {
  cursor: pointer;
  transition: all 0.3s ease;
}

.project-indicator:hover {
  transform: scale(1.2);
}

.project-indicator.active {
  background: var(--primary-color);
  transform: scale(1.1);
}

/* Carousel animations */

@keyframes slideInProject {
  0% {
    opacity: 0.7;
    transform: scale(0.95);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

/* Responsive adjustments for carousel */

@media (max-width: 768px) {
  .carousel-nav-button {
    padding: 0.75rem;
    transform: translateY(-50%);
  }
  .carousel-nav-button i {
    font-size: 1rem;
  }
}

/* Touch interaction feedback */

.projects-track {
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
}

/* ===== CUSTOM CURSOR STYLES ===== */

/* Hide default cursor when custom cursor is active */

body:has(.cursor-dot) 


/* Fallback for browsers that don't support :has() */

body.custom-cursor-active {
  cursor: none;
}

/* Custom Cursor Styles */

.cursor-dot,
.cursor-dot-outline {
  pointer-events: none;
  position: fixed;
  left: 0;
  opacity: 0;
  transform: translate(-50%, -50%);
  transition: opacity 0.3s ease;
  z-index: 9999;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}

.cursor-dot {
  width: 8px;
  height: 8px;
  background-color: var(--primary-color);
  transition:
    width 0.3s ease,
    height 0.3s ease,
    background-color 0.3s ease;
}

.cursor-dot-outline {
  width: 40px;
  height: 40px;
  background-color: rgba(59, 149, 246, 0.2);
  transition:
    transform 0.3s ease,
    width 0.3s ease,
    height 0.3s ease,
    background-color 0.3s ease;
  z-index: 9998;
}

/* Dark mode cursor adjustments */

.dark .cursor-dot {
  background-color: var(--primary-color);
}

.dark .cursor-dot-outline {
  background-color: rgba(59, 149, 246, 0.15);
}

/* Cursor hover states */

.cursor-hover .cursor-dot {
  width: 12px;
  height: 12px;
  background-color: var(--neon-blue);
}

.cursor-hover .cursor-dot-outline {
  width: 24px;
  height: 24px;
  background-color: var(--primary-color);
}

.dark .cursor-hover .cursor-dot-outline {
  background-color: var(--primary-dark);
}

/* Cursor click state */

.cursor-click .cursor-dot {
  transform: translate(-50%, -50%) scale(0.5);
  background-color: var(--primary-dark);
}

.cursor-click .cursor-dot-outline {
  transform: translate(-50%, -50%) scale(1.5);
  opacity: 0.2;
  background-color: var(--primary-dark);
}

/* Hide custom cursor on touch devices */

@media (hover: none) and (pointer: coarse) {
  .cursor-dot,
  .cursor-dot-outline {
    display: none;
  }
}

/* Additional mobile fallback */

@media (max-width: 768px) {
  .cursor-dot,
  .cursor-dot-outline {
    display: none;
  }
}

/* ===== TILT EFFECT STYLES ===== */

.project-card {
  transition:
    transform 0.1s ease-out,
    box-shadow 0.1s ease-out;
  transform-style: preserve-3d;
  will-change: transform, box-shadow;
}

/* Disable tilt effect on mobile devices for better performance */

@media (max-width: 768px) {
  .project-card {
    transform: none !important;
    box-shadow: var(--shadow-md) !important;
  }
}

/* Ensure tilt effect doesn't interfere with existing hover effects */

.project-card:hover {
  transform: perspective(1000px) rotateX(0) rotateY(0) scale3d(1.05, 1.05, 1.05) !important;
}

/* ===== PARTICLES BACKGROUND STYLES ===== */

#particles-js {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  opacity: 0.6;
}

/* Ensure hero content is above particles */

.hero-section .container {
  position: relative;
  z-index: 10;
}

/* Particles canvas styling */

#particles-js canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

/* Dark mode particles adjustment */

.dark #particles-js {
  opacity: 0.8;
}

/* Mobile optimization for particles */

@media (max-width: 768px) {
  #particles-js {
    opacity: 0.3;
  }
  .dark #particles-js {
    opacity: 0.4;
  }
}
