:root {
  --font-main: "Outfit", sans-serif;
  --font-display: "Syncopate", sans-serif;
  --bg-color: #050505;
  --text-main: #ffffff;
  --accent: #00f0ff;
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-color);
  color: var(--text-main);
  font-family: var(--font-main);
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

.nav-link {
  font-family: var(--font-display);
  font-size: 0.9rem;
  letter-spacing: 0.1rem;
  transition: color 0.3s;
}

.nav-link:hover {
  color: var(--accent);
}

.glitch {
  position: relative;
  color: white;
}

.glitch::before,
.glitch::after {
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--bg-color);
}

.glass-card {
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
  padding: 2rem;
  opacity: 0; /* Hidden initially for GSAP */
  transform: translateY(30px);
}

/* --- Sections --- */
section {
  position: relative;
  width: 100%;
  box-sizing: border-box;
}

/* Skills Section - Canvas Overlay handled by Three.js, UI simple */
#skills .glass-card {
  max-width: 400px;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid #00f0ff;
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
}

/* Projects Section - Dimension Portals */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 3rem;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.project-card {
  position: relative;
  height: 400px;
  border-radius: 20px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1);
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.project-card:hover {
  transform: translateY(-10px) scale(1.02);
  border-color: var(--accent);
  box-shadow: 0 0 30px rgba(0, 240, 255, 0.3);
}

.project-image-container {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.project-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s;
  opacity: 0.7;
}

.project-card:hover .project-image {
  transform: scale(1.1);
  opacity: 1;
}

.project-info {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 2rem;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
  transform: translateY(20px);
  opacity: 0;
  transition: all 0.4s ease;
}

.project-card:hover .project-info {
  transform: translateY(0);
  opacity: 1;
}

.project-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  margin: 0 0 0.5rem 0;
  color: var(--accent);
}

.project-tech {
  font-size: 0.9rem;
  color: #ccc;
}

/* Skill Tags */
.skill-tag {
  background: rgba(255, 255, 255, 0.05);
  padding: 8px 16px;
  border-radius: 50px;
  font-size: 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s;
  cursor: default;
}

.skill-tag:hover {
  background: var(--accent);
  color: #000;
  box-shadow: 0 0 15px var(--accent);
}

/* Profile Glow Animation */
.profile-glow {
  animation: pulse-glow 3s infinite alternate;
}

@keyframes pulse-glow {
  0% {
    box-shadow: 0 0 30px rgba(0, 240, 255, 0.2);
  }
  100% {
    box-shadow: 0 0 60px rgba(0, 240, 255, 0.6),
      0 0 100px rgba(0, 240, 255, 0.2);
  }
}

/* UI Components */
.glass-btn {
  padding: 10px 30px;
  border-radius: 50px;
  text-decoration: none;
  background: transparent;
  color: #fff;
  border: 1px solid var(--accent);
  font-weight: bold;
  transition: all 0.3s;
  box-shadow: none;
}

.glass-btn:hover {
  background: var(--accent);
  color: #000;
  box-shadow: 0 0 20px var(--accent);
}

.glass-btn.btn-filled {
  background: var(--accent);
  color: #000;
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.3);
}

.glass-btn.btn-filled:hover {
  background: #fff;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
}

.icon-btn {
  width: 45px;
  height: 45px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.05);
  transition: all 0.3s;
}

.icon-btn:hover {
  background: var(--accent);
  color: #000;
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 240, 255, 0.3);
}

.social-icon {
  font-size: 2rem; /* Increased from 1.5rem */
  color: #aaa;
  transition: all 0.3s;
}

.social-icon:hover {
  color: var(--accent);
  transform: translateY(-3px);
  text-shadow: 0 0 10px var(--accent);
}

/* Contact Form */
.contact-form-container {
  width: 100%;
  max-width: 500px;
  padding: 3rem;
  background: rgba(10, 10, 20, 0.6); /* Slightly Darker */
}

.form-input {
  width: 100%;
  padding: 15px;
  margin-bottom: 1rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #fff;
  font-family: "Outfit", sans-serif;
  font-size: 1rem;
  box-sizing: border-box; /* Fix padding issue */
  transition: border-color 0.3s;
}

.form-input:focus {
  outline: none;
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.1);
}

.submit-btn {
  padding: 15px;
  width: 100%;
  background: linear-gradient(90deg, #00f0ff, #00afff);
  border: none;
  border-radius: 8px;
  color: #000;
  font-weight: bold;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.3s;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 20px rgba(0, 240, 255, 0.4);
}

/* Tooltip */
#project-tooltip {
  backdrop-filter: blur(15px);
  background: rgba(10, 10, 25, 0.9);
  border: 1px solid rgba(0, 240, 255, 0.3);
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.8);
  border-radius: 12px;
  opacity: 0;
  transition: opacity 0.3s;
}

/* --- Responsive Design --- */

/* Tablet & Smaller Laptops */
@media (max-width: 1024px) {
  section {
    padding: 80px 5% !important;
  }

  .hero-title {
    font-size: 5vw !important;
  }
}

/* Mobile Devices */
@media (max-width: 768px) {
  /* Navigation */
  .desktop-nav {
    display: none !important;
  }

  #hamburger-btn {
    display: block !important;
  }

  /* Mobile Menu Styles */
  #mobile-menu.active {
    right: 0 !important;
  }

  /* Hamburger Animation */
  #hamburger-btn.active .bar:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
  }
  #hamburger-btn.active .bar:nth-child(2) {
    opacity: 0;
  }
  #hamburger-btn.active .bar:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
  }

  /* Hero Section */
  #hero {
    flex-direction: column-reverse;
    justify-content: center;
    padding-top: 100px !important;
    text-align: center;
  }

  .hero-content {
    text-align: center !important;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-title {
    font-size: 3rem !important; /* Fixed size for readability */
  }

  /* Hero Action Bar */
  .hero-content > div:last-child {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    width: 100%;
  }

  .glass-btn {
    width: 80%; /* Wider buttons on mobile */
    justify-content: center;
  }

  /* Center the social icons container */
  .hero-content > div:last-child > div {
    width: 100%;
    align-items: center;
  }

  /* Image */
  .profile-glow {
    width: 250px !important;
    height: 250px !important;
    margin-bottom: 2rem;
  }

  /* About & Skills */
  #about,
  #skills {
    padding: 60px 5% !important;
  }

  h2 {
    font-size: 2.5rem !important;
  }

  .skills-grid {
    grid-template-columns: 1fr !important; /* Stack columns */
  }

  /* Projects */
  /* Hide the 3D text/interaction hint on mobile if it's too complex, 
     but for now we keep it. Maybe adjust position. */
  #projects > div {
    left: 5% !important;
    top: 80px !important;
    width: 90%;
    text-align: center;
  }

  /* Contact */
  .contact-form-container {
    padding: 2rem !important;
    width: 90%;
  }
}
