/* assets/css/front-page-catalog.css */

.gptc-home-page {
	--gptc-bg: #f6f8fc;
	--gptc-surface: #ffffff;
	--gptc-surface-2: #f9fbff;
	--gptc-text: #0f172a;
	--gptc-text-soft: #55637a;
	--gptc-border: rgba(15, 23, 42, 0.08);
	--gptc-border-strong: rgba(15, 23, 42, 0.14);
	--gptc-primary: #2563eb;
	--gptc-primary-strong: #1d4ed8;
	--gptc-primary-soft: rgba(37, 99, 235, 0.08);
	--gptc-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
	--gptc-radius-xl: 24px;
	--gptc-radius-lg: 18px;
	--gptc-radius-md: 14px;
	--gptc-radius-sm: 12px;

	background: linear-gradient(180deg, #f7faff 0%, #f4f7fb 100%);
	color: var(--gptc-text);
	padding-bottom: 64px;
}

.gptc-shell {
	width: min(1280px, calc(100% - 32px));
	margin: 0 auto;
}

.gptc-kicker {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 12px;
	border-radius: 999px;
	background: var(--gptc-primary-soft);
	color: var(--gptc-primary);
	font-size: 13px;
	font-weight: 700;
	line-height: 1;
	letter-spacing: 0.02em;
}

.gptc-kicker--muted {
	background: rgba(15, 23, 42, 0.05);
	color: #334155;
}

.gptc-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 46px;
	padding: 0 18px;
	border-radius: 14px;
	border: 1px solid transparent;
	font-size: 15px;
	font-weight: 700;
	text-decoration: none;
	cursor: pointer;
	transition: 0.22s ease;
}

.gptc-button:hover {
	transform: translateY(-1px);
}

.gptc-button--primary {
	background: var(--gptc-primary);
	color: #ffffff;
	box-shadow: 0 10px 22px rgba(37, 99, 235, 0.22);
}

.gptc-button--primary:hover {
	background: var(--gptc-primary-strong);
	color: #ffffff;
}

.gptc-button--ghost {
	background: #ffffff;
	color: var(--gptc-text);
	border-color: var(--gptc-border-strong);
}

.gptc-button--ghost:hover {
	border-color: rgba(37, 99, 235, 0.28);
	color: var(--gptc-primary);
}

.gptc-button--wide {
	width: 100%;
}

.gptc-home-hero {
	padding: 28px 0 16px;
}

.gptc-home-hero__grid {
	display: grid;
	grid-template-columns: minmax(0, 1.35fr) minmax(280px, 380px);
	gap: 24px;
	align-items: stretch;
}

.gptc-home-hero__content,
.gptc-home-hero__panel {
	min-width: 0;
}

.gptc-home-title {
	margin: 16px 0 12px;
	font-size: clamp(32px, 5vw, 56px);
	line-height: 1.02;
	letter-spacing: -0.03em;
}

.gptc-home-subtitle {
	margin: 0;
	max-width: 780px;
	font-size: 18px;
	line-height: 1.65;
	color: var(--gptc-text-soft);
}

.gptc-search-box {
	display: flex;
	gap: 12px;
	align-items: center;
	margin-top: 24px;
}

.gptc-search-box__field {
	position: relative;
	flex: 1 1 auto;
}

.gptc-search-box__field svg {
	position: absolute;
	left: 18px;
	top: 50%;
	width: 20px;
	height: 20px;
	fill: #6b7280;
	transform: translateY(-50%);
	pointer-events: none;
}

.gptc-search-box__input {
	width: 100%;
	height: 58px;
	padding: 0 18px 0 50px;
	border: 1px solid var(--gptc-border);
	border-radius: 16px;
	background: rgba(255, 255, 255, 0.95);
	box-shadow: 0 10px 24px rgba(148, 163, 184, 0.12);
	font-size: 16px;
	outline: none;
	transition: 0.22s ease;
}

