/*=============== GOOGLE FONTS ===============*/
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;700&family=Playfair+Display:wght@700&display=swap');

/*=============== CSS VARIABLES ===============*/
:root {
	/* Colors */
	--header-height: 3.5rem;
	--first-color: #1a1a2e;
	--accent-color: #d4af37;
	--text-color: #e0e0e0;
	--title-color: #ffffff;
	--body-color: #0f0f1a;
	--container-color: #1a1a2e;
	--border-color: #2a2a3e;

	/* Font and typography */
	--body-font: 'Manrope', sans-serif;
	--title-font: 'Playfair Display', serif;
	--biggest-font-size: 2.25rem;
	--h1-font-size: 1.75rem;
	--h2-font-size: 1.25rem;
	--h3-font-size: 1rem;
	--normal-font-size: 0.938rem;
	--small-font-size: 0.813rem;

	/* Font weight */
	--font-medium: 500;
	--font-bold: 700;

	/* z-index */
	--z-tooltip: 10;
	--z-fixed: 100;
}

/*=============== BASE ===============*/
* {
	box-sizing: border-box;
	padding: 0;
	margin: 0;
}

html {
	scroll-behavior: smooth;
}

body {
	font-family: var(--body-font);
	font-size: var(--normal-font-size);
	background-color: var(--body-color);
	color: var(--text-color);
	transition: background-color 0.4s;
}

h1,
h2,
h3 {
	color: var(--title-color);
	font-family: var(--title-font);
	font-weight: var(--font-bold);
}

ul {
	list-style: none;
}

a {
	text-decoration: none;
}

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

/*=============== REUSABLE CSS CLASSES ===============*/
.container {
	max-width: 1140px;
	margin-left: 1.5rem;
	margin-right: 1.5rem;
}

/*=============== HEADER ===============*/
.header {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	background-color: var(--container-color);
	box-shadow: 0 2px 8px hsla(0, 0%, 0%, 0.05);
	z-index: var(--z-fixed);
}

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

.header__logo {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	color: var(--title-color);
	font-weight: var(--font-bold);
	font-family: var(--title-font);
}

.header__logo span {
	font-size: 1.25rem;
}

.header__toggle,
.header__close {
	font-size: 1.25rem;
	color: var(--title-color);
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}

/* Navigation for mobile devices */
@media screen and (max-width: 767px) {
	.header__menu {
		position: fixed;
		top: 0;
		right: -100%;
		width: 100%;
		height: 100%;
		background-color: var(--container-color);
		padding: 6rem 2rem 4rem;
		transition: right 0.4s;
	}
}

.header__list {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 2.5rem;
}

.header__link {
	color: var(--title-color);
	font-weight: var(--font-medium);
	transition: color 0.3s;
}

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

.header__close {
	position: absolute;
	top: 1rem;
	right: 1.5rem;
}

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

/*=============== FOOTER ===============*/
.footer {
	background-color: var(--container-color);
	padding: 4rem 0 2rem;
	border-top: 1px solid var(--border-color);
}

.footer__container {
	display: flex;
	flex-direction: column;
	gap: 3rem;
}

.footer__group {
	display: grid;
	gap: 2.5rem;
}

.footer__logo {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	color: var(--title-color);
	font-weight: var(--font-bold);
	font-family: var(--title-font);
	font-size: 1.25rem;
	margin-bottom: 1rem;
}

.footer__description {
	font-size: var(--normal-font-size);
	line-height: 1.6;
}

.footer__title {
	font-size: var(--h3-font-size);
	margin-bottom: 1rem;
}

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

.footer__link {
	color: var(--text-color);
	transition: color 0.3s;
}

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

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

.footer__contact-item {
	display: flex;
	align-items: center;
	gap: 0.75rem;
}

.footer__contact-item i {
	color: var(--accent-color);
	width: 20px;
	height: 20px;
}

