:root {
  --bg: #f0f0f0;
  --text: #222;
  --accent: #007bff;
  --card: #ffffff;
}

body.dark {
  --bg: #121212;
  --text: #eaeaea;
  --accent: #1e90ff;
  --card: #1e1e1e;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  scroll-behavior: smooth;
   -webkit-tap-highlight-color: transparent; /* ✅ removes mobile tap highlight */
  -webkit-touch-callout: none;              /* ✅ disables long press context menu on iOS */
  outline: none;                            /* ✅ removes focus outlines on tap */
  user-select: none; 
  
  -webkit-tap-highlight-color: transparent;


}
body {
  font-family: 'Montserrat', sans-serif;
  background: var(--bg);
  color: var(--text);
  transition: all 0.3s ease;
}
nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--card);
  padding: 15px 40px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 999;
}

.top-nav {
  display: flex;
  align-items: center;
  padding: 1rem 4rem;
}

.logo {
  flex: 1;
  font-size: 1.8rem;
  font-weight: bold;
}

.nav-links {
  display: flex;
  gap: 2rem;
  margin-right: 1.5rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
}


.menu-toggle {
  font-size: 28px;
  cursor: pointer;
  color: var(--text);
  z-index: 1001;
  transition: transform 0.3s ease;
}

.menu-toggle:hover {
  transform: scale(1.1);
}

.popup-menu {
  position: absolute;
  top: 60px;
  right: 20px;
  background: var(--card);
  padding: 18px 22px;
  border-radius: 12px;
  display: none;
  flex-direction: column;
  gap: 10px;
  z-index: 1001;
  width: 170px;  /* ⬅️ changed from 140px */
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  transform: scale(0.95);
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
}


.popup-menu.show {
  display: flex;
  transform: translate(0, 0) scale(1); /* 👈 animate into position */
  opacity: 1;
}




.popup-menu {
  transition: transform 0.4s ease, opacity 0.4s ease;
}


.popup-menu.show {
  display: flex;
  transform: scale(1) rotate(0deg);
  opacity: 1;
}




.popup-menu a {
  color: var(--text);
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 600;
  padding: 10px 20px;
  background: rgba(255, 255, 255, 0.07);
  border-radius: 10px;
  transition: all 0.3s ease;
  transform: skewX(-19deg); /* ✅ Slant the item */
  display: inline-block;
}

.popup-menu a {
  font-size: 1rem;
  padding: 8px 14px;
  border-radius: 8px;
}

.popup-menu a,
.menu-toggle,
button {
  -webkit-tap-highlight-color: transparent;
}


.popup-menu a:hover {
  background: var(--accent);
  color: white;
  transform: skewX(-12deg) scale(1.05);
}

.popup-menu a span {
  display: inline-block;
  transform: skewX(10deg); /* 🔁 counter skew for text readability */
}

.popup-menu a.active,
.nav-links a.active {
  background-color: var(--accent);
  color: white;
  border-radius: 8px;
  padding: 6px 12px;
}

/* .popup-menu.show {
  display: flex;
} */

.menu-toggle {
  transition: transform 0.3s;
}
.menu-toggle:hover {
  transform: rotate(10deg) scale(1.1);
}



