/* =========================================================
   Service 页面公共样式
   说明：
   1. 本文件仅用于 Service 及其子页面
   2. 结构顺序：
      公共容器
      Banner
      顶部按钮导航
      通用图文模块
      Install 页面
      Shipping 页面
      After-sales 页面
      Downloads 页面
      响应式
   ========================================================= */


/* =========================================================
   一、公共容器
   ========================================================= */

/* Service 页面整体外层 */
.service-page-wrap {
    width: 100%;
    padding: 60px 0 80px;
    background: #fff;
}

/* 正文内容区域（默认比按钮区域更宽） */
.service-inner {
    width: min(1500px, calc(100% - 60px));
    margin: 0 auto;
}

/* 正文顶部间距 */
.service-section {
    padding-top: 50px;
}


/* =========================================================
   二、Banner 区域（支持图片 / 视频）
   ========================================================= */

/* Banner 主容器 */
.service-hero {
    position: relative;
    width: 100%;
    min-height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* 背景媒体层 */
.service-hero__media {
    position: absolute;
    inset: 0;
    z-index: 1;
}

/* Banner 图片 / 视频统一铺满 */
.service-hero__media img,
.service-hero__media video,
.service-hero__video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* 视频轻微放大，避免边缘露白 */
.service-hero__video {
    transform: scale(1.05);
}

/* 遮罩层，增强标题可读性 */
.service-hero__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 2;
}

/* 标题内容层 */
.service-hero__content {
    position: relative;
    z-index: 3;
    text-align: center;
    color: #fff;
    padding: 40px 20px;
}

/* Banner 标题 */
.service-hero__title {
    margin: 0;
    font-size: 44px;
    font-weight: 700;
    line-height: 1.2;
}

/* 子页面 Banner 更矮 */
.service-hero--small {
    min-height: 220px;
}

/* 子页面标题更小 */
.service-hero--small .service-hero__title {
    font-size: 36px;
}


/* =========================================================
   三、顶部按钮导航
   ========================================================= */

/* 按钮整体，向上叠加到 Banner 下缘 */
.service-nav {
    margin-top: -28px;
    position: relative;
    z-index: 5;
}

/* 按钮列表区域（比正文窄） */
.service-nav__list {
    width: min(1200px, calc(100% - 40px));
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    padding: 0;
    list-style: none;
}

/* 单个按钮容器 */
.service-nav__item {
    margin: 0;
}

/* 按钮样式 */
.service-nav__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 180px;
    padding: 14px 24px;
    border-radius: 999px;
    background: #ffffff;
    color: #0f4c97;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid #dbe4f0;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
    transition: all 0.25s ease;
}

/* 按钮 hover 和当前选中 */
.service-nav__link:hover,
.service-nav__link.is-active {
    background: #0f4c97;
    color: #fff;
    border-color: #0f4c97;
}


/* =========================================================
   四、通用图文模块（适用于一般 Service 子页）
   ========================================================= */

/* 通用左右图文结构 */
.service-grid {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 26px;
    align-items: start;
}

/* 文字区域 */
.service-text {
    max-width: 680px;
}

/* 标题 */
.service-text h2 {
    margin: 0 0 16px;
    font-size: 34px;
    line-height: 1.2;
    color: #0f4c97;
}

/* 标题下引导语 */
.service-intro {
    margin: 0 0 20px;
    font-size: 16px;
    line-height: 1.8;
    color: #6b7280;
}

/* 通用列表 */
.service-list {
    margin: 0;
    padding-left: 0;
}

/* 通用列表项 */
.service-list li {
    position: relative;
    padding-left: 18px;
    margin-bottom: 10px;
    font-size: 18px;
    line-height: 1.8;
    color: #4b5563;
    list-style: none;
}

/* 蓝色圆点 */
.service-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 10px;
    width: 6px;
    height: 6px;
    background: #0f4c97;
    border-radius: 50%;
}

/* 图片容器 */
.service-image {
    display: flex;
    justify-content: flex-start;
}

/* 通用图片 */
.service-image img {
    width: 100%;
    max-width: 720px;
    border-radius: 22px;
    display: block;
    object-fit: cover;
}

