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

/*=============== CSS VARIABLES ===============*/
:root {
	/* Colors */
	--bg-color: #0d0c22;
	--primary-color: #6f30ff;
	--primary-color-alt: #5a28cc;
	--text-color: #e0e0e0;
	--text-color-light: #a0a0a0;
	--container-color: #161531;

	/* Typography */
	--body-font: 'Inter', sans-serif;
	--title-font: 'Poppins', sans-serif;
	--h1-font-size: 2.5rem;
	--h2-font-size: 1.5rem;
	--h3-font-size: 1.25rem;
	--normal-font-size: 1rem;
	--small-font-size: 0.875rem;

	/* z-index */
	--z-header: 100;
	--z-fixed: 100;
}

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

html {
	scroll-behavior: smooth;
}

body {
	font-family: var(--body-font);
	font-size: var(--normal-font-size);
	background-color: var(--bg-color);
	color: var(--text-color);
	line-height: 1.6;
}

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

ul {
	list-style: none;
}

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

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

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

/*=============== HEADER ===============*/
.header {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	background-color: rgba(13, 12, 34, 0.8);
	backdrop-filter: blur(10px);
	z-index: var(--z-header);
	border-bottom: 1px solid var(--container-color);
}

.header__container {
	height: 6rem;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

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

.header__logo span {
	transition: color 0.3s ease;
}

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

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

/*=============== NAV ===============*/
.nav__list {
	display: flex;
	gap: 2.5rem;
}

.nav__link {
	position: relative;
	font-weight: 500;
	color: var(--text-color-light);
	transition: color 0.3s ease;
}

.nav__link:hover {
	color: var(--text-color);
}

.nav__link::after {
	content: '';
	position: absolute;
	bottom: -5px;
	left: 0;
	width: 0;
	height: 2px;
	background-color: var(--primary-color);
	transition: width 0.3s ease;
}

.nav__link:hover::after {
	width: 100%;
}

/*=============== FOOTER ===============*/
.footer {
	background-color: var(--container-color);
	padding-top: 4rem;
	margin-top: 5rem;
}

.footer__container {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 2.5rem;
	row-gap: 3rem;
	padding-bottom: 4rem;
	border-bottom: 1px solid var(--bg-color);
}

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

.footer__description {
	color: var(--text-color-light);
	font-size: var(--small-font-size);
}

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

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

.footer__link {
	color: var(--text-color-light);
	font-size: var(--small-font-size);
	transition: color 0.3s ease;
}

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

.footer__list--contact li {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	color: var(--text-color-light);
	font-size: var(--small-font-size);
}

.footer__list--contact i {
	color: var(--primary-color);
	width: 20px;
	height: 20px;
}

.footer__copy {
	padding: 1.5rem 0;
	text-align: center;
	font-size: var(--small-font-size);
	color: var(--text-color-light);
}

/*=============== BREAKPOINTS ===============*/
/* For medium devices */
@media screen and (max-width: 768px) {
	.header__burger {
		position: relative;
		z-index: 999;
		display: block;
	}
	.nav {
		position: fixed;
		top: 0;
		right: -100%;
		width: 70%;
		height: 100vh;
		background-color: var(--container-color);
		padding: 6rem 2rem 2rem;
		transition: right 0.4s ease-in-out;
		z-index: var(--z-fixed);
	}
	.nav.is-active {
		right: 0;
	}
	.nav__list {
		flex-direction: column;
		gap: 2rem;
		text-align: center;
	}
	.nav__link {
		font-size: 1.25rem;
		color: var(--text-color);
	}
}

/* For small devices */
@media screen and (max-width: 350px) {
	.container {
		padding-left: 1rem;
		padding-right: 1rem;
	}
}

/*=============== HERO ===============*/
.hero {
	padding-top: 8rem; /* Учитываем высоту хедера */
	position: relative;
	overflow: hidden;
}

.hero__canvas {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 1;
}

.hero__container {
	position: relative;
	z-index: 2;
	display: grid;
	grid-template-columns: 1fr 1fr;
	align-items: center;
	gap: 3rem;
}

.hero__title {
	font-size: var(--h1-font-size);
	line-height: 1.3;
	margin-bottom: 1.5rem;
}

.hero__description {
	color: var(--text-color-light);
	margin-bottom: 2.5rem;
	max-width: 500px;
}

.button {
	display: inline-block;
	background-color: var(--primary-color);
	color: #fff;
	padding: 1rem 2rem;
	border-radius: 0.5rem;
	font-weight: 500;
	font-family: var(--title-font);
	transition: background-color 0.3s ease, transform 0.3s ease;
}

.button:hover {
	background-color: var(--primary-color-alt);
	transform: translateY(-3px);
}

.hero__image img {
	width: 100%;
	border-radius: 1rem;
}

/*=============== BREAKPOINTS (Hero) ===============*/
@media screen and (max-width: 992px) {
	:root {
		--h1-font-size: 2rem;
	}
}

@media screen and (max-width: 768px) {
	.hero {
		padding-top: 6rem;
	}
	.hero__container {
		grid-template-columns: 1fr;
		text-align: center;
	}
	.hero__data {
		order: 2; /* Текст будет под картинкой */
	}
	.hero__image {
		order: 1;
		max-width: 400px;
		margin: 0 auto 2rem;
	}
	.hero__description {
		margin-left: auto;
		margin-right: auto;
	}
}

/*=============== REUSABLE CSS (add to existing) ===============*/
.section {
	padding: 6rem 0 2rem;
}

.section__title,
.section__subtitle {
	text-align: center;
}

.section__title {
	font-size: var(--h2-font-size);
	margin-bottom: 1rem;
}

.section__subtitle {
	color: var(--text-color-light);
	margin-bottom: 4rem;
	max-width: 600px;
	margin-left: auto;
	margin-right: auto;
}

/*=============== HOW IT WORKS ===============*/
.how-it-works__container {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 2.5rem;
	position: relative;
}

/* Connecting line */
.how-it-works__container::before {
	content: '';
	position: absolute;
	top: 40px; /* Adjust vertical position */
	left: 10%;
	right: 10%;
	height: 2px;
	background: repeating-linear-gradient(
		90deg,
		var(--primary-color),
		var(--primary-color) 6px,
		transparent 6px,
		transparent 12px
	);
	z-index: -1;
}

.how-it-works__step {
	background-color: var(--container-color);
	padding: 2.5rem 2rem;
	border-radius: 1rem;
	text-align: center;
	border: 1px solid transparent;
	transition: transform 0.3s ease, border-color 0.3s ease;
}

.how-it-works__step:hover {
	transform: translateY(-8px);
	border-color: var(--primary-color);
}

.how-it-works__icon-wrapper {
	position: relative;
	width: 80px;
	height: 80px;
	background-color: var(--bg-color);
	border-radius: 50%;
	display: flex;
	justify-content: center;
	align-items: center;
	margin: 0 auto 2rem;
	border: 2px solid var(--primary-color);
}

.how-it-works__icon-wrapper i {
	width: 36px;
	height: 36px;
	color: var(--primary-color);
}

.how-it-works__number {
	position: absolute;
	top: -10px;
	right: -10px;
	background-color: var(--primary-color);
	color: #fff;
	width: 30px;
	height: 30px;
	border-radius: 50%;
	display: flex;
	justify-content: center;
	align-items: center;
	font-weight: 600;
	font-family: var(--title-font);
	border: 2px solid var(--bg-color);
}

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

.how-it-works__description {
	font-size: var(--small-font-size);
	color: var(--text-color-light);
	line-height: 1.7;
}

/*=============== BREAKPOINTS (How it works) ===============*/
@media screen and (max-width: 992px) {
	.how-it-works__container {
		grid-template-columns: 1fr;
		gap: 2rem;
	}
	.how-it-works__container::before {
		display: none; /* Hide line on vertical layout */
	}
}

/*=============== FEATURES ===============*/
.features__container {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 4rem;
	align-items: center;
}

.features__image img {
	max-width: 450px;
	border-radius: 1rem;
	width: 100%;
}

/* Override default centered text for this section */
.features__data .section__title,
.features__data .section__subtitle {
	text-align: left !important;
	margin-left: 0 !important;
	margin-right: 0 !important;
}

.features__list {
	display: flex;
	flex-direction: column;
	gap: 2.5rem;
}

.features__item {
	display: flex;
	align-items: flex-start;
	gap: 1.5rem;
}

.features__item-icon {
	flex-shrink: 0;
	width: 50px;
	height: 50px;
	background-color: var(--container-color);
	border-radius: 0.75rem;
	display: flex;
	justify-content: center;
	align-items: center;
}

.features__item-icon i {
	color: var(--primary-color);
	width: 24px;
	height: 24px;
}

.features__item-content h3 {
	font-size: 1.1rem;
	margin-bottom: 0.5rem;
}

.features__item-content p {
	font-size: var(--small-font-size);
	color: var(--text-color-light);
	line-height: 1.7;
}

/*=============== BREAKPOINTS (Features) ===============*/
@media screen and (max-width: 992px) {
	.features__container {
		grid-template-columns: 1fr;
		gap: 3rem;
	}
	.features__image {
		order: -1; /* Image will be on top on mobile */
		max-width: 450px;
		margin: 0 auto;
	}
	.features__data .section__title,
	.features__data .section__subtitle {
		text-align: center !important;
		margin-left: auto !important;
		margin-right: auto !important;
	}
}

/*=============== EXAMPLES ===============*/
.examples__tabs {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 1rem;
	margin-bottom: 3rem;
	flex-wrap: wrap;
}

.examples__tab-button {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	background-color: var(--container-color);
	color: var(--text-color-light);
	border: 1px solid var(--container-color);
	padding: 0.75rem 1.5rem;
	border-radius: 2rem;
	cursor: pointer;
	font-family: var(--title-font);
	font-weight: 500;
	transition: all 0.3s ease;
}

.examples__tab-button:hover {
	background-color: var(--primary-color);
	color: #fff;
}

.examples__tab-button.is-active {
	background-color: var(--primary-color);
	color: #fff;
	border-color: var(--primary-color-alt);
}

.examples__tab-button i {
	width: 20px;
	height: 20px;
}

.examples__content {
	display: none;
	grid-template-columns: repeat(2, 1fr);
	gap: 3rem;
	align-items: center;
	animation: fadeIn 0.5s ease-in-out;
}

.examples__content.is-active {
	display: grid;
}

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

.examples__image img {
	border-radius: 1rem;
	width: 100%;
}

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

.examples__data p {
	color: var(--text-color-light);
	margin-bottom: 2rem;
}

.examples__data ul {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.examples__data ul li {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	font-size: var(--small-font-size);
}

.examples__data ul li i {
	color: var(--primary-color);
	width: 20px;
	height: 20px;
}

/*=============== BREAKPOINTS (Examples) ===============*/
@media screen and (max-width: 768px) {
	.examples__content {
		grid-template-columns: 1fr;
	}
}

/*=============== FAQ ===============*/
.faq__container {
	max-width: 768px;
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

.faq__item {
	background-color: var(--container-color);
	border-radius: 0.75rem;
	border: 1px solid var(--container-color);
	transition: border-color 0.3s;
}

.faq__header {
	display: flex;
	align-items: center;
	gap: 1rem;
	padding: 1.25rem 1.5rem;
	cursor: pointer;
}

.faq__icon {
	color: var(--primary-color);
	width: 24px;
	height: 24px;
}

.faq__question {
	font-size: var(--normal-font-size);
	font-weight: 500;
	font-family: var(--body-font);
	flex-grow: 1;
}

.faq__arrow {
	width: 20px;
	height: 20px;
	transition: transform 0.4s;
}

.faq__content {
	max-height: 0;
	overflow: hidden;
	transition: max-height 0.4s ease-out, padding 0.4s ease-out;
}

.faq__answer {
	padding: 0 1.5rem 1.5rem 4.5rem; /* 1.5rem (left padding) + 1rem (gap) + 24px (icon width) */
	font-size: var(--small-font-size);
	color: var(--text-color-light);
	line-height: 1.7;
	border-top: 1px solid var(--bg-color);
}

/* Active state for accordion */
.faq__item.is-active {
	border-color: var(--primary-color);
}

.faq__item.is-active .faq__arrow {
	transform: rotate(180deg);
}

.faq__item.is-active .faq__content {
	max-height: 200px; /* Adjust if your content is taller */
}

.faq__item.is-active .faq__answer {
	padding-top: 1.5rem;
}

/*=============== CONTACT ===============*/
.contact__container {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 4rem;
	align-items: center;
}

.contact__data .section__title,
.contact__data .section__subtitle {
	text-align: left !important;
	margin-left: 0 !important;
}

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

.contact__form-group {
	position: relative;
}

.contact__form-input {
	width: 100%;
	padding: 1.25rem 1rem;
	background-color: var(--container-color);
	border: 1px solid var(--container-color);
	border-radius: 0.5rem;
	color: var(--text-color);
	font-size: var(--normal-font-size);
	outline: none;
	transition: border-color 0.3s;
}

.contact__form-label {
	position: absolute;
	top: 1.25rem;
	left: 1rem;
	color: var(--text-color-light);
	pointer-events: none;
	transition: top 0.3s, font-size 0.3s, color 0.3s;
}

/* Input focus styles */
.contact__form-input:focus {
	border-color: var(--primary-color);
}

.contact__form-input:focus + .contact__form-label,
.contact__form-input:not(:placeholder-shown) + .contact__form-label {
	top: -0.75rem;
	left: 0.75rem;
	font-size: var(--small-font-size);
	color: var(--primary-color);
	background-color: var(--bg-color);
	padding: 0 0.25rem;
}

.contact__form-checkbox {
	display: flex;
	align-items: flex-start;
	gap: 0.75rem;
}

.contact__form-checkbox-input {
	appearance: none;
	width: 20px;
	height: 20px;
	border: 2px solid var(--primary-color);
	border-radius: 0.25rem;
	margin-top: 0.15rem;
	cursor: pointer;
	position: relative;
	flex-shrink: 0;
}

.contact__form-checkbox-input:checked {
	background-color: var(--primary-color);
}

.contact__form-checkbox-input:checked::before {
	content: '✓';
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	color: #fff;
	font-weight: bold;
	font-size: 14px;
}

.contact__form-checkbox-label {
	font-size: var(--small-font-size);
	color: var(--text-color-light);
	cursor: pointer;
}

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

.contact__form-button {
	width: 100%;
	border: none;
	cursor: pointer;
}

.contact__form-message {
	font-size: var(--small-font-size);
	text-align: center;
	color: var(--primary-color);
	height: 1.5rem; /* Reserve space */
}

/*=============== BREAKPOINTS (Contact) ===============*/
@media screen and (max-width: 992px) {
	.contact__container {
		grid-template-columns: 1fr;
		gap: 3rem;
	}
	.contact__data {
		text-align: center;
	}
	.contact__data .section__title,
	.contact__data .section__subtitle {
		text-align: center !important;
		margin-left: auto !important;
		margin-right: auto !important;
	}
}

/*=============== COOKIE POP-UP ===============*/
.cookie {
	position: fixed;
	bottom: -100%; /* Initially hidden */
	left: 0;
	width: 100%;
	background-color: var(--container-color);
	box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.2);
	padding: 1.5rem 0;
	z-index: var(--z-fixed);
	transition: bottom 0.5s ease-in-out;
}

.cookie.is-active {
	bottom: 0;
}

.cookie__container {
	max-width: 1120px;
	margin: 0 auto;
	padding: 0 1.5rem;
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 1.5rem;
}

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

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

.cookie__button {
	background-color: var(--primary-color);
	color: #fff;
	border: none;
	padding: 0.75rem 1.5rem;
	border-radius: 0.5rem;
	cursor: pointer;
	font-family: var(--body-font);
	font-weight: 500;
	transition: background-color 0.3s;
	flex-shrink: 0; /* Prevent button from shrinking */
}

.cookie__button:hover {
	background-color: var(--primary-color-alt);
}

/*=============== BREAKPOINTS (Cookie) ===============*/
@media screen and (max-width: 768px) {
	.cookie__container {
		flex-direction: column;
		text-align: center;
	}
}

/*==================== PAGES (Privacy, Terms, etc.) ====================*/
.pages {
	padding: 8rem 0 4rem; /* Add padding for header */
}

.pages .container {
	max-width: 800px; /* Narrower container for better readability */
}

.pages h1 {
	font-size: 1.5rem;
	margin-bottom: 2rem;
	color: var(--primary-color);
}

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

.pages p {
	color: var(--text-color-light);
	line-height: 1.8;
	margin-bottom: 1.5rem;
}

.pages ul {
	list-style-type: none;
	padding-left: 1.5rem;
	margin-bottom: 1.5rem;
}

.pages ul li {
	color: var(--text-color-light);
	margin-bottom: 1rem;
	position: relative;
}

/* Custom list bullet */
.pages ul li::before {
	content: '•';
	position: absolute;
	left: -1.5rem;
	color: var(--primary-color);
	font-size: 1.25rem;
	line-height: 1;
}

.pages a {
	color: var(--primary-color);
	text-decoration: none;
	font-weight: 500;
	transition: text-decoration 0.3s;
}

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

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