/* ===== LabhMitra.in — Government Official Theme ===== */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Devanagari:wght@400;500;600;700&family=Mukta:wght@400;500;600;700;800&family=Source+Serif+4:wght@400;600&display=swap');

:root {
  --primary: #1a3a6b;
  --primary-dark: #0f2347;
  --primary-light: #2d5aa0;
  --accent: #f47b20;
  --accent-light: #ffa64d;
  --gold: #c9a227;
  --white: #ffffff;
  --bg: #f4f6fb;
  --bg-card: #ffffff;
  --text: #1a1a2e;
  --text-muted: #5a6a85;
  --text-light: #8896ab;
  --border: #d0dae8;
  --border-light: #e8eef6;
  --success: #1a8a3c;
  --shadow: 0 2px 12px rgba(26,58,107,0.10);
  --shadow-lg: 0 8px 32px rgba(26,58,107,0.15);
  --radius: 8px;
  --radius-lg: 14px;
}

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

body {
  font-family: 'Mukta', 'Noto Sans Devanagari', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  font-size: 16px;
}

a { color: var(--primary); text-decoration: none; transition: all 0.2s; }
a:hover { color: var(--accent); }

/* ===== HEADER ===== */
.site-header {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 60%, var(--primary-light) 100%);
  box-shadow: 0 3px 20px rgba(15,35,71,0.4);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-top {
  background: var(--primary-dark);
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.header-top-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: rgba(255,255,255,0.7);
}

.header-top-inner a { color: rgba(255,255,255,0.7); }
.header-top-inner a:hover { color: var(--accent-light); }

.header-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.logo-icon {
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--accent), var(--gold));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  box-shadow: 0 4px 12px rgba(244,123,32,0.4);
  flex-shrink: 0;
}

.logo-text h1,
.logo-text .logo-name {
  font-size: 24px;
  font-weight: 800;
  color: white;
  letter-spacing: -0.5px;
  line-height: 1.1;
  margin: 0;
}

.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;
}

.logo-text span {
  font-size: 11px;
  color: rgba(255,255,255,0.65);
  font-weight: 400;
  letter-spacing: 0.5px;
}

/* Search Bar */
.header-search {
  flex: 1;
  max-width: 480px;
}

.search-form {
  display: flex;
  background: rgba(255,255,255,0.12);
  border: 1.5px solid rgba(255,255,255,0.25);
  border-radius: 30px;
  overflow: hidden;
  transition: all 0.3s;
}

.search-form:focus-within {
  background: rgba(255,255,255,0.2);
  border-color: rgba(255,255,255,0.5);
  box-shadow: 0 0 0 3px rgba(255,255,255,0.1);
}

.search-form input {
  flex: 1;
  padding: 10px 18px;
  background: transparent;
  border: none;
  outline: none;
  color: white;
  font-family: 'Mukta', sans-serif;
  font-size: 14px;
}

.search-form input::placeholder { color: rgba(255,255,255,0.55); }

.search-form button {
  padding: 10px 20px;
  background: var(--accent);
  border: none;
  cursor: pointer;
  color: white;
  font-size: 16px;
  transition: background 0.2s;
}

.search-form button:hover { background: var(--accent-light); }

/* Nav */
.site-nav {
  background: rgba(255,255,255,0.08);
  border-top: 1px solid rgba(255,255,255,0.1);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  gap: 2px;
  overflow-x: auto;
  scrollbar-width: none;
}

.nav-inner::-webkit-scrollbar { display: none; }

.nav-inner a {
  padding: 10px 14px;
  color: rgba(255,255,255,0.8);
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  transition: all 0.2s;
}

.nav-inner a:hover, .nav-inner a.active {
  color: white;
  border-bottom-color: var(--accent);
}

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

.page-wrapper {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 28px;
  padding: 28px 0;
}

/* ===== HERO BANNER ===== */
.hero-banner {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  padding: 40px 20px;
  text-align: center;
  color: white;
  position: relative;
  overflow: hidden;
}

.hero-banner::before {
  content: '';
  position: absolute;
  top: -40px; right: -40px;
  width: 200px; height: 200px;
  background: rgba(255,255,255,0.05);
  border-radius: 50%;
}

.hero-banner::after {
  content: '';
  position: absolute;
  bottom: -60px; left: -20px;
  width: 250px; height: 250px;
  background: rgba(255,255,255,0.04);
  border-radius: 50%;
}

.hero-banner h2 {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 8px;
  position: relative;
}

.hero-banner p {
  font-size: 15px;
  opacity: 0.85;
  position: relative;
}

/* ===== CATEGORY PILLS ===== */
.category-strip {
  background: white;
  padding: 16px 0;
  border-bottom: 2px solid var(--border-light);
  overflow-x: auto;
}

.category-strip-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  gap: 10px;
  white-space: nowrap;
}

.cat-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 25px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  transition: all 0.2s;
  white-space: nowrap;
  text-decoration: none;
}

.cat-pill:hover, .cat-pill.active {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(26,58,107,0.25);
}