/* 底部说明块 */
.service-note {
    margin-top: 36px;
    padding: 30px;
    background: #f6f8fb;
    border-radius: 18px;
}

.service-note p:last-child {
    margin-bottom: 0;
}


/* =========================================================
   五、Install Service 页面
   说明：图文各占一半，中间留白更大
   ========================================================= */

/* Install 页面正文宽度 */
.install-page-wrap .service-inner {
    width: min(1440px, calc(100% - 60px));
}

/* Install 页面图文布局 */
.install-page-wrap .service-grid {
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
}

/* Install 图片区域 */
.install-page-wrap .service-image {
    justify-content: flex-start;
}

/* Install 图片 */
.install-page-wrap .service-image img {
    width: 100%;
    max-width: none;
    border-radius: 22px;
    display: block;
    object-fit: cover;
}

/* Install 文字区域 */
.install-page-wrap .service-text {
    max-width: none;
}

/* Install 标题 */
.install-page-wrap .service-text h2 {
    margin: 0 0 20px;
    font-size: 34px;
    line-height: 1.2;
    color: #0f4c97;
}

/* Install 列表项 */
.install-page-wrap .service-list li {
    margin-bottom: 12px;
    font-size: 18px;
    line-height: 1.8;
    color: #4b5563;
}

/* Install 列表圆点微调 */
.install-page-wrap .service-list li::before {
    top: 10px;
}


/* =========================================================
   六、Shipping Service 页面
   ========================================================= */

/* Shipping 页面正文宽度 */
.shipping-page-wrap .service-inner {
    width: min(1280px, calc(100% - 60px));
}

/* 蓝色主标题 */
.shipping-main-title {
    margin: 0 0 18px;
    font-size: 34px;
    line-height: 1.2;
    font-weight: 700;
    color: #0f4c97;
}

/* 顶部图文区域：左右 50/50 */
.shipping-top {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: start;
    margin-bottom: 56px;
}

/* 左侧文字 */
.shipping-top__text {
    max-width: 620px;
}

/* 黑色说明标题 */
.shipping-title {
    margin: 0 0 24px;
    font-size: 28px;
    line-height: 1.25;
    font-weight: 700;
    color: #111827;
}

/* 顶部段落 */
.shipping-top__text p {
    margin: 0 0 10px;
    font-size: 16px;
    line-height: 1.8;
    color: #111827;
}

/* 海运列表 */
.shipping-sea-list {
    margin: 0;
    padding-left: 0;
    list-style: none;
}

.shipping-sea-list li {
    margin-bottom: 6px;
    font-size: 16px;
    line-height: 1.8;
    color: #111827;
}

/* 图片 */
.shipping-top__image img {
    width: 100%;
    max-width: none;
    display: block;
    object-fit: cover;
}

/* 下方正文区 */
.shipping-content {
    margin-top: 8px;
}

/* 正文段落 */
.shipping-content p {
    margin: 0 0 26px;
    font-size: 16px;
    line-height: 1.85;
    color: #111827;
}

/* 加粗小标题 */
.shipping-content strong,
.shipping-top__text strong {
    font-weight: 700;
    color: #111827;
}


/* =========================================================
   七、After-sales Service 页面
   ========================================================= */

/* 页面正文宽度 */
.aftersales-page-wrap .service-inner {
    width: min(1280px, calc(100% - 60px));
    margin: 0 auto;
}

/* 页面顶部内容区微调 */
.aftersales-page-wrap .service-section {
    padding-top: 48px;
}

/* 左右两栏布局 */
.aftersales-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 56px;
    align-items: start;
}

/* 左侧图片容器 */
.aftersales-image {
    width: 100%;
}

/* 图片 */
.aftersales-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    border-radius: 0;
}

/* 右侧内容容器 */
.aftersales-content {
    width: 100%;
}

/* 蓝色主标题 */
.aftersales-main-title {
    margin: 0 0 22px;
    font-size: 34px;
    line-height: 1.2;
    font-weight: 700;
    color: #0f4c97;
}

/* 列表整体 */
.aftersales-list {
    margin: 0;
    padding-left: 22px;
}

