/**
 * KS LP Price Table Block Styles
 */

/* ==========================================================================
   Block Wrapper & Base
   ========================================================================== */
.kslp-price-table-block {
	position: relative;
	box-sizing: border-box;
	width: 100%;
}

.kslp-price-table-inner {
	width: 100%;
	margin-left: auto;
	margin-right: auto;
	position: relative;
	z-index: 1;
	box-sizing: border-box;
}

/* Overlay & Pattern */
.kslp-price-table-overlay {
	position: absolute;
	inset: 0;
	pointer-events: none;
	z-index: 0;
}

/* ==========================================================================
   Header Section (Optional)
   ========================================================================== */
.kslp-pt-header {
	margin-bottom: 28px;
}

.kslp-pt-sub {
	text-transform: uppercase;
	letter-spacing: 1.5px;
	font-weight: 700;
	margin-top: 0;
	margin-bottom: 6px;
	line-height: 1.25;
}

.kslp-pt-title {
	font-weight: 800;
	line-height: 1.2;
	margin-top: 0;
	margin-bottom: 10px;
}

.kslp-pt-desc {
	margin-top: 0;
	margin-bottom: 0;
	line-height: 1.6;
}

/* ==========================================================================
   Price Table List Container
   ========================================================================== */
.kslp-pt-list {
	display: flex;
	flex-direction: column;
	width: 100%;
	box-sizing: border-box;
}

/* ==========================================================================
   Price Table Row (Desktop Default)
   ========================================================================== */
.kslp-pt-row {
	display: flex;
	align-items: center;
	box-sizing: border-box;
	width: 100%;
	transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
	position: relative;
}

.kslp-pt-row:hover {
	transform: translateY(-1px);
}

/* Column 1: Date & Badge */
.kslp-pt-col--date {
	flex: 0 0 22%;
	min-width: 140px;
	box-sizing: border-box;
	text-align: left;
}

.kslp-pt-badge {
	display: block;
	text-transform: uppercase;
	line-height: 1.2;
	margin-bottom: 3px;
}

.kslp-pt-date {
	line-height: 1.25;
}

/* Mobile Quota (Hidden on desktop) */
.kslp-pt-quota-mobile {
	display: none;
}

/* Column 2: Package Name & Duration */
.kslp-pt-col--pkg {
	flex: 1 1 auto;
	min-width: 0;
	padding-right: 16px;
	box-sizing: border-box;
	text-align: left;
}

.kslp-pt-pkg {
	line-height: 1.3;
	margin-bottom: 2px;
	word-break: break-word;
}

.kslp-pt-dur {
	line-height: 1.3;
}

/* Column 3: Quota Pill */
.kslp-pt-col--quota {
	flex: 0 0 auto;
	margin-right: 20px;
	box-sizing: border-box;
}

.kslp-pt-quota-pill {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: 9999px;
	padding: 5px 14px;
	font-weight: 600;
	line-height: 1.2;
	white-space: nowrap;
}

/* Wrapper for Price + Button */
.kslp-pt-mobile-right {
	display: contents;
}

/* Column 4: Price */
.kslp-pt-col--price {
	flex: 0 0 auto;
	margin-right: 24px;
	box-sizing: border-box;
	text-align: right;
}

.kslp-pt-price {
	white-space: nowrap;
	line-height: 1.2;
}

/* Column 5: CTA Button */
.kslp-pt-col--cta {
	flex: 0 0 auto;
	box-sizing: border-box;
}

.kslp-pt-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	text-decoration: none !important;
	text-decoration-line: none !important;
	line-height: 1.2;
	white-space: nowrap;
	transition: all 0.25s ease;
	cursor: pointer;
	box-sizing: border-box;
	user-select: none;
	-webkit-tap-highlight-color: transparent;
}

.kslp-pt-btn:hover {
	transform: translateY(-1px);
	filter: brightness(1.08);
}

.kslp-pt-btn:active {
	transform: translateY(0);
}

.kslp-pt-btn-text {
	display: inline-block;
}

.kslp-pt-btn-icon {
	display: none;
	align-items: center;
	justify-content: center;
	line-height: 1;
}

.kslp-pt-btn-icon svg {
	width: 100%;
	height: 100%;
	display: block;
}

