@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@300;400;500;700;800;900&family=Amiri:wght@400;700&display=swap');

:root {
  --bg-main: #0a0e1a;
  --bg-card: #111827;
  --bg-card-hover: #1a2234;
  --bg-sidebar: #0d1220;
  --bg-input: #0f1626;
  --border-color: #1f2937;
  --border-accent: #2d3748;
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --accent-gold: #d4a84b;
  --accent-gold-light: #e8c572;
  --accent-gold-dark: #a67f2f;
  --accent-emerald: #10b981;
  --accent-rose: #f43f5e;
  --accent-amber: #f59e0b;
  --accent-blue: #3b82f6;
  --accent-purple: #8b5cf6;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.35);
  --shadow-glow: 0 0 32px rgba(212, 168, 75, 0.15);
}

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

svg { width: 16px; height: 16px; flex-shrink: 0; vertical-align: middle; }
button svg, a svg { pointer-events: none; }

body {
  font-family: 'Tajawal', sans-serif;
  background: var(--bg-main);
  color: var(--text-primary);
  direction: rtl;
  min-height: 100vh;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse at 15% 10%, rgba(212, 168, 75, 0.08) 0%, transparent 45%),
    radial-gradient(ellipse at 85% 90%, rgba(59, 130, 246, 0.06) 0%, transparent 45%),
    radial-gradient(ellipse at 50% 50%, rgba(139, 92, 246, 0.03) 0%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}

