/* =========================================
   SITE REVIEWS GALLERY — FRONT STYLES
   ========================================= */

/* ===== Базовые цвета ===== */
:root {
	--srg-blue: #1f5b9f;
	--srg-blue-dark: #0f3f78;
	--srg-blue-deep: #123d73;
	--srg-gold: #e1b323;
	--srg-text: #4e4e4e;
	--srg-text-dark: #2e2e2e;
	--srg-border: #d9d9d9;
	--srg-border-soft: #e6e6e6;
	--srg-bg: #f3f3f3;
	--srg-white: #ffffff;
	--srg-overlay: rgba(0, 0, 0, 0.62);
}

/* ===== Общие ===== */
.srg-review-form-wrap,
.srg-reviews-list-wrap,
.srg-review-gallery-wrap {
	font-family: Arial, Helvetica, sans-serif;
	color: var(--srg-text);
}

.srg-review-form-wrap {
	width: 100%;
	max-width: 100%;
	margin: 0 auto;
}

.srg-label {
	display: block;
	margin: 0 0 7px;
	font-size: 0;
	line-height: 0;
}

/* =========================================
   FORM / POPUP CONTENT
   ========================================= */

.srg-review-form-wrap {
	width: 100%;
	max-width: 100%;
	margin: 0 auto;
	font-family: Arial, Helvetica, sans-serif;
	color: #4e4e4e;
}

.srg-review-form-box {
	width: 100%;
	max-width: 100%;
}

.srg-review-form-title {
	margin: 0 0 20px;
	font-size: 24px;
	line-height: 1.2;
	font-weight: 700;
	color: var(--srg-blue);
}

.srg-form-row {
	margin-bottom: 10px;
}

.srg-form-row-rating {
	margin-bottom: 16px;
}

.srg-label {
	display: block;
	margin: 0 0 6px;
	font-size: 0;
	line-height: 0;
}

.srg-input,
.srg-textarea {
	display: block;
	width: 100%;
	box-sizing: border-box;
	border: 1px solid #1C5491!important;
	border-radius: 7px!important;
	background: #fff;
	color: #555;
	font-family: inherit;
	font-size: 15px;
	line-height: 1.4;
	padding-left: 14px;
	padding-right: 14px;
	outline: none;
	box-shadow: none;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.srg-input {
	height: 35px;
	padding-top: 0;
	padding-bottom: 0;
}

.srg-textarea {
	min-height: 89px;
	padding-top: 12px;
	padding-bottom: 12px;
	resize: vertical;
}

.srg-input::placeholder,
.srg-textarea::placeholder {
	color: #9a9a9a;
	opacity: 1;
}

.srg-input:focus,
.srg-textarea:focus {
	border-color: #4f82b6;
	box-shadow: 0 0 0 1px rgba(79, 130, 182, 0.12);
}

/* ===== Звёзды в форме ===== */
.srg-rating-input {
	display: flex;
	align-items: center;
	gap: 4px;
}

.srg-rating-star {
	margin: 0;
	padding: 0;
	border: none;
	background: transparent;
	color: #D1D1D1;
	font-size: 34px;
	line-height: 1;
	cursor: pointer;
	appearance: none;
	box-shadow: none;
	outline: none;
	transition: transform 0.15s ease, opacity 0.15s ease;
}

.srg-rating-star:hover {
	/*transform: scale(1.03);*/
	background: transparent;
}

.srg-rating-star.is-active {
	color: var(--srg-gold);
	background: transparent;
}

/* ===== Поле загрузки ===== */
.srg-file-input {
	display: block;
	width: 100%;
	box-sizing: border-box;

	font-size: 14px;
	color: #8a8a8a;

	border: 1px solid #d7d7d7;
	border-radius: 7px;
	background: #fff;

	height: 35px;
	line-height: 35px;

	padding: 0;
	position: relative;
}
.srg-file-input::before {
	content: '';
	position: absolute;
	left: 120px; /* подогнать под ширину кнопки */
	top: 0;
	bottom: 0;
	width: 1px;
	background: #d7d7d7;
}

.srg-file-field {
	display: flex;
	align-items: stretch;
	width: 100%;
	height: 35px;
	border: 1px solid #d7d7d7;
	border-radius: 7px;
	overflow: hidden;
	background: #fff;
}

.srg-file-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	min-width: 118px;
	height: 100%;
	padding: 0 18px;
	margin: 0;
	position: relative;

	background: #fff;
	color: var(--srg-blue);
	font-size: 15px;
	line-height: 1;
	white-space: nowrap;
	cursor: pointer;

	box-sizing: border-box;
	border-right: 0px solid #1C5491;
	box-shadow: inset 0 0 0 1px #1C5491;
	border-radius: 7px 0 0 7px;
}

