/* ============================================================
   小迈佳科技企业官网 - 自定义样式
   配合 TailwindCSS 使用，补充动画 / 细节样式
   ============================================================ */

html { scroll-behavior: smooth; }

/* ---------- 图片淡入动画 ---------- */
.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .8s ease, transform .8s ease;
}
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- 卡片悬浮上浮阴影 ---------- */
.card-hover {
    transition: transform .35s ease, box-shadow .35s ease;
}
.card-hover:hover {
    transform: translateY(-6px);
    box-shadow: 0 14px 40px rgba(7,32,49,0.16);
}

/* ---------- 核心实力卡片（背景图 + 悬停切换 + 高级样式） ---------- */
.strength-card {
    min-height: 250px;
    border: 1px solid rgba(255,255,255,.10);
    box-shadow: 0 10px 30px rgba(7,32,49,.12);
}
.strength-card::after {
    content: '';
    position: absolute; inset: 0; z-index: 1;
    border-radius: inherit;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.06);
    pointer-events: none;
}
.strength-bg {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    transition: opacity .7s ease, transform .9s ease;
}
.strength-bg-base  { opacity: 1; }
.strength-bg-hover { opacity: 0; transform: scale(1.06); }
.strength-card:hover .strength-bg-base  { opacity: 0; transform: scale(1.06); }
.strength-card:hover .strength-bg-hover { opacity: 1; transform: scale(1); }
.strength-overlay {
    position: absolute; inset: 0; z-index: 1;
    background: linear-gradient(180deg, rgba(8,24,42,.30) 0%, rgba(8,24,42,.15) 40%, rgba(8,24,42,.82) 100%);
    transition: background .5s ease;
}
.strength-card:hover .strength-overlay {
    background: linear-gradient(180deg, rgba(7,32,58,.18) 0%, rgba(7,32,58,.08) 35%, rgba(7,32,58,.88) 100%);
}
.strength-card:hover {
    box-shadow: 0 22px 50px rgba(7,32,49,.28);
    border-color: rgba(59,130,246,.45);
}
.strength-card .rich-arrow {
    opacity: 0; transform: translateX(-8px);
    transition: opacity .45s ease, transform .45s ease;
}
.strength-card:hover .rich-arrow { opacity: 1; transform: translateX(0); }

/* ---------- 按钮 hover 变色（Tailwind 已内置，这里补充平滑） ---------- */
.btn-anim {
    transition: all .3s ease;
}

/* ---------- 首页 Banner 大字视差 ---------- */
.hero-slide { opacity: 0; transition: opacity 1s ease; visibility: hidden; }
.hero-slide.active { opacity: 1; visibility: visible; }
.hero-kb { animation: kenburns 18s ease-in-out infinite alternate; }
@keyframes kenburns {
    0%   { transform: scale(1) translate(0,0); }
    100% { transform: scale(1.08) translate(-10px,-6px); }
}

