
/* 顶部导航栏 */
header.navbar {
	padding: 10px 10px;     /* ↑ 上下都有 10px */
    display: flex;
    justify-content: space-between;
    align-items: center;    /* 垂直居中：关键 */
    background-color: var(--base-color);
    color: #fff;
    position: sticky;
    top: 0;
    z-index: 1000;
    height: var(--header-height);
}

/* Logo + 网站名称 */
.header-left {
    display: flex;
    align-items: center;
}
.header-left img {
    height: 60px;
    margin-right: 15px;
}
.header-left span {
    font-size: var(--font-h2);
    font-weight: 700;
}

/* 汉堡按钮（动画） */
.menu-button {
    position: fixed;      /* 固定在页面右上角 */
    top: 8px;            /* 离页面顶部 8px */
    right: 10px;          /* 离页面右边 10px */
    width: 30px;
    height: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 3000;        /* 高于 header 和 menu-content */
}

.menu-button span {
    width: 30px;
    height: 4px;
    background: #fff;
    margin: 3px 0;          /* 增加间距，避免挤压 */
    border-radius: 3px;
    transition: 0.35s;
}

.menu-button.active span {
    width: 30px;
    height: 4px;
    margin: 1.5px 0;
}
.menu-button.active span:nth-child(1),
.menu-button.active span:nth-child(3) {
    background-color: white;   /* X 颜色变黑, 由于topbar的颜色，不用变黑了 */
    transform: rotate(45deg); /* 第1条上旋 / 第3条下旋 */
}
/* 汉堡按钮切换为 X 状态 */
.menu-button.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.menu-button.active span:nth-child(2) {
    opacity: 0;
}

.menu-button.active span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

/* 动画过渡 */
.menu-button span {
    transition: 0.35s;
}

.menu-topbar {
	height: var(--header-height);
	background-color:var(--base-color);
}

.menu-user-avatar {
    width: 45px;
    height: 45px;
    flex: 0 0 38px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background-color: #D34947;
    color: #fff;
    font-size: 16px;
    font-weight: 600;
}

.menu-login {
    margin-top: auto;
    color: #5BA3D0 !important;
}

/* 抽屉菜单 - 半屏，简洁 */
.menu-content {
    position: fixed;
    top: 0;                 /* 顶部贴住 */
    right: -80%;
    width: 80%;
    height: 100%;          /* 100% 全屏高度 */
    background-color: #fff;
    color: #333;
    box-shadow: -8px 0 20px rgba(0,0,0,0.2);
    border-top-left-radius: 0;     /* 顶部不要圆角了，因为与header贴齐 */
    border-bottom-left-radius: 12px;
    transition: right 0.35s ease;
    z-index: 2500;
    display: flex;
    flex-direction: column;
    padding-top: 0;         /* 不需要空白 */
}
.menu-inner {
    flex: 1;                 /* 占用关闭按钮下面的全部空间 */
    display: flex;
    flex-direction: column;
    overflow-y: auto;        /* 内容很多的话可以滚动 */
}
.menu-inner a {
    text-decoration: none;
    color: #000;
    font-size: var(--navi-menu-font); /* 菜单字体加大 */
    padding: 15px 15px;
    border-bottom: 1px solid #ddd;
    transition: background 0.3s;
}
.menu-inner a:hover {
    background-color: #f0f0f0;
}

/* 关闭按钮 */
.menu-close {
    height: 100px;      /* 和 header 相同高度 */
    min-height: 100px;

    width: 100%;        /* 占满顶部一整行 */
    display: flex;
    justify-content: center;
    align-items: center;

    cursor: pointer;
    z-index: 1201;
    position: relative;
    
}


/* 幻灯片容器 */
#mySlider {
    width: 100%;
    max-width: 100%;
    height: var(--slider-height);  /* 使用CSS变量控制高度 */

    position: relative;
    overflow: hidden;

    /* 固定背景 */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

/* 轨道 */
.slider-track {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.45s ease;
    background: transparent;
}

/* 图片：在背景范围内最大化显示且保持比例 */
.slider-track img {
    width: 100%;
    height: 100%;
    max-width: 100vw;  /* 最大宽度不超过视口宽度 */
    max-height: 100%;
    object-fit: cover;    /* 改为cover以填充容器，保持比例 */
    flex-shrink: 0;
    display: block;
}

/* 左右按钮（现代毛玻璃风） */
.slider-prev,
.slider-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 999; /* ← 提高层级，避免被 track 影响 */
    box-shadow: 0 4px 14px rgba(0,0,0,0.25);
    transition: background 0.25s, transform 0.2s;
}

/* 左右位置固定 */
.slider-prev {
    left: 20px;   /* ← 固定在左边 */
}
.slider-next {
    right: 20px;  /* ← 固定在右边 */
}

/* hover 更明显 */
.slider-prev:hover,
.slider-next:hover {
    background-color: rgba(255, 255, 255, 0.9);
    transform: translateY(-50%) scale(1.08);
}

/* 箭头更大、更明显 */
.slider-prev svg,
.slider-next svg {
    width: 40px;
    height: 40px;
    fill: #333;
    stroke: #333;
    stroke-width: 1.2px;
}



/* 圆点指示器 */
.slider-dots {
    position: absolute;
    bottom: 15px;
    width: 100%;
    text-align: center;
}

.slider-dots .dot {
    display: inline-block;
    width: 12px;
    height: 12px;
    margin: 0 6px;
    background-color: rgba(255,255,255,0.7);
    border-radius: 50%;
    cursor: pointer;
}

.slider-dots .dot.active {
    background-color: #5BA3D0;
}


/* 页面模块 */
section {
    width: 100%;
    margin: 0;
    padding: 0;
}


/* ========== 产品详情页面样式 ========== */


/* 产品主标题 */
.product-main-title {
    font-size: 1.8em;
    font-weight: bold;
    color: #333;
    margin: 1.5rem 0 1rem 0;
    padding-bottom: 0.5rem;
}

/* 产品详情小节标题样式 */
.product-section-title {
    font-size: 1.3em;
    font-weight: bold;
    color: #5BA3D0;
    margin: 1.5rem 0 1rem 0;
    padding-left: 12px;
    border-left: 4px solid #5BA3D0;
    background-color: #f5f9fc;
    padding: 10px 15px;
    border-radius: 4px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .product-main-title {
        font-size: 1.5em;
        margin: 1rem 0 0.8rem 0;
        padding: 0.8rem 0;
    }

    .product-section-title {
        font-size: 1.1em;
        margin: 1.2rem 0 0.8rem 0;
        padding: 8px 12px;
        padding-left: 12px;
    }

    .product-section-content {
        margin: 0.8rem 0 1.2rem 0;
        font-size: 0.95em;
    }

    .product-section-list {
        padding-left: 1.5rem;
    }

    .product-section-list li {
        margin: 0.6rem 0;
        font-size: 0.95em;
    }
}

@media (max-width: 480px) {
    .product-main-title {
        font-size: 1.3em;
        margin: 0.8rem 0 0.6rem 0;
        border-bottom-width: 2px;
    }

    .product-section-title {
        font-size: 1em;
        margin: 1rem 0 0.6rem 0;
        padding: 6px 10px;
        padding-left: 10px;
        border-left-width: 3px;
    }

    .product-section-content {
        margin: 0.6rem 0 1rem 0;
        font-size: 0.9em;
    }

    .product-section-list {
        padding-left: 1.2rem;
    }

    .product-section-list li {
        margin: 0.5rem 0;
        font-size: 0.9em;
    }
}
