/*
Theme Name: Digital Seva Kendra
Theme URI: https://digitalseva.gov.in
Author: Digital Seva
Description: A citizen services portal theme for Digital Seva Kendra / CSC centers.
Version: 1.0
License: GNU General Public License v2 or later
Text Domain: digital-seva
*/

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Segoe UI', Arial, sans-serif; color: #222; background: #f5f5f5; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; }

:root {
  --saffron: #FF6600;
  --navy: #003580;
  --green: #138808;
  --white: #ffffff;
  --light: #f0f4ff;
  --shadow: 0 2px 12px rgba(0,0,0,0.1);
}

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

/* ===== TOP BAR ===== */
.top-bar { background: var(--navy); color: #cce; font-size: 13px; padding: 6px 0; }
.top-bar-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; }
.top-bar span i { margin-right: 6px; color: var(--saffron); }
.lang-btns { display: flex; gap: 6px; }
.lang-btns button {
  background: transparent; border: 1px solid #aac; color: #cce;
  padding: 2px 10px; border-radius: 3px; cursor: pointer; font-size: 12px;
}
.lang-btns button.active { background: var(--saffron); border-color: var(--saffron); color: #fff; }

/* ===== HEADER ===== */
.header { background: var(--white); box-shadow: var(--shadow); position: sticky; top: 0; z-index: 100; }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; }
.logo { display: flex; align-items: center; gap: 12px; }
.logo img { height: 56px; }
.logo h1 { font-size: 20px; color: var(--navy); font-weight: 700; line-height: 1.2; }
.logo h1 a { color: var(--navy); }
.logo p { font-size: 12px; color: var(--saffron); font-weight: 500; }