.gptc-search-box__input:focus {
	border-color: rgba(37, 99, 235, 0.28);
	box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.gptc-home-stats {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 14px;
	margin-top: 22px;
}

.gptc-stat-card {
	padding: 18px;
	border: 1px solid var(--gptc-border);
	border-radius: 18px;
	background: rgba(255, 255, 255, 0.92);
	box-shadow: var(--gptc-shadow);
}

.gptc-stat-card__value {
	display: block;
	font-size: clamp(22px, 3vw, 30px);
	font-weight: 800;
	line-height: 1;
}

.gptc-stat-card__label {
	display: block;
	margin-top: 8px;
	font-size: 14px;
	line-height: 1.45;
	color: var(--gptc-text-soft);
}

.gptc-side-card {
	height: 100%;
	padding: 24px;
	border: 1px solid var(--gptc-border);
	border-radius: var(--gptc-radius-xl);
	background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
	box-shadow: var(--gptc-shadow);
}

.gptc-side-card__title {
	margin: 14px 0 12px;
	font-size: 24px;
	line-height: 1.15;
	letter-spacing: -0.02em;
}

.gptc-side-card__text {
	margin: 0 0 16px;
	font-size: 15px;
	line-height: 1.65;
	color: var(--gptc-text-soft);
}

.gptc-side-card__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 18px;
}

.gptc-side-card__meta span {
	display: inline-flex;
	align-items: center;
	min-height: 34px;
	padding: 0 12px;
	border-radius: 999px;
	background: rgba(15, 23, 42, 0.04);
	color: #334155;
	font-size: 13px;
	font-weight: 700;
}

.gptc-facets-section {
	padding: 10px 0 8px;
}

.gptc-facets {
	display: grid;
	gap: 14px;
}

.gptc-facet-group {
	padding: 18px 18px 16px;
	border: 1px solid var(--gptc-border);
	border-radius: var(--gptc-radius-lg);
	background: var(--gptc-surface);
	box-shadow: var(--gptc-shadow);
}

.gptc-facet-group__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 12px;
}

.gptc-facet-group__head h2 {
	margin: 0;
	font-size: 16px;
	line-height: 1.2;
}

.gptc-facet-clear {
	padding: 0;
	border: 0;
	background: none;
	color: var(--gptc-primary);
	font-size: 14px;
	font-weight: 700;
	cursor: pointer;
}

.gptc-chip-list {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.gptc-chip {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 40px;
	padding: 0 14px;
	border: 1px solid var(--gptc-border);
	border-radius: 999px;
	background: #ffffff;
	color: var(--gptc-text);
	font-size: 14px;
	font-weight: 700;
	cursor: pointer;
	transition: 0.22s ease;
}

.gptc-chip:hover,
.gptc-chip.is-active {
	border-color: rgba(37, 99, 235, 0.28);
	background: rgba(37, 99, 235, 0.06);
	color: var(--gptc-primary);
}

.gptc-chip em {
	font-style: normal;
	font-size: 12px;
	color: #64748b;
}

.gptc-chip strong {
	display: inline-flex;
	align-items: center;
	height: 22px;
	padding: 0 8px;
	border-radius: 999px;
	background: rgba(37, 99, 235, 0.12);
	font-size: 11px;
	line-height: 1;
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: var(--gptc-primary);
}

.gptc-chip--all {
	font-weight: 800;
}

.gptc-catalog-section,
.gptc-paid-section,
.gptc-add-section {
	padding-top: 24px;
}

.gptc-section-head {
	display: flex;
	align-items: end;
	justify-content: space-between;
	gap: 20px;
	margin-bottom: 18px;
}

.gptc-section-head--stack {
	align-items: center;
}

.gptc-section-title {
	margin: 10px 0 0;
	font-size: clamp(28px, 4vw, 42px);
	line-height: 1.08;
	letter-spacing: -0.03em;
}

.gptc-section-text {
	margin: 10px 0 0;
	max-width: 820px;
	font-size: 16px;
	line-height: 1.7;
	color: var(--gptc-text-soft);
}

.gptc-result-pill {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 42px;
	padding: 0 14px;
	border-radius: 999px;
	background: rgba(15, 23, 42, 0.05);
	color: #334155;
	font-size: 14px;
	font-weight: 700;
}

.gptc-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 18px;
}

