/* 
 * Niyagama Pradeshiya Sabha Payment Portal
 * Premium Modern Government Theme 
 * Colors: Deep Maroon, Gold, Clean White, and Sleek Dark Grays.
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Outfit:wght@400;600;700&display=swap');

:root {
  --primary-color: #8B1538;     /* Deep Maroon - Sri Lankan flag inspired */
  --secondary-color: #D4AF37;   /* Elegant Gold */
  --accent-color: #F8E5A6;      /* Soft Gold Accent */
  
  --bg-color: #f4f6f8;
  --surface-color: #ffffff;
  
  --text-dark: #1F2937;
  --text-muted: #6B7280;
  --text-light: #ffffff;

  --border-radius-sm: 8px;
  --border-radius-md: 16px;
  --border-radius-lg: 24px;
  
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
  --shadow-md: 0 8px 16px rgba(139, 21, 56, 0.08);
  --shadow-lg: 0 16px 32px rgba(139, 21, 56, 0.12);
  
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-dark);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  color: var(--primary-color);
}

a {
  text-decoration: none;
  color: var(--primary-color);
  transition: var(--transition);
}

a:hover {
  color: var(--secondary-color);
}

/* Header & Nav */
.navbar {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 15px 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: var(--shadow-sm);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 15px;
}

.nav-brand img {
  height: 50px;
  width: auto;
}

.nav-brand h2 {
  font-size: 1.5rem;
  margin: 0;
  color: var(--primary-color);
}

.nav-brand p {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-family: 'Inter', sans-serif;
  letter-spacing: 0.5px;
}

.nav-links {
  display: flex;
  gap: 30px;
  list-style: none;
}

.nav-links li a {
  font-weight: 600;
  font-size: 0.95rem;
  padding: 8px 12px;
  border-radius: var(--border-radius-sm);
}

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

/* Button Styles */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  font-weight: 600;
  border-radius: var(--border-radius-md);
  cursor: pointer;
  border: none;
  font-family: 'Outfit', sans-serif;
  letter-spacing: 0.5px;
  transition: var(--transition);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-color) 0%, #a01841 100%);
  color: var(--text-light);
  box-shadow: 0 4px 10px rgba(139, 21, 56, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(139, 21, 56, 0.4);
  color: var(--text-light);
}

.btn-secondary {
  background: var(--secondary-color);
  color: var(--text-dark);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  background: #ecd47a;
}

/* Hero Section */
.hero {
  position: relative;
  padding: 40px 5%;
  background: linear-gradient(to right, rgba(255,255,255,0.98), rgba(255,255,255,0.85)), url('../img/hero-bg.jpg') center/cover;
  border-radius: 0 0 var(--border-radius-lg) var(--border-radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: auto;
  box-shadow: var(--shadow-sm);
}

.hero-content {
  max-width: 800px;
  animation: fadeUp 0.8s ease forwards;
}

.hero-content h1 {
  font-size: 2.5rem;
  line-height: 1.2;
  margin-bottom: 15px;
}

.hero-content p {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

/* Section Title */
.section-title {
  text-align: center;
  margin: 60px 0 40px;
}

.section-title h2 {
  font-size: 2.5rem;
  position: relative;
  display: inline-block;
}

.section-title h2::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: var(--secondary-color);
  border-radius: 2px;
}

/* Service Cards */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  padding: 0 5% 80px;
}

.service-card {
  background: var(--surface-color);
  border-radius: var(--border-radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  position: relative;
  border: 1px solid rgba(139, 21, 56, 0.05);
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.service-img {
  height: 200px;
  background-size: cover;
  background-position: center;
  position: relative;
}

.service-img::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 40%, rgba(0,0,0,0.6));
}

.service-content {
  padding: 25px;
}

.service-content h3 {
  font-size: 1.4rem;
  margin-bottom: 10px;
}

.service-rate {
  font-size: 1.2rem;
  color: var(--secondary-color);
  font-weight: 700;
  margin-bottom: 20px;
}

/* Form Styles */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-dark);
}

.form-control {
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid #e5e7eb;
  border-radius: var(--border-radius-sm);
  font-size: 1rem;
  font-family: 'Inter', sans-serif;
  transition: var(--transition);
  background: #f9fafb;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(139, 21, 56, 0.1);
}

/* Glassmorphic Container */
.glass-container {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: var(--border-radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-lg);
}

/* Footer */
footer {
  background: var(--primary-color);
  color: var(--text-light);
  padding: 60px 5% 30px;
  margin-top: auto;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-col h3 {
  color: var(--secondary-color);
  margin-bottom: 20px;
}

.footer-col p, .footer-col ul li {
  color: rgba(255,255,255,0.8);
  margin-bottom: 10px;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li a {
  color: rgba(255,255,255,0.8);
}

.footer-col ul li a:hover {
  color: var(--secondary-color);
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-size: 0.9rem;
  color: rgba(255,255,255,0.6);
}

/* Animations */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive Media Queries */
.mobile-menu-toggle {
  display: none;
  font-size: 1.5rem;
  color: var(--primary-color);
  cursor: pointer;
}

@media (max-width: 900px) {
  .hero {
    padding: 30px 5%;
  }
  .hero-content h1 {
    font-size: 2rem;
  }
}

@media (max-width: 768px) {
  /* Header & Navigation */
  .navbar {
    padding: 15px 20px;
  }
  .nav-brand h2 {
    font-size: 1.2rem;
  }
  .mobile-menu-toggle {
    display: block;
  }
  .nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    box-shadow: 0 10px 15px rgba(0,0,0,0.1);
    padding: 20px 0;
    gap: 15px;
    text-align: center;
  }
  .nav-links.active {
    display: flex;
  }
  
  /* Hero Section */
  .hero {
    padding: 30px 20px;
  }
  .hero-content h1 {
    font-size: 1.8rem;
  }
  .hero-content p {
    font-size: 1rem;
  }
  
  /* General Sections & Grid Layouts */
  .container {
    padding: 40px 20px !important; /* Overriding inline padding for mobile */
  }
  .section-title h2 {
    font-size: 2rem;
  }
  .row {
    flex-direction: column !important; /* Stack columns on mobile */
    gap: 20px !important;
  }
  
  /* Service Cards */
  .services-grid {
    grid-template-columns: 1fr;
  }
  
  /* Glass Container (Forms/Checkout) */
  .glass-container {
    padding: 25px !important; /* Reduce padding on mobile */
  }
  
  /* Footer */
  footer {
    padding: 40px 20px 20px;
  }
  .footer-content {
    grid-template-columns: 1fr;
    gap: 30px;
    text-align: center;
  }
}
