/*
 * Product category landing page. Shared pieces (section title, handbook cards,
 * arrow link) come from pages.css.
 */

.tipa-cat {
	--tipa-sticky-top: 0px;
}

/* Head: breadcrumb + title, "Request a quote" on the right */
.tipa-cat__head {
	padding: 32px 0 40px;
	background: var(--tipa-white);
}

.tipa-cat__head-inner {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 24px 48px;
}

/* Flatsome's clearfix pseudo-elements would become flex items */
.tipa-cat .tipa-cat__head-inner::before,
.tipa-cat .tipa-cat__head-inner::after {
	display: none;
}

.tipa-ui .tipa-cat__title {
	margin: 0;
	color: var(--tipa-ink);
	font-size: 40px;
	font-weight: 500;
	line-height: 1.15;
	letter-spacing: -.03em;
}

.tipa-cat__head .tipa-breadcrumb ol {
	margin-bottom: 16px;
}

/* Landing menu: sticky under the header */
.tipa-landing-nav {
	position: sticky;
	top: var(--tipa-sticky-top);
	z-index: 20;
	border-top: 1px solid var(--tipa-green-100);
	border-bottom: 1px solid var(--tipa-green-100);
	background: var(--tipa-green-50);
}

.tipa-landing-nav ul {
	display: flex;
	gap: 40px;
	margin: 0;
	padding: 0;
	overflow-x: auto;
	list-style: none;
	scrollbar-width: none;
}

.tipa-landing-nav ul::-webkit-scrollbar {
	display: none;
}

.tipa-landing-nav li {
	flex: 0 0 auto;
	margin: 0;
}

.tipa-landing-nav a {
	position: relative;
	display: block;
	padding: 18px 0;
	color: var(--tipa-ink);
	font-size: 15px;
	font-weight: 600;
	line-height: 1.4;
	white-space: nowrap;
	transition: color .2s ease;
}

.tipa-landing-nav a::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: -1px;
	height: 2px;
	border-radius: 2px;
	background: var(--tipa-green);
	transform: scaleX(0);
	transition: transform .2s ease;
}

.tipa-landing-nav a:hover,
.tipa-landing-nav a.is-active {
	color: var(--tipa-green);
}

.tipa-landing-nav a.is-active::after {
	transform: scaleX(1);
}

/* Landing sections: title left, content right */
.tipa-landing__section {
	scroll-margin-top: calc(var(--tipa-sticky-top) + 72px);
}

.tipa-landing__inner {
	display: grid;
	grid-template-columns: 4fr 8fr;
	gap: 32px 60px;
	padding-top: 64px;
	padding-bottom: 64px;
	border-bottom: 1px solid var(--tipa-green-100);
}

.tipa-ui .tipa-landing__title {
	margin: 0;
	color: var(--tipa-ink);
	font-size: 28px;
	font-weight: 500;
	line-height: 1.25;
	letter-spacing: -.02em;
}

.tipa-landing__content {
	color: var(--tipa-text);
	line-height: 1.7;
}

.tipa-landing__content > :last-child {
	margin-bottom: 0;
}

.tipa-landing__content ul li {
	margin-bottom: 8px;
}

/* Products */
.tipa-products {
	padding: 80px 0;
	scroll-margin-top: calc(var(--tipa-sticky-top) + 72px);
}

.tipa-ui .tipa-products .tipa-section-title {
	margin-bottom: 32px;
	text-align: left;
}

.tipa-products__filter {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-bottom: 40px;
}

.tipa-chip {
	margin: 0;
	padding: 0 18px;
	min-height: 40px;
	border: 1px solid var(--tipa-green-100);
	border-radius: 99px;
	background: var(--tipa-white);
	color: var(--tipa-ink);
	font-size: 14px;
	font-weight: 500;
	line-height: 38px;
	letter-spacing: 0;
	text-transform: none;
	cursor: pointer;
	transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}

.tipa-chip:hover {
	border-color: var(--tipa-green);
	color: var(--tipa-green);
}

.tipa-chip.is-active {
	border-color: var(--tipa-green);
	background: var(--tipa-green);
	color: var(--tipa-white);
}

.tipa-chip:focus-visible,
.tipa-pagination__btn:focus-visible {
	outline: 2px solid var(--tipa-green);
	outline-offset: 2px;
}

.tipa-products__grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 30px;
	transition: opacity .2s ease;
}

.tipa-products__grid.is-loading {
	opacity: .4;
	pointer-events: none;
}

.tipa-products__empty {
	grid-column: 1 / -1;
	color: var(--tipa-gray);
}

.tipa-products__footer {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 24px;
	margin-top: 40px;
}

.tipa-products__footer:has(.tipa-pagination:empty):has(.tipa-products__more[hidden]) {
	display: none;
}

.tipa-products__more[hidden] {
	display: none;
}

.tipa-pagination {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px;
}

.tipa-pagination__btn {
	margin: 0;
	padding: 0;
	width: 40px;
	height: 40px;
	min-height: 0;
	border: 1px solid var(--tipa-green-100);
	border-radius: 50%;
	background: var(--tipa-white);
	color: var(--tipa-ink);
	font-size: 14px;
	font-weight: 600;
	line-height: 38px;
	cursor: pointer;
	transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}

.tipa-pagination__btn:hover:not(:disabled) {
	border-color: var(--tipa-green);
	color: var(--tipa-green);
}

.tipa-pagination__btn.is-active {
	border-color: var(--tipa-green);
	background: var(--tipa-green);
	color: var(--tipa-white);
}

.tipa-pagination__btn:disabled {
	opacity: .4;
	cursor: default;
}

/* Tablet */
@media (max-width: 849px) {
	.tipa-cat__head-inner {
		flex-direction: column;
		align-items: flex-start;
	}

	.tipa-ui .tipa-cat__title { font-size: 32px; }

	.tipa-landing__inner {
		grid-template-columns: 1fr;
		gap: 16px;
		padding-top: 48px;
		padding-bottom: 48px;
	}

	.tipa-ui .tipa-landing__title { font-size: 24px; }

	.tipa-products { padding: 64px 0; }

	.tipa-products__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
}

/* Mobile */
@media (max-width: 549px) {
	.tipa-cat__head { padding: 24px 0 32px; }
	.tipa-ui .tipa-cat__title { font-size: 28px; }
	.tipa-landing-nav ul { gap: 28px; }
	.tipa-products { padding: 48px 0; }
	.tipa-products__filter {
		flex-wrap: nowrap;
		margin-right: -15px;
		padding-right: 15px;
		overflow-x: auto;
		scrollbar-width: none;
	}
	.tipa-chip { flex: 0 0 auto; }
}
