/* ============ Chi tiết Sản phẩm (single-product.php) ============ */
.hpd {
    --navy: #0a2a66;
    --navy-dark: #071d47;
    --blue: #0a4fc1;
    --blue-hover: #083f9c;
    --bg: #f4f7fb;
    --tint: #e6eefa;
    --line: #dbe3ef;
    --text: #3d4a63;
    --muted: #5b6780;
    --gold-1: #f3e0ab;
    --gold-2: #d6ad5a;
    --sans: "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.7;
    color: var(--text);
    background: var(--bg);
}

/* flatsome-child.css ép font Inter !important cho h1-h6, p, span */
.hpd h1,
.hpd h2,
.hpd h3,
.hpd h4,
.hpd p,
.hpd span,
.hpd li,
.hpd td,
.hpd th,
.hpd button {
    font-family: var(--sans) !important;
}

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

.hpd h1,
.hpd h2,
.hpd p {
    margin: 0;
}

.hpd a {
    text-decoration: none;
}

.hpd-container {
    max-width: calc(1160px + 48px);
    margin: 0 auto;
    padding: 0 24px;
}

.hpd-ico {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.hpd-eyebrow {
    display: inline-block;
    margin-bottom: 10px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--blue);
}

.hpd-eyebrow--gold {
    color: var(--gold-1);
}

.hpd-h2 {
    margin-bottom: 22px !important;
    font-size: 28px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--navy);
}

/* ---------- Buttons ---------- */
.hpd-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 24px;
    border: 1.5px solid transparent;
    border-radius: 999px;
    font-size: 15.5px;
    font-weight: 600;
    line-height: 1.2;
    transition: transform .2s, background .2s;
}

.hpd-btn:hover {
    transform: translateY(-1px);
}

.hpd-btn .hpd-ico {
    width: 18px;
    height: 18px;
}

.hpd-btn--block {
    display: flex;
    width: 100%;
    margin-bottom: 10px;
}

.hpd-btn--gold,
.hpd-btn--gold:hover {
    color: var(--navy);
}

.hpd-btn--gold {
    background: linear-gradient(180deg, var(--gold-1), var(--gold-2));
    box-shadow: 0 10px 24px rgba(214, 173, 90, .32);
}

.hpd-btn--ghost,
.hpd-btn--ghost:hover {
    color: #fff;
}

.hpd-btn--ghost {
    border-color: rgba(255, 255, 255, .65);
}

.hpd-btn--ghost:hover {
    background: rgba(255, 255, 255, .1);
}

.hpd-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 15.5px;
    font-weight: 600;
    color: var(--blue);
    white-space: nowrap;
}

.hpd-link:hover {
    color: var(--blue-hover);
}

.hpd-link .hpd-ico {
    width: 18px;
    height: 18px;
}

/* ---------- Hero ---------- */
.hpd-hero {
    position: relative;
    overflow: hidden;
    padding: 48px 0 110px;
    background:
        radial-gradient(circle at 85% 20%, rgba(22, 96, 224, .5), transparent 45%),
        linear-gradient(135deg, var(--navy-dark), var(--navy));
    color: #fff;
}

.hpd-hero__tri {
    position: absolute;
    left: -60px;
    bottom: -80px;
    width: 320px;
    height: 288px;
    background: rgba(255, 255, 255, .04);
    clip-path: polygon(50% 0, 100% 100%, 0 100%);
}

.hpd-hero__grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    gap: 56px;
    align-items: center;
}

.hpd-crumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 26px;
    font-size: 14px;
    color: rgba(212, 221, 238, .75);
}

.hpd-crumbs a {
    color: rgba(212, 221, 238, .9);
}

.hpd-crumbs a:hover {
    color: #fff;
}

.hpd-crumbs .sep {
    opacity: .5;
}

.hpd-crumbs .current {
    color: #fff;
    font-weight: 500;
}

.hpd .hpd-hero__title {
    font-size: 46px;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: 0;
    text-transform: none;
    color: #fff;
}

.hpd-hero__lead {
    margin-top: 16px !important;
    font-size: 17px;
    line-height: 1.7;
    color: #d4ddee;
}

.hpd-hero__specs {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 26px 0 0;
    padding: 0;
    list-style: none;
}

.hpd-hero__specs li {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 12px 18px;
    background: rgba(255, 255, 255, .07);
    border: 1px solid rgba(255, 255, 255, .14);
    border-radius: 14px;
}

.hpd-hero__specs span {
    font-size: 13px;
    color: rgba(212, 221, 238, .8);
}