.srg-file-button span {
	position: relative;
	z-index: 2;
	display: inline-block;
}

.srg-file-button:hover {
	background: #f7fbff;
}

.srg-file-button input {
	position: absolute;
	inset: 0;
	opacity: 0;
	cursor: pointer;
	z-index: 3;
}

.srg-file-text {
	flex: 1 1 auto;
	display: flex;
	align-items: center;
	min-width: 0;
	padding: 0 14px;
	font-size: 14px;
	line-height: 1;
	color: #9a9a9a;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	background: #fff;
}
/* ===== Подстройка popup под Elementor ===== */
.elementor-popup-modal .dialog-widget-content,
.elementor-popup-modal .dialog-message {
	border-radius: 10px;
}

.elementor-popup-modal .dialog-message {
	padding: 20px 20px 18px;
}

.elementor-popup-modal .dialog-close-button {
	top: 14px;
	right: 14px;
	font-size: 22px;
	color: #222;
}

.elementor-popup-modal .dialog-close-button:hover {
	color: #000;
}

/* центрирование */
.srg-form-submit-row {
	text-align: center;
	padding-top: 16px;
	margin-bottom: 0;
}

/* кнопка */
.srg-submit-button {
	display: inline-block;
	min-width: 140px;
	height: 40px;
	padding: 0 26px;

	border: none;
	border-radius: 8px;

	background: linear-gradient(180deg, #2f6fa7 0%, #1f4f7f 100%);
	color: #fff;

	font-size: 14px;
	line-height: 40px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.3px;
	text-align: center;

	cursor: pointer;

	box-shadow: 0 2px 4px rgba(0,0,0,0.08);
	transition: all 0.2s ease;
}

/* hover */
.srg-submit-button:hover {
	background: linear-gradient(180deg, #3479b8 0%, #255b91 100%);
}

/* active (нажатие) */
.srg-submit-button:active {
	transform: translateY(1px);
	box-shadow: 0 1px 2px rgba(0,0,0,0.12);
}

/* disabled */
.srg-submit-button:disabled {
	opacity: 0.65;
	cursor: not-allowed;
	box-shadow: none;
}

/* =========================================
   THANK YOU SCREEN
   ========================================= */

.srg-thank-you-screen {
	width: 100%;
}

.srg-thank-you {
	text-align: center;
	padding: 28px 0 16px;
}

.srg-thank-you-icon {
	display: none;
}

.srg-thank-you-title {
	margin: 0 0 20px;
	font-size: 22px;
	line-height: 1.25;
	font-weight: 700;
	color: var(--srg-blue);
}

.srg-thank-you-text {
	margin: 0;
	font-size: 14px;
	line-height: 1.5;
	color: #666;
	max-width: 520px;
	margin-left: auto;
	margin-right: auto;
}

/* Если захочешь в thank-you отдельно кнопку через HTML —
   класс уже стилизован */
.srg-thank-you .srg-submit-button,
.srg-thank-you .srg-home-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 79px;
	height: 27px;
	padding: 0 16px;
	margin-top: 22px;
	border: none;
	border-radius: 7px;
	background: var(--srg-blue);
	color: #fff;
	font-size: 13px;
	font-weight: 700;
	line-height: 1;
	text-transform: uppercase;
	text-decoration: none;
	transition: background 0.2s ease;
}

.srg-thank-you .srg-submit-button:hover,
.srg-thank-you .srg-home-button:hover {
	background: var(--srg-blue-dark);
	color: #fff;
}

/* =========================================
   REVIEWS LIST
   ========================================= */

.srg-reviews-list-wrap {
	width: 100%;
}

.srg-reviews-list {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 16px;
}

.srg-review-card {
	background: #f8f8f8;
	border: 1px solid #D1D1D1;
	border-radius: 8px;
	padding: 24px 24px 24px;
	min-height: 199px;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

.srg-review-header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 20px;
}

.srg-review-name {
	flex: 1 1 auto;
	min-width: 0;
	font-size: 18px;
	line-height: 1.25;
	font-weight: 400;
	color: var(--srg-text-dark);
	word-break: break-word;
	padding-top: 1px;
}

.srg-review-rating {
	flex: 0 0 auto;
	padding-top: 1px;
}

.srg-review-text {
	font-size: 16px;
	line-height: 1.38;
	font-weight: 400;
	color: #5b5b5b;
	margin: 0;
	word-break: break-word;

	display: -webkit-box;
	-webkit-line-clamp: 6;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.srg-review-images {
	margin-top: 0;
	flex: 0 0 auto;
}

.srg-review-divider {
	height: 1px;
	margin: 10px 0 10px;
	background: #d8d8d8;
	flex: 0 0 auto;
}

.srg-no-reviews {
	padding: 20px;
	border: 1px solid var(--srg-border);
	border-radius: 8px;
	background: #fafafa;
	text-align: center;
	font-size: 14px;
	color: #777;
	grid-column: 1 / -1;
}

.srg-review-photos {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
}

.srg-review-photos a {
	display: block;
	width: 34px;
	height: 34px;
	flex: 0 0 34px;
	border-radius: 6px;
	overflow: hidden;
	text-decoration: none;
	background: #e9e9e9;
}

.srg-review-photos img {
	display: block;
	width: 100%;
	height: 100%!important;
	object-fit: cover;
	object-position: center center;
	border-radius: 6px;
}



/* ===== Stars display ===== */
.srg-stars {
	display: flex;
	align-items: center;
	gap: 1px;
}

.srg-star {
	color: #d7d7d7;
	font-size: 18px;
	line-height: 1;
}

.srg-star.is-active {
	color: #D8BC1F;
}

/* ===== Review photos ===== */
.srg-review-photos {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
}

.srg-review-photos a {
	display: block;
	width: 34px;
	height: 34px;
	border-radius: 6px;
	overflow: hidden;
	text-decoration: none;
}

.srg-review-photos img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 6px;
}

/* ===== Load more ===== */
.srg-reviews-load-more-wrap {
	text-align: center;
	padding-top: 36px;
}

.srg-load-more-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 99px;
	height: 29px;
	padding: 0 18px;
	border: 1px solid #7da0c5;
	border-radius: 7px;
	background: transparent;
	color: var(--srg-blue);
	font-size: 13px;
	line-height: 1;
	font-weight: 700;
	text-transform: uppercase;
	cursor: pointer;
	transition: all 0.2s ease;
}

