@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;500;600;700;800;900&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  text-decoration: none;
  border: none;
  outline: none;
  scroll-behavior: smooth;
  font-family: 'Poppins', sans-serif;
}

/* ===================================
   LOADING SCREEN
   =================================== */
.loader-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99999;
  opacity: 1;
  transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
}

.loader-wrapper.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3rem;
}

/* Spinner Animation */
.loader-spinner {
  position: relative;
  width: 120px;
  height: 120px;
}

.spinner-ring {
  position: absolute;
  width: 100%;
  height: 100%;
  border: 4px solid transparent;
  border-top: 4px solid #00efff;
  border-radius: 50%;
  animation: spin 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}

.spinner-ring:nth-child(1) {
  animation-delay: -0.45s;
  border-top-color: #00efff;
}

.spinner-ring:nth-child(2) {
  animation-delay: -0.3s;
  width: 80%;
  height: 80%;
  top: 10%;
  left: 10%;
  border-top-color: #7b2fff;
}

.spinner-ring:nth-child(3) {
  animation-delay: -0.15s;
  width: 60%;
  height: 60%;
  top: 20%;
  left: 20%;
  border-top-color: #ff00ff;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/* Loader Text */
.loader-text {
  text-align: center;
}

.loader-name {
  font-size: 2.5rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 1.5rem;
  letter-spacing: 3px;
  animation: fadeInUp 0.8s ease-out;
}

.loader-dots {
  display: flex;
  justify-content: center;
  gap: 0.8rem;
}

.loader-dots span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #00efff;
  animation: bounce 1.4s infinite ease-in-out both;
  box-shadow: 0 0 10px rgba(0, 239, 255, 0.5);
}

.loader-dots span:nth-child(1) {
  animation-delay: -0.32s;
}

.loader-dots span:nth-child(2) {
  animation-delay: -0.16s;
  background: #7b2fff;
  box-shadow: 0 0 10px rgba(123, 47, 255, 0.5);
}

.loader-dots span:nth-child(3) {
  background: #ff00ff;
  box-shadow: 0 0 10px rgba(255, 0, 255, 0.5);
}

@keyframes bounce {

  0%,
  80%,
  100% {
    transform: scale(0);
    opacity: 0.5;
  }

  40% {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Hide body content during loading */
body.loading {
  overflow: hidden;
}

body.loading .header,
body.loading section,
body.loading .animated-bg,
body.loading .cursor,
body.loading .cursor-follower {
  opacity: 0;
  transition: opacity 0.3s ease;
}

body.loaded .header,
body.loaded section,
body.loaded .animated-bg,
body.loaded .cursor,
body.loaded .cursor-follower {
  opacity: 1;
}

:root {
  --bg-color: #1f242d;
  --second-bg-color: #323946;
  --text-color: #fff;
  --main-color: #0ef;
}

/* Light Mode Theme */
.light-mode {
  --bg-color: #f5f5f5;
  --second-bg-color: #e4e4e4;
  --text-color: #111;
  --main-color: #0077ff;
}

/* Adjust for light feel */
.light-mode .header,
.light-mode .footer {
  background: var(--second-bg-color);
}

/* Typing animation */
.typing-line {
  display: inline-block;
  position: relative;
  min-width: 350px;
  /* Fixed width to prevent layout shift */
  text-align: left;
  margin-left: 0.5rem;
  /* Space between "I'm" and typing animation */
}

.typed-text {
  border-right: 3px solid var(--main-color);
  padding-right: 6px;
  white-space: nowrap;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Poppins', sans-serif
}

:root {
  --bg: #1f242d;
  --card: #1c2331;
  --muted: #bbb;
  --main: #0ef;
  --accent: #00eaff
}

html {
  font-size: 62.5%
}

body {
  background: var(--bg);
  color: #fff
}


/* header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 2rem 6%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg);
  z-index: 1000
}

.logo {
  font-size: 2.2rem;
  font-weight: 700
}

.navbar a {
  color: #fff;
  margin-left: 3.2rem;
  font-size: 1.6rem
}

.navbar a.active {
  color: var(--main)
}


/* home */
section {
  min-height: 100vh;
  padding: 12rem 6rem 4rem
}

.home {
  display: flex;
  gap: 4rem;
  align-items: center;
  flex-wrap: wrap
}

.home-content {
  flex: 1;
  min-width: 280px
}

.home-img {
  flex: 1;
  min-width: 280px;
  display: flex;
  justify-content: flex-end
}

.profile-circle img {
  width: 30rem;
  height: 30rem;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--main)
}


h1 {
  font-size: 4.2rem
}

h2 {
  font-size: 2.2rem;
  margin: 1.2rem 0
}

h3 {
  font-size: 1.9rem;
  color: var(--main)
}

p {
  color: var(--muted);
  font-size: 1.6rem
}


/* typing */
.typing-line {
  display: inline-block;
  position: relative;
  min-width: 350px;
  /* Fixed width to prevent layout shift */
  text-align: left;
  margin-left: 0.5rem;
  /* Space between "I'm" and typing animation */
}

.typed-text {
  border-right: 3px solid rgba(14, 238, 255, 0.9);
  padding-right: 0.6rem;
  white-space: nowrap;
}


/* certificates / portfolio simple styles (kept short) */
.heading {
  font-size: 3.4rem;
  text-align: center;
  margin-bottom: 3.2rem
}

.timeline {
  margin-top: 3rem
}


/* auto-scroll helper: smooth behaviour handled by CSS */
html {
  scroll-behavior: smooth
}


/* small responsive */
@media(max-width:760px) {
  h1 {
    font-size: 3rem
  }

  .profile-circle img {
    width: 22rem;
    height: 22rem
  }

  .navbar {
    display: none
  }

  section {
    padding-top: 10rem
  }
}

html {
  font-size: 62.5%;
  overflow-x: hidden;
}

body {
  background: var(--bg-color);
  color: var(--text-color);
  overflow-x: hidden;
}

/* Hide default cursor on desktop only */
@media (min-width: 769px) {
  body {
    cursor: none;
  }
}

/* Custom Cursor Styles */
.cursor {
  width: 20px;
  height: 20px;
  border: 2px solid var(--main-color);
  border-radius: 50%;
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 10000;
  transition: transform 0.1s ease;
  mix-blend-mode: difference;
}

.cursor-follower {
  width: 50px;
  height: 50px;
  border: 1px solid rgba(0, 238, 255, 0.3);
  border-radius: 50%;
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 9999;
  transition: transform 0.3s ease;
}

.cursor.hover {
  transform: scale(1.5);
  background: var(--main-color);
  border-color: var(--main-color);
}

.cursor-follower.hover {
  transform: scale(1.5);
  border-color: var(--main-color);
  background: rgba(0, 238, 255, 0.1);
}

/* Pointer cursor style for buttons */
.cursor.pointer {
  transform: scale(1.3);
  background: var(--main-color);
  border-color: var(--main-color);
}

.cursor-follower.pointer {
  transform: scale(1.4);
  border-color: var(--main-color);
  background: rgba(0, 238, 255, 0.2);
}

/* Clicked state for cursor on buttons - works with or without pointer class */
.cursor.clicked {
  background: #00ff88 !important;
  border-color: #00ff88 !important;
  transform: scale(1.1) !important;
}

.cursor-follower.clicked {
  border-color: #00ff88 !important;
  background: rgba(0, 255, 136, 0.4) !important;
  transform: scale(1.2) !important;
}

/* Specific styling when both pointer and clicked are active */
.cursor.pointer.clicked {
  background: #00ff88 !important;
  border-color: #00ff88 !important;
  transform: scale(1.1) !important;
}

.cursor-follower.pointer.clicked {
  border-color: #00ff88 !important;
  background: rgba(0, 255, 136, 0.4) !important;
  transform: scale(1.2) !important;
}

/* Animated Background */
.animated-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  overflow: hidden;
  background: var(--bg-color);
}

