/*
Theme Name:   Astra Child
Theme URI:    https://wpastra.com/
Description:  Child theme untuk Astra. Letakkan kustomisasi CSS dan PHP di sini agar aman saat Astra diperbarui.
Author:       Lazis RJ
Template:     astra
Version:      1.2.0
Requires at least: 5.3
Requires PHP: 7.4
License:      GNU General Public License v2 or later
License URI:  https://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  astra-child
*/

/* ==========================================================================
   Kustomisasi LAZIS RJ
   Dipindahkan dari Customizer > Additional CSS tema Astra (post ID 2196).
   ========================================================================== */


/* --------------------------------------------------------------------------
   1. Header sticky
   -------------------------------------------------------------------------- */

#masthead {
	position: -webkit-sticky;
	position: sticky;
	top: 0;
	z-index: 999;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* Menu utama: transisi warna halus, dan garis bawah emas juga pada menu aktif.
   Garis hover berasal dari Astra (Menu Hover Style: Underline); Astra tidak
   menampilkannya untuk menu aktif, jadi ditambahkan di sini. */
.ast-builder-menu-1 .main-header-menu > .menu-item > .menu-link {
	transition: color 0.2s ease;
}

.ast-desktop .ast-builder-menu-1 .ast-menu-hover-style-underline > .current-menu-item > .menu-link:before,
.ast-desktop .ast-builder-menu-1 .ast-menu-hover-style-underline > .current-menu-ancestor > .menu-link:before {
	width: calc(100% - 1.2em);
	background-color: currentColor;
	transform: scale(1, 1) translate(50%, 0);
}


/* --------------------------------------------------------------------------
   2. Tagline situs (mobile)
   -------------------------------------------------------------------------- */

@media (max-width: 768px) {
	.site-description,
	.ast-site-title-wrap .site-description {
		font-size: 9px;
		line-height: 1.3;
		margin-top: 4px;
	}
}


/* --------------------------------------------------------------------------
   3. Halaman depan: sembunyikan judul "Beranda"
   -------------------------------------------------------------------------- */

.home .entry-title,
.home .ast-single-post .entry-title {
	display: none;
}


/* --------------------------------------------------------------------------
   4. Tombol WhatsApp melayang
   Markup berasal dari snippet WPCode "Tombol WhatsApp Melayang" (ID 2211).
   -------------------------------------------------------------------------- */

.wa-float {
	position: fixed;
	bottom: 20px;
	right: 20px;
	width: 56px;
	height: 56px;
	background-color: #25D366;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
	z-index: 9999;
	transition: transform 0.2s ease;
}

.wa-float:hover {
	transform: scale(1.1);
}

.wa-float svg {
	width: 32px;
	height: 32px;
}


/* --------------------------------------------------------------------------
   5. Footer
   Markup berasal dari Astra Footer Builder > elemen HTML 1.
   -------------------------------------------------------------------------- */

/* 5a. Wadah Astra (baris Above Footer): hilangkan pita abu-abu #eeeeee dan
   padding 20px/35px dari Customizer agar footer menyambung selebar body.
   Selector setara dengan CSS dinamis Astra; style.css dimuat setelahnya. */
.site-footer {
	background-color: #ffffff;
}

.site-above-footer-wrap[data-section="section-above-footer-builder"] {
	background-color: #ffffff;
	padding-top: 0;
	padding-bottom: 0;
	min-height: 0;
}

.site-above-footer-wrap[data-section="section-above-footer-builder"] .ast-builder-grid-row {
	padding-left: 0;
	padding-right: 0;
}

/* Astra memberi margin-bottom 10px per mode stack (desktop/tablet/mobile) dengan
   selector (0,4,0), jadi disamakan persis agar menang lewat urutan. */
.site-above-footer-wrap[data-section="section-above-footer-builder"].ast-footer-row-stack .site-footer-section,
.site-above-footer-wrap[data-section="section-above-footer-builder"].ast-footer-row-tablet-stack .site-footer-section,
.site-above-footer-wrap[data-section="section-above-footer-builder"].ast-footer-row-mobile-stack .site-footer-section {
	margin-bottom: 0;
}

/* 5b. Kerangka & kolom. Pembatas dengan body: garis tipis + bayangan halus. */
.lrj-footer {
	background: #ffffff;
	color: #243029;
	padding: 48px 24px 24px;
	border-top: 1px solid #E5EAE6;
	box-shadow: 0 -6px 18px rgba(19, 61, 40, 0.05);
}