.srg-load-more-button:hover {
	background: #f7fbff;
	border-color: #5c87b7;
	color: var(--srg-blue-dark);
}

.srg-load-more-button.is-loading,
.srg-load-more-button:disabled {
	opacity: 0.7;
	cursor: wait;
}
/* =========================================
   GALLERY
   ========================================= */

.srg-review-gallery-wrap {
	width: 100%;
	margin-bottom: 24px;
	position: relative;
}

.srg-review-gallery {
	position: relative;
	width: 100%;
	padding: 0 0;
}

.srg-review-gallery.swiper {
	overflow: hidden;
	width: 100%;
}

.srg-review-gallery .swiper-wrapper {
	display: flex;
	align-items: stretch;
}

.srg-review-gallery .swiper-slide,
.srg-gallery-item {
	height: auto;
}

.srg-gallery-item a {
	display: block;
	width: 100%;
	height: 112px;
	border-radius: 8px;
	overflow: hidden;
	text-decoration: none;
	background: #e9e9e9;
}

.srg-gallery-item img {
	display: block;
	width: 100%;
	height: 112px;
	object-fit: cover;
	object-position: center center;
	border-radius: 8px;
}

/* ===== Стрелки ===== */
.srg-swiper-button-prev,
.srg-swiper-button-next {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 34px;
	height: 34px;
	margin: 0;
	border-radius: 50%;
	background: rgba(31, 91, 159, 0.96);
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	z-index: 20;
	transition: background 0.2s ease, opacity 0.2s ease;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.srg-swiper-button-prev:hover,
.srg-swiper-button-next:hover {
	background: rgba(15, 63, 120, 1);
}

.srg-swiper-button-prev {
	left: 12px;
}

.srg-swiper-button-next {
	right: 12px;
}

/* Убираем стандартные иконки Swiper */
.srg-swiper-button-prev::after,
.srg-swiper-button-next::after {
	content: '';
	display: block;
	width: 10px;
	height: 10px;
	border-top: 2px solid #fff;
	border-right: 2px solid #fff;
	font-size: 0;
	line-height: 0;
}

.srg-swiper-button-prev::after {
	transform: rotate(-135deg);
	margin-left: 3px;
}

.srg-swiper-button-next::after {
	transform: rotate(45deg);
	margin-right: 3px;
}

.srg-swiper-button-disabled {
	opacity: 0.35;
	cursor: default;
	pointer-events: none;
}
/* =========================================
   LIGHTBOX
   ========================================= */

.srg-lightbox-overlay {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(0, 0, 0, 0.82);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 30px;
	box-sizing: border-box;
}

.srg-lightbox-inner {
	position: relative;
	width: 100%;
	max-width: 1200px;
	max-height: 90vh;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 18px;
}

.srg-lightbox-stage {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	max-width: 1000px;
	max-height: 90vh;
}

.srg-lightbox-image {
	display: block;
	max-width: 100%;
	max-height: 90vh;
	border-radius: 8px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.28);
	background: #fff;
}