/* Floating Particles */
.particles {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--main-color);
  border-radius: 50%;
  opacity: 0.6;
  animation: float 15s infinite ease-in-out;
  box-shadow: 0 0 10px var(--main-color);
}

.particle:nth-child(1) {
  left: 10%;
  animation-delay: 0s;
  animation-duration: 20s;
}

.particle:nth-child(2) {
  left: 20%;
  animation-delay: 2s;
  animation-duration: 18s;
}

.particle:nth-child(3) {
  left: 30%;
  animation-delay: 4s;
  animation-duration: 22s;
}

.particle:nth-child(4) {
  left: 40%;
  animation-delay: 1s;
  animation-duration: 16s;
}

.particle:nth-child(5) {
  left: 50%;
  animation-delay: 3s;
  animation-duration: 19s;
}

.particle:nth-child(6) {
  left: 60%;
  animation-delay: 5s;
  animation-duration: 21s;
}

.particle:nth-child(7) {
  left: 70%;
  animation-delay: 2.5s;
  animation-duration: 17s;
}

.particle:nth-child(8) {
  left: 80%;
  animation-delay: 4.5s;
  animation-duration: 23s;
}

.particle:nth-child(9) {
  left: 90%;
  animation-delay: 1.5s;
  animation-duration: 18s;
}

.particle:nth-child(10) {
  left: 15%;
  animation-delay: 3.5s;
  animation-duration: 20s;
}

.particle:nth-child(11) {
  left: 25%;
  animation-delay: 0.5s;
  animation-duration: 19s;
}

.particle:nth-child(12) {
  left: 35%;
  animation-delay: 5.5s;
  animation-duration: 21s;
}

.particle:nth-child(13) {
  left: 45%;
  animation-delay: 2.2s;
  animation-duration: 17s;
}

.particle:nth-child(14) {
  left: 55%;
  animation-delay: 4.2s;
  animation-duration: 22s;
}

.particle:nth-child(15) {
  left: 65%;
  animation-delay: 1.2s;
  animation-duration: 18s;
}

.particle:nth-child(16) {
  left: 75%;
  animation-delay: 3.2s;
  animation-duration: 20s;
}