.lrj-footer-inner {
	max-width: 1140px;
	margin: 0 auto;
	display: flex;
	flex-wrap: wrap;
	gap: 32px;
}

.lrj-footer .lrj-col {
	flex: 1;
	min-width: 150px;
}

.lrj-footer .lrj-col-1 {
	flex: 1.6;
	min-width: 240px;
}

.lrj-footer .lrj-col h4 {
	font-size: 16px;
	color: #1F5C3A;
	margin: 0 0 16px;
	font-weight: 700;
}

/* 5c. Logo & deskripsi */
.lrj-logo {
	max-width: 190px;
	height: auto;
	margin-bottom: 16px;
	display: block;
}

.lrj-desc {
	font-size: 14px;
	line-height: 1.7;
	color: #4a5750;
	margin: 0;
}

/* 5d. Kontak */
.lrj-contact-item {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	margin-bottom: 14px;
	font-size: 14px;
	line-height: 1.6;
	color: #4a5750;
}

.lrj-contact-item svg {
	flex: 0 0 18px;
	width: 18px;
	height: 18px;
	fill: #E0A11B;
	margin-top: 2px;
}

.lrj-contact-item i {
	flex: 0 0 18px;
	width: 18px;
	font-size: 16px;
	color: #E0A11B;
	margin-top: 3px;
	text-align: center;
}

.lrj-contact-item a {
	color: #4a5750;
	text-decoration: none;
}

.lrj-contact-item a:hover {
	color: #E0A11B;
}

/* 5e. Tautan */
.lrj-links {
	list-style: none;
	padding: 0;
	margin: 0;
}

.lrj-links li {
	margin-bottom: 12px;
}

.lrj-links a {
	color: #4a5750;
	text-decoration: none;
	font-size: 14px;
}

.lrj-links a:hover {
	color: #E0A11B;
}

/* 5f. Media sosial */
.lrj-social {
	display: flex;
	gap: 12px;
	flex-wrap: wrap;
}

.lrj-social a {
	width: 40px;
	height: 40px;
	border-radius: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #1F5C3A;
	transition: transform 0.2s ease, background 0.2s ease;
}

.lrj-social a:hover {
	transform: translateY(-3px);
	background: #E0A11B;
}

/* Ikon digambar lewat CSS mask karena wp_kses_post di HTML component Astra
   membuang <svg>. Tiap <a> dibedakan lewat aria-label. */
.lrj-social a::before {
	content: "";
	display: block;
	width: 18px;
	height: 18px;
	background-color: #ffffff;
	-webkit-mask: var(--lrj-icon) center / contain no-repeat;
	mask: var(--lrj-icon) center / contain no-repeat;
}

.lrj-social a[aria-label^="Facebook"]::before {
	--lrj-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 320 512'%3E%3Cpath d='M279.14 288l14.22-92.66h-88.91v-60.13c0-25.35 12.42-50.06 52.24-50.06h40.42V6.26S260.43 0 225.36 0c-73.22 0-121.08 44.38-121.08 124.72v70.62H22.89V288h81.39v224h100.17V288z'/%3E%3C/svg%3E");
}

.lrj-social a[aria-label^="Instagram"]::before {
	--lrj-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'%3E%3Cpath d='M224.1 141c-63.6 0-114.9 51.3-114.9 114.9s51.3 114.9 114.9 114.9S339 319.5 339 255.9 287.7 141 224.1 141zm0 189.6c-41.1 0-74.7-33.5-74.7-74.7s33.5-74.7 74.7-74.7 74.7 33.5 74.7 74.7-33.6 74.7-74.7 74.7zm146.4-194.3c0 14.9-12 26.8-26.8 26.8-14.9 0-26.8-12-26.8-26.8s12-26.8 26.8-26.8 26.8 12 26.8 26.8zm76.1 27.2c-1.7-35.9-9.9-67.7-36.2-93.9-26.2-26.2-58-34.4-93.9-36.2-37-2.1-147.9-2.1-184.9 0-35.8 1.7-67.6 9.9-93.9 36.1s-34.4 58-36.2 93.9c-2.1 37-2.1 147.9 0 184.9 1.7 35.9 9.9 67.7 36.2 93.9s58 34.4 93.9 36.2c37 2.1 147.9 2.1 184.9 0 35.9-1.7 67.7-9.9 93.9-36.2 26.2-26.2 34.4-58 36.2-93.9 2.1-37 2.1-147.8 0-184.8zM398.8 388c-7.8 19.6-22.9 34.7-42.6 42.6-29.5 11.7-99.5 9-132.1 9s-102.7 2.6-132.1-9c-19.6-7.8-34.7-22.9-42.6-42.6-11.7-29.5-9-99.5-9-132.1s-2.6-102.7 9-132.1c7.8-19.6 22.9-34.7 42.6-42.6 29.5-11.7 99.5-9 132.1-9s102.7-2.6 132.1 9c19.6 7.8 34.7 22.9 42.6 42.6 11.7 29.5 9 99.5 9 132.1s2.7 102.7-9 132.1z'/%3E%3C/svg%3E");
}

