/* ==========================================================================
   Trang Lốp xe theo hãng
   Prefix tb-. Dùng token và thành phần chung từ assets/css/core/theme.css.
   ========================================================================== */

.gl-crumb {
	background: #fff;
	border-bottom: 1px solid var(--gl-line);
}

.gl-crumb__list {
	display: flex;
	align-items: center;
	gap: 8px;
	min-height: 42px;
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: 12px;
	color: var(--gl-muted);
}

.gl-crumb__list a:hover {
	color: var(--gl-navy);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.gl-crumb__sep {
	opacity: .45;
}

.gl-crumb__list [aria-current="page"] {
	font-weight: 700;
	color: var(--gl-navy);
}

.tb-page {
	overflow: clip;
	background: var(--gl-white);
}

.tb-section {
	padding-block: clamp(58px, 7vw, 60px);
}

.tb-section--soft {
	background: #f5f7fa;
}

.tb-heading {
	max-width: 760px;
	margin-bottom: 30px;
}

.tb-heading--center {
	margin-inline: auto;
	text-align: center;
}

.tb-eyebrow {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 0 0 8px;
	font-size: 11px;
	font-weight: 700;
	line-height: 1.4;
	letter-spacing: .13em;
	text-transform: uppercase;
	color: #d49400;
}

.tb-heading--center .tb-eyebrow {
	justify-content: center;
}

.tb-title {
	margin: 0;
	font-size: clamp(26px, 3.3vw, 38px);
	font-weight: 700;
	line-height: 1.17;
	letter-spacing: -.03em;
	color: var(--gl-navy);
	text-wrap: balance;
}

.tb-lede {
	max-width: 680px;
	margin: 10px 0 0;
	font-size: 15px;
	line-height: 1.7;
	color: var(--gl-muted);
	text-wrap: pretty;
}

.tb-heading--center .tb-lede {
	margin-inline: auto;
}

/* Hero */
.tb-hero {
	position: relative;
	isolation: isolate;
	min-height: 300px;
	overflow: hidden;
	color: var(--gl-white);
	background:
		radial-gradient(700px 320px at 82% 45%, rgba(52, 94, 142, .72), transparent 72%),
		linear-gradient(120deg, #0f2d52 0%, var(--gl-navy) 62%, #294f7b 100%);
}

.tb-hero::before {
	position: absolute;
	inset: 0;
	z-index: -2;
	content: "";
	background-image: var(--tb-hero-image, none);
	background-position: center;
	background-size: cover;
}

.tb-hero::after {
	position: absolute;
	inset: 0;
	z-index: -1;
	content: "";
	background:
		linear-gradient(90deg, rgba(8, 34, 63, .8) 0%, rgba(9, 38, 72, .62) 48%, rgba(10, 41, 76, .3) 100%),
		linear-gradient(180deg, rgba(8, 29, 54, .12), rgba(8, 29, 54, .34));
}

.tb-hero__inner {
	display: flex;
	align-items: center;
	min-height: 300px;
	padding-block: 44px;
}

.tb-hero__body {
	max-width: 690px;
}

.tb-eyebrow--light {
	color: var(--gl-yellow);
}

.tb-hero__title {
	margin: 0;
	font-size: clamp(34px, 4.6vw, 56px);
	font-weight: 700;
	line-height: 1.05;
	letter-spacing: -.045em;
	color: var(--gl-white);
	text-wrap: balance;
}

.tb-hero__desc {
	max-width: 680px;
	margin: 18px 0 0;
	font-size: clamp(14px, 1.3vw, 16px);
	line-height: 1.72;
	color: rgba(255, 255, 255, .84);
	text-wrap: pretty;
}

/* Brand cards */
.tb-brands__grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 18px;
}

.tb-brand {
	display: flex;
	min-width: 0;
	overflow: hidden;
	flex-direction: column;
	border: 1px solid var(--gl-line);
	border-radius: var(--gl-radius);
	background: var(--gl-white);
	box-shadow: var(--gl-shadow);
	transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.tb-brand:hover {
	transform: translateY(-4px);
	border-color: rgba(28, 55, 103, .48);
	box-shadow: var(--gl-shadow-md);
}

.tb-brand__logo {
	display: grid;
	min-height: 114px;
	padding: 22px;
	place-items: center;
	border-bottom: 1px solid var(--gl-line);
	background: #f9fafc;
}

.tb-brand__logo img {
	width: auto;
	max-width: 145px;
	height: auto;
	max-height: 48px;
	object-fit: contain;
}

.tb-brand__wordmark {
	padding: 10px 14px;
	border: 1px dashed #cbd5e1;
	border-radius: 7px;
	font-size: 13px;
	font-weight: 850;
	letter-spacing: .02em;
	text-transform: uppercase;
	color: var(--gl-navy);
}

.tb-brand__body {
	display: flex;
	flex: 1;
	padding: 18px 18px 19px;
	flex-direction: column;
}

.tb-brand__title {
	margin: 0;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.35;
	color: var(--gl-navy);
}

.tb-brand__title a:hover {
	color: #315d94;
}

.tb-brand__desc {
	margin: 10px 0 18px;
	font-size: 13px;
	line-height: 1.66;
	color: var(--gl-muted);
}

.tb-brand__more {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-top: auto;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.45;
	color: var(--gl-navy);
}

.tb-brand__more svg {
	transition: transform .2s ease;
}

.tb-brand__more:hover svg {
	transform: translateX(3px);
}

/* Guide */
.tb-guide__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 18px;
	margin: 0;
	padding: 0;
	list-style: none;
}

/* Số thứ tự và tiêu đề cùng một hàng, ảnh và mô tả trải hết chiều ngang bên dưới. */
.tb-guide__item {
	position: relative;
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	align-content: start;
	align-items: center;
	column-gap: 12px;
	min-height: 190px;
	padding: 22px 24px 26px;
	text-align: left;
	border: 1px solid var(--gl-line);
	border-radius: var(--gl-radius);
	background: var(--gl-white);
}

.tb-guide__number {
	display: grid;
	width: 34px;
	height: 34px;
	place-items: center;
	border-radius: 9px;
	font-size: 12px;
	font-weight: 850;
	color: var(--gl-navy);
	background: #edf4ff;
}

.tb-guide__item h3 {
	margin: 0;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.4;
	color: var(--gl-navy);
}

.tb-guide__item p {
	grid-column: 1 / -1;
	margin: 12px 0 0;
	font-size: 14px;
	line-height: 1.65;
	color: var(--gl-muted);
}

/* Ảnh minh hoạ nằm giữa tiêu đề và mô tả */
.tb-guide__media {
	grid-column: 1 / -1;
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	margin-top: 14px;
	object-fit: cover;
	border-radius: var(--gl-radius);
}

/* Comparison table */
.tb-table-wrap {
	overflow-x: auto;
	border: 1px solid var(--gl-line);
	border-radius: var(--gl-radius);
	background: var(--gl-white);
	box-shadow: var(--gl-shadow);
}

.tb-table-wrap:focus-visible {
	outline: 3px solid rgba(245, 200, 66, .6);
	outline-offset: 3px;
}

.tb-table {
	width: 100%;
	min-width: 720px;
	border-collapse: collapse;
	font-size: 13px;
}

.tb-table th,
.tb-table td {
	padding: 15px 18px;
	text-align: left;
	border-bottom: 1px solid var(--gl-line);
}

.tb-table thead th {
	font-size: 12px;
	font-weight: 700;
	color: var(--gl-white);
	background: var(--gl-navy);
}

.tb-table thead th:first-child {
	border-radius: 11px 0 0;
}

.tb-table thead th:last-child {
	border-radius: 0 11px 0 0;
}

.tb-table tbody th {
	font-weight: 700;
	color: var(--gl-navy);
}

.tb-table tbody td {
	color: #3f4b5d;
}

.tb-table tbody tr:last-child > * {
	border-bottom: 0;
}

.tb-table tbody tr:hover {
	background: #f8fafc;
}

/* Needs */
.tb-needs__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 14px;
}

