/* ═══════════════════════════════════════════════════════
   Pragyan — style.css
   Dark / Light theme + bilingual animations
═══════════════════════════════════════════════════════ */

/* ── Variables ───────────────────────────────────────── */
:root {
  --green: #1a6b3c;
  --green-l: #22c55e;
  --amber: #e8a020;
  --purple: #7c3aed;

  /* dark mode defaults */
  --bg: #030712;
  --bg-alt: #0d1117;
  --bg-card: #111827;
  --border: rgba(255, 255, 255, 0.07);
  --text: #f1f5f9;
  --text-muted: rgba(255, 255, 255, 0.5);
  --contact-bg: #111827;
  --footer-bg: #030712;
}

html.light {
  --bg: #f3f4f6;
  --bg-alt: #ffffff;
  --bg-card: #ffffff;
  --border: rgba(0, 0, 0, 0.08);
  --text: #111827;
  --text-muted: #6b7280;
  --contact-bg: #ffffff;
  --footer-bg: #1f2937;
}

/* ── Base ────────────────────────────────────────────── */
html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', 'Noto Sans Devanagari', sans-serif;
  transition: background 0.4s ease, color 0.3s ease;
}

::-webkit-scrollbar {
  width: 5px;
}

::-webkit-scrollbar-track {
  background: var(--bg);
}

::-webkit-scrollbar-thumb {
  background: var(--green);
  border-radius: 99px;
}

/* ── Text gradients ──────────────────────────────────── */
.text-gradient {
  background: linear-gradient(135deg, #22c55e 0%, #86efac 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-gradient-amber {
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-gradient-purple {
  background: linear-gradient(135deg, #c084fc 0%, #818cf8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Section backgrounds ─────────────────────────────── */
.section-bg {
  background: var(--bg);
}

.section-bg-alt {
  background: var(--bg-alt);
}

/* ── Blobs ───────────────────────────────────────────── */
.blob {
  position: absolute;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
}

.blob-green {
  background: rgba(26, 107, 60, 0.12);
}

.blob-amber {
  background: rgba(232, 160, 32, 0.08);
}

.blob-purple {
  background: rgba(124, 58, 237, 0.07);
}

/* ── Typography ──────────────────────────────────────── */
.section-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 900;
  line-height: 1.15;
  color: var(--text);
}

.body-text {
  color: var(--text-muted);
  line-height: 1.75;
  font-size: 0.95rem;
}

/* ── Chips ───────────────────────────────────────────── */
.chip {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0.25rem 0.9rem;
  border-radius: 99px;
}

.chip-green {
  background: rgba(34, 197, 94, 0.12);
  color: #22c55e;
  border: 1px solid rgba(34, 197, 94, 0.3);
}

.chip-amber {
  background: rgba(245, 158, 11, 0.12);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

/* ── Header / Glassmorphism ──────────────────────────── */
.header {
  background: rgb(255 255 255 / 52%);
  transition: background 0.4s ease, backdrop-filter 0.4s ease, box-shadow 0.4s ease;
}

.header.scrolled {
  background: rgba(255, 255, 255, 0.88);
  /* background: rgba(3,7,18,0.82); */
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

html.light .header.scrolled {
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.08);
}

html.light .header.scrolled .hamburger-line {
  background: #1f2937;
}

html.light .header.scrolled .nav-link {
  color: #374151;
}

html.light .header.scrolled .nav-link:hover {
  color: #111827;
}

.nav-link {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.875rem;
  font-weight: 500;
  position: relative;
  transition: color 0.2s;
}

html.light .nav-link {
  color: rgba(255, 255, 255, 0.75);
}

.nav-link:hover {
  color: #fff;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #22c55e;
  border-radius: 99px;
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
}

.mobile-nav-link {
  color: rgba(255, 255, 255, 0.75);
  font-size: 1rem;
  font-weight: 500;
  transition: color 0.2s;
  display: block;
}

.mobile-nav-link:hover {
  color: #22c55e;
}

/* Hamburger */
#hamburger.active .hamburger-line:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

#hamburger.active .hamburger-line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

#hamburger.active .hamburger-line:nth-child(3) {
  width: 24px;
  transform: translateY(-8px) rotate(-45deg);
}

/* Language toggle */
.lang-btn {
  color: #000;
  font-size: 0.7rem;
  font-weight: 700;
  transition: all 0.3s ease;
}

.lang-btn.active {
  background: var(--green);
  color: #fff;
  box-shadow: 0 2px 6px rgba(26, 107, 60, 0.5);
}

/* ── Hero Slider ─────────────────────────────────────── */
.slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.9s cubic-bezier(0.4, 0, 0.2, 1);
}

.slide.active {
  opacity: 1;
  pointer-events: auto;
}

.slide .slide-content>* {
  opacity: 2;
  transform: translateY(32px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.slide.active .slide-tag {
  opacity: 1;
  transform: none;
  transition-delay: 0.2s;
}

.slide.active .slide-title {
  opacity: 1;
  transform: none;
  transition-delay: 0.35s;
}

.slide.active .slide-desc {
  opacity: 1;
  transform: none;
  transition-delay: 0.5s;
}

.slide.active .slide-cta {
  opacity: 1;
  transform: none;
  transition-delay: 0.65s;
}

@keyframes kbZoom {
  0% {
    transform: scale(1)
  }

  100% {
    transform: scale(1.07)
  }
}

.slide.active .slide-bg {
  animation: kbZoom 8s ease-in-out forwards;
}

.slide-title {
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  line-height: 1.1;
}

/* Slider buttons */
.btn-green {
  background: var(--green);
  color: #fff;
  font-weight: 600;
  padding: 0.9rem 1.8rem;
  border-radius: 12px;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.btn-green:hover {
  background: #145530;
  box-shadow: 0 12px 28px rgba(26, 107, 60, 0.45);
  transform: translateY(-2px);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  font-weight: 600;
  padding: 0.9rem 1.8rem;
  border-radius: 12px;
  backdrop-filter: blur(8px);
  transition: all 0.3s ease;
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.18);
}

/* Slider controls */
.slider-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(12px);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.slider-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
}

.dot.active {
  width: 32px;
  background: #fff;
}

/* ── Stat cards ──────────────────────────────────────── */
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
  transition: all 0.3s ease;
}

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

.stat-num {
  font-size: 2.8rem;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 0.4rem;
}

.stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ── Portal Cards  ───────────────────────────────────── */
.portal-card {
  animation-delay: var(--delay, 0s);
}

.portal-card-inner {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  height: 300px;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
    box-shadow 0.4s ease;
}

.portal-card-inner:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.portal-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.7s ease;
}

.portal-card-inner:hover .portal-bg {
  transform: scale(1.06);
}

.portal-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.88) 0%, rgba(0, 0, 0, 0.5) 55%, rgba(0, 0, 0, 0.2) 100%);
}

