/*
 * CURADLE POLICY THEME NOTE
 * Màu nhấn chính thức của CURADLE: #2e3d98.
 * File được kế thừa layout policy đã ổn định từ Rcom; chỉ đổi namespace và màu thương hiệu,
 * không thay đổi cấu trúc responsive/layout của trang Chính sách.
 */
/* ================================================================
   TRANG HỖ TRỢ > CHÍNH SÁCH
   URL: /ho-tro/chinh-sach/
   ================================================================
   PHẠM VI FILE:
   - Chỉ style giao diện trang Chính sách; không chứa nội dung policy.
   - Nội dung text của 9 policy được PHP lấy từ curadle_policies.
   - Font đồng bộ theme: Inter. Không sử dụng ExtraBold/Black.
   - Weight dùng trong file này tối đa 700; tiêu đề policy cấp 1 dùng 600
     để tránh cảm giác quá đậm/quá lớn so với layout thực tế.

   CẤU TRÚC CSS:
   01. Font + nền trang
   02. Hero đầu trang
   03. Layout 2 cột
   04. Sidebar / tab policy
   05. Card Liên hệ hỗ trợ
   06. Panel nội dung policy
   07. Heading / paragraph / list / table
   08. Empty state
   09. Responsive tablet + mobile
   ================================================================ */
/* 01. FONT + NỀN TRANG ------------------------------------------------ */
.curadle-policy-page,
.curadle-policy-page * {
    font-family: "Inter", Arial, Helvetica, sans-serif;
}

.curadle-policy-page {
    background: #fff;
    color: #181818;
}

/* 02. HERO ĐẦU TRANG -------------------------------------------------
   ĐỒNG BỘ 100% VỚI HERO CHUNG CỦA FAQ / LIÊN HỆ
   ================================================================
   MỤC TIÊU:
   - Hero Chính sách không có chiều cao, padding hoặc background riêng.
   - Không vẽ thêm pseudo-element riêng vì `.hero-circuit` của theme
     đã chịu trách nhiệm toàn bộ nền/họa tiết.
   - Tiêu đề, underline và mô tả luôn nằm đúng giữa theo cả chiều ngang.
   - Các rule này chỉ xử lý alignment, không thay đổi component chung.

   LƯU Ý:
   - Không khai báo `height`, `min-height`, `padding`.
   - Không override cỡ chữ/độ đậm của `.heading-line`.
   - Không dùng `text-transform: uppercase`.
   ================================================================ */
.curadle-policy-hero {
    position: relative;
}

/*
 * Wrapper nội dung hero.
 * Flex-column giúp cả heading và paragraph cùng dùng một trục giữa,
 * tránh trường hợp paragraph kế thừa width/margin khiến bị lệch trái.
 */


/*
 * Tiêu đề:
 * - Giữ "Chính sách", không chuyển thành chữ hoa toàn bộ.
 * - margin-inline:auto đảm bảo heading/underline luôn nằm giữa.
 */


/*
 * Mô tả:
 * - width:100% để text-align:center áp dụng ổn định.
 * - max-width tương đương utility `max-w-2xl` của component chung.
 * - margin-inline:auto loại bỏ mọi lệch trái do CSS kế thừa.
 */



/* 02A. GIỚI THIỆU AUTOELEX VIỆT NAM -------------------------------
   VỊ TRÍ: NGAY SAU HERO, TRƯỚC LAYOUT CHÍNH SÁCH
   ================================================================
   - Full-width theo container chung của website.
   - Không nằm trong panel bên phải.
   - Không dùng card viền ngoài để giữ thiết kế thoáng như ảnh mẫu.
   - Nội dung text lấy động từ DB; CSS chỉ xử lý trình bày.
   ================================================================ */
.curadle-policy-intro-section {
    background: #fff;
    padding: 30px 0 24px;
}

.curadle-policy-intro-section .container-page {
    width: min(calc(100% - 36px), 1110px);
    margin: 0 auto;
}