.particle:nth-child(17) {
  left: 85%;
  animation-delay: 5.2s;
  animation-duration: 19s;
}

.particle:nth-child(18) {
  left: 95%;
  animation-delay: 2.8s;
  animation-duration: 21s;
}

.particle:nth-child(19) {
  left: 5%;
  animation-delay: 4.8s;
  animation-duration: 18s;
}

.particle:nth-child(20) {
  left: 12%;
  animation-delay: 0.8s;
  animation-duration: 20s;
}

@keyframes float {
  0% {
    transform: translateY(100vh) translateX(0) rotate(0deg);
    opacity: 0;
  }

  10% {
    opacity: 0.6;
  }

  90% {
    opacity: 0.6;
  }

  100% {
    transform: translateY(-100px) translateX(50px) rotate(360deg);
    opacity: 0;
  }
}

/* Gradient Orbs */
.gradient-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.3;
  animation: orbFloat 20s infinite ease-in-out;
}

.orb-1 {
  width: 400px;
  height: 400px;
  background: linear-gradient(135deg, var(--main-color), #7b2fff);
  top: 10%;
  left: 10%;
  animation-duration: 25s;
}

.orb-2 {
  width: 350px;
  height: 350px;
  background: linear-gradient(135deg, #ff00ff, var(--main-color));
  bottom: 10%;
  right: 10%;
  animation-duration: 30s;
  animation-delay: -10s;
}

.orb-3 {
  width: 300px;
  height: 300px;
  background: linear-gradient(135deg, var(--main-color), #00ff88);
  top: 50%;
  left: 50%;
  animation-duration: 35s;
  animation-delay: -5s;
}

@keyframes orbFloat {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }

  33% {
    transform: translate(50px, -50px) scale(1.1);
  }

  66% {
    transform: translate(-50px, 50px) scale(0.9);
  }
}

section {
  min-height: 100vh;
  padding: 10rem 9% 2rem;
  ;
}

.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 2rem 9%;
  background: var(--bg-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 1000;
}

.logo {
  font-size: 2.5rem;
  font-weight: 600;
  color: var(--text-color);
  cursor: default;
}

.navbar a {
  font-size: 1.7rem;
  color: #fff;
  margin-left: 4rem;
  transition: color 0.3s ease;
}

.navbar a:hover {
  color: var(--main-color);
}

.navbar a.active {
  color: #00efff;
  /* Cyan color for active link */
}

/* Light mode navbar link styling */
.light-mode .navbar a {
  color: #333;
  /* Dark color for inactive links in light mode */
}

.light-mode .navbar a:hover {
  color: var(--main-color);
}

.light-mode .navbar a.active {
  color: #00efff;
  /* Keep cyan color for active link even in light mode */
}

#menu-icon {
  font-size: 3.6rem;
  color: var(--text-color);
  display: none;
}

.home {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 5rem;
  text-align: left;
  flex-wrap: wrap;
}

.home-content {
  flex: 1;
  min-width: 300px;
}

.home-img {
  flex: 1;
  min-width: 300px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.home-img img {
  width: 40rem;
  height: 40rem;
  border-radius: 50%;
  border: 5px solid var(--main-color);
  object-fit: cover;
  box-shadow: 0 0 35px rgba(0, 238, 255, 0.7);
}

.home-img {
  margin-bottom: 2rem;
}

.home-img img:hover {
  transform: scale(1.05);
  box-shadow: 0 0 45px rgba(0, 238, 255, 1);
  transition: 0.3s ease;
}

.home-content h3 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--main-color);
}

.home-content h1 {
  font-size: 4.5rem;
  margin-bottom: 1rem;
  min-height: 5.5rem;
  /* Prevent height shift during typing */
  display: flex;
  align-items: center;
}

.home-content h2:nth-of-type(1) {
  margin-bottom: 2rem;
}

/* Ensure typing container maintains space */
.home-content h1:nth-of-type(2) {
  margin-bottom: 2rem;
  min-height: 5.5rem;
}

span {
  color: var(--main-color);
}

.home-content h2 {
  font-size: 2.5rem;
  margin-bottom: 2rem;
}

.home-content p {
  font-size: 1.6rem;
  margin-bottom: 2rem;
  color: #bbb;
}

.social-media {
  display: flex;
  align-items: center;
  margin-top: 2rem;
  /* Fixed spacing above, won't shift */
  padding-top: 1rem;
  clear: both;
  /* Ensure it's below the typing animation */
}

.social-media a {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 4rem;
  height: 4rem;
  background: transparent;
  border: 2px solid var(--main-color);
  border-radius: 50%;
  color: var(--main-color);
  font-size: 2rem;
  margin-right: 1.5rem;
  flex-shrink: 0;
  /* Prevent shrinking */
}

.social-media a:hover {
  background: var(--main-color);
  color: var(--bg-color);
  box-shadow: 0 0 1rem var(--main-color);
  transition: 0.3s ease;
}

.header-text {
  margin-bottom: 30px;
  /* Space below the text */
}

/* ---------- Timeline Section ---------- */

.about {
  padding-top: 12rem;
}

