/* =========================================================
   4 Saisons — PDF Flipbook Viewer
   ========================================================= */

.fst-flipbook-container {
	max-width: 1200px;
	margin: 0 auto;
	font-family: 'Manrope', sans-serif;
}

/* Toolbar */
.fst-flipbook-toolbar {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.75rem;
	padding: 0.75rem 1.25rem;
	background: #1a1a1a;
	border-radius: 10px 10px 0 0;
	color: #fff;
	flex-wrap: wrap;
}

.fst-flipbook-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.35rem;
	padding: 0.5rem 0.85rem;
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 6px;
	color: #fff;
	font-size: 0.85rem;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.2s;
	text-decoration: none;
	font-family: 'Manrope', sans-serif;
}

.fst-flipbook-btn:hover {
	background: var(--fst-primary, #C41E3A);
	border-color: var(--fst-primary, #C41E3A);
	color: #fff;
}

.fst-flipbook-btn:disabled {
	opacity: 0.4;
	cursor: not-allowed;
}

.fst-flipbook-btn:disabled:hover {
	background: rgba(255, 255, 255, 0.1);
	border-color: rgba(255, 255, 255, 0.15);
	color: #fff;
}

.fst-flipbook-btn svg {
	width: 16px;
	height: 16px;
}

.fst-flipbook-page-info {
	display: flex;
	align-items: center;
	gap: 0.4rem;
	font-size: 0.88rem;
	color: rgba(255, 255, 255, 0.8);
	padding: 0 0.5rem;
}

.fst-flipbook-page-input {
	width: 3rem;
	padding: 0.3rem 0.4rem;
	background: rgba(255, 255, 255, 0.15);
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 4px;
	color: #fff;
	font-size: 0.88rem;
	text-align: center;
	font-family: 'Manrope', sans-serif;
}

.fst-flipbook-page-input:focus {
	outline: none;
	border-color: var(--fst-primary, #C41E3A);
}

.fst-flipbook-separator {
	width: 1px;
	height: 24px;
	background: rgba(255, 255, 255, 0.2);
}

/* Viewer area */
.fst-flipbook-viewer {
	position: relative;
	background: var(--fst-gray-light, #F8F9FA);
	min-height: 500px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-left: 1px solid #E1E8ED;
	border-right: 1px solid #E1E8ED;
	overflow: hidden;
}

.fst-flipbook-spread {
	display: flex;
	gap: 0;
	padding: 2rem;
	perspective: 2000px;
}

.fst-flipbook-page {
	background: #fff;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
	position: relative;
	transition: transform 0.4s ease;
}

.fst-flipbook-page canvas {
	display: block;
	width: 100%;
	height: auto;
}

/* Spine shadow between pages in double mode */
.fst-flipbook-spread.fst-spread-double .fst-flipbook-page:first-child {
	box-shadow: 4px 4px 20px rgba(0, 0, 0, 0.1), inset -8px 0 20px -10px rgba(0, 0, 0, 0.08);
	border-radius: 4px 0 0 4px;
}

.fst-flipbook-spread.fst-spread-double .fst-flipbook-page:last-child {
	box-shadow: -4px 4px 20px rgba(0, 0, 0, 0.1), inset 8px 0 20px -10px rgba(0, 0, 0, 0.08);
	border-radius: 0 4px 4px 0;
}

.fst-flipbook-spread.fst-spread-single .fst-flipbook-page {
	border-radius: 4px;
}

/* Click zones for navigation */
.fst-flipbook-nav-prev,
.fst-flipbook-nav-next {
	position: absolute;
	top: 0;
	bottom: 0;
	width: 15%;
	cursor: pointer;
	z-index: 5;
	display: flex;
	align-items: center;
	opacity: 0;
	transition: opacity 0.2s;
}

.fst-flipbook-nav-prev { left: 0; justify-content: flex-start; padding-left: 1rem; }
.fst-flipbook-nav-next { right: 0; justify-content: flex-end; padding-right: 1rem; }

.fst-flipbook-viewer:hover .fst-flipbook-nav-prev,
.fst-flipbook-viewer:hover .fst-flipbook-nav-next {
	opacity: 1;
}

.fst-flipbook-nav-arrow {
	width: 40px;
	height: 40px;
	background: rgba(0, 0, 0, 0.5);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff;
	transition: background 0.2s;
}

.fst-flipbook-nav-prev:hover .fst-flipbook-nav-arrow,
.fst-flipbook-nav-next:hover .fst-flipbook-nav-arrow {
	background: var(--fst-primary, #C41E3A);
	color: #fff;
}

/* Loading */
.fst-flipbook-loading {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1rem;
	color: #888;
	font-size: 0.95rem;
}

.fst-flipbook-spinner {
	width: 40px;
	height: 40px;
	border: 3px solid #E1E8ED;
	border-top-color: var(--fst-primary, #C41E3A);
	border-radius: 50%;
	animation: fst-spin 0.8s linear infinite;
}

@keyframes fst-spin {
	to { transform: rotate(360deg); }
}

/* Bottom bar / Download */
.fst-flipbook-bottom {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0.75rem 1.25rem;
	background: #1a1a1a;
	border-radius: 0 0 10px 10px;
}

.fst-flipbook-download {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	padding: 0.5rem 1.2rem;
	background: var(--fst-primary, #C41E3A);
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	font-size: 0.88rem;
	border-radius: 6px;
	transition: all 0.2s;
	font-family: 'Manrope', sans-serif;
}

.fst-flipbook-download:hover {
	background: #fff;
	color: #1a1a1a;
	transform: translateY(-1px);
}

.fst-flipbook-download svg {
	width: 16px;
	height: 16px;
}

/* Fullscreen mode */
.fst-flipbook-container.fst-fullscreen {
	position: fixed;
	inset: 0;
	max-width: none;
	z-index: 99999;
	display: flex;
	flex-direction: column;
	background: #1a1a1a;
	border-radius: 0;
}

.fst-fullscreen .fst-flipbook-toolbar {
	border-radius: 0;
	flex-shrink: 0;
}

.fst-fullscreen .fst-flipbook-viewer {
	flex: 1;
	border: none;
}

.fst-fullscreen .fst-flipbook-bottom {
	border-radius: 0;
	flex-shrink: 0;
}

/* Empty state */
.fst-pdf-empty {
	text-align: center;
	padding: 4rem 1rem;
	color: #888;
	font-size: 1.05rem;
}

/* Responsive */
@media (max-width: 768px) {
	.fst-flipbook-toolbar {
		padding: 0.6rem 0.75rem;
		gap: 0.4rem;
	}

	.fst-flipbook-btn {
		padding: 0.4rem 0.6rem;
		font-size: 0.78rem;
	}

	.fst-flipbook-btn .fst-btn-label {
		display: none;
	}

	.fst-flipbook-separator {
		display: none;
	}

	.fst-flipbook-page-info {
		font-size: 0.8rem;
	}

	.fst-flipbook-spread {
		padding: 1rem 0.5rem;
	}

	.fst-flipbook-viewer {
		min-height: 350px;
	}
}