.lrj-social a[aria-label^="TikTok"]::before {
	--lrj-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'%3E%3Cpath d='M448,209.91a210.06,210.06,0,0,1-122.77-39.25V349.38A162.55,162.55,0,1,1,185,188.31V278.2a74.62,74.62,0,1,0,52.23,71.18V0l88,0a121.18,121.18,0,0,0,1.86,22.17h0A122.18,122.18,0,0,0,381,102.39a121.43,121.43,0,0,0,67,20.14Z'/%3E%3C/svg%3E");
}

.lrj-social a[aria-label^="YouTube"]::before {
	--lrj-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 576 512'%3E%3Cpath d='M549.655 124.083c-6.281-23.65-24.787-42.276-48.284-48.597C458.781 64 288 64 288 64S117.22 64 74.629 75.486c-23.497 6.322-42.003 24.947-48.284 48.597-11.412 42.867-11.412 132.305-11.412 132.305s0 89.438 11.412 132.305c6.281 23.65 24.787 41.5 48.284 47.821C117.22 448 288 448 288 448s170.78 0 213.371-11.486c23.497-6.321 42.003-24.171 48.284-47.821 11.412-42.867 11.412-132.305 11.412-132.305s0-89.438-11.412-132.305zm-317.51 213.508V175.185l142.739 81.205-142.739 81.201z'/%3E%3C/svg%3E");
}

/* 5g. Rata kiri (menimpa perataan tengah bawaan) */
.lrj-footer,
.lrj-footer .lrj-col,
.lrj-footer h4,
.lrj-footer p,
.lrj-footer .lrj-contact-item,
.lrj-footer .lrj-links li {
	text-align: left;
}

/* 5h. Disclaimer */
.lrj-disclaimer {
	position: relative;
	max-width: 900px;
	margin: 32px auto 0;
	padding: 8px 0 8px 48px;
	border-left: 3px solid #E0A11B;
	font-size: 13px;
	line-height: 1.7;
	color: #6a6a6a;
	text-align: left;
	font-style: italic;
}

.lrj-disclaimer::before {
	content: "\201C";
	position: absolute;
	left: 16px;
	top: -4px;
	font-size: 44px;
	line-height: 1;
	color: #E0A11B;
	font-family: Georgia, serif;
	font-style: normal;
}

/* 5i. Copyright */
.lrj-copyright {
	max-width: 1140px;
	margin: 24px auto 0;
	padding: 20px 24px 0;
	border-top: 1px solid #d0d0d0;
	text-align: center;
	font-size: 13px;
	color: #8a8a8a;
}

/* 5j. Responsif */
@media (max-width: 768px) {
	.lrj-footer-inner {
		flex-direction: column;
		gap: 28px;
	}

	.lrj-footer .lrj-col,
	.lrj-footer .lrj-col-1 {
		min-width: 100%;
	}
}


/* --------------------------------------------------------------------------
   6. Kartu campaign DonasiAja (daftar di /infak/ dan Load more)
   HTML kartu dibangun ulang di functions.php (astra_child_dja_card_html),
   memakai class lrj-card* sendiri agar tidak bentrok dengan CSS plugin.
   -------------------------------------------------------------------------- */

.cards__campaign.campaign_grid .cards__item {
	padding: 10px;
}

