/* ===== CSS Variables ===== */
:root {
  --primary-50: #f2f6fa;
  --primary-100: #c2d5e6;
  --primary-200: #92b5d2;
  --primary-300: #6294be;
  --primary-400: #3173aa;
  --primary-500: #015296;
  --primary-600: #014680;
  --primary-700: #013969;
  --primary-800: #012d53;
  --primary-900: #00213c;
  --font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --text-color: #000;
  --text-color-light: rgba(0, 0, 0, 0.5);
  --heading-color: #015296;
  --bg-color: #ffffff;
  --bg-color-header: #015296;
  --bg-color-block: #fff;
  --bg-announcements: #DFEFFF;
  --bg-footer-page: #F6FBFF;
  --bg-sitemap-page: #E4EEFF;
  --bg-breadcrum: #FAFAFA;
  --bg-active-color: #F2FAFF;
  --border-what-new: #f2f2f2;
  --active-link-color: #015296;
  --text-blur: #015296b3;
  --text-gray: #52525b;
  --button-color: #fff;
  --border-menubar: #E2E2EA;
  --border-input: #E2E2EA;
  --bg-download-wrap: #f5f5f5;
  --text-faq: rgba(60, 60, 67, 0.85);
  --white-border: 255, 255, 255;
  --yellow-accent: #FFD580;
}

/* Dark mode */
body.dark-mode {
  --text-color: #e0e0e0;
  --bg-color: #1a1a2e;
  --bg-color-block: #16213e;
  --bg-announcements: #0f3460;
  --bg-footer-page: #0f3460;
  --bg-sitemap-page: #0f3460;
  --bg-breadcrum: #16213e;
  --bg-active-color: #0f3460;
  --border-what-new: #333;
  --border-menubar: #333;
  --bg-download-wrap: #16213e;
  --text-gray: #aaa;
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  color: var(--text-color);
  background: var(--bg-color);
  font-size: 1rem;
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ===== Accessibility Bar ===== */
.accessibility-bar {
  background: var(--primary-500);
  color: #fff;
  font-size: 0.8rem;
  padding: 6px 0;
}

.accessibility-bar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.access-left {
  display: flex;
  gap: 20px;
  align-items: center;
}

.skip-link, .lang-switch {
  color: #fff;
  text-decoration: underline;
  font-size: 0.75rem;
}

.lang-switch {
  font-weight: 600;
  background: rgba(255,255,255,0.15);
  padding: 2px 12px;
  border-radius: 4px;
  text-decoration: none;
}

.access-right {
  display: flex;
  gap: 15px;
  align-items: center;
}

.access-tools {
  display: flex;
  gap: 5px;
}

.tool-btn {
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.3);
  color: #fff;
  padding: 2px 10px;
  border-radius: 3px;
  cursor: pointer;
  font-size: 0.75rem;
  font-family: inherit;
  transition: background 0.2s;
}

.tool-btn:hover {
  background: rgba(255,255,255,0.3);
}

.social-links {
  display: flex;
  gap: 10px;
}

.social-links a {
  color: #fff;
  font-size: 0.75rem;
}

/* ===== Header ===== */
.main-header {
  background: var(--bg-color);
  border-bottom: 3px solid var(--primary-500);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  gap: 20px;
}

.logo-section {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 200px;
}

.emblem {
  width: 50px;
  height: 50px;
  flex-shrink: 0;
}

.emblem img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.govt-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.govt-title {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary-500);
}

.govt-title-en {
  font-size: 0.65rem;
  color: var(--text-gray);
}

.ministry-title {
  font-size: 0.6rem;
  color: var(--primary-500);
  font-weight: 500;
}

.ministry-title-en {
  font-size: 0.55rem;
  color: var(--text-gray);
}

.scheme-title {
  text-align: center;
  flex: 1;
}

.scheme-title h1 {
  font-size: 1.3rem;
  color: var(--heading-color);
  font-weight: 700;
  line-height: 1.2;
}

.scheme-title .subtitle {
  font-size: 0.75rem;
  color: var(--text-gray);
  font-weight: 500;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
}

.login-dropdown {
  position: relative;
}

.login-btn {
  background: var(--primary-500);
  color: #fff;
  border: none;
  padding: 8px 20px;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background 0.2s;
}

.login-btn:hover {
  background: var(--primary-600);
}

