/* =========================================================
   DASHBOARD.CSS - Khusus untuk halaman Dashboard & Tetapan
   ========================================================= */

/* SKRIN PENGAKTIFAN & LOADING */
.activation-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100vh; background: rgba(0,0,0,0.85); backdrop-filter: blur(5px); z-index: 9999; display: flex; justify-content: center; align-items: center; }
.activation-box { background: white; padding: 40px; border-radius: 12px; text-align: center; box-shadow: 0 20px 50px rgba(0,0,0,0.3); max-width: 400px; width: 90%; }
.activation-box h2 { margin-top: 0; font-weight: 800; color: #2c3e50; }
.activation-box p { font-size: 13px; color: #555; margin-bottom: 20px; line-height: 1.5; }
.activation-input { width: 100%; padding: 12px; margin-bottom: 20px; border: 2px solid #ddd; border-radius: 6px; font-family: 'Montserrat'; font-weight: 700; font-size: 16px; text-align: center; box-sizing: border-box;}
.activation-input:focus { border-color: var(--accent); outline: none; }
.btn-activate { background: var(--accent); color: white; padding: 12px 25px; border: none; border-radius: 6px; font-family: 'Montserrat'; font-weight: 700; font-size: 14px; cursor: pointer; width: 100%; transition: 0.3s; }
.btn-activate:hover { background: #c0392b; }
#loadingOverlay { display:none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(255,255,255,0.9); z-index: 9998; justify-content: center; align-items: center; flex-direction: column; font-weight: bold; color: #2c3e50;}

/* SUB NAVBAR (Menu kedua di bawah menu utama) */
.sub-navbar { background: #fff; padding: 0 20px; display: flex; box-shadow: 0 2px 5px rgba(0,0,0,0.05); margin-bottom: 20px; border-bottom: 1px solid #ddd; overflow-x: auto;}
.sub-nav-item { padding: 15px 20px; font-size: 13px; font-weight: 700; color: #555; cursor: pointer; border-bottom: 3px solid transparent; transition: 0.2s; white-space: nowrap;}
.sub-nav-item.active { color: #2980b9; border-bottom-color: #2980b9; }

.tab-content { display: none; padding: 10px 20px 100px 20px; }
.tab-content.active { display: block; }

/* KAD TETAPAN & HEADER MODUL */
.module-header { max-width: 1000px; margin: 0 auto 20px; }
.module-title { font-size: 24px; font-weight: 800; color: #2c3e50; margin: 0 0 5px 0; }
.module-subtitle { font-size: 13px; color: #7f8c8d; margin: 0; }
.settings-card { background: white; padding: 30px; border-radius: 8px; box-shadow: 0 5px 15px rgba(0,0,0,0.05); margin: 0 auto 20px auto; }
.settings-card h3 { margin-top: 0; border-bottom: 1px solid #eee; padding-bottom: 15px; color: #2c3e50;}

/* BUTANG KHUSUS TETAPAN */
.btn-new { background: #2ecc71; color: white; }
.btn-add { background: #ecf0f1; color: #333; }
.btn-save { background: #9b59b6; color: white; }
.btn-history { background: #3498db; color: white; }
.btn-danger-outline { background: transparent; border: 2px solid #e74c3c; color: #e74c3c; font-weight: bold; width: 100%; padding: 15px; height: auto; font-size: 14px; margin-top: 15px;}
.btn-danger-outline:hover { background: #e74c3c; color: white; }
.custom-select { padding: 0 10px; border-radius: 4px; border: 1px solid #ddd; font-family: 'Montserrat'; font-weight: 600; font-size: 12px; height: 36px; outline: none; background: white; color: #333; cursor: pointer; flex-shrink: 0; }

/* MODAL EDIT COA */
.edit-coa-btn { background: #f39c12; color: white; font-size: 12px; font-weight: bold; padding: 5px 12px; height: auto; }
.coa-no, .coa-name { font-weight: 500 !important; font-size: 13px !important; }
.coa-name { text-align: left !important; }

/* NAV LOGOUT BUTTON */
.nav-right-controls { margin-left: auto; display: flex; align-items: center; padding-right: 10px; }

/* =====================================
   MOBILE RESPONSIVE (DASHBOARD SAHAJA)
   ===================================== */
@media screen and (max-width: 768px) {
    .sub-navbar { padding: 5px 10px; flex-wrap: nowrap; overflow-x: auto; }
    .sub-nav-item { font-size: 13px; padding: 12px 10px; flex: 0 0 auto; }
    
    div[style*="display: flex; gap: 20px;"], div[style*="display: flex; gap: 15px;"] { flex-direction: column !important; gap: 15px !important; }
    .settings-card { flex: none !important; min-width: 100% !important; width: 100% !important; box-sizing: border-box; }
    
    .module-title { font-size: 20px !important; }
    .module-subtitle { font-size: 11px !important; }
    .settings-card h3 { font-size: 14px !important; }
    .settings-card div[style*="font-size: 22px;"] { font-size: 18px !important; } 
    .settings-card h3[style*="font-size: 11px;"] { font-size: 10px !important; }
    
    .activation-input { font-size: 14px !important; }
    .edit-coa-btn { font-size: 11px; padding: 4px 8px; }
    .coa-edit-row { gap: 5px !important; }
    .coa-no { width: 25% !important; padding: 6px !important; }
    .coa-name { width: 60% !important; padding: 6px !important; }
    .btn-remove.coa-del-btn { width: 15% !important; padding: 6px !important; }
    
    #dash-outstanding-list td { font-size: 11px !important; padding: 8px 5px !important; line-height: 1.3; }

    .nav-right-controls { width: 100%; display: flex; justify-content: space-between; padding: 15px 15px 0 15px; margin-left: 0; border-top: 1px solid rgba(255,255,255,0.1); }
    .nav-item[data-i18n="nav_logout"] { border-left: none !important; padding-left: 0 !important; text-align: right; }
}