.srg-lightbox-close {
	position: absolute;
	top: -42px;
	right: 0;
	width: 34px;
	height: 34px;
	padding: 0;
	border: none;
	background: transparent;
	color: #fff;
	font-size: 36px;
	line-height: 34px;
	font-weight: 400;
	cursor: pointer;
	transition: opacity 0.2s ease;
	z-index: 30;
}

.srg-lightbox-close:hover {
	opacity: 0.8;
}

.srg-lightbox-nav {
	position: relative;
	flex: 0 0 42px;
	width: 42px;
	height: 42px;
	padding: 0;
	border: none;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.16);
	cursor: pointer;
	transition: background 0.2s ease, opacity 0.2s ease;
}

.srg-lightbox-nav:hover {
	background: rgba(255, 255, 255, 0.24);
}

.srg-lightbox-nav::after {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	width: 12px;
	height: 12px;
	border-top: 2px solid #fff;
	border-right: 2px solid #fff;
	transform-origin: center;
}

.srg-lightbox-prev::after {
	transform: translate(-35%, -50%) rotate(-135deg);
}

.srg-lightbox-next::after {
	transform: translate(-65%, -50%) rotate(45deg);
}

.srg-lightbox-counter {
	position: absolute;
	left: 50%;
	bottom: -34px;
	transform: translateX(-50%);
	padding: 4px 10px;
	border-radius: 999px;
	background: rgba(0, 0, 0, 0.45);
	color: #fff;
	font-size: 13px;
	line-height: 1.2;
	white-space: nowrap;
}

body.srg-lightbox-open {
	overflow: hidden;
}

@media (max-width: 767px) {
	.srg-lightbox-overlay {
		padding: 16px;
	}

	.srg-lightbox-inner {
		gap: 10px;
	}

	.srg-lightbox-nav {
		flex: 0 0 34px;
		width: 34px;
		height: 34px;
	}

	.srg-lightbox-nav::after {
		width: 10px;
		height: 10px;
	}

	.srg-lightbox-close {
		top: -36px;
		font-size: 32px;
	}

	.srg-lightbox-counter {
		bottom: -28px;
		font-size: 12px;
		padding: 4px 8px;
	}
}

/* =========================================
   ELEMENTOR POPUP TUNING
   ========================================= */

/* Эти стили помогают приблизить popup к скриншоту,
   если форма вставлена внутрь Elementor Popup */
.elementor-popup-modal .dialog-widget-content,
.elementor-popup-modal .dialog-message {
	border-radius: 10px;
}

.elementor-popup-modal .dialog-message {
	padding: 26px 26px 30px;
}

.elementor-popup-modal .dialog-close-button {
	top: 18px;
	right: 18px;
	font-size: 22px;
	color: #222;
}

.elementor-popup-modal .dialog-close-button:hover {
	color: #000;
}

/* ===== Upload progress ===== */

.srg-upload-progress {
	display: none;
	margin: 14px 0 4px;
}

.srg-upload-progress-bar {
	width: 100%;
	height: 10px;
	background: #e6edf5;
	border-radius: 999px;
	overflow: hidden;
}

.srg-upload-progress-fill {
	width: 0;
	height: 100%;
	background: var(--srg-blue);
	border-radius: 999px;
	transition: width 0.2s ease;
}

.srg-upload-progress-text {
	margin-top: 8px;
	font-size: 13px;
	line-height: 1.2;
	color: var(--srg-blue);
	font-weight: 700;
	text-align: right;
}

.srg-upload-status-text {
	margin-top: 6px;
	font-size: 12px;
	line-height: 1.3;
	color: #6f7d8c;
	text-align: right;
}

/* =========================================
   RESPONSIVE
   ========================================= */

@media (max-width: 1024px) {
	.srg-reviews-list {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 767px) {
	.srg-review-form-title {
		font-size: 22px;
	}

	.srg-rating-star {
		font-size: 28px;
	}

	.srg-reviews-list {
		grid-template-columns: 1fr;
		gap: 12px;
	}

	.srg-review-card {
		min-height: auto;
	}

	.srg-gallery-item img {
		height: 92px;
	}

	.elementor-popup-modal .dialog-message {
		padding: 22px 18px 24px;
	}
	
	.srg-gallery-item a,
.srg-gallery-item img {
	height: 92px;
}

.srg-swiper-button-prev {
	left: -10px;
}

.srg-swiper-button-next {
	right: -10px;
}

.srg-swiper-button-prev,
.srg-swiper-button-next {
	width: 28px;
	height: 28px;
}
	
}