.arrow-down {
  font-size: 0.6rem;
}

.login-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background: #fff;
  min-width: 220px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
  border-radius: 8px;
  overflow: hidden;
  z-index: 100;
  margin-top: 4px;
}

.login-menu.show {
  display: block;
}

.login-menu a {
  display: block;
  padding: 10px 16px;
  color: #333;
  font-size: 0.85rem;
  border-bottom: 1px solid #f0f0f0;
  transition: background 0.2s;
}

.login-menu a:hover {
  background: var(--primary-50);
  color: var(--primary-500);
}

.login-menu a:last-child {
  border-bottom: none;
}

.grievance-link {
  background: transparent;
  color: var(--primary-500);
  border: 2px solid var(--primary-500);
  padding: 6px 16px;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 500;
  transition: all 0.2s;
}

.grievance-link:hover {
  background: var(--primary-500);
  color: #fff;
}

.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 5px;
}

.mobile-toggle span {
  width: 28px;
  height: 3px;
  background: var(--primary-500);
  border-radius: 3px;
  transition: 0.3s;
}

/* ===== Navigation ===== */
.main-nav {
  background: var(--primary-500);
}

.nav-list {
  display: flex;
  gap: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.nav-list li {
  flex-shrink: 0;
}

.nav-list a {
  display: block;
  padding: 12px 18px;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 500;
  transition: background 0.2s;
  white-space: nowrap;
}

.nav-list a:hover,
.nav-list a.active {
  background: var(--primary-600);
}

/* ===== Announcement Bar ===== */
.announcement-bar {
  background: var(--bg-announcements);
  padding: 10px 0;
  border-bottom: 2px solid var(--primary-100);
}

.announcement-content {
  display: flex;
  align-items: center;
  gap: 15px;
}

.announcement-icon {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

.announcement-label {
  background: var(--primary-500);
  color: #fff;
  padding: 4px 14px;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}

.announcement-text {
  font-size: 0.85rem;
  color: var(--text-color);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* ===== Hero Section ===== */
.hero-section {
  background: linear-gradient(135deg, var(--primary-50) 0%, #fff 100%);
  padding: 50px 0;
  position: relative;
  overflow: hidden;
}

.hero-graphic {
  position: absolute;
  right: -100px;
  bottom: -50px;
  width: 600px;
  opacity: 0.15;
  pointer-events: none;
}

.hero-graphic img {
  width: 100%;
  height: auto;
}

.hero-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}

.hero-text {
  flex: 1;
}

.hero-text h2 {
  font-size: 2.5rem;
  color: var(--heading-color);
  font-weight: 800;
  line-height: 1.1;
}

.hero-text h3 {
  font-size: 2rem;
  color: var(--primary-400);
  font-weight: 700;
  margin-bottom: 8px;
}

.hero-desc {
  font-size: 1.1rem;
  color: var(--text-gray);
  margin-bottom: 4px;
}

.hero-sub {
  font-size: 0.95rem;
  color: var(--text-gray);
  margin-bottom: 24px;
}

.hero-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.btn-primary, .btn-secondary {
  display: inline-block;
  padding: 12px 32px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.2s;
}

.btn-primary {
  background: var(--primary-500);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-600);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(1, 82, 150, 0.3);
}

.btn-secondary {
  background: #fff;
  color: var(--primary-500);
  border: 2px solid var(--primary-500);
}

.btn-secondary:hover {
  background: var(--primary-50);
}

.hero-image {
  text-align: center;
  flex-shrink: 0;
}

.pm-image {
  width: 200px;
  height: 240px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
  background: #f0f0f0;
  margin-bottom: 10px;
}

.pm-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pm-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.pm-caption {
  font-size: 0.8rem;
  color: var(--text-gray);
  font-weight: 500;
}

/* ===== Ministers Section ===== */
.ministers-section {
  padding: 30px 0;
  background: var(--bg-color);
}

.ministers-grid {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
}

.minister-card {
  text-align: center;
  max-width: 180px;
}

.minister-img {
  width: 120px;
  height: 140px;
  border-radius: 10px;
  overflow: hidden;
  margin: 0 auto 10px;
  background: #e8f4fd;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.minister-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.minister-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-color);
}

.minister-post {
  font-size: 0.7rem;
  color: var(--text-gray);
}

/* ===== Section Header ===== */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.section-header h2 {
  font-size: 1.5rem;
  color: var(--heading-color);
  font-weight: 700;
  position: relative;
  padding-bottom: 8px;
}

.section-header h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 50px;
  height: 3px;
  background: var(--yellow-accent);
  border-radius: 2px;
}

.view-more {
  font-size: 0.85rem;
  color: var(--primary-500);
  font-weight: 500;
  border: 1px solid var(--primary-500);
  padding: 6px 16px;
  border-radius: 6px;
  transition: all 0.2s;
}

.view-more:hover {
  background: var(--primary-500);
  color: #fff;
}

/* ===== What's New ===== */
.whats-new-section {
  padding: 40px 0;
  background: var(--bg-color);
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.news-card {
  background: var(--bg-color-block);
  border: 1px solid var(--border-what-new);
  border-radius: 10px;
  padding: 20px;
  transition: all 0.3s;
}

.news-card:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  transform: translateY(-2px);
}

.news-date {
  font-size: 0.75rem;
  color: var(--primary-400);
  font-weight: 600;
  display: block;
  margin-bottom: 8px;
}

.news-card h3 {
  font-size: 0.95rem;
  color: var(--text-color);
  font-weight: 600;
  margin-bottom: 6px;
  line-height: 1.4;
}

.news-card p {
  font-size: 0.8rem;
  color: var(--text-gray);
}

/* ===== Benefits ===== */
.benefits-section {
  padding: 40px 0;
  background: var(--primary-50);
}

.benefits-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 30px;
}

