/* ============================================================
   GLOBAL DESIGN SYSTEM - GMIT CHURCH PORTAL
   Sistem desain terpusat untuk seluruh halaman frontend & backend
   Skema Warna: Royal Navy + Celestial Gold + Modern Slate Neutrals
   Referensi: Halaman /dashboard (template-backend.php + redesign-backend.css)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,500;0,600;0,700;0,800;1,400;1,600&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600;700&display=swap');

/* ============================================================
   1. DESIGN TOKENS - CSS CUSTOM PROPERTIES (GLOBAL)
   ============================================================ */
:root {
  /* === BRAND CORE - Royal Church Navy & Celestial Gold === */
  --primary: #0f1d38;
  --primary-light: #1c325e;
  --primary-lighter: #28447d;
  --primary-dark: #091224;
  --primary-rgb: 15, 29, 56;

  --gold: #c5a059;
  --gold-light: #dfbe78;
  --gold-lighter: #f5e6c4;
  --gold-dark: #9e7d38;
  --gold-rgb: 197, 160, 89;

  --accent: #722f37;
  --accent-light: #8e3b45;
  --accent-dark: #501e24;

  /* === VIBRANT ACCENT & STATUS COLORS (dari dashboard) === */
  --accent-indigo: #4f46e5;
  --accent-indigo-light: #e0e7ff;
  --accent-indigo-dark: #3730a3;

  --accent-emerald: #10b981;
  --accent-emerald-light: #d1fae5;
  --accent-emerald-dark: #047857;

  --accent-amber: #f59e0b;
  --accent-amber-light: #fef3c7;
  --accent-amber-dark: #b45309;

  --accent-rose: #ef4444;
  --accent-rose-light: #fee2e2;
  --accent-rose-dark: #b91c1c;

  --accent-cyan: #06b6d4;
  --accent-cyan-light: #cffafe;
  --accent-cyan-dark: #0e7490;

  /* === BACKGROUND SYSTEM === */
  --bg-page: #f8fafc;
  --bg-light: #f1f5f9;
  --bg-warm: #faf8f5;
  --bg-cream: #fcfbf8;
  --bg-white: #ffffff;
  --bg-card: #ffffff;
  --church-bg: #f8fafc;

  /* === TEXT & TYPOGRAPHY === */
  --text: #334155;
  --text-dark: #0f172a;
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --text-light: #94a3b8;

  /* === BORDER SYSTEM === */
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --border-color: #e2e8f0;
  --border-gold: rgba(197, 160, 89, 0.35);
  --border-focus: #4f46e5;

  /* === LAYOUT MEASUREMENTS === */
  --sidebar-width: 260px;
  --header-height: 72px;
  --topbar-height: 38px;
  --content-max-width: 1240px;

  /* === SHAPE & RADIUS SYSTEM === */
  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 9999px;
  --radius-pill: 9999px;

  /* === ELEVATION & SHADOW SYSTEM === */
  --shadow-xs: 0 1px 2px 0 rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 1px 3px 0 rgba(15, 23, 42, 0.06), 0 1px 2px -1px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.07), 0 2px 4px -2px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.04);
  --shadow-xl: 0 20px 25px -5px rgba(15, 23, 42, 0.1), 0 8px 10px -6px rgba(15, 23, 42, 0.04);
  --shadow-gold: 0 8px 24px -4px rgba(197, 160, 89, 0.3);
  --shadow-card: 0 2px 8px -1px rgba(15, 29, 56, 0.08), 0 1px 3px -1px rgba(15, 29, 56, 0.04);

  /* === FONT FAMILIES === */
  --font-heading: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* === MICRO-INTERACTIONS === */
  --transition-fast: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition: all 0.28s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: all 0.45s cubic-bezier(0.16, 1, 0.3, 1);

  /* === LEGACY ALIASES (untuk kompatibilitas template lama) === */
  --church-navy: #0f1d38;
  --church-navy-dark: #091020;
  --church-navy-light: #1c325e;
  --church-navy-rgb: 15, 29, 56;
  --church-gold: #c5a059;
  --church-gold-light: #dfc284;
  --church-gold-dark: #9a7b3c;
  --church-card-bg: #ffffff;
}

