/**
 * Celebration Tabs widget styles.
 *
 * @package PerranParthBeachWeddings
 */

.ppbw-celebration-tabs {
	--ppbw-accent: #c5a54c;
	--ppbw-cream: #fdf9f3;
	--ppbw-text: #1a1a1a;
	--ppbw-white: #ffffff;
	--ppbw-font: "Cormorant Garamond", "Playfair Display", "Times New Roman", serif;
	--ppbw-mobile-breakpoint: 767px;
	--ppbw-image-zoom-duration: 1.2s;
	--ppbw-image-zoom-exit-duration: 0.8s;
	--ppbw-image-zoom-scale: 1.22;
	--ppbw-image-zoom-ease: cubic-bezier(0.16, 1, 0.3, 1);
	--ppbw-image-flash-duration: 0.55s;
	--ppbw-image-flash-color: #ffffff;
	width: 100%;
	font-family: var(--ppbw-font);
	color: var(--ppbw-text);
}

.ppbw-celebration-tabs *,
.ppbw-celebration-tabs *::before,
.ppbw-celebration-tabs *::after {
	box-sizing: border-box;
}

.ppbw-celebration-tabs__wrapper {
	width: 100%;
	margin: 0 auto;
	border: 1px solid var(--ppbw-accent);
	background-color: var(--ppbw-white);
}

/* Desktop tab navigation */
.ppbw-celebration-tabs__nav--desktop {
	display: flex;
	width: 100%;
	border-bottom: 1px solid var(--ppbw-accent);
}

.ppbw-celebration-tabs__tab {
	flex: 1 1 0;
	margin: 0;
	padding: 18px 24px;
	border: 0;
	border-radius: 0;
	background-color: var(--ppbw-white);
	color: var(--ppbw-accent);
	font-family: inherit;
	font-size: 22px;
	font-weight: 400;
	line-height: 1.2;
	text-align: center;
	cursor: pointer;
	transition: background-color 0.25s ease, color 0.25s ease;
	appearance: none;
	-webkit-appearance: none;
}

.ppbw-celebration-tabs__tab + .ppbw-celebration-tabs__tab {
	border-left: 1px solid var(--ppbw-accent);
}

.ppbw-celebration-tabs__tab.is-active {
	background-color: var(--ppbw-accent);
	color: var(--ppbw-white);
}

.ppbw-celebration-tabs__tab:focus-visible {
	outline: 2px solid var(--ppbw-accent);
	outline-offset: -2px;
}

/* Mobile navigation — hidden on desktop */
.ppbw-celebration-tabs__nav--mobile {
	display: none;
	align-items: stretch;
	width: 100%;
	border-bottom: 1px solid var(--ppbw-accent);
}

.ppbw-celebration-tabs__mobile-btn {
	display: flex;
	flex: 0 0 56px;
	align-items: center;
	justify-content: center;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background-color: var(--ppbw-white);
	color: var(--ppbw-text);
	cursor: pointer;
	transition: opacity 0.2s ease;
	appearance: none;
	-webkit-appearance: none;
}

.ppbw-celebration-tabs__mobile-btn + .ppbw-celebration-tabs__mobile-btn {
	border-left: 1px solid var(--ppbw-accent);
}

.ppbw-celebration-tabs__mobile-btn svg,
.ppbw-celebration-tabs__mobile-btn i {
	width: 18px;
	height: 18px;
	font-size: 18px;
}

.ppbw-celebration-tabs__mobile-btn:focus-visible {
	outline: 2px solid var(--ppbw-accent);
	outline-offset: -2px;
}

.ppbw-celebration-tabs__mobile-label {
	display: flex;
	flex: 1 1 auto;
	align-items: center;
	justify-content: center;
	padding: 16px 12px;
	background-color: var(--ppbw-accent);
	color: var(--ppbw-white);
	font-size: 22px;
	font-weight: 400;
	line-height: 1.2;
	text-align: center;
}

/* Panels */
.ppbw-celebration-tabs__panels {
	position: relative;
}

.ppbw-celebration-tabs__panel {
	display: none;
}

.ppbw-celebration-tabs__panel.is-active {
	display: block;
}

.ppbw-celebration-tabs__panel-inner {
	display: grid;
	grid-template-columns: 1fr 1fr;
	min-height: 420px;
}

/* Content column */
.ppbw-celebration-tabs__content {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 48px 40px;
	background-color: var(--ppbw-cream);
	text-align: center;
	overflow: hidden;
}

.ppbw-celebration-tabs__title {
	margin: 0 0 20px;
	color: var(--ppbw-text);
	font-family: inherit;
	font-size: 42px;
	font-weight: 400;
	line-height: 1.15;
	letter-spacing: 0.01em;
}

.ppbw-celebration-tabs__description {
	max-width: 340px;
	margin: 0 0 32px;
	color: var(--ppbw-text);
	font-family: inherit;
	font-size: 18px;
	font-weight: 400;
	line-height: 1.55;
}

