/*=============== 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 */
	--header-height: 3.5rem;
	--bg-color: #0d1128;
	--bg-color-alt: #161a33;
	--primary-color: #007bff;
	--primary-color-hover: #0056b3;
	--title-color: #ffffff;
	--text-color: #d1d1d1;
	--text-color-light: #a0a0a0;

	/* Fonts */
	--body-font: 'Inter', sans-serif;
	--title-font: 'Poppins', sans-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-semibold: 600;
	--font-bold: 700;

	/* Margins & Paddings */
	--mb-0-5: 0.5rem;
	--mb-1: 1rem;
	--mb-1-5: 1.5rem;
	--mb-2: 2rem;
	--mb-2-5: 2.5rem;

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

@media screen and (min-width: 968px) {
	:root {
		--biggest-font-size: 4rem;
		--h1-font-size: 2.25rem;
		--h2-font-size: 1.5rem;
		--h3-font-size: 1.25rem;
		--normal-font-size: 1rem;
		--small-font-size: 0.875rem;
	}
}

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

html {
	scroll-behavior: smooth;
}

body {
	margin: var(--header-height) 0 0 0;
	font-family: var(--body-font);
	font-size: var(--normal-font-size);
	background-color: var(--bg-color);
	color: var(--text-color);
}

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

ul {
	list-style: none;
}

a {
	text-decoration: none;
}

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

/*=============== REUSABLE CSS CLASSES ===============*/
.container {
	max-width: 1024px;
	margin-left: var(--mb-1-5);
	margin-right: var(--mb-1-5);
}

.section {
	padding: 4.5rem 1rem 2rem;
}

.section__title {
	font-size: var(--h1-font-size);
	color: var(--title-color);
	text-align: center;
	margin-bottom: var(--mb-2);
}

/*=============== HEADER & NAV ===============*/
.header {
	width: 100%;
	background-color: transparent;
	position: fixed;
	top: 0;
	left: 0;
	z-index: var(--z-fixed);
	transition: background-color 0.3s;
}

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

.nav__logo {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	font-family: var(--title-font);
	font-weight: var(--font-bold);
	color: var(--title-color);
	font-size: var(--h2-font-size);
	transition: color 0.3s;
}

.nav__logo svg {
	color: var(--primary-color);
}

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

.nav__toggle,
.nav__close {
	font-size: 1.5rem;
	color: var(--title-color);
	cursor: pointer;
}

@media screen and (max-width: 767px) {
	.nav__menu {
		position: fixed;
		background-color: var(--bg-color-alt);
		top: 0;
		right: -100%;
		width: 80%;
		height: 100%;
		padding: 4rem 2rem 0;
		z-index: var(--z-fixed);
		transition: right 0.4s ease-in-out;
		backdrop-filter: blur(10px);
		-webkit-backdrop-filter: blur(10px);
	}
}

.nav__list {
	display: flex;
	flex-direction: column;
	gap: 2rem;
}

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

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

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

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

/* Change header background on scroll */
.scroll-header {
	background-color: var(--bg-color);
	box-shadow: 0 1px 4px hsla(0, 4%, 15%, 0.1);
}

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

.footer__container {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 2.5rem;
}

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

.footer__logo svg {
	color: var(--primary-color);
}

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

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

.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(--primary-color);
}

.footer__list--contact li {
	display: flex;
	align-items: flex-start;
	gap: 0.75rem;
}

.footer__list--contact i {
	color: var(--primary-color);
	margin-top: 4px; /* Align icon with text */
	flex-shrink: 0;
}

/*=============== MEDIA QUERIES ===============*/
/* For small devices */
@media screen and (max-width: 320px) {
	.container {
		margin-left: var(--mb-1);
		margin-right: var(--mb-1);
	}
}

/* For medium devices */
@media screen and (min-width: 768px) {
	body {
		margin: 0;
	}

	.nav {
		height: calc(var(--header-height) + 1.5rem);
	}
	.nav__toggle,
	.nav__close {
		display: none;
	}
	.nav__list {
		flex-direction: row;
		gap: 2.5rem;
	}
}

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

/*=============== HERO ===============*/
.hero {
	padding-top: 6rem;
	padding-bottom: 4rem;
	background: radial-gradient(
		circle at 30% 107%,
		rgba(0, 123, 255, 0.1),
		transparent 40%
	);
}

