:root {
  --primary: #2e5bff;
  --secondary: #6c63ff;
  --accent: #00f2fe;
  --text: #f0f0f0;
  --dark: #121212;
  --light-dark: #1e1e1e;
  --transition: all 0.3s ease;
}

*,
*::after,
*::before {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

/* body, html {
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
} */

body {
  color: var(--text);
  background: var(--dark);
  font-family: 'Poppins', Arial, sans-serif;
  line-height: 1.6;
  position: relative;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}

#particles-js {
  position: absolute; /* change to absolute if want to */
  width: 100%;
  height: 100vh;
  top: 0;
  left: 0;
  z-index: -1; 
}

#particles-js {
  background: radial-gradient(circle at center, #0f0c29, #302b63, #24243e);
  animation: fadeIn 2s ease-in-out;
}

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

.typed-text{
  color:#2e5bff;
  font-weight: bolder;
  font-size: larger;

}
/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  background: linear-gradient(to right, var(--primary), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 1.5rem;
}

h2 {
  font-size: clamp(2rem, 4vw, 2.5rem);
  text-align: center;
  margin-bottom: 2rem;
  background: linear-gradient(to right, var(--secondary), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

p {
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
}

/* Navigation */
nav {
  width: 100%;
  height: 70px;
  background: rgba(18, 18, 18, 0.8);
  backdrop-filter: blur(10px);
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

nav ul {
  display: flex;
  justify-content:space-evenly;
  align-items: center;
  height: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

nav li {
  list-style: none;
}

nav a {
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
  font-size: 1rem;
  transition: var(--transition);
  position: relative;
}

nav a:hover {
  color: var(--accent);
}

nav a::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: var(--transition);
}

nav a:hover::after {
  width: 100%;
}

/* Mobile Navigation */
.mobile-menu-btn {
  display: none;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 1.5rem;
  cursor: pointer;
}

@media (max-width: 768px) {

  nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    /* background: linear-gradient(to left, var(--primary), var(--accent)); */
    
  }

  .mobile-menu-btn {
    display: block;
    margin-right: 10px;
  }

  nav ul {
    position: fixed;
    top: 70px;
    right: -100%;
    width: 100%;
    height: calc(100vh - 70px);
    background: var(--light-dark);
    /* background: rgba(18, 18, 18, 0.9);
    backdrop-filter: blur(10px); */
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 2rem;
    transition: var(--transition);
  }

  nav ul.active {
    right: 0;
  }

  nav li {
    margin: 1.5rem 0;
  }

  nav li:first-child {
    margin-bottom: 2rem;
  }

}

/* Main Sections */
main {
  width: 100%;
  min-height: 100vh;
  padding-top: 70px;
}

section {
  padding: 5rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* Hero Section */
.hero-section {
  min-height: calc(100vh - 70px);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.main {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 800px;
  border: none;
}

.tech-stack {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  margin: 1.5rem 0;
}

.tech-stack span {
  background: rgba(46, 91, 255, 0.15);
  color: var(--accent);
  padding: 0.5rem 1rem;
  border-radius: 50px;
  font-size: 0.9rem;
}

.profile-image {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--primary);
  margin-top: 2rem;
  box-shadow: 0 0 20px rgba(108, 99, 255, 0.5);
  cursor: pointer;
}

/* About Section */
.about-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  border: none;
  max-width: 100%;
}

.expertise-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
  border: none;
  width: 100%;
}

.expertise-card {
  background: rgba(30, 30, 30, 0.6);
  border-radius: 10px;
  padding: 2rem;
  border: 1px solid rgba(108, 99, 255, 0.2);
  transition: var(--transition);
  height: 100%;
  width: 100%;
}

.expertise-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 242, 254, 0.1);
  border-color: var(--accent);
}

.expertise-card h3 {
  margin-bottom: 1rem;
  color: var(--accent);
}

.expertise-card ul {
  list-style: none;
}

.expertise-card li {
  margin-bottom: 0.5rem;
  position: relative;
  padding-left: 1.5rem;
}

.expertise-card li::before {
  content: "⟫";
  position: absolute;
  left: 0;
  color: var(--secondary);
}

/* Projects Section */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2em;
  width: 100%;
  border: none;
}

.project-card {
  background: rgba(30, 30, 30, 0.6);
  border-radius: 10px;
  overflow: hidden;
  transition: var(--transition);
  border: 1px solid rgba(108, 99, 255, 0.2);
  height: 100%;
  width: 100%;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 242, 254, 0.1);
  border-color: var(--accent);
}

.project-image {
  height: 200px;
  overflow: hidden;
  border: none;
  width: 100%;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

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

.project-card h3 {
  margin: 1.5rem 1.5rem 1rem;
  color: var(--text);
}

.project-card p {
  margin: 0 1.5rem 1.5rem;
  font-size: 0.95rem;
}

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 1.5rem 1.5rem;
  border: none;
  width: auto;
}