.curadle-policy-intro-brand {
    margin: 0 0 16px;
    color: #2e3d98;
    font-family: "Inter", sans-serif;
    font-size: 20px;
    line-height: 1.4;
    font-weight: 600;
    text-transform: none;
}

.curadle-policy-intro-section p {
    margin: 0 0 12px;
    color: #57514d;
    font-family: "Inter", sans-serif;
    font-size: 14px;
    line-height: 1.8;
    font-weight: 400;
}

.curadle-policy-intro-section p:last-child {
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .curadle-policy-intro-section {
        padding: 24px 0 18px;
    }

    .curadle-policy-intro-brand {
        font-size: 18px;
    }
}

/* 03. LAYOUT 2 CỘT --------------------------------------------------- */
.curadle-policy-layout {
    width: min(calc(100% - 36px), 1110px);
    margin: 0 auto;
    padding: 28px 0 34px;
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 20px;
    align-items: start;
}

.curadle-policy-sidebar {
    min-width: 0;
}

/* 04. SIDEBAR / TAB POLICY ------------------------------------------ */
.curadle-policy-tabs {
    display: flex;
    flex-direction: column;
    gap: 0;
    border: 1px solid #e5e7ef;
    border-radius: 9px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 5px 18px rgba(30, 18, 10, .025);
}

.curadle-policy-tab {
    position: relative;
    min-height: 52px;
    padding: 0 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid #e8eaf2;
    color: #272421;
    background: #fff;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.35;
    transition: background .18s ease, color .18s ease;
}

.curadle-policy-tab:last-child {
    border-bottom: 0;
}

.curadle-policy-tab:hover {
    background: #f7f8ff;
    color: #2e3d98;
}

.curadle-policy-tab.is-active {
    color: #2e3d98;
    background: linear-gradient(90deg, #f5f6ff 0%, #eef0ff 100%);
    font-weight: 600;
}

.curadle-policy-tab.is-active::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: #2e3d98;
}

.curadle-policy-tab__icon {
    width: 21px;
    height: 21px;
    flex: 0 0 21px;
    color: #2e3d98;
}