.tb-need {
	display: flex;
	min-width: 0;
	min-height: 82px;
	padding: 16px 18px;
	align-items: center;
	gap: 13px;
	border: 1px solid var(--gl-line);
	border-radius: var(--gl-radius);
	background: var(--gl-white);
	box-shadow: var(--gl-shadow);
	transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.tb-need:hover {
	transform: translateY(-2px);
	border-color: rgba(28, 55, 103, .5);
	box-shadow: var(--gl-shadow-md);
}

.tb-need__icon {
	display: grid;
	width: 38px;
	height: 38px;
	flex: 0 0 38px;
	place-items: center;
	border-radius: 10px;
	color: var(--gl-navy);
	background: #edf4ff;
}

/* Ảnh thay cho icon — vuông 64px */
.tb-need__icon--image {
	width: 64px;
	height: 64px;
	flex-basis: 64px;
	overflow: hidden;
	background: none;
}

.tb-need__icon--image img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.tb-need__copy {
	display: flex;
	min-width: 0;
	flex: 1;
	flex-direction: column;
	gap: 3px;
}

.tb-need__copy strong {
	font-size: 13.5px;
	font-weight: 700;
	line-height: 1.35;
	color: var(--gl-navy);
}

.tb-need__copy small {
	font-size: 13px;
	line-height: 1.45;
	color: var(--gl-muted);
}

.tb-need__arrow {
	display: grid;
	flex: 0 0 auto;
	place-items: center;
	color: #8190a3;
	transition: transform .2s ease, color .2s ease;
}

.tb-need:hover .tb-need__arrow {
	transform: translateX(3px);
	color: var(--gl-navy);
}

/* Posts */
.tb-posts {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 20px;
}

.tb-posts--slider {
	grid-template-columns: none;
	grid-auto-flow: column;
	grid-auto-columns: calc((100% - 40px) / 3);
	overflow-x: auto;
	overscroll-behavior-inline: contain;
	scroll-behavior: smooth;
	scroll-snap-type: inline mandatory;
	scrollbar-width: none;
}

.tb-posts--slider::-webkit-scrollbar {
	display: none;
}

.tb-posts--slider .tb-post {
	scroll-snap-align: start;
}

.tb-posts--slider .tb-post:last-child {
	grid-column: auto;
}

.tb-posts__nav {
	display: flex;
	justify-content: flex-end;
	gap: 10px;
	margin-top: 18px;
}

.tb-posts__button {
	display: inline-flex;
	width: 42px;
	height: 42px;
	align-items: center;
	justify-content: center;
	padding: 0;
	border: 1px solid var(--gl-line);
	border-radius: 50%;
	background: var(--gl-white);
	color: var(--gl-navy);
	cursor: pointer;
	transition: color .2s ease, background-color .2s ease, border-color .2s ease, opacity .2s ease;
}

.tb-posts__button:hover:not(:disabled) {
	border-color: var(--gl-navy);
	background: var(--gl-navy);
	color: var(--gl-white);
}

.tb-posts__button:focus-visible {
	outline: 3px solid rgba(26, 74, 124, .25);
	outline-offset: 2px;
}

.tb-posts__button:disabled {
	opacity: .35;
	cursor: not-allowed;
}

.tb-posts__button--prev svg {
	transform: rotate(180deg);
}

.tb-post {
	overflow: hidden;
	border: 1px solid var(--gl-line);
	border-radius: var(--gl-radius);
	background: var(--gl-white);
	box-shadow: var(--gl-shadow);
	transition: transform .2s ease, box-shadow .2s ease;
}

.tb-post:hover {
	transform: translateY(-3px);
	box-shadow: var(--gl-shadow-md);
}

.tb-post__media {
	display: block;
	overflow: hidden;
	aspect-ratio: 16 / 9;
	background: linear-gradient(135deg, #f1f5f9, #e6edf6);
}

.tb-post__media img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .35s ease;
}

.tb-post:hover .tb-post__media img {
	transform: scale(1.035);
}

.tb-post__placeholder {
	display: flex;
	width: 100%;
	height: 100%;
	align-items: center;
	justify-content: center;
	flex-direction: column;
	gap: 8px;
	color: #94a3b8;
}

.tb-post__placeholder small {
	font-size: 10px;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
}

.tb-post__body {
	padding: 18px 18px 20px;
}

.tb-post__label {
	margin: 0 0 8px;
	font-size: 10px;
	font-weight: 700;
	letter-spacing: .06em;
	text-transform: uppercase;
	color: var(--gl-muted);
}

.tb-post__title {
	margin: 0;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.45;
	color: var(--gl-navy);
}

.tb-post__title a:hover {
	color: #315d94;
}

.tb-post__excerpt {
	margin: 10px 0 0;
	font-size: 12.5px;
	line-height: 1.65;
	color: var(--gl-muted);
}

/* FAQ */
.tb-faq-layout {
	display: grid;
	grid-template-columns: minmax(240px, .75fr) minmax(0, 1.25fr);
	align-items: start;
	gap: clamp(36px, 7vw, 96px);
}

.tb-faq-layout .tb-heading {
	position: sticky;
	top: 96px;
	margin: 0;
}

.tb-faq {
	display: flex;
	flex-direction: column;
	border-top: 1px solid var(--gl-line);
}

.tb-faq__item {
	border-bottom: 1px solid var(--gl-line);
}

.tb-faq__question {
	display: flex;
	min-height: 64px;
	padding: 18px 0;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	cursor: pointer;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.5;
	color: var(--gl-navy);
	list-style: none;
}

.tb-faq__question::-webkit-details-marker {
	display: none;
}

.tb-faq__question:focus-visible {
	outline: 3px solid rgba(245, 200, 66, .55);
	outline-offset: 4px;
}

.tb-faq__icon {
	display: grid;
	width: 30px;
	height: 30px;
	flex: 0 0 30px;
	place-items: center;
	border-radius: 50%;
	color: var(--gl-navy);
	background: var(--gl-white);
	transition: transform .2s ease, background .2s ease;
}

.tb-faq__item[open] .tb-faq__icon {
	transform: rotate(45deg);
	background: var(--gl-yellow);
}

.tb-faq__answer {
	padding: 0 48px 20px 0;
}

.tb-faq__answer p {
	margin: 0;
	font-size: 14px;
	line-height: 1.75;
	color: #4b5563;
}

/* CTA */
.tb-cta {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	padding-block: 38px;
	color: var(--gl-white);
	background:
		radial-gradient(520px 180px at 80% 50%, rgba(57, 101, 151, .72), transparent 75%),
		linear-gradient(110deg, #112d50, #183d68 68%, #264f7d);
}

.tb-cta::before {
	position: absolute;
	inset: 0;
	z-index: -2;
	content: "";
	background-image: var(--tb-cta-image, none);
	background-position: center;
	background-size: cover;
}

.tb-cta::after {
	position: absolute;
	inset: 0;
	z-index: -1;
	content: "";
	background:
		linear-gradient(90deg, rgba(9, 33, 61, .9) 0%, rgba(16, 51, 88, .76) 58%, rgba(16, 51, 88, .58) 100%),
		radial-gradient(520px 180px at 80% 50%, rgba(57, 101, 151, .44), transparent 75%);
}

.tb-cta__inner {
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 32px;
}

.tb-cta__title {
	margin: 0;
	font-size: clamp(25px, 3vw, 36px);
	font-weight: 700;
	line-height: 1.18;
	letter-spacing: -.03em;
	color: var(--gl-white);
}

.tb-cta__desc {
	max-width: 650px;
	margin: 9px 0 0;
	font-size: 13.5px;
	line-height: 1.65;
	color: rgba(255, 255, 255, .74);
}

.tb-cta__actions {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 10px;
	flex: 0 0 auto;
}

.tb-cta__actions .gl-btn {
	white-space: nowrap;
}

.tb-btn--light {
	border: 1px solid rgba(255, 255, 255, .45);
	color: var(--gl-white);
	background: rgba(255, 255, 255, .08);
}

.tb-btn--light:hover {
	border-color: var(--gl-white);
	color: var(--gl-navy);
	background: var(--gl-white);
}

@media (max-width: 1080px) {
	.tb-brands__grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (max-width: 820px) {
	.tb-hero__inner {
		padding-block: 42px;
	}

	.tb-hero__body {
		max-width: 650px;
	}

	.tb-brands__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.tb-guide__grid,
	.tb-needs__grid,
	.tb-posts {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.tb-guide__item:last-child,
	.tb-post:last-child {
		grid-column: 1 / -1;
	}

	.tb-posts--slider {
		grid-template-columns: none;
		grid-auto-columns: calc((100% - 20px) / 2);
	}

	.tb-faq-layout {
		grid-template-columns: 1fr;
		gap: 28px;
	}

	.tb-faq-layout .tb-heading {
		position: static;
	}

	.tb-cta__inner {
		align-items: flex-start;
		flex-direction: column;
	}

	.tb-cta__actions {
		justify-content: flex-start;
	}
}

@media (max-width: 560px) {
	.gl-crumb__list {
		overflow: hidden;
		white-space: nowrap;
	}

	.gl-crumb__list li:last-child {
		overflow: hidden;
		text-overflow: ellipsis;
	}

	.tb-section {
		padding-block: 48px;
	}

	.tb-heading {
		margin-bottom: 24px;
	}

	.tb-hero::before {
		background-position: 62% center;
	}

	.tb-hero::after {
		background: linear-gradient(90deg, rgba(8, 34, 63, .88), rgba(9, 38, 72, .62));
	}

	.tb-hero__inner {
		padding-block: 36px;
	}

	.tb-hero__title {
		font-size: clamp(32px, 10vw, 43px);
	}

	.tb-hero__desc {
		font-size: 14px;
	}

	.tb-brands__grid,
	.tb-guide__grid,
	.tb-needs__grid,
	.tb-posts {
		grid-template-columns: 1fr;
	}

	.tb-guide__item:last-child,
	.tb-post:last-child {
		grid-column: auto;
	}

	.tb-posts--slider {
		grid-template-columns: none;
		grid-auto-columns: 86%;
	}

	.tb-brand__logo {
		min-height: 104px;
	}

	.tb-guide__item {
		min-height: auto;
		padding: 20px 20px 24px;
	}

	.tb-need {
		min-height: 78px;
	}

	.tb-table th,
	.tb-table td {
		padding: 13px 15px;
	}

	.tb-faq__question {
		font-size: 12.5px;
	}

	.tb-faq__answer {
		padding-right: 0;
	}

	.tb-cta {
		padding-block: 34px;
	}

	.tb-cta__actions {
		width: 100%;
		align-items: stretch;
		flex-direction: column;
	}

	.tb-cta__actions .gl-btn {
		width: 100%;
		justify-content: center;
	}
}

@media (prefers-reduced-motion: reduce) {
	.tb-brand,
	.tb-brand__more svg,
	.tb-need,
	.tb-need__arrow,
	.tb-post,
	.tb-post__media img,
	.tb-posts__button,
	.tb-faq__icon {
		transition: none;
	}

	.tb-posts--slider {
		scroll-behavior: auto;
	}
}