/* ============================================================
   2. GLOBAL RESETS & BASE TYPOGRAPHY
   ============================================================ */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  color: var(--text);
  background-color: var(--bg-page);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  margin: 0;
  padding: 0;
}

h1, h2, h3, h4, h5, h6,
.font-heading,
.section-title h2 {
  font-family: var(--font-heading) !important;
  color: var(--primary);
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-top: 0;
  margin-bottom: 0.5rem;
  line-height: 1.25;
}

h1 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
h2 { font-size: clamp(1.5rem, 2.8vw, 2rem); }
h3 { font-size: clamp(1.25rem, 2.2vw, 1.6rem); }
h4 { font-size: clamp(1.1rem, 1.8vw, 1.35rem); }
h5 { font-size: 1.15rem; }
h6 { font-size: 1rem; }

p {
  margin-bottom: 1rem;
  color: var(--text);
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition-fast);
}

a:hover {
  color: var(--gold-dark);
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

::selection {
  background: var(--gold);
  color: var(--primary-dark);
}

/* ============================================================
   3. CUSTOM SCROLLBAR (KONSISTEN DENGAN DASHBOARD)
   ============================================================ */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}
::-webkit-scrollbar-track {
  background: var(--church-bg);
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: var(--radius-pill);
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* ============================================================
   4. ACCESSIBILITY FOCUS STATES
   ============================================================ */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--gold) !important;
  outline-offset: 3px !important;
}

/* ============================================================
   5. BUTTON SYSTEM (GLOBAL)
   ============================================================ */