/* ---------- 滚动条 ---------- */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #b5c6d6; border-radius: 4px; }
::-webkit-scrollbar-track { background: #f1f5f9; }

/* ---------- 参数表格样式 ---------- */
.param-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}
.param-table th,
.param-table td {
    border: 1px solid #e5e7eb;
    padding: 10px 14px;
    text-align: left;
}
.param-table th {
    background: #f0f6fb;
    color: #0E3A5D;
    font-weight: 600;
    width: 34%;
}
.param-table tr:nth-child(even) td { background: #fafbfc; }

/* ---------- 富文本正文内容样式（新闻/方案详情） ---------- */
.rich-content {
    line-height: 1.9;
    color: #374151;
    font-size: 0.98rem;
}
.rich-content h1, .rich-content h2, .rich-content h3 {
    color: #111827;
    font-weight: 700;
    margin: 1.4em 0 .6em;
}
.rich-content h1 { font-size: 1.5rem; }
.rich-content h2 { font-size: 1.3rem; }
.rich-content h3 { font-size: 1.1rem; }
.rich-content p { margin: .8em 0; }
.rich-content ul, .rich-content ol { padding-left: 1.4em; margin: .8em 0; }
.rich-content ul { list-style: disc; }
.rich-content ol { list-style: decimal; }
.rich-content img { max-width: 100%; border-radius: 10px; margin: 1em 0; }
.rich-content table { max-width: 100%; overflow-x: auto; }
.rich-content a { color: #155A96; text-decoration: underline; }

/* ---------- 分页 ---------- */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    margin: 36px 0 8px;
}
.pagination .page-info {
    font-size: 0.85rem;
    color: #6b7280;
    margin-right: 8px;
}
.pagination .page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 12px;
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    font-size: 0.875rem;
    color: #374151;
    background: #fff;
    transition: all .2s;
}
.pagination .page-link:hover { border-color: #155A96; color: #155A96; }
.pagination .page-link.current { background: #0E3A5D; border-color: #0E3A5D; color: #fff; }
.pagination .page-link.disabled { color: #c4cbd4; pointer-events: none; background: #f9fafb; }

/* ---------- 面包屑 ---------- */
.breadcrumb { font-size: 0.875rem; color: #6b7280; }
.breadcrumb a { color: #155A96; }
.breadcrumb a:hover { text-decoration: underline; }

/* ---------- 产品卡片图片占位淡入 ---------- */
.prod-img { transition: transform .5s ease; }
.prod-card:hover .prod-img { transform: scale(1.06); }

/* ============================================================
   分享 / 转发组件样式（微信/微博/QQ空间/QQ/复制链接/X/LinkedIn）
   ============================================================ */

/* ---------- 内联分享条 ---------- */
.share-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 26px;
    padding-top: 20px;
    border-top: 1px solid #f1f5f9;
}
.share-row-label { font-size: 14px; color: #6b7280; font-weight: 500; margin-right: 2px; }
.share-btn {
    min-width: 36px; height: 36px; padding: 0 10px;
    display: inline-flex; align-items: center; justify-content: center;
    border: none; border-radius: 999px;
    font-size: 13px; font-weight: 600; color: #fff;
    cursor: pointer; transition: transform .2s ease, box-shadow .2s ease, opacity .2s ease;
    box-shadow: 0 2px 8px rgba(7,32,49,.10);
}
.share-btn .share-svg { width: 18px; height: 18px; display: block; }
.share-btn .share-btn-text { margin-left: 6px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.share-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(7,32,49,.18); opacity: .95; }

/* 各平台品牌色 */
.share-wx   { background: #07C160; }
.share-wb   { background: #E6162D; }
.share-qz   { background: #FDC400; color: #7a4f01; }
.share-qq   { background: #12B7F5; }
.share-copy { background: #6b7280; }
.share-tw   { background: #111827; }
.share-in   { background: #0A66C2; }

/* ---------- 浮动分享按钮 ---------- */
.share-float { position: fixed; right: 18px; bottom: 18px; z-index: 90; }
.share-float-btn {
    width: 54px; height: 54px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #155A96, #0E3A5D); color: #fff;
    border: none; cursor: pointer;
    box-shadow: 0 8px 24px rgba(7,32,49,.30);
    transition: transform .25s ease, box-shadow .25s ease;
}
.share-float-btn:hover { transform: translateY(-3px) scale(1.04); box-shadow: 0 12px 30px rgba(7,32,49,.38); }

.share-panel {
    position: absolute; right: 0; bottom: 66px;
    width: 268px;
    background: #fff; border: 1px solid #eef2f6; border-radius: 18px;
    box-shadow: 0 18px 50px rgba(7,32,49,.22);
    padding: 18px;
    transition: opacity .18s ease, transform .18s ease;
}
.share-panel.share-hidden { opacity: 0; transform: translateY(10px) scale(.96); pointer-events: none; }
.share-panel.share-open   { opacity: 1; transform: translateY(0) scale(1); }
.share-panel-title { font-size: 14px; font-weight: 700; color: #111827; margin-bottom: 14px; }
.share-panel-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.share-item {
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    padding: 10px 4px; border: none; background: transparent; cursor: pointer;
    border-radius: 12px; transition: background .15s ease;
}
.share-item:hover { background: #f6f8fa; }
.share-item-icon {
    width: 42px; height: 42px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 12px; font-weight: 700;
    box-shadow: 0 2px 8px rgba(7,32,49,.14);
}
.share-item-icon .share-svg { width: 20px; height: 20px; }
.share-item-label { font-size: 11px; color: #6b7280; }
.share-panel-tip { margin-top: 14px; padding-top: 12px; border-top: 1px dashed #eef2f6; font-size: 11px; color: #9ca3af; text-align: center; }

/* 分享面板图标品牌色（按钮上同时带 share-item 与品牌类，图标用子元素独立着色） */
.share-panel .share-item.share-wx   .share-item-icon { background: #07C160; }
.share-panel .share-item.share-wb   .share-item-icon { background: #E6162D; }
.share-panel .share-item.share-qz   .share-item-icon { background: #FDC400; color: #7a4f01; }
.share-panel .share-item.share-qq   .share-item-icon { background: #12B7F5; }
.share-panel .share-item.share-copy .share-item-icon { background: #6b7280; }
.share-panel .share-item.share-tw   .share-item-icon { background: #111827; }
.share-panel .share-item.share-in   .share-item-icon { background: #0A66C2; }
/* ---------- 微信扫码弹窗 ---------- */
.share-overlay {
    position: fixed; inset: 0; z-index: 1000;
    background: rgba(7,32,49,.55);
    display: flex; align-items: center; justify-content: center;
    padding: 20px;
    opacity: 0; transition: opacity .25s ease;
}
.share-overlay.share-overlay-show { opacity: 1; }
.share-modal {
    position: relative;
    width: 100%; max-width: 360px;
    background: #fff; border-radius: 22px;
    padding: 28px 24px 24px; text-align: center;
    box-shadow: 0 24px 70px rgba(0,0,0,.35);
    transform: translateY(12px) scale(.97);
    transition: transform .25s ease;
}
.share-overlay-show .share-modal { transform: translateY(0) scale(1); }
.share-modal-close {
    position: absolute; top: 12px; right: 14px;
    width: 30px; height: 30px; border-radius: 50%;
    border: none; background: #f3f4f6; color: #6b7280;
    font-size: 18px; line-height: 1; cursor: pointer;
    transition: background .15s ease;
}
.share-modal-close:hover { background: #e5e7eb; }
.share-modal-title { font-size: 17px; font-weight: 700; color: #111827; }
.share-modal-sub { font-size: 12px; color: #6b7280; line-height: 1.7; margin: 8px 0 16px; }
.share-qr {
    width: 216px; height: 216px; margin: 0 auto;
    border: 1px solid #eef2f6; border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
    background: #fff; padding: 8px;
}
.share-qr img { width: 200px; height: 200px; display: block; }
.share-qr-fallback { font-size: 12px; color: #b91c1c; line-height: 1.6; padding: 8px; }
.share-modal-url {
    margin-top: 14px; font-size: 11px; color: #9ca3af;
    word-break: break-all; line-height: 1.6;
}

/* ---------- 微信咨询弹窗（展示后台上传的二维码图） ---------- */
.wxcontact-modal { max-width: 340px; }
.wxcontact-qr {
    width: 232px; height: 232px; margin: 0 auto;
    border: 1px solid #eef2f6; border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
    background: #fff; padding: 10px; overflow: hidden;
}
.wxcontact-qr img { width: 100%; height: 100%; object-fit: contain; display: block; }
.wxcontact-id {
    margin-top: 14px; font-size: 13px; color: #374151;
    display: flex; align-items: center; justify-content: center; gap: 6px;
}
.wxcontact-id span { font-weight: 700; color: #0E3A5D; word-break: break-all; }
.wxcontact-copy {
    padding: 2px 12px; border: 1px solid #155A96; border-radius: 999px;
    background: #EEF5FB; color: #155A96; font-size: 12px; cursor: pointer;
    transition: background .15s ease;
}
.wxcontact-copy:hover { background: #D9EAF7; }
.wxcontact-link {
    display: inline-block; margin-top: 14px;
    font-size: 13px; color: #155A96; text-decoration: underline;
}

/* ---------- 轻提示 ---------- */
.share-toast {
    position: fixed; left: 50%; bottom: 90px; z-index: 1001;
    transform: translateX(-50%) translateY(8px);
    max-width: 80%;
    background: rgba(17,24,39,.92); color: #fff;
    font-size: 13px; padding: 10px 18px; border-radius: 999px;
    opacity: 0; transition: opacity .25s ease, transform .25s ease;
    pointer-events: none;
}
.share-toast.share-toast-show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* 移动端浮动按钮略缩小，避免遮挡 */
@media (max-width: 640px) {
    .share-float-btn { width: 48px; height: 48px; }
    .share-panel { width: 250px; }
}

/* ---------- 在线客服悬浮（右下角：微信咨询 + 返回顶部，后台可开关） ---------- */
.kefu-float {
    position: fixed; right: 18px; bottom: 84px; z-index: 89;
    display: flex; flex-direction: column; gap: 10px;
}
.kefu-btn {
    width: 52px; height: 52px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 6px 18px rgba(14,58,93,.22);
    transition: transform .2s ease, box-shadow .2s ease;
    border: none; cursor: pointer; text-decoration: none;
}
.kefu-wx {
    background: linear-gradient(135deg, #16A34A, #15803D); color: #fff;
}
.kefu-wx:hover { transform: translateY(-3px); box-shadow: 0 10px 22px rgba(22,163,74,.35); }
.kefu-top {
    background: rgba(255,255,255,.96); color: #0E3A5D;
    border: 1px solid #eef2f6;
}
.kefu-top:hover { transform: translateY(-3px); background: #fff; }
@media (max-width: 640px) {
    .kefu-float { bottom: 80px; gap: 8px; }
    .kefu-btn { width: 46px; height: 46px; }
}
