/*
 * CSS cho các trang nội dung và chi tiết dùng chung.
 * Giữ các breakpoint và thứ tự ghi đè; styles.php quyết định vị trí nạp so với style.css.
 */


.products-container { max-width: 1180px; padding-left: 20px; padding-right: 20px; }
.products-page .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.products-page .page-header h1 { color: var(--primary); }
.products-page .product-card { border-radius: var(--radius); }
.products-page .product-detail-button { background: var(--accent); color: white; }
.search-summary { padding: 16px 25px; background: #eff6ff; color: var(--primary); overflow-wrap: anywhere; }
.search-summary a { margin-left: 12px; text-decoration: underline; }
.service-card h3 a { color: inherit; text-decoration: none; }
.service-card h3 a:hover { color: var(--accent); }
.page-hero { padding: 48px 0; background: var(--primary-dark); color: white; }
.page-hero h1 { margin-bottom: 12px; font-size: clamp(28px, 4vw, 42px); line-height: 1.25; }
.page-hero p { max-width: 720px; margin-bottom: 0; color: #d7e5f2; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 24px; font-size: 13px; }
.breadcrumbs a { color: inherit; }
.inner-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 26px 0 42px;
    background: linear-gradient(110deg, #082f52 15%, #0f3d68 100%);
}
.inner-hero::before {
    content: "";
    position: absolute;
    z-index: -1;
    inset: 0 0 0 55%;
    opacity: .12;
    background-image: linear-gradient(#8cb9df 1px, transparent 1px), linear-gradient(90deg, #8cb9df 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: linear-gradient(90deg, transparent, black);
    pointer-events: none;
}
.inner-hero .breadcrumbs { margin-bottom: 28px; color: #cfdeed; font-size: 12px; }
.inner-hero .breadcrumbs a { text-decoration: none; }
.inner-hero .breadcrumbs a:hover { color: white; text-decoration: underline; }
.inner-hero-layout { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.inner-hero-eyebrow { display: block; margin-bottom: 10px; color: #9dcbf5; font-size: 11px; font-weight: 700; letter-spacing: .13em; }
.inner-hero h1 { margin-bottom: 12px; font-size: clamp(34px, 4.2vw, 52px); letter-spacing: -.035em; }
.inner-hero h1 > span { color: #60a5fa; }
.inner-hero-copy, .inner-hero-identity { min-width: 0; overflow-wrap: anywhere; }
.inner-hero.inner-hero-detail h1 { font-size: clamp(28px, 3.2vw, 40px); line-height: 1.35; letter-spacing: -.02em; }
.inner-hero-copy > p { max-width: 510px; font-size: 15px; line-height: 1.8; }
.inner-hero-identity { padding: 8px 0 8px 28px; border-left: 2px solid #5798d2; }
.inner-hero p.inner-hero-company { color: white; font-size: 16px; font-weight: 600; line-height: 1.7; }
.inner-hero-identity ul { display: flex; flex-wrap: wrap; gap: 8px 16px; margin: 16px 0 0; padding: 0; list-style: none; color: #cfdeed; font-size: 12px; }
.inner-hero-identity li::before { content: ""; display: inline-block; width: 4px; height: 4px; margin-right: 7px; background: #79b7f0; border-radius: 50%; vertical-align: middle; }
@media (max-width: 700px) {
    .page-hero.inner-hero { padding: 22px 0 30px; }
    .inner-hero-layout { grid-template-columns: 1fr; gap: 24px; }
    .inner-hero .breadcrumbs { margin-bottom: 24px; }
    .inner-hero-identity { padding: 0 0 0 16px; }
    .inner-hero p.inner-hero-company { font-size: 14px; }
    .inner-hero-identity ul { margin-top: 10px; }
}
.detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; align-items: start; }
.detail-layout > * { min-width: 0; max-width: 100%; }
.detail-photo { width: 100%; height: 420px; object-fit: contain; padding: 24px; background: white; border: 1px solid var(--line); border-radius: var(--radius); }
.detail-placeholder { display: grid; place-items: center; color: var(--muted); }
.detail-thumbs { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.detail-thumbs button { border: 1px solid var(--line); background: white; border-radius: 8px; cursor: pointer; padding: 4px; }
.detail-thumbs button[aria-pressed="true"] { border: 2px solid var(--accent); }
.detail-thumbs img { width: 64px; height: 64px; object-fit: contain; }
.detail-summary h2 { text-align: left; text-transform: none; }
.detail-facts { margin: 24px 0; }
.detail-facts div { display: grid; grid-template-columns: 130px 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.detail-facts dt { color: var(--muted); }
.detail-facts dd { margin: 0; overflow-wrap: anywhere; }
.detail-facts .product-price { color: var(--accent); font-size: 18px; font-weight: 800; }
.page-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin: 24px 0; }
.page-panel { background: white; padding: 30px; border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 24px; }
.page-panel h2 { text-align: left; text-transform: none; }
.page-copy { white-space: normal; overflow-wrap: anywhere; }
.detail-content { margin-top: 40px; }
.product-reviews { margin-top: 24px; }
.review-list { display: grid; gap: 18px; margin-bottom: 28px; }
.review-item { padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.review-heading { display: flex; justify-content: space-between; gap: 16px; align-items: center; }
.review-stars { color: #f59e0b; letter-spacing: 2px; white-space: nowrap; }
.review-stars span { color: #cbd5e1; }
.review-item p { margin: 8px 0; white-space: pre-line; }
.review-item time { color: var(--muted); font-size: 13px; }
.review-empty, .review-alert { color: var(--muted); }
.review-alert { padding: 12px 14px; border-radius: 8px; background: #fee2e2; color: #991b1b; }
.product-reviews .review-form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 20px; }
.product-reviews .review-form label { display: grid; gap: 7px; color: var(--primary); font-size: 14px; font-weight: 700; }
.product-reviews .review-form input, .product-reviews .review-form select, .product-reviews .review-form textarea { width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid #cbd5e1; border-radius: 8px; background: #fff; color: var(--text); font: inherit; font-weight: 400; }
.product-reviews .review-form textarea { min-height: 120px; resize: vertical; }
.product-reviews .review-form input:focus, .product-reviews .review-form select:focus, .product-reviews .review-form textarea:focus { outline: 3px solid #dbeafe; border-color: var(--accent); }
.product-reviews .review-form button { width: fit-content; min-height: 46px; padding: 10px 22px; border: 0; border-radius: 8px; cursor: pointer; font: inherit; font-weight: 700; }
.review-full { grid-column: 1 / -1; }
.page-outline { color: var(--primary); border: 1px solid var(--primary); background: white; }
.page-photo { width: 100%; max-height: 420px; object-fit: contain; border-radius: var(--radius); }
.pagination { display: flex; justify-content: center; align-items: center; gap: 15px; padding: 25px 0; flex-wrap: wrap; }
.pagination a { color: var(--primary); padding: 8px 16px; border: 1px solid var(--line); border-radius: 8px; background: white; }
a:focus-visible, button:focus-visible { outline: 3px solid #60a5fa; outline-offset: 4px; }
@media (max-width: 1100px) {

    .products-page .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
    .detail-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; }
    .detail-photo { height: 300px; }
    .page-panel { padding: 22px; }
    .review-form { grid-template-columns: 1fr; }
    .review-full { grid-column: auto; }
    .page-hero { padding: 32px 0; }
    .products-page .product-grid { grid-template-columns: 1fr; }
}
