/* -----------------------------
   Root & Variables
----------------------------- */
:root {
    --primary-color: #f97316;
    --bg-color: #FDFBF8;
    --text-color: #1f2937;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --white: #ffffff;
}

/* -----------------------------
   Global Styles
----------------------------- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

/* -----------------------------
   Container
----------------------------- */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* -----------------------------
   Header
----------------------------- */
header {
    position: sticky;
    top: 0;
    z-index: 50;
    background-color: rgba(253, 251, 248, 0.9);
    backdrop-filter: blur(8px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease-in-out;
}

header .header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo .icon svg {
    color: var(--primary-color);
}

.logo h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--gray-900);
}

nav {
    display: flex;
    gap: 2rem;
}

nav a {
    font-weight: 500;
    color: var(--gray-700);
    position: relative;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease-in-out;
}

nav a:hover::after {
    width: 100%;
}

.cta-btn {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    font-weight: 700;
    padding: 0.75rem 1.5rem;
    border-radius: 9999px;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 5px 15px rgba(249, 115, 22, 0.2);
}

.cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(249, 115, 22, 0.3);
}

.menu-btn {
    display: none;
    font-size: 2rem;
    background: none;
    border: none;
}

/* -----------------------------
   Hero Section
----------------------------- */
.hero {
    position: relative;
    padding: 6rem 0;
    text-align: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    opacity: 0.15;
    z-index: -1;
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 800px;
    margin: 0 auto;
    animation: fadeInScale 1s ease-out forwards;
}

.hero-content h1 {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 900;
    margin-bottom: 1rem;
    color: var(--gray-900);
}

.hero-content p {
    font-size: clamp(1rem, 2vw, 1.125rem);
    color: var(--gray-600);
    margin-bottom: 2rem;
}

.hero-content a {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    font-weight: 700;
    padding: 1rem 2rem;
    border-radius: 9999px;
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

.hero-content a:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 20px rgba(0, 0, 0, 0.2);
}

/* -----------------------------
   Trusted Institutions
----------------------------- */
.institutions {
    padding: 4rem 0;
    text-align: center;
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.institutions h3 {
    font-size: clamp(1.5rem, 3vw, 1.875rem);
    font-weight: 700;
    margin-bottom: 2rem;
}

.institutions-logos {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 2rem;
}

.institutions-logos img {
    height: 4rem;
    transition: transform 0.3s;
}

.institutions-logos img:hover {
    transform: scale(1.05);
}

/* Make Aakash logo circular */
#aakash {
    border-radius: 50%;
    object-fit: contain;
}

/* -----------------------------
   Key Highlights
----------------------------- */
.highlights {
    padding: 5rem 0;
    text-align: center;
}

.highlights h3 {
    font-size: clamp(1.875rem, 4vw, 2.25rem);
    font-weight: 700;
    margin-bottom: 3rem;
    color: var(--gray-900);
}

.highlight-cards {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.highlight-card {
    background-color: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.highlight-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.highlight-card .icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background-color: #fee2e2;
    color: var(--primary-color);
    font-size: 1.5rem;
    margin: 0 auto 1rem auto;
}

.highlight-card h4 {
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.highlight-card p {
    color: var(--gray-600);
}

/* -----------------------------
   Telegram Channels
----------------------------- */
.telegram {
    padding: 5rem 0;
    text-align: center;
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.telegram h3 {
    font-size: clamp(1.875rem, 4vw, 2.25rem);
    font-weight: 700;
    margin-bottom: 3rem;
}

.telegram-cards {
    display: grid;
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
    grid-template-columns: 1fr 1fr;
}

.telegram-card {
    background-color: var(--white);
    padding: 1.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 1rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    gap: 1.25rem;
    transition: transform 0.3s, box-shadow 0.3s;
}

.telegram-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.telegram-card .icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 50%;
    background-color: #3b82f6;
    color: var(--white);
    box-shadow: 0 4px 10px rgba(59, 130, 246, 0.3);
}

.telegram-card .icon svg {
    width: 1.75rem;
    height: 1.75rem;
    fill: var(--white);
}

.telegram-card h4 {
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: var(--gray-800);
}

.telegram-card p {
    color: var(--gray-600);
    font-size: 0.9rem;
}

/* -----------------------------
   CTA Section
----------------------------- */
.cta-section {
    text-align: center;
    padding: 5rem 0;
}

.cta-section h2 {
    font-size: clamp(2rem, 5vw, 2.5rem);
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--gray-900);
}

.cta-section p {
    max-width: 600px;
    margin: 0 auto 2rem auto;
    color: var(--gray-600);
}

.cta-section a {
    background-color: var(--primary-color);
    color: white;
    font-weight: 700;
    padding: 1rem 2.5rem;
    border-radius: 9999px;
    display: inline-block;
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

.cta-section a:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 20px rgba(0, 0, 0, 0.2);
}

/* -----------------------------
   Footer
----------------------------- */
footer {
    background-color: var(--gray-800);
    color: var(--white);
    padding: 3rem 0;
}

footer .footer-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 2rem;
    align-items: center;
}