/* ===== ARTICLE CARDS ===== */
.section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--primary);
  padding-bottom: 10px;
  border-bottom: 3px solid var(--accent);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.articles-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.article-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow);
  transition: all 0.25s;
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.article-card:hover {
  border-color: var(--primary-light);
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.article-card-icon {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}

.article-card-body { flex: 1; }

.article-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.cat-badge {
  background: var(--primary);
  color: white;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  letter-spacing: 0.3px;
}

.date-text {
  font-size: 12px;
  color: var(--text-muted);
}

.article-card h3 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 7px;
  line-height: 1.4;
}

.article-card h3 a { color: var(--text); }
.article-card h3 a:hover { color: var(--primary); }

.article-card p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 10px;
}

.read-more {
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.read-more:hover { color: var(--accent); gap: 8px; }

/* ===== SIDEBAR ===== */
.sidebar { display: flex; flex-direction: column; gap: 20px; }

.sidebar-widget {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.widget-header {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  padding: 12px 16px;
  color: white;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.widget-body { padding: 14px; }

.widget-list { list-style: none; }

.widget-list li {
  padding: 9px 0;
  border-bottom: 1px solid var(--border-light);
  font-size: 14px;
}

.widget-list li:last-child { border-bottom: none; }

.widget-list li a {
  color: var(--text);
  display: flex;
  align-items: flex-start;
  gap: 8px;
  line-height: 1.4;
}

.widget-list li a:hover { color: var(--primary); }

.widget-list li a::before {
  content: '▸';
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 2px;
}

/* Important Links Widget */
.important-links a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  background: var(--bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  transition: all 0.2s;
}

.important-links a:last-child { margin-bottom: 0; }
.important-links a:hover {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

/* ===== ARTICLE PAGE ===== */
.article-page {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow);
}

.article-header { margin-bottom: 24px; }

.article-header h1 {
  font-size: 26px;
  font-weight: 800;
  color: var(--primary-dark);
  line-height: 1.35;
  margin-bottom: 12px;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  font-size: 13px;
  color: var(--text-muted);
  padding-bottom: 16px;
  border-bottom: 2px solid var(--border-light);
}

.article-content { font-family: 'Source Serif 4', 'Mukta', sans-serif; }

.article-content h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--primary);
  margin: 24px 0 12px;
  padding-left: 14px;
  border-left: 4px solid var(--accent);
}

.article-content h3 {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  margin: 18px 0 8px;
}

.article-content p {
  font-size: 15.5px;
  line-height: 1.8;
  margin-bottom: 14px;
  color: #2a2a3e;
}

.article-content ol, .article-content ul {
  padding-left: 22px;
  margin-bottom: 14px;
}

.article-content li {
  font-size: 15px;
  line-height: 1.8;
  margin-bottom: 4px;
}

.article-content strong { color: var(--primary-dark); }

/* Official Link Box */
.official-link-box {
  background: linear-gradient(135deg, #e8f0fb, #d4e3f8);
  border: 2px solid var(--primary-light);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 20px 0;
  display: flex;
  align-items: center;
  gap: 14px;
}

.official-link-box .icon { font-size: 28px; }

.official-link-box strong {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.official-link-box a {
  font-size: 15px;
  font-weight: 700;
  color: var(--primary);
}

/* Tags */
.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border-light);
}

.tag {
  padding: 4px 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 12px;
  color: var(--text-muted);
}

/* Breadcrumb */
.breadcrumb {
  padding: 12px 0;
  font-size: 13px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.breadcrumb a { color: var(--primary); }
.breadcrumb span { color: var(--text-light); }

/* ===== SEARCH PAGE ===== */
.search-results-header {
  background: white;
  padding: 20px;
  border-radius: var(--radius-lg);
  margin-bottom: 20px;
  border: 1px solid var(--border-light);
}

/* ===== ADMIN PANEL ===== */
.admin-wrapper {
  max-width: 900px;
  margin: 0 auto;
  padding: 28px 20px;
}

.admin-header {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  color: white;
  padding: 20px 28px;
  border-radius: var(--radius-lg);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.admin-header h2 { font-size: 22px; font-weight: 800; }

.admin-card {
  background: white;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow);
  margin-bottom: 20px;
}

.admin-card h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--border-light);
}

.form-group { margin-bottom: 18px; }

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-family: 'Mukta', sans-serif;
  font-size: 14px;
  color: var(--text);
  background: var(--bg);
  transition: border-color 0.2s;
  outline: none;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--primary-light);
  background: white;
  box-shadow: 0 0 0 3px rgba(26,58,107,0.08);
}

.form-group textarea { resize: vertical; min-height: 200px; }

.btn {
  padding: 10px 24px;
  border: none;
  border-radius: var(--radius);
  font-family: 'Mukta', sans-serif;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}

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

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(26,58,107,0.3);
}

