/* ==========================================================================
   Bổ sung cho WordPress / WooCommerce (style.css là CSS gốc từ bản thiết kế UI/)
   ========================================================================== */

/* Menu: mục cha của trang hiện tại */
.nav__link.is-active { color: var(--red); }
@media (min-width: 981px) {
  .nav__link.is-active::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -17px; height: 3px; background: var(--red); border-radius: 3px 3px 0 0; }
}
.mega h3 a { color: inherit; padding: 0; font-size: inherit; }
.mega a[aria-current] { color: var(--red); font-weight: 600; }

/* Class trợ năng của WordPress */
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Thẻ bài viết: tiêu đề có thể là h2 (trang danh sách) hoặc h3 (trang chủ) */
.post-card .post-card__title { font-size: 18px; margin-bottom: 8px; font-family: var(--font-head); font-weight: 700; letter-spacing: 0; line-height: 1.35; }
.post-card .post-card__title a::after { content: ""; position: absolute; inset: 0; }
.post-card--wide .post-card__title { font-family: var(--font-display); font-size: clamp(22px, 2.4vw, 30px); line-height: 1.2; }
.post-card--wide .link-arrow { position: relative; z-index: 2; }

/* Thanh công cụ danh mục sản phẩm (WooCommerce) */
.toolbar .woocommerce-result-count { margin: 0; color: var(--muted); font-size: 14.5px; }
.toolbar .woocommerce-ordering { margin: 0; }
@media (max-width: 680px) { .toolbar .woocommerce-result-count { order: 3; width: 100%; } }
.product__price del { color: var(--muted); font-weight: 500; margin-right: 4px; }
.product__price ins { text-decoration: none; }

/* Trang sản phẩm */
.pdp-short { margin-bottom: 18px; }
.pdp-short p:last-child { margin-bottom: 0; }
.pdp-price .amount { color: inherit; }
.pdp-gallery__main img { width: 100%; aspect-ratio: 1; }
.pdp-gallery__thumbs img { width: 100%; height: 100%; aspect-ratio: 1; }

/* Nội dung soạn trong trình soạn thảo (bài viết, mô tả sản phẩm, danh mục) */
.entry-content img { height: auto; max-width: 100%; border-radius: var(--radius-lg); }
.entry-content > *:first-child { margin-top: 0; }
.entry-content .alignleft { float: left; margin: .4em 1.4em 1em 0; max-width: 50%; }
.entry-content .alignright { float: right; margin: .4em 0 1em 1.4em; max-width: 50%; }
.entry-content .aligncenter { display: block; margin-inline: auto; }
.entry-content::after { content: ""; display: table; clear: both; }
.entry-content .wp-caption { max-width: 100%; margin: 1.6em auto; }
.entry-content .wp-caption-text { font-size: 14px; color: var(--muted); text-align: center; margin-top: 8px; }
.entry-content figure.wp-caption img { width: auto; max-width: 100%; max-height: 460px; margin-inline: auto; display: block; }
.entry-content iframe, .entry-content video, .entry-content .wp-video { max-width: 100% !important; border-radius: var(--radius-lg); }
.entry-content .wp-video { width: min(480px, 100%) !important; }
.entry-content iframe[src*="youtube"] { width: 100%; height: auto; aspect-ratio: 16/9; }
.entry-content table { display: block; overflow-x: auto; }
.entry-content h2 strong, .entry-content h3 strong { font-weight: inherit; }
@media (max-width: 600px) {
  .entry-content .alignleft, .entry-content .alignright { float: none; margin: 1em 0; max-width: 100%; }
}
.prose.read-more { max-width: none; }
.tabs__panel.prose { max-width: 860px; }

/* Mục lục do plugin LuckyWP Table of Contents chèn vào bài viết */
.entry-content .lwptoc { margin: 1.6em 0; }
.entry-content .lwptoc_i { background: var(--stone) !important; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 18px 22px !important; }
.entry-content .lwptoc a { text-decoration: none; color: var(--ink-2); }
.entry-content .lwptoc a:hover { color: var(--red); }

/* Thẻ bài viết */
.post-tags { flex-wrap: wrap; }

/* Bình luận */
.comments { border-top: 1px solid var(--line); padding-top: 32px; }
.comment-list { list-style: none; padding: 0; display: grid; gap: 18px; margin-bottom: 32px; }
.comment-list .children { list-style: none; padding-left: 24px; margin-top: 18px; }
.comment-body { padding: 16px 18px; background: var(--stone); border-radius: var(--radius-lg); font-size: 15px; }
.comment-meta { display: flex; flex-wrap: wrap; gap: 8px 14px; font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.comment-author img { border-radius: 50%; vertical-align: middle; margin-right: 8px; }
.comment-form { display: grid; gap: 12px; }
.comment-form label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 4px; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea { width: 100%; padding: 10px 14px; border: 1px solid var(--line); border-radius: var(--radius); font: inherit; }
.comment-reply-title { font-size: 22px; }

/* Thông báo của WooCommerce (nếu có) */
.woocommerce-notices-wrapper:empty { display: none; }
.woocommerce-info, .woocommerce-message, .woocommerce-error { list-style: none; padding: 14px 18px; margin: 0 0 20px; background: var(--stone); border-left: 3px solid var(--red); border-radius: var(--radius); }

/* Trang sản phẩm: nút Zalo đứng một mình thì giãn hết hàng */
.pdp-actions .btn:nth-child(2):last-child { grid-column: 1 / -1; }