.benefit-card {
  background: var(--bg-color-block);
  border-radius: 12px;
  padding: 28px;
  border: 1px solid var(--border-menubar);
}

.benefit-card.highlight {
  border-color: var(--yellow-accent);
  box-shadow: 0 4px 16px rgba(255, 213, 128, 0.2);
}

.benefit-card h3 {
  font-size: 1.1rem;
  color: var(--heading-color);
  margin-bottom: 20px;
}

.benefit-slabs {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.slab {
  padding: 12px 16px;
  background: var(--primary-50);
  border-radius: 8px;
  border-left: 4px solid var(--primary-300);
}

.slab.total {
  background: #fff8e1;
  border-left-color: var(--yellow-accent);
}

.amount {
  display: block;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary-500);
}

.per {
  font-size: 0.8rem;
  color: var(--text-gray);
  font-weight: 500;
}

.desc {
  font-size: 0.8rem;
  color: var(--text-gray);
  display: block;
  margin-top: 2px;
}

.capacity-table {
  background: var(--bg-color-block);
  border-radius: 12px;
  padding: 24px;
  border: 1px solid var(--border-menubar);
}

.capacity-table h3 {
  font-size: 1rem;
  color: var(--heading-color);
  margin-bottom: 16px;
}

.capacity-table table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 12px;
}

.capacity-table th, .capacity-table td {
  padding: 12px 16px;
  border: 1px solid var(--border-menubar);
  text-align: center;
  font-size: 0.9rem;
}

.capacity-table th {
  background: var(--primary-500);
  color: #fff;
  font-weight: 600;
}

.capacity-table td:first-child {
  background: var(--primary-50);
  font-weight: 500;
  text-align: left;
}

.special-states {
  font-size: 0.8rem;
  color: var(--primary-500);
  font-weight: 600;
  font-style: italic;
}

/* ===== Steps ===== */
.steps-section {
  padding: 40px 0;
  background: var(--bg-color);
}

.steps-process {
  margin-bottom: 30px;
}

.steps-process-img {
  max-width: 100%;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}

.process-img-desktop {
  width: 100%;
  height: auto;
  display: block;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 20px;
}

.step-card {
  text-align: center;
  padding: 24px 16px;
  background: var(--bg-color-block);
  border: 1px solid var(--border-menubar);
  border-radius: 12px;
  transition: all 0.3s;
}

.step-card:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  transform: translateY(-3px);
}

.step-number {
  width: 50px;
  height: 50px;
  background: var(--primary-500);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0 auto 12px;
}

.step-card h3 {
  font-size: 0.95rem;
  color: var(--heading-color);
  font-weight: 600;
  margin-bottom: 6px;
}

.step-card p {
  font-size: 0.8rem;
  color: var(--text-gray);
}

/* ===== Welcome ===== */
.welcome-section {
  padding: 40px 0;
  background: linear-gradient(135deg, var(--primary-50), var(--bg-announcements));
}