.btn {
  font-family: var(--font-body);
  font-weight: 600;
  border-radius: var(--radius-sm);
  padding: 0.5rem 1rem;
  transition: var(--transition);
  border: 1px solid transparent;
  font-size: 0.9rem;
  line-height: 1.5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.btn:active {
  transform: translateY(0);
}

/* Primary Button - Navy */
.btn-primary,
.btn-navy {
  background-color: var(--primary) !important;
  border-color: var(--primary) !important;
  color: #ffffff !important;
}
.btn-primary:hover,
.btn-navy:hover {
  background-color: var(--primary-dark) !important;
  border-color: var(--primary-dark) !important;
  color: #ffffff !important;
}

/* Gold Button */
.btn-gold {
  background-color: var(--gold) !important;
  border-color: var(--gold) !important;
  color: var(--primary-dark) !important;
  font-weight: 700;
}
.btn-gold:hover {
  background-color: var(--gold-dark) !important;
  border-color: var(--gold-dark) !important;
  color: #ffffff !important;
  box-shadow: var(--shadow-gold);
}

.btn-outline-gold {
  background-color: transparent !important;
  border-color: var(--gold) !important;
  color: var(--gold) !important;
  font-weight: 600;
}
.btn-outline-gold:hover {
  background-color: var(--gold) !important;
  color: var(--primary-dark) !important;
}

/* WhatsApp Button */
.btn-whatsapp {
  background-color: #25d366 !important;
  border-color: #25d366 !important;
  color: #ffffff !important;
  font-weight: 600;
}
.btn-whatsapp:hover {
  background-color: #1da851 !important;
  border-color: #1da851 !important;
  color: #ffffff !important;
}

/* Button Sizes */
.btn-sm {
  padding: 0.25rem 0.6rem;
  font-size: 0.8rem;
  border-radius: var(--radius-xs);
}
.btn-lg {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  border-radius: var(--radius-md);
}

/* ============================================================
   6. CARD SYSTEM (GLOBAL)
   ============================================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  transition: var(--transition);
  overflow: hidden;
}

.card:hover {
  box-shadow: var(--shadow-md);
}

.card-body {
  padding: 1.25rem;
}

.card-header {
  background: var(--bg-light);
  border-bottom: 1px solid var(--border);
  padding: 0.9rem 1.25rem;
  font-weight: 700;
  color: var(--primary);
  font-family: var(--font-body);
}

.card-footer {
  background: var(--bg-light);
  border-top: 1px solid var(--border);
  padding: 0.75rem 1.25rem;
}

/* Card Hover Lift Effect */
.card-hover-lift {
  transition: var(--transition);
}
.card-hover-lift:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

/* ============================================================
   7. BADGE SYSTEM (GLOBAL)
   ============================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0.3em 0.7em;
  font-weight: 600;
  font-size: 0.75rem;
  border-radius: var(--radius-full);
  line-height: 1;
  font-family: var(--font-body);
  border: 1px solid transparent;
}

.badge-navy {
  background-color: var(--primary);
  color: #ffffff;
}

.badge-gold {
  background-color: rgba(197, 160, 89, 0.15);
  color: var(--gold-dark);
  border-color: var(--border-gold);
}

.badge-primary {
  background-color: var(--accent-indigo-light);
  color: var(--accent-indigo-dark);
}

.badge-success {
  background-color: var(--accent-emerald-light);
  color: var(--accent-emerald-dark);
}

.badge-warning {
  background-color: var(--accent-amber-light);
  color: var(--accent-amber-dark);
}

.badge-danger {
  background-color: var(--accent-rose-light);
  color: var(--accent-rose-dark);
}

.badge-info {
  background-color: var(--accent-cyan-light);
  color: var(--accent-cyan-dark);
}

.badge-light {
  background-color: var(--bg-light);
  color: var(--text-secondary);
  border-color: var(--border);
}

/* ============================================================
   8. BREADCRUMB SYSTEM (KONSISTEN)
   ============================================================ */
.breadcrumb {
  background-color: var(--bg-light);
  border: 1px solid var(--border-light);
  padding: 0.6rem 1rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  font-size: 0.85rem;
}

.breadcrumb-item + .breadcrumb-item::before {
  content: '›';
  color: var(--text-light);
  font-weight: 700;
}

.breadcrumb-item a {
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
}

.breadcrumb-item a:hover {
  color: var(--gold-dark);
}

.breadcrumb-item.active {
  color: var(--text-muted);
  font-weight: 500;
}

/* ============================================================
   9. FORM ELEMENTS (GLOBAL - SESUAI DASHBOARD)
   ============================================================ */
.form-control,
.form-select {
  font-family: var(--font-body);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  padding: 0.55rem 0.85rem;
  font-size: 0.9rem;
  transition: var(--transition-fast);
  background-color: var(--bg-white);
  color: var(--text-dark);
}

.form-control:focus,
.form-select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 0.2rem rgba(197, 160, 89, 0.15);
  outline: none;
}

.form-label {
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 0.4rem;
  font-size: 0.875rem;
  font-family: var(--font-body);
}

.input-group-text {
  background-color: var(--bg-light);
  border-color: var(--border);
  color: var(--text-secondary);
  font-weight: 600;
  border-radius: var(--radius-sm);
}

/* ============================================================
   10. TABLE SYSTEM (GLOBAL)
   ============================================================ */
.table {
  font-family: var(--font-body);
  font-size: 0.875rem;
  color: var(--text);
}

.table thead th {
  background-color: var(--primary);
  color: #ffffff;
  font-weight: 700;
  border-bottom: 2px solid var(--gold);
  padding: 0.7rem 0.9rem;
  letter-spacing: 0.2px;
  font-size: 0.8rem;
  text-transform: uppercase;
}

.table tbody td {
  padding: 0.65rem 0.9rem;
  vertical-align: middle;
  border-color: var(--border-light);
}

.table tbody tr:hover {
  background-color: var(--bg-light);
}

.table-striped tbody tr:nth-of-type(odd) {
  background-color: rgba(15, 29, 56, 0.02);
}

/* ============================================================
   11. MODAL SYSTEM (GLOBAL - KONSISTEN)
   ============================================================ */
.modal-content {
  border-radius: var(--radius-md);
  border: none;
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  font-family: var(--font-body);
}

.modal-header {
  background: var(--primary);
  color: #ffffff;
  border: none;
  padding: 1rem 1.25rem;
}