.footer__copyright {
	text-align: center;
	font-size: var(--small-font-size);
	border-top: 1px solid var(--border-color);
	padding-top: 2rem;
}

/*=============== BREAKPOINTS ===============*/
/* For medium devices */
@media screen and (min-width: 576px) {
	.footer__group {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media screen and (min-width: 768px) {
	.header__nav {
		height: calc(var(--header-height) + 1.5rem);
	}
	.header__toggle,
	.header__close {
		display: none;
	}
	.header__list {
		flex-direction: row;
		gap: 2.5rem;
	}
	.footer__group {
		grid-template-columns: repeat(4, 1fr);
	}
}

/* For large devices */
@media screen and (min-width: 1024px) {
	.container {
		margin-left: auto;
		margin-right: auto;
	}
	.header__list {
		gap: 3.5rem;
	}
}

/*=============== HERO ===============*/
.hero {
	padding: 4rem 0 2rem;
	overflow: hidden; /* Для анимации */
	height: 100vh;
}

.hero__container {
	height: 100%;
	display: grid;
	gap: 3rem;
	align-items: center;
	justify-content: center;
}

.hero__content {
	text-align: center;
}

.hero__title {
	font-size: var(--h1-font-size);
	line-height: 1.3;
	margin-bottom: 1.5rem;
	/* Анимация */
	opacity: 0;
	transform: translateY(20px);
	animation: fadeInUp 1s 0.5s forwards;
}

.hero__description {
	font-size: var(--h3-font-size);
	line-height: 1.7;
	margin-bottom: 2.5rem;
	max-width: 600px;
	margin-left: auto;
	margin-right: auto;
	/* Анимация */
	opacity: 0;
	transform: translateY(20px);
	animation: fadeInUp 1s 0.7s forwards;
}

.hero__button {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	background-color: var(--accent-color);
	color: var(--first-color);
	padding: 1rem 2rem;
	border-radius: 4px;
	font-weight: var(--font-bold);
	transition: background-color 0.3s, transform 0.3s;
	/* Анимация */
	opacity: 0;
	transform: translateY(20px);
	animation: fadeInUp 1s 0.9s forwards;
}

.hero__button:hover {
	background-color: #c9a330;
	transform: translateY(-2px);
}

.hero__button i {
	width: 20px;
	height: 20px;
}

.hero__image {
	display: flex;
	justify-content: center;
	/* Анимация */
	opacity: 0;
	transform: translateY(20px);
	animation: fadeInUp 1s 1.1s forwards;
}

.hero__image img {
	width: 100%;
	max-width: 450px;
	border-radius: 8px;
}

/* Анимация появления */
@keyframes fadeInUp {
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/*=============== BREAKPOINTS ===============*/
/* For medium devices */
@media screen and (min-width: 768px) {
	.hero {
		padding: 6rem 0 4rem;
	}
	.hero__container {
		grid-template-columns: 1fr 1fr;
		gap: 2rem;
	}
	.hero__content {
		text-align: left;
	}
	.hero__description {
		margin-left: 0;
		margin-right: 0;
	}
}

/* For large devices */
@media screen and (min-width: 1024px) {
	:root {
		--biggest-font-size: 3rem;
		--h1-font-size: 2.25rem;
		--h2-font-size: 1.5rem;
		--h3-font-size: 1.25rem;
		--normal-font-size: 1rem;
		--small-font-size: 0.875rem;
	}

	.hero__container {
		gap: 4rem;
	}

	.hero__title {
		margin-bottom: 2rem;
	}

	.hero__description {
		margin-bottom: 3rem;
	}
}

/*=============== SERVICES ===============*/
.section {
	padding: 4rem 0 2rem;
}

.services__header {
	text-align: center;
	margin-bottom: 3rem;
	max-width: 650px;
	margin-left: auto;
	margin-right: auto;
}

.services__title {
	font-size: var(--h1-font-size);
	margin-bottom: 1rem;
}

.services__subtitle {
	font-size: var(--normal-font-size);
	line-height: 1.6;
}

.services__grid {
	display: grid;
	gap: 2rem;
}

.services__card {
	background-color: var(--container-color);
	padding: 2.5rem 2rem;
	border-radius: 8px;
	border: 1px solid var(--border-color);
	text-align: center;
	transition: transform 0.3s, box-shadow 0.3s;
}

.services__card:hover {
	transform: translateY(-8px);
	box-shadow: 0 8px 24px hsla(228, 66%, 45%, 0.1);
}

.services__card-icon {
	display: inline-flex;
	padding: 0.75rem;
	border-radius: 50%;
	background-color: hsl(44, 74%, 20%);
	margin-bottom: 1.5rem;
}

.services__card-icon i {
	color: var(--accent-color);
	width: 32px;
	height: 32px;
}

.services__card-title {
	font-size: var(--h3-font-size);
	margin-bottom: 0.75rem;
}

.services__card-description {
	font-size: var(--normal-font-size);
	line-height: 1.6;
}

/*=============== BREAKPOINTS ===============*/
/* For medium devices */
@media screen and (min-width: 576px) {
	.services__grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media screen and (min-width: 768px) {
	.section {
		padding: 6rem 0 4rem;
	}
	.services__grid {
		grid-template-columns: repeat(3, 1fr);
	}
}

/*=============== BLOG ===============*/
.blog__header {
	text-align: center;
	margin-bottom: 3rem;
	max-width: 650px;
	margin-left: auto;
	margin-right: auto;
}

.blog__title {
	font-size: var(--h1-font-size);
	margin-bottom: 1rem;
}

.blog__subtitle {
	font-size: var(--normal-font-size);
	line-height: 1.6;
}

.blog__grid {
	display: grid;
	gap: 2rem;
}

.blog__card {
	background-color: var(--container-color);
	border-radius: 8px;
	overflow: hidden;
	border: 1px solid var(--border-color);
	transition: transform 0.3s, box-shadow 0.3s;
	display: flex;
	flex-direction: column;
}

.blog__card:hover {
	transform: translateY(-8px);
	box-shadow: 0 8px 24px hsla(228, 66%, 45%, 0.1);
}

.blog__card-image img {
	width: 100%;
	height: 220px;
	object-fit: cover;
}

.blog__card-content {
	padding: 1.5rem;
	display: flex;
	flex-direction: column;
	flex-grow: 1; /* Позволяет контенту занимать все доступное место */
}

.blog__card-category {
	display: inline-block;
	background-color: hsl(44, 74%, 20%);
	color: var(--accent-color);
	padding: 0.25rem 0.75rem;
	border-radius: 4px;
	font-size: var(--small-font-size);
	font-weight: var(--font-bold);
	margin-bottom: 1rem;
	align-self: flex-start; /* Чтобы фон не растягивался */
}

.blog__card-title {
	font-size: var(--h3-font-size);
	margin-bottom: 0.75rem;
	font-family: var(
		--body-font
	); /* Делаем заголовок карточки более читабельным */
	font-weight: var(--font-bold);
}

.blog__card-description {
	line-height: 1.6;
	margin-bottom: 1.5rem;
	flex-grow: 1; /* Занимает доступное пространство, прижимая ссылку вниз */
}

.blog__card-link {
	color: var(--accent-color);
	font-weight: var(--font-bold);
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	transition: gap 0.3s;
}

.blog__card-link:hover {
	gap: 0.5rem;
}

/*=============== BREAKPOINTS ===============*/
/* For medium devices */
@media screen and (min-width: 576px) {
	.blog__grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media screen and (min-width: 768px) {
	.blog__grid {
		grid-template-columns: repeat(3, 1fr);
	}
}

/*=============== CASES ===============*/
.cases {
	background-color: var(--container-color);
	border-top: 1px solid var(--border-color);
	border-bottom: 1px solid var(--border-color);
}

.cases__header {
	text-align: center;
	margin-bottom: 3rem;
	max-width: 650px;
	margin-left: auto;
	margin-right: auto;
}

.cases__title {
	font-size: var(--h1-font-size);
	margin-bottom: 1rem;
}

.cases__subtitle {
	font-size: var(--normal-font-size);
	line-height: 1.6;
}

.cases__grid {
	display: grid;
	gap: 2rem;
}

.cases__card {
	background-color: var(--body-color);
	border-radius: 8px;
	overflow: hidden;
	border: 1px solid var(--border-color);
	transition: transform 0.3s;
}

.cases__card:hover {
	transform: translateY(-8px);
}

.cases__card-image img {
	width: 100%;
	height: 220px;
	object-fit: cover;
}

.cases__card-content {
	padding: 1.5rem;
}

.cases__card-title {
	font-size: var(--h3-font-size);
	margin-bottom: 0.75rem;
}

.cases__card-description {
	line-height: 1.6;
	margin-bottom: 1.5rem;
}

.cases__card-result {
	border-top: 1px solid var(--border-color);
	padding-top: 1.5rem;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
}

.cases__result-value {
	font-size: var(--h1-font-size);
	font-family: var(--title-font);
	color: var(--accent-color);
	font-weight: var(--font-bold);
}

.cases__result-label {
	font-size: var(--small-font-size);
	color: var(--text-color);
}

/*=============== BREAKPOINTS ===============*/
/* For medium devices */
@media screen and (min-width: 576px) {
	.cases__grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media screen and (min-width: 768px) {
	.cases__grid {
		grid-template-columns: repeat(3, 1fr);
	}
}

/*=============== ABOUT ===============*/
.about__container {
	display: grid;
	gap: 3rem;
	align-items: center;
}

.about__image img {
	width: 100%;
	border-radius: 8px;
}

.about__title {
	font-size: var(--h1-font-size);
	margin-bottom: 1.5rem;
}

.about__description {
	line-height: 1.7;
	margin-bottom: 2rem;
}

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

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

.about__list-item i {
	color: var(--accent-color);
	width: 20px;
	height: 20px;
	flex-shrink: 0; /* Чтобы иконка не сжималась */
	margin-top: 3px;
}

/*=============== BREAKPOINTS ===============*/
/* For medium devices */
@media screen and (min-width: 768px) {
	.about__container {
		grid-template-columns: repeat(2, 1fr);
		gap: 4rem;
	}
}

/*=============== CONTACT ===============*/
.contact__header {
	text-align: center;
	margin-bottom: 3rem;
	max-width: 650px;
	margin-left: auto;
	margin-right: auto;
}

.contact__title {
	font-size: var(--h1-font-size);
	margin-bottom: 1rem;
}

.contact__subtitle {
	font-size: var(--normal-font-size);
	line-height: 1.6;
}

.contact__form {
	max-width: 600px;
	margin: 0 auto;
}

.contact__group {
	display: grid;
	gap: 1.5rem;
}

.contact__field {
	display: flex;
	flex-direction: column;
	margin-bottom: 1.5rem;
}

.contact__label {
	font-size: var(--small-font-size);
	font-weight: var(--font-medium);
	color: var(--title-color);
	margin-bottom: 0.5rem;
}

.contact__input {
	width: 100%;
	padding: 1rem;
	border: 1px solid var(--border-color);
	border-radius: 4px;
	background-color: var(--container-color);
	color: var(--text-color);
	font-family: var(--body-font);
	font-size: var(--normal-font-size);
	outline: none;
	transition: border-color 0.3s, box-shadow 0.3s;
}

.contact__input::placeholder {
	color: #6a6a7a;
}

.contact__input:focus {
	border-color: var(--accent-color);
	box-shadow: 0 0 0 3px hsla(44, 74%, 56%, 0.2);
}

.contact__checkbox {
	display: flex;
	align-items: flex-start;
	gap: 0.75rem;
	margin-bottom: 2rem;
}

.contact__checkbox-input {
	appearance: none;
	width: 18px;
	height: 18px;
	border: 2px solid var(--border-color);
	border-radius: 4px;
	margin-top: 3px;
	flex-shrink: 0;
	cursor: pointer;
	position: relative;
	transition: background-color 0.3s, border-color 0.3s;
}

.contact__checkbox-input:checked {
	background-color: var(--accent-color);
	border-color: var(--accent-color);
}

.contact__checkbox-input:checked::before {
	content: '';
	position: absolute;
	top: 2px;
	left: 5px;
	width: 4px;
	height: 8px;
	border: solid var(--first-color);
	border-width: 0 2px 2px 0;
	transform: rotate(45deg);
}

.contact__checkbox-label {
	font-size: var(--small-font-size);
	line-height: 1.6;
	cursor: pointer;
}

.contact__checkbox-label a {
	color: var(--accent-color);
	text-decoration: underline;
}

.contact__button {
	width: 100%;
	padding: 1rem;
	background-color: var(--accent-color);
	color: var(--first-color);
	border: none;
	border-radius: 4px;
	font-size: var(--normal-font-size);
	font-weight: var(--font-bold);
	cursor: pointer;
	transition: background-color 0.3s;
}

.contact__button:hover {
	background-color: #c9a330;
}

.contact__message {
	font-size: var(--normal-font-size);
	padding: 1rem;
	border-radius: 4px;
	margin-bottom: 1.5rem;
	text-align: center;
	display: none; /* Скрыто по умолчанию */
}

.contact__message--success {
	background-color: hsl(142, 60%, 25%);
	color: hsl(142, 80%, 75%);
	display: block; /* Показываем при успехе */
}

/*=============== BREAKPOINTS ===============*/
/* For medium devices */
@media screen and (min-width: 576px) {
	.contact__group {
		grid-template-columns: repeat(2, 1fr);
	}
}

/*=============== COOKIE POPUP ===============*/
.cookie {
	position: fixed;
	bottom: -100%; /* Скрыто по умолчанию */
	left: 0;
	width: 100%;
	background-color: var(--container-color);
	box-shadow: 0 -2px 16px hsla(0, 0%, 0%, 0.1);
	padding: 1.5rem;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1rem;
	text-align: center;
	z-index: var(--z-fixed);
	transition: bottom 0.4s;
}

.cookie.show-cookie {
	bottom: 0;
}

.cookie__text {
	font-size: var(--small-font-size);
}

.cookie__text a {
	color: var(--accent-color);
	text-decoration: underline;
}

.cookie__button {
	background-color: var(--accent-color);
	color: var(--first-color);
	padding: 0.75rem 1.5rem;
	border: none;
	border-radius: 4px;
	font-weight: var(--font-medium);
	cursor: pointer;
	transition: background-color 0.3s;
}

.cookie__button:hover {
	background-color: #c9a330;
}

/*=============== POLICY PAGES ===============*/
.pages {
	padding: 6rem 0 4rem;
}

.pages .container {
	max-width: 800px;
}

.pages h1,
.pages h2 {
	font-family: var(--title-font);
	color: var(--title-color);
	margin-bottom: 1rem;
}

.pages h1 {
	font-size: 1.5rem;
	margin-bottom: 2rem;
}

.pages h2 {
	font-size: 1.5rem;
	margin-top: 2.5rem;
}

.pages p,
.pages li {
	font-size: var(--normal-font-size);
	line-height: 1.8;
	color: var(--text-color);
	margin-bottom: 1.5rem;
}

.pages ul {
	padding-left: 1.5rem;
	list-style: disc;
}

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

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

.pages strong {
	color: var(--title-color);
	font-weight: var(--font-bold);
}

/*=============== BREAKPOINTS ===============*/
/* For medium devices */
@media screen and (min-width: 768px) {
	.cookie {
		flex-direction: row;
		justify-content: space-between;
		padding: 1.5rem 2rem;
	}
}
