/* =====================================================================
   WTE Trip Reviews — Frontend Styles
   Color scheme: #f1f5f9 surfaces · #1b2340 text/actions · gold stars only
   ===================================================================== */

/* ---- Mover positioning (flex sibling inside NB-tabs) --------------- */
#wtr-reviews-mover {
	order: 9999;
	width: 100%;
}

/* ---- Reviews tab injected into WTE tab bar ------------------------- */
/*
 * We do NOT use WTE's .nav-tab class — it triggers WTE's own JS click
 * handler and resets to Overview. We replicate the appearance instead.
 *
 * The sibling .nav-tab elements inside WTE carry all the structural styles
 * (font, padding, colour) so we just copy what WTE renders on .nav-tab and
 * make sure our element flexes the same way in every breakpoint.
 */
.wtr-reviews-nav-tab {
	/* Layout — match a flex/inline-flex sibling */
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;          /* don't squish on narrow bars          */
	white-space: nowrap;

	/* Typography — inherit from the parent tab anchor context */
	font-size:   inherit;
	font-family: inherit;
	font-weight: inherit;
	line-height: inherit;
	color:       inherit;
	text-decoration: none !important;

	/* Spacing — copy WTE's .nav-tab defaults */
	padding: 0.5em 1em;
	margin:  0;

	/* Reset button/a defaults */
	background:  transparent !important;
	border:      none;
	border-bottom: 3px solid transparent; /* reserve space like WTE does */
	outline:     none;
	cursor:      pointer;
	transition:  color .2s, border-color .2s;
}
.wtr-reviews-nav-tab:hover,
.wtr-reviews-nav-tab:focus {
	color: inherit;
	text-decoration: none !important;
	background: transparent !important;
}



/*
 * Active state: mirror WTE's own nav-tab-active styling exactly.
 *
 * WTE's CSS rule is:
 *   .nav-tab-wrapper .tab-anchor-wrapper .nav-tab.nav-tab-active {
 *     color: var(--wpte-primary-color, var(--primary-color));
 *     border-bottom-color: var(--wpte-primary-color, var(--primary-color));
 *   }
 *
 * Our link doesn't carry .nav-tab (that would trigger WTE's click handler),
 * so we replicate the same CSS-variable rule here.  The fallback #e03f3f is
 * WTE's compiled default for sites that don't set the custom property.
 */