.welcome-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
}

.welcome-text {
  flex: 1;
}

.welcome-text h2 {
  font-size: 1.3rem;
  color: var(--heading-color);
  font-weight: 700;
  margin-bottom: 10px;
}

.welcome-text p {
  font-size: 0.9rem;
  color: var(--text-gray);
  margin-bottom: 20px;
}

.welcome-contact h3 {
  font-size: 1rem;
  color: var(--heading-color);
  margin-bottom: 12px;
}

.app-links {
  display: flex;
  gap: 12px;
}

.app-badge {
  display: inline-flex;
  align-items: center;
}

.app-badge img {
  height: 48px;
  width: auto;
  transition: opacity 0.2s;
}

.app-badge:hover {
  opacity: 0.85;
}

.app-icon {
  font-size: 1.3rem;
}

/* ===== Gallery ===== */
.gallery-section {
  padding: 40px 0;
  background: var(--bg-color);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
}

.gallery-item {
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  transition: transform 0.3s;
  aspect-ratio: 4/3;
}

.gallery-item:hover {
  transform: scale(1.03);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ===== Footer ===== */
.main-footer {
  background: var(--primary-800);
  color: #fff;
  padding: 40px 0 20px;
  position: relative;
}

.main-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('../assets/images/footer-bg.svg') no-repeat right bottom / cover;
  background-size: cover;
  opacity: 0.1;
  pointer-events: none;
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 30px;
  margin-bottom: 30px;
}

.footer-links h3,
.footer-info h3,
.footer-visitors h3 {
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid rgba(255,255,255,0.2);
}

.footer-links ul {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.footer-links a {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.8);
  transition: color 0.2s;
}

.footer-links a:hover {
  color: #fff;
  text-decoration: underline;
}

.footer-logo-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.footer-flag {
  height: 36px;
  width: auto;
}

.footer-mnre-logo {
  height: 40px;
  width: auto;
}

.footer-info p {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.8);
  margin-bottom: 6px;
}

.visitor-count {
  margin-bottom: 16px;
}

.visitor-count span {
  display: block;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.8);
  margin-bottom: 4px;
}

.footer-visitors .social-links {
  flex-direction: column;
  gap: 4px;
}

.footer-visitors .social-links a {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.8);
  transition: color 0.2s;
}

.footer-visitors .social-links a:hover {
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding-top: 20px;
  text-align: center;
}

.footer-bottom p {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.6);
  margin-bottom: 4px;
}

/* ===== Responsive ===== */
@media (max-width: 992px) {
  .header-content {
    flex-wrap: wrap;
  }
  .scheme-title {
    order: 3;
    width: 100%;
    text-align: center;
  }
  .hero-content {
    flex-direction: column-reverse;
    text-align: center;
  }
  .hero-buttons {
    justify-content: center;
  }
  .hero-text h2 {
    font-size: 2rem;
  }
  .hero-text h3 {
    font-size: 1.6rem;
  }
  .benefits-grid {
    grid-template-columns: 1fr;
  }
  .footer-content {
    grid-template-columns: 1fr 1fr;
  }
  .welcome-content {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 768px) {
  .accessibility-bar .container {
    flex-direction: column;
    align-items: center;
  }
  .header-actions {
    display: none;
  }
  .mobile-toggle {
    display: flex;
  }
  .main-nav {
    display: none;
  }
  .main-nav.open {
    display: block;
  }
  .nav-list {
    flex-direction: column;
  }
  .nav-list a {
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }
  .hero-text h2 {
    font-size: 1.6rem;
  }
  .hero-text h3 {
    font-size: 1.3rem;
  }
  .pm-image {
    width: 150px;
    height: 180px;
  }
  .footer-content {
    grid-template-columns: 1fr;
  }
  .footer-links ul {
    grid-template-columns: 1fr 1fr;
  }
  .news-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .hero-text h2 {
    font-size: 1.3rem;
  }
  .hero-text h3 {
    font-size: 1.1rem;
  }
  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }
  .btn-primary, .btn-secondary {
    width: 100%;
    text-align: center;
  }
  .steps-grid {
    grid-template-columns: 1fr 1fr;
  }
  .gallery-grid {
    grid-template-columns: 1fr 1fr;
  }
  .access-right {
    flex-direction: column;
    align-items: center;
  }
}
