/* ==================== GOOGLE FONTS ==================== */
@import url('https://fonts.googleapis.com/css2?family=Lato:wght@400;700&family=Montserrat:wght@600;700&display=swap');

/* ==================== CSS VARIABLES ==================== */
:root {
	/* Colors */
	--bg-color: #f8f9fa;
	--text-color: #212529;
	--primary-color: #0057ff;
	--secondary-color: #4a90e2;
	--white: #ffffff;
	--border-color: #e9ecef;

	/* Typography */
	--font-family-headings: 'Montserrat', sans-serif;
	--font-family-body: 'Lato', sans-serif;

	/* Other */
	--header-height: 4rem;
	--border-radius: 8px;
	--transition: 0.3s ease;
}

/* ==================== GLOBAL STYLES / RESET ==================== */
*,
*::before,
*::after {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

html {
	scroll-behavior: smooth;
	font-size: 16px; /* 1rem = 16px */
}

body {
	font-family: var(--font-family-body);
	font-size: 1rem;
	line-height: 1.6;
	background-color: var(--bg-color);
	color: var(--text-color);
	overflow-x: hidden;
}

ul {
	list-style: none;
}

a {
	text-decoration: none;
	color: var(--primary-color);
	transition: var(--transition);
}

a:hover {
	opacity: 0.8;
}

img,
svg {
	max-width: 100%;
	height: auto;
}

h1,
h2,
h3,
h4,
h5,
h6 {
	font-family: var(--font-family-headings);
	font-weight: 700;
	color: var(--text-color);
}

.container {
	max-width: 1140px;
	margin-left: auto;
	margin-right: auto;
	padding-left: 1rem;
	padding-right: 1rem;
}

/* ==================== LOGO (REUSABLE) ==================== */
.logo {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	font-family: var(--font-family-headings);
	font-weight: 700;
	font-size: 1.5rem;
	color: var(--text-color);
}

.logo:hover {
	opacity: 1;
}

.logo__svg {
	width: 32px;
	height: 32px;
}

/* ==================== HEADER ==================== */
.header {
	width: 100%;
	background-color: var(--white);
	border-bottom: 1px solid var(--border-color);
	position: fixed;
	top: 0;
	left: 0;
	z-index: 100;
}

.header__container {
	height: var(--header-height);
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.header__burger {
	display: block;
	cursor: pointer;
	background: none;
	border: none;
	color: var(--text-color);
}

.header__nav {
	position: fixed;
	top: var(--header-height);
	right: -100%; /* Hidden by default */
	width: 80%;
	height: calc(100vh - var(--header-height));
	background-color: var(--white);
	box-shadow: -4px 0 15px rgba(0, 0, 0, 0.1);
	transition: var(--transition);
	padding: 2rem;
}

.header__nav--active {
	right: 0; /* Show menu */
}

.header__list {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

.header__link {
	font-family: var(--font-family-headings);
	font-weight: 600;
	color: var(--text-color);
	font-size: 1.1rem;
}

.header__link:hover {
	color: var(--primary-color);
}

.header__link--button {
	display: inline-block;
	background-color: var(--primary-color);
	color: var(--white);
	padding: 0.75rem 1.5rem;
	border-radius: var(--border-radius);
	text-align: center;
}

.header__link--button:hover {
	background-color: var(--secondary-color);
	color: var(--white);
	opacity: 1;
}

.header__item--cta {
	margin-top: 1rem;
}

/* ==================== FOOTER ==================== */
.footer {
	background-color: var(--white);
	border-top: 1px solid var(--border-color);
	padding: 4rem 0 2rem;
	margin-top: 4rem; /* Отступ от контента */
}

.footer__container {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2.5rem;
}

.footer__column--info {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.footer__description {
	font-size: 0.9rem;
	color: #6c757d;
}

.footer__copyright {
	font-size: 0.85rem;
	color: #6c757d;
	margin-top: 1rem;
}

.footer__title {
	font-size: 1.2rem;
	margin-bottom: 1rem;
}

.footer__list {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}

.footer__link {
	font-size: 0.9rem;
	color: #495057;
}

.footer__link:hover {
	color: var(--primary-color);
}

.footer__column--contacts .footer__item {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	font-size: 0.9rem;
	color: #495057;
}

.footer__icon {
	width: 18px;
	height: 18px;
	color: var(--secondary-color);
	flex-shrink: 0;
}

/* ==================== MAIN (Placeholder) ==================== */
.main {
	/* Добавляем отступ сверху, равный высоте хедера */
	padding-top: var(--header-height);
}

/* ==================== MEDIA QUERIES (Mobile-First) ==================== */

/* Tablet */
@media (min-width: 768px) {
	.header__burger {
		display: none;
	}

	.header__nav {
		position: static;
		width: auto;
		height: auto;
		background: none;
		box-shadow: none;
		padding: 0;
		transform: none; /* Reset transform */
		right: 0; /* Reset position */
	}

	.header__list {
		flex-direction: row;
		align-items: center;
		gap: 2rem;
	}

	.header__link {
		font-size: 1rem;
	}

	.header__item--cta {
		margin-top: 0;
		margin-left: 1rem;
	}

	.header__link--button {
		padding: 0.5rem 1rem;
	}

	.footer__container {
		grid-template-columns: repeat(2, 1fr);
	}
}

/* Desktop */
@media (min-width: 1024px) {
	.footer__container {
		/* 2.5fr для инфо, 1.5fr для навигации, 2fr для документов, 2fr для контактов */
		grid-template-columns: 2.5fr 1.5fr 2fr 2fr;
		gap: 2rem;
	}
}

/* ==================== REUSABLE BUTTON ==================== */
.btn {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.85rem 1.75rem;
	border-radius: var(--border-radius);
	font-family: var(--font-family-headings);
	font-weight: 600;
	font-size: 1rem;
	text-decoration: none;
	border: none;
	cursor: pointer;
	transition: var(--transition);
	white-space: nowrap;
}

.btn--primary {
	background-color: var(--primary-color);
	color: var(--white);
}

.btn--primary:hover {
	background-color: var(--secondary-color);
	color: var(--white);
	transform: translateY(-2px);
	opacity: 1;
}

.btn__icon {
	width: 20px;
	height: 20px;
}

/* ==================== HERO SECTION ==================== */
.hero {
	/* Отступ от хедера + дополнительный отступ */
	padding: 3rem 0;
}

.hero__container {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2rem;
	align-items: center;
	text-align: center;
}

.hero__title {
	font-size: 2.5rem; /* 40px */
	line-height: 1.2;
	margin-bottom: 1rem;
}

.hero__description {
	font-size: 1.125rem; /* 18px */
	color: #495057;
	margin-bottom: 2rem;
}

.hero__image-wrapper {
	width: 100%;
	max-width: 500px;
	margin: 0 auto;
}

.hero__image {
	width: 100%;
	border-radius: var(--border-radius);
	box-shadow: 0 10px 30px rgba(0, 87, 255, 0.1);
}

/* --- Hero Animation --- */
.hero--animate {
	opacity: 0;
	transform: translateY(20px);
	transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.hero--animate.is-visible {
	opacity: 1;
	transform: translateY(0);
}

/* ==================== HERO MEDIA QUERIES ==================== */

/* Планшеты и десктопы */
@media (min-width: 768px) {
	.hero {
		padding: 4rem 0;
	}

	.hero__container {
		grid-template-columns: 1fr 1fr;
		gap: 3rem;
		text-align: left;
	}

	.hero__title {
		font-size: 3rem; /* 48px */
	}

	.hero__content {
		/* Текст слева */
		order: 1;
	}

	.hero__image-wrapper {
		/* Картинка справа */
		order: 2;
	}
}

/* Большие десктопы */
@media (min-width: 1024px) {
	.hero {
		padding: 5rem 0;
	}
	.hero__title {
		font-size: 3.5rem; /* 56px */
	}
}

/* ==================== REUSABLE SECTION HEADER ==================== */
.section-header {
	text-align: center;
	max-width: 650px;
	margin: 0 auto 3rem auto;
}

.section-header__subtitle {
	display: inline-block;
	font-family: var(--font-family-headings);
	font-weight: 600;
	color: var(--primary-color);
	background-color: rgba(0, 87, 255, 0.1);
	padding: 0.25rem 0.75rem;
	border-radius: var(--border-radius);
	font-size: 0.9rem;
	margin-bottom: 0.5rem;
}

.section-header__title {
	font-size: 2.25rem; /* 36px */
	line-height: 1.2;
	margin-bottom: 0.75rem;
}

.section-header__description {
	font-size: 1.05rem;
	color: #495057;
}

/* ==================== SERVICES SECTION ==================== */
.services {
	padding: 3rem 0;
	background-color: var(--white); /* Чередуем фон секций */
}

.services__grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 1.5rem;
}

.services__card {
	background-color: var(--bg-color); /* Светлый фон для карточек */
	border: 1px solid var(--border-color);
	padding: 2rem;
	border-radius: var(--border-radius);
	text-align: center;
	transition: var(--transition);
}

.services__card:hover {
	transform: translateY(-5px);
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.05);
}

.services__icon-wrapper {
	display: inline-flex;
	justify-content: center;
	align-items: center;
	width: 60px;
	height: 60px;
	border-radius: 50%;
	background-color: var(--primary-color);
	margin-bottom: 1.5rem;
}

.services__icon {
	width: 30px;
	height: 30px;
	color: var(--white);
}

.services__card-title {
	font-size: 1.3rem;
	margin-bottom: 0.75rem;
}

.services__card-description {
	font-size: 0.95rem;
	color: #495057;
	line-height: 1.7;
}

/* ==================== SERVICES MEDIA QUERIES ==================== */

/* Планшеты */
@media (min-width: 576px) {
	.services__grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

/* Десктопы */
@media (min-width: 992px) {
	.services {
		padding: 5rem 0;
	}

	.services__grid {
		grid-template-columns: repeat(3, 1fr);
	}

	.section-header__title {
		font-size: 2.5rem; /* 40px */
	}
}

/* ==================== ABOUT US SECTION ==================== */
.about {
	padding: 3rem 0;
	/* Секция снова на --bg-color (чередование) */
}

.about__container {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2rem;
	align-items: center;
}

.about__header {
	/* Сбрасываем центрирование от .section-header */
	text-align: left;
	margin-left: 0;
	margin-right: 0;
	margin-bottom: 2rem;
}

.about__text {
	font-size: 1rem;
	color: #495057;
	margin-bottom: 2rem;
	line-height: 1.7;
}

.about__list {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

.about__list-item {
	display: flex;
	align-items: flex-start;
	gap: 1rem;
}

.about__list-icon {
	width: 24px;
	height: 24px;
	color: var(--primary-color);
	flex-shrink: 0;
	margin-top: 4px;
}

.about__list-item strong {
	font-family: var(--font-family-headings);
	font-weight: 700;
	color: var(--text-color);
	font-size: 1.05rem;
}

.about__list-item p {
	font-size: 0.9rem;
	color: #495057;
}

.about__image-wrapper {
	width: 100%;
	max-width: 500px;
	margin: 0 auto;
}

.about__image {
	width: 100%;
	border-radius: var(--border-radius);
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.07);
}

/* ==================== ABOUT MEDIA QUERIES ==================== */

/* Планшеты и десктопы */
@media (min-width: 768px) {
	.about__container {
		grid-template-columns: 1fr 1fr;
		gap: 3rem;
	}
}

/* Большие десктопы */
@media (min-width: 1024px) {
	.about {
		padding: 5rem 0;
	}
}

/* ==================== BLOG SECTION ==================== */
.blog {
	padding: 3rem 0;
	background-color: var(--white); /* Чередуем фон */
}

.blog__grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 1.5rem;
}

.blog__card {
	background-color: var(--bg-color);
	border: 1px solid var(--border-color);
	border-radius: var(--border-radius);
	overflow: hidden; /* Чтобы скруглить углы картинки */
	display: flex;
	flex-direction: column;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
	transition: var(--transition);
}

.blog__card:hover {
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.07);
	transform: translateY(-5px);
}

.blog__image-wrapper {
	display: block;
	width: 100%;
	/* Сохраняем пропорции 16:9 */
	aspect-ratio: 16 / 9;
	overflow: hidden;
}

.blog__image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.4s ease;
}

.blog__card:hover .blog__image {
	transform: scale(1.05);
}

.blog__content {
	padding: 1.5rem;
	display: flex;
	flex-direction: column;
	flex-grow: 1; /* Карточка растягивается на всю высоту */
}

.blog__category {
	font-family: var(--font-family-headings);
	font-size: 0.8rem;
	font-weight: 600;
	color: var(--secondary-color);
	margin-bottom: 0.5rem;
	text-transform: uppercase;
}

.blog__card-title {
	font-size: 1.25rem;
	line-height: 1.4;
	margin-bottom: 0.75rem;
}

.blog__card-title a {
	color: var(--text-color);
}

.blog__card-title a:hover {
	color: var(--primary-color);
	opacity: 1;
}

.blog__card-description {
	font-size: 0.95rem;
	color: #495057;
	margin-bottom: 1.5rem;
	flex-grow: 1; /* Описание занимает место, отодвигая ссылку вниз */
}

.blog__read-more {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	font-family: var(--font-family-headings);
	font-weight: 600;
	color: var(--primary-color);
	font-size: 0.95rem;
}

.blog__read-more:hover {
	opacity: 0.8;
}

.blog__icon {
	width: 18px;
	height: 18px;
	transition: transform 0.3s ease;
}

.blog__read-more:hover .blog__icon {
	transform: translateX(4px);
}

/* ==================== BLOG MEDIA QUERIES ==================== */

/* Планшеты */
@media (min-width: 576px) {
	.blog__grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

/* Десктопы */
@media (min-width: 992px) {
	.blog {
		padding: 5rem 0;
	}

	.blog__grid {
		grid-template-columns: repeat(3, 1fr);
	}
}

/* ==================== FAQ SECTION ==================== */
.faq {
	padding: 3rem 0;
	background-color: var(--bg-color); /* Чередуем фон */
}

.faq__container {
	max-width: 800px; /* Делаем контейнер уже для лучшей читаемости */
}

.faq__contact-link {
	font-weight: 700;
	color: var(--primary-color);
	text-decoration: underline;
}

.faq__accordion {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	margin-top: 3rem;
}

.faq__item {
	background-color: var(--white);
	border: 1px solid var(--border-color);
	border-radius: var(--border-radius);
	overflow: hidden; /* Важно для max-height */
}

.faq__question {
	display: flex;
	justify-content: space-between;
	align-items: center;
	width: 100%;
	padding: 1.5rem;
	background: none;
	border: none;
	cursor: pointer;
	text-align: left;
	font-family: var(--font-family-headings);
	font-weight: 600;
	font-size: 1.1rem;
	color: var(--text-color);
}

.faq__question span {
	flex: 1;
	padding-right: 1rem;
}

.faq__icon {
	width: 20px;
	height: 20px;
	color: var(--primary-color);
	transition: transform 0.3s ease;
	flex-shrink: 0;
}

.faq__answer {
	/* Скрываем ответ по умолчанию */
	max-height: 0;
	overflow: hidden;
	transition: max-height 0.4s ease-out, padding 0.4s ease-out;
}

.faq__answer p {
	padding: 0 1.5rem 1.5rem 1.5rem;
	font-size: 0.95rem;
	color: #495057;
	line-height: 1.7;
}

/* --- Активное состояние --- */
.faq__item.faq--active .faq__answer {
	/* Высота ответа. 200px - с запасом. */
	max-height: 200px;
}

.faq__item.faq--active .faq__icon {
	transform: rotate(180deg);
}

/* ==================== FAQ MEDIA QUERIES ==================== */
@media (min-width: 992px) {
	.faq {
		padding: 5rem 0;
	}
}

/* ==================== CONTACT SECTION ==================== */
.contact {
	padding: 3rem 0;
	background-color: var(--white); /* Чередуем фон */
}

.contact__container {
	display: grid;
	grid-template-columns: 1fr;
	gap: 3rem;
}

.contact__header {
	text-align: left;
	margin: 0 0 1.5rem 0;
}

.contact__text {
	font-size: 1rem;
	color: #495057;
	margin-bottom: 2rem;
	line-height: 1.7;
}

.contact__details {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

.contact__detail-item {
	display: flex;
	align-items: flex-start;
	gap: 1rem;
}

.contact__icon {
	width: 24px;
	height: 24px;
	color: var(--primary-color);
	flex-shrink: 0;
	margin-top: 4px;
}

.contact__detail-item strong {
	font-family: var(--font-family-headings);
	font-weight: 700;
	font-size: 1.05rem;
}

.contact__detail-item p,
.contact__detail-item a {
	font-size: 0.95rem;
	color: #495057;
	text-decoration: none;
}

.contact__detail-item a:hover {
	text-decoration: underline;
}

/* --- Форма --- */
.contact__form {
	background-color: var(--bg-color);
	padding: 2.5rem;
	border-radius: var(--border-radius);
	border: 1px solid var(--border-color);
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.05);
}

.contact__form-title {
	font-size: 1.8rem;
	margin-bottom: 2rem;
	text-align: center;
}

.form__group {
	margin-bottom: 1.5rem;
}

.form__label {
	display: block;
	font-family: var(--font-family-headings);
	font-weight: 600;
	font-size: 0.9rem;
	margin-bottom: 0.5rem;
	color: var(--text-color);
}

.form__input-wrapper {
	position: relative;
}

.form__input {
	width: 100%;
	padding: 0.85rem 1rem;
	padding-left: 2.75rem; /* Место для иконки */
	font-family: var(--font-family-body);
	font-size: 1rem;
	border: 1px solid var(--border-color);
	border-radius: var(--border-radius);
	background-color: var(--white);
	color: var(--text-color);
	transition: var(--transition);
}

.form__input:focus {
	outline: none;
	border-color: var(--primary-color);
	box-shadow: 0 0 0 3px rgba(0, 87, 255, 0.2);
}

.form__input-icon {
	position: absolute;
	left: 1rem;
	top: 50%;
	transform: translateY(-50%);
	width: 20px;
	height: 20px;
	color: #adb5bd;
}

.form__input:focus + .form__input-icon {
	color: var(--primary-color);
}

/* --- Чекбокс --- */
.form__group--checkbox {
	display: flex;
	align-items: flex-start;
	gap: 0.75rem;
	margin-top: 1rem;
}

.form__checkbox {
	width: 1.15em;
	height: 1.15em;
	margin-top: 0.2em;
	flex-shrink: 0;
	accent-color: var(--primary-color); /* Стилизация самого чекбокса */
}

.form__checkbox-label {
	font-size: 0.85rem;
	color: #495057;
	line-height: 1.5;
}

.form__checkbox-label a {
	color: var(--primary-color);
	text-decoration: underline;
}

/* --- Кнопка и Сообщение --- */
.contact__submit {
	width: 100%;
	justify-content: center; /* Центрируем иконку и текст */
}

.form__message {
	/* Скрыто по умолчанию */
	display: none;

	margin-top: 1.5rem;
	padding: 1rem;
	background-color: #d1e7dd; /* Success green */
	border: 1px solid #badbcc;
	color: #0f5132;
	border-radius: var(--border-radius);
	font-size: 0.95rem;
	font-weight: 600;
	text-align: center;

	/* Flex для иконки */
	display: none; /* Переопределяем на flex при показе */
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
}

.form__message.form__message--visible {
	display: flex; /* Показываем сообщение */
}

.form__message-icon {
	width: 20px;
	height: 20px;
	flex-shrink: 0;
}

/* ==================== CONTACT MEDIA QUERIES ==================== */
@media (min-width: 992px) {
	.contact {
		padding: 5rem 0;
	}

	.contact__container {
		grid-template-columns: 1fr 1fr;
		gap: 4rem;
	}
}

/* ==================== COOKIE POPUP ==================== */
.cookie-popup {
	position: fixed;
	bottom: -100%; /* Скрыто по умолчанию */
	left: 0;
	width: 100%;
	background-color: var(--white);
	padding: 1.5rem;
	box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.1);
	border-top: 1px solid var(--border-color);
	z-index: 110; /* Выше хедера */
	transition: bottom 0.5s ease-in-out;
}

/* Класс для показа */
.cookie-popup--visible {
	bottom: 0;
}

.cookie-popup__content {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1rem;
	max-width: 800px;
	margin: 0 auto;
	text-align: center;
}

.cookie-popup__text {
	font-size: 0.9rem;
	color: #495057;
	line-height: 1.5;
}

.cookie-popup__link {
	font-weight: 700;
	text-decoration: underline;
	color: var(--primary-color);
}

.cookie-popup__btn {
	padding: 0.6rem 1.2rem; /* Делаем кнопку чуть меньше */
	font-size: 0.9rem;
}

/* ==================== COOKIE MEDIA QUERIES ==================== */
@media (min-width: 768px) {
	.cookie-popup__content {
		flex-direction: row;
		justify-content: space-between;
		text-align: left;
	}

	.cookie-popup__btn {
		flex-shrink: 0; /* Не даем кнопке сжиматься */
	}
}

/* ==================== PAGES (Privacy, Terms, etc.) ==================== */
.pages {
	/* Відступ від хедера + додатковий відступ */
	padding: calc(var(--header-height) + 3rem) 0 4rem 0;
	background-color: var(--white);
	min-height: 80vh; /* Щоб футер не прилипав до хедера на коротких сторінках */
}

/* Обмежуємо ширину контейнера для кращої читабельності */
.pages .container {
	max-width: 800px;
}

.pages h1 {
	font-size: 1.5rem; /* 40px */
	line-height: 1.2;
	margin-bottom: 2rem;
	color: var(--text-color);
}

.pages h2 {
	font-size: 1.5rem; /* 28px */
	line-height: 1.3;
	margin-top: 2.5rem;
	margin-bottom: 1rem;
	color: var(--text-color);
}

.pages p {
	font-size: 1rem;
	line-height: 1.7;
	color: #495057;
	margin-bottom: 1.5rem;
}

.pages ul {
	list-style: disc; /* Стандартні маркери */
	padding-left: 1.5rem; /* Відступ для маркерів */
	margin-bottom: 1.5rem;
}

.pages li {
	font-size: 1rem;
	line-height: 1.7;
	color: #495057;
	margin-bottom: 0.75rem;
}

.pages strong {
	font-weight: 700;
	color: var(--text-color);
}

.pages a {
	color: var(--primary-color);
	text-decoration: underline;
	font-weight: 600;
}

.pages a:hover {
	text-decoration: none;
	opacity: 0.8;
}