.ppbw-celebration-tabs__button {
	display: inline-block;
	padding: 14px 36px;
	border: 0;
	border-radius: 0;
	background-color: var(--ppbw-accent);
	color: var(--ppbw-white);
	font-family: inherit;
	font-size: 16px;
	font-weight: 400;
	line-height: 1.2;
	text-decoration: none;
	text-align: center;
	cursor: pointer;
	transition: background-color 0.25s ease, color 0.25s ease;
}

.ppbw-celebration-tabs__button:hover,
.ppbw-celebration-tabs__button:focus {
	text-decoration: none;
}

/* Animated content and image on tab switch */
.ppbw-celebration-tabs__content,
.ppbw-celebration-tabs__media {
	animation-fill-mode: both;
}

.ppbw-celebration-tabs__content.elementor-invisible,
.ppbw-celebration-tabs__media.elementor-invisible {
	visibility: hidden;
}

/* Image column */
.ppbw-celebration-tabs__media {
	position: relative;
	overflow: hidden;
	height: 100%;
	display: flex;
}
.ppbw-tab__media {
    height: 100%;
	width: 100%; 
	flex-shrink: 0;
} 

.ppbw-celebration-tabs__media-flash {
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	left: 0;
	z-index: 3;
	background-color: var(--ppbw-image-flash-color, #ffffff);
	opacity: 0;
	pointer-events: none;
}

.ppbw-celebration-tabs__media-flash.is-flashing {
	animation: ppbw-tabs-image-flash var(--ppbw-image-flash-duration, 0.4s) cubic-bezier(0.4, 0, 0.2, 1) 1 forwards;
}

@keyframes ppbw-tabs-image-flash {
	0% {
		opacity: 0.72;
	}

	35% {
		opacity: 0.28;
	}

	100% {
		opacity: 0;
	}
}

.ppbw-celebration-tabs__media .ppbw-celebration-tabs__image {
	display: block;
	position: relative;
	z-index: 1;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center center;
	transform: scale(1);
	transform-origin: center center;
	backface-visibility: hidden;
	-webkit-backface-visibility: hidden;
	will-change: transform, opacity;
	opacity: 1;
}

.ppbw-celebration-tabs__image.is-zooming-out {
	animation: ppbw-tabs-image-zoom-out var(--ppbw-image-zoom-exit-duration, 0.35s) var(--ppbw-image-zoom-ease, cubic-bezier(0.22, 1, 0.36, 1)) 1 forwards;
}

.ppbw-celebration-tabs__image.is-zooming-in {
	animation: ppbw-tabs-image-zoom-in var(--ppbw-image-zoom-duration, 0.8s) var(--ppbw-image-zoom-ease, cubic-bezier(0.22, 1, 0.36, 1)) 1 forwards;
}

.ppbw-celebration-tabs__content,.ppbw-celebration-tabs__media{
	height: var(--height);
}

@keyframes ppbw-tabs-image-zoom-out {
	from {
		transform: scale(1);
	}

	to {
		transform: scale(var(--ppbw-image-zoom-scale, 1.3));
	}
}

@keyframes ppbw-tabs-image-zoom-in {
	from {
		transform: scale(var(--ppbw-image-zoom-scale, 1.3));
	}

	to {
		transform: scale(1);
	}
}

@media (prefers-reduced-motion: reduce) {
	.ppbw-celebration-tabs__media-flash.is-flashing {
		animation: none;
		opacity: 0;
	}

	.ppbw-celebration-tabs__image.is-zooming-out,
	.ppbw-celebration-tabs__image.is-zooming-in {
		animation: none !important;
		transform: scale(1);
	}
}

/* Mobile layout */
@media (max-width: 767px) {
	.ppbw-celebration-tabs__nav--desktop {
		display: none;
	}

	.ppbw-celebration-tabs__nav--mobile {
		display: flex;
	}

	.ppbw-celebration-tabs__panel-inner {
		grid-template-columns: 1fr;
		min-height: 0;
	}

	.ppbw-celebration-tabs__media {
		order: -1;
		min-height: 260px;
	}

	.ppbw-celebration-tabs__image {
		min-height: 260px;
	}

	.ppbw-celebration-tabs__content {
		padding: 40px 28px 44px;
	}

	.ppbw-celebration-tabs__title {
		font-size: 36px;
	}

	.ppbw-celebration-tabs__description {
		max-width: 100%;
		font-size: 17px;
	}
	.ppbw-celebration-tabs__content{
		height: auto;
	}
}

@media (max-width: 480px) {
	.ppbw-celebration-tabs__mobile-btn {
		flex-basis: 48px;
	}

	.ppbw-celebration-tabs__mobile-label {
		font-size: 20px;
	}

	.ppbw-celebration-tabs__title {
		font-size: 32px;
	}

	.ppbw-celebration-tabs__description {
		font-size: 16px;
	}

	.ppbw-celebration-tabs__content {
		padding: 32px 20px 36px;
	}
}
