*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    scroll-behavior: smooth;
   font-family: 'Montserrat', sans-serif;
}

:root {
--bg-color: #0f0f0f;
    --text-color: #f5f5f5;
    --main-color: #7F00FF;
    --accent-color: #ffb347;
    --gradient: linear-gradient(135deg, #7F00FF, #E100FF);
}


body {
    background: var(--bg-color);
    color: var(--text-color);
    
}

html{
    font-size: 62.5%; 
    overflow-x: hidden;

}

.header{
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 3rem 9%;
    background: rgba(20, 20, 20, 0.6);
    backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    justify-content: space-between;
  z-index: 100;

}
.logo {
    font-size: 3rem;
    display: inline-block;
    color: var(--text-color);
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.3s ease, color 0.3s ease, text-shadow 0.3s ease;

    

}
.logo:hover{
    transform:scale(1.3) ;
    color: #ffd700;
     text-shadow: 0 0 5px #ffb347;


}
span{
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    

}
.navbar {
      list-style-type: none;
      margin: 0;
      padding: 0;
  font-family: 'Montserrat', sans-serif;
      
    }

    .navbar li {
      display: inline-block;
      margin: 0 15px;
      
    }

    .navbar li a {
      text-decoration: none;
      display: inline-block;
      font-size: 23px;
      font-weight: bold;
        font-family: 'Montserrat', sans-serif;
      color: var(--text-color);
      padding: 5px;
      
      letter-spacing: 1px;
      transition: transform 0.3s ease, color 0.3s ease;
     
    }

    .navbar li a:hover {
      transform: scale(1.2);
      color: #ffb347;
      text-shadow: 0 0 5px #ffb347;
      
    }
    .navbar li a.active {
     color: #ffd700;
     text-shadow: 0 0 5px #ffd700;
}
/* ===== Responsive Navbar Fix ===== */
#menu-icon {
  font-size: 3rem;
  color: var(--text-color);
  display: none;
  cursor: pointer;
  z-index: 101;
}

/* Default desktop layout */
.navbar {
  display: flex;
  gap: 2rem;
  list-style: none;
  transition: 0.3s ease;
}

/* Tablet and phone view (General adjustments) */
@media (max-width: 992px) {
  #menu-icon {
    display: block;
  }
  
  .header {
    padding: 2rem 5%; /* Reduced header padding */
  }

  .navbar {
    position: absolute;
    top: 100%;
    right: -100%;
    width: 100%;
    background: rgba(20, 20, 40, 0.95);
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 2rem 0;
    gap: 2rem;
    transition: right 0.4s ease;
  }

  .navbar.active {
    right: 0;
  }

  .navbar a {
    display: block;
    font-size: 1.8rem;
    color: var(--text-color);
  }

  .navbar a:hover {
    color: var(--main-color);
  }
  
  /* **New/Modified Rules for Tablet/Mobile Layout** */
  section {
    padding: 8rem 5% 5rem; /* Adjust section padding */
  }

  /* Home Section Adjustments */
  .home {
    gap: 4rem; /* Reduced gap */
  }

  /* Fix for background rectangle on mobile */
  .home-rectangle {
    width: 100%; /* Make it full width on mobile/tablet */
    height: 40%;
    top: 60%;
    right: 0;
    border-top-left-radius: 20%;
    border-bottom-left-radius: 0;
    border-top-right-radius: 20%; /* New border radius */
  }
}