/* 列表项 */
.aftersales-list li {
    margin-bottom: 16px;
    font-size: 16px;
    line-height: 1.8;
    color: #111827;
}

/* 列表中的加粗标题 */
.aftersales-list strong {
    font-weight: 700;
    color: #111827;
}


/* =========================================================
   八、Downloads 页面
   说明：
   1. 数据来源于 cable 文章类型
   2. 文件字段来自 ACF：header_cta_datasheet
   3. 页面包含：标题 + 简介 + 表格 + 分页
   ========================================================= */

/* 页面内容宽度 */
.downloads-page-wrap .service-inner {
    width: min(1280px, calc(100% - 60px));
    margin: 0 auto;
}

/* 页面头部 */
.downloads-header {
    margin-bottom: 28px;
}

/* 蓝色主标题 */
.downloads-main-title {
    margin: 0 0 14px;
    font-size: 34px;
    line-height: 1.2;
    font-weight: 700;
    color: #0f4c97;
}

/* 标题下说明 */
.downloads-intro {
    margin: 0;
    font-size: 16px;
    line-height: 1.8;
    color: #4b5563;
}

/* 表格外层 */
.downloads-table-wrap {
    width: 100%;
    overflow-x: auto;
    background: #fff;
    border-radius: 16px;
    border: 1px solid #e5e7eb;
}

/* 表格主体 */
.downloads-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

/* 三列宽度 */
.downloads-table th:nth-child(1),
.downloads-table td:nth-child(1) {
    width: 45%;
}

.downloads-table th:nth-child(2),
.downloads-table td:nth-child(2) {
    width: 25%;
}

.downloads-table th:nth-child(3),
.downloads-table td:nth-child(3) {
    width: 30%;
}

/* 表头 */
.downloads-table thead th {
    padding: 18px 22px;
    background: #f7f9fc;
    font-size: 15px;
    font-weight: 700;
    color: #123b73;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
    vertical-align: middle;
}

/* 表格内容 */
.downloads-table tbody td {
    padding: 18px 22px;
    font-size: 15px;
    line-height: 1.7;
    color: #374151;
    text-align: left;
    border-bottom: 1px solid #eef2f7;
    vertical-align: middle;
    word-break: break-word;
}

/* 最后一行去掉底边 */
.downloads-table tbody tr:last-child td {
    border-bottom: none;
}

/* 文件名列 */
.downloads-file-name {
    font-weight: 600;
    color: #111827;
}

/* 日期列 */
.downloads-date {
    color: #6b7280;
    white-space: nowrap;
}

/* 按钮列 */
.downloads-action {
    white-space: nowrap;
}

/* 下载按钮默认状态 */
.downloads-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 110px;
    padding: 10px 18px;
    border-radius: 999px;
    background: #0f4c97;
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
}

/* 已访问状态（防止点击后文字颜色被浏览器改掉） */
.downloads-btn:visited {
    color: #fff !important;
    background: #0f4c97;
}

/* 鼠标悬停 */
.downloads-btn:hover {
    background: #0b3b76;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

/* 鼠标点击 */
.downloads-btn:active {
    color: #fff;
    transform: translateY(0);
    box-shadow: none;
}

/* 聚焦状态 */
.downloads-btn:focus {
    color: #fff;
    outline: none;
}

/* 禁用状态 */
.downloads-btn.is-disabled {
    background: #cbd5e1;
    color: #fff;
    cursor: default;
}

/* 空内容提示 */
.downloads-empty {
    text-align: center;
    color: #6b7280;
    padding: 28px 22px;
}

/* 分页区域 */
.downloads-pagination {
    margin-top: 28px;
}

/* WordPress 分页列表 */
.downloads-pagination ul {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 0;
    margin: 0;
    list-style: none;
}

/* 分页按钮 */
.downloads-pagination a,
.downloads-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid #dbe4f0;
    background: #fff;
    color: #0f4c97;
    text-decoration: none;
    font-weight: 600;
}

/* 当前页 */
.downloads-pagination .current {
    background: #0f4c97;
    color: #fff;
    border-color: #0f4c97;
}


/* =========================================================
   九、平板端适配（≤ 991px）
   ========================================================= */

