/* Shared product navigation for 550W AI main pages. Served under /blog/. */
/* 所有产品页统一预留滚动条宽度，避免跨页导航因滚动条实现不同而左右跳动。 */
html {
    overflow-y: scroll;
    scrollbar-gutter: stable;
}

html::-webkit-scrollbar {
    width: 12px;
}

.ui-icon { --ui-icon-color:currentColor;display:inline-block;width:1em;height:1em;margin-right:.32em;vertical-align:-.12em;background-color:var(--ui-icon-color);-webkit-mask:var(--ui-icon-mask) center/contain no-repeat;mask:var(--ui-icon-mask) center/contain no-repeat; }
.ui-icon-topic { --ui-icon-color:#a5b4fc;--ui-icon-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3 4.5 7.2v9.6L12 21l7.5-4.2V7.2L12 3Z'/%3E%3Cpath d='m8.5 12 2.2 2.2 4.8-4.8'/%3E%3C/svg%3E"); }
.ui-icon-success { --ui-icon-color:#34d399;--ui-icon-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='m8 12 2.7 2.7L16.5 9'/%3E%3C/svg%3E"); }
.ui-icon-warning { --ui-icon-color:#fbbf24;--ui-icon-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10.3 4.2 2.8 18a2 2 0 0 0 1.8 3h14.8a2 2 0 0 0 1.8-3L13.7 4.2a2 2 0 0 0-3.4 0Z'/%3E%3Cpath d='M12 9v4M12 17h.01'/%3E%3C/svg%3E"); }
.site-header-bar {
    /* 与 qzm 品牌栏共用同一宽度基准，保证跨站跳转时左上角不位移。 */
    width: min(1392px, calc(100vw - 48px));
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: clamp(3.5rem, 7vw, 6rem);
}

.site-header-bar .logo {
    margin: 0;
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 0;
    border: 0;
    color: var(--text-primary);
    background: transparent;
    box-shadow: none;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.site-header-bar .logo:hover {
    background: transparent;
    opacity: 0.88;
}

.site-header-bar .logo::before { display: none !important; }

.site-header-bar .logo-icon {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    padding: 0;
    border: 0;
    border-radius: 10px;
    background: transparent;
    box-shadow: 0 5px 16px rgba(0, 0, 0, 0.24);
    object-fit: cover;
}

.site-header-bar .logo-text {
    display: inline-flex;
    align-items: baseline;
    gap: 5px;
    font-size: 18px;
    line-height: 1;
    color: #f4f4f5;
    font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    font-weight: 680;
    letter-spacing: -0.025em;
    font-kerning: normal;
    text-rendering: geometricPrecision;
}

.site-footer-brand-mark img {
    display: block;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    object-fit: cover;
}

.product-site-footer {
    margin-top: 3.75rem;
    padding: 2.75rem 0 1.4rem;
    border-top: 1px solid var(--border, rgba(255, 255, 255, .08));
    background: rgba(18, 18, 26, .96);
    color: var(--text-secondary, #a1a1aa);
    line-height: 1.5;
    text-align: left;
}

.product-footer-shell {
    width: min(1392px, calc(100vw - 48px));
    margin: 0 auto;
}

.product-footer-grid {
    display: grid;
    grid-template-columns: 1.45fr .78fr .82fr 1.05fr;
    gap: clamp(2rem, 4vw, 4rem);
    align-items: stretch;
}

.product-footer-title {
    display: flex;
    align-items: center;
    gap: .7rem;
    margin-bottom: .9rem;
    color: var(--text-primary, #f4f4f5);
    font-size: .94rem;
}

.product-footer-title img { width: 30px; height: 30px; border-radius: 9px; object-fit: cover; box-shadow: 0 8px 24px rgba(99,102,241,.2); }
.product-footer-brand, .product-footer-grid > section { display: flex; flex-direction: column; }
.product-footer-brand > p { margin: 0; color: var(--text-secondary, #a1a1aa); font-size: .82rem; line-height: 1.75; }
.product-site-footer h2 { margin: .35rem 0 .95rem; color: var(--text-primary, #f4f4f5); font-size: .88rem; line-height: 1.4; font-weight: 700; }
.product-site-footer nav, .product-footer-contacts { display: grid; gap: .58rem; }
.product-site-footer a { color: var(--text-secondary, #a1a1aa); font-size: .76rem; line-height: 1.45; text-decoration: none; }
.product-site-footer a:hover { color: var(--text-primary, #f4f4f5); text-decoration: none; }
.product-footer-tail { margin-top: auto !important; padding-top: .9rem; border-top: 1px solid var(--border, rgba(255,255,255,.08)); color: var(--text-muted, #71717a) !important; font-size: .75rem !important; line-height: 1.7 !important; }
.product-footer-contact { position: relative; display: grid; grid-template-columns: 68px minmax(0,1fr); align-items: center; gap: .45rem; min-height: 28px; color: var(--text-secondary, #a1a1aa); font-size: .8rem; cursor: default; }
.product-footer-contact strong { color: var(--text-primary, #f4f4f5); font-size: .78rem; font-weight: 600; white-space: nowrap; }
.product-footer-qr { position: absolute; z-index: 5; left: 0; bottom: calc(100% + 10px); display: none; width: 150px; padding: 10px; border: 1px solid var(--border, rgba(255,255,255,.08)); border-radius: 12px; background: #fff; color: #222; box-shadow: 0 16px 40px rgba(0,0,0,.4); text-align: center; }
.product-footer-qr img { display: block; width: 128px; height: 128px; margin: 0 auto 6px; object-fit: cover; }
.product-footer-qr small { font-size: .72rem; }
.product-footer-contact:hover .product-footer-qr, .product-footer-contact:focus-within .product-footer-qr { display: block; }
.product-footer-bottom { display: flex; justify-content: space-between; gap: 1rem; margin-top: 2rem; padding-top: 1.15rem; border-top: 1px solid var(--border, rgba(255, 255, 255, .08)); color: var(--text-muted, #71717a); font-size: .74rem; }
.product-footer-bottom a { color: inherit; font-size: inherit; }

.site-header-bar .logo-highlight {
    background: linear-gradient(125deg, #ddd6fe 0%, #a5b4fc 52%, #818cf8 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: #a5b4fc;
    font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    font-weight: 650;
    letter-spacing: -0.035em;
}

.tool-page-header {
    padding: 32px 0 3.5rem !important;
}

.tool-page-header .site-header-bar {
    margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

.tool-page-header .site-header-bar + h1 {
    max-width: 1080px;
    margin: 0 auto 1rem !important;
    font-size: clamp(2rem, 4.2vw, 3.25rem);
    line-height: 1.14;
    letter-spacing: -1.5px;
}

.tool-page-header .tagline {
    max-width: 720px;
    margin: 0 auto;
    font-size: clamp(0.95rem, 1.6vw, 1.1rem);
    line-height: 1.7;
}

.tool-page-header h1,
.tool-page-header .tagline {
    animation: none !important;
}

.site-nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    padding: 5px;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: rgba(26, 26, 36, 0.72);
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.site-nav a {
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 13px;
    border: 1px solid transparent;
    border-radius: 9px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    transition: var(--transition-fast);
}

.site-nav.site-nav a:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.055) !important;
    border-color: var(--border) !important;
    box-shadow: none !important;
}

.site-nav.site-nav a[aria-current="page"] {
    color: #fff;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary)) !important;
    border-color: rgba(129, 140, 248, 0.65) !important;
    box-shadow: 0 6px 16px rgba(79, 70, 229, 0.24) !important;
}

@media (max-width: 820px) {
    .site-header-bar {
        width: calc(100vw - 32px);
        align-items: flex-start;
        flex-direction: column;
        gap: 18px;
        margin-bottom: 3rem;
    }

    .site-nav {
        width: 100%;
        justify-content: flex-start;
        overflow-x: auto;
        overscroll-behavior-x: contain;
        scrollbar-width: none;
        -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 14px, #000 calc(100% - 14px), transparent 100%);
        mask-image: linear-gradient(90deg, transparent 0, #000 14px, #000 calc(100% - 14px), transparent 100%);
    }

    .site-nav a {
        min-height: 44px;
    }

    .site-nav::-webkit-scrollbar {
        display: none;
    }

    .tool-page-header {
        padding-top: 20px !important;
        padding-bottom: 2.75rem !important;
    }

    .tool-page-header .site-header-bar {
        margin-bottom: 2.5rem;
    }

    .product-footer-shell { width: calc(100vw - 32px); }
    .product-footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem; }
}

@media (max-width: 480px) {
    .tool-page-header .site-header-bar + h1 {
        font-size: clamp(1.8rem, 9vw, 2.35rem);
        letter-spacing: -1px;
    }

    .site-header-bar .logo {
        padding: 0;
    }

    .site-header-bar .logo-icon {
        width: 36px;
        height: 36px;
        flex-basis: 36px;
    }

    .site-header-bar .logo-text {
        font-size: 16px;
    }

    .site-nav a {
        min-height: 44px;
        padding: 0 11px;
        font-size: 13px;
    }

    .product-footer-grid { grid-template-columns: 1fr; gap: 1.75rem; }
    .product-footer-bottom { flex-direction: column; }
}
