/* Đổi màu chủ đạo bằng cách ghi đè biến trong theme: .tt { --tt-accent: #e30613; } */
.tt {
	--tt-accent: orange;
	--tt-tab-radius: 0 20px 20px 0;
	--tt-border: #e3e6ea;
	--tt-muted: #f5f7fa;
	--tt-radius: 8px;
	margin-bottom: 2em;
}
.tt, .tt *, .tt *::before, .tt *::after { box-sizing: border-box; }

.tt-hero {
	aspect-ratio: 3 / 1;
	border-radius: var(--tt-radius);
	overflow: hidden;
	margin-bottom: 1.5em;
}
.tt-hero img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* Thanh tab: kéo ngang trên mobile */
.tt-nav {
	display: flex;
	gap: 4px;
	border-bottom: 2px solid var(--tt-accent);
	overflow-x: auto;
	scrollbar-width: none;
	margin-bottom: 1.5em;
}
.tt-nav::-webkit-scrollbar { display: none; }

.tt .tt-tab {
	flex: 0 0 auto;
	appearance: none;
	box-shadow: none;
	border-radius: var(--tt-tab-radius);
	text-transform: none;
	letter-spacing: normal;
	min-height: 0;
	line-height: 1.4;
	background: none;
	border: 0;
	padding: .75em 1.1em;
	font: inherit;
	font-weight: 600;
	color: inherit;
	opacity: .7;
	cursor: pointer;
	white-space: nowrap;
	transition: opacity .15s, background-color .15s, color .15s;
}
.tt .tt-tab:hover { opacity: 1; color: var(--tt-accent); }
.tt .tt-tab[aria-selected="true"] {
	opacity: 1;
	color: #fff;
	background-color: var(--tt-accent);
}
.tt .tt-tab:focus-visible {
	outline: 2px solid var(--tt-accent);
	outline-offset: -2px;
}

.tt-panel[hidden] { display: none; }
.tt-content > :first-child { margin-top: 0; }
.tt-content img { max-width: 100%; height: auto; }

/* Giới thiệu: hàng chữ + ảnh so le */
.tt-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 2em;
	align-items: center;
	margin-bottom: 2em;
}
.tt-row--reverse .tt-row-text { order: 2; }
.tt-row-text h3 { margin-top: 0; }
.tt-row-media img {
	width: 100%;
	height: auto;
	border-radius: var(--tt-radius);
	display: block;
}

/* Khóa học */
.tt-courses {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 1.5em;
}
.tt-course {
	border: 1px solid var(--tt-border);
	border-radius: var(--tt-radius);
	overflow: hidden;
	display: flex;
	flex-direction: column;
}
.tt-course-thumb { aspect-ratio: 53 / 30; background: var(--tt-muted); }
.tt-course-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tt-course-body { padding: 1em 1.25em 1.25em; }
.tt-course-name { margin: 0 0 .5em; font-size: 1.15em; }
.tt-course-desc p { margin: 0 0 .75em; }
.tt-course-more summary {
	cursor: pointer;
	font-weight: 600;
	color: var(--tt-accent);
}
.tt-course-more[open] summary { margin-bottom: .75em; }

/* Hình ảnh */
.tt-gallery {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 10px;
}
.tt-gallery-item {
	display: block;
	aspect-ratio: 4 / 3;
	overflow: hidden;
	border-radius: var(--tt-radius);
}
.tt-gallery-item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform .3s;
}
.tt-gallery-item:hover img { transform: scale(1.05); }

/* Lightbox */
.tt-lb {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(0, 0, 0, .9);
	display: flex;
	align-items: center;
	justify-content: center;
}
.tt-lb img { max-width: 92vw; max-height: 88vh; object-fit: contain; }
.tt-lb button {
	position: absolute;
	background: none;
	border: 0;
	color: #fff;
	font-size: 2.5rem;
	line-height: 1;
	padding: .3em .5em;
	cursor: pointer;
}
.tt-lb-close { top: 10px; right: 10px; }
.tt-lb-prev { left: 10px; top: 50%; transform: translateY(-50%); }
.tt-lb-next { right: 10px; top: 50%; transform: translateY(-50%); }

@media (max-width: 767px) {
	.tt-row { grid-template-columns: 1fr; gap: 1em; }
	.tt-row--reverse .tt-row-text { order: 0; }
	.tt-row .tt-row-media { order: -1; }
	.tt-gallery { grid-template-columns: repeat(2, 1fr); }
}