.hero__container {
	display: grid;
	gap: 3rem;
	align-items: center;
}

.hero__data {
	text-align: center;
}

.hero__title {
	font-size: var(--h1-font-size);
	font-weight: var(--font-bold);
	line-height: 1.2;
	margin-bottom: var(--mb-1-5);
}

.hero__title-line1 {
	display: block;
	color: var(--text-color);
	font-size: calc(var(--biggest-font-size) * 0.5);
	font-weight: var(--font-medium);
}

.hero__typed-text {
	color: var(--primary-color);
}
/* Blinking cursor effect */
.hero__typed-text::after {
	content: '|';
	animation: blink 1s infinite;
}

@keyframes blink {
	0%,
	100% {
		opacity: 1;
	}
	50% {
		opacity: 0;
	}
}

.hero__description {
	font-size: var(--h3-font-size);
	line-height: 1.6;
	margin-bottom: var(--mb-2-5);
	color: var(--text-color-light);
	max-width: 600px;
	margin-left: auto;
	margin-right: auto;
}

.hero__img {
	width: 100%;
	height: auto;
	justify-self: center;
	opacity: 0.9;
}

/*=============== BUTTONS ===============*/
.button {
	display: inline-block;
	background-color: var(--primary-color);
	color: #fff;
	padding: 1rem 2rem;
	border-radius: 0.5rem;
	font-weight: var(--font-medium);
	transition: background-color 0.3s, transform 0.3s;
}

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

.button--flex {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
}

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

/*=============== MEDIA QUERIES (for Hero section) ===============*/
@media screen and (min-width: 768px) {
	.hero__container {
		grid-template-columns: 1fr 1fr;
		align-items: center;
	}

	.hero__data {
		text-align: left;
	}

	.hero__description {
		margin-left: 0;
		margin-right: 0;
	}
}

@media screen and (min-width: 968px) {
	.hero {
		padding-top: 8rem;
	}
}

/*=============== COURSES ===============*/
.courses {
	background-color: var(--bg-color-alt);
}

.courses__container {
	display: grid;
	gap: 1.5rem;
	padding-top: 1rem;
}

.course-card {
	background-color: var(--bg-color);
	padding: 2rem 1.5rem;
	border-radius: 0.75rem;
	border: 1px solid transparent;
	transition: transform 0.3s, border-color 0.3s;
}

.course-card:hover {
	transform: translateY(-5px);
	border-color: var(--primary-color);
}

.course-card__icon {
	display: inline-block;
	color: var(--primary-color);
	margin-bottom: var(--mb-1);
}

.course-card__icon i {
	width: 40px;
	height: 40px;
}

.course-card__title {
	font-size: var(--h2-font-size);
	margin-bottom: var(--mb-0-5);
}

.course-card__description {
	font-size: var(--normal-font-size);
	color: var(--text-color-light);
	line-height: 1.6;
}

