/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --primary: #1a3a5c;
    --primary-light: #2a5a8c;
    --accent: #c8a96e;
    --text: #333;
    --text-light: #666;
    --text-en: #888;
    --bg: #fff;
    --bg-gray: #f3f5f7;
    --border: #e8e8e8;
    --max-width: 1200px;
}

html { font-size: 16px; scroll-behavior: smooth; }

body {
    font-family: "Noto Sans SC", "Inter", -apple-system, "Segoe UI", sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.7;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 2rem;
}

a { color: inherit; text-decoration: none; }

img { max-width: 100%; height: auto; display: block; }

/* === Header === */
.header {
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo img { height: 48px; width: auto; }

.logo-text { display: flex; flex-direction: column; }
.logo-cn { font-size: 1.4rem; font-weight: 700; color: var(--primary); letter-spacing: 0.05em; }
.logo-en { font-size: 0.75rem; color: var(--text-light); font-weight: 400; letter-spacing: 0.02em; }

.nav { display: flex; gap: 2rem; }

.nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
    transition: border-color 0.2s;
}

.nav-link:hover, .nav-link.active { border-bottom-color: var(--primary); }

.nav-cn { font-size: 0.95rem; font-weight: 500; color: var(--text); }
.nav-en { font-size: 0.7rem; color: var(--text-en); font-weight: 300; }

/* === Intro (Homepage) === */
.intro {
    padding: 3rem 0 4rem;
    background: var(--bg);
}

.intro-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.intro-slogan {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: 0.1em;
    margin-bottom: 2rem;
    line-height: 1.4;
}

.intro-text .text-cn {
    font-size: 0.92rem;
    line-height: 2;
    color: var(--text);
    margin-bottom: 1.5rem;
    text-align: justify;
}

.intro-text .text-en {
    font-size: 0.82rem;
    line-height: 1.8;
    color: var(--text-en);
    text-align: justify;
    font-family: "Inter", sans-serif;
    max-width: 120%;
}

.intro-image {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 1rem;
}

.intro-image img {
    max-height: 350px;
    width: auto;
    object-fit: contain;
}

/* === Sections === */
.section { padding: 4rem 0; }

.highlights { background: var(--bg-gray); }

.section-title {
    text-align: center;
    margin-bottom: 3rem;
}

.title-cn {
    display: block;
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: 0.1em;
}

.title-en {
    display: block;
    font-size: 0.8rem;
    color: var(--text-en);
    font-weight: 300;
    margin-top: 0.3rem;
    letter-spacing: 0.15em;
    font-family: "Inter", sans-serif;
}

/* === Highlights === */
.highlights-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.highlight-card {
    text-align: center;
    padding: 2.5rem 1.5rem;
    border: 1px solid var(--border);
    border-radius: 4px;
    background: var(--bg);
    transition: box-shadow 0.2s;
}

.highlight-card:hover { box-shadow: 0 4px 20px rgba(0,0,0,0.06); }

.highlight-icon { width: 56px; height: 56px; margin: 0 auto 1.2rem; }
.highlight-title { font-size: 1.1rem; font-weight: 600; color: var(--primary); margin-bottom: 0.2rem; }
.highlight-title-en { font-size: 0.75rem; color: var(--text-en); margin-bottom: 1rem; font-family: "Inter", sans-serif; }
.highlight-desc { font-size: 0.88rem; color: var(--text-light); line-height: 1.7; }
.highlight-desc-en { font-size: 0.78rem; color: var(--text-en); line-height: 1.6; margin-top: 0.5rem; font-family: "Inter", sans-serif; }

/* === Page Header (product list) === */
.page-header {
    background: var(--primary);
    padding: 3rem 0;
    text-align: center;
    color: #fff;
}

.page-title .title-cn { color: #fff; font-size: 1.8rem; }
.page-title .title-en { color: rgba(255,255,255,0.6); }

/* === Detail Breadcrumb === */
.detail-breadcrumb {
    background: var(--bg);
    padding: 1rem 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.85rem;
    color: var(--text-light);
}

.detail-breadcrumb a {
    color: var(--primary);
}

.detail-breadcrumb a:hover {
    text-decoration: underline;
}

/* === Product Detail (single-column, matches old site) === */
.product-detail {
    padding: 2rem 0 3rem;
}

.detail-cn-section,
.detail-en-section {
    margin-bottom: 2.5rem;
}

.detail-sub-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.3rem;
}

.detail-model {
    font-size: 0.9rem;
    color: var(--text-en);
    font-family: "Inter", sans-serif;
    margin-bottom: 1.5rem;
}

.detail-block {
    margin-bottom: 2rem;
}

.detail-block h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.8rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid var(--border);
}

/* Intro layout: text left, image right */
.detail-intro-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.detail-intro-text {
    font-size: 0.9rem;
    line-height: 1.9;
}