.modal-header .modal-title {
  font-family: var(--font-heading);
  color: #ffffff !important;
  font-weight: 700;
  font-size: 1.1rem;
  margin: 0;
}

.modal-header .btn-close {
  filter: brightness(0) invert(1);
  opacity: 0.9;
}

.modal-body {
  padding: 1.25rem;
  color: var(--text);
}

.modal-footer {
  background: var(--bg-light);
  border-top: 1px solid var(--border);
  padding: 0.75rem 1.25rem;
}

/* ============================================================
   12. PAGE HEADER / SECTION TITLE (STANDARD)
   ============================================================ */
.section-title {
  text-align: center;
  margin-bottom: 2rem;
}

.section-title .badge-gold {
  letter-spacing: 1.2px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 0.4em 1em;
}

.section-title h2 {
  margin: 0.75rem 0 0.5rem;
  font-weight: 800;
}

.section-title p {
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
  font-size: 0.95rem;
}

.divider-gold {
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--gold) 0%, var(--primary) 100%);
  border-radius: var(--radius-full);
  margin: 14px auto 0;
}

/* Page Title Bar untuk halaman konten */
.page-title-bar {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 60%, var(--primary-light) 100%);
  padding: 2.5rem 0;
  position: relative;
  overflow: hidden;
  border-bottom: 3px solid var(--gold);
}

.page-title-bar::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.6;
}

.page-title-bar .container {
  position: relative;
  z-index: 1;
}

.page-title-bar h1 {
  color: #ffffff !important;
  margin: 0 0 0.3rem;
  font-weight: 700;
}

.page-title-bar p {
  color: rgba(255, 255, 255, 0.8);
  margin: 0;
  font-size: 0.95rem;
}

/* ============================================================
   13. PAGINATION SYSTEM
   ============================================================ */
.pagination .page-link {
  font-family: var(--font-body);
  color: var(--primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin: 0 2px;
  padding: 0.45rem 0.8rem;
  font-weight: 600;
  font-size: 0.875rem;
  transition: var(--transition-fast);
}

.pagination .page-link:hover {
  background-color: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  z-index: auto;
}

.pagination .page-item.active .page-link {
  background-color: var(--gold);
  border-color: var(--gold);
  color: var(--primary-dark);
  font-weight: 700;
}

.pagination .page-item.disabled .page-link {
  color: var(--text-light);
  opacity: 0.7;
}

/* ============================================================
   14. BACK TO TOP BUTTON (STANDARD)
   ============================================================ */
.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 990;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--primary);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: var(--transition);
  border: 2px solid var(--gold);
  text-decoration: none;
}

.back-to-top:hover {
  background: var(--gold);
  color: var(--primary-dark);
  transform: translateY(-4px);
  text-decoration: none;
}

.back-to-top.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* ============================================================
   15. PRELOADER (STANDARD - SEMUA TEMPLATE)
   ============================================================ */
.preloader {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at center, #16284e 0%, #091224 100%);
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.5s ease;
}

.preloader.out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  text-align: center;
}

.preloader-spinner-container {
  position: relative;
  width: 84px;
  height: 84px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.preloader .loader,
.loader {
  position: absolute;
  inset: 0;
  width: 84px;
  height: 84px;
  border: 3px solid rgba(197, 160, 89, 0.18);
  border-top: 3px solid var(--gold, #c5a059);
  border-right: 3px solid rgba(197, 160, 89, 0.5);
  border-radius: 50%;
  animation: spin 0.9s cubic-bezier(0.5, 0, 0.5, 1) infinite;
  box-shadow: 0 0 24px rgba(197, 160, 89, 0.22);
}

.preloader-center-logo {
  width: 44px;
  height: 44px;
  object-fit: contain;
  z-index: 2;
  border-radius: 50%;
  padding: 4px;
  background: rgba(15, 29, 56, 0.6);
  backdrop-filter: blur(4px);
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.35));
  animation: logoPulse 2s ease-in-out infinite;
}

