body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background: #f4f7fb;
  margin: 0;
  padding: 0;
  transition: background 0.3s, color 0.3s;
  height:100vh;
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem;
  flex-wrap: wrap;
   position: sticky;
  top: 0;
  z-index: 1000;
  background-color: #fff;
  border-radius: 10px;
  margin-bottom: 1.5rem;
}
.hamburger-container {
  display: none;
  flex-direction: column;
  /* justify-content: center; */
  cursor: pointer;
  gap: 5px;
  padding: 10px;
}

.hamburger-container .bar {
  width: 25px;
  height: 3px;
  background-color: #333;
  transition: 0.3s;
}



/* Responsive styles */
@media (max-width: 768px) {
  .hamburger-container {
    display: flex;
  }

 
  .navbar {
    display: flex;
   justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    position: relative;
  }

  .navbar-right-links {
    display: none;
    position: absolute;
    top: 70px;              /* adjust depending on navbar height */
    right: 10px;  
    margin:15px;          /* aligns the box to the right */
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    padding: 1rem;
    flex-direction: column;
    gap: 0.75rem;
    z-index: 1000;
    width: max-content;     /* only as wide as content */
    min-width: 150px;  
  }

  .navbar-right-links.show {
    display: flex;
  }

  .nav-item {
    display: inline-flex;          
    align-items: center;           
    justify-content: center;
    padding: 1rem;
    width:10rem;
    font-size: 1rem; 
  }
}
.dark-toggle {
  color:#1a1a1a;
  border: none;
  cursor: pointer;
  padding: 0.6rem 1.2rem;
  border-radius: 10px;
  transition: all 0.25s ease;
  }

  .dark-mode .navbar {
    background: rgba(17, 24, 39, 0.9);
    border-bottom: 1px solid #374151;
}

  body.dark-mode .nav-item {

    color: #e0e0e0;
  }
  

/* Example text inside open-source.html cards */

body.dark-mode .repo h3 {
  color:#4CC9F0;
}


body.dark-mode .repo p {
  color:#D1D5DB;
}

body.dark-mode .repo small {
  color: #E0E0E6;
  /* background: #2A2D3E; soft gray so it's readable */
}

body.dark-mode .repo strong {
  color: #f9fafb;
  /* background: #2A2D3E; brighter for "Example:" label */
}


/* Dark Mode Global */
body.dark-mode {
  background: #111827;
  color: #f3f4f6;
}

/* Navbar
body.dark-mode .landing-nav {
  background: rgba(31, 41, 55, 0.95);
  border-bottom: 1px solid #374151;
}
body.dark-mode .nav-brand span,
body.dark-mode .nav-links a {
  color: #f3f4f6;
} */