.heading {
  text-align: center;
  font-size: 4rem;
  margin-bottom: 5rem;
}

.timeline {
  position: relative;
  width: 100%;
  margin: 60px auto;
  padding: 0;
}

/* Vertical line */
.timeline::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 4px;
  height: 100%;
  background: linear-gradient(#00eaff, #0ef, #00eaff);
  transform: translateX(-50%);
  border-radius: 10px;
}


/*Timeline Item */
.timeline-item {
  width: 50%;
  padding: 20px 40px;
  position: relative;
}

.timeline-item.left {
  left: 0;
  text-align: left;
}

.timeline-item.right {
  left: 50%;
  text-align: left;
}

/* Each item card */
.timeline-content {
  background: #1c2331;
  padding: 25px;
  border-radius: 12px;
  box-shadow: 0px 0px 20px rgba(0, 255, 255, 0.1);
  position: relative;
}

/* Circle marker */
.timeline-item .timeline-content::before {
  content: "";
  position: absolute;
  top: 20px;
  width: 18px;
  height: 18px;
  background: transparent;
  border: 4px solid #00eaff;
  border-radius: 50%;
}

/* Circle position left */
.timeline-item.left .timeline-content::before {
  right: -54px;
}

/* Circle position right */
.timeline-item.right .timeline-content::before {
  left: -54px;
}


/* Text inside timeline */
.timeline-content h3 {
  margin-bottom: 10px;
  font-size: 1.4rem;
  color: #ffffff;
}

.timeline-content {
  background: #1c2331;
  padding: 25px;
  border-radius: 16px;
  transition: 0.3s ease-in-out;
  box-shadow: 0 0 0 rgba(0, 255, 255, 0);
  /* default no glow */
}

.timeline-content {
  border-left: 4px solid var(--main-color);
  background: rgba(28, 35, 49, 0.6);
  backdrop-filter: blur(6px);
}


/* Hover effect: curved neon cyan glow */
.timeline-content:hover {
  box-shadow:
    0 0 25px rgba(0, 255, 255, 0.4),
    0 0 45px rgba(0, 255, 255, 0.25),
    0 0 70px rgba(0, 255, 255, 0.2);
  transform: translateY(-3px);
}

/* ---------- Certificates Section ---------- */
.certificates-container {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 4rem;
  flex-wrap: wrap;
}

.certificate-box {
  background: var(--second-bg-color);
  padding: 2rem;
  border-radius: 1.2rem;
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.1);
  transition: 0.3s ease;
  width: 30rem;
  text-align: center;
  animation: fadeUp 0.8s ease forwards;
}

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

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

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

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

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

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

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

.certificate-box img {
  width: 100%;
  height: 20rem;
  border-radius: 1rem;
  object-fit: cover;
  cursor: pointer;
}

.certificate-box:hover {
  transform: translateY(-10px) scale(1.03);
  box-shadow: 0 0 25px var(--main-color);
}

.certificate-box a {
  color: red;
  text-decoration: none;
}

.certificate-container .certificate-box a:hover {
  color: darkred;


  background: var(--main-color);
  color: var(--bg-color);
  box-shadow: 0 0 1rem var(--main-color);
  transition: 0.3s ease;

}

.portfolio {
  background: transparent;
  /* Remove solid background to match certificates section */
}

.portfolio h2 {
  text-align: center;
  padding-bottom: 2rem;
  margin-bottom: 4rem;
}

.portfolio-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
  width: 100%;
  margin-top: 3rem;
}

.portfolio-container .portfolio-box {
  padding: 1rem;
  box-shadow: 0 0 20px rgba(0, 239, 255, 0.2),
    0 0 40px rgba(0, 239, 255, 0.1);
  /* Enhanced neon glow */
  border-radius: 1.2rem;
  transition: all 0.3s ease;
  margin: 1rem;
  text-align: center;
  border: 1px solid rgba(0, 239, 255, 0.1);
  /* Subtle border for glow effect */
}

.portfolio-container .portfolio-box:hover {
  transform: translateY(-10px) scale(1.03);
  box-shadow: 0 0 30px rgba(0, 239, 255, 0.5),
    0 0 50px rgba(0, 239, 255, 0.3),
    0 0 70px rgba(0, 239, 255, 0.2);
  /* Enhanced neon glow on hover */
  border-color: rgba(0, 239, 255, 0.3);
}


.portfolio-box img {
  width: adjust-content;
  height: 35rem;
  border-radius: 1rem;
  object-fit: cover;
  cursor: pointer;
}

/* ------------ Contact Section ------------ */

/* ------------ Contact Section ------------ */

.contact h2 {
  text-align: center;
  margin-bottom: 4rem;
}

/* Form container */
.contact form {
  max-width: 70rem;
  margin: 0 auto;
}

/* Two-column container */
.contact form .input-box {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
}

/* Input styling (all same background) */
.contact form .input-box input:not([type="submit"]):not([type="button"]) {
  width: 47%;
  padding: 1.5rem;
  font-size: 1.6rem;
  color: var(--text-color);
  background: var(--second-bg-color);
  border-radius: 0.8rem;
  margin: 0.7rem 0;
  cursor: text;
  /* Show text cursor (I-beam) for input fields */
}

