/* =====================================================================
   BARCEP PTM ASN — Application Stylesheet
   Tema: Kesehatan | Warna utama: Biru
   ===================================================================== */

:root {
	--barcep-primary: #0B5ED7;
	--barcep-primary-dark: #084298;
	--barcep-primary-light: #DFF7F7;
	--barcep-teal: #0FA3B1;
	--barcep-bg: #F4FAFC;
	--barcep-card-bg: #FFFFFF;
	--barcep-border: #D9EEF2;
	--barcep-text: #12355B;
	--barcep-text-muted: #64748B;
	--barcep-radius: 16px;
	--barcep-shadow: 0 4px 16px rgba(18, 53, 91, 0.06);
	--barcep-sidebar-width: 240px;
}

* {
	font-family: inherit;
}

body.barcep-body {
	background-color: var(--barcep-bg);
	color: var(--barcep-text);
}

a {
	text-decoration: none;
}

/* -------------------- Welcome Popup -------------------- */
.barcep-welcome-overlay {
	position: fixed;
	inset: 0;
	z-index: 2000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 22px;
	background: rgba(8, 35, 57, .56);
	backdrop-filter: blur(5px);
	-webkit-backdrop-filter: blur(5px);
	animation: barcepWelcomeFade .35s ease both;
}
.barcep-welcome-overlay.is-closing { animation: barcepWelcomeFadeOut .22s ease both; }
.barcep-welcome-modal {
	position: relative;
	width: min(620px, calc(100% - 24px));
	max-height: min(90vh, 680px);
	overflow: auto;
	padding: 28px 26px 24px;
	border: 1px solid rgba(15, 163, 177, .18);
	border-radius: 31px;
	background: linear-gradient(145deg, #fff 0%, #f8fdff 65%, #e7f9f6 100%);
	box-shadow: 0 24px 80px rgba(8, 35, 57, .28);
	animation: barcepWelcomeZoom .4s cubic-bezier(.2,.8,.2,1) both;
}
.barcep-welcome-close {
	position: absolute;
	top: 13px;
	right: 14px;
	width: 36px;
	height: 36px;
	border: 0;
	border-radius: 50%;
	background: #edf7f8;
	color: #31536d;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}
.barcep-welcome-close:hover, .barcep-welcome-close:focus-visible { background: #d7efee; color: #0b5ed7; }
.barcep-welcome-head { display: flex; align-items: center; justify-content: center; gap: 17px; padding: 0 28px; text-align: center; }
.barcep-welcome-logo { width: 105px; height: 78px; object-fit: contain; flex: 0 0 105px; }
.barcep-welcome-kicker { margin: 0 0 8px; color: #0fa3b1; font-size: 13px; font-weight: 800; letter-spacing: .14em; }
.barcep-welcome-modal h2 { margin: 0; color: #084298; font-size: clamp(1.8rem, 4vw, 2.35rem); line-height: 1.08; }
.barcep-welcome-modal h2 strong { color: #0b5ed7; }
.barcep-welcome-modal h2 strong .barcep-title-barcep { color: #0b5ed7; }
.barcep-welcome-modal h2 strong .barcep-title-ptm { color: #0f9f73; }
.barcep-welcome-work { display: inline-block; margin: 8px 0 0; padding: 5px 20px; border-radius: 999px; background: #dff7e9; color: #12875d; font-size: .92rem; font-weight: 700; }
.barcep-welcome-quote { margin: 20px 0 12px; color: #123b72; font-size: clamp(.78rem, 1.7vw, .98rem); line-height: 1.45; text-align: center; }
.barcep-welcome-quote > span { color: #16b878; font-size: 1.9em; font-weight: 800; line-height: 0; vertical-align: -.28em; margin: 0 5px; }
.barcep-welcome-quote-break { display: none; }
.barcep-welcome-divider { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 4px 0 17px; }
.barcep-welcome-divider span { display: block; width: 58px; height: 2px; background: #9fb2c9; }
.barcep-welcome-divider i { color: #16b878; font-size: 1.25rem; font-style: normal; }
.barcep-welcome-photo-wrap { overflow: hidden; border-radius: 18px; border: 1px solid #d8eef0; background: #e9f7f6; }
.barcep-welcome-photo { display: block; width: 100%; height: 205px; object-fit: cover; }
.barcep-welcome-html-photo { position: relative; height: 205px; overflow: hidden; color: #0b5870; background: linear-gradient(145deg, #dff8f5, #f5fdff 58%, #dceffb); }
.barcep-html-photo-title { position: relative; z-index: 3; padding: 12px 16px 0; color: #0b6f78; font-size: .72rem; font-weight: 800; letter-spacing: .04em; }
.barcep-html-photo-title i { color: #e11d48; margin-right: 4px; }
.barcep-html-photo-scene { position: absolute; inset: 32px 0 0; }
.barcep-html-photo-scene::before { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 58px; background: linear-gradient(180deg, rgba(255,255,255,0), #c5e9e7); }
.barcep-html-worker, .barcep-html-patient { position: absolute; bottom: 32px; width: 96px; height: 137px; }
.worker-left { left: 11%; }
.barcep-html-patient { right: 31%; bottom: 30px; transform: scale(.86); }
.worker-head, .patient-head { position: absolute; top: 0; left: 31px; width: 38px; height: 38px; border-radius: 50%; background: #f4c7a1; box-shadow: inset -6px -2px 0 rgba(151, 82, 57, .12); }
.worker-head::before { content: ''; position: absolute; top: -4px; left: 2px; width: 34px; height: 16px; border-radius: 50% 50% 35% 35%; background: #536b7a; }
.worker-body, .patient-body { position: absolute; left: 11px; top: 36px; width: 74px; height: 91px; border-radius: 22px 22px 8px 8px; background: #fff; border: 3px solid #0fa3b1; }
.worker-body::after { content: '✚'; position: absolute; top: 24px; left: 31px; color: #0fa3b1; font-size: 22px; }
.worker-arm, .patient-arm { position: absolute; top: 63px; width: 67px; height: 16px; border-radius: 12px; background: #f4c7a1; }
.worker-arm { right: -19px; transform: rotate(15deg); transform-origin: left center; }
.patient-head { background: #b77b5b; }
.patient-head::before { content: ''; position: absolute; top: -3px; left: 0; width: 38px; height: 17px; border-radius: 50%; background: #202f3a; }
.patient-body { border-color: #3b82c4; background: #eff6ff; }
.patient-arm { left: -31px; transform: rotate(-12deg); background: #f4c7a1; }
.barcep-html-table { position: absolute; left: 28%; bottom: 25px; width: 44%; height: 34px; border-radius: 8px; background: #c98f65; box-shadow: 0 9px 0 #a66c4d; }
.barcep-html-table::before { content: ''; position: absolute; left: 25%; right: 25%; top: -6px; height: 8px; border-radius: 5px; background: #e0a477; }
.barcep-html-table span { position: absolute; top: 33px; width: 7px; height: 37px; background: #915a43; }
.barcep-html-table span:first-child { left: 14px; transform: rotate(8deg); }.barcep-html-table span:last-child { right: 14px; transform: rotate(-8deg); }
.barcep-html-device { position: absolute; left: 48%; bottom: 60px; display: grid; place-items: center; width: 45px; height: 37px; border-radius: 6px; background: #fff; border: 2px solid #0fa3b1; color: #e11d48; box-shadow: 0 3px 8px rgba(8, 35, 57, .12); }
.barcep-html-device i { font-size: 14px; line-height: 1; }.barcep-html-device small { color: #31536d; font-size: 6px; font-weight: 800; }
.barcep-html-checklist { position: absolute; right: 5%; top: 10px; display: grid; gap: 2px; width: 145px; padding: 8px 10px; border-radius: 10px; background: rgba(255,255,255,.88); border: 1px solid #cbe7ea; box-shadow: 0 4px 12px rgba(8, 35, 57, .08); font-size: 9px; }
.barcep-html-checklist b { color: #084298; font-size: 10px; }.barcep-html-checklist span { color: #416576; }.barcep-html-checklist i { color: #16a34a; margin-right: 3px; }
.barcep-html-photo-note { position: absolute; z-index: 4; bottom: 6px; left: 0; right: 0; color: #5b7d88; text-align: center; font-size: 8px; }
.barcep-welcome-benefits { display: grid; grid-template-columns: repeat(5, 1fr); gap: 7px; margin: 0 0 14px; }
.barcep-welcome-benefits div { min-height: 91px; padding: 11px 4px 8px; border: 1px solid #dceef0; border-radius: 13px; background: rgba(255,255,255,.8); text-align: center; }
.barcep-welcome-benefits div:nth-child(1) { background: #fff0f3; }
.barcep-welcome-benefits div:nth-child(2) { background: #eaf6ff; }
.barcep-welcome-benefits div:nth-child(3) { background: #e9faf1; }
.barcep-welcome-benefits div:nth-child(4) { background: #fff8df; }
.barcep-welcome-benefits div:nth-child(5) { background: #f3efff; }
.barcep-welcome-benefits div:nth-child(1) span { color: #f1264f; }
.barcep-welcome-benefits div:nth-child(2) span { color: #087ee5; }
.barcep-welcome-benefits div:nth-child(3) span { color: #10a66d; }
.barcep-welcome-benefits div:nth-child(4) span { color: #f6a723; }
.barcep-welcome-benefits div:nth-child(5) span { color: #8061d8; }
.barcep-welcome-benefits span { display: block; margin-bottom: 6px; font-size: 1.65rem; line-height: 1; }
.barcep-welcome-benefits b, .barcep-welcome-benefits small { display: block; }
.barcep-welcome-benefits b { color: #084298; font-size: .72rem; }
.barcep-welcome-benefits small { color: #31536d; font-size: .6rem; line-height: 1.2; }
.barcep-welcome-slogans { display: grid; gap: 4px; margin: 0 0 15px; padding: 11px 8px 10px; border-radius: 14px; background: linear-gradient(100deg, #effaf2, #f4fcf8); color: #31536d; text-align: center; font-size: .65rem; }
.barcep-welcome-slogans strong { color: #12875d; font-size: 1.05rem; line-height: 1.12; font-style: italic; }
.barcep-welcome-slogans strong span { margin-right: 8px; font-style: normal; }
.barcep-welcome-start { display: flex; align-items: center; justify-content: center; gap: 9px; width: 100%; min-height: 48px; border: 0; border-radius: 999px; background: linear-gradient(100deg, #066be4, #04b875); color: #fff; font-size: 1.05rem; font-weight: 800; letter-spacing: .02em; box-shadow: 0 8px 17px rgba(11, 94, 215, .2); cursor: pointer; }
.barcep-welcome-start span { font-size: 1.65rem; line-height: 1; }
.barcep-welcome-start:hover, .barcep-welcome-start:focus-visible { filter: brightness(1.06); transform: translateY(-1px); }
@keyframes barcepWelcomeFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes barcepWelcomeFadeOut { from { opacity: 1; } to { opacity: 0; } }
@keyframes barcepWelcomeZoom { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: scale(1); } }
@media (max-width: 900px) {
	.barcep-welcome-modal { padding: 36px 28px 28px; }
	.barcep-welcome-head { gap: 20px; padding: 0 46px 0 0; }
	.barcep-welcome-logo { width: 180px; height: 110px; flex-basis: 180px; }
	.barcep-welcome-modal h2 { font-size: clamp(1.9rem, 5vw, 3.1rem); }
	.barcep-welcome-work { font-size: 1.08rem; }
	.barcep-welcome-benefits { gap: 10px; }
	.barcep-welcome-benefits div { min-height: 130px; padding: 17px 7px 12px; border-radius: 17px; }
	.barcep-welcome-benefits span { font-size: 2.25rem; }
	.barcep-welcome-benefits b { font-size: .95rem; }
	.barcep-welcome-benefits small { font-size: .78rem; }
	.barcep-welcome-slogans strong { font-size: 1.4rem; }
	.barcep-welcome-start { min-height: 62px; font-size: 1.25rem; }
}
@media (max-width: 600px) {
	.barcep-welcome-overlay { padding: 12px; }
	.barcep-welcome-modal { padding: 26px 18px 20px; border-radius: 21px; }
	.barcep-welcome-head { gap: 11px; padding: 0 31px 0 0; }
	.barcep-welcome-logo { width: 82px; height: 74px; flex-basis: 82px; }
	.barcep-welcome-kicker { font-size: 9px; }
	.barcep-welcome-modal h2 { font-size: 1.65rem; }
	.barcep-welcome-work { margin-top: 7px; padding: 5px 15px; font-size: .82rem; }
	.barcep-welcome-quote { margin: 20px 0 13px; font-size: .83rem; }
	.barcep-welcome-quote-break { display: block; }
	.barcep-welcome-divider { gap: 10px; margin-bottom: 16px; }
	.barcep-welcome-divider span { width: 58px; }
	.barcep-welcome-divider i { font-size: 1.35rem; }
	.barcep-welcome-photo, .barcep-welcome-html-photo { height: 145px; }
	.barcep-html-photo-title { padding: 7px 10px 0; font-size: .55rem; }
	.barcep-html-worker, .barcep-html-patient { transform: scale(.68); transform-origin: bottom center; }
	.worker-left { left: 4%; }.barcep-html-patient { right: 24%; }
	.barcep-html-checklist { right: 2%; top: 3px; width: 106px; padding: 5px 6px; font-size: 7px; }.barcep-html-checklist b { font-size: 7px; }
	.barcep-html-table { bottom: 17px; }.barcep-html-device { bottom: 39px; transform: scale(.75); }
	.barcep-html-photo-note { font-size: 6px; }
	.barcep-welcome-benefits { grid-template-columns: repeat(2, 1fr); gap: 6px; margin: 0 0 13px; }
	.barcep-welcome-benefits div:last-child { grid-column: span 2; }
	.barcep-welcome-benefits div { min-height: 87px; padding: 11px 4px 8px; border-radius: 13px; }
	.barcep-welcome-benefits span { margin-bottom: 5px; font-size: 1.45rem; }
	.barcep-welcome-benefits b { font-size: .72rem; }
	.barcep-welcome-benefits small { font-size: .62rem; }
	.barcep-welcome-slogans { margin-bottom: 16px; padding: 14px 8px 12px; font-size: .7rem; }
	.barcep-welcome-slogans strong { font-size: 1.05rem; }
	.barcep-welcome-start { min-height: 50px; font-size: 1.02rem; gap: 8px; }
	.barcep-welcome-start span { font-size: 1.7rem; }
}

/* -------------------- App Layout -------------------- */
.barcep-app-wrapper {
	display: flex;
	min-height: 100vh;
}

.barcep-main {
	flex: 1;
	display: flex;
	flex-direction: column;
	min-width: 0;
	margin-left: var(--barcep-sidebar-width);
}

.barcep-content {
	padding: 24px;
	flex: 1;
}

/* -------------------- BARCEP POSYANDU full width --------------------
   Hanya dipasang oleh layouts/main ketika controller Posyandu aktif.
   Override ini menghilangkan batas max-width dari view Posyandu tanpa
   mengubah container BARCEP ASN atau BARCEP UMUM. */
.barcep-posyandu-main,
.barcep-posyandu-content {
	width: 100%;
	max-width: none;
	min-width: 0;
}
.barcep-posyandu-content > .container,
.barcep-posyandu-content > .container-fluid,
.barcep-posyandu-content .container,
.barcep-posyandu-content .container-fluid {
	width: 100% !important;
	max-width: none !important;
	margin-left: 0 !important;
	margin-right: 0 !important;
	box-sizing: border-box;
}
.barcep-posyandu-content .table-responsive,
.barcep-posyandu-content table {
	width: 100%;
}
.barcep-posyandu-content .table-responsive {
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
}
.barcep-posyandu-content .row {
	--bs-gutter-x: 1rem;
}

/* -------------------- Sidebar & Logo -------------------- */
.barcep-sidebar {
	width: var(--barcep-sidebar-width);
	background: var(--barcep-card-bg);
	border-right: 1px solid var(--barcep-border);
	position: fixed;
	top: 0;
	left: 0;
	bottom: 0;
	display: flex;
	flex-direction: column;
	z-index: 1030;
	overflow-y: auto;
	overflow-x: hidden;
}

.logo-container {
	width: 100%;
	display: flex;
	justify-content: center;
	align-items: center;
	padding: 18px 16px 12px 16px;
	box-sizing: border-box;
	border-bottom: 1px solid #f0f2f5;
	position: relative;
	background: #FFFFFF;
}

.logo-container img {
	width: 130px;
	max-width: 100%;
	height: auto;
	object-fit: contain;
	display: block;
	filter: contrast(1.15) saturate(1.25);
	transform: rotate(0deg);
	margin: 0;
}

.logo-container .barcep-sidebar-close {
	position: absolute;
	top: 12px;
	right: 12px;
	background: transparent;
	border: none;
	cursor: pointer;
}

.barcep-sidebar-logo-fallback {
	display: flex;
	align-items: center;
	gap: 12px;
}

.barcep-sidebar-logo-icon {
	width: 42px;
	height: 42px;
	border-radius: 12px;
	background: linear-gradient(135deg, var(--barcep-primary), var(--barcep-primary-dark));
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.25rem;
	flex-shrink: 0;
}

.barcep-sidebar-brand-text .fw-bold {
	color: var(--barcep-primary-dark);
	line-height: 1.1;
	font-size: 1.05rem;
}

.barcep-sidebar-brand-text .small {
	color: var(--barcep-text-muted);
	letter-spacing: 0.06em;
	font-size: 0.7rem;
}

/* --- REVISI DIMULAI DI SINI --- */
.barcep-sidebar-nav {
	padding: 14px 12px;
	display: flex;
	flex-direction: column;
	gap: 2px;
	flex: 1 1 auto;
	min-height: 0;
	overflow-y: auto; /* Mencegah menu menabrak ilustrasi */
	-ms-overflow-style: none; /* IE and Edge */
	scrollbar-width: none; /* Firefox */
}

/* Menyembunyikan scrollbar pada menu navigasi */
.barcep-sidebar-nav::-webkit-scrollbar {
	display: none;
}
/* --- REVISI SELESAI --- */

.barcep-sidebar-link {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px 12px;
	border-radius: 10px;
	color: var(--barcep-text);
	font-size: 0.92rem;
	font-weight: 500;
	position: relative;
}

.barcep-sidebar-link i {
	font-size: 1.05rem;
	width: 20px;
	text-align: center;
	color: var(--barcep-text-muted);
}

.barcep-sidebar-link:not(.disabled):hover {
	background: var(--barcep-primary-light);
	color: var(--barcep-primary-dark);
}

.barcep-sidebar-link:not(.disabled):hover i {
	color: var(--barcep-primary-dark);
}

.barcep-sidebar-link.active {
	background: var(--barcep-primary);
	color: #fff;
}

.barcep-sidebar-link.active i {
	color: #fff;
}

.barcep-sidebar-link.disabled {
	color: #B4BAC6;
	cursor: not-allowed;
}

.barcep-sidebar-link.disabled i {
	color: #C7CCD6;
}

/* -------------------- Grup Menu / Folder (collapsible) -------------------- */
.barcep-sidebar-group {
	display: flex;
	flex-direction: column;
}

.barcep-sidebar-group-toggle {
	display: flex;
	align-items: center;
	gap: 12px;
	width: 100%;
	padding: 10px 12px;
	border: none;
	background: transparent;
	border-radius: 10px;
	color: var(--barcep-primary-dark);
	font-size: 0.92rem;
	font-weight: 600;
	text-align: left;
	cursor: pointer;
}

.barcep-sidebar-group-toggle i:first-child {
	font-size: 1.05rem;
	width: 20px;
	text-align: center;
	color: var(--barcep-teal);
}

.barcep-sidebar-group-toggle span {
	flex: 1 1 auto;
}

.barcep-sidebar-group-toggle:hover {
	background: var(--barcep-primary-light);
	color: var(--barcep-primary-dark);
}

.barcep-sidebar-group-toggle:hover i {
	color: var(--barcep-primary-dark);
}

.barcep-group-chevron {
	flex: 0 0 auto;
	font-size: 0.85rem !important;
	width: auto !important;
	transition: transform 0.2s ease;
}

.barcep-sidebar-group.open .barcep-group-chevron {
	transform: rotate(180deg);
}

.barcep-sidebar-group-items {
	display: flex;
	flex-direction: column;
	gap: 2px;
	padding: 4px 0 6px 20px;
}

.barcep-sidebar-sublink {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 8px 12px;
	border-radius: 8px;
	color: var(--barcep-primary-dark);
	font-size: 0.86rem;
	font-weight: 500;
	position: relative;
}

.barcep-sidebar-sublink i {
	font-size: 0.9rem;
	width: 16px;
	text-align: center;
	color: var(--barcep-teal);
}

.barcep-sidebar-sublink:not(.disabled):hover {
	background: var(--barcep-primary-light);
	color: var(--barcep-primary-dark);
}

.barcep-sidebar-sublink:not(.disabled):hover i {
	color: var(--barcep-primary-dark);
}

.barcep-sidebar-sublink.active {
	background: var(--barcep-primary);
	color: #fff;
}

.barcep-sidebar-sublink.active i {
	color: #fff;
}

.barcep-sidebar-sublink.disabled {
	color: #B4BAC6;
	cursor: not-allowed;
}

.barcep-sidebar-sublink.disabled i {
	color: #C7CCD6;
}

.barcep-soon-badge {
	margin-left: auto;
	font-size: 0.62rem;
	background: #EEF1F6;
	color: #9AA1AF;
	padding: 2px 7px;
	border-radius: 999px;
	white-space: nowrap;
}

.barcep-sidebar-divider {
	height: 1px;
	background: var(--barcep-border);
	margin: 10px 4px;
}

.barcep-logout-link {
	color: #DC2626;
}

.barcep-logout-link i {
	color: #DC2626;
}

.barcep-logout-link:hover {
	background: #FEF2F2;
	color: #B91C1C;
}

.barcep-sidebar-overlay {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(15, 23, 42, 0.45);
	z-index: 1020;
}

/* -------------------- Ilustrasi Sidebar (DIPERBARUI) -------------------- */
.barcep-sidebar-illustration {
    margin-top: auto;
    margin-bottom: 12px;
    padding: 0 16px;
    text-align: center;
    pointer-events: none;
    flex-shrink: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.barcep-sidebar-illustration img {
    width: 100%;
    max-width: 160px; /* Gambar dibuat besar penuh */
    max-height: 140px;
    height: auto;
    display: block;
    object-fit: contain;
    margin: 0 auto;
}

@media (max-height: 700px) {
	.barcep-sidebar-illustration { display: none; }
}

@media (max-width: 991.98px) {
	.barcep-sidebar-illustration {
		display: none;
	}
}

/* -------------------- Topbar -------------------- */
.barcep-topbar {
	background: var(--barcep-card-bg);
	border-bottom: 1px solid var(--barcep-border);
	padding: 14px 24px;
	position: sticky;
	top: 0;
	z-index: 1010;
}

.barcep-user-btn {
	background: transparent;
	border: 1px solid var(--barcep-border);
	border-radius: 999px;
	padding: 6px 12px 6px 6px;
}

.barcep-avatar {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: var(--barcep-primary);
	color: #fff;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-weight: 700;
	font-size: 0.95rem;
}

.barcep-avatar-lg {
	width: 64px;
	height: 64px;
	font-size: 1.6rem;
}

/* -------------------- Cards -------------------- */
.barcep-card {
	background: var(--barcep-card-bg);
	border: 1px solid var(--barcep-border);
	border-radius: var(--barcep-radius);
	box-shadow: var(--barcep-shadow);
	padding: 24px;
}

.barcep-welcome-card {
	background: linear-gradient(135deg, #FFFFFF 0%, #F4FAFC 58%, #DFF7F7 100%);
}

@media (min-width: 992px) {
	.barcep-welcome-card {
		position: sticky;
		top: 85px; 
		z-index: 1000; 
	}
}

.barcep-badge-program {
	background: var(--barcep-primary-light);
	color: var(--barcep-primary-dark);
	font-weight: 600;
	font-size: 0.72rem;
	padding: 6px 12px;
	border-radius: 999px;
}

.barcep-badge-role {
	background: var(--barcep-primary-light);
	color: var(--barcep-primary-dark);
	font-weight: 600;
	padding: 6px 12px;
	border-radius: 999px;
}

/* -------------------- Flow -------------------- */
.barcep-flow {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	justify-content: flex-end;
}

.barcep-flow-step {
	background: #fff;
	border: 1px solid var(--barcep-border);
	border-radius: 999px;
	padding: 6px 14px;
	font-size: 0.78rem;
	font-weight: 600;
	color: var(--barcep-primary-dark);
	white-space: nowrap;
}

.barcep-flow-arrow {
	color: #C7CCD6;
	font-size: 0.85rem;
}

/* -------------------- KPI -------------------- */
.barcep-kpi-card {
	padding: 20px;
	text-align: left;
}

.barcep-kpi-icon {
	width: 42px;
	height: 42px;
	border-radius: 12px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.15rem;
	margin-bottom: 12px;
}

.barcep-kpi-value {
	font-size: 1.6rem;
	font-weight: 800;
	color: var(--barcep-text);
	line-height: 1;
}

.barcep-kpi-label {
	font-size: 0.8rem;
	color: var(--barcep-text-muted);
	margin-top: 4px;
}

/* -------------------- Footer -------------------- */
.barcep-footer {
	padding: 16px 24px 24px;
}

/* -------------------- Login Page (Split Screen) -------------------- */
.barcep-login-left {
    position: relative;
    overflow: hidden;
}

.barcep-login-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(8, 66, 152, 0.85) 0%, rgba(15, 163, 177, 0.4) 100%);
    z-index: 0;
}

.input-group-text {
    border-color: #dee2e6;
}

.form-control:focus {
    box-shadow: none;
    border-color: #dee2e6;
}

.btn-success {
    background-color: #19693B;
    border-color: #19693B;
}

.btn-success:hover {
    background-color: #124A29;
    border-color: #124A29;
}

.text-success {
    color: #19693B !important;
}

/* -------------------- Responsive -------------------- */
@media (max-width: 991.98px) {
	.barcep-sidebar {
		transform: translateX(-100%);
		transition: transform 0.25s ease;
		box-shadow: 0 0 30px rgba(0,0,0,0.15);
	}

	.barcep-sidebar.show {
		transform: translateX(0);
	}

	.barcep-main {
		margin-left: 0;
	}

	.barcep-sidebar-overlay.show {
		display: block;
	}

	.barcep-flow {
		justify-content: flex-start;
	}
}

@media (max-width: 575.98px) {
	.barcep-content {
		padding: 16px;
	}

	.barcep-topbar {
		padding: 12px 16px;
	}

	.barcep-login-card {
		padding: 28px 20px;
	}
}

/* =====================================================================
   BARCEP ASN — responsive field use
   Dibatasi pada konten ASN agar Posyandu dan BARCEP Umum tidak terpengaruh.
   ===================================================================== */
.barcep-asn-content,
.barcep-asn-content .container-fluid,
.barcep-asn-content .card,
.barcep-asn-content img,
.barcep-asn-content canvas,
.barcep-asn-content svg {
	max-width: 100%;
}

.barcep-asn-content .container-fluid {
	min-width: 0;
}

.barcep-asn-content .table-responsive {
	-webkit-overflow-scrolling: touch;
	border-radius: 10px;
}

@media (max-width: 767.98px) {
	.barcep-content.barcep-asn-content {
		padding: 12px;
	}

	.barcep-asn-content .container-fluid {
		padding-left: 0;
		padding-right: 0;
	}

	/* Toolbar halaman boleh turun baris; tombol tidak saling berhimpitan. */
	.barcep-asn-content > .container-fluid > .d-flex {
		flex-wrap: wrap;
		gap: 12px !important;
	}

	.barcep-asn-content > .container-fluid > .d-flex > .d-flex {
		width: 100%;
		flex-wrap: wrap;
	}

	/* 16px mencegah Safari iPhone melakukan zoom otomatis saat input. */
	.barcep-asn-content input.form-control,
	.barcep-asn-content select.form-select,
	.barcep-asn-content textarea.form-control,
	.barcep-asn-content .form-control,
	.barcep-asn-content .form-select {
		font-size: 16px !important;
		min-height: 44px;
	}

	.barcep-asn-content textarea.form-control {
		min-height: 96px;
	}

	.barcep-asn-content .btn,
	.barcep-asn-content button,
	.barcep-asn-content input[type="submit"],
	.barcep-asn-content input[type="button"] {
		min-height: 44px;
	}

	.barcep-asn-content .btn-group,
	.barcep-asn-content .btn-toolbar {
		flex-wrap: wrap;
		gap: 8px;
	}

	.barcep-asn-content .card-body {
		padding: 16px;
	}

	.barcep-asn-content .table {
		font-size: 0.875rem;
	}

	.barcep-asn-content .table th,
	.barcep-asn-content .table td {
		white-space: nowrap;
	}
}

@media (max-width: 479.98px) {
	.barcep-asn-content > .container-fluid > .d-flex > .d-flex > .btn,
	.barcep-asn-content > .container-fluid > .d-flex > .btn {
		flex: 1 1 100%;
	}

	.barcep-asn-content .card-header,
	.barcep-asn-content .card-body {
		padding: 14px;
	}

	.barcep-asn-content h1,
	.barcep-asn-content h2,
	.barcep-asn-content h3 {
		font-size: clamp(1.25rem, 6vw, 1.6rem);
	}
}

/* =====================================================================
   BARCEP — Shared visual theme (ASN, UMUM, POSYANDU)
   Presentational only: no route, data, form name, or interaction changes.
   ===================================================================== */
body.barcep-body {
	background: var(--barcep-bg);
	color: var(--barcep-text);
}

body.barcep-body h1,
body.barcep-body h2,
body.barcep-body h3,
body.barcep-body h4,
body.barcep-body h5,
body.barcep-body h6,
body.barcep-body .h1,
body.barcep-body .h2,
body.barcep-body .h3,
body.barcep-body .h4,
body.barcep-body .h5,
body.barcep-body .h6 {
	color: var(--barcep-primary-dark);
}

body.barcep-body .card,
body.barcep-body .barcep-card,
body.barcep-body .barcep-panel,
body.barcep-body .barcep-filter-card,
body.barcep-body .barcep-kpi-card {
	background-color: var(--barcep-card-bg);
	border: 1px solid var(--barcep-border);
	border-radius: var(--barcep-radius);
	box-shadow: var(--barcep-shadow);
}

body.barcep-body .card-header,
body.barcep-body .card-footer {
	background-color: var(--barcep-card-bg);
	border-color: var(--barcep-border);
}

body.barcep-body .form-control,
body.barcep-body .form-select,
body.barcep-body .input-group-text {
	background-color: #fff;
	border-color: var(--barcep-border);
	border-radius: 10px;
	color: var(--barcep-text);
}

body.barcep-body .form-control:focus,
body.barcep-body .form-select:focus {
	border-color: var(--barcep-primary);
	box-shadow: 0 0 0 3px rgba(11, 94, 215, .12);
}

body.barcep-body .form-label,
body.barcep-body label {
	color: var(--barcep-primary-dark);
}

body.barcep-body .text-muted {
	color: var(--barcep-text-muted) !important;
}

body.barcep-body .btn {
	border-radius: 9px;
	font-weight: 600;
}

body.barcep-body .btn-primary {
	background-color: var(--barcep-primary);
	border-color: var(--barcep-primary);
	color: #fff;
}

body.barcep-body .btn-primary:hover,
body.barcep-body .btn-primary:focus,
body.barcep-body .btn-primary:active {
	background-color: var(--barcep-primary-dark);
	border-color: var(--barcep-primary-dark);
	color: #fff;
}

body.barcep-body .btn-info,
body.barcep-body .btn-secondary {
	background-color: var(--barcep-teal);
	border-color: var(--barcep-teal);
	color: #fff;
}

body.barcep-body .btn-info:hover,
body.barcep-body .btn-info:focus,
body.barcep-body .btn-secondary:hover,
body.barcep-body .btn-secondary:focus {
	background-color: var(--barcep-primary-dark);
	border-color: var(--barcep-primary-dark);
	color: #fff;
}

body.barcep-body .btn-outline-primary {
	border-color: var(--barcep-primary);
	color: var(--barcep-primary);
}

body.barcep-body .btn-outline-primary:hover,
body.barcep-body .btn-outline-primary:focus {
	background-color: var(--barcep-primary);
	border-color: var(--barcep-primary);
	color: #fff;
}

body.barcep-body .table {
	--bs-table-border-color: var(--barcep-border);
	color: var(--barcep-text);
	border-color: var(--barcep-border);
}

body.barcep-body .table > :not(caption) > * > * {
	border-bottom-color: var(--barcep-border);
}

body.barcep-body .table thead th,
body.barcep-body .table thead td {
	background-color: #EEF7FA;
	color: var(--barcep-primary-dark);
	font-weight: 700;
	vertical-align: middle;
}

body.barcep-body .table tbody tr:hover > * {
	background-color: var(--barcep-bg);
}

body.barcep-body .dropdown-menu {
	border: 1px solid var(--barcep-border);
	border-radius: 10px;
	box-shadow: 0 .5rem 1.25rem rgba(18, 53, 91, .12);
}

body.barcep-body .dropdown-item {
	color: var(--barcep-text);
	border-radius: 7px;
}

body.barcep-body .dropdown-item:hover,
body.barcep-body .dropdown-item:focus {
	background-color: var(--barcep-primary-light);
	color: var(--barcep-primary-dark);
}

/* The one-button action pattern used by list pages keeps its existing JS. */
body.barcep-body .barcep-action-toggle,
body.barcep-body .pendaftaran-action-toggle {
	background-color: var(--barcep-primary);
	border-color: var(--barcep-primary);
	color: #fff;
}

body.barcep-body .barcep-action-toggle:hover,
body.barcep-body .barcep-action-toggle:focus,
body.barcep-body .pendaftaran-action-toggle:hover,
body.barcep-body .pendaftaran-action-toggle:focus {
	background-color: var(--barcep-primary-dark);
	border-color: var(--barcep-primary-dark);
	color: #fff;
}

body.barcep-body .barcep-action-menu,
body.barcep-body .pendaftaran-action-menu {
	border-color: var(--barcep-border);
	box-shadow: 0 .5rem 1.25rem rgba(18, 53, 91, .14);
}

body.barcep-body .barcep-action-menu .dropdown-item:hover,
body.barcep-body .barcep-action-menu .dropdown-item:focus,
body.barcep-body .pendaftaran-action-menu .dropdown-item:hover,
body.barcep-body .pendaftaran-action-menu .dropdown-item:focus {
	background-color: var(--barcep-primary-light);
}

body.barcep-body .progress {
	background-color: #E6F1F5;
}

body.barcep-body .progress-bar {
	background: linear-gradient(90deg, var(--barcep-primary), var(--barcep-teal));
}

@media (max-width: 767.98px) {
	body.barcep-body .card,
	body.barcep-body .barcep-card,
	body.barcep-body .barcep-panel,
	body.barcep-body .barcep-filter-card {
		border-radius: 14px;
	}

	body.barcep-body .table-responsive {
		border-radius: 10px;
		-webkit-overflow-scrolling: touch;
	}
}
