/* ==========================================================================
   UI BRIDGE DESIGN SYSTEM (Single Reusable Component Bridge)
   Management Usaha Pondok — Modern, Standardized, Standalone-First
   ========================================================================== */

/* --------------------------------------------------------------------------
   0. ACCESSIBILITY UTILITIES (Screen Reader Only / Visually Hidden)
   -------------------------------------------------------------------------- */
.sr-only,
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* --------------------------------------------------------------------------
   1. NAVBAR SUB-MENU DROPDOWN (Headbar Navigation)
   -------------------------------------------------------------------------- */
.nav-dropdown-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.nav-link.nav-dropdown-trigger {
  cursor: pointer;
  user-select: none;
}

.nav-dropdown-wrapper:hover .nav-dropdown-menu,
.nav-dropdown-wrapper:focus-within .nav-dropdown-menu,
.nav-dropdown-wrapper.open .nav-dropdown-menu {
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
  transform: translateY(0) !important;
}

.nav-dropdown-wrapper:hover .dropdown-chevron,
.nav-dropdown-wrapper:focus-within .dropdown-chevron,
.nav-dropdown-wrapper.open .dropdown-chevron {
  transform: rotate(180deg);
}

.nav-dropdown-menu {
  display: none;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  max-width: 280px;
  background: var(--color-surface, #ffffff);
  border: 1px solid var(--color-border, #e2e8f0);
  border-radius: var(--radius-lg, 12px);
  box-shadow: 0 12px 28px -4px rgba(0, 0, 0, 0.16), 0 4px 10px rgba(0, 0, 0, 0.06);
  z-index: 9999;
  padding: 6px 0;
  transform: translateY(-4px);
  transition: opacity 0.18s ease-out, transform 0.18s ease-out;
}

/* Hover bridge to keep dropdown open during mouse transit */
.nav-dropdown-menu::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 0;
  right: 0;
  height: 8px;
}

.nav-dropdown-item {
  display: flex;
  align-items: center;
  padding: 9px 16px;
  color: var(--color-text, #1e293b);
  text-decoration: none;
  font-size: 13px;
  font-weight: 550;
  transition: background 0.15s ease, color 0.15s ease;
}

.nav-dropdown-item:hover {
  background: var(--color-primary-050, #f0fdf4);
  color: var(--color-primary-900, #07513f);
}

.nav-dropdown-item-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
}

.nav-dropdown-item-desc {
  font-size: 11px;
  color: var(--color-text-soft, #64748b);
  margin-top: 2px;
  line-height: 1.35;
}

.nav-dropdown-item-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 9999px;
  background: #ecfdf5;
  color: #065f46;
  white-space: nowrap;
  flex-shrink: 0;
  margin-top: 2px;
}

/* --------------------------------------------------------------------------
   2. STANDARDIZED DATA TABLE (Toolbar, Search, Filters, Table, Pagination)
   -------------------------------------------------------------------------- */
.ui-table-card {
  background: var(--color-surface, #ffffff);
  border: 1px solid var(--color-border, #e2e8f0);
  border-radius: var(--radius-xl, 14px);
  box-shadow: var(--shadow-sm, 0 1px 3px rgba(0, 0, 0, 0.05));
  overflow: hidden;
  margin-bottom: 24px;
}

/* Table Toolbar (Search, Filter, Actions) */
.ui-table-toolbar {
  padding: 16px 20px;
  background: #ffffff;
  border-bottom: 1px solid var(--color-border, #e2e8f0);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.ui-table-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  flex: 1 1 300px;
}

.ui-search-input-wrapper {
  position: relative;
  min-width: 240px;
  max-width: 360px;
  flex: 1;
}

.ui-search-input-wrapper svg {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: #94a3b8;
  pointer-events: none;
}

.ui-search-input {
  width: 100%;
  padding: 8px 12px 8px 34px;
  font-size: 13px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  outline: none;
  background: #f8fafc;
  color: #1e293b;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}

.ui-search-input:focus {
  background: #ffffff;
  border-color: var(--color-primary-900, #07513f);
  box-shadow: 0 0 0 3px rgba(7, 81, 63, 0.12);
}

.ui-filter-select {
  padding: 8px 30px 8px 12px;
  font-size: 13px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  outline: none;
  background: #f8fafc url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E") no-repeat right 8px center / 14px;
  color: #334155;
  cursor: pointer;
  appearance: none;
  transition: border-color 0.15s;
}

.ui-filter-select:focus {
  border-color: var(--color-primary-900, #07513f);
}

.ui-table-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Data Table Wrapper & Table Elements */
.ui-table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.ui-data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 13px;
  line-height: 1.5;
}

.ui-data-table th {
  background: #f8fafc;
  color: #475569;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 12px 18px;
  border-bottom: 1px solid #e2e8f0;
  white-space: nowrap;
}

.ui-data-table td {
  padding: 14px 18px;
  border-bottom: 1px solid #f1f5f9;
  color: #1e293b;
  vertical-align: middle;
}

/* Standard Table Action Column: Anti-Wrap & Alignment Protection */
.ui-data-table th.col-actions,
.ui-data-table td.col-actions,
.ui-data-table th:last-child,
.ui-data-table td:last-child,
.ui-table th:last-child,
.ui-table td:last-child,
table.min-w-full th:last-child,
table.min-w-full td:last-child {
  text-align: right !important;
  white-space: nowrap !important;
  min-width: 120px;
}

.ui-data-table tbody tr {
  transition: background-color 0.15s ease;
}

.ui-data-table tbody tr:hover {
  background-color: #f8fafc;
}

.ui-data-table tbody tr:last-child td {
  border-bottom: none;
}

/* Empty State */
.ui-table-empty {
  padding: 48px 24px;
  text-align: center;
  color: #64748b;
}

.ui-table-empty-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 14px;
  border-radius: 14px;
  background: #f1f5f9;
  color: #94a3b8;
  display: grid;
  place-items: center;
}

.ui-table-empty-title {
  font-size: 15px;
  font-weight: 700;
  color: #334155;
  margin-bottom: 4px;
}

.ui-table-empty-desc {
  font-size: 13px;
  color: #64748b;
  max-width: 420px;
  margin: 0 auto 16px;
}

/* Pagination Bar */
.ui-pagination-bar {
  padding: 14px 20px;
  background: #ffffff;
  border-top: 1px solid var(--color-border, #e2e8f0);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  color: #64748b;
}

.ui-pagination-info {
  font-weight: 500;
}

.ui-pagination-controls {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.ui-page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  padding: 0 8px;
  border-radius: 6px;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #334155;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s ease;
}

.ui-page-btn:hover:not(:disabled):not(.active) {
  background: #f8fafc;
  border-color: #94a3b8;
}

.ui-page-btn.active {
  background: var(--color-primary-900, #07513f);
  color: #ffffff;
  border-color: var(--color-primary-900, #07513f);
}

.ui-page-btn:disabled,
.ui-page-btn.disabled {
  opacity: 0.4;
  cursor: not-allowed;
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   3. ACTION MENU "TITIK 3" / "TITIK 2" (Floating Action Popover)
   -------------------------------------------------------------------------- */
.ui-action-menu-wrapper {
  position: relative;
  display: inline-block;
  text-align: right;
}

.ui-action-trigger-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: #64748b;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.ui-action-trigger-btn:hover,
.ui-action-trigger-btn.active {
  background: #f1f5f9;
  color: #0f172a;
  border-color: #cbd5e1;
}

.ui-action-dropdown-popover {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  min-width: 190px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.12), 0 4px 6px rgba(0, 0, 0, 0.04);
  z-index: 1050;
  padding: 6px 0;
  text-align: left;
  animation: actionFadeIn 0.14s ease-out;
}

.ui-action-dropdown-popover.show {
  display: block;
}

@keyframes actionFadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.ui-action-item {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 8px 14px;
  font-size: 12.5px;
  color: #334155;
  background: transparent;
  border: none;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}

.ui-action-item svg {
  width: 15px;
  height: 15px;
  color: #64748b;
  flex-shrink: 0;
}

.ui-action-item:hover {
  background: #f8fafc;
  color: var(--color-primary-900, #07513f);
}

.ui-action-item:hover svg {
  color: var(--color-primary-900, #07513f);
}

.ui-action-item.danger {
  color: #b91c1c;
}

.ui-action-item.danger svg {
  color: #ef4444;
}

.ui-action-item.danger:hover {
  background: #fef2f2;
  color: #991b1b;
}

.ui-action-divider {
  height: 1px;
  background: #f1f5f9;
  margin: 4px 0;
}

/* --------------------------------------------------------------------------
   4. STANDARDIZED FORM FIELDS & CONTROLS
   -------------------------------------------------------------------------- */
.ui-form-group {
  margin-bottom: 18px;
}

.ui-form-label {
  display: block;
  font-size: 13px;
  font-weight: 650;
  color: #334155;
  margin-bottom: 6px;
}

.ui-form-label .required-mark {
  color: #dc2626;
  margin-left: 2px;
}

.ui-form-control {
  width: 100%;
  padding: 9px 13px;
  font-size: 13.5px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #ffffff;
  color: #1e293b;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  font-family: inherit;
}

.ui-form-control:focus {
  border-color: var(--color-primary-900, #07513f);
  box-shadow: 0 0 0 3px rgba(7, 81, 63, 0.12);
}

.ui-form-control:disabled,
.ui-form-control[readonly] {
  background: #f1f5f9;
  color: #64748b;
  cursor: not-allowed;
}

.ui-form-control.is-invalid {
  border-color: #ef4444;
  background-color: #fffaf0;
}

.ui-form-control.is-invalid:focus {
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

/* Currency Input with "Rp" Prefix */
.ui-currency-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.ui-currency-prefix {
  position: absolute;
  left: 12px;
  font-size: 13px;
  font-weight: 700;
  color: #64748b;
  pointer-events: none;
}

.ui-currency-input {
  padding-left: 38px;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

/* Helper text & Error Feedback */
.ui-form-help {
  font-size: 11.5px;
  color: #64748b;
  margin-top: 4px;
}

.ui-form-error {
  font-size: 11.5px;
  color: #dc2626;
  margin-top: 4px;
  font-weight: 500;
}

/* Modern Toggle Switch */
.ui-toggle-switch {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  user-select: none;
}

.ui-toggle-switch input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.ui-toggle-track {
  width: 44px;
  height: 24px;
  border-radius: 9999px;
  background: #cbd5e1;
  position: relative;
  transition: background-color 0.2s;
}

.ui-toggle-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffffff;
  position: absolute;
  top: 3px;
  left: 3px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.ui-toggle-switch input:checked + .ui-toggle-track {
  background: var(--color-primary-900, #07513f);
}

.ui-toggle-switch input:checked + .ui-toggle-track .ui-toggle-thumb {
  transform: translateX(20px);
}

/* --------------------------------------------------------------------------
   5. STANDARDIZED MODAL DIALOG
   -------------------------------------------------------------------------- */
.ui-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(2px);
  z-index: 1200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  transition: opacity 0.2s ease-out;
}

.ui-modal-overlay.active {
  display: flex;
  opacity: 1;
}

.ui-modal-card {
  width: 100%;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  border: 1px solid #e2e8f0;
  overflow: hidden;
  transform: scale(0.96) translateY(8px);
  transition: transform 0.2s ease-out;
  max-height: calc(100vh - 32px);
  display: flex;
  flex-direction: column;
}

.ui-modal-overlay.active .ui-modal-card {
  transform: scale(1) translateY(0);
}

/* Modal Sizes */
.ui-modal-sm { max-width: 420px; }
.ui-modal-md { max-width: 560px; }
.ui-modal-lg { max-width: 780px; }
.ui-modal-xl { max-width: 1020px; }

.ui-modal-header {
  padding: 18px 24px;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #ffffff;
  flex-shrink: 0;
}

.ui-modal-title {
  font-size: 16px;
  font-weight: 750;
  color: #0f172a;
  margin: 0;
}

.ui-modal-subtitle {
  font-size: 12px;
  color: #64748b;
  margin-top: 2px;
}

.ui-modal-close-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: #94a3b8;
  font-size: 20px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.ui-modal-close-btn:hover {
  background: #f1f5f9;
  color: #334155;
}

.ui-modal-body {
  padding: 22px 24px;
  overflow-y: auto;
  flex: 1 1 auto;
}

.ui-modal-footer {
  padding: 16px 24px;
  border-top: 1px solid #e2e8f0;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-shrink: 0;
}

/* Modal Form Controls & Grid Standard */
.ui-modal-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}
.ui-modal-form-grid.single-col {
  grid-template-columns: 1fr;
}
.ui-modal-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ui-modal-form-label {
  font-size: 12.5px;
  font-weight: 650;
  color: #334155;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.ui-modal-form-label .required {
  color: #e11d48;
  margin-left: 2px;
}
.ui-modal-form-control {
  width: 100%;
  padding: 9px 13px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  font-size: 13.5px;
  color: #1e293b;
  background: #ffffff;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  box-sizing: border-box;
}
.ui-modal-form-control:focus {
  border-color: var(--color-primary-800, #07513f);
  box-shadow: 0 0 0 3px rgba(7, 81, 63, 0.12);
}
.ui-modal-form-hint {
  font-size: 11px;
  color: #64748b;
  margin-top: 2px;
}
.ui-modal-callout {
  padding: 12px 16px;
  border-radius: 10px;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
  font-size: 12.5px;
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.ui-modal-callout.info {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1e40af;
}
.ui-modal-callout.warning {
  background: #fffbeb;
  border-color: #fde68a;
  color: #92400e;
}

/* --------------------------------------------------------------------------
   6. HOME NAVIGATION V2 & SUMMARY CARDS (UI-DEC-001)
   -------------------------------------------------------------------------- */
.summary-grid-v2 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

@media (max-width: 992px) {
  .summary-grid-v2 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 576px) {
  .summary-grid-v2 {
    grid-template-columns: 1fr;
  }
}

/* Home Menu Grid (Grid 4 Kolom Sesuai Permintaan) */
.home-menu-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 28px;
}

@media (max-width: 900px) {
  .home-menu-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }
}

@media (max-width: 600px) {
  .home-menu-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
}

@media (max-width: 400px) {
  .home-menu-grid {
    grid-template-columns: 1fr;
  }
}

/* Home Menu Card */
.home-menu-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 116px;
  min-width: 44px;
  padding: 18px 12px 14px;
  background: var(--color-surface, #ffffff);
  border: 1px solid var(--color-border, #e2e8f0);
  border-radius: var(--radius-lg, 14px);
  text-decoration: none;
  color: var(--color-text, #1e293b);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: transform 0.18s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.18s ease, border-color 0.18s ease;
  user-select: none;
  outline: none;
}

.home-menu-card:focus-visible {
  box-shadow: 0 0 0 3px rgba(7, 81, 63, 0.35);
  border-color: var(--color-primary-900, #07513f);
}

.home-menu-card:hover {
  transform: translateY(-3px);
  border-color: var(--color-primary-700, #0a6c53);
  box-shadow: 0 8px 18px -4px rgba(7, 81, 63, 0.14);
}

.home-menu-card:active {
  transform: translateY(-1px);
}

.home-menu-icon {
  width: 56px;
  height: 56px;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
  flex-shrink: 0;
}

.home-menu-icon svg {
  width: 52px;
  height: 52px;
  max-width: 52px;
  max-height: 52px;
  display: block;
}

.home-menu-card:hover .icon-3d-wrapper {
  transform: translateY(-3px) scale(1.08);
}

.home-menu-icon-img {
  width: 60px;
  height: 60px;
  max-width: 60px;
  max-height: 60px;
  object-fit: contain;
  filter: drop-shadow(0 6px 12px rgba(7, 81, 63, 0.12));
  transition: transform 0.22s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.22s ease;
}

.home-menu-card:hover .home-menu-icon-img {
  transform: translateY(-4px) scale(1.1);
  filter: drop-shadow(0 12px 20px rgba(7, 81, 63, 0.22));
}

.home-menu-title {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.25;
  color: var(--color-text, #1e293b);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Badge pada Kartu Menu (HANYA muncul jika > 0) */
.home-menu-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 10px;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
}

.badge-danger {
  background: #fee2e2;
  color: #dc2626;
  border: 1px solid #fca5a5;
}

.badge-warning {
  background: #fef3c7;
  color: #b45309;
  border: 1px solid #fde68a;
}

.badge-info {
  background: #e0f2fe;
  color: #0284c7;
  border: 1px solid #bae6fd;
}

/* --------------------------------------------------------------------------
   7. TUGAS SAYA & PERLU PERHATIAN (Maksimal 5 item)
   -------------------------------------------------------------------------- */
.task-section {
  background: var(--color-surface, #ffffff);
  border: 1px solid var(--color-border, #e2e8f0);
  border-radius: var(--radius-lg, 14px);
  padding: 20px 24px;
  margin-bottom: 28px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.task-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--color-border-subtle, #f1f5f9);
}

.task-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 750;
  color: var(--color-text, #1e293b);
}

.task-icon {
  width: 18px;
  height: 18px;
  color: var(--color-primary-900, #07513f);
}

.task-count-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
  background: #f1f5f9;
  color: #64748b;
}

.task-list {
  display: flex;
  flex-direction: column;
}

.task-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid #f8fafc;
}

.task-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.task-item-main {
  flex: 1 1 auto;
  overflow: hidden;
}

.task-item-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text, #1e293b);
  margin-bottom: 2px;
}

.task-item-meta {
  font-size: 12px;
  color: var(--color-text-muted, #64748b);
  display: flex;
  gap: 8px;
  align-items: center;
}

.task-item-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.task-status-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 6px;
}

.task-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  color: var(--color-primary-900, #07513f);
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  transition: background 0.15s;
}

.task-action-btn:hover {
  background: #d1fae5;
}

.task-empty-state {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px 16px;
  color: var(--color-text-muted, #64748b);
  font-size: 13px;
}

.task-empty-icon {
  width: 20px;
  height: 20px;
  color: #10b981;
}

/* --------------------------------------------------------------------------
   8. AUDITED SUPPORT CONTEXT BANNER
   -------------------------------------------------------------------------- */
.support-context-banner {
  background: #fffbeb;
  border-bottom: 1px solid #fde68a;
  color: #92400e;
  padding: 10px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 12px;
  position: relative;
  z-index: 1050;
}

.support-banner-content {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.support-banner-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fef3c7;
  color: #b45309;
  border: 1px solid #fde68a;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 11px;
  letter-spacing: 0.02em;
}

.support-banner-details {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.support-sep {
  color: #d97706;
}

.badge-mode-ro {
  display: inline-block;
  background: #e0f2fe;
  color: #0369a1;
  padding: 1px 6px;
  border-radius: 4px;
  font-weight: 750;
  font-size: 10px;
}

.btn-support-exit {
  background: #b45309;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  padding: 5px 12px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s;
  font-family: inherit;
}

.btn-support-exit:hover {
  background: #92400e;
}

/* Hero Banner: Tampilan Banner dengan Navigasi Breadcrumbs & Judul Halaman Tanpa Keterangan */
.hero-banner {
  min-height: 125px;
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
  margin: 0 calc(-1 * var(--page-gutter, 24px)) 24px;
  padding: 16px 7.2%;
  background: linear-gradient(105deg, #f8f5e9 0%, #f3f4e8 52%, #eaf1e5 100%);
  border-bottom: 1px solid #e4e2cf;
}
.hero-banner::before {
  content: "";
  position: absolute;
  left: -75px;
  top: -112px;
  width: 270px;
  height: 295px;
  transform: rotate(-9deg);
  border-radius: 0 0 90% 0;
  background: linear-gradient(140deg, #057253, #0b8a68);
  box-shadow: inset -5px -4px 0 rgba(200, 166, 83, 0.85);
}
.hero-copy {
  position: relative;
  z-index: 2;
  margin-left: 92px;
  max-width: 750px;
}
.hero-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #4b6354;
  margin-bottom: 5px;
}
.hero-breadcrumb-link {
  color: #07513f;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: opacity 0.15s;
}
.hero-breadcrumb-link:hover {
  text-decoration: underline;
}
.hero-breadcrumb-sep {
  color: #94a3b8;
  font-size: 11px;
}
.hero-breadcrumb-current {
  color: #1e293b;
  font-weight: 700;
}
.hero-title {
  margin: 0;
  color: #07513f;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.6px;
  line-height: 1.2;
}
.hero-accent {
  width: 54px;
  height: 3px;
  margin-top: 8px;
  border-radius: 10px;
  background: #c8a653;
}
.hero-image-slot {
  position: absolute;
  z-index: 1;
  right: 5.5%;
  bottom: 12px;
  width: min(30%, 320px);
  height: 95px;
  border: 1px dashed rgba(93, 129, 101, 0.28);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #07513f;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  padding: 8px 16px;
}



/* ==============================================================================
   STANDARDIZED MOBILE NAVIGATION DRAWER & TOPBAR (Dokumen 169)
   ============================================================================== */
.mobile-nav-toggle {
  display: none;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.mobile-nav-toggle:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.4);
}
@media (max-width: 1024px) {
  .mobile-nav-toggle {
    display: inline-flex;
  }
  .topbar .main-nav {
    display: none !important;
  }
}

.mobile-nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(6, 42, 33, 0.65);
  backdrop-filter: blur(4px);
  z-index: 99998;
  opacity: 0;
  transition: opacity 0.22s ease-out;
}
.mobile-nav-overlay.open {
  display: block;
  opacity: 1;
}

.mobile-nav-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: min(85vw, 320px);
  background: #ffffff;
  z-index: 99999;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  transform: translateX(-100%);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.mobile-nav-drawer.open {
  transform: translateX(0);
}
.mobile-nav-header {
  padding: 16px 20px;
  background: var(--color-primary-050, #f2f8f3);
  border-bottom: 1px solid var(--color-border, #e2e8f0);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.mobile-nav-close {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: #64748b;
  font-size: 22px;
  cursor: pointer;
  line-height: 1;
}
.mobile-nav-close:hover {
  background: #fee2e2;
  color: #991b1b;
}
.mobile-nav-body {
  flex: 1;
  overflow-y: auto;
  padding: 12px 14px;
}
.mobile-nav-group {
  margin-bottom: 4px;
}
.mobile-nav-link {
  display: flex;
  align-items: center;
  padding: 10px 14px;
  font-size: 13.5px;
  font-weight: 700;
  color: #1e293b;
  text-decoration: none;
  border-radius: 8px;
  min-height: 44px; /* Fitts's Law touch target >= 44px */
  transition: all 0.15s ease;
}
.mobile-nav-link:hover,
.mobile-nav-link.active {
  background: var(--color-primary-050, #f0fdf4);
  color: var(--color-primary-900, #07513f);
}
.mobile-subnav-list {
  padding-left: 14px;
  margin-top: 2px;
}
.mobile-subnav-item {
  display: flex;
  align-items: center;
  padding: 8px 12px;
  font-size: 12.5px;
  font-weight: 550;
  color: #64748b;
  text-decoration: none;
  border-radius: 6px;
  min-height: 38px;
  transition: all 0.15s ease;
}
.mobile-subnav-item:hover {
  background: #f1f5f9;
  color: var(--color-primary-900, #07513f);
}

/* ==============================================================================
   STANDARDIZED ACTION BUTTONS (DETAIL, EDIT, DELETE, MORE)
   ============================================================================== */
.ui-action-btn-group {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  vertical-align: middle;
  white-space: nowrap;
  flex-wrap: nowrap;
}
.ui-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  min-width: 32px;
  min-height: 32px;
  max-width: 32px;
  max-height: 32px;
  border-radius: 8px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  position: relative;
  transition: all 0.16s ease-in-out;
  overflow: hidden;
  flex-shrink: 0;
  padding: 0;
  line-height: 1;
}
.ui-action-btn svg {
  width: 15px;
  height: 15px;
  display: block;
  flex-shrink: 0;
  pointer-events: none;
}
/* Strictly hide any text or sr-only span inside action icon buttons */
.ui-action-btn span,
.ui-action-btn .sr-only,
.ui-action-btn .visually-hidden {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
  font-size: 0 !important;
  line-height: 0 !important;
}
/* Accessible touch area padding helper */
.ui-action-btn::after {
  content: '';
  position: absolute;
  inset: -6px;
}

/* Detail Button (Emerald / Pesantren Primary) */
.ui-action-btn-detail {
  background: #f0fdf4;
  color: #07513f;
  border-color: #bbf7d0;
}
.ui-action-btn-detail:hover {
  background: #07513f;
  color: #ffffff;
  border-color: #07513f;
  box-shadow: 0 2px 6px rgba(7, 81, 63, 0.25);
  transform: translateY(-1px);
}

/* Edit Button (Slate / Dark) */
.ui-action-btn-edit {
  background: #f8fafc;
  color: #334155;
  border-color: #cbd5e1;
}
.ui-action-btn-edit:hover {
  background: #0f172a;
  color: #ffffff;
  border-color: #0f172a;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.2);
  transform: translateY(-1px);
}

/* Delete Button (Rose / Danger) */
.ui-action-btn-delete {
  background: #fef2f2;
  color: #bd4d4d;
  border-color: #fecaca;
}
.ui-action-btn-delete:hover {
  background: #bd4d4d;
  color: #ffffff;
  border-color: #bd4d4d;
  box-shadow: 0 2px 6px rgba(189, 77, 77, 0.25);
  transform: translateY(-1px);
}

/* More Button ("Titik 3") */
.ui-action-btn-more {
  background: #ffffff;
  color: #64748b;
  border-color: #e2e8f0;
}
.ui-action-btn-more:hover {
  background: #f1f5f9;
  color: #0f172a;
  border-color: #cbd5e1;
}

/* Process / Verify / Quick Action Button (Royal Blue / Execution) */
.ui-action-btn-process {
  background: #eff6ff;
  color: #1d4ed8;
  border-color: #bfdbfe;
}
.ui-action-btn-process:hover {
  background: #1d4ed8;
  color: #ffffff;
  border-color: #1d4ed8;
  box-shadow: 0 2px 6px rgba(29, 78, 216, 0.25);
  transform: translateY(-1px);
}

/* Print / Invoice Button (Amber / Gold) */
.ui-action-btn-print {
  background: #fef3c7;
  color: #b45309;
  border-color: #fde68a;
}
.ui-action-btn-print:hover {
  background: #b45309;
  color: #ffffff;
  border-color: #b45309;
  box-shadow: 0 2px 6px rgba(180, 83, 9, 0.25);
  transform: translateY(-1px);
}

/* Download / Export Button (Teal) */
.ui-action-btn-download {
  background: #f0fdfa;
  color: #0f766e;
  border-color: #99f6e4;
}
.ui-action-btn-download:hover {
  background: #0f766e;
  color: #ffffff;
  border-color: #0f766e;
  box-shadow: 0 2px 6px rgba(15, 118, 110, 0.25);
  transform: translateY(-1px);
}

/* Warning / Hold Button (Orange) */
.ui-action-btn-warning {
  background: #fff7ed;
  color: #c2410c;
  border-color: #fed7aa;
}
.ui-action-btn-warning:hover {
  background: #c2410c;
  color: #ffffff;
  border-color: #c2410c;
  box-shadow: 0 2px 6px rgba(194, 65, 12, 0.25);
  transform: translateY(-1px);
}

/* ==============================================================================
   STANDARDIZED ACTION PILLS (ICON + LABEL BUTTONS)
   ============================================================================== */
.ui-action-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 32px;
  padding: 0 11px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
  text-decoration: none;
  border: 1px solid transparent;
  transition: all 0.16s ease-in-out;
  white-space: nowrap;
  vertical-align: middle;
}
.ui-action-pill svg {
  width: 14px;
  height: 14px;
  display: block;
  flex-shrink: 0;
}
.ui-action-pill-process {
  background: #eff6ff;
  color: #1d4ed8;
  border-color: #bfdbfe;
}
.ui-action-pill-process:hover {
  background: #1d4ed8;
  color: #ffffff;
  border-color: #1d4ed8;
  box-shadow: 0 2px 6px rgba(29, 78, 216, 0.2);
  transform: translateY(-1px);
}
.ui-action-pill-success {
  background: #f0fdf4;
  color: #07513f;
  border-color: #bbf7d0;
}
.ui-action-pill-success:hover {
  background: #07513f;
  color: #ffffff;
  border-color: #07513f;
  box-shadow: 0 2px 6px rgba(7, 81, 63, 0.2);
  transform: translateY(-1px);
}
.ui-action-pill-edit {
  background: #f8fafc;
  color: #334155;
  border-color: #cbd5e1;
}
.ui-action-pill-edit:hover {
  background: #0f172a;
  color: #ffffff;
  border-color: #0f172a;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.2);
  transform: translateY(-1px);
}
.ui-action-pill-print {
  background: #fef3c7;
  color: #b45309;
  border-color: #fde68a;
}
.ui-action-pill-print:hover {
  background: #b45309;
  color: #ffffff;
  border-color: #b45309;
  box-shadow: 0 2px 6px rgba(180, 83, 9, 0.2);
  transform: translateY(-1px);
}
.ui-action-pill-download {
  background: #f0fdfa;
  color: #0f766e;
  border-color: #99f6e4;
}
.ui-action-pill-download:hover {
  background: #0f766e;
  color: #ffffff;
  border-color: #0f766e;
  box-shadow: 0 2px 6px rgba(15, 118, 110, 0.2);
  transform: translateY(-1px);
}
.ui-action-pill-warning {
  background: #fff7ed;
  color: #c2410c;
  border-color: #fed7aa;
}
.ui-action-pill-warning:hover {
  background: #c2410c;
  color: #ffffff;
  border-color: #c2410c;
  box-shadow: 0 2px 6px rgba(194, 65, 12, 0.2);
  transform: translateY(-1px);
}
.ui-action-pill-delete {
  background: #fef2f2;
  color: #bd4d4d;
  border-color: #fecaca;
}
.ui-action-pill-delete:hover {
  background: #bd4d4d;
  color: #ffffff;
  border-color: #bd4d4d;
  box-shadow: 0 2px 6px rgba(189, 77, 77, 0.2);
  transform: translateY(-1px);
}

/* ==============================================================================
   TABLE SORTABLE HEADERS & COLUMN NUMBER STYLING
   ============================================================================== */
.ui-col-number {
  width: 52px;
  min-width: 52px;
  text-align: center !important;
  color: #64748b;
  font-weight: 700;
}
.ui-cell-number {
  text-align: center !important;
  color: #64748b;
  font-weight: 550;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
}
th.ui-sortable {
  cursor: pointer;
  user-select: none;
  transition: background-color 0.15s, color 0.15s;
}
th.ui-sortable:hover {
  background-color: #f1f5f9;
  color: var(--color-primary-900, #07513f);
}
.ui-sort-indicator {
  display: inline-flex;
  align-items: center;
  margin-left: 6px;
  color: #94a3b8;
  font-size: 11px;
  font-weight: normal;
  transition: color 0.15s, transform 0.15s;
}
th.ui-sortable:hover .ui-sort-indicator {
  color: var(--color-primary-900, #07513f);
}
th.ui-sortable.sort-asc .ui-sort-indicator,
th.ui-sortable.sort-desc .ui-sort-indicator {
  color: var(--color-primary-900, #07513f);
  font-weight: 700;
}

/* Page Size Selector */
.ui-pagesize-wrapper {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: #64748b;
}
.ui-pagesize-select {
  padding: 4px 24px 4px 8px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #ffffff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E") no-repeat right 6px center / 12px;
  color: #334155;
  cursor: pointer;
  appearance: none;
}
.ui-pagesize-select:focus {
  outline: none;
  border-color: var(--color-primary-900, #07513f);
}

/* ==============================================================================
   STANDARDIZED FOOTER STYLES (Design System Pesantren)
   ============================================================================== */
.footer-frame {
  margin-top: 56px;
  background: #ffffff;
  border-top: 2px solid var(--color-secondary-500, #c8a653);
  box-shadow: 0 -4px 18px rgba(0, 42, 31, 0.035);
  color: var(--color-text, #193b30);
  font-family: inherit;
}
.footer-container {
  max-width: var(--content-max, 1500px);
  margin: 0 auto;
  padding: 44px 28px 28px;
}
.footer-top-grid {
  display: grid;
  grid-template-columns: 2.2fr 1fr 1fr 1.4fr;
  gap: 36px;
}
@media (max-width: 1024px) {
  .footer-top-grid {
    grid-template-columns: 1fr 1fr;
    gap: 28px;
  }
}
@media (max-width: 640px) {
  .footer-top-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}
.footer-brand-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.footer-logo-slot {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--color-primary-050, #f2f8f3);
  border: 1px solid var(--color-primary-100, #e3f1e8);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.footer-logo-img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}
.footer-brand-title {
  font-size: 16px;
  font-weight: 850;
  color: var(--color-primary-950, #063b2f);
  line-height: 1.2;
}
.footer-brand-subtitle {
  font-size: 11px;
  font-weight: 600;
  color: var(--color-secondary-900, #775d25);
  letter-spacing: 0.02em;
}
.footer-mission-text {
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--color-text-soft, #64766d);
  margin: 0 0 14px 0;
  max-width: 480px;
}
.footer-tagline-pills {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  color: var(--color-primary-800, #08664d);
}
.footer-pill {
  background: var(--color-primary-050, #f2f8f3);
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid var(--color-primary-100, #e3f1e8);
}
.footer-pill-sep {
  color: var(--color-secondary-500, #c8a653);
  font-size: 9px;
}
.footer-heading {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-primary-950, #063b2f);
  margin-bottom: 14px;
}
.footer-nav-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-nav-list li {
  margin-bottom: 9px;
}
.footer-nav-list a {
  color: var(--color-text-soft, #64766d);
  text-decoration: none;
  font-size: 12.5px;
  font-weight: 500;
  transition: color 0.15s ease;
}
.footer-nav-list a:hover {
  color: var(--color-primary-900, #07513f);
  text-decoration: underline;
}
.footer-status-box {
  background: var(--color-surface-soft, #fbfcf9);
  border: 1px solid var(--color-border, #e4eae3);
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 12px;
}
.footer-status-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-weight: 750;
  color: var(--color-success, #16845d);
}
.status-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-success, #16845d);
  box-shadow: 0 0 0 3px rgba(22, 132, 93, 0.2);
  display: inline-block;
}
.footer-spec-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 6px;
  color: var(--color-text-soft, #64766d);
  font-size: 11.5px;
}
.footer-divider {
  height: 1px;
  background: var(--color-border, #e4eae3);
  margin: 28px 0 20px;
}
.footer-bottom-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 11.5px;
  color: var(--color-text-muted, #8b9890);
}
.footer-version-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--color-secondary-100, #f7f0dc);
  color: var(--color-secondary-900, #775d25);
  font-weight: 700;
  font-size: 10.5px;
  border: 1px solid var(--color-secondary-200, #eadcb4);
}