.hpd-hero__specs b {
    font-size: 17px;
    font-weight: 700;
    color: #fff;
}

.hpd-hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 30px;
}

/* gallery */
.hpd-gallery {
    padding: 14px;
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .14);
    border-radius: 24px;
}

.hpd-gallery__main {
    overflow: hidden;
    aspect-ratio: 1 / 1;
    background: #fff;
    border-radius: 16px;
}

.hpd-gallery__main img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hpd-gallery__thumbs {
    display: flex;
    gap: 10px;
    margin-top: 12px;
}

.hpd .hpd-gallery__thumb {
    width: 72px;
    height: 72px;
    min-height: 0;
    margin: 0;
    padding: 0;
    overflow: hidden;
    background: #fff;
    border: 2px solid transparent;
    border-radius: 12px;
    cursor: pointer;
    opacity: .7;
    transition: opacity .2s, border-color .2s;
}

.hpd .hpd-gallery__thumb:hover,
.hpd .hpd-gallery__thumb.is-active {
    opacity: 1;
    border-color: var(--gold-1);
}

.hpd-gallery__thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ---------- Thông số (đè lên mép dưới hero) ---------- */
.hpd-specs-wrap {
    position: relative;
    z-index: 2;
    margin-top: -64px;
}

.hpd-specs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0;
    margin: 0;
    padding: 0;
    list-style: none;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 20px;
    box-shadow: 0 18px 40px rgba(10, 42, 102, .1);
}

.hpd-specs li {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin: 0;
    padding: 22px 20px;
    border-right: 1px solid var(--line);
}

.hpd-specs li:last-child {
    border-right: 0;
}

.hpd-specs__ico {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    margin-bottom: 10px;
    border-radius: 12px;
    background: var(--tint);
    color: var(--blue);
}

.hpd-specs__lbl {
    font-size: 13.5px;
    color: var(--muted);
}

.hpd-specs b {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.35;
    color: var(--navy);
}

/* ---------- Nội dung ---------- */
.hpd-section {
    padding: 64px 0 84px;
}

.hpd-section--white {
    padding: 80px 0;
    background: #fff;
    border-top: 1px solid var(--line);
}

.hpd-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 40px;
    align-items: start;
}

.hpd-main {
    display: flex;
    flex-direction: column;
    gap: 24px;
    min-width: 0;
}

.hpd-block {
    padding: 34px 38px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 20px;
}

/* tính năng: danh sách có dấu check */
.hpd-features ul {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hpd-features li {
    position: relative;
    margin: 0;
    padding: 16px 18px 16px 54px;
    font-size: 15.5px;
    line-height: 1.65;
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: 14px;
}

.hpd-features li::before {
    content: "";
    position: absolute;
    left: 16px;
    top: 16px;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 14px no-repeat;
}

/* nội dung bài */
.hpd-content {
    font-size: 16.5px;
}

.hpd-content p {
    margin: 0 0 14px;
}

.hpd-content h2,
.hpd-content h3,
.hpd-content h4 {
    margin: 28px 0 12px;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.4;
    color: var(--navy);
}

.hpd-content ul,
.hpd-content ol {
    margin: 0 0 16px;
    padding-left: 22px;
}

.hpd-content img {
    max-width: 100%;
    height: auto;
    border-radius: 14px;
}

.hpd-content table {
    width: 100%;
    margin-bottom: 18px;
    border-collapse: collapse;
    font-size: 15px;
}

.hpd-content th,
.hpd-content td {
    padding: 10px 14px;
    border: 1px solid var(--line);
}

.hpd-content strong {
    color: var(--navy);
}

/* FAQ (accordion của Flatsome) */
.hpd-faq .accordion {
    display: grid;
    gap: 12px;
}

.hpd-faq .accordion-item {
    overflow: hidden;
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: 14px;
}

.hpd-faq .accordion-title {
    position: relative;
    display: block;
    padding: 16px 52px 16px 20px;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.5;
    color: var(--navy);
    border: 0;
}

.hpd-faq .accordion-title.active {
    color: var(--blue);
    background: #fff;
}

.hpd-faq .accordion-title .toggle {
    position: absolute;
    left: auto;
    right: 14px;
    top: 50%;
    width: 28px;
    height: 28px;
    margin-top: -14px;
    border-radius: 50%;
    background: #fff;
    color: var(--blue);
    opacity: 1;
}

.hpd-faq .accordion-inner {
    padding: 0 20px 18px;
    background: #fff;
    font-size: 15.5px;
}

.hpd-faq .accordion-inner ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.hpd-faq .accordion-inner li,
.hpd-faq .accordion-inner p {
    margin: 0;
}

/* ---------- Cột phải ---------- */
.hpd-side {
    position: sticky;
    top: 94px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.admin-bar .hpd-side {
    top: 126px;
}

.hpd-card {
    padding: 26px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 20px;
}

.hpd-card--cta {
    border: 0;
    background:
        radial-gradient(circle at 100% 0, rgba(22, 96, 224, .5), transparent 55%),
        linear-gradient(150deg, var(--navy-dark), var(--navy));
}

.hpd-card__title {
    margin-bottom: 10px !important;
    font-size: 19px;
    font-weight: 700;
    line-height: 1.35;
    color: #fff;
}

.hpd-card__title--dark {
    margin-bottom: 16px !important;
    color: var(--navy);
}

.hpd-card--cta p {
    margin-bottom: 20px !important;
    font-size: 15px;
    line-height: 1.65;
    color: #d4ddee;
}

.hpd-price {
    display: flex;
    flex-direction: column;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, .15);
}

.hpd-price span {
    font-size: 13.5px;
    color: #d4ddee;
}

.hpd-price b {
    font-size: 26px;
    font-weight: 700;
    color: var(--gold-1);
}

.hpd-zalo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 6px;
    font-size: 14.5px;
    font-weight: 500;
    color: #d4ddee;
}