.gptc-card {
	display: none;
	flex-direction: column;
	min-width: 0;
	border: 1px solid var(--gptc-border);
	border-radius: 22px;
	background: var(--gptc-surface);
	box-shadow: var(--gptc-shadow);
	overflow: hidden;
}

.gptc-card.is-visible {
	display: flex;
}

.gptc-card.is-hidden-by-filter {
	display: none !important;
}

.gptc-card__media {
	position: relative;
	aspect-ratio: 16 / 10;
	background: linear-gradient(180deg, #eff6ff 0%, #f8fbff 100%);
	overflow: hidden;
}

.gptc-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.gptc-card__placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	background:
		radial-gradient(circle at top left, rgba(37, 99, 235, 0.16), transparent 42%),
		linear-gradient(180deg, #eff6ff 0%, #f8fbff 100%);
}

.gptc-card__placeholder span {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 72px;
	height: 72px;
	border-radius: 22px;
	background: rgba(255, 255, 255, 0.88);
	box-shadow: 0 10px 24px rgba(37, 99, 235, 0.14);
	font-size: 24px;
	font-weight: 800;
	color: var(--gptc-primary);
}

.gptc-card__price {
	position: absolute;
	right: 14px;
	bottom: 14px;
	display: inline-flex;
	align-items: center;
	min-height: 34px;
	padding: 0 12px;
	border-radius: 999px;
	background: rgba(15, 23, 42, 0.8);
	backdrop-filter: blur(10px);
	color: #ffffff;
	font-size: 13px;
	font-weight: 700;
}

.gptc-card__body {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 18px;
}

.gptc-card__terms {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.gptc-card__terms span {
	display: inline-flex;
	align-items: center;
	min-height: 28px;
	padding: 0 10px;
	border-radius: 999px;
	background: rgba(37, 99, 235, 0.08);
	color: var(--gptc-primary);
	font-size: 12px;
	font-weight: 700;
}

.gptc-card__title {
	margin: 0;
	font-size: 20px;
	line-height: 1.2;
	letter-spacing: -0.02em;
}

.gptc-card__title a {
	color: inherit;
	text-decoration: none;
}

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

.gptc-card__desc {
	margin: 0;
	font-size: 14px;
	line-height: 1.7;
	color: var(--gptc-text-soft);
}

.gptc-card__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: auto;
}

.gptc-card__meta span {
	display: inline-flex;
	align-items: center;
	min-height: 30px;
	padding: 0 10px;
	border-radius: 999px;
	background: rgba(15, 23, 42, 0.05);
	color: #475569;
	font-size: 12px;
	font-weight: 700;
}

.gptc-card__actions {
	display: flex;
	gap: 10px;
	margin-top: 4px;
}

.gptc-card__actions .gptc-button {
	flex: 1 1 50%;
}

.gptc-load-more-wrap {
	display: flex;
	justify-content: center;
	margin-top: 22px;
}

.gptc-empty-state {
	padding: 28px;
	border: 1px dashed var(--gptc-border-strong);
	border-radius: var(--gptc-radius-lg);
	background: rgba(255, 255, 255, 0.72);
	text-align: center;
}

.gptc-empty-state h3 {
	margin: 0 0 10px;
	font-size: 24px;
}

.gptc-empty-state p {
	margin: 0;
	font-size: 15px;
	line-height: 1.7;
	color: var(--gptc-text-soft);
}

.gptc-package-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 18px;
	margin-top: 16px;
}