.wtr-reviews-nav-tab.nav-tab-active,
.wtr-reviews-nav-tab.wtr-nav-active {
	color:              var(--wpte-primary-color, var(--primary-color, #e03f3f)) !important;
	border-bottom-color: var(--wpte-primary-color, var(--primary-color, #e03f3f)) !important;
}

/*
 * Desktop sticky tab bar — match WTE's compiled .nav-tab values exactly:
 *   font-size: 16px; display: flex !important; padding: 16px 4px;
 *   border-bottom: 2px solid transparent; color: rgba(15,29,35,.56);
 */
.nav-tab-wrapper .tab-inner-wrapper .tab-anchor-wrapper .wtr-reviews-nav-tab {
	display:       flex !important;
	align-items:   center;
	font-size:     16px !important;
	padding:       16px 4px !important;
	border-bottom: 2px solid transparent !important;
	color:         rgba(15, 29, 35, .56) !important;
	white-space:   nowrap;
	text-decoration: none !important;
}

/*
 * Mobile sticky bar (.wpte-sticky-tab-mobile):
 * Native WTE links here are DIRECT children of .tab-anchor-wrapper (no h2).
 * We match the same structure + WTE's full compiled values:
 *   base:   font-size:16px; display:flex !important; padding:16px 4px;
 *   mobile: padding-right:16px; border-bottom:1px solid transparent !important;
 *           color:inherit; text-decoration:none; box-shadow:none !important;
 */
.wpte-sticky-tab-mobile .tab-anchor-wrapper .wtr-reviews-nav-tab {
	display:         flex !important;
	align-items:     center;
	font-size:       16px !important;
	padding:         16px 16px 16px 4px !important;
	border-bottom:   1px solid transparent !important;
	color:           inherit !important;
	white-space:     nowrap;
	text-decoration: none !important;
	box-shadow:      none !important;
}

/* ---- Section wrapper ----------------------------------------------- */
.wtr-section {
	margin: 48px 0 36px;
	font-family: inherit;
}

.wtr-inner { max-width: 100%; }

/* ---- Section header ------------------------------------------------ */
.wtr-section-header {
	display: flex;
	align-items: center;
	gap: 20px;
	margin-bottom: 28px;
}

.wtr-section-header__text { flex-shrink: 0; }

.wtr-section-title {
	font-size: 22px !important;
	font-weight: 800 !important;
	color: #0d1b2a !important;
	margin: 0 0 4px !important;
	line-height: 1.2 !important;
}

.wtr-section-sub { font-size: 14px; color: #6b7280; margin: 0; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }

/* Verified badge inside section sub-heading */
.wtr-verified-badge {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-size: 12px;
	font-weight: 600;
	color: #059669;
	background: #ecfdf5;
	border: 1px solid #a7f3d0;
	border-radius: 20px;
	padding: 2px 8px 2px 6px;
	white-space: nowrap;
}
.wtr-verified-badge svg { flex-shrink: 0; }

.wtr-section-divider {
	flex: 1;
	height: 2px;
	background: linear-gradient(to right, #1b2340 0%, rgba(27,35,64,.12) 60%, transparent 100%);
	border-radius: 2px;
}

/* ---- Title rating snippet (injected by JS below trip title) -------- */
/* Always sits on its own line between title and days/nights boxes */
.wtr-title-snippet {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 6px 0;
	flex-wrap: wrap;
}

/* Verified badge inside the title snippet */
.wtr-title-verified {
	display: inline-flex;
	align-items: center;
	gap: 3px;
	font-size: 11px;
	font-weight: 600;
	color: #059669;
	background: #ecfdf5;
	border: 1px solid #a7f3d0;
	border-radius: 20px;
	padding: 2px 7px 2px 5px;
	white-space: nowrap;
}
.wtr-title-verified svg { flex-shrink: 0; }

/* Mobile: wrap in a visible pill */
@media (max-width: 768px) {
	.wtr-title-snippet {
		display: inline-flex;
		background: #f1f5f9;
		border-radius: 20px;
		padding: 5px 12px;
		margin: 8px 0;
	}
}

.wtr-title-snippet-btn {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	background: none !important;
	border: none;
	cursor: pointer;
	padding: 4px 0;
	font-size: 14px;
	color: #374151;
	line-height: 1;
	text-decoration: none !important;
	box-shadow: none !important;
	outline: none !important;
}
.wtr-title-snippet-btn:hover,
.wtr-title-snippet-btn:focus {
	background: none !important;
	color: #374151 !important;
	box-shadow: none !important;
	outline: none !important;
	text-decoration: none !important;
}
.wtr-title-snippet-btn:hover .wtr-title-count { text-decoration: underline; }

.wtr-title-stars .wtr-s { font-size: 14px; }
.wtr-title-avg   { font-weight: 700; color: #1b2340; }
.wtr-title-count { color: #1b2340; font-weight: 600; opacity: .8; }

/* ---- Star display -------------------------------------------------- */
.wtr-stars-row { display: inline-flex; gap: 1px; }
.wtr-s         { font-size: 16px; }
.wtr-s--full   { color: #f0a500; }
.wtr-s--empty  { color: #d1d5db; }
.wtr-s--half   {
	position: relative;
	color: #d1d5db;
	display: inline-block;
}
.wtr-s--half::before {
	content: '★';
	position: absolute;
	left: 0; top: 0;
	width: 50%;
	overflow: hidden;
	color: #f0a500;
}

/* ---- Rating summary block ----------------------------------------- */
.wtr-summary-block {
	display: flex;
	align-items: center;
	gap: 32px;
	background: #fff;
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	padding: 24px 28px;
	margin-bottom: 24px;
}

.wtr-summary-score {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	flex-shrink: 0;
	min-width: 90px;
}

.wtr-big-avg { font-size: 52px; font-weight: 800; color: #0d1b2a; line-height: 1; }

.wtr-avg-stars .wtr-s { font-size: 20px; }

.wtr-review-count { font-size: 12px; color: #6b7280; font-weight: 500; }

.wtr-summary-bars {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 7px;
}

.wtr-bar-row { display: flex; align-items: center; gap: 8px; font-size: 12px; }

.wtr-bar-label {
	width: 26px;
	text-align: right;
	color: #6b7280;
	font-weight: 600;
	flex-shrink: 0;
}

.wtr-bar-track {
	flex: 1;
	height: 8px;
	background: #e5e7eb;
	border-radius: 4px;
	overflow: hidden;
}

.wtr-bar-fill {
	height: 100%;
	background: linear-gradient(90deg, #f0a500, #fbbf24);
	border-radius: 4px;
	transition: width .4s ease;
}

.wtr-bar-num { width: 18px; text-align: right; color: #6b7280; font-size: 11px; flex-shrink: 0; }

/* ---- Teaser action buttons ---------------------------------------- */
.wtr-teaser-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 4px; }

/* "See X more reviews" button */
.wtr-view-all-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: #f1f5f9;
	color: #1b2340 !important;
	border: none;
	border-radius: 8px;
	padding: 11px 22px;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	transition: background .2s, transform .1s;
	line-height: 1;
}
.wtr-view-all-btn:hover  { background: #e2e8f0; color: #1b2340 !important; }
.wtr-view-all-btn:active { transform: scale(.98); }

/* "Write a Review" button */
.wtr-write-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: #f1f5f9;
	color: #1b2340 !important;
	border: 2px solid #e2e8f0;
	border-radius: 8px;
	padding: 9px 20px;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	transition: background .2s, color .2s, transform .1s;
	line-height: 1;
}
.wtr-write-btn:hover  { background: #e2e8f0; color: #1b2340 !important; }
.wtr-write-btn:active { transform: scale(.98); }

/* Write button inside modal — same flat style */
.wtr-write-btn--modal {
	background: #f1f5f9;
	color: #1b2340 !important;
	border-color: #e2e8f0;
}
.wtr-write-btn--modal:hover                 { background: #e2e8f0; color: #1b2340 !important; }
.wtr-write-btn--modal[aria-expanded="true"] { background: #e2e8f0; color: #1b2340 !important; }

/* ---- No reviews placeholder --------------------------------------- */
.wtr-no-reviews {
	text-align: center;
	padding: 40px 20px;
	color: #9ca3af;
	background: #fff;
	border: 2px dashed #e5e7eb;
	border-radius: 12px;
	margin-bottom: 24px;
}
.wtr-no-reviews svg { display: block; margin: 0 auto 12px; opacity: .4; }
.wtr-no-reviews p   { margin: 0; font-size: 15px; }

/* ---- Review cards -------------------------------------------------- */
.wtr-reviews-list { display: flex; flex-direction: column; gap: 20px; margin-bottom: 28px; }

.wtr-card {
	background: #fff;
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	padding: 22px 24px;
	transition: box-shadow .2s;
}
.wtr-card:hover { box-shadow: 0 4px 20px rgba(13,27,42,.07); }

.wtr-card-top { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 14px; }

.wtr-reviewer-avatar {
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background: linear-gradient(135deg, #0d1b2a, #374151);
	color: #fff;
	font-size: 18px;
	font-weight: 800;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.wtr-reviewer-info { flex: 1; }

.wtr-reviewer-name { display: block; font-size: 15px; font-weight: 700; color: #0d1b2a; line-height: 1.3; }
.wtr-toured        { display: block; font-size: 12px; color: #6b7280; margin-top: 2px; }

.wtr-card-rating { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; flex-shrink: 0; }
.wtr-card-date   { font-size: 11px; color: #9ca3af; }

.wtr-card-title {
	font-size: 16px !important;
	font-weight: 700 !important;
	color: #0d1b2a !important;
	margin: 0 0 8px !important;
	line-height: 1.4 !important;
}

.wtr-card-body { font-size: 14px; line-height: 1.75; color: #374151; margin-bottom: 14px; }

/* Photos */
.wtr-card-photos { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }

.wtr-photo-thumb {
	display: block;
	width: 80px; height: 80px;
	border-radius: 8px;
	overflow: hidden;
	border: 2px solid #e5e7eb;
	transition: border-color .2s, transform .15s;
}
.wtr-photo-thumb:hover { border-color: #1b2340; transform: scale(1.04); }
.wtr-photo-thumb img   { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Owner reply */
.wtr-owner-reply {
	background: #f1f5f9;
	border-left: 3px solid #1b2340;
	border-radius: 0 8px 8px 0;
	padding: 14px 18px;
	margin-top: 4px;
}

.wtr-reply-badge {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	font-weight: 700;
	color: #1b2340;
	margin-bottom: 8px;
}
.wtr-reply-badge svg { flex-shrink: 0; }
.wtr-reply-date { font-weight: 400; color: #6b7280; font-size: 12px; }
.wtr-reply-text { font-size: 13px; line-height: 1.7; color: #374151; margin: 0; }

/* =====================================================================
   FULL-SCREEN MODAL  — 80 % desktop · 90 % mobile · always centred
   ===================================================================== */

.wtr-modal-overlay {
	position: fixed;
	inset: 0;
	z-index: 999999;
	background: rgba(13,27,42,.72);
	display: flex;
	align-items: center;
	justify-content: center;
	backdrop-filter: blur(3px);
	-webkit-backdrop-filter: blur(3px);
	animation: wtrFadeIn .2s ease;
}
.wtr-modal-overlay[hidden] { display: none; }

@keyframes wtrFadeIn { from { opacity: 0; } to { opacity: 1; } }

.wtr-modal-box {
	background: #fff;
	border-radius: 16px;
	width: 80vw;
	max-width: 80vw;
	max-height: 80vh;
	display: flex;
	flex-direction: column;
	overflow: hidden;
	box-shadow: 0 24px 80px rgba(13,27,42,.3);
	animation: wtrSlideUp .25s ease;
}

@keyframes wtrSlideUp {
	from { transform: translateY(24px); opacity: 0; }
	to   { transform: translateY(0);    opacity: 1; }
}

/* Sticky modal header */
.wtr-modal-top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 20px 28px;
	border-bottom: 1px solid #eaedf0;
	flex-shrink: 0;
	background: #fff;
}

.wtr-modal-top__info { flex: 1; min-width: 0; }

.wtr-modal-heading {
	font-size: 20px !important;
	font-weight: 800 !important;
	color: #0d1b2a !important;
	margin: 0 0 2px !important;
	line-height: 1.2 !important;
}

.wtr-modal-trip-name {
	font-size: 13px;
	color: #6b7280;
	margin: 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.wtr-modal-close-btn {
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 38px !important;
	height: 38px !important;
	min-width: 38px !important;
	border-radius: 50% !important;
	border: 2px solid #dde3ec !important;
	background: #ffffff !important;
	color: #5a6a7e !important;
	cursor: pointer !important;
	flex-shrink: 0 !important;
	margin-left: 16px;
	padding: 0 !important;
	line-height: 1 !important;
	box-shadow: none !important;
	outline: none !important;
	transition: border-color .18s, color .18s, background .18s !important;
}
.wtr-modal-close-btn:hover {
	border-color: #f0a0a0 !important;
	background: #fff4f4 !important;
	color: #c0392b !important;
}
.wtr-modal-close-btn svg {
	display: block !important;
	pointer-events: none !important;
	flex-shrink: 0 !important;
}

/* Scrollable body */
.wtr-modal-body {
	flex: 1;
	overflow-y: auto;
	padding: 28px;
	-webkit-overflow-scrolling: touch;
}
.wtr-modal-body::-webkit-scrollbar       { width: 6px; }
.wtr-modal-body::-webkit-scrollbar-track { background: #f1f5f9; }
.wtr-modal-body::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }

/* Form area separator */
.wtr-form-area {
	border-top: 1px solid #eaedf0;
	padding-top: 28px;
	margin-top: 8px;
}

/* ---- Alerts ------------------------------------------------------- */
.wtr-alert {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	padding: 14px 18px;
	border-radius: 8px;
	font-size: 14px;
	line-height: 1.5;
	margin-bottom: 20px;
}
.wtr-alert svg { flex-shrink: 0; margin-top: 1px; }
.wtr-alert--success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.wtr-alert--error   { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

/* ---- Form --------------------------------------------------------- */
.wtr-form-wrap         { margin-top: 20px; }
.wtr-form-wrap[hidden] { display: none; }
.wtr-form { display: flex; flex-direction: column; gap: 18px; }

.wtr-fields-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.wtr-field { display: flex; flex-direction: column; gap: 6px; }

.wtr-label {
	font-size: 13px;
	font-weight: 700;
	color: #374151;
	display: flex;
	align-items: center;
	gap: 5px;
}

.wtr-req  { color: #ef4444; font-size: 13px; }
.wtr-hint { font-size: 11px; font-weight: 400; color: #9ca3af; margin-left: 2px; }

.wtr-input,
.wtr-textarea {
	width: 100%;
	padding: 10px 13px;
	border: 1.5px solid #d1d5db;
	border-radius: 7px;
	font-size: 14px;
	color: #0d1b2a;
	background: #fff;
	outline: none;
	transition: border-color .2s, box-shadow .2s;
	box-sizing: border-box;
	font-family: inherit;
}
.wtr-input:focus,
.wtr-textarea:focus {
	border-color: #1b2340;
	box-shadow: 0 0 0 3px rgba(27,35,64,.1);
}
.wtr-input.wtr-invalid,
.wtr-textarea.wtr-invalid {
	border-color: #ef4444;
	box-shadow: 0 0 0 3px rgba(239,68,68,.1);
}
.wtr-textarea { resize: vertical; min-height: 110px; }

/* ---- Inline field error messages ---------------------------------- */
.wtr-field-error {
	font-size: 12px;
	color: #ef4444;
	font-weight: 600;
	min-height: 0;
	display: block;
}
.wtr-field-error:empty { display: none; }

/* ---- Star picker -------------------------------------------------- */
.wtr-star-picker {
	display: inline-flex;
	flex-direction: row-reverse;
	gap: 2px;
	padding: 4px 0;
}

.wtr-star-input {
	position: absolute;
	left: -9999px;
	opacity: 0;
	pointer-events: none;
}

.wtr-star-lbl {
	font-size: 30px;
	color: #d1d5db;
	cursor: pointer;
	transition: color .12s, transform .1s;
	line-height: 1;
	display: block;
}
.wtr-star-lbl:hover { transform: scale(1.2); }

.wtr-star-picker:hover .wtr-star-lbl          { color: #d1d5db; }
.wtr-star-lbl:hover,
.wtr-star-lbl:hover ~ .wtr-star-lbl           { color: #f0a500 !important; }
.wtr-star-input:checked ~ .wtr-star-lbl       { color: #f0a500; }

/* Invalid state for star picker */
.wtr-star-picker.wtr-invalid .wtr-star-lbl { color: #fca5a5; }

/* ---- Upload zone -------------------------------------------------- */
.wtr-upload-zone {
	position: relative;
	border: 2px dashed #d1d5db;
	border-radius: 10px;
	min-height: 110px;
	background: #fff;
	transition: border-color .2s, background .2s;
	overflow: hidden;
	cursor: pointer;
}
.wtr-upload-zone:hover,
.wtr-upload-zone.drag-over { border-color: #1b2340; background: #f1f5f9; }

.wtr-file-input {
	position: absolute;
	inset: 0;
	width: 100%; height: 100%;
	opacity: 0;
	cursor: pointer;
	z-index: 2;
}

.wtr-upload-prompt {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 20px;
	color: #9ca3af;
	font-size: 14px;
	pointer-events: none;
}
.wtr-upload-prompt svg { opacity: .5; }

.wtr-preview-grid { display: flex; flex-wrap: wrap; gap: 10px; padding: 12px; }

.wtr-preview-item {
	position: relative;
	width: 80px; height: 80px;
	border-radius: 8px;
	overflow: hidden;
	border: 2px solid #e5e7eb;
}
.wtr-preview-item img { width: 100%; height: 100%; object-fit: cover; display: block; }

.wtr-preview-remove {
	position: absolute;
	top: 3px; right: 3px;
	width: 20px; height: 20px;
	border-radius: 50%;
	background: rgba(0,0,0,.65);
	color: #fff;
	border: none;
	cursor: pointer;
	font-size: 13px;
	line-height: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0;
	transition: background .15s;
	z-index: 3;
}
.wtr-preview-remove:hover { background: #ef4444; }

/* ---- Form footer -------------------------------------------------- */
.wtr-form-footer {
	display: flex;
	align-items: center;
	gap: 16px;
	flex-wrap: wrap;
	padding-top: 6px;
}

.wtr-submit-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: #f1f5f9;
	color: #1b2340 !important;
	border: none;
	border-radius: 8px;
	padding: 12px 26px;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	transition: background .2s, transform .1s;
	line-height: 1;
}
.wtr-submit-btn:hover  { background: #e2e8f0; color: #1b2340 !important; }
.wtr-submit-btn:active { transform: scale(.98); }
.wtr-submit-btn:disabled { background: #9ca3af; cursor: not-allowed; color: #fff !important; }

.wtr-form-note { display: flex; align-items: center; gap: 5px; font-size: 12px; color: #9ca3af; margin: 0; }
.wtr-form-note svg { flex-shrink: 0; }

/* ---- Responsive --------------------------------------------------- */
@media (max-width: 900px) {
	.wtr-modal-box {
		width: 90vw;
		max-width: 90vw;
		max-height: 90vh;
		border-radius: 14px;
	}
	.wtr-modal-top  { padding: 16px 20px; }
	.wtr-modal-body { padding: 20px; }
}

@media (max-width: 680px) {
	.wtr-fields-2col { grid-template-columns: 1fr; }

	.wtr-summary-block {
		flex-direction: column;
		align-items: flex-start;
		gap: 20px;
		padding: 18px 20px;
	}
	.wtr-summary-bars { width: 100%; }

	.wtr-card-top { flex-wrap: wrap; }
	.wtr-card-rating { flex-direction: row; align-items: center; width: 100%; gap: 8px; }

	.wtr-big-avg { font-size: 42px; }

	.wtr-form-footer { flex-direction: column; align-items: flex-start; }
	.wtr-submit-btn  { width: 100%; justify-content: center; }

	.wtr-teaser-actions { flex-direction: column; }
	.wtr-view-all-btn,
	.wtr-write-btn { width: 100%; justify-content: center; }
}

/* =====================================================================
   PHOTO LIGHTBOX — full-screen image viewer
   ===================================================================== */

.wtr-lightbox {
	position: fixed;
	inset: 0;
	z-index: 9999999;   /* above the review modal (z-index: 999999) */
	display: flex;
	align-items: center;
	justify-content: center;
	animation: wtrFadeIn .18s ease;
}
.wtr-lightbox[hidden] { display: none; }

/* Semi-transparent backdrop */
.wtr-lb-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, .88);
	cursor: zoom-out;
}

/* Centred image container — sits above backdrop */
.wtr-lb-inner {
	position: relative;
	z-index: 1;
	max-width: 92vw;
	max-height: 92vh;
	display: flex;
	align-items: center;
	justify-content: center;
}

.wtr-lb-img {
	display: block;
	max-width: 92vw;
	max-height: 88vh;
	border-radius: 10px;
	object-fit: contain;
	box-shadow: 0 24px 80px rgba(0, 0, 0, .6);
	animation: wtrSlideUp .2s ease;
}

/* Close button — top-right of image */
.wtr-lb-close {
	position: absolute;
	top: -14px;
	right: -14px;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	border: 2px solid #dde3ec;
	background: #fff;
	color: #374151;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0;
	box-shadow: 0 2px 12px rgba(0, 0, 0, .25);
	transition: background .15s, color .15s, border-color .15s;
	z-index: 2;
}
.wtr-lb-close:hover {
	background: #fff4f4;
	border-color: #f0a0a0;
	color: #c0392b;
}
.wtr-lb-close svg { pointer-events: none; }

/* Prev / Next arrows */
.wtr-lb-arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 42px;
	height: 42px;
	border-radius: 50%;
	border: 2px solid rgba(255,255,255,.25);
	background: rgba(0,0,0,.45);
	color: #fff;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0;
	transition: background .15s, border-color .15s;
	z-index: 3;
}
.wtr-lb-arrow:hover { background: rgba(0,0,0,.7); border-color: rgba(255,255,255,.6); }
.wtr-lb-arrow svg   { pointer-events: none; flex-shrink: 0; }
.wtr-lb-prev { left:  -60px; }
.wtr-lb-next { right: -60px; }

/* On narrow viewports collapse arrows inside the image */
@media (max-width: 640px) {
	.wtr-lb-prev { left:  8px; }
	.wtr-lb-next { right: 8px; }
	.wtr-lb-arrow { width: 36px; height: 36px; }
}

/* Dot indicators */
.wtr-lb-dots {
	position: absolute;
	bottom: -28px;
	left: 50%;
	transform: translateX(-50%);
	display: flex;
	gap: 6px;
	align-items: center;
}
.wtr-lb-dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: rgba(255,255,255,.4);
	cursor: pointer;
	transition: background .2s, transform .2s;
}
.wtr-lb-dot--active {
	background: #fff;
	transform: scale(1.25);
}

/* Image fade on slide change */
.wtr-lb-img {
	transition: opacity .13s ease;
}

/* ---- Submit-button loading spinner ---------------------------------- */
@keyframes wtr-spin {
	to { transform: rotate(360deg); }
}
.wtr-spin {
	animation: wtr-spin .7s linear infinite;
	flex-shrink: 0;
}