/* Message box */
.contact form textarea {
  width: 100%;
  padding: 1.5rem;
  font-size: 1.6rem;
  color: var(--text-color);
  background: var(--second-bg-color);
  border-radius: 0.8rem;
  margin: 0.7rem 0;
  min-height: 18rem;
  resize: none;
  cursor: text;
  /* Show text cursor (I-beam) for textarea */
}

/* Hover effect */
.contact form input:hover,
.contact form textarea:hover {
  border: 2px solid var(--main-color);
  transition: 0.3s ease;
}

/* Button */
.btn {
  background: var(--main-color);
  padding: 1.5rem 3rem;
  color: var(--bg-color);
  border-radius: 0.8rem;
  font-size: 1.8rem;
  cursor: pointer;
  margin-top: 1rem;
  display: inline-block;
  transition: 0.3s ease;
}

.btn:hover {
  box-shadow: 0 0 1rem var(--main-color);
}

/* Responsive */
@media (max-width: 768px) {
  .contact form .input-box input {
    width: 100%;
  }
}

/* Fix portfolio grid responsiveness */
.portfolio-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
}

/* Tablets (2 per row) */
@media (max-width: 992px) {
  .portfolio-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile (1 per row) */
@media (max-width: 600px) {
  .portfolio-container {
    grid-template-columns: 1fr;
  }

  .portfolio-box img {
    width: 100%;
    height: auto;
  }
}

/* Mobile responsive fix for timeline */
@media (max-width: 768px) {

  /* Make timeline full width */
  .timeline-item {
    width: 100%;
    left: 0 !important;
    text-align: left;
    padding-left: 20px;
    padding-right: 20px;
    margin-bottom: 30px;
  }

  /* Move vertical line to the left */
  .timeline::before {
    left: 20px;
  }

  /* Adjust card spacing */
  .timeline-content {
    margin-left: 40px;
  }

  /* Fix circle position */
  .timeline-item .timeline-content::before {
    left: -32px !important;
    right: auto !important;
  }
}

/* Fade-in animation */
.fade-in {
  opacity: 0;
  transform: translateY(25px);
  transition: all 0.8s ease;
}

.fade-in.show {
  opacity: 1;
  transform: translateY(0);
}

/* Slide-in animation for timeline */
.timeline-item {
  opacity: 0;
  transform: translateX(-40px);
  transition: all 0.8s ease;
}

.timeline-item.right {
  transform: translateX(40px);
}

.timeline-item.show {
  opacity: 1;
  transform: translateX(0);
}

/* Footer */
.footer {
  width: 100%;
  text-align: center;
  padding: 3rem 0;
  background: var(--second-bg-color);
  color: var(--text-color);
  border-top: 2px solid var(--main-color);
  margin-top: 4rem;
}

/* Social icons in footer */
.footer-social {
  margin-bottom: 1.5rem;
}

.footer-social a {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 4rem;
  height: 4rem;
  margin: 0 .8rem;
  font-size: 2.2rem;
  color: var(--main-color);
  border: 2px solid var(--main-color);
  border-radius: 50%;
  transition: 0.3s ease;
}

.footer-social a:hover {
  background: var(--main-color);
  color: var(--bg-color);
  box-shadow: 0 0 1rem var(--main-color);
  transform: translateY(-4px);
}

/* Footer text */
.footer p {
  font-size: 1.5rem;
  color: #ccc;
  margin-top: 1rem;
}

/* Theme Toggle Button */
.theme-toggle {
  font-size: 3rem;
  color: var(--main-color);
  cursor: pointer;
  margin-left: 2rem;
  transition: all 0.3s ease;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: transparent;
}

.theme-toggle::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 238, 255, 0.2), transparent);
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  transform: scale(0.8);
}

.theme-toggle:hover {
  transform: scale(1.15);
  color: var(--main-color);
}

.theme-toggle:hover::before {
  opacity: 1;
  transform: scale(1.3);
}

.theme-toggle i {
  position: relative;
  z-index: 1;
  transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55),
    color 0.3s ease;
}

