/* ══════════════════════════════════════════════════════════════
   Magazine Style — Shared Styles for 智钺动力
   E-Ink × Editorial aesthetic with warm paper tones
   ══════════════════════════════════════════════════════════════ */

:root {
    --ink: #1c1917;
    --paper: #faf8f4;
    --cream: #f5f0e8;
    --gold: #9b7a3a;
    --gold-light: #c4a24e;
    --burgundy: #7b3f3f;
    --warm-gray: #78716c;
    --border: #e0d8cc;
    --border-light: #ede6d9;
    --white: #ffffff;
}

/* ── Base ── */
body {
    font-family: "Microsoft YaHei", "微软雅黑", -apple-system, "PingFang SC", sans-serif;
    background: var(--paper);
    color: var(--ink);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ── Typography ── */
.hero-title {
    font-family: "SimSun", "宋体", "Songti SC", serif;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.section-heading {
    font-family: "SimSun", "宋体", "Songti SC", serif;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: 0.03em;
}

.section-subheading {
    font-family: "SimSun", "宋体", "Songti SC", serif;
    color: var(--warm-gray);
    line-height: 1.8;
}

.magazine-title {
    font-family: "SimSun", "宋体", "Songti SC", serif;
    color: var(--ink);
}

.magazine-subtitle {
    color: var(--warm-gray);
}

.magazine-accent {
    color: var(--gold);
}

.gradient-text {
    background: linear-gradient(135deg, var(--gold), var(--gold-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Decorative divider ── */
.ornament-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin: 0 auto 24px;
}
.ornament-divider::before,
.ornament-divider::after {
    content: '';
    width: 40px;
    height: 1px;
    background: var(--gold);
    opacity: 0.5;
}
.ornament-divider span {
    color: var(--gold);
    font-size: 8px;
    letter-spacing: 6px;
}

/* ── Carousel ── */
.slide {
    transition: opacity 1s ease-in-out;
    will-change: opacity, transform;
    pointer-events: none;
}
.slide.opacity-100 {
    pointer-events: auto;
}

.hero-section {
    position: relative;
    height: 68vh;
    min-height: 420px;
    overflow: hidden;
}

/* Carousel slide image — 居中，object-contain，上下布局 */
.slide-image {
    object-fit: contain;
    max-width: 80%;
    max-height: 56%;
    margin: 0 auto;
    display: block;
}
.slide-image.object-contain {
    object-fit: contain;
}

/* 文字区域：图片下方居中 */
.slide-caption {
    text-align: center;
    margin-top: 16px;
}

/* 轮播遮罩：左浅右深，左侧图片清晰、右侧文字可读 */
.slide-overlay {
    background: linear-gradient(to right, rgba(28,25,23,0.10) 0%, rgba(28,25,23,0.15) 50%, rgba(28,25,23,0.78) 100%);
}

.hero-section::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(28,25,23,0.25), rgba(155,122,58,0.12)), url("../images/可用背景图/未标题-2.webp");
    background-size: cover;
    background-position: center;
    pointer-events: none;
    z-index: 0;
}

/* ── Navigation ── */
.nav-link.active {
    color: var(--gold-light);
}

.mobile-nav-link.active {
    color: var(--gold);
    background-color: #faf5eb;
}

.nav-dropdown {
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px) scale(0.98);
    transition: opacity 0.15s ease-out, transform 0.15s ease-out;
}

.nav-dropdown-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

/* ── Scroll reveal ── */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ── Magazine card ── */
.magazine-card {
    background: var(--white);
    border: 1px solid var(--border-light);
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.magazine-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
    border-color: var(--border);
}

/* ── Product card ── */
.product-card-img {
    max-width: 100%;
    height: auto;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.magazine-card:hover .product-card-img {
    transform: scale(1.04);
}

.product-img-area {
    background: var(--cream);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* ── Magazine button ── */
.magazine-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    border: 1px solid var(--ink);
    color: var(--ink);
    background: transparent;
    border-radius: 4px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.03em;
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
}
.magazine-btn:hover {
    background: var(--ink);
    color: var(--white);
}

/* ── Backgrounds ── */
.bg-paper { background: var(--paper); }
.bg-cream { background: var(--cream); }

/* ── Form elements ── */
.magazine-input {
    width: 100%;
    padding: 12px 16px;
    border: none;
    border-bottom: 1px solid var(--border);
    border-radius: 0;
    background: transparent;
    font-size: 15px;
    color: var(--ink);
    transition: border-color 0.3s ease;
    outline: none;
    font-family: "Microsoft YaHei", "微软雅黑", -apple-system, "PingFang SC", sans-serif;
}
.magazine-input:focus {
    border-bottom-color: var(--ink);
}
.magazine-input::placeholder {
    color: #c4bdb0;
}

.magazine-select {
    width: 100%;
    padding: 12px 16px;
    border: none;
    border-bottom: 1px solid var(--border);
    border-radius: 0;
    background: transparent;
    font-size: 15px;
    color: var(--ink);
    outline: none;
    font-family: "Microsoft YaHei", "微软雅黑", -apple-system, "PingFang SC", sans-serif;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2378716c' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    cursor: pointer;
}
.magazine-select:focus {
    border-bottom-color: var(--ink);
}

.magazine-label {
    font-size: 12px;
    font-weight: 500;
    color: var(--warm-gray);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 4px;
    display: block;
}

.magazine-submit {
    width: 100%;
    background: var(--ink);
    color: var(--white);
    font-family: "SimSun", "宋体", "Songti SC", serif;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 0.06em;
    padding: 14px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}
.magazine-submit:hover {
    background: var(--gold);
}
.magazine-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ── SMS button ── */
.sms-btn {
    padding: 10px 16px;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--warm-gray);
    border-radius: 4px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    letter-spacing: 0.03em;
}
.sms-btn:hover:not(:disabled) {
    border-color: var(--ink);
    color: var(--ink);
}
.sms-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ── Icon circles ── */
.icon-circle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 22px;
    border: 1px solid var(--border);
    background: var(--white);
    color: var(--gold);
}