.app-container {
  display: grid;
  grid-template-columns: 280px 1fr;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* ============ SIDEBAR ============ */
.sidebar {
  background: var(--bg-sidebar);
  border-left: 1px solid var(--border-color);
  padding: 28px 20px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.brand { padding: 0 8px 28px 8px; border-bottom: 1px solid var(--border-color); margin-bottom: 24px; }
.brand-logo { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.brand-icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: linear-gradient(135deg, var(--accent-gold) 0%, var(--accent-gold-dark) 100%);
  display: flex; align-items: center; justify-content: center;
  font-family: 'Amiri', serif; font-weight: 700; font-size: 22px; color: #0a0e1a;
  box-shadow: var(--shadow-glow);
}
.brand-text h1 { font-size: 17px; font-weight: 800; letter-spacing: 0.5px; line-height: 1.2; }
.brand-text p { font-size: 11px; color: var(--accent-gold); font-weight: 500; letter-spacing: 1.5px; margin-top: 2px; }

.user-card {
  display: flex; align-items: center; gap: 10px;
  padding: 12px; background: var(--bg-card);
  border: 1px solid var(--border-color); border-radius: 12px;
  margin-bottom: 16px;
}
.user-avatar {
  width: 38px; height: 38px; border-radius: 10px;
  background: linear-gradient(135deg, var(--accent-blue), #6366f1);
  color: white; display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 16px; flex-shrink: 0;
}
.user-avatar.admin {
  background: linear-gradient(135deg, var(--accent-gold), var(--accent-gold-dark));
  color: #0a0e1a;
}
.user-info { flex: 1; min-width: 0; }
.user-name {
  font-size: 13px; font-weight: 700; color: var(--text-primary);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.user-role { font-size: 10px; color: var(--text-muted); margin-top: 1px; }
.logout-btn {
  width: 32px; height: 32px; border-radius: 8px;
  border: 1px solid var(--border-color); background: transparent;
  color: var(--text-muted); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s ease; flex-shrink: 0; text-decoration: none;
}
.logout-btn:hover { background: var(--accent-rose); color: white; border-color: var(--accent-rose); }
.logout-btn svg { width: 15px; height: 15px; }

.nav-menu { flex: 1; display: flex; flex-direction: column; gap: 6px; }
.nav-label {
  font-size: 10px; color: var(--text-muted); font-weight: 700;
  letter-spacing: 1.5px; padding: 8px 12px; margin-top: 8px;
}
.nav-item {
  display: flex; align-items: center; gap: 14px;
  padding: 13px 14px; border-radius: 10px; color: var(--text-secondary);
  cursor: pointer; font-size: 14px; font-weight: 500;
  transition: all 0.2s ease; border: 1px solid transparent;
  position: relative; text-decoration: none;
}
.nav-item:hover { background: var(--bg-card); color: var(--text-primary); }
.nav-item.active {
  background: linear-gradient(135deg, rgba(212, 168, 75, 0.15) 0%, rgba(212, 168, 75, 0.05) 100%);
  color: var(--accent-gold-light); border-color: rgba(212, 168, 75, 0.25);
}
.nav-item.active::before {
  content: ''; position: absolute; right: -20px; top: 50%;
  transform: translateY(-50%); width: 3px; height: 60%;
  background: var(--accent-gold); border-radius: 4px 0 0 4px;
}
.nav-item svg { width: 20px; height: 20px; flex-shrink: 0; }

.sidebar-footer {
  padding: 16px 12px; border-top: 1px solid var(--border-color);
  margin-top: 12px; font-size: 11px; color: var(--text-muted); text-align: center;
}

/* ============ BACKUP BUTTONS ============ */
.sidebar-backup {
  padding: 14px 8px 16px;
  border-top: 1px solid var(--border-color);
  margin-top: 12px;
}
.backup-title {
  font-size: 10px; color: var(--text-muted); font-weight: 700;
  letter-spacing: 1.5px; padding: 0 6px 10px;
}
.backup-buttons {
  display: grid; grid-template-columns: 1fr 1fr; gap: 6px;
}
.backup-btn {
  padding: 9px 8px; border-radius: 8px;
  border: 1px solid var(--border-color); background: var(--bg-input);
  color: var(--text-secondary); font-family: inherit;
  font-size: 12px; font-weight: 600; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  gap: 6px; transition: all 0.2s ease;
}
.backup-btn svg { width: 14px; height: 14px; }
.backup-btn:hover {
  background: var(--accent-gold); color: #0a0e1a;
  border-color: var(--accent-gold); transform: translateY(-1px);
}

/* ============ IMPORT OPTIONS ============ */
.import-option {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 16px; background: var(--bg-input);
  border: 1px solid var(--border-color); border-radius: 12px;
  margin-bottom: 10px; transition: all 0.2s ease;
}
.import-option:hover {
  border-color: var(--accent-gold);
}
.import-option-icon {
  width: 42px; height: 42px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.import-option-icon svg { width: 20px; height: 20px; }
.import-option-content { flex: 1; min-width: 0; }
.import-option-title { font-size: 14px; font-weight: 700; color: var(--text-primary); margin-bottom: 3px; }
.import-option-desc { font-size: 12px; color: var(--text-muted); }

/* ============ BUDGET CARDS ============ */
.budget-card {
  background: var(--bg-card); border: 1px solid var(--border-color);
  border-radius: 14px; padding: 20px; margin-bottom: 16px;
  transition: all 0.2s ease;
}
.budget-card:hover { border-color: var(--border-accent); }
.budget-card-header {
  display: flex; justify-content: space-between; align-items: center;
  padding-bottom: 14px; margin-bottom: 14px;
  border-bottom: 1px solid var(--border-color);
}
.budget-card-title {
  display: flex; align-items: center; gap: 10px;
  font-size: 16px; font-weight: 700;
}
.budget-badge {
  padding: 3px 10px; border-radius: 20px;
  font-size: 10px; font-weight: 700;
  background: rgba(212, 168, 75, 0.15); color: var(--accent-gold);
}
.budget-values {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px;
}
.budget-value {
  padding: 12px; background: var(--bg-input);
  border-radius: 10px; border: 1px solid var(--border-color);
}
.budget-value-label {
  font-size: 11px; color: var(--text-muted);
  margin-bottom: 4px; font-weight: 500;
}
.budget-value-amount {
  font-size: 18px; font-weight: 800;
  font-feature-settings: "tnum";
}
.budget-value.total { background: linear-gradient(135deg, rgba(212, 168, 75, 0.1), rgba(212, 168, 75, 0.02)); border-color: rgba(212, 168, 75, 0.3); }
.budget-value.total .budget-value-amount { color: var(--accent-gold-light); }

/* Budget summary box */
.budget-summary {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 14px; margin-bottom: 24px;
}
.budget-stat {
  padding: 20px; background: var(--bg-card);
  border: 1px solid var(--border-color); border-radius: 14px;
}
.budget-stat-icon {
  width: 40px; height: 40px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 12px;
}
.budget-stat-icon > svg,
.budget-stat .budget-stat-icon svg { width: 20px !important; height: 20px !important; }
.budget-stat-label {
  font-size: 12px; color: var(--text-muted); margin-bottom: 4px;
}
.budget-stat-value {
  font-size: 24px; font-weight: 800;
  font-feature-settings: "tnum";
}

/* Budget card title icon */
.budget-card-title > svg { width: 22px !important; height: 22px !important; }

/* ============ MAIN ============ */
.main-content { padding: 32px 40px; overflow-y: auto; min-width: 0; }
.page-header {
  display: flex; justify-content: space-between; align-items: flex-end;
  margin-bottom: 32px; padding-bottom: 20px; border-bottom: 1px solid var(--border-color);
}
.page-title { font-size: 26px; font-weight: 800; letter-spacing: -0.3px; }
.page-subtitle { font-size: 13px; color: var(--text-muted); margin-top: 4px; }

/* ============ STAT CARDS ============ */
.stats-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px; margin-bottom: 32px;
}
.stat-card {
  background: var(--bg-card); border: 1px solid var(--border-color);
  border-radius: 16px; padding: 24px; position: relative; overflow: hidden;
  transition: all 0.3s ease;
}
.stat-card:hover { transform: translateY(-2px); border-color: var(--border-accent); box-shadow: var(--shadow-md); }
.stat-card::before {
  content: ''; position: absolute; top: 0; right: 0;
  width: 100px; height: 100px; opacity: 0.08;
  background: var(--stat-color, var(--accent-gold));
  border-radius: 50%; transform: translate(30%, -30%); filter: blur(20px);
}
.stat-card-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 16px; }
.stat-label { font-size: 13px; color: var(--text-secondary); font-weight: 500; }
.stat-icon {
  width: 40px; height: 40px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(var(--stat-rgb), 0.15); color: var(--stat-color);
}
.stat-icon svg { width: 20px; height: 20px; }
.stat-value {
  font-size: 28px; font-weight: 800; letter-spacing: -0.5px;
  margin-bottom: 8px; font-feature-settings: "tnum";
}
.stat-meta { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; gap: 6px; }

/* ============ CARDS ============ */
.content-card {
  background: var(--bg-card); border: 1px solid var(--border-color);
  border-radius: 16px; overflow: hidden;
}
.card-header {
  padding: 20px 24px; border-bottom: 1px solid var(--border-color);
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px; flex-wrap: wrap;
}
.card-title { font-size: 17px; font-weight: 700; }

/* ============ BUTTONS ============ */
.btn {
  padding: 10px 18px; border-radius: 10px; font-family: inherit;
  font-size: 13px; font-weight: 600; border: none; cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  transition: all 0.2s ease; white-space: nowrap; text-decoration: none;
}
.btn-primary {
  background: linear-gradient(135deg, var(--accent-gold) 0%, var(--accent-gold-dark) 100%);
  color: #0a0e1a;
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(212, 168, 75, 0.3); }
.btn-secondary {
  background: var(--bg-input); color: var(--text-secondary);
  border: 1px solid var(--border-color);
}
.btn-secondary:hover { background: var(--bg-card-hover); color: var(--text-primary); }
.btn svg { width: 16px; height: 16px; }

/* ============ TABLE ============ */
.table-wrapper { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th {
  padding: 14px 20px; text-align: right; font-size: 12px; font-weight: 700;
  color: var(--text-muted); letter-spacing: 0.5px;
  background: var(--bg-input); border-bottom: 1px solid var(--border-color);
  text-transform: uppercase;
}
td {
  padding: 16px 20px; font-size: 14px; color: var(--text-primary);
  border-bottom: 1px solid var(--border-color);
}
tr:last-child td { border-bottom: none; }
tr:hover td { background: var(--bg-card-hover); }

.table-empty { padding: 60px 20px; text-align: center; color: var(--text-muted); font-size: 14px; }
.table-empty-icon { width: 48px; height: 48px; margin: 0 auto 12px; opacity: 0.3; }

/* ============ BADGES ============ */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 20px; font-size: 11px; font-weight: 600;
}
.badge-success { background: rgba(16, 185, 129, 0.15); color: var(--accent-emerald); }
.badge-warning { background: rgba(245, 158, 11, 0.15); color: var(--accent-amber); }
.badge-danger { background: rgba(244, 63, 94, 0.15); color: var(--accent-rose); }
.badge-info { background: rgba(59, 130, 246, 0.15); color: var(--accent-blue); }
.badge-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

/* ============ ACTIONS ============ */
.actions { display: flex; gap: 4px; }
.action-icon {
  width: 32px; height: 32px; border-radius: 8px;
  border: 1px solid var(--border-color); background: var(--bg-input);
  color: var(--text-secondary); display: flex; align-items: center;
  justify-content: center; cursor: pointer; transition: all 0.2s ease;
  text-decoration: none;
}
.action-icon:hover { background: var(--accent-gold); color: #0a0e1a; border-color: var(--accent-gold); transform: translateY(-1px); }
.action-icon svg { width: 15px; height: 15px; }
.action-icon.view:hover { background: var(--accent-blue); border-color: var(--accent-blue); color: white; }
.action-icon.employee:hover { background: var(--accent-purple); border-color: var(--accent-purple); color: white; }
.action-icon.branch:hover { background: var(--accent-emerald); border-color: var(--accent-emerald); color: white; }
.action-icon.danger:hover { background: var(--accent-rose); border-color: var(--accent-rose); color: white; }

/* ============ MODAL ============ */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px); display: flex; align-items: center;
  justify-content: center; z-index: 100; padding: 20px;
  animation: fadeIn 0.2s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: var(--bg-card); border: 1px solid var(--border-accent);
  border-radius: 16px; width: 100%; max-width: 560px; max-height: 90vh;
  overflow-y: auto; box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
  animation: slideUp 0.3s ease;
}
.modal-lg { max-width: 800px; }
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.modal-header {
  padding: 20px 24px; border-bottom: 1px solid var(--border-color);
  display: flex; justify-content: space-between; align-items: center;
}
.modal-title { font-size: 17px; font-weight: 700; }
.modal-close {
  width: 32px; height: 32px; border-radius: 8px; border: none;
  background: var(--bg-input); color: var(--text-secondary);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.modal-close:hover { background: var(--accent-rose); color: white; }
.modal-body { padding: 24px; }
.modal-footer {
  padding: 16px 24px; border-top: 1px solid var(--border-color);
  display: flex; justify-content: flex-start; gap: 10px;
}

/* ============ FORMS ============ */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group.full { grid-column: 1 / -1; }
.form-label { font-size: 12px; font-weight: 600; color: var(--text-secondary); }
.form-label .required { color: var(--accent-rose); }
.form-input, .form-select, .form-textarea {
  width: 100%; padding: 11px 14px; border-radius: 10px;
  border: 1px solid var(--border-color); background: var(--bg-input);
  color: var(--text-primary); font-family: inherit; font-size: 14px;
  transition: all 0.2s ease;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none; border-color: var(--accent-gold);
  box-shadow: 0 0 0 3px rgba(212, 168, 75, 0.1);
}
.form-textarea { resize: vertical; min-height: 80px; }
.form-input:disabled { opacity: 0.5; cursor: not-allowed; }

/* ============ SEARCH ============ */
.search-bar { position: relative; display: flex; align-items: center; flex: 1; max-width: 320px; }
.search-bar svg { position: absolute; right: 12px; width: 16px; height: 16px; color: var(--text-muted); pointer-events: none; }
.search-bar input {
  width: 100%; padding: 9px 36px 9px 14px; border-radius: 10px;
  border: 1px solid var(--border-color); background: var(--bg-input);
  color: var(--text-primary); font-family: inherit; font-size: 13px;
}
.search-bar input:focus { outline: none; border-color: var(--accent-gold); }

/* ============ TABS ============ */
.tabs {
  display: flex; gap: 4px; padding: 6px; background: var(--bg-input);
  border-radius: 12px; border: 1px solid var(--border-color);
  margin-bottom: 24px; width: fit-content;
}
.tab {
  padding: 10px 18px; border-radius: 8px; font-size: 13px; font-weight: 600;
  color: var(--text-secondary); cursor: pointer; transition: all 0.2s ease;
  border: none; background: transparent; font-family: inherit; text-decoration: none;
}
.tab.active { background: var(--bg-card); color: var(--accent-gold); box-shadow: var(--shadow-sm); }

/* ============ ZAKAT ============ */
.zakat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.zakat-section {
  background: var(--bg-input); border: 1px solid var(--border-color);
  border-radius: 14px; padding: 20px;
}
.zakat-section-title {
  font-size: 14px; font-weight: 700; color: var(--accent-gold);
  margin-bottom: 16px; padding-bottom: 10px; border-bottom: 1px solid var(--border-color);
}
.zakat-result {
  background: linear-gradient(135deg, rgba(212, 168, 75, 0.1) 0%, rgba(212, 168, 75, 0.02) 100%);
  border: 1px solid rgba(212, 168, 75, 0.3); border-radius: 14px;
  padding: 24px; margin-top: 20px;
}
.zakat-result-row {
  display: flex; justify-content: space-between; padding: 10px 0;
  font-size: 14px; border-bottom: 1px dashed rgba(212, 168, 75, 0.15);
}
.zakat-result-row:last-child {
  border-bottom: none; padding-top: 14px; margin-top: 6px;
  border-top: 2px solid var(--accent-gold);
  font-size: 18px; font-weight: 800; color: var(--accent-gold-light);
}

/* ============ VAT ============ */
.vat-row {
  display: flex; justify-content: space-between; padding: 8px 12px;
  background: rgba(0,0,0,0.2); border-radius: 8px; font-size: 13px; font-weight: 600;
}
.vat-row span:first-child { color: var(--text-secondary); }
.vat-row span:last-child { color: var(--text-primary); font-feature-settings: "tnum"; }

/* ============ DETAIL ============ */
.detail-row {
  display: flex; justify-content: space-between;
  padding: 14px 0; border-bottom: 1px dashed var(--border-color);
}
.detail-row:last-child { border-bottom: none; }
.detail-label { color: var(--text-muted); font-size: 13px; }
.detail-value { color: var(--text-primary); font-weight: 600; font-size: 14px; }

/* ============ TOAST ============ */
.toast {
  position: fixed; top: 24px; left: 50%; transform: translateX(-50%);
  background: var(--bg-card); border: 1px solid var(--border-accent);
  border-radius: 12px; padding: 14px 20px; box-shadow: var(--shadow-md);
  display: flex; align-items: center; gap: 10px;
  font-size: 14px; font-weight: 500; z-index: 200;
  animation: slideDown 0.3s ease;
}
@keyframes slideDown { from { transform: translate(-50%, -20px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
.toast.success { border-color: var(--accent-emerald); color: var(--accent-emerald); }
.toast.error { border-color: var(--accent-rose); color: var(--accent-rose); }

/* ============ LOGIN ============ */
.login-container {
  min-height: 100vh; display: flex; align-items: center;
  justify-content: center; padding: 20px; position: relative; z-index: 1;
}
.login-box {
  width: 100%; max-width: 420px; background: var(--bg-card);
  border: 1px solid var(--border-color); border-radius: 20px;
  padding: 40px 32px; box-shadow: 0 25px 80px rgba(0,0,0,0.4);
  position: relative; overflow: hidden;
}
.login-box::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--accent-gold) 0%, var(--accent-gold-light) 50%, var(--accent-gold) 100%);
}
.login-logo {
  display: flex; flex-direction: column; align-items: center;
  gap: 14px; margin-bottom: 32px;
}
.login-logo .brand-icon {
  width: 72px; height: 72px; border-radius: 18px; font-size: 36px;
  box-shadow: 0 12px 32px rgba(212,168,75,0.25);
}
.login-logo h1 { font-size: 22px; font-weight: 800; }
.login-logo p { font-size: 12px; color: var(--accent-gold); letter-spacing: 2px; }
.login-title { text-align: center; font-size: 16px; color: var(--text-secondary); margin-bottom: 24px; }
.login-form { display: flex; flex-direction: column; gap: 16px; }
.login-input-wrapper { position: relative; }
.login-input-wrapper svg {
  position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
  width: 18px !important; height: 18px !important; color: var(--text-muted); pointer-events: none;
}
.login-input {
  width: 100%; padding: 14px 44px 14px 16px; border-radius: 12px;
  border: 1px solid var(--border-color); background: var(--bg-input);
  color: var(--text-primary); font-family: inherit; font-size: 14px;
}
.login-input:focus { outline: none; border-color: var(--accent-gold); box-shadow: 0 0 0 3px rgba(212,168,75,0.1); }
.login-submit {
  width: 100%; padding: 14px; border-radius: 12px; border: none;
  background: linear-gradient(135deg, var(--accent-gold) 0%, var(--accent-gold-dark) 100%);
  color: #0a0e1a; font-family: inherit; font-size: 15px; font-weight: 700;
  cursor: pointer; margin-top: 8px;
}
.login-submit:hover { transform: translateY(-1px); box-shadow: 0 12px 24px rgba(212,168,75,0.3); }
.login-error {
  padding: 12px; border-radius: 10px; background: rgba(244,63,94,0.1);
  border: 1px solid rgba(244,63,94,0.3); color: var(--accent-rose);
  font-size: 13px; text-align: center;
}
.login-hint {
  margin-top: 20px; padding: 12px; background: rgba(212,168,75,0.05);
  border: 1px dashed rgba(212,168,75,0.2); border-radius: 10px;
  font-size: 12px; color: var(--text-secondary); text-align: center; line-height: 1.7;
}
.login-hint code {
  background: var(--bg-input); padding: 2px 8px; border-radius: 4px;
  color: var(--accent-gold); font-family: monospace;
}

/* ============ PERMISSIONS ============ */
.perm-group {
  background: var(--bg-input); border: 1px solid var(--border-color);
  border-radius: 10px; padding: 14px; margin-bottom: 12px;
}
.perm-group-title {
  font-size: 12px; font-weight: 700; color: var(--accent-gold);
  margin-bottom: 10px; display: flex; justify-content: space-between; align-items: center;
}
.perm-toggle-all {
  font-size: 11px; background: transparent; border: 1px solid var(--border-color);
  color: var(--text-secondary); padding: 3px 10px; border-radius: 20px;
  cursor: pointer; font-family: inherit;
}
.perm-toggle-all:hover { background: var(--accent-gold); color: #0a0e1a; border-color: var(--accent-gold); }
.perm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.perm-item {
  display: flex; align-items: center; gap: 8px; padding: 8px 10px;
  background: var(--bg-card); border: 1px solid var(--border-color);
  border-radius: 8px; cursor: pointer; transition: all 0.15s ease; font-size: 12px;
}
.perm-item:hover { border-color: var(--accent-gold); }
.perm-item input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--accent-gold); cursor: pointer; }
.perm-item label { cursor: pointer; flex: 1; color: var(--text-secondary); }
.perm-item input:checked + label { color: var(--text-primary); font-weight: 600; }

.section-label {
  font-size: 12px; color: var(--accent-gold); font-weight: 700;
  margin-bottom: 12px; padding-right: 10px; border-right: 3px solid var(--accent-gold);
}

/* ============ PRINT ============ */
@media print {
  body { background: white !important; color: black !important; }
  .sidebar, .page-header button, .actions, .card-header button { display: none !important; }
  .main-content { padding: 20px !important; }
  .content-card, .stat-card { background: white !important; border: 1px solid #ccc !important; box-shadow: none !important; }
  * { color: black !important; }
  th { background: #f5f5f5 !important; }
}

/* ============ RESPONSIVE ============ */
@media (max-width: 900px) {
  .app-container { grid-template-columns: 1fr; }
  .sidebar { position: relative; height: auto; border-left: none; border-bottom: 1px solid var(--border-color); }
  .form-grid, .zakat-grid { grid-template-columns: 1fr; }
  .main-content { padding: 20px; }
}

/* ============ HIDE ============ */
.hidden { display: none !important; }