/* Rotation animation when clicked */
.theme-toggle.clicked i {
  animation: themeToggleRotate 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes themeToggleRotate {
  0% {
    transform: rotate(0deg) scale(1);
  }

  50% {
    transform: rotate(180deg) scale(1.2);
  }

  100% {
    transform: rotate(360deg) scale(1);
  }
}

/* Pulsing glow effect */
.theme-toggle.pulse {
  animation: themeTogglePulse 0.6s ease-out;
}

@keyframes themeTogglePulse {
  0% {
    box-shadow: 0 0 0 0 rgba(0, 238, 255, 0.7);
  }

  50% {
    box-shadow: 0 0 0 15px rgba(0, 238, 255, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(0, 238, 255, 0);
  }
}

/* Light mode specific styles */
.light-mode .theme-toggle::before {
  background: radial-gradient(circle, rgba(0, 119, 255, 0.2), transparent);
}

.light-mode .theme-toggle.pulse {
  animation: themeTogglePulseLight 0.6s ease-out;
}

@keyframes themeTogglePulseLight {
  0% {
    box-shadow: 0 0 0 0 rgba(0, 119, 255, 0.7);
  }

  50% {
    box-shadow: 0 0 0 15px rgba(0, 119, 255, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(0, 119, 255, 0);
  }
}

/* Smooth theme transitions */
body,
.header,
.portfolio,
.certificate-box,
.timeline-content {
  transition: background 0.4s ease, color 0.4s ease;
}

/* Light mode adjustments for animated background */
.light-mode .particle {
  opacity: 0;
}

.light-mode .gradient-orb {
  opacity: 0;
}

/* ===================================
   LIGHT MODE CREATIVE ANIMATIONS
   =================================== */

.light-mode-animations {
  display: none;
}

.light-mode .light-mode-animations {
  display: block;
}

/* Geometric Shapes */
.geo-shape {
  position: absolute;
  opacity: 0.25;
  animation: geoFloat 20s infinite ease-in-out;
}

/* Triangles */
.triangle-1,
.triangle-2,
.triangle-3 {
  width: 0;
  height: 0;
  border-style: solid;
}

.triangle-1 {
  border-width: 0 40px 70px 40px;
  border-color: transparent transparent #0077ff transparent;
  top: 15%;
  left: 10%;
  animation-duration: 18s;
  animation-delay: 0s;
}

.triangle-2 {
  border-width: 70px 40px 0 40px;
  border-color: #7b2fff transparent transparent transparent;
  top: 60%;
  right: 15%;
  animation-duration: 22s;
  animation-delay: -5s;
  transform: rotate(45deg);
}

.triangle-3 {
  border-width: 0 35px 60px 35px;
  border-color: transparent transparent #00ff88 transparent;
  bottom: 20%;
  left: 25%;
  animation-duration: 25s;
  animation-delay: -10s;
  transform: rotate(-30deg);
}

/* Hexagons */
.hexagon-1,
.hexagon-2,
.hexagon-3 {
  width: 60px;
  height: 34.64px;
  background: linear-gradient(135deg, #ff00ff, #7b2fff);
  position: relative;
  clip-path: polygon(25% 0%, 75% 0%, 100% 50%, 75% 100%, 25% 100%, 0% 50%);
}

.hexagon-1 {
  top: 25%;
  right: 20%;
  animation-duration: 20s;
  animation-delay: -2s;
}

.hexagon-2 {
  top: 70%;
  left: 50%;
  animation-duration: 24s;
  animation-delay: -8s;
  background: linear-gradient(135deg, #0077ff, #00ff88);
}

.hexagon-3 {
  top: 40%;
  right: 45%;
  animation-duration: 19s;
  animation-delay: -12s;
  background: linear-gradient(135deg, #00ff88, #0077ff);
  transform: rotate(45deg);
}

/* Circles */
.circle-1,
.circle-2,
.circle-3 {
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 0, 255, 0.3), rgba(123, 47, 255, 0.1));
}

.circle-1 {
  width: 80px;
  height: 80px;
  top: 10%;
  left: 60%;
  animation-duration: 23s;
  animation-delay: -3s;
  box-shadow: 0 0 30px rgba(0, 119, 255, 0.3);
}

.circle-2 {
  width: 100px;
  height: 100px;
  bottom: 15%;
  right: 30%;
  animation-duration: 21s;
  animation-delay: -7s;
  background: radial-gradient(circle, rgba(0, 119, 255, 0.3), rgba(0, 255, 136, 0.1));
  box-shadow: 0 0 40px rgba(123, 47, 255, 0.3);
}

.circle-3 {
  width: 70px;
  height: 70px;
  top: 55%;
  left: 15%;
  animation-duration: 26s;
  animation-delay: -15s;
  background: radial-gradient(circle, rgba(0, 255, 136, 0.3), rgba(0, 119, 255, 0.1));
  box-shadow: 0 0 25px rgba(255, 0, 255, 0.3);
}

@keyframes geoFloat {

  0%,
  100% {
    transform: translate(0, 0) rotate(0deg) scale(1);
  }

  25% {
    transform: translate(30px, -40px) rotate(90deg) scale(1.1);
  }

  50% {
    transform: translate(-20px, 30px) rotate(180deg) scale(0.9);
  }

  75% {
    transform: translate(40px, 20px) rotate(270deg) scale(1.05);
  }
}

/* Gradient Waves */
.wave-container {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 40%;
  overflow: hidden;
  opacity: 0.4;
}

.wave {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 200%;
  height: 100%;
  animation: waveFlow 15s infinite linear;
}

.wave-1 {
  animation-duration: 20s;
  animation-delay: 0s;
  opacity: 0.5;
}

.wave-2 {
  animation-duration: 25s;
  animation-delay: -5s;
  opacity: 0.4;
  height: 120%;
}

.wave-3 {
  animation-duration: 18s;
  animation-delay: -10s;
  opacity: 0.35;
  height: 110%;
}

@keyframes waveFlow {
  0% {
    transform: translateX(0) translateY(0);
  }

  50% {
    transform: translateX(-25%) translateY(-10px);
  }

  100% {
    transform: translateX(-50%) translateY(0);
  }
}

/* Network Lines */
.network-lines {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0.15;
  z-index: 0;
}

.network-node {
  animation: nodePulse 3s infinite ease-in-out;
}

.node-1 {
  animation-delay: 0s;
}

.node-2 {
  animation-delay: 0.4s;
}

.node-3 {
  animation-delay: 0.8s;
}

.node-4 {
  animation-delay: 1.2s;
}

.node-5 {
  animation-delay: 1.6s;
}

.node-6 {
  animation-delay: 2s;
}

.node-7 {
  animation-delay: 2.4s;
}

.node-8 {
  animation-delay: 2.8s;
}

.network-line {
  stroke-dasharray: 5, 5;
  animation: lineDash 4s infinite linear;
  opacity: 0.3;
}

.line-1 {
  animation-delay: 0s;
}

.line-2 {
  animation-delay: 0.5s;
}

.line-3 {
  animation-delay: 1s;
}

.line-4 {
  animation-delay: 1.5s;
}

.line-5 {
  animation-delay: 2s;
}

.line-6 {
  animation-delay: 2.5s;
}

.line-7 {
  animation-delay: 3s;
}

@keyframes nodePulse {

  0%,
  100% {
    r: 3;
    opacity: 0.6;
  }

  50% {
    r: 5;
    opacity: 0.9;
  }
}

@keyframes lineDash {
  0% {
    stroke-dashoffset: 0;
    opacity: 0.2;
  }

  50% {
    opacity: 0.4;
  }

  100% {
    stroke-dashoffset: 20;
    opacity: 0.2;
  }
}

/* Floating Bubbles */
.bubble {
  position: absolute;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(0, 119, 255, 0.15), rgba(123, 47, 255, 0.1));
  backdrop-filter: blur(10px);
  border: 1px solid rgba(0, 119, 255, 0.2);
  animation: bubbleFloat 25s infinite ease-in-out;
}

.bubble-1 {
  width: 120px;
  height: 120px;
  top: 20%;
  left: 5%;
  animation-duration: 20s;
  animation-delay: 0s;
  box-shadow: 0 0 40px rgba(0, 119, 255, 0.2);
}

.bubble-2 {
  width: 90px;
  height: 90px;
  top: 50%;
  right: 10%;
  animation-duration: 22s;
  animation-delay: -5s;
  background: linear-gradient(135deg, rgba(255, 0, 255, 0.15), rgba(123, 47, 255, 0.1));
  box-shadow: 0 0 35px rgba(255, 0, 255, 0.2);
}

.bubble-3 {
  width: 150px;
  height: 150px;
  bottom: 25%;
  left: 40%;
  animation-duration: 28s;
  animation-delay: -10s;
  background: linear-gradient(135deg, rgba(0, 255, 136, 0.15), rgba(0, 119, 255, 0.1));
  box-shadow: 0 0 50px rgba(0, 255, 136, 0.2);
}

.bubble-4 {
  width: 70px;
  height: 70px;
  top: 75%;
  left: 20%;
  animation-duration: 18s;
  animation-delay: -3s;
  background: linear-gradient(135deg, rgba(123, 47, 255, 0.15), rgba(255, 0, 255, 0.1));
  box-shadow: 0 0 25px rgba(123, 47, 255, 0.2);
}

.bubble-5 {
  width: 110px;
  height: 110px;
  top: 35%;
  right: 35%;
  animation-duration: 24s;
  animation-delay: -7s;
  background: linear-gradient(135deg, rgba(0, 119, 255, 0.15), rgba(0, 255, 136, 0.1));
  box-shadow: 0 0 38px rgba(0, 119, 255, 0.2);
}

.bubble-6 {
  width: 85px;
  height: 85px;
  bottom: 40%;
  right: 20%;
  animation-duration: 21s;
  animation-delay: -12s;
  background: linear-gradient(135deg, rgba(255, 0, 255, 0.15), rgba(0, 255, 136, 0.1));
  box-shadow: 0 0 30px rgba(255, 0, 255, 0.2);
}

@keyframes bubbleFloat {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.6;
  }

  25% {
    transform: translate(50px, -60px) scale(1.1);
    opacity: 0.8;
  }

  50% {
    transform: translate(-40px, -100px) scale(0.9);
    opacity: 0.7;
  }

  75% {
    transform: translate(60px, -40px) scale(1.05);
    opacity: 0.75;
  }
}

/* Make interactive elements show hover on cursor (desktop only) */
@media (min-width: 769px) {

  a,
  button,
  .btn,
  .social-media a,
  .navbar a,
  .portfolio-box,
  .certificate-box {
    cursor: none;
  }

  /* Form inputs and textareas always show text cursor (excluding submit buttons) */
  input:not([type="submit"]):not([type="button"]),
  textarea {
    cursor: text !important;
  }

  /* Submit buttons show pointer cursor */
  input[type="submit"],
  input[type="button"],
  button {
    cursor: pointer !important;
  }
}

/* Mobile: Show default cursor */
@media (max-width: 768px) {
  body {
    cursor: auto;
  }

  .cursor,
  .cursor-follower {
    display: none !important;
  }

  /* Reduce light mode animations on mobile for performance */
  .light-mode .geo-shape,
  .light-mode .bubble {
    opacity: 0.15;
  }

  .light-mode .wave-container {
    opacity: 0.25;
  }

  .light-mode .network-lines {
    opacity: 0.1;
  }

  /* Typing animation adjustments for mobile */
  .typing-line {
    min-width: 280px;
  }

  .home-content h1 {
    font-size: 3.5rem;
    min-height: 4.5rem;
  }

  .home-content h1:nth-of-type(2) {
    min-height: 4.5rem;
  }
}

/* ===================================
   PORTFOLIO / PROJECTS SECTION
   =================================== */
.portfolio {
  background: var(--second-bg-color);
}

.portfolio-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 3rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 0;
}

.portfolio-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 2rem;
  padding: 3rem 2.5rem;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  overflow: hidden;
}

