/* ============================================================
   LACHHARSAR PORTAL — Complete Styles
   ============================================================ */
:root {
  --primary: #0c2340;
  --accent: #ff9933;
  --bg: #ffffff;
  --text: #1e293b;
  --light-bg: #f9fafb;
  --gray-500: #64748b;
  --gray-700: #334155;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 8px 24px rgba(0,0,0,0.08);
  --shadow-lg: 0 16px 40px rgba(0,0,0,0.12);
  --radius: 16px;
  --transition: all 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', 'Noto Sans Devanagari', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Language toggle */
.lang-hi, .lang-en { display: none; }
body[data-lang="hi"] .lang-hi { display: block; }
body[data-lang="en"] .lang-en { display: block; }
body[data-lang="hi"] .lang-hi.inline { display: inline; }
body[data-lang="en"] .lang-en.inline { display: inline; }

/* NAVBAR */
.navbar {
  position: sticky; top: 0; z-index: 1000;
  background: var(--primary);
  box-shadow: var(--shadow-md);
}
.nav-container {
  max-width: 1280px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.75rem 1.25rem; gap: 1rem;
}
.brand {
  display: flex; align-items: center; gap: 0.6rem;
  font-weight: 800; font-size: 1.2rem; color: #fff;
  text-decoration: none;
}
.brand-logo {
  width: 36px; height: 36px; border-radius: 8px;
  object-fit: cover; background: #fff;
}
.nav-links { display: flex; gap: 1.5rem; align-items: center; }
.nav-links a {
  color: #cbd5e1; text-decoration: none;
  font-weight: 500; font-size: 0.95rem;
  transition: var(--transition); position: relative;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0;
  width: 0; height: 2px; background: var(--accent);
  transition: width 0.3s;
}
.nav-links a:hover::after { width: 100%; }

.nav-actions { display: flex; align-items: center; gap: 0.75rem; }
.lang-btn {
  background: transparent; color: #fff;
  border: 1.5px solid var(--accent); border-radius: 40px;
  padding: 0.4rem 0.9rem; font-size: 0.85rem; font-weight: 600;
  cursor: pointer; transition: var(--transition); font-family: inherit;
}
.lang-btn:hover { background: var(--accent); color: var(--primary); }
.hamburger {
  display: none; background: none; border: none;
  color: #fff; font-size: 1.6rem; cursor: pointer;
}

/* NOTICE BAR */
.notice-bar {
  background: linear-gradient(90deg, var(--accent), #e07e1a);
  color: #fff; padding: 0.85rem 1rem;
  box-shadow: 0 4px 12px rgba(255,153,51,0.3);
  animation: slideDown 0.4s ease;
}
@keyframes slideDown {
  from { transform: translateY(-100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
.notice-inner {
  max-width: 1280px; margin: 0 auto;
  display: flex; align-items: center; gap: 1rem;
}
.notice-icon { font-size: 1.4rem; animation: bellShake 2s infinite; }
@keyframes bellShake {
  0%, 100% { transform: rotate(0); }
  10%, 30% { transform: rotate(-10deg); }
  20%, 40% { transform: rotate(10deg); }
}
.notice-content { flex: 1; display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.notice-content strong {
  background: rgba(0,0,0,0.15); padding: 0.2rem 0.7rem; border-radius: 20px;
}
.notice-close {
  background: rgba(255,255,255,0.2); border: none; color: #fff;
  width: 30px; height: 30px; border-radius: 50%;
  cursor: pointer; transition: var(--transition); font-size: 0.9rem;
}
.notice-close:hover { background: rgba(255,255,255,0.4); transform: rotate(90deg); }

/* HERO */
.hero {
  background: linear-gradient(145deg, #f1f5f9 0%, var(--bg) 100%);
  padding: 3rem 1.25rem 4rem;
}
.hero-grid {
  max-width: 1280px; margin: 0 auto;
  display: grid; grid-template-columns: 1.1fr 0.9fr;
  gap: 3rem; align-items: center;
}
.hero-tag {
  display: inline-block; background: rgba(255,153,51,0.15);
  color: var(--primary); font-weight: 600; font-size: 0.8rem;
  padding: 0.35rem 0.9rem; border-radius: 40px; margin-bottom: 1rem;
}
.hero-name {
  font-size: 3.5rem; font-weight: 800; color: var(--primary);
  line-height: 1.15; margin-bottom: 0.3rem;
}
.hero-subtitle {
  font-size: 1.3rem; font-weight: 600; color: var(--accent);
  margin-bottom: 1rem;
}
.hero-desc {
  color: var(--gray-700); font-size: 1.05rem; margin-bottom: 1.5rem;
  line-height: 1.7;
}
.hero-stats { display: flex; gap: 1rem; margin: 1.5rem 0; flex-wrap: wrap; }
.stat-box {
  background: #fff; border-radius: 14px; padding: 1rem 1.5rem;
  box-shadow: var(--shadow-sm); text-align: center;
  border-top: 3px solid var(--accent);
}
.stat-box strong { display: block; font-size: 1.5rem; color: var(--primary); }
.stat-box span { font-size: 0.8rem; color: var(--gray-500); }
.hero-cta { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: 1rem; }
.hero-image { display: flex; justify-content: center; }
.hero-img {
  width: 100%; max-width: 500px; border-radius: 24px;
  box-shadow: var(--shadow-lg); border: 4px solid var(--accent);
  object-fit: cover; max-height: 500px;
}

/* BUTTONS */
.btn-primary {
  background: var(--accent); color: var(--primary);
  border: none; border-radius: 60px;
  padding: 0.75rem 1.75rem; font-weight: 700; font-size: 0.95rem;
  cursor: pointer; transition: var(--transition);
  box-shadow: 0 4px 14px rgba(255,153,51,0.35);
  text-decoration: none; display: inline-block;
  font-family: inherit; text-align: center;
}
.btn-primary:hover {
  background: #e07e1a; color: #fff;
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(255,153,51,0.5);
}
.btn-primary:disabled {
  opacity: 0.6; cursor: not-allowed; transform: none;
}
.btn-outline {
  background: transparent; color: var(--primary);
  border: 2px solid var(--primary); border-radius: 60px;
  padding: 0.7rem 1.6rem; font-weight: 600;
  cursor: pointer; transition: var(--transition);
  text-decoration: none; display: inline-block; font-family: inherit;
}
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-outline-light {
  background: transparent; border: 2px solid var(--accent);
  color: var(--accent); border-radius: 40px;
  padding: 0.45rem 1.2rem; font-weight: 600;
  cursor: pointer; transition: var(--transition);
  font-family: inherit; font-size: 0.85rem;
}
.btn-outline-light:hover { background: var(--accent); color: var(--primary); }
.btn-danger {
  background: #fee2e2; color: #dc2626; border: none;
  padding: 0.45rem 0.9rem; border-radius: 8px;
  font-weight: 600; font-size: 0.8rem; cursor: pointer;
  transition: var(--transition); font-family: inherit;
}
.btn-danger:hover { background: #dc2626; color: #fff; }

/* SECTIONS */
.section { padding: 4rem 1.25rem; }
.section-alt { background: var(--light-bg); }
.section-container { max-width: 1200px; margin: 0 auto; }
.section-title {
  font-size: 2rem; font-weight: 800; color: var(--primary);
  text-align: center; margin-bottom: 2.5rem; position: relative;
}
.section-title::after {
  content: ''; display: block; width: 70px; height: 4px;
  background: var(--accent); margin: 0.75rem auto 0; border-radius: 4px;
}

/* ABOUT */
.about-grid { max-width: 900px; margin: 0 auto; }
.about-text p {
  font-size: 1.05rem; color: var(--gray-700);
  margin-bottom: 1.25rem; line-height: 1.75;
}

/* PANCHAYAT */
.panchayat-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}
.info-card {
  background: #fff; border-radius: var(--radius); padding: 1.75rem;
  box-shadow: var(--shadow-sm); border-top: 4px solid var(--accent);
  transition: var(--transition);
}
.info-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.info-card .icon { font-size: 2rem; margin-bottom: 0.75rem; }
.info-card h4 { color: var(--primary); margin-bottom: 0.5rem; font-weight: 700; }
.info-card p { color: var(--gray-500); font-size: 0.95rem; }

/* GALLERY */
.gallery-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}
.gallery-item {
  position: relative; border-radius: 14px; overflow: hidden;
  box-shadow: var(--shadow-sm); transition: var(--transition);
  cursor: pointer;
}
.gallery-item:hover { transform: scale(1.03); box-shadow: var(--shadow-lg); }
.gallery-item img {
  width: 100%; height: 200px; object-fit: cover; display: block;
}
.gallery-caption {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.85));
  color: #fff; padding: 1.5rem 0.75rem 0.6rem;
  font-size: 0.85rem; font-weight: 600;
}

/* CONTACT */
.contact-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}
.contact-card {
  background: #fff; border-radius: var(--radius); padding: 1.5rem;
  box-shadow: var(--shadow-sm); text-align: center;
  transition: var(--transition);
}
.contact-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.contact-card .icon { font-size: 2.5rem; margin-bottom: 0.75rem; }
.contact-card h4 { color: var(--primary); margin-bottom: 0.5rem; }
.contact-card p { color: var(--gray-700); font-size: 0.95rem; word-break: break-word; }

/* FOOTER */
.footer {
  background: var(--primary); color: #cbd5e1;
  text-align: center; padding: 2.5rem 1rem;
}
.footer-content p { margin: 0.35rem 0; }
.footer-sub { font-size: 0.85rem; color: #94a3b8; }

/* POPUP */
.popup-overlay {
  position: fixed; inset: 0; background: rgba(12,35,64,0.8);
  backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center;
  z-index: 3000; padding: 1rem;
  animation: fadeIn 0.3s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.popup-box {
  background: #fff; border-radius: 24px; padding: 1.5rem;
  max-width: 560px; width: 100%; max-height: 90vh; overflow-y: auto;
  position: relative; box-shadow: 0 24px 60px rgba(0,0,0,0.4);
  animation: popupIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes popupIn {
  from { transform: scale(0.8) translateY(20px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}
.popup-close {
  position: absolute; top: 0.75rem; right: 0.75rem;
  background: #f1f5f9; border: none; border-radius: 50%;
  width: 36px; height: 36px; font-size: 1.1rem;
  cursor: pointer; transition: var(--transition); z-index: 10;
}
.popup-close:hover { background: var(--accent); color: #fff; transform: rotate(90deg); }
.popup-content { text-align: center; }
.popup-content img {
  width: 100%; max-width: 500px; border-radius: 16px;
  display: block; margin: 0 auto;
}

/* ============================================================
   ADMIN STYLES
   ============================================================ */
.admin-body { background: #f1f5f9; min-height: 100vh; }
.admin-gate {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #0c2340, #1e3a5f); padding: 1rem;
}
.admin-login-box {
  background: #fff; border-radius: 24px; padding: 2.5rem 2rem;
  max-width: 420px; width: 100%; text-align: center;
  box-shadow: 0 24px 60px rgba(0,0,0,0.3);
}
.admin-logo {
  font-size: 1.6rem; font-weight: 800; color: #0c2340;
  margin-bottom: 0.5rem;
}
.google-btn {
  width: 100%; display: flex; align-items: center; justify-content: center;
  gap: 0.65rem; background: #fff; border: 2px solid #e2e8f0;
  border-radius: 60px; padding: 0.85rem 1.5rem; font-weight: 600;
  font-size: 0.95rem; color: #0c2340; cursor: pointer;
  transition: var(--transition); font-family: inherit;
}
.google-btn:hover { border-color: #ff9933; background: #fff8ee; }
.google-btn:disabled { opacity: 0.6; cursor: not-allowed; }

.admin-topbar {
  background: #0c2340; color: #fff; padding: 1rem 1.5rem;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1rem; position: sticky; top: 0; z-index: 100;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}
.admin-brand { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.admin-brand .logo { font-size: 1.3rem; font-weight: 800; }
.admin-brand .subtitle { font-size: 0.8rem; color: #94a3b8; }

.admin-main { max-width: 1280px; margin: 0 auto; padding: 2rem 1.5rem; }
.admin-tabs {
  display: flex; gap: 0.5rem; margin-bottom: 1.5rem;
  border-bottom: 2px solid #e2e8f0; flex-wrap: wrap; overflow-x: auto;
  scrollbar-width: thin;
}
.admin-tab {
  background: none; border: none; padding: 0.85rem 1.1rem;
  font-weight: 600; color: #64748b; cursor: pointer;
  border-bottom: 3px solid transparent; transition: var(--transition);
  font-size: 0.9rem; font-family: inherit; white-space: nowrap;
}
.admin-tab:hover { color: #0c2340; }
.admin-tab.active { color: #0c2340; border-bottom-color: #ff9933; }

.admin-panel { display: none; animation: fadeIn 0.3s ease; }
.admin-panel.active { display: block; }
.admin-section-title {
  font-size: 1.5rem; font-weight: 800; color: #0c2340;
  margin-bottom: 0.5rem;
}
.admin-form {
  background: #fff; border-radius: 16px; padding: 1.75rem;
  box-shadow: var(--shadow-sm);
}
.form-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}
.form-group {
  display: flex; flex-direction: column; margin-bottom: 1rem;
}
.form-group label {
  font-weight: 600; font-size: 0.85rem; color: #334155;
  margin-bottom: 0.4rem;
}
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%; padding: 0.7rem 0.9rem;
  border: 1.5px solid #e2e8f0; border-radius: 10px;
  font-family: inherit; font-size: 0.92rem;
  transition: var(--transition); resize: vertical;
  background: #fff;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: #ff9933; outline: none;
  box-shadow: 0 0 0 3px rgba(255,153,51,0.15);
}
.form-group input[type="color"] {
  padding: 0.3rem; height: 48px; cursor: pointer;
}
.code-textarea {
  font-family: 'Courier New', Consolas, monospace;
  background: #0f172a; color: #e2e8f0;
  border: 2px solid #ff9933;
  min-height: 120px; font-size: 0.85rem;
  line-height: 1.5;
}

.dynamic-list {
  display: flex; flex-direction: column; gap: 0.75rem;
}
.dynamic-item {
  background: #fff; border-radius: 12px; padding: 1rem 1.25rem;
  box-shadow: var(--shadow-sm); display: flex;
  justify-content: space-between; align-items: center;
  border-left: 4px solid #ff9933; gap: 1rem; flex-wrap: wrap;
}
.dynamic-item .meta {
  font-size: 0.75rem; color: #94a3b8; margin-top: 0.4rem;
}
.dynamic-item .meta strong { color: #0c2340; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 2rem; }
  .hero-name { font-size: 2.5rem; }
  .hero-image { order: -1; }
  .hero-img { max-width: 100%; }
  .form-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex; flex-direction: column;
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--primary); padding: 1rem 1.5rem;
    box-shadow: var(--shadow-md); gap: 0.75rem; z-index: 999;
  }
  .hamburger { display: block; }
  .section-title { font-size: 1.6rem; }
  .hero { padding: 2rem 1rem 3rem; }
  .admin-main { padding: 1.25rem 1rem; }
  .admin-brand .subtitle { display: none; }
}
@media (max-width: 480px) {
  .hero-name { font-size: 2rem; }
  .section { padding: 2.5rem 1rem; }
  .stat-box { padding: 0.75rem 1rem; }
  .stat-box strong { font-size: 1.2rem; }
  .notice-content { flex-direction: column; align-items: flex-start; gap: 0.4rem; }
}