.cards__campaign .lrj-card {
	display: flex;
	flex-direction: column;
	width: 100%;
	overflow: hidden;
	background: #ffffff;
	border: 1px solid #E5EAE6;
	border-radius: 14px;
	box-shadow: 0 4px 14px rgba(19, 61, 40, 0.06);
	transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.cards__campaign .lrj-card:hover {
	border-color: #E0A11B;
	box-shadow: 0 8px 22px rgba(19, 61, 40, 0.1);
}

.cards__campaign .lrj-card__link {
	display: block;
	color: inherit;
	text-decoration: none;
}

/* Gambar + badge kategori di pojok kanan atas. */
.cards__campaign .lrj-card__media {
	position: relative;
	aspect-ratio: 650 / 350;
	background: #EEF5F0;
}

.cards__campaign .lrj-card__media img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.cards__campaign .lrj-cat-badge {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 2;
	padding: 4px 10px;
	border-radius: 999px;
	background: rgba(238, 245, 240, 0.92);
	color: #1F5C3A;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.4;
	box-shadow: 0 2px 6px rgba(19, 61, 40, 0.15);
	pointer-events: none;
}

.cards__campaign .lrj-card__head {
	padding: 14px 16px 0;
}

.cards__campaign .lrj-card__org {
	display: flex;
	align-items: center;
	gap: 5px;
	margin: 0 0 6px;
	color: #5B6660;
	font-size: 12px;
	line-height: 1.4;
}

.cards__campaign .lrj-card__verified {
	flex: none;
	width: 15px;
	height: 15px;
	fill: #E0A11B;
}

/* Judul: maksimal 2 baris lalu "...", selalu memakan ruang 2 baris
   agar tinggi kartu seragam. Judul lengkap ada di halaman detail. */
.cards__campaign .lrj-card__title {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	line-clamp: 2;
	overflow: hidden;
	min-height: 2.6em;
	margin: 0;
	color: #1F5C3A;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.3;
	word-break: break-word;
}

.cards__campaign .lrj-card__link:hover .lrj-card__title {
	color: #133D28;
}

.cards__campaign .lrj-card__body {
	display: flex;
	flex: 1;
	flex-direction: column;
	padding: 12px 16px 16px;
}

.cards__campaign .lrj-card__stats {
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	gap: 10px;
}

.cards__campaign .lrj-card__label {
	display: block;
	color: #5B6660;
	font-size: 12px;
	line-height: 1.4;
}

.cards__campaign .lrj-card__amount {
	display: block;
	color: #1F5C3A;
	font-size: 18px;
	font-weight: 700;
	line-height: 1.3;
}

.cards__campaign .lrj-card__days-box {
	text-align: right;
}

.cards__campaign .lrj-card__days {
	display: block;
	color: #1F5C3A;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.3;
	white-space: nowrap;
}

.cards__campaign .lrj-card__days.is-open {
	color: #B8860B;
}

.cards__campaign .lrj-card__days.is-ended {
	color: #8a8a8a;
}

.cards__campaign .lrj-card__bar {
	height: 8px;
	margin: 10px 0 6px;
	overflow: hidden;
	border-radius: 999px;
	background: #EEF5F0;
}

.cards__campaign .lrj-card__bar span {
	display: block;
	height: 100%;
	border-radius: 999px;
	background: #E0A11B;
}

.cards__campaign .lrj-card__meta {
	display: flex;
	justify-content: space-between;
	gap: 10px;
	margin-bottom: 14px;
	color: #8a8a8a;
	font-size: 12px;
	line-height: 1.4;
}

.cards__campaign .lrj-card__target {
	margin-left: auto;
	text-align: right;
}

/* Tombol didorong ke bawah agar sejajar antar kartu dalam satu baris. */
.cards__campaign .lrj-card__btn {
	display: block;
	margin-top: auto;
	padding: 11px 16px;
	border-radius: 10px;
	background: #E0A11B;
	color: #ffffff;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.3;
	text-align: center;
	text-decoration: none;
	transition: background-color 0.2s ease;
}

.cards__campaign .lrj-card__btn:hover,
.cards__campaign .lrj-card__btn:focus-visible {
	background: #B8860B;
	color: #ffffff;
}

.cards__campaign .lrj-card__btn.is-disabled {
	background: #eeeeee;
	color: #8a8a8a;
	cursor: not-allowed;
	pointer-events: none;
}

.cards__campaign .lrj-card.is-ended .lrj-card__bar span {
	background: #d0d0d0;
}

/* Kartu kategori Zakat (kelas ditambah PHP; tidak dipasang di halaman Program). */
.cards__campaign .lrj-card--zakat .lrj-card__stats,
.cards__campaign .lrj-card--zakat .lrj-card__bar,
.cards__campaign .lrj-card--zakat .lrj-card__target,
.cards__campaign .lrj-card--zakat.lrj-card--no-donor .lrj-card__donors {
	display: none;
}