.hpd-zalo:hover {
    color: #fff;
}

.hpd-zalo .hpd-ico {
    width: 17px;
    height: 17px;
}

.hpd-steps {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hpd-steps li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    font-size: 15px;
    line-height: 1.5;
    color: var(--text);
}

.hpd-steps li > span {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    font-size: 14px;
    font-weight: 700;
    color: var(--navy);
    background: linear-gradient(180deg, var(--gold-1), var(--gold-2));
    border-radius: 50%;
}

/* ---------- Sản phẩm khác ---------- */
.hpd-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 30px;
}

.hpd-head .hpd-h2 {
    margin-bottom: 0 !important;
}

.hpd-related {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.hpd-rcard {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: 16px;
    transition: border-color .2s, box-shadow .2s;
}

.hpd-rcard:hover {
    border-color: var(--blue);
    box-shadow: 0 16px 34px rgba(10, 79, 193, .1);
}

.hpd-rcard__img {
    display: block;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: var(--tint);
}

.hpd-rcard__img img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s;
}

.hpd-rcard:hover .hpd-rcard__img img {
    transform: scale(1.05);
}

.hpd-rcard__title {
    padding: 16px 18px 4px;
    font-size: 16.5px;
    font-weight: 700;
    line-height: 1.4;
    color: var(--navy);
}

.hpd-rcard__more {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0 18px 18px;
    font-size: 14px;
    font-weight: 600;
    color: var(--blue);
}

.hpd-rcard__more .hpd-ico {
    width: 16px;
    height: 16px;
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
    .hpd-hero__grid,
    .hpd-layout {
        grid-template-columns: 1fr;
    }

    .hpd-gallery {
        max-width: 560px;
    }

    .hpd-side {
        position: static;
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .hpd-related {
        grid-template-columns: repeat(2, 1fr);
    }

    .hpd-specs li:nth-child(n) {
        border-bottom: 1px solid var(--line);
    }
}

@media (max-width: 640px) {
    .hpd-container {
        padding: 0 16px;
    }

    .hpd-hero {
        padding: 32px 0 90px;
    }

    .hpd .hpd-hero__title {
        font-size: 32px;
    }

    .hpd-hero__lead {
        font-size: 15.5px;
    }

    .hpd-hero__actions .hpd-btn {
        width: 100%;
    }

    .hpd-specs {
        grid-template-columns: 1fr 1fr;
    }

    .hpd-specs li {
        padding: 16px 14px;
    }

    .hpd-specs li:nth-child(even) {
        border-right: 0;
    }

    .hpd-section {
        padding: 40px 0 56px;
    }

    .hpd-block {
        padding: 24px 18px;
    }

    .hpd-h2 {
        font-size: 23px;
    }

    .hpd-side,
    .hpd-related {
        grid-template-columns: 1fr;
    }

    .hpd-related {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .hpd-rcard__title {
        padding: 12px 12px 2px;
        font-size: 15px;
    }

    .hpd-rcard__more {
        padding: 0 12px 14px;
        font-size: 13px;
    }

    .hpd-head {
        flex-direction: column;
        align-items: flex-start;
    }
}