.curadle-policy-tab__icon svg,
.curadle-policy-support-button svg {
    display: block;
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* 05. CARD LIÊN HỆ HỖ TRỢ ------------------------------------------- */
.curadle-policy-support-card {
    margin-top: 12px;
    min-height: 124px;
    display: grid;
    grid-template-columns: 105px minmax(0, 1fr);
    align-items: end;
    overflow: hidden;
    border: 1px solid #dfe3fb;
    border-radius: 9px;
    background: linear-gradient(135deg, #f5f6ff 0%, #eef0ff 100%);
}

.curadle-policy-support-card > img {
    width: 115px;
    height: 118px;
    align-self: end;
    object-fit: cover;
    object-position: 22% center;
}

.curadle-policy-support-card__content {
    padding: 14px 12px 12px 2px;
}

/*
 * FIX 2026-08-07 - KHÓA CỠ CHỮ RIÊNG CHO TIÊU ĐỀ CARD HỖ TRỢ.
 * ------------------------------------------------------------------
 * Theme Curadle có rule global `body main h2` đặt font-size:
 * `clamp(26px, 2.6vw, 38px) !important`, nên nếu rule riêng của card không
 * match đúng DOM thì tiêu đề “Cần hỗ trợ?” sẽ bị phóng rất lớn.
 *
 * Lỗi trước đó: selector viết `main .curadle-policy-page ...`, trong khi DOM
 * thực tế là `<main class="curadle-wp-main curadle-policy-page">`. Dấu cách
 * khiến CSS đi tìm `.curadle-policy-page` là PHẦN TỬ CON của `main`, nên rule
 * hoàn toàn không áp dụng.
 *
 * FIX: dùng `main.curadle-policy-page` để match đúng chính thẻ `<main>`.
 * Rule chỉ tác động tới h2 trong card hỗ trợ của trang Chính sách và dùng
 * `!important` để khóa cỡ chữ trước các rule heading global của theme.
 */
body:not(.wp-admin) main.curadle-policy-page .curadle-policy-support-card h2 {
    margin: 0 0 5px;
    font-size: 16px !important;
    line-height: 1.25 !important;
    font-weight: 700 !important;
}

.curadle-policy-support-card p {
    margin: 0;
    color: #625d59;
    font-size: 10.5px;
    line-height: 1.5;
    font-weight: 400;
}

.curadle-policy-support-button {
    min-height: 34px;
    margin-top: 10px;
    padding: 0 11px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border-radius: 6px;
    background: #2e3d98;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    box-shadow: 0 5px 12px rgba(46, 61, 152, .16);
}

.curadle-policy-support-button:hover {
    background: #25337f;
    color: #fff;
}

.curadle-policy-support-button svg {
    width: 15px;
    height: 15px;
}

/* 06. PANEL NỘI DUNG POLICY ----------------------------------------- */
.curadle-policy-content-panel {
    min-width: 0;
    padding: 20px 22px 17px;
    border: 1px solid #e4e6ef;
    border-radius: 9px;
    background: #fff;
    box-shadow: 0 5px 18px rgba(30, 18, 10, .025);
}



/* ---------------------------------------------------------
 * TIÊU ĐỀ CẤP 1 CỦA TỪNG CHÍNH SÁCH (1., 2., 3....)
 * Giảm cỡ chữ và độ đậm để cân đối với phần nội dung bên dưới.
 * Giữ Inter SemiBold, không dùng ExtraBold/Black.
 * --------------------------------------------------------- */
.curadle-policy-main-title {
    margin: 0 0 16px;
    color: #2e3d98;
    font-size: clamp(17px, 1.35vw, 20px);
    line-height: 1.4;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.curadle-policy-content-panel > p,
.curadle-policy-detail-card > p {
    margin: 0 0 10px;
    color: #46413e;
    font-size: 12px;
    line-height: 1.72;
    font-weight: 400;
}

.curadle-policy-content-panel > p {
    margin-bottom: 14px;
}

.curadle-policy-content-panel strong,
.curadle-policy-detail-card strong {
    font-weight: 700;
}

.curadle-policy-detail-card {
    position: relative;
    margin-top: 10px;
    padding: 15px 16px 13px;
    border: 1px solid #e4e6ef;
    border-radius: 8px;
    background: #fff;
}

.curadle-policy-detail-card h3 {
    margin: 0 0 10px;
    color: #2e3d98;
    font-size: 14px;
    line-height: 1.4;
    font-weight: 700;
}

.curadle-policy-content-panel ul,
.curadle-policy-detail-card ul {
    margin: 0 0 8px;
    padding: 0 0 0 19px;
}

.curadle-policy-content-panel li,
.curadle-policy-detail-card li {
    margin: 0 0 6px;
    color: #3f3b38;
    font-size: 11.5px;
    line-height: 1.62;
    font-weight: 400;
}

.curadle-policy-content-panel em,
.curadle-policy-detail-card em {
    color: #625c58;
}

.curadle-policy-table-wrap {
    width: 100%;
    margin: 10px 0 14px;
    overflow-x: auto;
    border: 1px solid #e4e7f1;
    border-radius: 7px;
}

.curadle-policy-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 460px;
    font-size: 11.5px;
}

.curadle-policy-table th,
.curadle-policy-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #e7e9f2;
    text-align: left;
    line-height: 1.45;
    font-weight: 400;
}

.curadle-policy-table th {
    background: #f2f4ff;
    color: #2e3d98;
    font-weight: 600;
}

.curadle-policy-table tr:last-child td {
    border-bottom: 0;
}

/* 08. EMPTY STATE ---------------------------------------------------- */
.curadle-policy-empty {
    padding: 30px 20px;
    text-align: center;
}

.curadle-policy-empty h2 {
    margin: 0 0 8px;
    font-size: 20px;
    font-weight: 700;
}

.curadle-policy-empty p {
    margin: 0;
    color: #77716c;
    font-size: 13px;
}

/* 09. RESPONSIVE TABLET / MOBILE ------------------------------------ */
@media (max-width: 900px) {
    .curadle-policy-layout {
        grid-template-columns: 230px minmax(0, 1fr);
        gap: 14px;
    }

    .curadle-policy-tab {
        padding-inline: 12px;
        font-size: 12px;
    }

    .curadle-policy-support-card {
        grid-template-columns: 86px minmax(0, 1fr);
    }

    .curadle-policy-support-card > img {
        width: 94px;
    }
}

@media (max-width: 720px) {
    .curadle-policy-hero {
        min-height: 146px;
    }

    .curadle-policy-layout {
        width: min(calc(100% - 24px), 1110px);
        grid-template-columns: 1fr;
        padding-top: 18px;
    }

    .curadle-policy-tabs {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        border-radius: 8px;
    }

    .curadle-policy-tab {
        border-right: 1px solid #e8eaf2;
    }

    .curadle-policy-support-card {
        display: none;
    }

    .curadle-policy-content-panel {
        padding: 17px 15px;
    }
}

@media (max-width: 460px) {
    .curadle-policy-tabs {
        grid-template-columns: 1fr;
    }

    .curadle-policy-tab {
        min-height: 48px;
        border-right: 0;
    }
}


/* ============================================================
 * TIÊU ĐỀ CẤP 1 CỦA TỪNG CHÍNH SÁCH
 * ------------------------------------------------------------
 * Ví dụ: "1. CHÍNH SÁCH GIAO HÀNG & VẬN CHUYỂN"
 *
 * Yêu cầu thiết kế:
 * - Giảm độ nặng để cân đối với nội dung.
 * - Font Inter theo theme.
 * - Không dùng ExtraBold/Black.
 * - Desktop tối đa 20px.
 * - Weight 600.
 * - Line-height thoáng hơn để tiêu đề dài không bị nặng.
 * ============================================================ */
.curadle-policy-content > h2,
.curadle-policy-article > h2,
.curadle-policy-body > h2,
.curadle-policy-main h2:first-child {
    font-family: "Inter", sans-serif;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.45;
}

/* Tablet/mobile: giảm thêm nhẹ để tránh xuống dòng nặng. */
@media (max-width: 768px) {
    .curadle-policy-content > h2,
    .curadle-policy-article > h2,
    .curadle-policy-body > h2,
    .curadle-policy-main h2:first-child {
        font-size: 18px;
    }
}


/* ================================================================
 * HERO CHÍNH SÁCH - CANH GIỮA TOÀN BỘ NỘI DUNG
 * ================================================================
 *
 * VẤN ĐỀ CŨ:
 * - Heading và underline đã ở giữa.
 * - Paragraph mô tả vẫn lệch trái vì còn chịu width/margin từ class
 *   hoặc CSS kế thừa của component chung.
 *
 * GIẢI PHÁP:
 * - Wrapper dùng flex-column + align-items:center.
 * - Tất cả child block dùng margin-inline:auto.
 * - Paragraph có width:100% + max-width và text-align:center.
 *
 * LƯU Ý:
 * - Không đặt height/min-height/padding riêng.
 * - Không làm thay đổi hero FAQ/Liên hệ.
 * - Chỉ scope trong `.curadle-policy-hero`.
 * ================================================================ */
.curadle-policy-hero .curadle-policy-hero__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.curadle-policy-hero .heading-line {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
    text-transform: none;
}

.curadle-policy-hero .curadle-policy-hero__inner > p {
    display: block;
    width: 100%;
    max-width: 42rem;
    margin-left: auto !important;
    margin-right: auto !important;
    text-align: center !important;
}


/* ================================================================
 * TYPOGRAPHY TRANG CHÍNH SÁCH - GIẢM ĐỘ NẶNG THEO THIẾT KẾ
 * ================================================================
 *
 * VẤN ĐỀ:
 * - "AUTOELEX VIỆT NAM" và tiêu đề policy đang quá to / quá đậm.
 * - Tổng thể bị nặng, không cân với sidebar và body text.
 *
 * ĐIỀU CHỈNH:
 * - Font vẫn là Inter.
 * - Weight chính giảm về 500 (Medium), tương đương khoảng 2/3 cảm giác
 *   nặng của mức 700 trước đây.
 * - Heading policy cấp 1 giảm còn 18px desktop.
 * - Heading con 3.x giảm còn 15px.
 * - Không dùng ExtraBold / Black.
 *
 * SCOPE:
 * - Chỉ áp dụng trong trang Chính sách.
 * - Không ảnh hưởng FAQ, Liên hệ, homepage hoặc các trang khác.
 * ================================================================ */

/* AUTOELEX VIỆT NAM - section giới thiệu ngay dưới hero */
.curadle-policy-intro-section .curadle-policy-intro-brand {
    font-family: "Inter", sans-serif;
    font-size: 18px !important;
    line-height: 1.45 !important;
    font-weight: 500 !important;
    letter-spacing: 0 !important;
}

/* Tiêu đề policy chính, ví dụ: "3. Chính sách bảo hành" */
.curadle-policy-main-title,
.curadle-policy-content > h2,
.curadle-policy-article > h2,
.curadle-policy-body > h2,
.curadle-policy-main h2:first-child {
    font-family: "Inter", sans-serif;
    font-size: 18px !important;
    line-height: 1.45 !important;
    font-weight: 500 !important;
    letter-spacing: 0 !important;
}

/* Heading con, ví dụ 3.1 / 3.2 / 3.3 */
.curadle-policy-detail-card > h3,
.curadle-policy-detail-card h3 {
    font-family: "Inter", sans-serif;
    font-size: 15px !important;
    line-height: 1.5 !important;
    font-weight: 500 !important;
}

/* Sidebar policy: giữ rõ nhưng không quá nặng */
.curadle-policy-nav a,
.curadle-policy-sidebar a {
    font-weight: 400 !important;
}

/* Active item sidebar: chỉ nhấn vừa phải */
.curadle-policy-nav a.is-active,
.curadle-policy-sidebar a.is-active,
.curadle-policy-nav .active > a,
.curadle-policy-sidebar .active > a {
    font-weight: 500 !important;
}

/* Mobile: giảm thêm để không bị nặng khi xuống dòng */
@media (max-width: 768px) {
    .curadle-policy-intro-section .curadle-policy-intro-brand {
        font-size: 17px !important;
    }

    .curadle-policy-main-title,
    .curadle-policy-content > h2,
    .curadle-policy-article > h2,
    .curadle-policy-body > h2,
    .curadle-policy-main h2:first-child {
        font-size: 17px !important;
    }

    .curadle-policy-detail-card > h3,
    .curadle-policy-detail-card h3 {
        font-size: 14px !important;
    }
}


/* ================================================================
 * NỘI DUNG POLICY - ĐỒNG BỘ CỠ CHỮ VỚI SECTION AUTOELEX VIỆT NAM
 * ================================================================
 *
 * YÊU CẦU THIẾT KẾ:
 * - Phần paragraph/list trong nội dung chính sách bên phải không được
 *   nhỏ hơn phần giới thiệu AUTOELEX VIỆT NAM.
 * - Dùng cùng cỡ chữ 14px trên desktop như section AUTOELEX.
 * - Giữ font Inter và weight 400 để không bị nặng.
 * - Heading vẫn giữ mức nhẹ đã chốt ở rule typography phía trên.
 *
 * SCOPE:
 * - Chỉ áp dụng phần content panel của trang Chính sách.
 * - Không ảnh hưởng sidebar, Hero, FAQ, Liên hệ hay trang chủ.
 * ================================================================ */
.curadle-policy-content-panel,
.curadle-policy-content,
.curadle-policy-article,
.curadle-policy-body,
.curadle-policy-main {
    font-family: "Inter", sans-serif;
}

.curadle-policy-content-panel p,
.curadle-policy-content-panel li,
.curadle-policy-content p,
.curadle-policy-content li,
.curadle-policy-article p,
.curadle-policy-article li,
.curadle-policy-body p,
.curadle-policy-body li,
.curadle-policy-main p,
.curadle-policy-main li {
    font-size: 14px !important;
    line-height: 1.8 !important;
    font-weight: 400 !important;
}

/* Danh sách giữ khoảng cách dễ đọc, không dồn chữ. */
.curadle-policy-content-panel li,
.curadle-policy-content li,
.curadle-policy-article li,
.curadle-policy-body li,
.curadle-policy-main li {
    margin-bottom: 6px;
}

/* Mobile giữ cùng tỷ lệ, không giảm nhỏ hơn section AUTOELEX. */
@media (max-width: 768px) {
    .curadle-policy-content-panel p,
    .curadle-policy-content-panel li,
    .curadle-policy-content p,
    .curadle-policy-content li,
    .curadle-policy-article p,
    .curadle-policy-article li,
    .curadle-policy-body p,
    .curadle-policy-body li,
    .curadle-policy-main p,
    .curadle-policy-main li {
        font-size: 14px !important;
        line-height: 1.75 !important;
    }
}


/* ================================================================
 * BẢNG TRONG NỘI DUNG CHÍNH SÁCH - ĐỒNG BỘ CỠ CHỮ
 * ================================================================
 *
 * Ví dụ: bảng "Khu vực / Thời gian dự kiến".
 *
 * YÊU CẦU THIẾT KẾ:
 * - Không để bảng nhỏ hơn paragraph policy.
 * - Header dùng 14px / 500 để đủ phân cấp nhưng không quá đậm.
 * - Cell dùng 14px / 400, bằng body text.
 * - Ghi chú italic dưới bảng cũng giữ 14px.
 *
 * SCOPE:
 * - Chỉ áp dụng bảng bên trong trang Chính sách.
 * - Không ảnh hưởng table ở sản phẩm, phụ kiện, FAQ hay admin.
 * ================================================================ */
.curadle-policy-page .curadle-policy-table,
.curadle-policy-page .curadle-policy-table th,
.curadle-policy-page .curadle-policy-table td {
    font-family: "Inter", sans-serif;
}

.curadle-policy-page .curadle-policy-table th {
    font-size: 14px !important;
    line-height: 1.6 !important;
    font-weight: 500 !important;
}

.curadle-policy-page .curadle-policy-table td {
    font-size: 14px !important;
    line-height: 1.65 !important;
    font-weight: 400 !important;
}

/*
 * Ghi chú ngay sau bảng, ví dụ:
 * "Thời gian giao hàng không bao gồm ngày nghỉ..."
 */
.curadle-policy-page .curadle-policy-table-wrap + p,
.curadle-policy-page .curadle-policy-table-wrap + p em,
.curadle-policy-page .curadle-policy-table-wrap + em {
    font-size: 14px !important;
    line-height: 1.7 !important;
    font-weight: 400 !important;
}

/* Mobile vẫn giữ 14px để không bị nhỏ lại. */
@media (max-width: 768px) {
    .curadle-policy-page .curadle-policy-table th,
    .curadle-policy-page .curadle-policy-table td,
    .curadle-policy-page .curadle-policy-table-wrap + p,
    .curadle-policy-page .curadle-policy-table-wrap + p em,
    .curadle-policy-page .curadle-policy-table-wrap + em {
        font-size: 14px !important;
    }
}