/* ==========================================================================
   Full Width Mode Breakout
   ========================================================================== */
.kslp-price-table-block--full {
	width: 100vw !important;
	max-width: 100vw !important;
	margin-left: calc(50% - 50vw) !important;
	margin-right: calc(50% - 50vw) !important;
}

/* ==========================================================================
   Responsive: Mobile (<= 767px)
   Transforms cleanly into the mockup mobile layout!
   ========================================================================== */
@media (max-width: 767px) {
	/* Clean divider layout mode (Mockup Mobile) */
	.kslp-price-table-block--divider .kslp-pt-list {
		gap: 0 !important;
	}

	.kslp-price-table-block--divider .kslp-pt-row {
		background-color: transparent !important;
		border-radius: 0 !important;
		border: none !important;
		border-bottom: 1px solid var(--kslp-pt-divider, #eee7dc) !important;
		padding-left: 0 !important;
		padding-right: 0 !important;
		display: flex !important;
		flex-direction: row !important;
		justify-content: space-between !important;
		align-items: center !important;
		box-shadow: none !important;
		transform: none !important;
	}

	.kslp-price-table-block--divider .kslp-pt-row:last-child {
		border-bottom: none !important;
	}

	/* Card mode for mobile if selected */
	.kslp-price-table-block--card .kslp-pt-row {
		display: flex !important;
		flex-direction: row !important;
		justify-content: space-between !important;
		align-items: center !important;
		padding: 14px 16px !important;
	}

	/* Left side in Mobile: takes remaining space */
	.kslp-pt-col--date {
		flex: 1 1 auto !important;
		min-width: 0 !important;
		padding-right: 12px !important;
	}

	.kslp-pt-badge {
		margin-bottom: 2px !important;
	}

	.kslp-pt-date {
		margin-bottom: 2px !important;
	}

	/* Display Quota below date in Mobile */
	.kslp-pt-quota-mobile {
		display: block !important;
		font-weight: 500 !important;
		line-height: 1.3 !important;
		margin-top: 2px !important;
	}

	/* Hide desktop separate quota pill */
	.kslp-pt-col--quota {
		display: none !important;
	}

	/* Hide package/duration on mobile unless specifically enabled */
	.kslp-price-table-block:not(.kslp-pt--show-pkg-mob) .kslp-pt-col--pkg {
		display: none !important;
	}

	.kslp-price-table-block.kslp-pt--show-pkg-mob .kslp-pt-col--pkg {
		display: block !important;
		margin-top: 4px !important;
		padding-right: 0 !important;
	}

	/* Right side in Mobile: Price and WA Button */
	.kslp-pt-mobile-right {
		display: flex !important;
		align-items: center !important;
		gap: 12px !important;
		flex: 0 0 auto !important;
	}

	.kslp-pt-col--price {
		margin-right: 0 !important;
		text-align: right !important;
	}

	.kslp-pt-col--cta {
		flex: 0 0 auto !important;
	}

	/* Transform CTA Button into 42px Circle WA Button */
	.kslp-pt-btn {
		width: var(--kslp-pt-btn-size, 42px) !important;
		height: var(--kslp-pt-btn-size, 42px) !important;
		min-width: var(--kslp-pt-btn-size, 42px) !important;
		padding: 0 !important;
		border-radius: 50% !important;
		justify-content: center !important;
		box-shadow: 0 3px 10px rgba(12, 68, 48, 0.22) !important;
	}

	.kslp-pt-btn-text {
		display: none !important;
	}

	.kslp-pt-btn-icon {
		display: inline-flex !important;
		width: 20px !important;
		height: 20px !important;
	}

	.kslp-pt-header {
		margin-bottom: 20px !important;
	}
}

/* ==========================================================================
   Animation Support
   ========================================================================== */
.kslp-section-anim[data-kslp-anim="fade-up"] .kslp-pt-row {
	opacity: 0;
	transform: translateY(20px);
	transition: opacity var(--kslp-anim-duration, 600ms) cubic-bezier(0.16, 1, 0.3, 1),
	            transform var(--kslp-anim-duration, 600ms) cubic-bezier(0.16, 1, 0.3, 1);
}

.kslp-section-anim[data-kslp-anim="fade-up"].is-animated .kslp-pt-row {
	opacity: 1;
	transform: translateY(0);
}