/*=============== MEDIA QUERIES (for Courses section) ===============*/
@media screen and (min-width: 576px) {
	.courses__container {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media screen and (min-width: 968px) {
	.courses__container {
		grid-template-columns: repeat(4, 1fr);
	}
}

/*=============== BENEFITS & ACCORDION ===============*/
.benefits__container {
	display: grid;
	gap: 2.5rem;
	align-items: center;
}

.benefits__image {
	text-align: center;
}

.benefits__img {
	width: 300px;
	max-height: 400px;
	border-radius: 0.75rem;
	object-fit: cover;
}

.benefits__title {
	text-align: left;
	margin-bottom: var(--mb-2);
}

.accordion__item {
	border-bottom: 1px solid var(--bg-color-alt);
	transition: background-color 0.3s;
}
.accordion__item:last-child {
	border-bottom: none;
}

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

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

.accordion__title {
	font-size: var(--h3-font-size);
	font-weight: var(--font-medium);
}

.accordion__chevron {
	margin-left: auto;
	transition: transform 0.4s;
}

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

.accordion__description {
	padding: 0 0 1.5rem 3.5rem; /* 1rem (gap) + 24px (icon width) + .5rem */
	color: var(--text-color-light);
	line-height: 1.6;
}

/* Rotate icon and show content */
.accordion__item.is-open .accordion__chevron {
	transform: rotate(180deg);
}

.accordion__item.is-open .accordion__content {
	max-height: 200px; /* Adjust if content is taller */
}

/*=============== MEDIA QUERIES (for Benefits section) ===============*/
@media screen and (min-width: 768px) {
	.benefits__container {
		grid-template-columns: 0.8fr 1.2fr;
	}

	.benefits__img {
		width: 350px;
	}
}

/*=============== FORMAT (TIMELINE) ===============*/
.format {
	background-color: var(--bg-color-alt);
}

.format__container {
	position: relative;
	display: grid;
	gap: 2rem;
}

/* Timeline line */
.format__container::before {
	content: '';
	position: absolute;
	left: 20px;
	top: 0;
	bottom: 0;
	width: 2px;
	background-color: var(--primary-color);
	opacity: 0.2;
}

.format__item {
	position: relative;
	padding-left: 3rem;
}

/* Timeline circle */
.format__item::before {
	content: '';
	position: absolute;
	left: 14px; /* (20px from container line) - (12px width / 2) */
	top: 8px;
	width: 12px;
	height: 12px;
	background-color: var(--bg-color);
	border: 2px solid var(--primary-color);
	border-radius: 50%;
	z-index: 1;
}

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

.format__icon {
	color: var(--primary-color);
	width: 32px;
	height: 32px;
	flex-shrink: 0;
}

.format__title {
	font-size: var(--h3-font-size);
	margin-bottom: var(--mb-0-5);
}

.format__description {
	color: var(--text-color-light);
	line-height: 1.6;
}

/*=============== MEDIA QUERIES (for Format section) ===============*/
@media screen and (min-width: 768px) {
	.format__container {
		gap: 0;
	}

	.format__container::before {
		left: 50%;
		transform: translateX(-50%);
	}

	.format__item {
		width: 50%;
		padding-left: 0;
		padding-right: 3rem;
	}

	.format__item:nth-child(even) {
		margin-left: 50%;
		padding-left: 3rem;
		padding-right: 0;
	}

	.format__item::before {
		left: 50%;
		transform: translateX(-50%);
	}

	.format__item:nth-child(odd)::before {
		right: -6px;
		left: auto;
	}

	.format__item:nth-child(even)::before {
		left: -6px;
	}
}

/*=============== REVIEWS (SWIPER) ===============*/
.reviews {
	position: relative;
	overflow: hidden; /* Important for swiper navigation */
}

.reviews__container {
	padding-bottom: 4rem; /* Space for pagination */
}

.review-card {
	background-color: var(--bg-color-alt);
	padding: 2rem;
	border-radius: 0.75rem;
	text-align: center;
	border: 1px solid transparent;
	height: 100%; /* Ensure all cards have same height in a row */
}

.review-card__img {
	width: 80px;
	height: 80px;
	border-radius: 50%;
	object-fit: cover;
	margin: 0 auto var(--mb-1);
	border: 2px solid var(--primary-color);
}

.review-card__text {
	color: var(--text-color-light);
	line-height: 1.7;
	margin-bottom: var(--mb-1-5);
	font-style: italic;
}

.review-card__name {
	font-size: var(--h3-font-size);
	color: var(--title-color);
}

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

/* Swiper Styles */
.reviews-swiper {
	padding: 1rem 0;
}
.swiper-pagination-bullet {
	background-color: var(--primary-color);
	opacity: 0.5;
}

.swiper-pagination-bullet-active {
	opacity: 1;
}

.swiper-button-prev,
.swiper-button-next {
	color: var(--primary-color);
	width: 30px !important;
	height: 30px !important;
	background-color: var(--bg-color-alt);
	border-radius: 50%;
	transition: opacity 0.3s;
}
.swiper-button-prev:after,
.swiper-button-next:after {
	font-size: 1rem !important;
	font-weight: bold;
}
@media (hover: none) {
	.swiper-button-prev,
	.swiper-button-next {
		display: none !important;
	}
}

/*=============== CONTACT ===============*/
.contact {
	padding-bottom: 6rem;
}

.contact__container {
	display: grid;
	gap: 3rem;
}

.contact__info-title {
	font-size: var(--h2-font-size);
	margin-bottom: var(--mb-1);
}

.contact__info-description {
	color: var(--text-color-light);
	line-height: 1.7;
	margin-bottom: var(--mb-2);
}

.contact__info-item {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	color: var(--text-color);
	margin-bottom: var(--mb-1);
}

.contact__info-item i {
	color: var(--primary-color);
}

/* Form Styles */
.contact__form-wrapper {
	position: relative; /* For success message positioning */
}

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

.form__group {
	position: relative;
	padding-top: 0.5rem;
}

.form__input {
	width: 100%;
	padding: 1rem;
	border: 1px solid var(--bg-color-alt);
	background-color: var(--bg-color);
	border-radius: 0.5rem;
	color: var(--title-color);
	font-size: var(--normal-font-size);
	outline: none;
	transition: border-color 0.3s;
}

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

.form__label {
	position: absolute;
	left: 1rem;
	top: 1.5rem; /* Vertically centered */
	background-color: var(--bg-color);
	color: var(--text-color-light);
	font-size: var(--normal-font-size);
	padding: 0 0.25rem;
	pointer-events: none;
	transition: top 0.3s, font-size 0.3s;
}

/* Input focus or has value */
.form__input:focus + .form__label,
.form__input:not(:placeholder-shown) + .form__label {
	top: 0;
	font-size: var(--small-font-size);
	color: var(--primary-color);
}

.button--full {
	width: 100%;
	justify-content: center;
}

/* Checkbox */
.form__group--checkbox {
	padding-top: 0;
}

.form__checkbox-input {
	display: none;
}

.form__checkbox-label {
	display: inline-block;

	font-size: var(--small-font-size);
	color: var(--text-color-light);
	cursor: pointer;
}

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

.form__checkbox-box {
	width: 18px;
	height: 18px;
	border: 2px solid var(--primary-color);
	border-radius: 0.25rem;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background-color 0.3s;
}

.form__checkbox-input:checked
	+ .form__checkbox-label
	.form__checkbox-box::after {
	content: '✔';
	font-size: 12px;
	color: var(--primary-color);
}

/* Success Message */
.contact__success-message {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: var(--bg-color);
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	text-align: center;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.4s, visibility 0.4s;
	border-radius: 0.75rem;
}

.contact__success-message.is-visible {
	opacity: 1;
	visibility: visible;
}

.success-message__icon {
	width: 60px;
	height: 60px;
	color: var(--primary-color);
	margin-bottom: var(--mb-1);
}

.success-message__title {
	font-size: var(--h2-font-size);
}
.success-message__text {
	color: var(--text-color-light);
}

/*=============== MEDIA QUERIES (for Contact section) ===============*/
@media screen and (min-width: 968px) {
	.contact__container {
		grid-template-columns: repeat(2, 1fr);
		align-items: center;
	}
}

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

.cookie-popup.is-visible {
	bottom: 0;
}

.cookie-popup__content {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
	gap: 1rem;
	max-width: 1024px;
	margin: 0 var(--mb-1-5);
}

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

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

.cookie-popup__button {
	padding: 0.5rem 1.5rem;
}

@media screen and (min-width: 768px) {
	.cookie-popup__content {
		flex-direction: row;
		justify-content: space-between;
		margin-left: auto;
		margin-right: auto;
	}
}

/*=============== STYLES FOR POLICY PAGES ===============*/
.pages {
	padding-top: 4rem;
	padding-bottom: 4rem;
}

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

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

.pages h1 {
	font-size: 1.5rem;
	margin-bottom: var(--mb-2);
	border-bottom: 1px solid var(--bg-color-alt);
	padding-bottom: var(--mb-1);
}

.pages h2 {
	font-size: 1.5rem;
	margin-top: var(--mb-2);
}

.pages p {
	color: var(--text-color);
	line-height: 1.8;
	margin-bottom: var(--mb-1-5);
}

.pages ul {
	list-style-type: disc;
	padding-left: 2rem;
	margin-bottom: var(--mb-1-5);
}

.pages li {
	color: var(--text-color);
	margin-bottom: var(--mb-0-5);
	line-height: 1.8;
}

.pages a {
	color: var(--primary-color);
	text-decoration: underline;
	transition: color 0.3s;
}

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

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