/* ==========================================================
   Phoenix Unite – trang sản phẩm tối giản
   Mọi style đều nằm dưới .pu-product để không ảnh hưởng trang khác.
   ========================================================== */

.pu-product {
	--pu-ink: #15171c;
	--pu-text: #44474f;
	--pu-muted: #5b5f68;
	--pu-line: #e7e5e1;
	--pu-soft: #f3f1ee;
	--pu-accent: #c2410c;
	--pu-accent-soft: #fff4ec;
	--pu-radius: 16px;
	--pu-display: "Sora", system-ui, sans-serif;
	--pu-body: "DM Sans", system-ui, sans-serif;

	font-family: var(--pu-body);
	color: var(--pu-ink);
	max-width: 1120px;
	margin: 0 auto;
	padding: 24px 24px 80px;
	box-sizing: border-box;
}

.pu-product *,
.pu-product *::before,
.pu-product *::after { box-sizing: border-box; }

/* ---------- Bố cục 2 cột ---------- */
.pu-layout {
	display: flex;
	flex-wrap: wrap;
	gap: 56px;
	align-items: flex-start;
}
.pu-main {
	flex: 1 1 580px;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 48px;
}
.pu-side {
	flex: 1 1 320px;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 20px;
}

/* ---------- Chữ ---------- */
.pu-h2 {
	margin: 0 0 16px;
	font-family: var(--pu-display);
	font-size: 22px;
	font-weight: 700;
	letter-spacing: -0.015em;
	color: var(--pu-ink);
}
.pu-h3 {
	margin: 0 0 4px;
	font-family: var(--pu-body);
	font-size: 16px;
	font-weight: 600;
	color: var(--pu-ink);
}
.pu-prose { font-size: 16px; line-height: 1.7; color: #33363d; }
.pu-prose p { margin: 0 0 14px; }
.pu-prose p:last-child { margin-bottom: 0; }
.pu-icon { width: 22px; height: 22px; flex: none; }

/* ---------- Video ---------- */
.pu-video-block { display: flex; flex-direction: column; gap: 14px; }
.pu-video {
	position: relative;
	aspect-ratio: 16 / 9;
	border-radius: var(--pu-radius);
	overflow: hidden;
	background: var(--pu-ink);
}
.pu-video iframe,
.pu-video video {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}
/* Ảnh demo khi chưa có video */
.pu-media__main {
	border-radius: var(--pu-radius);
	overflow: hidden;
	background: var(--pu-soft);
}
.pu-media__main img { display: block; width: 100%; height: auto; margin: 0; }
.pu-media__thumbs {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
	gap: 10px;
}
.pu-thumb {
	padding: 0;
	border: 1px solid var(--pu-line);
	border-radius: 10px;
	overflow: hidden;
	background: #fff;
	aspect-ratio: 1 / 1;
	cursor: pointer;
}
.pu-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; margin: 0; }
.pu-thumb.is-active { border: 2px solid var(--pu-accent); }
.pu-thumb:focus-visible { outline: 2px solid var(--pu-accent); outline-offset: 2px; }

.pu-chapters { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.pu-chapter {
	min-height: 44px;
	padding: 0;
	border: 0;
	background: none;
	font: inherit;
	font-size: 14px;
	color: var(--pu-text);
	cursor: pointer;
	text-underline-offset: 6px;
}
.pu-chapter__time { color: #6b6f78; margin-right: 4px; }
.pu-chapter:hover { color: var(--pu-ink); }
.pu-chapter.is-active {
	color: var(--pu-ink);
	font-weight: 600;
	text-decoration: underline;
	text-decoration-color: var(--pu-accent);
	text-decoration-thickness: 2px;
}
.pu-chapter:focus-visible { outline: 2px solid var(--pu-accent); outline-offset: 2px; border-radius: 4px; }

/* ---------- Lợi ích ---------- */
.pu-benefits {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 24px 32px;
}
.pu-benefit { display: flex; gap: 14px; }
.pu-benefit .pu-icon { color: var(--pu-accent); margin-top: 2px; }
.pu-benefit p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--pu-muted); }

/* ---------- FAQ ---------- */
.pu-faq details { border-bottom: 1px solid var(--pu-line); }
.pu-faq summary {
	list-style: none;
	cursor: pointer;
	min-height: 56px;
	padding: 14px 32px 14px 0;
	position: relative;
	display: flex;
	align-items: center;
	font-size: 16px;
	font-weight: 500;
}
.pu-faq summary::-webkit-details-marker { display: none; }
.pu-faq summary::after {
	content: "+";
	position: absolute;
	right: 0;
	font-size: 20px;
	color: #6b6f78;
}
.pu-faq details[open] summary::after { content: "−"; }
.pu-faq details p { margin: 0; padding: 0 0 16px; font-size: 15px; line-height: 1.6; color: var(--pu-text); }

/* ---------- Thẻ cột phải ---------- */
.pu-card {
	border: 1px solid var(--pu-line);
	border-radius: var(--pu-radius);
	padding: 24px;
	display: flex;
	flex-direction: column;
	gap: 14px;
	background: #fff;
}
.pu-card__title { margin: 0; font-family: var(--pu-body); font-size: 15px; font-weight: 600; color: var(--pu-ink); }

