/* 
Theme Name: Hello Elementor Child
Theme URI: https://github.com/elementor/hello-theme-child/
Description: Hello Elementor Child is a child theme of Hello Elementor, created by Elementor team
Author: Elementor Team
Author URI: https://elementor.com/
Template: hello-elementor
Version: 2.0.0
Text Domain: hello-elementor-child
License: GNU General Public License v3 or later.
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Tags: flexible-header, custom-colors, custom-menu, custom-logo, editor-style, featured-images, rtl-language-support, threaded-comments, translation-ready
*/

/* Add your custom styles here */


/* ==========================================================
   EA Image Accordion (.product-grid): title tampil sebelum hover,
   deskripsi tetap muncul saat hover.
   ========================================================== */
.product-grid .eael-image-accordion-item .overlay-inner > a,
.product-grid .eael-image-accordion-item .overlay-inner .img-accordion-title {
	opacity: 1 !important;
	visibility: visible !important;
	transform: none !important;
}

/* Gradasi gelap di bawah supaya title terbaca di atas foto */
.product-grid .eael-image-accordion-item .overlay {
	background-image: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, rgba(0, 0, 0, 0) 55%) !important;
}

/* Title tidak pecah per huruf saat item masih sempit */
.product-grid .eael-image-accordion-item .img-accordion-title {
	word-break: normal;
	overflow-wrap: normal;
	hyphens: none;
}

/* Deskripsi tidak makan tempat sebelum hover, jadi title tetap di bawah kartu */
.product-grid .eael-image-accordion-item .overlay-inner p {
	max-height: 600px;
	overflow: hidden;
	transition: max-height .4s ease;
}
.product-grid .eael-image-accordion-item:not(:hover):not(.overlay-active) .overlay-inner p {
	max-height: 0;
	margin: 0;
	padding: 0;
}

/* Title selalu 16px, sebelum maupun saat hover */
.product-grid .eael-image-accordion-item .img-accordion-title {
	font-size: 16px !important;
}

/* Accordion selalu selebar container. Tanpa ini, di container yang
   Align Items = Center (tablet/mobile) widget menyusut jadi 8px dan tidak terlihat. */
.elementor-widget-eael-image-accordion:not([class*="__width-"]) {
	width: 100%;
	align-self: stretch;
}

/* Items per Row: susun baris-baris accordion ke bawah */
.hsg-ia-rows {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

/* Baris terakhir yang belum penuh: kartu tetap selebar kartu di baris atas (desktop) */
@media (min-width: 1025px) {
	.hsg-ia-rows > .eael-img-accordion.hsg-ia-partial {
		width: var(--hsg-ia-row-w);
		max-width: var(--hsg-ia-row-w);
	}
}

/* Seluruh kartu bisa diklik: link title dibentangkan menutupi kartu (.overlay sudah absolute penuh) */
.product-grid .eael-image-accordion-item .overlay-inner > a::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 2;
}
.product-grid .eael-image-accordion-item:has(.overlay-inner > a) {
	cursor: pointer;
}
