/**
 * Главная страница (edetauto): отдельные стили, не shell.css.
 * Центрирование колонки — .ea-page-width в shell.css, здесь только контент.
 */

#bx-workarea-main:has(.ea-home) {
	padding-top: 0;
	padding-bottom: 0;
}

.ea-home {
	width: 100%;
	min-width: 0;
}

.ea-home-blocks {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	padding-bottom: 1.25rem;
}

@media (min-width: 768px) {
	.ea-home-blocks {
		gap: 1.25rem;
		padding-bottom: 60px;
	}
}

.ea-home-section {
	min-width: 0;
}

/* Hero */
.ea-home-hero {
	width: 100%;
	padding: 32px 0 0;
	background-color: #f9f9f7;
	background-repeat: no-repeat;
}

@media (min-width: 768px) {
	.ea-home-hero {
		padding-top: 56px;
	}
}

.ea-home--auth .ea-home-hero {
	padding-bottom: 40px;
}

.ea-home-hero--morning {
	background-image: radial-gradient(
		ellipse 120% 85% at 50% 0%,
		rgba(253, 230, 138, 0.38) 0%,
		rgba(254, 249, 195, 0.22) 24%,
		rgba(249, 249, 247, 0.96) 54%,
		#f9f9f7 100%
	);
}

.ea-home-hero--day {
	background-image: radial-gradient(
		ellipse 120% 85% at 50% 0%,
		rgba(209, 250, 229, 0.4) 0%,
		rgba(236, 253, 245, 0.22) 22%,
		rgba(249, 249, 247, 0.96) 52%,
		#f9f9f7 100%
	);
}

.ea-home-hero--evening {
	background-image: radial-gradient(
		ellipse 120% 85% at 50% 0%,
		rgba(253, 186, 116, 0.36) 0%,
		rgba(255, 237, 213, 0.2) 24%,
		rgba(249, 249, 247, 0.96) 54%,
		#f9f9f7 100%
	);
}

.ea-home-hero--night {
	background-image: radial-gradient(
		ellipse 120% 85% at 50% 0%,
		rgba(147, 197, 253, 0.34) 0%,
		rgba(219, 234, 254, 0.2) 24%,
		rgba(249, 249, 247, 0.96) 54%,
		#f9f9f7 100%
	);
}

.ea-home-hero__inner {
	width: 100%;
	max-width: 48rem;
	margin: 0 auto;
	text-align: center;
}

.ea-home-hero h1.ea-home-hero__title {
	margin: 0 0 10px;
	font-size: clamp(1.875rem, 5.5vw, 3rem);
	font-weight: normal;
	line-height: 1.15;
	letter-spacing: -0.03em;
	text-align: center;
	color: #004b6d;
}

.ea-home-hero__subtitle {
	margin: 0 auto;
	max-width: 42rem;
	font-size: clamp(0.9375rem, 1.8vw, 1.0625rem);
	line-height: 1.55;
	text-align: center;
	color: #4b5563;
}

/* Гость: размеры в px */
.ea-home--guest .ea-home-hero h1.ea-home-hero__title {
	font-size: 24px;
	line-height: 1.25;
	letter-spacing: normal;
}

.ea-home--guest .ea-home-hero__subtitle {
	max-width: 544px;
	font-size: 17px;
}

@media (min-width: 768px) {
	.ea-home--guest .ea-home-hero__inner {
		max-width: 1024px;
	}

	.ea-home--guest .ea-home-hero h1.ea-home-hero__title {
		font-size: 38px;
	}

	.ea-home-hero h1.ea-home-hero__title {
		margin-bottom: 16px;
	}

	.ea-home-hero__subtitle {
		line-height: 1.6;
	}

	.ea-home-hero__cta-wrap {
		margin-top: 32px;
	}
}

.ea-home-hero__cta-wrap {
	margin-top: 20px;
}

.ea-home-hero__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 0 28px;
	border: 0;
	border-radius: 14px;
	color: #fff;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.2;
	cursor: pointer;
	transition: background-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.ea-home-hero__cta--primary {
	background-color: #17a48b;
	box-shadow: 0 2px 10px rgba(23, 164, 139, 0.28);
}

.ea-home-hero__cta--primary:hover,
.ea-home-hero__cta--primary:focus-visible {
	background-color: #148a75;
	transform: translateY(-1px);
}

.ea-home-section--catalog {
	margin-top: 0;
}

.ea-home-divider {
	display: block;
	width: 100%;
	height: 0;
	margin: 20px 0 16px;
	border: 0;
	border-top: 1px solid #e5e7eb;
}

.ea-home-divider--hero {
	width: 100vw;
	position: relative;
	left: 50%;
	transform: translateX(-50%);
	margin: 28px 0 8px;
}

@media (min-width: 768px) {
	.ea-home-divider--hero {
		margin-top: 48px;
		margin-bottom: 8px;
	}
}

.ea-home-hero__nav {
	width: 100%;
	max-width: 48rem;
	margin: 28px auto 0;
}

@media (min-width: 768px) {
	.ea-home--guest .ea-home-hero__nav {
		max-width: 1024px;
		margin-top: 40px;
	}
}

.ea-home-hero__nav .ea-home-card {
	position: relative;
	padding-right: 44px;
}