.btn-danger { background: #dc3545; color: white; }
.btn-danger:hover { background: #b02a37; }

.btn-sm { padding: 6px 14px; font-size: 12px; }

/* Articles Table */
.articles-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.articles-table th {
  background: var(--bg);
  padding: 10px 14px;
  text-align: left;
  font-weight: 700;
  color: var(--text-muted);
  border-bottom: 2px solid var(--border);
}

.articles-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-light);
  vertical-align: middle;
}

.articles-table tr:hover td { background: var(--bg); }

.status-badge {
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
}

.status-published { background: #d1f7e0; color: #1a8a3c; }
.status-draft { background: #fff3cd; color: #856404; }

/* Alerts */
.alert {
  padding: 12px 18px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  font-size: 14px;
  font-weight: 500;
}

.alert-success { background: #d1f7e0; color: #1a8a3c; border: 1px solid #a3e9bb; }
.alert-error { background: #ffe0e0; color: #c0392b; border: 1px solid #ffb3b3; }

/* ===== FOOTER ===== */
.site-footer {
  background: var(--primary-dark);
  color: rgba(255,255,255,0.8);
  padding: 40px 0 20px;
  margin-top: 40px;
}

.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 30px;
}

.footer-col h4 {
  color: white;
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--accent);
  display: inline-block;
}

.footer-col p { font-size: 13px; line-height: 1.7; }

.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 7px; }
.footer-col ul li a { color: rgba(255,255,255,0.7); font-size: 13px; }
.footer-col ul li a:hover { color: var(--accent-light); }

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 20px 0;
  border-top: 1px solid rgba(255,255,255,0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  flex-wrap: wrap;
  gap: 8px;
}

/* ===== PAGINATION ===== */
.pagination {
  display: flex;
  gap: 6px;
  justify-content: center;
  margin-top: 24px;
}

.pagination a, .pagination span {
  padding: 8px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  background: white;
  transition: all 0.2s;
}

.pagination a:hover, .pagination .current {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

/* ===== CATEGORY PAGE ===== */
.category-hero {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  padding: 28px;
  border-radius: var(--radius-lg);
  color: white;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.category-hero-icon {
  font-size: 40px;
  width: 70px;
  height: 70px;
  background: rgba(255,255,255,0.15);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.category-hero h2 { font-size: 22px; font-weight: 800; margin-bottom: 4px; }
.category-hero p { font-size: 14px; opacity: 0.85; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .page-wrapper {
    grid-template-columns: 1fr;
  }

  .sidebar { display: none; }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 600px) {
  .header-main { flex-wrap: wrap; }
  .header-search { width: 100%; max-width: 100%; }
  .logo-text h1 { font-size: 20px; }
  .hero-banner h2 { font-size: 20px; }
  .footer-grid { grid-template-columns: 1fr; }
  .article-page { padding: 18px; }
  .article-header h1 { font-size: 20px; }
}

/* ===== NO RESULTS ===== */
.no-results {
  text-align: center;
  padding: 50px 20px;
  color: var(--text-muted);
}

.no-results .icon { font-size: 50px; margin-bottom: 12px; }
.no-results h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }

/* ===== TOP NOTICE BAR ===== */
.notice-bar {
  background: var(--accent);
  color: white;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 20px;
  font-size: 12.5px;
  font-weight: 600;
  overflow: hidden;
}
.notice-label { flex-shrink: 0; white-space: nowrap; }
.notice-ticker { flex: 1; position: relative; height: 18px; overflow: hidden; }
.notice-item {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  opacity: 0;
  transition: opacity 0.6s ease;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 18px;
}
.notice-item.active { opacity: 1; }
.notice-bar a { color: white; text-decoration: underline; }

/* ===== BACK TO TOP ===== */
#back-to-top {
  position: fixed;
  bottom: 28px;
  right: 24px;
  width: 44px;
  height: 44px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s, transform 0.2s;
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
  z-index: 999;
  line-height: 1;
}
#back-to-top.visible { opacity: 1; visibility: visible; }
#back-to-top:hover { background: var(--accent); transform: translateY(-3px); }

/* ===== SOCIAL SHARE ===== */
.share-box {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
  padding: 16px 20px;
  background: var(--bg-light);
  border-radius: 10px;
  border: 1px solid var(--border);
}
.share-label { font-size: 14px; font-weight: 700; color: var(--text-main); }
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 14px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.15s;
}
.share-btn:hover { opacity: 0.85; transform: translateY(-1px); }
.share-wa  { background: #25D366; color: white; }
.share-fb  { background: #1877F2; color: white; }
.share-tw  { background: #1DA1F2; color: white; }
.share-copy { background: var(--primary); color: white; }

/* ===== MOBILE NAV TOGGLE ===== */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: rgba(255,255,255,0.9);
  font-size: 22px;
  cursor: pointer;
  padding: 8px 14px;
  margin-left: auto;
}

@media (max-width: 640px) {
  .nav-toggle { display: block; }
  .nav-inner {
    display: none;
    flex-direction: column;
    width: 100%;
    padding: 4px 0 10px;
  }
  .nav-inner a {
    border-radius: 0;
    padding: 10px 18px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }
}