.preloader-brand-title {
  color: rgba(255, 255, 255, 0.9);
  font-family: var(--font-heading, 'Playfair Display', Georgia, serif);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  opacity: 0.85;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes logoPulse {
  0%, 100% {
    transform: scale(1);
    opacity: 0.95;
  }
  50% {
    transform: scale(1.06);
    opacity: 1;
    filter: drop-shadow(0 0 12px rgba(197, 160, 89, 0.5));
  }
}

/* ============================================================
   16. ALERT / NOTIFICATION SYSTEM
   ============================================================ */
.alert {
  border-radius: var(--radius-sm);
  border: none;
  border-left: 4px solid;
  font-family: var(--font-body);
  font-size: 0.9rem;
  padding: 0.9rem 1.1rem;
}

.alert-primary {
  background-color: var(--accent-indigo-light);
  color: var(--accent-indigo-dark);
  border-left-color: var(--accent-indigo);
}

.alert-success {
  background-color: var(--accent-emerald-light);
  color: var(--accent-emerald-dark);
  border-left-color: var(--accent-emerald);
}

.alert-warning {
  background-color: var(--accent-amber-light);
  color: var(--accent-amber-dark);
  border-left-color: var(--accent-amber);
}

.alert-danger {
  background-color: var(--accent-rose-light);
  color: var(--accent-rose-dark);
  border-left-color: var(--accent-rose);
}

.alert-info {
  background-color: var(--accent-cyan-light);
  color: var(--accent-cyan-dark);
  border-left-color: var(--accent-cyan);
}

/* ============================================================
   17. RESPONSIVE UTILITIES (GLOBAL BREAKPOINTS)
   ============================================================ */
@media (max-width: 991.98px) {
  :root {
    --header-height: 64px;
  }
  .page-title-bar {
    padding: 1.8rem 0;
  }
}

@media (max-width: 767.98px) {
  h1 { font-size: 1.65rem; }
  h2 { font-size: 1.35rem; }
  h3 { font-size: 1.15rem; }
  .card-body { padding: 1rem; }
  .section-title { margin-bottom: 1.5rem; }
}

@media (max-width: 575.98px) {
  .btn {
    padding: 0.45rem 0.85rem;
    font-size: 0.85rem;
  }
  .pagination .page-link {
    padding: 0.35rem 0.65rem;
    font-size: 0.8rem;
  }
  .back-to-top {
    right: 16px;
    bottom: 16px;
    width: 40px;
    height: 40px;
  }
}

/* ============================================================
   18. UTILITY CLASSES UMUM
   ============================================================ */
.text-gold { color: var(--gold) !important; }
.text-navy { color: var(--primary) !important; }
.bg-gold { background-color: var(--gold) !important; }
.bg-navy { background-color: var(--primary) !important; }
.bg-navy-dark { background-color: var(--primary-dark) !important; }
.bg-page { background-color: var(--bg-page) !important; }
.bg-card { background-color: var(--bg-card) !important; }

.font-weight-bold, .fw-bold { font-weight: 700 !important; }
.font-weight-semibold, .fw-semibold { font-weight: 600 !important; }
.font-weight-medium, .fw-medium { font-weight: 500 !important; }

.shadow-card { box-shadow: var(--shadow-card); }
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow-md { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: var(--shadow-xl); }

.rounded-xs { border-radius: var(--radius-xs); }
.rounded-sm { border-radius: var(--radius-sm); }
.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-pill { border-radius: var(--radius-full); }

.duration-fast { transition: var(--transition-fast); }
.duration-base { transition: var(--transition); }
.duration-slow { transition: var(--transition-smooth); }

.pointer { cursor: pointer !important; }

/* ============================================================
   19. TOPBAR, HEADER & NAVBAR SYSTEM (FRONTEND GLOBAL)
   ============================================================ */
/* ─── TOPBAR ─── */
#topbar {
  background: linear-gradient(90deg, #091224 0%, #0f1d38 50%, #16284e 100%) !important;
  border-bottom: 1px solid rgba(197, 160, 89, 0.25);
  padding: 7px 0 !important;
  font-size: 0.825rem;
  color: rgba(255, 255, 255, 0.85);
  position: relative;
  z-index: 1010;
}

#topbar .container {
  max-width: 1240px;
}