nav .logo {
  font-weight: bold;
  font-size: 1.6rem;
}
nav ul {
  display: flex;
  list-style: none;
  gap: 20px;
}
nav ul a {
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
}
nav button {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
}
section {
  padding: 80px 40px;
}
.hero {
  margin-left: 5%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
.hero-text {
  flex: 1;
  max-width: 500px;
}
.hero-text h1 {
  font-size: 2.8rem;
  margin-bottom: 10px;
}
.hero-text p {
  font-size: 1.2rem;
  margin-bottom: 25px;
}
.hero-text a {
  background: var(--accent);
  color: white;
  padding: 10px 20px;
  text-decoration: none;
  border-radius: 8px;
  margin-right: 10px;
}
.hero-img {
  flex: 1;
  display: flex;
  justify-content: center;
  /*margin-left: 30%;*/
  /*justify-content: right;*/
}
.hero-img img {
  width: 350px;
  border-radius: 50%;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}
.section-title {
  font-size: 2rem;
  margin-bottom: 30px;
  text-align: center;
}
.about p {
  text-align: center;
  max-width: 800px;
  margin: auto;
  font-size: 1.1rem;
  line-height: 1.8;
}
.dev-links {
  text-align: center;
  margin: 20px 0;
}
.dev-links a {
  margin-right: 15px;
  color: var(--accent);
  font-weight: bold;
}
.contributions {
  text-align: center;
  margin-top: 40px;
}

.contributions h3 {
  margin-bottom: 10px;
  font-size: 1.2rem;
  color: var(--accent);
}

.contributions img {
  width: 100%;
  max-width: 600px;
  margin: 15px auto;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.projects {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
  margin-top: 30px;
  padding: 0 20px;
}





.project-card {
  background: var(--card);
  padding: 25px;
  border-radius: 10px;
  width: 100%;
  max-width: 300px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  transition: transform 0.2s ease;
  display: flex;
  flex-direction: column;
}



.project-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 15px;
}

.project-card h3 {
  margin: 10px 0 5px;
  font-size: 1.2rem;
}

.project-card p {
  margin-bottom: 8px;
  font-size: 0.95rem;
  line-height: 1.5;
}

.project-card a {
  margin-top: auto;
  text-decoration: none;
  font-weight: bold;
  color: var(--accent);
}

.contact {
  text-align: center;
  font-size: 1.1rem;
}


.contact-form {
  max-width: 650px;
  margin: 0 auto;
  padding: 40px;
  backdrop-filter: blur(12px);
  background: rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.2);
  border: 1px solid rgba(255,255,255,0.1);
  display: flex;
  flex-direction: column;
  gap: 25px;
  position: relative;
}

.form-group {
  position: relative;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 16px 14px;
  border: 2px solid transparent;
  border-radius: 12px;
  background-color: rgba(255, 255, 255, 0.07);
  color: var(--text);
  font-size: 1rem;
  outline: none;
  transition: 0.3s;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.form-group input:focus,
.form-group textarea:focus {
  border: 2px solid var(--accent);
  background-color: rgba(255, 255, 255, 0.1);
}

.form-group label {
  position: absolute;
  top: 14px;
  left: 14px;
  font-size: 0.95rem;
  color: var(--text);
  pointer-events: none;
  transition: all 0.3s ease;
}

.form-group input:focus + label,
.form-group input:not(:placeholder-shown) + label,
.form-group textarea:focus + label,
.form-group textarea:not(:placeholder-shown) + label {
  transform: translateY(-26px);
  font-size: 0.8rem;
  color: var(--accent);
  background-color: transparent;
  padding: 0 6px;
}

.contact-form button {
  padding: 14px 20px;
  background-color: var(--accent);
  color: white;
  border: none;
  font-weight: bold;
  border-radius: 10px;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  position: relative;
  overflow: hidden;
}

.contact-form button::after {
  content: "✓ Sent!";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: var(--accent);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.4s;
  font-weight: bold;
}

.contact-form button.submitted::after {
  opacity: 1;
  transform: scale(1);
}

.contact-form button:hover {
  background-color: #0056c7;
  transform: scale(1.02);
}



footer {
  text-align: center;
  padding: 20px;
  background: var(--card);
}

/* Reveal Animation */
.reveal {
  opacity: 0;
  transform: translateY(50px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
  .hero {
    flex-direction: column;
    text-align: center;
  }
  .hero-img {
    margin-top: 20px;
  }
}

/* Floating Dark Mode Toggle Button */
#toggleTheme {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(12px);
  border: 1px solid var(--accent);
  border-radius: 50%;
  width: 48px;
  height: 48px;
  font-size: 20px;
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  cursor: pointer;
  box-shadow: 0 6px 12px rgba(0,0,0,0.15);
  transition: all 0.3s ease;
}

#toggleTheme:hover {
  background: var(--accent);
  color: white;
}