.detail-intro-image {
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.detail-intro-image img {
    max-height: 350px;
    width: auto;
    object-fit: contain;
    border: 1px solid var(--border);
    border-radius: 4px;
}

/* English section */
.detail-en-section {
    border-top: 1px solid var(--border);
    padding-top: 2rem;
}

.detail-en-section .detail-sub-name {
    font-family: "Inter", sans-serif;
}

.detail-en-section p.text-en {
    font-size: 0.88rem;
    line-height: 1.8;
    color: var(--text);
}

.specs-list-en {
    list-style: none;
    padding: 0;
}

.specs-list-en li {
    font-size: 0.88rem;
    line-height: 1.8;
    color: var(--text);
    font-family: "Inter", sans-serif;
    padding: 0.2rem 0;
}

.specs-list-en li::before {
    content: "·";
    margin-right: 0.5rem;
    color: var(--primary);
    font-weight: 700;
}

/* Specs table (Chinese section) */
.specs-table { width: 100%; border-collapse: collapse; }
.specs-table td { padding: 0.6rem 1rem; font-size: 0.88rem; border-bottom: 1px solid #f0f0f0; }
.spec-key { color: var(--text-light); width: 30%; background: var(--bg-gray); font-weight: 500; }
.spec-val { color: var(--text); }

/* === Product List === */
.product-category-section { margin-bottom: 3rem; }

.category-heading {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary);
    padding-bottom: 0.8rem;
    border-bottom: 2px solid var(--primary);
    margin-bottom: 1.5rem;
}

.category-heading-en {
    font-size: 0.8rem;
    font-weight: 300;
    color: var(--text-en);
    margin-left: 0.8rem;
    font-family: "Inter", sans-serif;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
}

.product-card {
    border: 1px solid var(--border);
    border-radius: 4px;
    overflow: hidden;
    transition: box-shadow 0.2s;
    display: block;
}

.product-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.08); }

.product-image-wrap {
    aspect-ratio: 4/3;
    overflow: hidden;
    background: var(--bg-gray);
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image-wrap img { width: 100%; height: 100%; object-fit: cover; }

.product-no-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-en);
    font-size: 1.2rem;
    background: var(--bg-gray);
}

.product-no-image.large { min-height: 300px; font-size: 1.5rem; }

.product-info { padding: 1rem; }
.product-name { font-size: 0.92rem; font-weight: 500; color: var(--text); }
.product-name-en { font-size: 0.75rem; color: var(--text-en); margin-top: 0.2rem; font-family: "Inter", sans-serif; }

/* === References === */
.detail-references {
    font-size: 0.88rem;
    line-height: 1.9;
    color: var(--text);
}

.detail-references.text-en {
    font-family: "Inter", sans-serif;
}

/* === Contact === */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 3rem;
}

.contact-card {
    padding: 2rem;
    border: 1px solid var(--border);
    border-radius: 4px;
    text-align: center;
}

.contact-card h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 1rem;
}

.contact-card p { font-size: 0.9rem; color: var(--text-light); line-height: 1.6; }

.contact-sub-company {
    text-align: center;
    padding: 2rem;
    border-top: 1px solid var(--border);
}

.contact-sub-company h2 { font-size: 1.1rem; color: var(--primary); margin-bottom: 0.3rem; }

/* === Common === */
.text-en { color: var(--text-en); font-family: "Inter", sans-serif; }

/* === Footer === */
.footer {
    background: var(--bg-gray);
    border-top: 1px solid var(--border);
    padding: 1.5rem 0;
    text-align: center;
    font-size: 0.82rem;
    color: var(--text-light);
}

/* === Mobile Nav Toggle === */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}
.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--primary);
    transition: 0.2s;
}

/* === Responsive === */
@media (max-width: 768px) {
    .header .container { height: 60px; }
    .logo-cn { font-size: 1.1rem; }
    .logo-en { font-size: 0.65rem; }

    .nav-toggle { display: flex; }

    .nav {
        display: none;
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: var(--bg);
        flex-direction: column;
        gap: 0;
        border-bottom: 1px solid var(--border);
        box-shadow: 0 4px 12px rgba(0,0,0,0.08);
        z-index: 99;
    }
    .nav.open { display: flex; }
    .nav-link {
        padding: 0.8rem 2rem;
        border-bottom: 1px solid var(--border);
        flex-direction: row;
        gap: 0.5rem;
    }
    .nav-cn { font-size: 0.9rem; }

    .intro-layout { grid-template-columns: 1fr; }
    .intro-slogan { font-size: 1.4rem; }
    .intro-image { order: -1; }
    .intro-text .text-en { max-width: 100%; }

    .highlights-grid { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; }
    .detail-intro-layout { grid-template-columns: 1fr; }
    .product-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
    .product-grid { grid-template-columns: 1fr; }
}
