/* Complete CSS Bundle - All styles needed for optimized homepage */
/* This combines all necessary CSS for faster loading */

/* ========================================
   BASE STYLES - Core variables and resets
   ======================================== */

:root {
  --header-height: 80px;
  --primary-color: #1a2b4a;
  --accent-color: #f8a01c;
  --light-text-color: #fff;
  --text-color: #333;
  --bg-main: #f8f9fa;
  --spacing-sm: 0.5rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2rem;
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
  --shadow-lg: 0 8px 15px rgba(0,0,0,0.1);
  --content-max-width: 1400px;
  --transition-speed: 0.3s;
  --border-radius: 8px;
  
  /* Dark mode variables */
  --dark-bg: #1a1a1a;
  --dark-surface: #2d2d2d;
  --dark-text: #e0e0e0;
  --dark-border: #3d3d3d;
}

/* Reset and Box Model */
*, *::before, *::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
  background: var(--bg-main);
  color: var(--text-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Typography Base */
h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  line-height: 1.2;
  font-weight: 700;
}

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

/* ========================================
   LAYOUT - Header, containers, grid
   ======================================== */

.content-wrapper {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  width: 100%;
  height: var(--header-height);
  background: #fff;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 0 1.5rem;
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.logo-link {
  display: flex;
  align-items: center;
}

.logo {
  height: 60px;
  width: auto;
}

.nav-wrapper {
  display: flex;
  align-items: center;
}

.nav-links {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 1rem;
}

.nav-links a {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  color: var(--text-color);
  text-decoration: none;
  border-radius: 4px;
  transition: all 0.3s ease;
  font-weight: 500 !important;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Helvetica Neue", Arial, sans-serif !important;
  font-size: 0.95rem !important;
}

.nav-links a:hover,
.nav-links a.active {
  background: var(--primary-color);
  color: white;
}

/* Dropdown */
.dropdown {
  position: relative;
}

.nav-links .dropdown button {
  background: none;
  border: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  color: var(--text-color);
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.3s ease;
  font-weight: 500 !important;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Helvetica Neue", Arial, sans-serif !important;
  font-size: 0.95rem !important;
}

.nav-links .dropdown button:hover {
  background: var(--primary-color);
  color: white;
}

.dropdown-content {
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  min-width: 200px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
  border-radius: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  z-index: 1001;
}

.dropdown:hover .dropdown-content {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-content ul {
  list-style: none;
  margin: 0;
  padding: 0.5rem 0;
}

.dropdown-content a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  color: var(--text-color);
  transition: background 0.3s ease;
}

.dropdown-content a:hover {
  background: #f8f9fa;
}

/* Mobile menu */
.mobile-menu-btn,
.mobile-close-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.75rem;
  min-width: 44px;
  min-height: 44px;
}

.dark-mode-toggle {
  background: rgba(0,0,0,0.05);
  border: 1px solid rgba(0,0,0,0.1);
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 50%;
  transition: all 0.3s ease;
  color: var(--text-color);
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  min-height: 40px;
}

.dark-mode-toggle:hover {
  background: rgba(0,0,0,0.1);
  border-color: rgba(0,0,0,0.2);
}

.theme-hint {
  font-size: 0.75rem;
  margin-left: 0.5rem;
  opacity: 0.7;
}

/* ========================================
   HERO SECTION
   ======================================== */

.main-content {
  margin-top: var(--header-height);
}

.modern-hero {
  position: relative;
  min-height: 680px;
  display: flex;
  align-items: center;
  background: var(--primary-color);
  color: white;
  overflow: hidden;
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(26, 43, 74, 0.7);
}