/* WordPress nav menu */
.main-nav { display: flex; gap: 4px; }
.main-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.main-nav ul li a {
  display: block; padding: 8px 14px; border-radius: 4px; font-weight: 600;
  font-size: 14px; color: var(--navy); transition: background 0.2s, color 0.2s;
}
.main-nav ul li a:hover,
.main-nav ul li.current-menu-item a { background: var(--navy); color: #fff; }
.hamburger { display: none; background: none; border: none; font-size: 22px; color: var(--navy); cursor: pointer; }

/* ===== MARQUEE ===== */
.marquee-bar { background: var(--saffron); color: #fff; padding: 7px 0; font-size: 13px; font-weight: 500; }

/* ===== HERO SLIDER ===== */
.hero-slider { position: relative; overflow: hidden; height: 480px; }
.slide {
  position: absolute; inset: 0; display: flex; align-items: center;
  justify-content: space-between; padding: 0 60px;
  opacity: 0; transition: opacity 0.7s ease, transform 0.7s ease;
  transform: translateX(40px);
}
.slide.active { opacity: 1; transform: translateX(0); z-index: 2; }
.slide-content { max-width: 580px; color: #fff; }
.slide-badge {
  display: inline-flex; align-items: center; gap: 7px;
  background: rgba(255,255,255,0.15); border: 1px solid rgba(255,255,255,0.3);
  color: #fff; font-size: 13px; font-weight: 600; padding: 5px 14px;
  border-radius: 20px; margin-bottom: 18px; backdrop-filter: blur(4px);
}
.slide-content h2 { font-size: 38px; font-weight: 800; line-height: 1.2; margin-bottom: 14px; text-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.slide-content p { font-size: 16px; opacity: 0.9; margin-bottom: 28px; line-height: 1.6; }
.slide-btns { display: flex; gap: 14px; flex-wrap: wrap; }
.btn-primary {
  background: var(--saffron); color: #fff; padding: 12px 28px;
  border-radius: 6px; font-weight: 700; font-size: 15px;
  transition: background 0.2s, transform 0.2s; display: inline-block;
}
.btn-primary:hover { background: #e05500; transform: translateY(-2px); }
.btn-outline {
  background: transparent; color: #fff; padding: 12px 28px;
  border-radius: 6px; font-weight: 700; font-size: 15px; border: 2px solid rgba(255,255,255,0.7);
  transition: background 0.2s, transform 0.2s; display: inline-block;
}
.btn-outline:hover { background: rgba(255,255,255,0.15); transform: translateY(-2px); }
.slide-icon {
  font-size: 160px; color: rgba(255,255,255,0.08);
  position: absolute; right: 60px; top: 50%; transform: translateY(-50%);
  pointer-events: none; line-height: 1;
}
/* Arrows */
.slider-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,0.15); border: 2px solid rgba(255,255,255,0.4);
  color: #fff; width: 46px; height: 46px; border-radius: 50%;
  font-size: 16px; cursor: pointer; z-index: 10;
  transition: background 0.2s; backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
}
.slider-arrow:hover { background: var(--saffron); border-color: var(--saffron); }
.slider-arrow.prev { left: 16px; }
.slider-arrow.next { right: 16px; }
/* Dots */
.slider-dots { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; z-index: 10; }
.dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: rgba(255,255,255,0.4); cursor: pointer; transition: background 0.3s, transform 0.3s;
}
.dot.active { background: var(--saffron); transform: scale(1.3); }

/* ===== STATS ===== */
.stats { background: var(--white); padding: 36px 16px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.stat-card { text-align: center; padding: 24px 12px; border-radius: 8px; background: var(--light); border-top: 4px solid var(--saffron); }
.stat-card h3 { font-size: 36px; color: var(--navy); font-weight: 800; }
.stat-card p { font-size: 13px; color: #555; margin-top: 4px; font-weight: 500; }

/* ===== SERVICES ===== */
.services { padding: 50px 16px; background: #f5f5f5; }
.section-title { text-align: center; font-size: 28px; color: var(--navy); font-weight: 800; margin-bottom: 32px; position: relative; }
.section-title::after { content: ''; display: block; width: 60px; height: 4px; background: var(--saffron); margin: 10px auto 0; border-radius: 2px; }
.services-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; }
.service-card {
  background: var(--white); border-radius: 10px; padding: 28px 20px 22px;
  text-align: center; box-shadow: var(--shadow); transition: transform 0.2s, box-shadow 0.2s;
  border-bottom: 4px solid transparent;
}
.service-card:hover { transform: translateY(-5px); box-shadow: 0 8px 24px rgba(0,0,0,0.13); border-bottom-color: var(--saffron); }
.service-card i { font-size: 36px; color: var(--saffron); margin-bottom: 14px; }
.service-card h3 { font-size: 15px; color: var(--navy); font-weight: 700; margin-bottom: 8px; }
.service-card p { font-size: 13px; color: #666; margin-bottom: 16px; line-height: 1.5; }
.btn-apply {
  display: inline-block; background: var(--navy); color: #fff;
  padding: 8px 20px; border-radius: 4px; font-size: 13px; font-weight: 600;
  transition: background 0.2s;
}
.btn-apply:hover { background: var(--saffron); }
.service-card.hidden { display: none; }

/* ===== ABOUT ===== */
.about { background: var(--white); padding: 60px 16px; }
.about-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.about-text h2 { font-size: 26px; color: var(--navy); font-weight: 800; margin-bottom: 16px; }
.about-text p { color: #555; line-height: 1.7; margin-bottom: 20px; }
.about-text ul { display: flex; flex-direction: column; gap: 10px; }
.about-text li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: #333; }
.about-text li i { color: var(--green); font-size: 16px; }
.about-img img { border-radius: 10px; box-shadow: var(--shadow); width: 100%; height: 300px; object-fit: cover; }

/* ===== CONTACT ===== */
.contact { background: var(--light); padding: 60px 16px; }
.contact-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 40px; }
.contact-info { display: flex; flex-direction: column; gap: 18px; padding-top: 10px; }
.contact-info p { display: flex; align-items: flex-start; gap: 12px; font-size: 15px; color: #444; }
.contact-info i { color: var(--saffron); font-size: 18px; margin-top: 2px; }
.contact-form { display: flex; flex-direction: column; gap: 12px; }
.contact-form input, .contact-form textarea {
  padding: 12px 14px; border: 1px solid #ccc; border-radius: 6px;
  font-size: 14px; outline: none; transition: border 0.2s; width: 100%;
}
.contact-form input:focus, .contact-form textarea:focus { border-color: var(--navy); }
.contact-form button {
  background: var(--navy); color: #fff; border: none; padding: 13px;
  border-radius: 6px; font-size: 15px; font-weight: 700; cursor: pointer; transition: background 0.2s;
}
.contact-form button:hover { background: var(--saffron); }

/* ===== FOOTER ===== */
.footer { background: var(--navy); color: #cce; padding: 48px 16px 20px; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 32px; }
.footer h3 { color: #fff; font-size: 18px; margin-bottom: 10px; }
.footer h4 { color: var(--saffron); font-size: 14px; margin-bottom: 12px; text-transform: uppercase; letter-spacing: 0.5px; }
.footer p { font-size: 13px; line-height: 1.7; }
.footer-nav ul { list-style: none; margin: 0; padding: 0; }
.footer-nav ul li a { display: block; font-size: 13px; color: #aac; margin-bottom: 6px; transition: color 0.2s; }
.footer-nav ul li a:hover { color: var(--saffron); }
.footer-links a { display: block; font-size: 13px; color: #aac; margin-bottom: 6px; transition: color 0.2s; }
.footer-links a:hover { color: var(--saffron); }
.social-links { display: flex; gap: 12px; margin-top: 4px; }
.social-links a { font-size: 20px; color: #aac; transition: color 0.2s; }
.social-links a:hover { color: var(--saffron); }
.footer-bottom { border-top: 1px solid #1a3a6e; padding-top: 16px; text-align: center; font-size: 12px; color: #889; }

/* ===== BACK TO TOP ===== */
.back-to-top {
  position: fixed; bottom: 28px; right: 28px; background: var(--saffron); color: #fff;
  border: none; width: 44px; height: 44px; border-radius: 50%; font-size: 18px;
  cursor: pointer; box-shadow: 0 4px 12px rgba(0,0,0,0.2); display: none;
  align-items: center; justify-content: center; transition: background 0.2s; z-index: 200;
}
.back-to-top:hover { background: var(--navy); }

/* ===== TOAST ===== */
.toast {
  position: fixed; bottom: 80px; right: 28px; background: #222; color: #fff;
  padding: 12px 20px; border-radius: 6px; font-size: 14px; opacity: 0;
  transition: opacity 0.3s; pointer-events: none; z-index: 300;
}
.toast.show { opacity: 1; }

/* ===== WordPress defaults ===== */
.wp-block-image img { border-radius: 8px; }
.aligncenter { display: block; margin: 0 auto; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .about-inner { grid-template-columns: 1fr; }
  .about-img { display: none; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .hero-slider { height: 420px; }
  .slide { padding: 0 50px; }
  .slide-content h2 { font-size: 28px; }
  .slide-icon { font-size: 110px; }
}

@media (max-width: 640px) {
  .main-nav ul { display: none; flex-direction: column; position: absolute; top: 76px; left: 0; right: 0; background: #fff; box-shadow: var(--shadow); padding: 12px 0; }
  .main-nav ul.open { display: flex; }
  .main-nav ul li a { padding: 12px 24px; border-radius: 0; }
  .hamburger { display: block; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr; }
  .services-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
  .hero-slider { height: auto; min-height: 380px; }
  .slide { padding: 40px 20px; flex-direction: column; justify-content: center; position: relative; }
  .slide.active { position: relative; }
  .slide:not(.active) { display: none; }
  .slide-content h2 { font-size: 22px; }
  .slide-content p { font-size: 14px; }
  .slide-icon { display: none; }
  .slider-arrow { width: 36px; height: 36px; font-size: 13px; }
}