.topbar-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-full);
  padding: 3px 12px;
  color: #fff;
  font-weight: 500;
  font-size: 0.8rem;
}

.topbar-badge i {
  color: var(--gold-light);
}

.topbar-clock {
  font-family: 'JetBrains Mono', Consolas, Monaco, monospace;
  letter-spacing: 0.5px;
  color: var(--gold-light);
  font-weight: 600;
}

.topbar-social {
  display: flex;
  align-items: center;
  gap: 8px;
}

.topbar-social a {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.85) !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  transition: var(--transition);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.topbar-social a:hover {
  background: var(--gold);
  color: var(--primary-dark) !important;
  transform: translateY(-2px);
  border-color: var(--gold);
}

/* ─── MAIN HEADER & NAVBAR ─── */
#header {
  background: var(--primary) !important;
  min-height: 72px;
  padding: 8px 0;
  box-shadow: 0 4px 20px rgba(9, 18, 36, 0.15);
  border-bottom: 2px solid rgba(197, 160, 89, 0.3);
  transition: var(--transition-smooth);
  position: relative;
  z-index: 1000;
}

#header.fixed-top {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  min-height: 64px;
  background: rgba(15, 29, 56, 0.96) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: var(--shadow-lg);
  border-bottom-color: var(--gold);
  animation: slideDown 0.35s ease forwards;
}

@keyframes slideDown {
  from { transform: translateY(-100%); }
  to { transform: translateY(0); }
}

#header .container {
  max-width: 1240px;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none !important;
}

.header-brand-logo {
  max-height: 50px;
  width: auto;
  object-fit: contain;
  transition: var(--transition);
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.25));
}

.header-brand-text {
  display: flex;
  flex-direction: column;
}

.header-brand-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.5px;
  margin: 0;
  line-height: 1.2;
}

.header-brand-sub {
  font-family: var(--font-body);
  font-size: 0.725rem;
  color: var(--gold-light);
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* ─── DESKTOP NAVBAR LINKS ─── */
.navbar {
  padding: 0;
}

.navbar ul {
  margin: 0;
  padding: 0;
  display: flex;
  list-style: none;
  align-items: center;
  gap: 4px;
}

.navbar li {
  position: relative;
}

.navbar > ul > li > a {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 10px 14px;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9) !important;
  white-space: nowrap;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  position: relative;
}

.navbar > ul > li > a i {
  font-size: 0.75rem;
  transition: transform 0.25s ease;
}

.navbar > ul > li > a:hover,
.navbar > ul > li.active > a {
  color: #ffffff !important;
  background: rgba(197, 160, 89, 0.18);
}

.navbar > ul > li > a::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 14px;
  right: 14px;
  height: 2px;
  background: var(--gold);
  border-radius: 2px;
  transform: scaleX(0);
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar > ul > li:hover > a::after,
.navbar > ul > li.active > a::after {
  transform: scaleX(1);
}

/* ─── DROPDOWN MENUS ─── */
.navbar .dropdown ul {
  display: block;
  position: absolute;
  left: 0;
  top: calc(100% + 15px);
  margin: 0;
  padding: 8px 0;
  z-index: 1050;
  opacity: 0;
  visibility: hidden;
  background: #ffffff;
  box-shadow: var(--shadow-xl);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  border-top: 3px solid var(--gold);
  min-width: 220px;
  transition: var(--transition);
  transform: translateY(10px);
}

.navbar .dropdown:hover > ul {
  opacity: 1;
  visibility: visible;
  top: 100%;
  transform: translateY(0);
}

.navbar .dropdown ul li {
  min-width: 200px;
}

.navbar .dropdown ul a {
  padding: 9px 18px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-dark) !important;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: var(--transition);
}

.navbar .dropdown ul a:hover,
.navbar .dropdown ul li:hover > a {
  color: var(--primary) !important;
  background: var(--bg-warm);
  padding-left: 22px;
}