.portfolio-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--main-color), #7b2fff, #ff00ff);
  border-radius: 2rem 2rem 0 0;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.portfolio-box:hover {
  transform: translateY(-10px);
  border-color: rgba(0, 238, 255, 0.2);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3),
              0 0 40px rgba(0, 238, 255, 0.05);
}

.portfolio-box:hover::before {
  opacity: 1;
}

/* Project Image */
.project-img {
  width: 100%;
  height: 20rem;
  border-radius: 1.5rem;
  overflow: hidden;
  margin-bottom: 2rem;
  background: rgba(0, 238, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
}

.project-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.5s ease;
}

.portfolio-box:hover .project-img img {
  transform: scale(1.1);
  filter: brightness(1.1);
}

/* Project Content */
.project-content h3 {
  font-size: 2.2rem;
  color: var(--text-color);
  margin-bottom: 1rem;
  font-weight: 600;
}

.project-content p {
  font-size: 1.4rem;
  color: #aaa;
  line-height: 1.7;
  margin-bottom: 1.8rem;
}

/* Tech Tags */
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-bottom: 2rem;
}

.project-tags .tag {
  padding: 0.4rem 1.2rem;
  border-radius: 5rem;
  font-size: 1.2rem;
  font-weight: 500;
  background: rgba(0, 238, 255, 0.08);
  color: var(--main-color);
  border: 1px solid rgba(0, 238, 255, 0.15);
  transition: all 0.3s ease;
}