/* Tablet scaling */
@media (max-width: 768px) {
  .home {
    flex-direction: column-reverse; /* Put content first */
    text-align: center;
    justify-content: space-around;
  }

  .home-content h1 {
    font-size: 5rem; /* Slightly smaller */
  }
  .home-content h3 {
    font-size: 3rem; /* Slightly smaller */
  }

  .home-img {
    margin-bottom: 2rem;
  }
  .home-img img {
    width: 50vw; /* Adjust image size */
    max-width: 250px;
    border: 15px solid #0f0f0f; /* Smaller border */
  }

  .home-rectangle {
    height: 50%; /* Adjusted height for column layout */
    top: 50%;
  }

  .about {
    flex-direction: column;
    text-align: center;
    gap: 4rem;
  }

  .about-content {
    text-align: center;
  }

  .about-img img {
    width: 50vw; /* Adjust image size */
    max-width: 250px;
    border: 15px solid #0f0f0f; /* Smaller border */
  }

  /* Fix for background rectangle on mobile */
  .about-rectangle {
    width: 100%; /* Make it full width on mobile/tablet */
    height: 30%;
    top: 70%;
    left: 0;
    border-top-right-radius: 20%;
    border-bottom-right-radius: 0;
    border-top-left-radius: 20%; /* New border radius */
  }

  .about-content h2 {
    text-align: center; /* Center heading */
  }

  .about-content p {
    text-align: left; /* Keep paragraph left-aligned for readability */
    max-width: 600px;
    margin: 2rem auto 3rem;
  }

  .text-animation {
    min-width: unset; /* Remove fixed min-width for flexibility */
  }
  
  .bento-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    grid-auto-rows: minmax(180px, auto); /* Adjust row height for smaller items */
  }
}
@media (max-width: 768px) {
  .home-img img,
  .about-img img {
    transform: scale(1.5);
    transition: transform 0.5s ease-in-out;
    object-fit: cover;

    }
}

/* Phone scaling */
@media (max-width: 480px) {
  html {
    font-size: 50%; /* Further reduction in base size */
  }
  
  .logo {
    font-size: 2.5rem;
  }

  .home-content h1 {
    font-size: 4rem;
  }

  .home-content h3 {
    font-size: 2.5rem;
  }

  .social-icons a {
    width: 4rem;
    height: 4rem;
    font-size: 2rem;
    margin: 2rem 1rem 2rem 0;
  }
  
  /* HIDE RECTANGLES AS REQUESTED */
  .home-rectangle {
    display: none; 
  }
  
  .about-rectangle {
    display: none;
  }
  
  .heading {
    font-size: 3rem;
  }

  .bento-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: minmax(150px, auto); /* Adjust row height for smaller items */
    gap: 15px;
  }

  .bento-item.wide,
  .bento-item.big {
    grid-column: span 1; /* All items become single column */
    grid-row: span 1;
  }

  .skills-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}



section{
    min-height: 100vh;
    padding: 10rem 9% 10rem;

}
.home{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8rem;
   
}
.home-rectangle{
    position: absolute;
    background: var(--gradient);
    border-top-left-radius: 10%;
    border-bottom-left-radius: 10%;
    width: 30%;
    height: 100%;
    top:0;
    right: 0;
    z-index: 2;
    transition: all 0.5s ease; /* Added transition */
}
.home-content h3{
    font-size: 3.2rem;
    font-weight: 700;

}
.home-content h1{
    font-size: 8rem;
    font-weight: 700;
    line-height: 1.3;

}
.home-img{
    display: grid;
    place-items: center;
    z-index: 2;
   
    
}
.img-border {
    padding: 8px; /* border thickness */
    border-radius: 50%;
    background: var(--gradient);
    display: inline-block;

}
.home-img img{
    position: relative;
    background-color:#0f0f0f;
    border: 20px solid #0f0f0f;
    width: 32vw;
    border-radius: 50%;
    cursor: pointer;
    z-index: 1;

}
.home-content p{
    font-size: 1.8rem;
    font-weight: 500;
    max-width: 650px;
}
.social-icons a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4.5rem;
    height: 4.5rem;
    font-size: 2.5rem;
    margin: 3rem 1.5rem 3rem 0;
    transition: 0.3s ease;
    color: var(--bg-color);

    border-radius: 50%; /* Makes it circular */
    padding: 0.5rem;    /* Thickness of the border */
    background:
        var(--gradient) padding-box, /* Outer gradient border */
        var(--bg-color) border-box;   /* Inner solid background */
    background-clip: padding-box, border-box;
    border: 0.2rem solid transparent; /* Needed for background-clip to work */
}