.navbar .dropdown ul a i {
  font-size: 0.75rem;
  color: var(--gold);
}

.navbar .dropdown .dropdown ul {
  top: 0;
  left: calc(100% + 10px);
  visibility: hidden;
  transform: translateX(10px);
}

.navbar .dropdown .dropdown:hover > ul {
  opacity: 1;
  visibility: visible;
  left: 100%;
  transform: translateX(0);
}

/* ─── HEADER ACTIONS & SEARCH BUTTON ─── */
.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-header-search {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--gold-light) !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
}

.btn-header-search:hover {
  background: var(--gold);
  color: var(--primary-dark) !important;
  border-color: var(--gold);
  transform: scale(1.05);
}

.mobile-nav-toggle {
  color: var(--gold-light) !important;
  font-size: 28px;
  cursor: pointer;
  line-height: 0;
  display: none;
  padding: 6px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  transition: var(--transition);
}

.mobile-nav-toggle:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff !important;
}

/* ─── MOBILE DRAWER NAVIGATION ─── */
@media (max-width: 991.98px) {
  .mobile-nav-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .navbar ul {
    display: none;
  }

  .navbar-mobile {
    position: fixed;
    inset: 0;
    background: rgba(9, 18, 36, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 9999;
    transition: var(--transition);
    overflow: hidden;
  }

  .navbar-mobile .mobile-nav-toggle {
    position: absolute;
    top: 18px;
    right: 20px;
    color: #fff !important;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    z-index: 10001;
    font-size: 24px;
    width: 40px;
    height: 40px;
  }

  .navbar-mobile ul {
    display: block;
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(85vw, 360px);
    background: #ffffff;
    box-shadow: var(--shadow-xl);
    padding: 70px 16px 30px;
    overflow-y: auto;
    border-left: 3px solid var(--gold);
    animation: drawerSlide 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  }

  @keyframes drawerSlide {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
  }

  .navbar-mobile li {
    display: block;
    margin-bottom: 4px;
  }

  .navbar-mobile a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--primary) !important;
    border-radius: var(--radius-sm);
    background: transparent;
  }

  .navbar-mobile a:hover,
  .navbar-mobile li.active > a {
    background: var(--bg-warm);
    color: var(--gold-dark) !important;
  }

  .navbar-mobile .dropdown ul {
    position: static;
    display: none;
    opacity: 1;
    visibility: visible;
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    box-shadow: none;
    border: none;
    border-left: 3px solid var(--gold);
    margin: 4px 0 8px 12px;
    padding: 6px 0;
    transform: none;
  }

  .navbar-mobile .dropdown ul a {
    padding: 8px 14px;
    font-size: 0.875rem;
    font-weight: 500;
  }

  .navbar-mobile .dropdown > .dropdown-active {
    display: block !important;
  }
}

/* ============================================================
   20. MODERN RICH FOOTER (FRONTEND GLOBAL)
   ============================================================ */
.footer-church {
  background: linear-gradient(180deg, #0f1d38 0%, #091224 100%);
  color: rgba(255, 255, 255, 0.8);
  padding: 60px 0 0;
  border-top: 3px solid var(--gold);
}

.footer-church h5 {
  font-family: var(--font-heading);
  color: #ffffff !important;
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.footer-church h5::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 36px;
  height: 2px;
  background: var(--gold);
  border-radius: 2px;
}

.footer-church p,
.footer-church span {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.875rem;
  line-height: 1.7;
}

.footer-links-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links-list li {
  margin-bottom: 10px;
}

.footer-links-list a {
  color: rgba(255, 255, 255, 0.75) !important;
  font-size: 0.875rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
}

.footer-links-list a:hover {
  color: var(--gold-light) !important;
  padding-left: 6px;
}

.footer-bottom-bar {
  background: #050b16;
  padding: 20px 0;
  margin-top: 48px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.825rem;
  color: rgba(255, 255, 255, 0.65);
}

/* Print styles */
@media print {
  .back-to-top,
  .preloader,
  .no-print {
    display: none !important;
  }
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }
}