.gptc-package-card {
	padding: 22px;
	border: 1px solid var(--gptc-border);
	border-radius: 22px;
	background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
	box-shadow: var(--gptc-shadow);
}

.gptc-package-card__badge {
	display: inline-flex;
	align-items: center;
	min-height: 28px;
	padding: 0 10px;
	border-radius: 999px;
	background: rgba(37, 99, 235, 0.08);
	color: var(--gptc-primary);
	font-size: 11px;
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.gptc-package-card h3 {
	margin: 14px 0 10px;
	font-size: 22px;
	line-height: 1.15;
}

.gptc-package-card p {
	margin: 0;
	font-size: 14px;
	line-height: 1.7;
	color: var(--gptc-text-soft);
}

.gptc-package-card__price {
	margin-top: 16px;
	font-size: 26px;
	font-weight: 800;
	line-height: 1;
	letter-spacing: -0.03em;
}

.gptc-add-card {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	padding: 26px;
	border: 1px solid var(--gptc-border);
	border-radius: 24px;
	background:
		radial-gradient(circle at top right, rgba(37, 99, 235, 0.1), transparent 28%),
		linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
	box-shadow: var(--gptc-shadow);
}

.gptc-add-card__content {
	max-width: 820px;
}

.gptc-add-card__actions {
	flex: 0 0 auto;
}

.gptc-modal[hidden] {
	display: none;
}

.gptc-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
}

.gptc-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(15, 23, 42, 0.64);
	backdrop-filter: blur(8px);
}

.gptc-modal__dialog {
	position: relative;
	display: flex;
	flex-direction: column;
	width: min(1280px, calc(100% - 32px));
	height: min(88vh, 920px);
	margin: min(6vh, 40px) auto 0;
	border-radius: 24px;
	background: #ffffff;
	box-shadow: 0 40px 100px rgba(15, 23, 42, 0.3);
	overflow: hidden;
}

.gptc-modal__top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 18px 20px;
	border-bottom: 1px solid var(--gptc-border);
	background: #ffffff;
}

.gptc-modal__title {
	margin: 0;
	font-size: 20px;
	line-height: 1.2;
	letter-spacing: -0.02em;
}

.gptc-modal__close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	padding: 0;
	border: 1px solid var(--gptc-border);
	border-radius: 12px;
	background: #ffffff;
	cursor: pointer;
}

.gptc-modal__close svg {
	width: 20px;
	height: 20px;
	fill: #334155;
}

.gptc-modal__frame-wrap {
	flex: 1 1 auto;
	min-height: 0;
	background: #eef2ff;
}

.gptc-modal__frame {
	width: 100%;
	height: 100%;
	border: 0;
	background: #ffffff;
}

.gptc-modal__bottom {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 16px 20px;
	border-top: 1px solid var(--gptc-border);
	background: #ffffff;
}

@media (max-width: 1180px) {
	.gptc-grid,
	.gptc-package-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.gptc-home-hero__grid {
		grid-template-columns: 1fr;
	}

	.gptc-home-hero__panel {
		max-width: 560px;
	}
}

@media (max-width: 820px) {
	.gptc-shell {
		width: min(100% - 24px, 1280px);
	}

	.gptc-search-box {
		flex-direction: column;
		align-items: stretch;
	}

	.gptc-home-stats {
		grid-template-columns: 1fr;
	}

	.gptc-grid,
	.gptc-package-grid {
		grid-template-columns: 1fr;
	}

	.gptc-section-head,
	.gptc-add-card,
	.gptc-modal__bottom {
		flex-direction: column;
		align-items: stretch;
	}

	.gptc-card__actions {
		flex-direction: column;
	}

	.gptc-modal__dialog {
		width: calc(100% - 16px);
		height: calc(100vh - 16px);
		margin-top: 8px;
		border-radius: 18px;
	}

	.gptc-modal__top,
	.gptc-modal__bottom {
		padding: 14px;
	}
}