.tech-tags span {
  background: rgba(46, 91, 255, 0.15);
  color: var(--accent);
  padding: 0.3rem 0.8rem;
  border-radius: 50px;
  font-size: 0.8rem;
}

.project-links {
  display: flex;
  gap: 1rem;
  margin: 0 1.5rem 1.5rem;
  border: none;
  width: auto;
}

@media (max-width: 600px) {
  .project-grid {
    display: flex !important;
    flex-direction: row;
    overflow-x: auto;
    gap: 1.2rem;
    padding: 1rem;

    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
  }

  /* Hide scrollbar */
  .project-grid::-webkit-scrollbar {
    display:none;
  }

  .project-card {
    min-width: 85%;
    flex: 0 0 auto;
    scroll-snap-align: center;
    height: 600px;
  }
}

/* Experience Section */
.experience-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  width: 100%;
  border: none;
}

.exp-header{
  height: auto;
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
}

.experience-card {
  background: rgba(30, 30, 30, 0.6);
  border-radius: 10px;
  padding: 2rem;
  border: 1px solid rgba(108, 99, 255, 0.2);
  transition: var(--transition);
  width: 100%;
  cursor: pointer; 
}

.experience-card:hover{
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 242, 254, 0.1);
  border-color: var(--accent);
}

.experience-card-meta{
  color: var(--accent);
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.experience-type{
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  border: none;
  width: auto;
}

.experience-type span{
  background: rgba(46, 91, 255, 0.15);
  color: var(--accent);
  padding: 0.3rem 0.8rem;
  border-radius: 50px;
  font-size: 0.8rem;
}

.experience-card p{
  margin-top: 10px;
}

.experience-card h3{
  font-size: x-large;
}

.experience-cta {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

/* Smooth collapse/expand animation
.exp-details {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: all 0.4s ease-in-out;
}

/* When card is active */
/* .experience-card.active .exp-details {
  max-height: 800px; 
  opacity: 1;
} */

/*.exp-header::after{
  content: '+';
  margin-right: 10px;
  font-weight: 600;
  font-size: 24px;
  position: relative;
  left: 60%;
  right: auto;
} */

@media (max-width: 768px){
  .experience-card h3{
    font-size: 5vw;
    font-weight: 600;
  }

  .exp-details {
  max-height: 0;
  opacity: 0;
  overflow: visible;
  transition: all 0.4s ease;
}

.experience-card.active .exp-details {
  max-height: 800px;
  opacity: 1;
}

.experience-card.active {
  border-color: #6c63ff;
  box-shadow: 0 0 15px rgba(108, 99, 255, 0.4);
}

}

/* Contact Section */
.contact-form {
  background: rgba(30, 30, 30, 0.6);
  border-radius: 10px;
  padding: 2rem;
  border: 1px solid rgba(108, 99, 255, 0.2);
  max-width: 600px;
  margin: 0 auto;
  width: 100%;
}

.form-group {
  margin-bottom: 1.5rem;
  border: none;
  width: 100%;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 1rem;
  background: rgba(18, 18, 18, 0.8);
  border: 1px solid rgba(108, 99, 255, 0.2);
  border-radius: 5px;
  color: var(--text);
  font-family: inherit;
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 10px rgba(0, 242, 254, 0.2);
}

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

.btn {
  display: inline-block;
  padding: 0.8rem 1.5rem;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border: none;
  border-radius: 5px;
  color: white;
  text-decoration: none;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
}

.btn:hover {
  background: linear-gradient(135deg, var(--secondary), var(--primary));
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(108, 99, 255, 0.3);
}

/* Footer */
footer {
  background: var(--light-dark);
  padding: 3rem 2rem;
  text-align: center;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  border: none;
  width: 100%;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  border: none;
  width: 100%;
}

.social-links a {
  color: var(--text);
  font-size: 1.5rem;
  transition: var(--transition);
}

.social-links a:hover {
  color: var(--accent);
  transform: translateY(-3px);
}

footer p {
  font-size: 0.9rem;
  color: rgba(240, 240, 240, 0.7);
}

/* Responsive Design */
@media (max-width: 992px) {
  section {
    padding: 4rem 1.5rem;
  }
}

@media (max-width: 768px) {
  .expertise-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 576px) {
  section {
    padding: 3rem 1rem;
  }
  
  .tech-stack {
    display: flex;
    flex-wrap: wrap;
  } 
  
  .profile-image {
    width: 150px;
    height: 150px;
  }

  .about-content p{
    font-size: 0.95rem;
  }

  .experience-card .internship-summary{
    font-size: 0.95rem;
  }
}

/* Skills Section */
.skills-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  width: 100%;
}

.skills-category {
  background: rgba(30, 30, 30, 0.6);
  border-radius: 10px;
  padding: 2rem;
  border: 1px solid rgba(108, 99, 255, 0.2);
  transition: var(--transition);
}

.skills-category h3 {
  margin-bottom: 1.5rem;
  color: var(--accent);
  text-align: center;
}

.skill-item {
  margin-bottom: 1.5rem;
}

.skill-info {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.skill-bar {
  height: 10px;
  background: rgba(18, 18, 18, 0.6);
  border-radius: 5px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0; /* Will be set via JavaScript */
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 5px;
  transition: width 1.5s ease-in-out;
}

/* Button Styles */
.primary-btn {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.secondary-btn {
  background: transparent;
  border: 2px solid var(--secondary);
  color: var(--text);
}

.secondary-btn:hover {
  background: rgba(108, 99, 255, 0.1);
  transform: translateY(-2px);
}

.hero-cta {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

.section-cta {
  text-align: center;
  margin-top: 3rem;
}

/* Contact Section Updates */
.contact-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  width: 100%;
}

.contact-info {
  background: rgba(30, 30, 30, 0.6);
  border-radius: 10px;
  padding: 2rem;
  border: 1px solid rgba(108, 99, 255, 0.2);
}

.contact-info h3 {
  margin-bottom: 1rem;
  color: var(--accent);
}

.contact-details {
  margin-top: 2rem;
}

.contact-item {
  display: flex;
  align-items: center;
  margin-bottom: 1.5rem;
}

.contact-item i {
  margin-right: 1rem;
  color: var(--secondary);
  font-size: 1.5rem;
}

.contact-item a {
  color: var(--text);
  text-decoration: none;
  transition: var(--transition);
}

.contact-item a:hover {
  color: var(--accent);
}

/* Form Error State */
.form-group .error {
  border-color: #ff4d4d;
}

.form-message {
  padding: 1rem;
  margin-top: 1rem;
  border-radius: 5px;
  text-align: center;
}

.form-message.success {
  background: rgba(0, 200, 83, 0.1);
  color: #00c853;
  border: 1px solid rgba(0, 200, 83, 0.3);
}

.form-message.error {
  background: rgba(255, 77, 77, 0.1);
  color: #ff4d4d;
  border: 1px solid rgba(255, 77, 77, 0.3);
}

/* Additional Responsive Design Rules */
@media (max-width: 768px) {
  .contact-container {
    grid-template-columns: 1fr;
  }
  
  .hero-cta {
    flex-direction: column;
  }
  
  .theme-toggle {
    top: auto;
    bottom: 20px;
    right: 20px;
    background: rgba(30, 30, 30, 0.6);
  }
}

@media (max-width: 576px) {
  .skills-container {
    grid-template-columns: 1fr;
  }
}

/* Animation Keyframes */
@keyframes float {
  0% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
  100% {
    transform: translateY(0);
  }
}

.image img {
  animation: float 6s ease-in-out infinite;
}

/* Thoughts Section */
.thoughts{
  height: 70vh;
  transition-duration: 5s;
}

.thought-list {
  margin-top: 4rem;
  gap: 2rem;
  width: 100%;
  display: flex !important;
  flex-direction: row;
  overflow-x: auto;
  padding: 1rem;  
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.thought-card {
    border: 2px solid rgb(111, 35, 241);
    background-color: rgba(30, 30, 30, 0.6);
    border-radius: 10px;
    transition: var(--transition);
    width: 400px;
    flex: 0 0 auto;
    display: flex;
    text-align: center;
    align-items: center;
    justify-content: center;
    scroll-snap-align: center;
    height: 200px;
}

.thought-list::-webkit-scrollbar {
    display:none;
}


.thought-card p {
  font-family: monospace;
  text-align: center;
  text-wrap: wrap;
  font-size: 1rem;
  margin: 0;
  padding-inline: 20px;
}

.thought-card p > span{
  font-size: x-large;
  padding: 5px;
}

@keyframes slide {
    to {
        translate: calc(-10 * 250px);
    }
}

@media (max-width: 768px) {

  .thoughts {
    height: auto;
    position: relative;
  }

  .thought-list {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    border: none;
    overflow: visible;
  }

  .thought-card {
    animation: none;
    grid-auto-flow: row;
    grid-auto-columns: unset;
    grid-auto-rows: unset;
    height: 200px;
    width: 90%;
    margin: 0 auto;
    position: sticky;
    align-items: center;
    justify-content: center;
    top: 10%;
    z-index: 2;
    background-color: rgba(30, 30, 30, 0.85);
    box-shadow: 0 0 20px rgba(111, 35, 241, 0.4);
  }

  .thought-card p{
    text-align: center;
    align-items: center;
    margin: 0;
  }

  .thought-card p > span{
  font-size: x-large;
  padding: 5px;
  }

  .thought-card:nth-child(odd) {
    transform: rotate(-1deg);
  }
  .thought-card:nth-child(even) {
    transform: rotate(1deg);
  }
}