.portfolio-box:hover .project-tags .tag {
  background: rgba(0, 238, 255, 0.12);
  border-color: rgba(0, 238, 255, 0.25);
}

/* Project Links / Buttons */
.project-links {
  display: flex;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.project-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.8rem 2rem;
  border-radius: 5rem;
  font-size: 1.3rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-color);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.project-btn i {
  font-size: 1.6rem;
}

.project-btn:hover {
  background: var(--main-color);
  color: #000;
  border-color: var(--main-color);
  transform: translateY(-2px);
  box-shadow: 0 5px 20px rgba(0, 238, 255, 0.3);
}

.project-btn.live-btn {
  background: linear-gradient(135deg, rgba(0, 238, 255, 0.15), rgba(123, 47, 255, 0.15));
  border-color: rgba(0, 238, 255, 0.3);
  color: var(--main-color);
}

.project-btn.live-btn:hover {
  background: linear-gradient(135deg, #0ef, #7b2fff);
  color: #000;
  border-color: transparent;
  box-shadow: 0 5px 25px rgba(0, 238, 255, 0.4);
}

/* Light Mode Adjustments */
.light-mode .portfolio-box {
  background: rgba(255, 255, 255, 0.7);
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.light-mode .portfolio-box:hover {
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1),
              0 0 40px rgba(0, 119, 255, 0.08);
  border-color: rgba(0, 119, 255, 0.2);
}

.light-mode .project-content p {
  color: #666;
}

.light-mode .project-tags .tag {
  background: rgba(0, 119, 255, 0.08);
  color: var(--main-color);
  border-color: rgba(0, 119, 255, 0.15);
}

.light-mode .project-btn {
  background: rgba(0, 0, 0, 0.04);
  color: var(--text-color);
  border-color: rgba(0, 0, 0, 0.1);
}

.light-mode .project-btn:hover {
  background: var(--main-color);
  color: #fff;
}

.light-mode .project-btn.live-btn {
  background: rgba(0, 119, 255, 0.08);
  color: var(--main-color);
}

.light-mode .project-btn.live-btn:hover {
  background: linear-gradient(135deg, #0077ff, #7b2fff);
  color: #fff;
}

/* Portfolio Responsive */
@media (max-width: 768px) {
  .portfolio-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .portfolio-box {
    padding: 2.5rem 2rem;
  }

  .project-icon {
    width: 6rem;
    height: 6rem;
  }

  .project-icon i {
    font-size: 2.8rem;
  }

  .project-content h3 {
    font-size: 1.9rem;
  }
}