@media (max-width: 991px) {

    /* Banner 高度缩小 */
    .service-hero {
        min-height: 220px;
    }

    .service-hero__title {
        font-size: 34px;
    }

    .service-hero--small {
        min-height: 180px;
    }

    .service-hero--small .service-hero__title {
        font-size: 28px;
    }

    /* 顶部按钮缩小 */
    .service-nav__link {
        min-width: 150px;
        padding: 12px 18px;
    }

    /* 通用图文改为上下结构 */
    .service-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .service-image {
        justify-content: center;
    }

    .service-image img {
        max-width: 100%;
    }

    .service-list li {
        font-size: 16px;
    }

    /* Install 页面 */
    .install-page-wrap .service-inner {
        width: min(100%, calc(100% - 40px));
    }

    .install-page-wrap .service-grid {
        grid-template-columns: 1fr;
        gap: 24px;
        align-items: start;
    }

    .install-page-wrap .service-image {
        justify-content: center;
    }

    .install-page-wrap .service-image img {
        max-width: 100%;
    }

    .install-page-wrap .service-text {
        max-width: 100%;
    }

    /* Shipping 页面 */
    .shipping-page-wrap .service-inner {
        width: min(100%, calc(100% - 40px));
    }

    .shipping-top {
        grid-template-columns: 1fr;
        gap: 28px;
        margin-bottom: 40px;
    }

    .shipping-top__image {
        order: -1;
    }

    .shipping-main-title {
        font-size: 28px;
    }

    .shipping-title {
        font-size: 24px;
    }

    .shipping-top__text,
    .shipping-top__image {
        max-width: 100%;
    }

    .shipping-top__text p,
    .shipping-sea-list li,
    .shipping-content p {
        font-size: 15px;
    }

    /* After-sales 页面 */
    .aftersales-page-wrap .service-inner {
        width: min(100%, calc(100% - 40px));
    }

    .aftersales-layout {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .aftersales-main-title {
        font-size: 28px;
        margin-bottom: 18px;
    }

    .aftersales-list {
        padding-left: 20px;
    }

    .aftersales-list li {
        font-size: 15px;
        line-height: 1.75;
        margin-bottom: 14px;
    }

    /* Downloads 页面 */
    .downloads-page-wrap .service-inner {
        width: min(100%, calc(100% - 40px));
    }

    .downloads-main-title {
        font-size: 28px;
    }

    .downloads-table thead th,
    .downloads-table tbody td {
        padding: 16px 16px;
        font-size: 14px;
    }
}


/* =========================================================
   十、手机端适配（≤ 575px）
   ========================================================= */

@media (max-width: 575px) {

    /* Banner 更矮 */
    .service-hero {
        min-height: 180px;
    }

    .service-hero__title {
        font-size: 28px;
    }

    /* 顶部按钮向上收一点 */
    .service-nav {
        margin-top: -18px;
    }

    /* 底部说明块 padding 缩小 */
    .service-note {
        padding: 20px;
    }

    /* Shipping 页面 */
    .shipping-main-title {
        font-size: 24px;
    }

    .shipping-title {
        font-size: 22px;
    }

    .shipping-top {
        gap: 20px;
        margin-bottom: 32px;
    }

    .shipping-content p {
        margin-bottom: 20px;
    }

    /* After-sales 页面 */
    .aftersales-page-wrap .service-inner {
        width: min(100%, calc(100% - 30px));
    }

    .aftersales-layout {
        gap: 20px;
    }

    .aftersales-main-title {
        font-size: 24px;
        margin-bottom: 16px;
    }

    .aftersales-list {
        padding-left: 18px;
    }

    .aftersales-list li {
        font-size: 14px;
        line-height: 1.7;
        margin-bottom: 12px;
    }

    /* Downloads 页面 */
    .downloads-page-wrap .service-inner {
        width: min(100%, calc(100% - 30px));
    }

    .downloads-main-title {
        font-size: 24px;
    }

    .downloads-intro {
        font-size: 15px;
    }

    .downloads-pagination a,
    .downloads-pagination span {
        min-width: 38px;
        height: 38px;
        padding: 0 12px;
        font-size: 14px;
    }
}