/* AFP Wakaf Bas — gaya kempen. */
.afp-wb {
	/* Palet laman farispetra.org.my (sama dengan halaman Kempen & Derma). */
	--wb-primary: #1D4ED8;
	--wb-primary-2: #3B82F6;
	--wb-accent: #FFC220;
	--wb-heading: #0B1E5B;
	--wb-text: #1F2937;
	--wb-muted: #6B7280;
	--wb-soft: #EFF4FF;
	--wb-white: #ffffff;
	--wb-border: #E5E7EB;
	--wb-radius: 16px;
	color: var(--wb-text);
	font-family: Inter, system-ui, sans-serif;
	margin: 0 0 1.5em;
}
.afp-wb h4, .afp-wb-raised, .afp-wb-kpis strong { font-family: Poppins, sans-serif; }
.afp-wb *, .afp-wb *::before, .afp-wb *::after { box-sizing: border-box; }
.afp-wb h4 { color: var(--wb-heading); margin: 0 0 .75em; font-size: 1.05em; }

.afp-wb-card {
	background: var(--wb-white);
	border: 1px solid var(--wb-border);
	border-radius: var(--wb-radius);
	padding: 1.25em 1.4em;
	display: block;
	text-decoration: none;
	color: inherit;
}
.afp-wb-empty { color: var(--wb-muted, #6B7280); font-style: italic; margin: .5em 0; }
.afp-wb-note { font-size: .875em; color: var(--wb-muted, #6B7280); margin: .75em 0 0; }

/* Tracker */
.afp-wb-raised { font-size: clamp(2rem, 5vw, 3rem); font-weight: 800; color: var(--wb-heading); line-height: 1.1; }
.afp-wb-sub { margin: .25em 0 1em; }
.afp-wb-bar { height: 12px; background: var(--wb-soft); border-radius: 99px; overflow: hidden; }
.afp-wb-bar > span { display: block; height: 100%; background: linear-gradient(90deg, var(--wb-primary), var(--wb-primary-2)); border-radius: inherit; transition: width .8s ease; }
.afp-wb-row { display: flex; justify-content: space-between; gap: 1em; margin-top: .6em; font-size: .95em; }
.afp-wb-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: .75em; margin-top: 1.25em; }
.afp-wb-kpis div { background: var(--wb-soft); border-radius: 10px; padding: .75em; text-align: center; }
.afp-wb-kpis strong { display: block; font-size: 1.4em; color: var(--wb-heading); }
.afp-wb-kpis span { font-size: .8em; }
.afp-wb-updated { font-size: .8em; color: var(--wb-muted, #6B7280); margin: 1em 0 0; }

/* Kerusi */
.afp-wb-legend { display: flex; flex-wrap: wrap; gap: 1.25em; list-style: none; margin: 0 0 1em; padding: 0; font-size: .9em; }
.afp-wb-legend i { display: inline-block; width: 14px; height: 14px; border-radius: 4px; margin-right: .4em; vertical-align: -2px; }
.afp-wb-seats { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 8px; }
.afp-wb-seat { position: relative; aspect-ratio: 1; border-radius: 10px 10px 6px 6px; display: flex; align-items: center; justify-content: center; overflow: hidden; text-decoration: none; font-weight: 700; border: 2px solid var(--wb-border); }
.afp-wb-seat .n { position: relative; z-index: 1; }
.afp-wb-seat .fill { position: absolute; left: 0; right: 0; bottom: 0; background: rgba(255, 194, 32, .45); }
.afp-wb .is-penuh { background: var(--wb-primary); border-color: var(--wb-primary); color: var(--wb-white); }
.afp-wb .is-kutipan { background: var(--wb-white); border-color: var(--wb-accent); color: var(--wb-heading); }
.afp-wb .is-kosong { background: var(--wb-soft); color: var(--wb-muted, #6B7280); }
a.afp-wb-seat:hover, a.afp-wb-seat:focus-visible { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,.1); outline: none; }

/* Feed & Wall */
.afp-wb-feed-list, .afp-wb-wall-list, .afp-wb-hof-grid ol { list-style: none; margin: 0; padding: 0; }
.afp-wb-feed-list li { display: grid; grid-template-columns: 1fr auto; gap: 0 1em; padding: .7em 0; border-bottom: 1px solid var(--wb-border); }
.afp-wb-feed-list .amt { font-weight: 700; color: var(--wb-heading); }
.afp-wb-feed-list .when { grid-column: 1 / -1; font-size: .8em; color: var(--wb-muted, #6B7280); }
.afp-wb-tabs { display: flex; flex-wrap: wrap; gap: .5em; margin-bottom: 1em; }
.afp-wb-tabs button { border: 1px solid var(--wb-border); background: var(--wb-white); color: var(--wb-text); border-radius: 99px; padding: .4em 1em; cursor: pointer; font: inherit; }
.afp-wb-tabs button[aria-selected="true"] { background: var(--wb-primary); border-color: var(--wb-primary); color: var(--wb-white); }
.afp-wb-wall-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: .75em; }
.afp-wb-wall-list li { background: var(--wb-soft); border-radius: 10px; padding: .8em 1em; }
.afp-wb-wall-list li[hidden] { display: none; }
.afp-wb-wall-list strong { display: block; color: var(--wb-heading); }
.afp-wb-wall-list span { font-size: .85em; }

/* Hall of Fame, statistik, kemas kini, bayaran */
.afp-wb-hof-grid, .afp-wb-stats-grid, .afp-wb-updates-list, .afp-wb-pay-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1em; }
.afp-wb-hof-grid li { display: flex; justify-content: space-between; gap: 1em; padding: .45em 0; border-bottom: 1px dashed var(--wb-border); counter-increment: hof; }
.afp-wb-hof-grid li::before { content: counter(hof) "."; color: var(--wb-accent); font-weight: 700; margin-right: .4em; }
.afp-wb-hof-grid li span { flex: 1; }
.afp-wb-hof-grid ol { counter-reset: hof; }
.afp-wb-hbar { margin-bottom: .9em; }
.afp-wb-hbar .lbl { display: flex; justify-content: space-between; font-size: .9em; margin-bottom: .3em; }
.afp-wb-bar > span.c-syarikat { background: var(--wb-accent); }
.afp-wb-bar > span.c-individu { background: var(--wb-heading); }
.afp-wb-bar > span.c-lain { background: #a0aec0; }
.afp-wb-mini { display: flex; align-items: flex-end; gap: 3px; height: 90px; }
.afp-wb-mini span { flex: 1; height: 100%; background: var(--wb-soft); border-radius: 3px; display: flex; align-items: flex-end; }
.afp-wb-mini i { display: block; width: 100%; background: var(--wb-primary); border-radius: 3px; }
.afp-wb-updates-list time { font-size: .8em; color: var(--wb-accent); font-weight: 700; }
.afp-wb-updates-list h4 { margin: .3em 0; }
.afp-wb-updates-list p { margin: 0; font-size: .9em; }
.afp-wb-updates-list a:hover { border-color: var(--wb-primary); }
.afp-wb-pay-online { border: 2px solid var(--wb-primary); position: relative; }
.afp-wb-badge { position: absolute; top: -.75em; right: 1em; background: var(--wb-accent); color: var(--wb-heading); font-size: .75em; font-weight: 700; padding: .2em .7em; border-radius: 99px; }
.afp-wb-pay-grid dl { display: grid; grid-template-columns: auto 1fr; gap: .35em 1em; margin: 0 0 1em; }
.afp-wb-pay-grid dt { color: var(--wb-muted, #6B7280); font-size: .9em; }
.afp-wb-pay-grid dd { margin: 0; }
.afp-wb-qr { max-width: 180px; border-radius: 10px; margin: 0 0 1em; display: block; }
.afp-wb-btn, .afp-wb-share, .afp-wb-copy { display: inline-block; background: var(--wb-accent); color: var(--wb-heading) !important; border: 0; border-radius: 99px; padding: .7em 1.6em; font-weight: 700; text-decoration: none; cursor: pointer; font: inherit; font-weight: 700; }
.afp-wb-btn.is-ghost, .afp-wb-share { background: transparent; color: var(--wb-primary) !important; border: 2px solid var(--wb-primary); }
.afp-wb-share { margin-top: 1em; }
.afp-wb-copy { padding: .2em .8em; font-size: .8em; margin-left: .5em; background: var(--wb-primary); color: var(--wb-white) !important; }

/* Medan di halaman produk */
.afp-wb-presets { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; margin: 0 0 1em; }
.afp-wb-presets[hidden] { display: none; }
.afp-wb-presets button { border: 2px solid #1D4ED8; background: #fff; color: #1D4ED8; border-radius: 10px; padding: .6em .4em; font-weight: 700; cursor: pointer; line-height: 1.2; }
.afp-wb-presets button small { display: block; font-weight: 400; font-size: .75em; }
.afp-wb-presets button[aria-pressed="true"] { background: #1D4ED8; color: #fff; }
.afp-wb-fields { margin: 1em 0 1.25em; padding: 1em 1.2em; border: 1px solid #E5E7EB; border-radius: 12px; }
.afp-wb-field { margin: 0 0 .9em; }
.afp-wb-field label { display: block; font-weight: 600; margin-bottom: .3em; }
.afp-wb-field input[type="text"], .afp-wb-field select { width: 100%; }
.afp-wb-field small { color: var(--wb-muted, #6B7280); }
.afp-wb-consent label { font-weight: 400; }
.afp-wb-field[hidden] { display: none; }

/* Kemasan dalam tema Astra */
.afp-wb a { text-decoration: none !important; }
.afp-wb ul, .afp-wb ol { margin-left: 0 !important; padding-left: 0; }
.afp-wb-legend i.is-kutipan { background: #fff; border: 2px solid var(--wb-accent); }
.afp-wb-legend i.is-kosong { background: var(--wb-soft); border: 1px solid var(--wb-border); }
.afp-wb-wall-list li { background: #fff; border: 1px solid var(--wb-border); }

/* Blok halaman kempen: tambah kelas pada blok Kumpulan (Advanced → Additional CSS class). */
.afp-wb-faq details { background: #fff; border: 1px solid #E5E7EB; border-radius: 14px; padding: 16px 20px; margin: 0 0 12px; }
.afp-wb-faq details[open] { border-color: #1D4ED8; }
.afp-wb-faq summary { font-weight: 600; color: #0B1E5B; cursor: pointer; }
.afp-wb-faq details > :not(summary) { margin: 12px 0 0; }
.afp-wb-timeline ol { list-style: none; counter-reset: afptl; padding-left: 0; }
.afp-wb-timeline li { position: relative; padding: 4px 0 22px 52px; counter-increment: afptl; }
.afp-wb-timeline li::before { content: counter(afptl); position: absolute; left: 0; top: 0; width: 34px; height: 34px; border-radius: 50%; background: #1D4ED8; color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.afp-wb-timeline li::after { content: ""; position: absolute; left: 16px; top: 38px; bottom: 4px; width: 2px; background: #E5E7EB; }
.afp-wb-timeline li:last-child::after { display: none; }
/* Item senarai: kelas is-now (fasa semasa, emas) atau is-next (akan datang, kelabu). Tanpa kelas = selesai. */
.afp-wb-timeline li.is-now::before { background: #FFC220; color: #0B1E5B; }
.afp-wb-timeline li.is-next::before { background: #E5E7EB; color: #6B7280; }