/* Khung mua */
.pu-buy { padding: 28px; gap: 18px; }
.pu-eyebrow {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--pu-accent);
}
.pu-title {
	margin: 0;
	font-family: var(--pu-display);
	font-size: 30px;
	line-height: 1.15;
	letter-spacing: -0.025em;
	font-weight: 700;
	color: var(--pu-ink);
}
.pu-price { font-family: var(--pu-display); font-size: 28px; font-weight: 700; color: var(--pu-ink); }
.pu-price del { font-size: 18px; color: #8b909a; font-weight: 500; margin-right: 6px; }
.pu-price ins { text-decoration: none; }
.pu-note { margin: 0; font-size: 14px; line-height: 1.5; color: var(--pu-muted); }

/* Form mua của WooCommerce */
.pu-buy form.cart { margin: 0; display: flex; flex-direction: column; gap: 14px; }
.pu-buy .variations { width: 100%; border: 0; margin: 0; }
.pu-buy .variations tr { display: flex; flex-direction: column; gap: 8px; }
.pu-buy .variations th,
.pu-buy .variations td { padding: 0; border: 0; text-align: left; background: none; }
.pu-buy .variations label { font-size: 14px; font-weight: 600; }
.pu-buy .reset_variations { font-size: 13px; color: var(--pu-muted); margin-top: 6px; display: inline-block; }
.pu-buy .woocommerce-variation-price { display: none; } /* giá đã hiện ở trên */
.pu-buy .woocommerce-variation-add-to-cart,
.pu-buy form.cart:not(.variations_form) { display: flex; gap: 10px; flex-wrap: wrap; }
.pu-buy .quantity { display: none; } /* sản phẩm số: luôn mua 1 */
.pu-buy .single_add_to_cart_button {
	flex: 1 1 auto;
	width: 100%;
	min-height: 54px;
	border: 0;
	border-radius: 12px;
	background: var(--pu-accent) !important;
	color: #fff !important;
	font-family: var(--pu-body);
	font-size: 16px;
	font-weight: 600;
	cursor: pointer;
	transition: opacity .2s;
}
.pu-buy .single_add_to_cart_button:hover { opacity: .9; }
.pu-buy .single_add_to_cart_button.disabled { opacity: .45; cursor: not-allowed; }

/* Nút chọn biến thể (JS tạo từ dropdown) */
.pu-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pu-pill {
	min-height: 44px;
	padding: 8px 16px;
	border: 1px solid #dddad5;
	border-radius: 999px;
	background: #fff;
	color: var(--pu-ink);
	font: 500 14px/1.2 var(--pu-body);
	cursor: pointer;
}
.pu-pill:hover { border-color: var(--pu-ink); }
.pu-pill.is-active { border: 1.5px solid var(--pu-ink); font-weight: 600; }
.pu-pill:disabled { opacity: .4; cursor: not-allowed; text-decoration: line-through; }
.pu-pill:focus-visible { outline: 2px solid var(--pu-accent); outline-offset: 2px; }
.pu-visually-hidden {
	position: absolute !important;
	width: 1px; height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* Người review */
.pu-creator__head { display: flex; align-items: center; gap: 12px; }
.pu-creator__head strong { display: block; font-size: 15px; }
.pu-creator__head span { display: block; font-size: 13px; color: var(--pu-muted); }
.pu-avatar { width: 48px; height: 48px; border-radius: 999px; object-fit: cover; flex: none; }
.pu-avatar--empty { display: block; background: var(--pu-soft); }
.pu-creator p { margin: 0; font-size: 14px; line-height: 1.6; color: var(--pu-text); }
.pu-link { font-size: 14px; font-weight: 600; color: var(--pu-accent); text-decoration: none; }
.pu-link:hover { text-decoration: underline; }

/* File nhận được */
.pu-files { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 12px; font-size: 14px; }
.pu-files li { display: flex; align-items: center; gap: 10px; }
.pu-files .pu-icon { width: 18px; height: 18px; color: var(--pu-muted); stroke-width: 1.8; }
.pu-files__name { flex: 1; }
.pu-files__meta { color: #6b6f78; }

/* Sản phẩm liên quan */
.pu-related { display: flex; flex-direction: column; gap: 14px; }
.pu-related__item { display: flex; align-items: center; gap: 12px; color: var(--pu-ink); text-decoration: none; }
.pu-related__item:hover strong { color: var(--pu-accent); }
.pu-related__thumb {
	position: relative;
	flex: none;
	width: 64px;
	height: 64px;
	border-radius: 12px;
	overflow: hidden;
	background: var(--pu-ink);
	display: flex;
	align-items: center;
	justify-content: center;
}
.pu-related__thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; margin: 0; }
.pu-related__thumb .pu-icon {
	position: relative;
	width: 26px; height: 26px;
	padding: 6px;
	border-radius: 999px;
	background: rgba(21, 23, 28, .6);
	color: #fff;
}
.pu-related__text { display: flex; flex-direction: column; gap: 2px; }
.pu-related__text strong { font-size: 14px; }
.pu-related__text > span { font-size: 13px; color: var(--pu-muted); }

/* ---------- Điện thoại ---------- */
@media (max-width: 720px) {
	.pu-product { padding: 16px 16px 56px; }
	.pu-layout { gap: 32px; }
	.pu-main { gap: 36px; }
	.pu-title { font-size: 26px; }
	/* Khung mua hiện ngay sau video */
	.pu-layout { flex-direction: column; }
	.pu-main, .pu-side { display: contents; }
	.pu-video-block { order: 1; }
	.pu-buy { order: 2; }
	.pu-section { order: 3; }
	.pu-card:not(.pu-buy) { order: 4; }
}
