/**
 * Mobile-only overrides (max-width: 991px / 640px)
 * Desktop styles untouched — all rules scoped inside media queries.
 */

@media (max-width: 991px) {
  /* ── 手机导航：深色磨砂玻璃（高不透明，blur 失效也有实底） ── */
  .tc-header,
  .tc-liquid-glass .tc-header,
  .tc-check-page .tc-header {
    background: rgba(15, 36, 30, 0.86);
    background: color-mix(in srgb, var(--bg-mid) 86%, rgba(255, 255, 255, 0.06));
    border-bottom: 0.5px solid rgba(255, 255, 255, 0.14);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.1),
      0 4px 24px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(20px) saturate(170%);
    -webkit-backdrop-filter: blur(20px) saturate(170%);
  }

  .tc-header.is-scrolled,
  .tc-liquid-glass .tc-header.is-scrolled,
  .tc-check-page .tc-header.is-scrolled {
    background: rgba(15, 36, 30, 0.92);
    background: color-mix(in srgb, var(--bg-mid) 92%, rgba(255, 255, 255, 0.04));
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.12),
      0 6px 28px rgba(0, 0, 0, 0.32);
  }

  .tc-liquid-glass .tc-header::after,
  .tc-check-page .tc-header::after {
    background: rgba(255, 255, 255, 0.12);
  }

  .tc-liquid-glass .tc-logo,
  .tc-logo {
    background: color-mix(in srgb, var(--bg-mid) 88%, rgba(255, 255, 255, 0.08));
    border-color: rgba(255, 255, 255, 0.16);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.14),
      0 4px 16px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
  }

  .tc-mobile-toggle {
    background: color-mix(in srgb, var(--bg-mid) 84%, rgba(255, 255, 255, 0.08));
    border-color: rgba(255, 255, 255, 0.16);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.12),
      0 2px 10px rgba(0, 0, 0, 0.18);
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
  }

  .tc-mobile-toggle span {
    background: rgba(238, 248, 245, 0.92);
  }

  /* 侧滑菜单：实色底（禁用 blur，避免 WebKit 文字发糊） */
  .tc-nav-panel {
    background: #0f241e;
    background: var(--bg-mid, #0f241e);
    border-left: 0.5px solid rgba(255, 255, 255, 0.14);
    box-shadow: -16px 0 48px rgba(0, 0, 0, 0.38);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    filter: none;
    isolation: isolate;
  }

  .tc-liquid-glass .tc-nav-panel {
    background: #0f241e;
    background: var(--bg-mid, #0f241e);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    filter: none;
  }

  .tc-liquid-glass .tc-nav-panel::before,
  .tc-liquid-glass .tc-nav-panel::after {
    display: none !important;
  }

  .tc-nav-panel .tc-nav-indicator,
  .tc-liquid-glass .tc-nav-panel .tc-nav-indicator {
    display: none !important;
  }

  .tc-nav-panel .tc-nav-glass {
    position: relative;
    z-index: 2;
    display: block;
    width: 100%;
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    isolation: auto;
  }

  .tc-nav-panel .tc-nav ul {
    gap: 10px;
  }

  .tc-nav-panel .tc-nav li + li::before {
    display: none;
  }

  /* 侧滑菜单文字：实色卡片 + 高对比（仅手机抽屉） */
  .tc-nav-panel .tc-nav a,
  .tc-liquid-glass .tc-nav-panel .tc-nav a {
    position: relative;
    z-index: 1;
    display: block;
    padding: 16px 18px;
    color: #ffffff;
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: 1.35;
    -webkit-font-smoothing: antialiased;
    text-shadow: none;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
    overflow: visible;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    filter: none;
    mix-blend-mode: normal;
  }

  .tc-nav-panel .tc-nav a .tc-lg-ripple {
    display: none !important;
  }

  .tc-nav-panel .tc-nav a:hover,
  .tc-liquid-glass .tc-nav-panel .tc-nav a:hover,
  .tc-liquid-glass .tc-nav-panel .tc-nav a.is-lg-hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.22);
  }

  .tc-nav-panel .tc-nav .is-active a,
  .tc-liquid-glass .tc-nav-panel .tc-nav .is-active a {
    color: #ffffff;
    font-weight: 800;
    background: color-mix(in srgb, var(--sp-accent) 38%, #163028);
    border-color: color-mix(in srgb, var(--sp-accent-3) 65%, rgba(255, 255, 255, 0.25));
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.18),
      0 0 18px color-mix(in srgb, var(--sp-accent) 40%, transparent);
  }

  .tc-liquid-glass .tc-nav-panel .tc-nav .is-active a,
  .tc-liquid-glass .tc-nav-panel .tc-nav a:active,
  .tc-liquid-glass .tc-nav-panel .tc-nav a.is-lg-pressed {
    color: #ffffff;
    font-weight: 800;
    background: color-mix(in srgb, var(--sp-accent) 38%, #163028);
    border: 1px solid color-mix(in srgb, var(--sp-accent-3) 65%, rgba(255, 255, 255, 0.25));
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.18),
      0 0 18px color-mix(in srgb, var(--sp-accent) 40%, transparent);
    transform: none;
    filter: none;
  }

  .tc-nav-panel .tc-header-cta,
  .tc-liquid-glass .tc-nav-panel .tc-header-cta {
    position: relative;
    z-index: 1;
    margin-top: 20px;
    padding: 16px 20px !important;
    color: #ffffff !important;
    font-size: 1.12rem !important;
    font-weight: 800 !important;
    letter-spacing: 0.04em;
    text-shadow: none;
    border-radius: 999px;
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.45),
      0 12px 32px color-mix(in srgb, var(--sp-accent) 55%, transparent);
  }

  .tc-nav-open .tc-header,
  .tc-liquid-glass .tc-nav-open .tc-header {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .tc-logo-text {
    color: #ffffff;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
  }

  /* iOS / 微信：内容区卡片仍避免多层 blur 发糊 */
  .tc-liquid-glass .tc-glass-card,
  .tc-liquid-glass .tc-plan,
  .tc-liquid-glass .tc-proof-panel,
  .tc-liquid-glass .tc-showcase-stage,
  .tc-liquid-glass .tc-media-shell,
  .tc-liquid-glass .tc-enterprise-panel,
  .tc-liquid-glass .tc-backend-strip,
  .tc-liquid-glass .tc-carousel-dots,
  .tc-liquid-glass .tc-carousel-btn,
  .tc-liquid-glass .tc-manifesto-text,
  .tc-liquid-glass .tc-stat-tile,
  .tc-liquid-glass .tc-trust-item {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: rgba(255, 255, 255, 0.08);
  }

  .tc-liquid-glass .tc-nav-indicator,
  .tc-liquid-glass .tc-carousel-dots-indicator {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .tc-liquid-glass .tc-carousel-dots-indicator {
    background: rgba(255, 255, 255, 0.22);
    border: 0.5px solid rgba(255, 255, 255, 0.45);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.55),
      0 2px 8px rgba(0, 0, 0, 0.15);
  }

  .tc-liquid-glass.tc-check-page .tc-check-card,
  .tc-liquid-glass .tc-pay-card {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: rgba(15, 36, 30, 0.94);
  }

  .tc-mobile-backdrop {
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    background: rgba(4, 10, 8, 0.62);
  }

  /* 抽屉关闭时不参与合成，避免 Safari 残影模糊 */
  .tc-nav-panel {
    visibility: hidden;
    pointer-events: none;
  }

  .tc-nav-open .tc-nav-panel {
    visibility: visible;
    pointer-events: auto;
  }

  .tc-header {
    padding-top: env(safe-area-inset-top, 0);
  }

  .tc-wrap {
    width: min(var(--tc-max), calc(100% - 24px));
  }

  /* Hero */
  .tc-hero {
    min-height: auto;
    padding: calc(var(--tc-header-h) + env(safe-area-inset-top, 0px) + 20px) 0 48px;
  }

  .tc-hero-grid {
    gap: 28px;
  }

  .tc-hero-brand {
    font-size: clamp(1.85rem, 8.5vw, 2.4rem);
  }

  .tc-hero-tagline {
    font-size: clamp(1.25rem, 5.5vw, 1.6rem);
  }

  .tc-hero-desc {
    font-size: 0.95rem;
    line-height: 1.65;
    margin-bottom: 20px;
  }

  .tc-hero-pillars {
    justify-content: center;
    margin-bottom: 20px;
  }

  .tc-hero-pillars li {
    font-size: 0.78rem;
    padding: 6px 10px;
  }

  .tc-hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .tc-hero-actions .tc-btn {
    width: 100%;
    justify-content: center;
  }

  .tc-device-frame {
    max-width: min(260px, 78vw);
    margin-inline: auto;
  }

  .tc-section {
    padding: 52px 0;
  }

  .tc-head {
    margin-bottom: 36px;
  }

  .tc-head h2 {
    font-size: clamp(1.45rem, 6vw, 1.85rem);
  }

  .tc-lead {
    font-size: 0.92rem;
  }

  /* 轮播分页：11 个数字横向滑动 */
  .tc-carousel-controls {
    flex-wrap: nowrap;
    gap: 8px;
    padding: 0 4px;
    max-width: 100%;
  }

  .tc-carousel-dots {
    flex: 1;
    min-width: 0;
    max-width: calc(100vw - 108px);
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 4px 6px;
  }

  .tc-carousel-dots::-webkit-scrollbar {
    display: none;
  }

  .tc-carousel-dot {
    min-width: 24px;
    height: 24px;
    padding: 0 5px;
    font-size: 0.68rem;
    flex-shrink: 0;
  }

  .tc-carousel-btn {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
  }

  /* 授权查询页 */
  .tc-check-page .tc-check-hero {
    padding: calc(var(--tc-header-h) + env(safe-area-inset-top, 0px) + 24px) 0 48px;
  }

  .tc-check-page .tc-check-hero h1 {
    font-size: 1.55rem;
    line-height: 1.25;
  }

  .tc-check-page .tc-check-hero p {
    font-size: 0.92rem;
    padding: 0 8px;
  }

  .tc-check-page .tc-check-card {
    margin: -28px auto 40px;
    padding: 22px 18px;
    border-radius: 18px;
  }

  .tc-check-page .tc-check-field input {
    height: 48px;
    font-size: 16px;
  }

  .tc-check-page .tc-check-submit {
    height: 48px;
    font-size: 1rem;
    border-radius: 12px;
  }

  /* 支付页 */
  .tc-pay-page {
    padding: max(24px, env(safe-area-inset-top)) 16px max(24px, env(safe-area-inset-bottom));
  }

  .tc-pay-card {
    padding: 28px 20px 24px;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .tc-pay-actions {
    flex-direction: column;
  }

  .tc-pay-actions .tc-btn {
    width: 100%;
  }

  .tc-footer {
    padding-bottom: calc(32px + env(safe-area-inset-bottom, 0px));
  }

  .tc-back-top {
    right: max(14px, env(safe-area-inset-right));
    bottom: max(14px, env(safe-area-inset-bottom));
  }

  /* 定价 / 卡片 */
  .tc-pricing-grid {
    gap: 16px;
  }

  .tc-plan {
    padding: 24px 20px;
  }

  .tc-news-list .tc-news-card-link,
  .tc-news-compact .tc-news-card-link {
    flex-direction: column;
  }

  .tc-news-list .tc-news-media,
  .tc-news-compact .tc-news-media {
    flex: none;
    width: 100%;
    max-width: none;
    border-right: none;
    border-bottom: 1px solid var(--tc-border);
  }
}

@media (max-width: 640px) {
  .tc-logo {
    max-width: min(150px, 46vw);
    padding: 5px 8px 5px 10px;
  }

  .tc-logo-text {
    font-size: 0.95rem;
  }

  .tc-proof-stats {
    gap: 10px;
  }

  .tc-feature-grid {
    gap: 24px;
  }

  .tc-showcase-stage {
    padding: 16px 12px;
  }
}