.social-icons a:hover{
    color: #ffb347;
    transform: scale(1.3)translateY(-5px);
    background: linear-gradient(var(--bg-color), var(--bg-color)), /* inner fill */
        var(--gradient); 
         background-origin: border-box;
    background-clip: padding-box, border-box;

}
.btn{
    display: inline-block;
    padding: 1rem 2.8rem;
    background: var(--gradient);
    border-radius: 4rem;
    font-size: 1.6rem;
    color: white;
    border: 2px solid transparent;
    letter-spacing:0.1rem ;
    font-weight: 600;
    transition: 0.3s ease;
    cursor: pointer;

}
.btn:hover {
    transform: scale(1.2);
    color: var(--accent-color);

    /* Transparent border so gradient can show */
    border: 2px solid transparent;
    border-radius: 4rem; /* must match normal state */

    /* Two-layer background: inner fill + gradient border */
    background-image:
        linear-gradient(var(--bg-color), var(--bg-color)), /* inner fill */
        var(--gradient); /* border gradient */
    background-origin: border-box;
    background-clip: padding-box, border-box;
}


.text-animation{
    font-size: 34px;
    font-weight: 600;
    min-width: 280px;

}
.text-animation span{
    position:relative;


}
.text-animation span::before{
    content:'Computational Biologist';
    background: var(--gradient);
    animation: words 20s infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;

}
.text-animation span::after{
    content:'';
    background: var(--gradient);
    position: absolute;
    width:calc(100% + 8px);
    height:100%;
    border-left: 2px solid #f1f1f1;
    right: -8px;
    animation: cursor 0.6s infinite, typing 20s steps(14)infinite;

}

@keyframes cursor{
    to{
        border-left: 2px solid var(--main-color);

    }
    
}
@keyframes words{
    0%,
    20%{
        content:'Computational Biologist';
    }
    21%,
    40%{
        content:'Bioinformatician';
    }
    41%,
    60%{
        content: 'Biochemist';

    }
    61%,
    80%{
        content: 'Web Developer';
    }
    81%,
    100%{
        content: 'Fitness Enthusiast';
    }
}
@keyframes typing{
    10%,
    15%,
    30%,
    35%,
    50%,
    55%,
    70%,
    75%,
    90%,
    95%{
        width:0 ;
    }
    5%,
    20%,
    40%,
    45%,
    60%,
    65%,
    80%,
    85%{
        width:calc(100% + 8px);
    }

}

.dna-line {
    position: absolute;
    width: 200%; /* make extra wide for scrolling */
    white-space: nowrap;
    font-size: 1.4rem;

    /* gradient text */
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;

    text-shadow: none; /* optional: remove old gold shadow */
    z-index: -2;
    opacity: 0.05; /* make it subtle */
}


@keyframes scroll-left {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

@keyframes scroll-right {
    0% { transform: translateX(-50%); }
    100% { transform: translateX(0); }
}
#welcome-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: radial-gradient(circle at center, #1a1a1a, #0d0d0d);
  background-color: #0d0d0d;
  color: #ffcc70;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  font-family: 'Montserrat', sans-serif;
  z-index: 9999;
  transition: opacity 0.5s ease;
}


@keyframes fadeOutLoader {
  to { opacity: 0; visibility: hidden; pointer-events: none; }
}

.welcome-text {
  opacity: 1;
  transition: opacity 0.37s ease;
  text-shadow: 0 0 12px rgba(255, 182, 193, 0.6);
}
.welcome-text.visible {
  opacity: 1;
}



