/* CSS Variables for Themes */
:root {
    --primary-color: #000dff;
    --secondary-color: #fff;
    --background-color: #f0f0f0;
    --text-color: #333;
    --nav-bg: rgba(255, 255, 255, 0.8);
    --nav-bg-scrolled: rgba(255, 255, 255, 1);
    --hero-gradient-start: #6b73ff;
    --hero-gradient-end: #000dff;
    --footer-bg: #333;
  }
  
  body.dark-mode {
    --primary-color: #64ffda;
    --secondary-color: #0a192f;
    --background-color: #0a192f;
    --text-color: #ccd6f6;
    --nav-bg: rgba(10, 25, 47, 0.8);
    --nav-bg-scrolled: rgba(10, 25, 47, 1);
    --hero-gradient-start: #112240;
    --hero-gradient-end: #233554;
    --footer-bg: #112240;
  }
  
  /* Global Styles */
  html, body {
    font-family: 'Poppins', sans-serif;
    background: var(--background-color);
    color: var(--text-color);
    scroll-behavior: smooth;
    overflow-x: hidden;
  }
  
  /* Navigation Bar */
  #navbar {
    background: var(--nav-bg);
    transition: background 0.3s ease;
  }
  #navbar.scrolled {
    background: var(--nav-bg-scrolled);
  }
  
  /* Hero Section with Rotating Radial Background */
  #hero {
    position: relative;
    min-height: 100vh;
    background: linear-gradient(135deg, var(--hero-gradient-start) 0%, var(--hero-gradient-end) 100%);
    color: var(--secondary-color);
    overflow: hidden;
    padding-top: 60px; /* avoid overlap with fixed navbar */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
  }
  #hero::before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 60%);
    animation: rotate 20s linear infinite;
  }
  @keyframes rotate {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
  }
  #hero .hero-content {
    z-index: 2;
    position: relative;
  }
  #hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
  }
  #hero p {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 30px;
  }
  
  /* Typed Text Effect */
  #typed-text {
    font-weight: 600;
    border-right: 2px solid var(--secondary-color);
    white-space: nowrap;
    overflow: hidden;
  }
  
  /* Scroll Down Indicator */
  .scroll-down {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    cursor: pointer;
    animation: bounce 2s infinite;
  }
  .scroll-down span {
    display: block;
    width: 30px;
    height: 30px;
    border-bottom: 2px solid var(--secondary-color);
    border-right: 2px solid var(--secondary-color);
    transform: rotate(45deg);
    margin: 0 auto;
  }
  @keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-10px); }
    60% { transform: translateX(-50%) translateY(-5px); }
  }
  
  /* About Section */
  #about {
    background: var(--background-color);
    padding: 60px 0;
  }
  #about h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
  }
  #about p {
    max-width: 800px;
    margin: 0 auto 30px;
    line-height: 1.6;
  }
  .counter {
    font-size: 3rem;
    font-weight: 600;
    color: var(--primary-color);
  }
  
  /* Tools Section */
  #tools {
    background-color: #f8f9fa;
    padding: 50px 0;
    margin-top: 40px;
  }
  
  #tools h2 {
    font-size: 2.5rem;
    margin-bottom: 30px;
    color: #343a40;
  }
  
  #tools .card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin: 10px;
  }
  
  #tools .card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
  }
  
  #tools .card-title {
    font-size: 1.25rem;
    color: #007bff;
  }
  
  #tools .btn-primary {
    background-color: #007bff;
    border-color: #007bff;
    transition: background-color 0.3s ease, border-color 0.3s ease;
  }
  
  #tools .btn-primary:hover {
    background-color: #0056b3;
    border-color: #0056b3;
  }
  
  #tools .text-center {
    color: #6c757d;
    font-size: 1.1rem;
  }

  #tools div.container {
    border: 1px solid black;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    padding: 20px;
    background-color: #eaecee;
    border-radius: 10px;
  }

  /* Games Section */
  #games {
    padding: 50px;
    margin: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
  }
  
  /* Social Icons */
  .social-icons {
    display: flex;
    justify-content: center;
    gap: 20px;
  }
  .social-icons a {
    color: var(--primary-color);
    font-size: 1.8rem;
    transition: transform 0.3s, color 0.3s;
  }
  .social-icons a:hover {
    transform: scale(1.2);
    color: var(--nav-bg-scrolled);
  }
  
  /* Skills Section */
  #skills {
    padding: 60px 0;
    background: var(--background-color);
  }
  #skills h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
  }
  #skills p {
    max-width: 800px;
    margin: 0 auto 30px;
  }
  #skills .skills-box {
    border-bottom: 2px solid #64ffda; padding-bottom: 10px;
  }
  #skills .skills-box h5 {
    font-size: 1.5rem; color: #000dff;
  }
  #skills .skills-box p {
    color: #666;
  }
  
  /* Testimonials Section */
  #testimonials {
    padding: 60px 0;
  }
  .testimonial-card {
    border: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
    background: var(--secondary-color);
    color: var(--text-color);
  }
  .testimonial-card:hover {
    transform: translateY(-5px);
  }
  .testimonial-message {
    font-style: italic;
    font-size: 1rem;
  }
  .testimonial-name {
    font-weight: 600;
    margin-top: 10px;
  }
  .testimonial-designation {
    color: var(--primary-color);
    font-size: 0.9rem;
  }
  
  /* Contact Section */
  #contact {
    background-color: #f8f9fa; /* Light background color */
    padding: 60px 0; /* Add padding for spacing */
    border-top: 1px solid #e9ecef; /* Subtle border at the top */
  }
  
  #contact h5 {
    font-size: 2rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 30px;
  }
  
  #contactForm {
    max-width: 600px;
    margin: 0 auto; /* Center the form */
  }
  
  #contactForm .form-control {
    border-radius: 5px;
    border: 1px solid #ced4da;
    margin-bottom: 20px;
    padding: 10px;
    font-size: 1rem;
  }
  
  #contactForm button {
    background-color: #007bff;
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    font-size: 1rem;
    color: #fff;
    transition: background-color 0.3s ease;
  }
  
  #contactForm button:hover {
    background-color: #0056b3;
  }
  
  #formFeedback {
    color: #28a745; /* Green color for success messages */
    font-size: 1rem;
    margin-top: 20px;
  }
  
  /* Footer Styles */
  footer {
    background: var(--footer-bg);
    color: var(--secondary-color);
  }
  footer p {
    margin: 5px 0;
  }
  footer .social-icons {
    margin: 10px 0;
  }
  
  /* Scroll to Top Button */
  #scrollTopBtn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 99;
    border: none;
    outline: none;
    background-color: var(--primary-color);
    color: var(--secondary-color);
    cursor: pointer;
    padding: 10px 15px;
    border-radius: 50%;
    font-size: 18px;
    display: none;
    transition: background-color 0.3s;
  }
  #scrollTopBtn:hover {
    background-color: var(--nav-bg);
  }
  
  /* Fade-in Animation for Sections */
  .fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
  }
  .fade-in.visible {
    opacity: 1;
    transform: translateY(0);
  }
  
/* Other Styles */

.card {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s;
}

.card:hover {
    transform: translateY(-5px);
}

.card-body {
    padding: 20px;
}

/* Password Generator */
.form-container { max-width: 400px; margin: auto; padding: 20px; border: 1px solid #ccc; border-radius: 10px; }
.form-container h2 { text-align: center; }
.form-container label { display: block; margin: 10px 0 5px; }
.form-container input[type="text"] { width: 100%; padding: 8px; margin: 10px 0; border: 1px solid #ccc; border-radius: 5px; }
.form-container input[type="checkbox"] { margin-right: 10px; }
.form-container button { background-color: #007BFF; color: #fff; border: none; padding: 10px 20px; border-radius: 5px; cursor: pointer; }
.form-container button:hover { background-color: #0056b3; }
.result { text-align: center; margin-top: 20px; }
.strength { font-weight: bold; }