/* Logo badge top-center */
.portal-logo-badge {
  position: absolute;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  border: 2px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  z-index: 5;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
}

.portal-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1.25rem 1.5rem;
  z-index: 5;
  text-align: center;
}

.portal-title {
  color: #fff;
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
}

.portal-desc {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.78rem;
  line-height: 1.55;
  margin-bottom: 1rem;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}

/* Green portal button — matching reference image */
.portal-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #16a34a;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.55rem 1.4rem;
  border-radius: 8px;
  border: 2px solid #22c55e;
  text-decoration: none;
  transition: all 0.25s ease;
  box-shadow: 0 2px 12px rgba(22, 163, 74, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.15);
  cursor: pointer;
}

.portal-btn:hover {
  background: #15803d;
  box-shadow: 0 6px 20px rgba(22, 163, 74, 0.6);
  transform: scale(1.04);
}

/* Coming soon variant */
.portal-btn-coming {
  background: rgba(60, 60, 60, 0.7);
  border-color: rgba(150, 150, 150, 0.4);
  color: rgba(255, 255, 255, 0.55);
  cursor: not-allowed;
  box-shadow: none;
}

.portal-btn-coming:hover {
  transform: none;
  background: rgba(60, 60, 60, 0.7);
  box-shadow: none;
}

/* ── Contact card ────────────────────────────────────── */
.contact-card {
  background: var(--contact-bg);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.3);
}

.contact-info {
  background: var(--contact-bg);
}

.contact-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.875rem;
  color: var(--text);
}

.contact-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-label {
  font-weight: 700;
}

.contact-val {
  color: var(--text-muted);
}

.quick-link {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.3rem 0.75rem;
  border-radius: 8px;
  background: rgba(34, 197, 94, 0.1);
  color: #22c55e;
  border: 1px solid rgba(34, 197, 94, 0.25);
  transition: all 0.2s ease;
}

.quick-link:hover {
  background: rgba(34, 197, 94, 0.2);
}

/* ── Footer ──────────────────────────────────────────── */
.footer-bg {
  background: var(--footer-bg);
}

.footer-heading {
  color: var(--text);
  font-weight: 700;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1.1rem;
}

.footer-link {
  display: inline-block;
  color: var(--text-muted);
  font-size: 0.875rem;
  transition: all 0.2s ease;
}

.footer-link:hover {
  color: #22c55e;
  padding-left: 4px;
}

.social-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.45);
  transition: all 0.3s ease;
}

.social-icon:hover {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
  transform: scale(1.1);
}

/* ── Scroll-reveal ───────────────────────────────────── */
.reveal-up {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s ease, transform 0.7s ease;
  transition-delay: var(--delay, 0s);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-up.visible,
.reveal-left.visible,
.reveal-right.visible {
  opacity: 1;
  transform: none;
}

/* ── Back to top ─────────────────────────────────────── */
#back-to-top.visible {
  opacity: 1;
  pointer-events: auto;
}

/* ── Light mode overrides ────────────────────────────── */
html.light body {
  background: #f3f4f6;
  color: #111827;
}

html.light .section-title {
  color: #111827;
}

html.light .body-text {
  color: #6b7280;
}

html.light .stat-card {
  background: #fff;
  border-color: #e5e7eb;
}

html.light .footer-bg {
  background: #1f2937;
}

html.light .mobile-nav-link {
  color: rgba(255, 255, 255, 0.8);
}

/* ── Responsive ──────────────────────────────────────── */
@media (max-width: 768px) {
  .slide-title {
    font-size: 2.4rem !important;
  }

  .portal-card-inner {
    height: 260px;
  }

  .portal-title {
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  .slide-title {
    font-size: 2rem !important;
  }

  .portal-card-inner {
    height: 240px;
  }
}