.hero-container {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.hero-content {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.department-badge {
  margin-bottom: 2rem;
}

.badge-image {
  width: 120px;
  height: auto;
}

.hero-title {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  font-weight: 800;
}

.hero-tagline {
  font-size: 1.5rem;
  margin-bottom: 2.5rem;
  opacity: 0.9;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.modern-btn {
  display: inline-block;
  padding: 1rem 2rem;
  background: rgba(255,255,255,0.1);
  color: white;
  border: 2px solid white;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
}

.modern-btn:hover {
  background: white;
  color: var(--primary-color);
}

.modern-btn.accent {
  background: #c0392b;
  border-color: #c0392b;
  color: white;
}

.modern-btn.accent:hover {
  background: #a93226;
  border-color: #a93226;
  color: white;
}

.hero-divider {
  height: 4px;
  background: linear-gradient(to right, var(--primary-color), var(--accent-color));
}

/* ========================================
   NEWS HUB SECTION
   ======================================== */

.news-hub-section {
  padding: 4rem 0;
  background: var(--bg-main);
}

.section-title {
  font-size: 2.5rem;
  text-align: center;
  margin-bottom: 3rem;
  color: var(--text-color);
}

.news-hub-container {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 3rem;
  align-items: flex-start;
}

.column-title {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 2rem;
  color: var(--text-color);
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--primary-color);
}

/* Featured News */
.news-item {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

/* Ensure proper contrast for news item links */
.news-item a {
  color: #007bff !important; /* Better contrast blue color */
  font-weight: 500;
}

.news-item a:hover {
  color: #0056b3 !important; /* Darker blue on hover */
}

.news-image {
  position: relative;
  overflow: hidden;
}

.news-image-fit {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

.news-content {
  padding: 1.5rem;
}

.news-date {
  color: #0d47a1; /* Explicit color for better contrast */
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.news-content h4 {
  margin: 0.5rem 0 1rem;
  font-size: 1.4rem;
  color: var(--text-color);
}

.news-content p {
  color: #343a40; /* Higher contrast than #666 */
  margin-bottom: 1rem;
}

.read-more-link {
  color: #0d47a1; /* Explicit color for better contrast */
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: gap 0.3s ease;
}

.read-more-link:hover {
  gap: 0.75rem;
}

.view-all-container {
  text-align: center;
}

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 6px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
}

.btn-outline {
  border: 2px solid #1a2b4a; /* Explicit dark color for better contrast */
  color: #1a2b4a; /* Explicit dark color for better contrast */
  background: transparent;
}

.btn-outline:hover {
  background: var(--primary-color);
  color: white;
}

/* ========================================
   COMMUNITY RESOURCES WIDGETS
   ======================================== */

.community-resources-column {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Recruitment Widget */
.recruitment-widget {
  background: linear-gradient(135deg, var(--primary-color), #2c3e50);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(26, 43, 74, 0.2);
  color: white;
  position: relative;
}

.recruitment-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--accent-color);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.widget-header {
  padding: 1.5rem;
}

.widget-title {
  font-size: 1.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0;
}

.salary-spotlight {
  background: var(--accent-color);
  padding: 2rem;
  text-align: center;
}

.salary-label {
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.9;
  display: block;
  margin-bottom: 0.5rem;
}

.salary-amount {
  font-size: 3rem;
  font-weight: 800;
  display: block;
  margin-bottom: 0.25rem;
}

.salary-period {
  font-size: 1.1rem;
  opacity: 0.8;
}

.recruitment-benefits {
  padding: 1.5rem;
}

.benefit-item {
  background: rgba(255,255,255,0.1);
  padding: 0.75rem 1rem;
  margin-bottom: 0.75rem;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: all 0.3s ease;
}

.benefit-item:hover {
  background: rgba(255,255,255,0.2);
  transform: translateX(5px);
}

.benefit-item i {
  color: var(--accent-color);
  font-size: 1.25rem;
}

.benefit-item a {
  color: white;
  text-decoration: underline;
}

.recruitment-text {
  padding: 0 1.5rem 1rem;
  opacity: 0.9;
}

.recruitment-cta {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.recruitment-cta a {
  padding: 1.25rem;
  text-align: center;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
}

.primary-cta {
  background: #c0392b;
  color: white;
}

.primary-cta:hover {
  background: #962d22;
}

.secondary-cta {
  background: rgba(255,255,255,0.1);
  color: white;
}

.secondary-cta:hover {
  background: rgba(255,255,255,0.2);
}

/* Emergency Contacts Widget */
.quick-links-widget {
  background: #2c3e50;
  border-radius: 12px;
  padding: 1.5rem;
  color: white;
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.quick-links-widget .widget-title {
  color: white;
  border-bottom: 1px solid rgba(255,255,255,0.2);
  padding-bottom: 0.75rem;
  margin-bottom: 1rem;
}

.quick-links-widget .widget-title i {
  color: #e74c3c;
}

.emergency-numbers {
  list-style: none;
  padding: 0;
  margin: 0;
}

.contact-item {
  display: flex;
  justify-content: space-between;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.contact-item:last-child {
  border-bottom: none;
}

.contact-item .label {
  font-weight: 500;
}

.contact-item .phone-number {
  color: white;
  text-decoration: none;
  font-weight: 700;
}

.view-all {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #1a2b4a; /* Dark color for better contrast */
  background: rgba(255,255,255,0.9); /* More opaque background for contrast */
  padding: 0.5rem 1rem;
  border-radius: 4px;
  margin-top: 1rem;
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: 600; /* Bolder text for better visibility */
}

.view-all:hover {
  background: rgba(255,255,255,1.0); /* Full opacity on hover */
  color: #1a2b4a; /* Keep dark text color */
}

/* Common Forms Widget */
.common-forms-widget {
  background: #f0f9f0;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 8px 20px rgba(0,0,0,0.06);
}

.common-forms-widget .widget-title {
  color: #2c3e50;
  border-bottom: 1px solid #d1e7d1;
  padding-bottom: 0.75rem;
  margin-bottom: 1rem;
}

.common-forms-widget .widget-title i {
  color: #27ae60;
}

.forms-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.forms-list li {
  margin-bottom: 0.75rem;
}

.forms-list a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #2c3e50;
  text-decoration: none;
  padding: 0.5rem;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.forms-list a:hover {
  background: rgba(39, 174, 96, 0.1);
  transform: translateX(5px);
}

.forms-list i {
  color: #27ae60;
}

.common-forms-widget .view-all {
  color: white;
  background: #27ae60;
}

.common-forms-widget .view-all:hover {
  background: #219653;
}

/* ========================================
   FEATURED SERVICES SECTION
   ======================================== */

.section-divider {
  height: 1px;
  background: #e9ecef;
  margin: 2rem 0;
}

.featured-services {
  padding: 4rem 0;
  background: white;
}

.services-intro {
  text-align: center;
  margin-bottom: 3rem;
}

.section-subtitle {
  font-size: 1.2rem;
  color: #666;
  max-width: 800px;
  margin: 0 auto;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.service-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

.service-img img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.service-content {
  padding: 1.5rem;
}

.service-content h3 {
  margin-bottom: 1rem;
  color: var(--text-color);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.service-content h3 i {
  color: var(--primary-color);
}

.service-content p {
  color: #666;
  margin-bottom: 1.5rem;
}

/* ========================================
   FOOTER
   ======================================== */

.footer {
  background: var(--primary-color);
  color: white;
  padding: 3rem 0 1rem;
}

.footer-content {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3rem;
}

.footer-logo-container {
  text-align: center;
}

.footer-logo {
  width: 80px;
  height: auto;
  margin-bottom: 1rem;
}

.social-icons {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 1rem;
}

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

.social-icons a:hover {
  background: var(--accent-color);
  transform: translateY(-2px);
}

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

.footer-column h3 {
  font-size: 1rem;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

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

.footer-column li {
  margin-bottom: 0.5rem;
}

.footer-column a {
  color: rgba(255,255,255,0.8);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.3s ease;
}

.footer-column a:hover {
  color: white;
}

.footer-bottom {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.2);
  text-align: center;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.last-updated {
  font-size: 0.9rem;
  opacity: 0.8;
}

/* ========================================
   DARK MODE STYLES
   ======================================== */

body.dark-mode {
  background: var(--dark-bg);
  color: var(--dark-text);
}

body.dark-mode .header {
  background: var(--dark-surface);
  border-bottom: 1px solid var(--dark-border);
}

body.dark-mode .nav-links a {
  color: var(--dark-text);
}

body.dark-mode .nav-links .dropdown button {
  color: var(--dark-text);
}

body.dark-mode .dropdown-content {
  background: var(--dark-surface);
  border: 1px solid var(--dark-border);
}

body.dark-mode .dropdown-content a {
  color: var(--dark-text);
}

body.dark-mode .dropdown-content a:hover {
  background: rgba(255,255,255,0.1);
}

body.dark-mode .news-hub-section {
  background: var(--dark-bg);
}

body.dark-mode .section-title,
body.dark-mode .column-title {
  color: var(--dark-text);
}

body.dark-mode .news-item {
  background: var(--dark-surface);
  border: 1px solid var(--dark-border);
}

body.dark-mode .news-content h4 {
  color: var(--dark-text);
}

body.dark-mode .featured-services {
  background: var(--dark-bg);
}

body.dark-mode .service-card {
  background: var(--dark-surface);
  border: 1px solid var(--dark-border);
}

body.dark-mode .service-content h3 {
  color: var(--dark-text);
}

body.dark-mode .dark-mode-toggle {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  color: var(--dark-text);
}

body.dark-mode .dark-mode-toggle:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.2);
}

/* Navigation controls container */
.nav-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 992px) {
  .news-hub-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }
}

@media (max-width: 768px) {
  .mobile-menu-btn {
    display: block;
  }
  
  .nav-wrapper {
    position: fixed;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100vh;
    background: white;
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 2rem;
    transition: left 0.3s ease;
    z-index: 1002;
  }
  
  .nav-wrapper.active {
    left: 0;
  }
  
  .mobile-close-btn {
    display: block;
    position: absolute;
    top: 1rem;
    right: 1rem;
  }
  
  .nav-links {
    flex-direction: column;
    width: 100%;
    padding: 2rem;
  }
  
  .dropdown-content {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    background: #f8f9fa;
    margin-left: 1rem;
  }
  
  .hero-title {
    font-size: 2.5rem;
  }
  
  .hero-tagline {
    font-size: 1.2rem;
  }
  
  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .recruitment-cta {
    grid-template-columns: 1fr;
  }
  
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .content-wrapper {
    padding: 0 1rem;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .section-title {
    font-size: 2rem;
  }
  
  .service-card,
  .news-item {
    margin-bottom: 1rem;
  }
}

/* Accessibility */
.skip-to-main {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.skip-to-main:focus {
  position: fixed;
  top: 10px;
  left: 10px;
  width: auto;
  height: auto;
  padding: 0.5rem 1rem;
  background: var(--primary-color);
  color: white;
  text-decoration: none;
  border-radius: 4px;
  z-index: 10000;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* Scroll progress bar */
.scroll-progress {
  position: fixed;
  top: var(--header-height);
  left: 0;
  width: 0%;
  height: 3px;
  background: var(--accent-color);
  z-index: 999;
  transition: width 0.1s ease;
}

/* Animations */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Dark mode transitions */
* {
  transition: color 0.3s ease, background-color 0.3s ease, border-color 0.3s ease;
}