/* ── Solution check icons ── */
.solution-check {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border: 1px solid var(--gold);
    color: var(--gold);
    font-size: 12px;
    background: transparent;
}

/* ── Footer ── */
.site-footer {
    background: var(--ink);
    color: #a89f91;
}
.site-footer .footer-title {
    color: var(--white);
    font-family: "SimSun", "宋体", "Songti SC", serif;
}
.site-footer .footer-divider {
    border-color: rgba(255,255,255,0.1);
}

/* ── Product sub-page header ── */
.product-header {
    background: rgba(28,25,23,0.95);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* ── Product tag chips ── */
.tag-chip {
    display: inline-flex;
    align-items: center;
    padding: 8px 18px;
    border-radius: 9999px;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.02em;
    transition: all 0.25s ease;
    text-decoration: none;
}
.tag-chip.active {
    background: var(--ink);
    color: var(--white);
}
.tag-chip:not(.active) {
    background: var(--white);
    color: var(--warm-gray);
    border: 1px solid var(--border);
}
.tag-chip:not(.active):hover {
    border-color: var(--ink);
    color: var(--ink);
}

/* ── Tab buttons (unified with tag-chip style) ── */
.tab-nav { display:flex; flex-wrap:wrap; gap:8px; margin-bottom:24px; }
.tab-btn {
    display: inline-flex; align-items: center;
    padding: 8px 18px; border: 1px solid var(--border); border-radius: 9999px;
    font-size: 13px; font-weight: 500; letter-spacing: 0.02em;
    cursor: pointer; transition: all 0.25s ease;
    background: var(--white); color: var(--warm-gray);
    font-family: "Microsoft YaHei", "微软雅黑", -apple-system, "PingFang SC", sans-serif;
}
.tab-btn:hover { border-color: var(--ink); color: var(--ink); }
.tab-btn.active { background: var(--ink); color: var(--white); border-color: var(--ink); }

/* ── Product detail card (sub-pages) ── */
.product-detail-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}
.product-detail-card .spec-section {
    margin-bottom: 16px;
}
.product-detail-card .spec-section h3 {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 6px;
    letter-spacing: 0.04em;
}
.product-detail-card .spec-section ul {
    font-size: 13px;
    color: var(--warm-gray);
    line-height: 1.8;
    list-style: none;
    padding: 0;
}
.product-detail-card .spec-section ul li::before {
    content: '— ';
    color: var(--border);
}
.product-detail-card .spec-section p {
    font-size: 13px;
    color: var(--warm-gray);
    line-height: 1.8;
}

/* ══════════════════════════════════════════════════════════════
   Responsive Breakpoints
   ══════════════════════════════════════════════════════════════ */

/* Mobile: < 640px */
@media (max-width: 639px) {
    .hero-section {
        height: 50vh;
        min-height: 320px;
    }

    .hero-title {
        font-size: 1.75rem !important;
    }

    .slide-subtitle {
        font-size: 1rem !important;
    }

    .slide-description {
        font-size: 0.8125rem !important;
    }

    .section-heading {
        font-size: 1.75rem !important;
    }

    .section-subheading {
        font-size: 0.9375rem !important;
    }

    .magazine-label {
        font-size: 11px;
    }

    .magazine-card {
        border-radius: 6px;
    }

    .site-footer .flex-wrap {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    /* Product image area — smaller on mobile */
    .product-img-area {
        min-height: 10rem;
    }

    .product-card-img {
        max-height: 10rem;
    }

    /* Product sub-page mobile */
    .product-header .header-inner {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }

    .tag-chips-wrap {
        justify-content: center;
    }

    .tag-chip {
        padding: 6px 14px;
        font-size: 12px;
    }

    .product-detail-card .spec-section ul {
        font-size: 12px;
    }

    /* Form mobile */
    #contact-form .flex.space-x-3 {
        flex-direction: column;
        gap: 8px;
    }

    #captcha-canvas {
        width: 100%;
        height: 48px;
    }
}

/* Tablet: 640px – 1023px */
@media (min-width: 640px) and (max-width: 1023px) {
    .hero-section {
        height: 60vh;
        min-height: 380px;
    }

    .hero-title {
        font-size: 2.25rem !important;
    }

    .section-heading {
        font-size: 2.25rem !important;
    }
}

/* Desktop: ≥ 1024px */
@media (min-width: 1024px) {
    .hero-section {
        height: 68vh;
        min-height: 480px;
    }

    .product-img-area {
        min-height: 14rem;
    }
}