@keyframes fadeInOut {
  0% { opacity: 0; transform: translateY(20px); }
  50% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-20px); }
}
.about{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10rem;
    background: var(--bg-color);

}
.about-rectangle{
    position: absolute;
    left: 0;
    height: 100%;
    border-top-right-radius: 10%;
    border-bottom-right-radius: 10%;
    background: var(--gradient);
    width: 25%;
    transition: all 0.5s ease; /* Added transition */
}
.about-img{
    border-radius: 50%;
    display: grid;
    place-items: center;
   

}
.about-img img{
    position: relative;
    width: 30vw;
    border-radius: 50%;
    border: 25px solid #0f0f0f;
    cursor: pointer;

}
.heading{
    text-align: center;
    font: size 8rem;
}
.about-content h2{
    text-align: left;
    line-height: 1.5;

}
.about-content h3{
    font-size: 2.6rem;

}
.about-content p{

        font-size: 1.6rem;
        margin:2rem 0 3rem ;

}
.about-content .text-animation span::before{
    content: 'Web Devoloper';
    background: var(--gradient);
    animation: words 20s infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;

}
.text-animation span::after{
    content:'';
    background: var(--gradient);
    position: absolute;
    width:calc(100% + 9px);
    height:100%;
    border-left: 2px solid #f1f1f1;
    right: -8px;
    animation: cursor 0.6s infinite, typing 20s steps(14)infinite;

}
.theme-switcher {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 999999;
}

.theme-btn {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  outline: none;
  transition: transform 0.2s ease;
  font-size: 18px;
  font-weight: bold;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  /* UPDATED TO USE THE ACTIVE GRADIENT */
  background: var(--gradient);
  

}

.theme-btn:hover {
  transform: scale(1.2);
}

@media (max-width: 768px) {
  .theme-switcher {
    bottom: 15px; 
    
    /* CRITICAL: Must be 'auto' to ensure 'left' is calculated from the viewport */
    right: auto; 
    
    /* Re-enforce the horizontal position based on the visible viewport width (100vw - 55px) */
    left: calc(100vw - 55px); 
    
    flex-direction: row;
    z-index: 999999; 
  }
}


body {
  margin: 0;
  font-family: "Inter", sans-serif;
  background: #0d0f1a;
  color: #fff;
}

.bento-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  grid-auto-rows: 220px;
  gap: 20px;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  padding: 60px 5%;
  position: relative;
  z-index: 1;
}


/* Card styles */
.bento-item {
  background: rgba(30, 30, 60, 0.6);
  border-radius: 20px;
  padding: 20px;
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 25px rgba(0,0,0,0.5);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bento-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 35px rgba(0,0,0,0.7);
}

/* Sizes */
.wide {
  grid-column: span 2;
}

.big {
  grid-column: span 2;
  grid-row: span 2;
}

.dynamic-glow {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--gradient);
  filter: blur(220px);
  opacity: 0.25;
  z-index: 0;
  pointer-events: none;
  transition: background 1s ease;
}
.bento-item {
  position: relative;
  background: rgba(15, 15, 25, 0.95);
  border-radius: 20px;
  padding: 20px;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.8);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden;
  z-index: 1;
}

.bento-item::before {
  content: '';
  position: absolute;
  inset: -3px; /* extends glow slightly outside card */
  border-radius: 22px;
  background: var(--active-gradient, var(--gradient));
  opacity: 0.6;
  filter: blur(25px);
  z-index: -1;
  transition: background 0.6s ease, filter 0.4s ease, opacity 0.4s ease;
  pointer-events: none;
}

.bento-item:hover::before {
  filter: blur(35px);
  opacity: 0.9;
}

.bento-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 0 25px rgba(0, 0, 0, 0.9);
}
/* ===== Skills Section ===== */
.skills {
  min-height: 100vh;
  padding: 10rem 9%;
  background: var(--bg-color);
  position: relative;
  overflow: hidden;
}

.skills .heading {
  text-align: center;
  font-size: 4rem;
  margin-bottom: 4rem;
}

.skills-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
}

.skill-card {
  background: rgba(30, 30, 60, 0.6);
  backdrop-filter: blur(15px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  padding: 3rem 2rem;
  text-align: center;
  box-shadow: 0 8px 25px rgba(0,0,0,0.4);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.skill-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 35px rgba(0,0,0,0.6);
}

.skill-card i {
  font-size: 4rem;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 1.5rem;
}

.skill-card h3 {
  font-size: 2rem;
  color: var(--text-color);
  margin-bottom: 1rem;
}

.skill-card p {
  font-size: 1.5rem;
  color: #dcdcdc;
  line-height: 1.5;
}