.ea-home-hero__nav .ea-home-card::after {
	content: "";
	position: absolute;
	top: 50%;
	right: 18px;
	width: 9px;
	height: 9px;
	margin-top: -1px;
	border-right: 2px solid #94a3b8;
	border-top: 2px solid #94a3b8;
	transform: translateY(-50%) rotate(45deg);
	transition: border-color 0.15s ease, transform 0.15s ease;
}

a.ea-home-card:hover::after,
a.ea-home-card:focus-visible::after {
	border-right-color: #17a48b;
	border-top-color: #17a48b;
	transform: translateY(-50%) rotate(45deg) translate(1px, -1px);
}

#bx-workarea:has(.ea-home--guest),
#bx-workarea-main:has(.ea-home--guest) {
	min-height: 0;
}

.ea-page-stretch:has(.ea-home--guest) {
	min-height: 0;
}

.ea-home--guest .ea-catalog-list-shell,
.ea-home--guest [data-react-module="catalog"] {
	flex: none;
	min-height: 400px;
	padding-bottom: 24px;
}

.ea-home--guest [data-react-module="catalog"] .min-h-\[400px\] {
	flex: none;
	min-height: 400px !important;
}

@media (max-width: 767px) {
	.ea-home--guest .ea-catalog-list-shell,
	.ea-home--guest [data-react-module="catalog"],
	.ea-home--guest [data-react-module="catalog"] .min-h-\[400px\] {
		min-height: 320px !important;
		padding-bottom: 16px;
	}
}

/* Блоки-заглушки под будущий контент (разные наборы для guest/auth) */
.ea-home-cards {
	display: grid;
	grid-template-columns: 1fr;
	gap: 0.75rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

@media (min-width: 640px) {
	.ea-home-cards {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (min-width: 960px) {
	.ea-home-cards--presets,
	.ea-home-section--main .ea-home-cards,
	.ea-home-section--active .ea-home-cards,
	.ea-home-section--archive .ea-home-cards {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (min-width: 1100px) {
	.ea-home-section--active .ea-home-cards,
	.ea-home-section--archive .ea-home-cards {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}
}

.ea-home-section--active,
.ea-home-section--archive {
	margin-top: 1.5rem;
}

.ea-home-section--archive {
	margin-bottom: 0.75rem;
}

@media (min-width: 768px) {
	.ea-home-section--active,
	.ea-home-section--archive {
		margin-top: 2rem;
	}

	.ea-home-section--archive {
		margin-bottom: 0;
	}
}

.ea-home-section__heading {
	margin: 0 0 0.375rem;
	font-size: 1.125rem;
	font-weight: 600;
	line-height: 1.35;
	color: #0f172a;
}

.ea-home-section__desc {
	margin: 0 0 1rem;
	max-width: 42rem;
	font-size: 0.875rem;
	line-height: 1.5;
	color: #64748b;
}

@media (max-width: 767px) {
	.ea-home-section__heading,
	.ea-home-section__desc {
		text-align: center;
	}

	.ea-home-section__desc {
		margin-left: auto;
		margin-right: auto;
	}
}

.ea-home-cards > li {
	display: flex;
	min-height: 0;
}

.ea-home-card__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.375rem;
	min-width: 0;
}

.ea-home-card__badge {
	flex-shrink: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 0;
	padding: 0.125rem 0.375rem;
	border-radius: 999px;
	font-size: 0.75rem;
	font-weight: 600;
	line-height: 1.25;
	letter-spacing: -0.01em;
	white-space: nowrap;
	color: #6b7280;
	background: rgba(107, 114, 128, 0.12);
}

.ea-home-card__badge--hot {
	color: #dc2626;
	background: rgba(220, 38, 38, 0.1);
}

.ea-home-section--archive .ea-home-card {
	background: #fafafa;
}

.ea-home-card {
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	flex: 1;
	width: 100%;
	gap: 0.375rem;
	min-width: 0;
	min-height: 100%;
	padding: 1rem 1.125rem;
	border-radius: 12px;
	background: #fff;
	border: 1px solid #e5e7eb;
	text-decoration: none;
	color: inherit;
	transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

a.ea-home-card:hover,
a.ea-home-card:focus-visible {
	border-color: rgba(23, 164, 139, 0.35);
	box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06);
	transform: translateY(-1px);
}

.ea-home-card__title {
	margin: 0;
	flex: 1;
	min-width: 0;
	font-size: 1rem;
	font-weight: 600;
	line-height: 1.35;
	color: #0f172a;
}

.ea-home-card__text {
	margin: 0;
	flex: 1;
	font-size: 0.875rem;
	line-height: 1.45;
	color: #64748b;
}

.ea-home-card--disabled {
	cursor: not-allowed;
	opacity: 0.72;
	background: #f9fafb;
	border-color: #e5e7eb;
	pointer-events: none;
}

.ea-home-card--disabled .ea-home-card__title {
	color: #6b7280;
}

.ea-home-card--disabled .ea-home-card__text {
	color: #9ca3af;
}

.ea-home-card--disabled .ea-home-card__badge {
	color: #9ca3af;
	background: rgba(156, 163, 175, 0.14);
}

.ea-home-card--placeholder {
	background: #f9fafb;
	border-style: dashed;
	border-color: #d1d5db;
}

.ea-home-card--placeholder .ea-home-card__title {
	color: #6b7280;
}

.ea-home-card--placeholder .ea-home-card__text {
	color: #9ca3af;
}