footer .logo h2 {
    color: var(--white);
    font-weight: 800;
}

footer .logo .icon svg {
    color: var(--primary-color);
}

footer nav {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

footer nav a {
    color: #d1d5db;
    transition: color 0.3s;
    font-weight: 500;
    position: relative;
}

footer nav a:hover {
    color: white;
}

footer nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease-in-out;
}

footer nav a:hover::after {
    width: 100%;
}


footer .copyright {
    margin-top: 2rem;
    border-top: 1px solid #374151;
    padding-top: 2rem;
    text-align: center;
    color: #9ca3af;
    font-size: 0.875rem;
}

/* -----------------------------
   Animations
----------------------------- */
@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}


/* -----------------------------
   Responsive
----------------------------- */
@media(max-width: 768px) {
    nav {
        display: none;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .menu-btn {
        display: inline-block;
    }

    .telegram-cards {
        grid-template-columns: 1fr;
    }

    .highlight-cards {
        grid-template-columns: 1fr;
    }

    .institutions-logos {
        gap: 1rem;
    }

    .institutions-logos img {
        height: 3rem;
    }
}

/* Base nav menu (hidden on mobile until active) */
#main-nav {
  display: flex;
  gap: 2rem;
  align-items: center;
}

#main-nav a {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 500;
  position: relative;
  transition: color 0.3s ease;
}

#main-nav a:hover {
  color: var(--primary-color);
}

/* Dropdown container */
#main-nav .dropdown {
  position: relative;
}

/* Dropdown menu */
#main-nav .dropdown-menu {
  position: absolute;
  top: 100%;
  /* To slide from right, we need to adjust left or right property.
     If `left: 0;` is maintained, it will slide in from outside the parent's left edge.
     If we want it to slide relative to its own position (e.g., from its right edge),
     we might set `right: 0;` and then `transform: translateX(1rem)`.
     Let's assume you want it to appear *next* to the parent link, but slide from right.
     We'll keep `left: 0;` to align with the parent, and use a negative translateX
     to make it slide from the right side relative to its final position. */
  left: 0; 
  background: var(--white);
  border: 1px solid var(--gray-600);
  border-radius: 0.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  flex-direction: column;
  min-width: 180px;
  z-index: 1000;
  
  /* Key Animation Changes for Right-to-Left */
  visibility: hidden;
  opacity: 0;
  transform: translateX(1rem); /* Starts 1rem to the right */
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0.3s;
}

#main-nav .dropdown-menu a {
  padding: 0.75rem 1rem;
  color: var(--gray-700);
  font-size: 0.95rem;
  transition: all 0.3s ease;
  border-radius: 0.25rem;
}

#main-nav .dropdown-menu a:hover {
  background: var(--primary-color);
  color: var(--white);
}

/* New: Show dropdown on hover (desktop) */
#main-nav .dropdown:hover .dropdown-menu {
  visibility: visible;
  opacity: 1;
  transform: translateX(0); /* Slides to its final position */
  transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Responsive */
@media (max-width: 768px) {
  #main-nav {
    position: absolute;
    top: 64px;
    left: 0;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    background: var(--bg-color);
    padding: 1rem 2rem;
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
  }

  #main-nav.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  #main-nav a {
    padding: 0.75rem 0;
    width: 100%;
  }

  /* Dropdowns open inline on mobile */
  #main-nav .dropdown-menu {
    position: static;
    box-shadow: none;
    border: none;
    background: transparent;
    display: none;
    width: 100%;
    padding-left: 1rem;
    /* Reset animation for mobile */
    opacity: 1;
    transform: none; /* No slide effect on mobile dropdowns */
  }

  /* Show dropdown on click/tap on mobile */
  #main-nav .dropdown.active .dropdown-menu {
    display: flex;
  }
}