#toggleTheme::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 60px;
  right: 0;
  background: var(--card);
  color: var(--text);
  font-size: 12px;
  padding: 5px 10px;
  border-radius: 6px;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s ease;
  pointer-events: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

#toggleTheme:hover::after {
  opacity: 1;
  transform: translateY(0);
}

.projects {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
  margin-top: 30px;
  padding: 0 20px;
}


.project-card {
  background: var(--card);
  padding: 25px;
  border-radius: 10px;
  max-width: 300px;
  width: 100%;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: transform 0.2s ease;
}


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

.project-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 15px;
}

.project-card h3 {
  font-size: 1.1rem;
}


.blog-card {
  background: var(--card);
  padding: 25px;
  max-width: 800px;
  margin: 0 auto;
  border-radius: 10px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.1);
  text-align: center;
}

.blog-card h3 a {
  color: var(--accent);
  text-decoration: none;
}

.blog-card p {
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 20px;
}

.blog-card a {
  text-decoration: none;
  font-weight: bold;
  color: var(--accent);
}

.testimonial-card {
  background: var(--card);
  max-width: 700px;
  margin: auto;
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  font-style: italic;
  color: var(--text);
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
}


.fixed-footer a {
  text-decoration: none;
}

.fixed-footer a img {
  display: inline-block;
  vertical-align: middle;
}



.fixed-footer {
  position: fixed;
  bottom: 0;
  width: 100%;
  background: var(--card);
  padding: 10px 0;
  text-align: center;
  z-index: 999;
  box-shadow: 0 -2px 8px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
}

.fixed-footer.hidden {
  transform: translateY(100%);
}


.footer-socials a {
  margin: 0 12px;
  display: inline-block;
}

.footer-socials img {
  width: 24px;
  height: 24px;
  opacity: 0.85;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.footer-socials img:hover {
  transform: scale(1.2);
  opacity: 1;
}




/* MODAL STYLES */
.modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
}

.modal-content {
  background: var(--card);
  margin: 5% auto;
  padding: 30px;
  border-radius: 10px;
  width: 90%;
  max-width: 600px;
  text-align: center;
  color: var(--text);
  animation: fadeIn 0.3s ease-in-out;
}

.modal-content img {
  width: 100%;
  max-height: 250px;
  object-fit: contain;
  border-radius: 10px;
  margin-bottom: 20px;
}

.modal-content a {
  display: inline-block;
  margin-top: 10px;
  color: var(--accent);
  font-weight: bold;
  text-decoration: none;
}

.close-btn {
  float: right;
  font-size: 24px;
  font-weight: bold;
  cursor: pointer;
  color: var(--text);
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

.skill-category {
  margin-bottom: 40px;
  text-align: center;
}

.skill-category h3 {
  color: var(--accent);
  font-size: 1.2rem;
  margin-bottom: 15px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.skills-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  margin-top: 10px;
}

.skills-list span {
  background: var(--card);
  color: var(--text);
  padding: 8px 16px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 25px;
  display: inline-flex;
  align-items: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease;
}

.skills-list span:hover {
  transform: scale(1.05);
  background-color: var(--accent);
  color: #fff;
}

.skill-icon {
  width: 20px;
  height: 20px;
  margin-right: 8px;
  object-fit: contain;
}

@media (max-width: 768px) {
  nav {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
  }

  .nav-links {
    display: none; /* Hide full nav on mobile */
  }

  .hero {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px 20px;
    gap: 20px;
  }

  .hero-img img {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
  }

  .hero-text h1 {
    font-size: 1.8rem;
    margin-top: 15px;
  }

  .hero-text p {
    font-size: 1rem;
    margin: 10px 0 20px;
  }

  .hero-text a {
    display: inline-block;
    margin: 8px 0;
    padding: 10px 20px;
    font-size: 0.95rem;
    width: 100%;
    max-width: 240px;
  }

  /* #toggleTheme {
    position: static;
    font-size: 20px;
  } */

  .logo {
    font-size: 1.4rem;
  }
}