/* Header */
body.dark-mode .open-source-header {
  background: linear-gradient(135deg, #1e40af, #1e3a8a);
  color: white;
}
body.dark-mode .controls input {
  background: #1f2937;
  color: #f3f4f6;
  border: 1px solid #374151;
}



/* Open-source Items */
body.dark-mode .repo {
  background: #1f2937;
  border: 1px solid #374151;
  color: #f3f4f6;
}

body.dark-mode .contribute {
  background: linear-gradient(135deg, #0f172a, #1e293b);
}

body.dark-mode .contribute-card {
  background: #1f2937;
  border: 1px solid #374151;
  color: #f3f4f6;
}


body.dark-mode .contribute-card h3 {
  color:#4CC9F0;
}


body.dark-mode .contribute-card p {
  color:#D1D5DB;
}

body.dark-mode .contribute-card small {
  color: #E0E0E6;
  /* background: #2A2D3E; soft gray so it's readable */
}

body.dark-mode .contribute-card strong {
  color: #f9fafb;
  /* background: #2A2D3E; brighter for "Example:" label */
}

body.dark-mode .acknowledge {
  background: transparent;
}

body.dark-mode .ack-card {
  background: #1f2937;
  border: 1px solid #374151;
  color: #f3f4f6;
}

body.dark-mode .ack-card h3 {
  color:#4CC9F0;
}

body.dark-mode .ack-card p {
  color:#D1D5DB;
}

body.dark-mode .ack-card small {
  color: #E0E0E6;
  /* background: #2A2D3E; soft gray so it's readable */
}

body.dark-mode .ack-card strong {
  color: #f9fafb;
  /* background: #2A2D3E; brighter for "Example:" label */
}

/* Footer */
body.dark-mode .modern-footer {
  background: linear-gradient(135deg, #1a202c, #2d3748);
}

body.dark-mode .tags span {
  color: #f3f4f6;
  background: #1f2937;
  border: 1px solid #374151;
}
body.dark-mode .tags span:hover {
  background: #374151;
}

body.dark-mode div.repo a {
  color: #f3f4f6;
  background: #1f2937;
  border: 1px solid #374151;
}
body.dark-mode div.repo a:hover {
  background: #374151;
}



/* Dark Mode Footer Styles */
body.dark-mode .modern-footer {
  background: linear-gradient(135deg, #1a202c, #2d3748);
}

body.dark-mode .footer-section h3,
body.dark-mode .footer-section h4 {
  color: #e0e0e0;
}

body.dark-mode .footer-section h4 {
  border-bottom-color: rgba(224, 224, 224, 0.2);
}

body.dark-mode .footer-links a {
  color: rgba(224, 224, 224, 0.8);
}

body.dark-mode .footer-links a:hover {
  color: #90cdf4;
}

body.dark-mode .social-links a {
  background: rgba(224, 224, 224, 0.1);
  color: #e0e0e0;
}

body.dark-mode .social-links a:hover {
  background: rgba(144, 205, 244, 0.2);
  color: #90cdf4;
}

body.dark-mode .footer-bottom {
  background: rgba(0, 0, 0, 0.3);
  border-top-color: rgba(224, 224, 224, 0.1);
}

 /* Reset + Base */
      * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
      }
      body {
        font-family: "Segoe UI", sans-serif;
        background: #f8fafc;
        color: #1e293b;
        line-height: 1.6;
      }
      a {
        text-decoration: none;
        color: inherit;
      }
      h1,
      h2,
      h3,
      h4 {
        font-weight: 700;
      }

      /* Floating Back Button */
      .back-home {
        position: fixed;
        top: 20px;
        left: 20px;
        background: #fff;
        padding: 10px 16px;
        border-radius: 30px;
        font-weight: bold;
        border: 1px solid #cbd5e1;
        color: #1e293b;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        transition: 0.3s;
        z-index: 1000;
      }
      .back-home:hover {
        transform: scale(1.05);
        background: #e2e8f0;
      }

      /* Header */
      header {
        text-align: center;
        padding: 80px 20px 50px;
        background: linear-gradient(135deg, #4a90e2, #357abd);
        color: #fff;
        border-radius: 0 0 60px 60px;
        box-shadow: 0 6px 20px rgba(0,0,0,0.15);
        animation: fadeDown 1s ease;
      }
      header::after {
        content: "";
        position: absolute;
        bottom: -30px;
        left: 50%;
        transform: translateX(-50%);
        width: 80%;
        height: 60px;
        background: transparent;
        border-radius: 50%;
        z-index: -1;
      }
      header h1 {
        font-size: 3rem;
        margin-bottom: 15px;
        letter-spacing: 1px;
      }
      header h2 {
        font-size: 1.2rem;
        font-weight: 400;
        opacity: 0.9;
        color: #e0f2fe;
      }

      /* Controls */
      .controls {
        text-align: center;
        margin: 40px 0;
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
        justify-content: center;
      }
      .controls input {
        padding: 10px 16px;
        border-radius: 30px;
        border: 1px solid #cbd5e1;
        background: #fff;
        color: #1e293b;
        width: 240px;
      }
      .controls button {
        padding: 10px 18px;
        border: none;
        border-radius: 30px;
        background: #3b82f6;
        color: #fff;
        font-weight: 500;
        cursor: pointer;
        transition: 0.3s;
        border: 1px solid #3b82f6;
      }
      .controls button:hover {
        background: #2563eb;
        border-color: #2563eb;
      }

      /* Repo Cards */
      .repo-container {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 25px;
        padding: 20px;
        max-width: 1200px;
        margin: auto;
      }
      .repo {
        background: #fff;
        border: 1px solid #e2e8f0;
        padding: 25px;
        border-radius: 20px;
        box-shadow: 0 6px 18px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  transform: translateY(40px);
  animation: fadeUp 0.6s ease forwards;
        position: relative;
        overflow: hidden;
        animation: fadeUp 0.6s ease both;
      }
      .repo:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 12px 28px rgba(74,144,226,0.25);
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(40px); }
  to { opacity: 1; transform: translateY(0); }
}
      .repo h3 {
        margin-bottom: 12px;
        color: #2563eb;
        font-size: 1.2rem;
      }
      .repo p {
        font-size: 14px;
        color: #1e293b;
        margin-bottom: 12px;
      }
      .repo a {
        display: inline-block;
        background: #3b82f6;
        color: #fff;
        padding: 7px 16px;
        border-radius: 20px;
        font-size: 14px;
        font-weight: 500;
        transition: 0.3s;
      }
      .repo a:hover {
        background: #2563eb;
      }
      .repo .tags {
        margin-top: 10px;
      }
      .repo .tags span {
        background: #60a5fa;
        color: whitesmoke;
        padding: 5px 12px;
        border-radius: 20px;
        font-size: 12px;
        margin: 3px;
        display: inline-block;
      }

      /* Contribute Section */
      .contribute {
        padding: 70px 20px;
        background: #e0f2fe;
        text-align: center;
        border-radius: 50px;
        margin: 60px auto;
        max-width: 1100px;
      }
      .contribute h2 {
        color: #2563eb;
        margin-bottom: 40px;
        font-size: 2rem;
      }
      .contribute-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        gap: 25px;
        max-width: 1000px;
        margin: auto;
      }
      .contribute-card {
        background: #fff;
        padding: 25px;
        border-radius: 16px;
        box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
        transition: 0.3s;
      }
      .contribute-card:hover {
        transform: translateY(-5px) scale(1.03);
      }
      .contribute-card h3 {
        margin-bottom: 12px;
        color: #2563eb;
      }
      .contribute-card p {
        font-size: 14px;
        color: #1e293b;
      }

      /* Acknowledgements */
      .acknowledge {
        padding: 70px 20px;
        background: #f0f9ff;
        text-align: center;
      }
      .acknowledge h2 {
        color: #2563eb;
        margin-bottom: 40px;
        font-size: 2rem;
      }
      .ack-grid {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 25px;
      }
      .ack-card {
        background: linear-gradient(135deg, #60a5fa, #3b82f6);
        color: #fff;
        padding: 30px;
        border-radius: 20px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
        transition: 0.3s;
        max-width: 280px;
      }
      .ack-card:hover {
        transform: translateY(-8px) rotate(-1deg);
      }
      .ack-card h3 {
        margin-bottom: 12px;
      }
      .ack-card p {
        font-size: 14px;
        opacity: 0.9;
      }

      /* Footer */
      .modern-footer {
        width: 100vw;
        /* Full viewport width */
        margin-left: calc(-50vw + 50%);
        /* Center it if inside a constrained container */
        background: linear-gradient(135deg, #1f3c88, #2c5aa0);
        color: #fff;
        padding: 60px 20px 20px;
        border-radius: 25px 25px 0 0;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.2);
        overflow-x: hidden;
      }

      .footer-top {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 2rem;
        margin-bottom: 30px;
      }

      .footer-brand h2 {
        font-size: 10px;
        margin-bottom: 10px;
        display: flex;
        align-items: center;
        flex-direction: column;
      }

      .footer-brand h2 i {
        margin-right: 10px;
        font-size: 1rem;
        vertical-align: middle;
      }

      .footer-brand p {
        font-size: 0.95;
        font-weight: 300;
        line-height: 1.5;
        opacity: 0.9;
      }

      .footer-links-section h4 {
        font-size: 1.1rem;
        margin-bottom: 10px;
        border-bottom: 2px solid rgba(255, 255, 255, 0.3);
        padding-bottom: 5px;
      }

      .footer-links-section ul {
        list-style: none;
        padding: 0;
        margin: 0;
      }

      .footer-links-section ul li {
        margin-bottom: 8px;
      }

      .footer-links-section ul li a {
        color: rgba(255, 255, 255, 0.8);
        text-decoration: none;
        display: flex;
        align-items: center;
        gap: 8px;
        transition: 0.3s;
      }

      .footer-links-section ul li a:hover {
        color: #fff;
        transform: translateX(5px);
      }

      .social-icons {
        display: flex;
        gap: 10px;
        margin-top: 5px;
      }

      .social-icons a {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        background: rgba(255, 255, 255, 0.1);
        border-radius: 50%;
        color: #fff;
        transition: 0.3s;
      }

      .social-icons a:hover {
        background: #fff;
        color: #2c5aa0;
        transform: scale(1.1);
      }

      .footer-bottom {
        text-align: center;
        border-top: 1px solid rgba(255, 255, 255, 0.2);
        padding-top: 15px;
        font-size: 0.9rem;
        opacity: 0.8;
      }

      .footer-card {
        flex: 1 1 200px;
        background: rgba(255, 255, 255, 0.1);
        border-radius: 12px;
        padding: 20px;
        min-width: 200px;
      }

      .footer-card ul {
        list-style: none;
        padding: 0;
        margin: 0;
      }

      .footer-card ul li {
        margin-bottom: 8px;
      }

      .footer-card ul li a {
        color: rgba(255, 255, 255, 0.8);
        text-decoration: none;
        display: flex;
        align-items: center;
        gap: 8px;
        transition: 0.3s;

        padding: 5px;
        padding-left: 20px;
      }

      .footer-card ul li a:hover {
        color: #fff;
        transform: translateX(5px);
      }

      @media (max-width: 768px) {
        .footer-top {
          grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
          gap: 3rem;
        }

        .footer-brand h2 {
          font-size: 1.5rem;
        }

        .footer-links-section h4 {
          font-size: 1rem;
        }

        .footer-links-section ul li a {
          font-size: 0.95rem;
        }

        .social-icons a {
          width: 35px;
          height: 35px;
        }
      }

      @media (max-width: 756px) and (min-width: 730px),
      (max-width: 601px) and (min-width: 540px) {
        .footer-card {
          gap: 4rem;
        }
      }

      @media (max-width: 480px) {
        .footer-top {
          grid-template-columns: 1fr;
          text-align: center;
        }

        .social-icons {
          justify-content: center;
        }

        .footer-links-section ul li a {
          justify-content: center;
        }
      }

      .footer-bottom .heart {
        color: inherit;
      }

      /* Back to Top Button Styles */
      #backToTop {
        height: 60px;
        width: 60px;
        position: fixed;
        bottom: 30px;
        right: 30px;
        z-index: 1000;
        background: linear-gradient(135deg, #0077b5, #4facfe);
        color: white;
        border: none;
        border-radius: 50%;
        padding: 15px;
        font-size: 18px;
        cursor: pointer;
        display: none;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
        transition: transform 0.3s ease, opacity 0.3s ease;
      }

      #backToTop:hover {
        transform: scale(1.1);
        opacity: 0.9;
        box-shadow: rgba(0, 0, 0, 0.8);
      }

      @media (max-width: 600px) {
        #backToTop {
          padding: 12px;
          font-size: 16px;
          bottom: 20px;
          right: 20px;
        }
      }

      /* Animations */
      @keyframes fadeUp {
        from {
          opacity: 0;
          transform: translateY(20px);
        }
        to {
          opacity: 1;
          transform: translateY(0);
        }
      }

      /* Responsive */
      @media (max-width: 768px) {
        header h1 {
          font-size: 2.2rem;
        }
        .controls input {
          width: 100%;
        }
      }