
/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
}

/* Ensure proper viewport behavior on mobile */
@viewport {
  width: device-width;
  initial-scale: 1;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: #e8eaed;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 25%, #16213e 50%, #0f0f23 75%, #000000 100%);
  background-size: 400% 400%;
  background-attachment: fixed;
  overflow-x: hidden;
  position: relative;
  animation: morphBackground 20s ease-in-out infinite;
}

body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.03) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.03) 0%, transparent 50%),
    radial-gradient(circle at 40% 40%, rgba(120, 198, 255, 0.02) 0%, transparent 50%);
  pointer-events: none;
  z-index: -1;
  animation: particleFloat 15s ease-in-out infinite;
}

body::after {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.01'%3E%3Ccircle cx='30' cy='30' r='1'/%3E%3Ccircle cx='10' cy='10' r='0.5'/%3E%3Ccircle cx='50' cy='50' r='0.5'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") repeat;
  pointer-events: none;
  z-index: -1;
  animation: float 25s ease-in-out infinite reverse;
}

.container {
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 50px;
}

/* Enhanced Navigation Styles */
.navbar {
  background: rgba(15, 15, 35, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  padding: 1rem 0;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  min-height: 70px;
  display: flex;
  align-items: center;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.nav-logo {
  flex: 0 0 auto;
  order: 1;
}

.nav-menu {
  flex: 0 0 auto;
  order: 3;
}

.nav-toggle {
  flex: 0 0 auto;
  order: 2;
  margin-left: auto;
}

.nav-logo a {
  font-size: 1.8rem;
  font-weight: 700;
  text-decoration: none;
  background: linear-gradient(135deg, #64b5f6, #42a5f5, #90caf9);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  transition: all 0.3s ease;
  position: relative;
}

.nav-logo a::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #64b5f6, #42a5f5);
  transition: width 0.3s ease;
}

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

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2.5rem;
}

.nav-link {
  text-decoration: none;
  color: #e8eaed;
  font-weight: 500;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  padding: 0.5rem 0;
}

.nav-link::before {
  content: "";
  position: absolute;
  top: 0;
  left: -10px;
  right: -10px;
  bottom: 0;
  background: linear-gradient(135deg, rgba(100, 181, 246, 0.1), rgba(144, 202, 249, 0.15));
  border-radius: 8px;
  opacity: 0;
  transform: scaleX(0) scaleY(0.5);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 0 20px rgba(100, 181, 246, 0.2);
}

.nav-link:hover::before,
.nav-link.nav-active::before {
  opacity: 1;
  transform: scaleX(1) scaleY(1);
}

.nav-link:hover {
  color: #64b5f6;
  transform: translateY(-2px);
}

.nav-link::after {
  content: "";
  position: absolute;
  width: 0;
  height: 3px;
  bottom: -8px;
  left: 0;
  background: linear-gradient(90deg, #64b5f6, #42a5f5);
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 2px;
  box-shadow: 0 2px 8px rgba(100, 181, 246, 0.3);
}

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

.nav-link.nav-active {
  color: #64b5f6;
  font-weight: 600;
  text-shadow: 0 0 10px rgba(100, 181, 246, 0.3);
}

.nav-link.nav-active::before {
  opacity: 1;
  transform: scaleX(1);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  cursor: pointer;
}

.bar {
  width: 28px;
  height: 3px;
  background: linear-gradient(90deg, #64b5f6, #42a5f5);
  margin: 4px 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 2px;
}

/* Enhanced Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: radial-gradient(ellipse at center, rgba(100, 181, 246, 0.1) 0%, transparent 50%),
              linear-gradient(135deg, rgba(25, 25, 50, 0.8) 0%, rgba(15, 15, 35, 0.9) 100%);
  color: white;
  padding-top: 80px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.02'%3E%3Ccircle cx='30' cy='30' r='1'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") repeat;
  animation: float 20s ease-in-out infinite;
}

.hero-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-title {
  font-size: 4rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  background: linear-gradient(135deg, #ffffff, #e8eaed, #64b5f6);
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: fadeInUp 1s ease, glow 2s ease-in-out infinite alternate, gradientShift 4s ease-in-out infinite;
  text-shadow: 0 0 30px rgba(100, 181, 246, 0.3);
  position: relative;
  overflow: hidden;
}

.hero-title.typewriter {
  border-right: 3px solid #64b5f6;
  white-space: nowrap;
  overflow: hidden;
  animation: typewriter 2s steps(20) 1s forwards, blink 1s infinite;
}

.hero-subtitle {
  font-size: 2rem;
  font-weight: 400;
  margin-bottom: 1.5rem;
  color: #90caf9;
  animation: fadeInUp 1s ease 0.2s both;
  text-shadow: 0 0 20px rgba(144, 202, 249, 0.4);
}

.hero-description {
  font-size: 1.3rem;
  margin-bottom: 2.5rem;
  line-height: 1.8;
  color: #b3e5fc;
  animation: fadeInUp 1s ease 0.4s both;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-buttons {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  animation: fadeInUp 1s ease 0.6s both;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 15px 30px;
  text-decoration: none;
  border-radius: 12px;
  font-weight: 600;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: none;
  cursor: pointer;
  font-size: 1.1rem;
  position: relative;
  overflow: hidden;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn::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 0.6s;
}

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

.btn-primary {
  background: linear-gradient(135deg, #1e88e5, #1976d2, #0d47a1);
  color: white;
  box-shadow: 0 8px 25px rgba(30, 136, 229, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #1976d2, #1565c0, #0d47a1);
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 15px 35px rgba(30, 136, 229, 0.6);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border: 2px solid rgba(100, 181, 246, 0.6);
  backdrop-filter: blur(10px);
}

.btn-secondary:hover {
  background: rgba(100, 181, 246, 0.2);
  border-color: #64b5f6;
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 15px 35px rgba(100, 181, 246, 0.3);
}

.hero-image {
  display: flex;
  justify-content: center;
  align-items: center;
  animation: fadeInRight 1s ease 0.8s both;
}

.hero-avatar {
  width: 350px;
  height: 350px;
  border-radius: 50%;
  overflow: hidden;
  position: relative;
  animation: float 6s ease-in-out infinite, pulse 2s ease-in-out infinite alternate;
  border: 4px solid rgba(100, 181, 246, 0.3);
  box-shadow: 
    0 0 50px rgba(100, 181, 246, 0.4),
    inset 0 0 50px rgba(100, 181, 246, 0.1);
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-avatar::before {
  content: "";
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, #64b5f6, #42a5f5, #90caf9, #64b5f6);
  z-index: -1;
  animation: rotate 3s linear infinite;
}

.hero-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.hero-avatar:hover {
  transform: scale(1.05);
  box-shadow: 
    0 0 80px rgba(100, 181, 246, 0.6),
    inset 0 0 80px rgba(100, 181, 246, 0.2);
}

.hero-avatar:hover img {
  transform: scale(1.1);
}

/* Enhanced Section Styles */
section {
  padding: 120px 0;
  position: relative;
}

.section-header {
  text-align: center;
  margin-bottom: 5rem;
  position: relative;
}

.section-title {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  background: linear-gradient(135deg, #64b5f6, #42a5f5, #90caf9);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  position: relative;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -20px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, #64b5f6, #42a5f5);
  border-radius: 2px;
}

.section-subtitle {
  font-size: 1.3rem;
  color: #b3e5fc;
  max-width: 700px;
  margin: 0 auto;
  line-height: 1.6;
}

/* Enhanced Skills Section */
.skills {
  background: rgba(15, 15, 35, 0.6);
  backdrop-filter: blur(10px);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2.5rem;
  max-width: 1400px;
  margin: 0 auto;
}

.skill-category {
  background: rgba(30, 30, 60, 0.5);
  border-radius: 20px;
  padding: 2.5rem;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(100, 181, 246, 0.2);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
  animation: float 6s ease-in-out infinite;
}

.skill-category:nth-child(2) {
  animation-delay: -1.5s;
}

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

.skill-category:nth-child(4) {
  animation-delay: -4.5s;
}

.skill-category::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #64b5f6, #42a5f5, #90caf9);
  transform: scaleX(0);
  transition: transform 0.4s ease;
}

.skill-category:hover::before {
  transform: scaleX(1);
}

.skill-category:hover {
  transform: translateY(-15px) scale(1.02);
  box-shadow: 0 25px 50px rgba(100, 181, 246, 0.2);
  border-color: rgba(100, 181, 246, 0.4);
}

.skill-category h3 {
  font-size: 1.4rem;
  margin-bottom: 2rem;
  background: linear-gradient(135deg, #64b5f6, #90caf9);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
}

.skill-category ul {
  list-style: none;
}

.skill-category li {
  padding: 0.8rem 0;
  color: #b3e5fc;
  font-size: 1rem;
  font-weight: 500;
  transition: all 0.3s ease;
  border-bottom: 1px solid rgba(100, 181, 246, 0.1);
  position: relative;
  padding-left: 20px;
}

.skill-category li:last-child {
  border-bottom: none;
}

.skill-category li::before {
  content: "▶";
  position: absolute;
  left: 0;
  color: #64b5f6;
  font-size: 0.8rem;
  transition: all 0.3s ease;
}

.skill-category li:hover {
  color: #90caf9;
  padding-left: 30px;
}

.skill-category li:hover::before {
  color: #90caf9;
  transform: translateX(5px);
}

/* Enhanced Projects Section */
.projects {
  background: rgba(25, 25, 50, 0.3);
  backdrop-filter: blur(10px);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2.5rem;
}

.project-card {
  background: rgba(30, 30, 60, 0.6);
  border: 1px solid rgba(100, 181, 246, 0.2);
  border-radius: 20px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
  overflow: hidden;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(15px);
  position: relative;
}

.project-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #64b5f6, #42a5f5, #90caf9);
  transform: scaleX(0);
  transition: transform 0.5s ease;
}

.project-card:hover::before {
  transform: scaleX(1);
}

.project-card:hover {
  transform: translateY(-15px) scale(1.02) rotateX(5deg);
  box-shadow: 
    0 25px 60px rgba(0, 0, 0, 0.3),
    0 0 40px rgba(100, 181, 246, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  border-color: rgba(100, 181, 246, 0.4);
  perspective: 1000px;
}

.project-content {
  padding: 2rem;
}

.project-content h3 {
  font-size: 1.4rem;
  margin-bottom: 1.2rem;
  background: linear-gradient(135deg, #64b5f6, #90caf9);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
}

.project-content p {
  color: #b3e5fc;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  font-size: 1rem;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}

.project-tech span {
  background: rgba(100, 181, 246, 0.2);
  color: #90caf9;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  border: 1px solid rgba(100, 181, 246, 0.3);
  transition: all 0.3s ease;
}

.project-tech span:hover {
  background: rgba(100, 181, 246, 0.3);
  transform: translateY(-2px);
}

.project-link {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  color: #64b5f6;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  padding: 0.5rem 0;
}

.project-link:hover {
  color: #90caf9;
  transform: translateX(5px);
}

/* Enhanced Contact Section */
.contact {
  background: rgba(15, 15, 35, 0.8);
  backdrop-filter: blur(15px);
}

.contact-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: start;
}

.contact-info h3 {
  font-size: 2.2rem;
  margin-bottom: 1.5rem;
  background: linear-gradient(135deg, #64b5f6, #90caf9);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
}

.contact-info p {
  color: #b3e5fc;
  line-height: 1.8;
  margin-bottom: 2.5rem;
  font-size: 1.1rem;
}

.social-links {
  display: flex;
  gap: 1.5rem;
}

.social-link {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, rgba(100, 181, 246, 0.2), rgba(66, 165, 245, 0.2));
  color: #64b5f6;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  font-size: 1.5rem;
  border: 1px solid rgba(100, 181, 246, 0.3);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.social-link::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: linear-gradient(135deg, #64b5f6, #42a5f5);
  border-radius: 50%;
  transition: all 0.4s ease;
  transform: translate(-50%, -50%);
}

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

.social-link:hover {
  transform: translateY(-5px) scale(1.1);
  box-shadow: 0 15px 30px rgba(100, 181, 246, 0.4);
  color: white;
}

.social-link i {
  position: relative;
  z-index: 1;
}

/* Enhanced Contact Form */
.contact-form {
  background: rgba(30, 30, 60, 0.6);
  border: 1px solid rgba(100, 181, 246, 0.2);
  padding: 3rem;
  border-radius: 20px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(15px);
}

.form-group {
  margin-bottom: 2rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.8rem;
  font-weight: 600;
  color: #90caf9;
  font-size: 1.1rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 15px 20px;
  background: rgba(15, 15, 35, 0.8);
  border: 2px solid rgba(100, 181, 246, 0.3);
  color: #e8eaed;
  border-radius: 12px;
  font-size: 1rem;
  transition: all 0.3s ease;
  font-family: inherit;
  backdrop-filter: blur(10px);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #64b5f6;
  box-shadow: 0 0 20px rgba(100, 181, 246, 0.3);
  transform: translateY(-2px);
}

.form-group textarea {
  resize: vertical;
  min-height: 140px;
}

.form-success-message {
  margin: 20px 0 0;
  padding: 1.2rem 1.5rem;
  background: linear-gradient(135deg, #4caf50, #45a049);
  color: white;
  border-radius: 12px;
  font-size: 1rem;
  line-height: 1.5;
  text-align: center;
  animation: fadeIn 0.5s ease-in-out, slideUp 0.5s ease-in-out;
  box-shadow: 0 8px 25px rgba(76, 175, 80, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Enhanced Footer */
.footer {
  background: rgba(10, 10, 20, 0.9);
  border-top: 1px solid rgba(100, 181, 246, 0.2);
  color: white;
  padding: 3rem 2rem;
  backdrop-filter: blur(15px);
  width: 100%;
  box-sizing: border-box;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.footer-left {
  flex: 1;
  min-width: 200px;
}

.footer-left p {
  margin: 0;
  font-size: 1rem;
  color: #b3e5fc;
  font-weight: 500;
}

.footer-right {
  flex: 1;
  display: flex;
  justify-content: flex-end;
  min-width: 200px;
}

.footer-links {
  display: flex;
  gap: 2.5rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.footer-links a {
  color: #b3e5fc;
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: 500;
  font-size: 1rem;
  padding: 0.5rem 0;
  white-space: nowrap;
}

.footer-links a:hover {
  color: #64b5f6;
  transform: translateY(-2px);
}

/* Enhanced Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(60px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes slideInFromRight {
  from {
    opacity: 0;
    transform: translateX(100px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

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

@keyframes blink {
  0%, 50% {
    border-color: transparent;
  }
  51%, 100% {
    border-color: #64b5f6;
  }
}

@keyframes morphBackground {
  0%, 100% {
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 25%, #16213e 50%, #0f0f23 75%, #000000 100%);
  }
  25% {
    background: linear-gradient(135deg, #0f0f23 0%, #16213e 25%, #1a1a2e 50%, #0a0a0a 75%, #000000 100%);
  }
  50% {
    background: linear-gradient(135deg, #16213e 0%, #0f0f23 25%, #000000 50%, #1a1a2e 75%, #0a0a0a 100%);
  }
  75% {
    background: linear-gradient(135deg, #1a1a2e 0%, #000000 25%, #0a0a0a 50%, #16213e 75%, #0f0f23 100%);
  }
}

@keyframes gradientShift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

@keyframes particleFloat {
  0%, 100% {
    transform: translateY(0px) translateX(0px);
  }
  25% {
    transform: translateY(-20px) translateX(10px);
  }
  50% {
    transform: translateY(-10px) translateX(-10px);
  }
  75% {
    transform: translateY(-30px) translateX(5px);
  }
}

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

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

@keyframes slideUp {
  from {
    transform: translateY(20px);
  }
  to {
    transform: translateY(0);
  }
}

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

@keyframes pulse {
  0% {
    opacity: 0.8;
  }
  100% {
    opacity: 1;
  }
}

@keyframes glow {
  0% {
    text-shadow: 0 0 30px rgba(100, 181, 246, 0.3);
  }
  100% {
    text-shadow: 0 0 50px rgba(100, 181, 246, 0.6);
  }
}

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

/* Responsive Design */
@media screen and (max-width: 1024px) {
  .container {
    padding: 0 30px;
  }

  .hero-container {
    gap: 2rem;
  }

  .nav-container {
    padding: 0 30px;
  }

  .hero-title {
    font-size: 3rem;
  }

  .section-title {
    font-size: 2.8rem;
  }
}

@media screen and (max-width: 768px) {
  .container {
    padding: 0 20px;
  }

  .nav-container {
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
  }

  .nav-logo {
    order: 1;
    flex: 0 0 auto;
  }

  .nav-toggle {
    order: 2;
    display: flex;
    cursor: pointer;
    margin-left: auto;
  }

  .nav-menu {
    position: fixed;
    left: -100%;
    top: 70px;
    flex-direction: column;
    background: rgba(15, 15, 35, 0.98);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(100, 181, 246, 0.2);
    width: 100vw;
    height: calc(100vh - 70px);
    text-align: center;
    transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    padding: 3rem 0;
    z-index: 999;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    order: 3;
  }

  .nav-menu.active {
    left: 0;
  }

  .nav-toggle.active .bar:nth-child(2) {
    opacity: 0;
  }

  .nav-toggle.active .bar:nth-child(1) {
    transform: translateY(10px) rotate(45deg);
  }

  .nav-toggle.active .bar:nth-child(3) {
    transform: translateY(-10px) rotate(-45deg);
  }

  .hero-container {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3rem;
    padding: 0 20px;
  }


/* Custom Magnetic Cursor */
.magnetic-cursor {
  position: fixed;
  width: 30px;
  height: 30px;
  border: 2px solid rgba(100, 181, 246, 0.5);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transition: all 0.1s ease;
  transform: translate(-50%, -50%);
  backdrop-filter: blur(5px);
}

.magnetic-cursor.cursor-grow {
  width: 60px;
  height: 60px;
  border-color: rgba(100, 181, 246, 0.8);
  background: rgba(100, 181, 246, 0.1);
}

.cursor-dot {
  position: fixed;
  width: 6px;
  height: 6px;
  background: #64b5f6;
  border-radius: 50%;
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  transition: opacity 0.2s ease;
}

.cursor-dot-hidden {
  opacity: 0;
}

/* Hide default cursor on desktop */
@media (min-width: 769px) {
  * {
    cursor: none !important;
  }
  
  a, button, .btn, .project-card, .skill-category, .social-link {
    cursor: none !important;
  }
}

/* Loading animation for better UX */
.page-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #0a0a0a 100%);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10000;
  opacity: 1;
  transition: opacity 0.5s ease;
}

.page-loader.fade-out {
  opacity: 0;
  pointer-events: none;
}

.loader-text {
  font-size: 2rem;
  color: #64b5f6;
  animation: glow 2s ease-in-out infinite alternate;
}

/* Enhanced button hover effects */
.btn {
  position: relative;
  overflow: hidden;
  transform-style: preserve-3d;
}

.btn::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.6s ease;
}

.btn:hover::after {
  left: 100%;
}

/* Enhanced social links with pulse effect */
.social-link:hover {
  animation: pulse 0.6s ease-in-out;
}

/* Glitch effect for hero title (optional) */
.hero-title.glitch {
  position: relative;
}

.hero-title.glitch::before,
.hero-title.glitch::after {
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: inherit;
  -webkit-background-clip: text;
  background-clip: text;
}

.hero-title.glitch::before {
  animation: glitch 2s infinite;
  color: #ff0000;
  z-index: -1;
}

.hero-title.glitch::after {
  animation: glitch 1.5s infinite;
  color: #00ffff;
  z-index: -2;
}

@keyframes glitch {
  0%, 100% {
    transform: translate(0);
  }
  20% {
    transform: translate(-2px, 2px);
  }
  40% {
    transform: translate(-2px, -2px);
  }
  60% {
    transform: translate(2px, 2px);
  }
  80% {
    transform: translate(2px, -2px);
  }
}

/* Modern card hover effects */
.project-card,
.skill-category,

/* Enhanced form focus effects */
.form-group input:focus,
.form-group textarea:focus {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 
    0 0 20px rgba(100, 181, 246, 0.3),
    0 10px 20px rgba(0, 0, 0, 0.2);
}

/* Floating labels effect */
.form-group {
  position: relative;
}

.form-group label {
  transition: all 0.3s ease;
  transform-origin: left top;
}

.form-group input:focus + label,
.form-group textarea:focus + label,
.form-group input:not(:placeholder-shown) + label,
.form-group textarea:not(:placeholder-shown) + label {
  transform: translateY(-25px) scale(0.8);
  color: #64b5f6;
}

/* Enhanced mobile responsiveness */
@media (max-width: 768px) {
  .magnetic-cursor,
  .cursor-dot {
    display: none;
  }
  
  * {
    cursor: auto !important;
  }
}


  .hero-title {
    font-size: 2.5rem;
  }

  .hero-subtitle {
    font-size: 1.5rem;
  }

  .hero-avatar {
    width: 280px;
    height: 280px;
  }

  .skills-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }

  .projects-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .contact-content {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .footer {
    padding: 2.5rem 1rem;
  }

  .footer-content {
    flex-direction: column !important;
    text-align: center !important;
    align-items: center !important;
    gap: 0 !important;
  }

  .footer-left {
    min-width: auto !important;
    width: 100% !important;
    text-align: center !important;
    margin-bottom: 0 !important;
  }

  .footer-right {
    display: none !important;
  }

  .footer-links {
    display: none !important;
  }

  .section-title {
    font-size: 2.2rem;
  }

  section {
    padding: 80px 0;
  }
}

@media screen and (max-width: 480px) {
  .container {
    padding: 0 15px;
  }

  .nav-container {
    padding: 0 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
  }

  .nav-logo {
    order: 1;
  }

  .nav-toggle {
    order: 2;
    margin-left: auto;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1.2rem;
  }

  .hero-avatar {
    width: 220px;
    height: 220px;
  }

  .skills-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .btn {
    padding: 12px 20px;
    font-size: 0.9rem;
  }

  .contact-form {
    padding: 2rem;
  }

  .footer {
    padding: 2rem 1rem;
  }

  .footer-content {
    flex-direction: column !important;
    text-align: center !important;
    align-items: center !important;
    gap: 0 !important;
  }

  .footer-left {
    width: 100% !important;
    text-align: center !important;
    margin-bottom: 0 !important;
  }

  .footer-right {
    display: none !important;
  }

  .footer-links {
    display: none !important;
  }

  .footer-left p {
    font-size: 0.9rem;
    line-height: 1.5;
  }
}

@media screen and (max-width: 360px) {
  .nav-container {
    padding: 0 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
  }

  .nav-logo {
    order: 1;
  }

  .nav-toggle {
    order: 2;
    margin-left: auto;
  }

  .hero-title {
    font-size: 1.8rem;
  }

  .hero-avatar {
    width: 200px;
    height: 200px;
  }

  .section-title {
    font-size: 1.6rem;
  }

  .footer {
    padding: 1.5rem 0.75rem;
  }

  .footer-content {
    flex-direction: column !important;
    text-align: center !important;
    align-items: center !important;
    gap: 0 !important;
  }

  .footer-left {
    width: 100% !important;
    text-align: center !important;
    margin-bottom: 0 !important;
  }

  .footer-right {
    display: none !important;
  }

  .footer-links {
    display: none !important;
  }

  .footer-left p {
    font-size: 0.85rem;
  }
}

/* Scroll Reveal Animations */
.reveal {
  opacity: 0;
  transition: all 0.8s ease;
}

.reveal.active {
  opacity: 1;
}

.reveal-fade-up {
  opacity: 0;
  transform: translateY(60px);
  transition: all 0.8s ease;
}

.reveal-fade-up.active {
  opacity: 1;
  transform: translateY(0);
  animation: scaleIn 0.6s ease-out;
}

.reveal-fade-left {
  opacity: 0;
  transform: translateX(-60px);
  transition: all 0.8s ease;
}

.reveal-fade-left.active {
  opacity: 1;
  transform: translateX(0);
}

.reveal-fade-right {
  opacity: 0;
  transform: translateX(60px);
  transition: all 0.8s ease;
}

.reveal-fade-right.active {
  opacity: 1;
  transform: translateX(0);
}

.reveal-scale {
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.8s ease;
}

.reveal-scale.active {
  opacity: 1;
  transform: scale(1);
}

.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-fade-up,
.reveal-fade-left,
.reveal-fade-right,
.reveal-scale {
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.section-header,
.contact-info,
.contact-form {
  opacity: 0;
}

.hero .hero-title,
.hero .hero-subtitle,
.hero .hero-description,
.hero .hero-buttons,
.hero .hero-image {
  opacity: 1;
}

.project-card-hidden {
  opacity: 0;
  transform: translateY(30px) scale(0.95);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-card.reveal-sequential {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Enhanced Navbar Shrinking */
.navbar-shrunk {
  padding: 0.5rem 0 !important;
  background: rgba(10, 10, 25, 0.98) !important;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.6) !important;
}

.navbar-shrunk .nav-logo a {
  font-size: 1.5rem;
}

/* Enhanced Back to Top Button */
.scroll-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 60px;
  height: 60px;
  border: none;
  border-radius: 50%;
  background: linear-gradient(135deg, #64b5f6, #42a5f5);
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1000;
  box-shadow: 0 8px 25px rgba(100, 181, 246, 0.4);
  border: 2px solid rgba(255, 255, 255, 0.1);
}

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

.scroll-to-top:hover {
  background: linear-gradient(135deg, #42a5f5, #1e88e5);
  transform: translateY(-5px) scale(1.1);
  box-shadow: 0 15px 35px rgba(100, 181, 246, 0.6);
}
