/* StandardsUpdate 样式定义 */
@charset "UTF-8";

:root {
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --bg-main: #f8fafc;
  --card-bg: #ffffff;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "WenQuanYi Micro Hei", sans-serif;
  background-color: var(--bg-main);
  color: var(--text-main);
  -webkit-font-smoothing: antialiased;
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* 全局强力自动换行规则：防止未分隔的长英文字符、标准号、WTO通报号撑破容器或造成折行混乱 */
*, ::before, ::after {
  overflow-wrap: anywhere;
  word-break: break-word;
}

h1, h2, h3, h4, h5, h6, p, span, a, div, article {
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* 顶部导航栏专用防挤压与防折行强化规则 (杜绝字符垂直折行) */
header,
header *,
header button,
header a,
header span,
header h1,
header nav,
.header-no-wrap {
  white-space: nowrap !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
}


/* 卡片顶部双栏布局：确保日期始终固定在右上角，不被左侧超长通报号挤下行 */
.card-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.625rem;
  width: 100%;
}

.card-header-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.375rem;
  min-width: 0;
  flex: 1 1 auto;
}

.card-header-date {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.75rem;
  color: #64748b;
  flex-shrink: 0;
  white-space: nowrap;
  padding-top: 0.125rem;
}

/* 已读/已点击公告标题变浅专属样式 (Visited / Read State) */
.bulletin-title {
  transition: color 0.18s ease-in-out, opacity 0.18s ease-in-out;
}

.bulletin-title.bulletin-title-read,
.bulletin-title-read {
  color: #94a3b8 !important; /* 柔和浅灰色 (slate-400)，对比鲜明清晰 */
  font-weight: 600 !important;
  opacity: 0.88;
}

.bulletin-title.bulletin-title-read:hover,
.bulletin-title-read:hover {
  color: #64748b !important; /* 悬停时稍微加深至 slate-500，保留交互反馈 */
  opacity: 1;
}

/* 现代化时序轴架构 (Apple / Linear 风格高阶时间刻度体系) */
.timeline-container {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.timeline-node {
  position: relative;
  display: flex;
  align-items: stretch;
  gap: 0.875rem;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (min-width: 640px) {
  .timeline-node {
    gap: 1.25rem;
  }
}

.timeline-node:hover .timeline-card-content {
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
  border-color: #cbd5e1;
}

.dark .timeline-node:hover .timeline-card-content {
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
  border-color: #475569;
}

/* 左侧时序刻度柱 */
.timeline-axis-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 3.5rem;
  flex-shrink: 0;
  padding-top: 0.25rem;
}

@media (min-width: 640px) {
  .timeline-axis-col {
    width: 4.5rem;
  }
}

/* 日期微卡片 */
.timeline-date-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.375rem 0.25rem;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 0.875rem;
  box-shadow: 0 2px 5px rgba(15, 23, 42, 0.05);
  text-align: center;
  user-select: none;
  transition: all 0.2s ease;
}

.dark .timeline-date-card {
  background: #1e293b;
  border-color: #334155;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.timeline-node:hover .timeline-date-card {
  border-color: #3b82f6;
  box-shadow: 0 4px 10px rgba(59, 130, 246, 0.15);
  transform: scale(1.03);
}

.timeline-date-year {
  font-size: 0.6875rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-weight: 700;
  color: #64748b;
  letter-spacing: 0.03em;
  line-height: 1;
}

.dark .timeline-date-year {
  color: #94a3b8;
}

.timeline-date-day {
  font-size: 0.8125rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
  margin-top: 0.25rem;
  line-height: 1.1;
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
}

@media (min-width: 640px) {
  .timeline-date-day {
    font-size: 0.9375rem;
  }
}

.dark .timeline-date-day {
  color: #f8fafc;
}

/* 时序主导轨与光标点 */
.timeline-spine {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  width: 100%;
  margin-top: 0.5rem;
  position: relative;
}

.timeline-spine-dot {
  width: 0.5625rem;
  height: 0.5625rem;
  border-radius: 9999px;
  background-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
  margin-bottom: 0.375rem;
  transition: all 0.2s ease;
  z-index: 2;
}

.timeline-node:hover .timeline-spine-dot {
  transform: scale(1.25);
  box-shadow: 0 0 0 5px rgba(59, 130, 246, 0.25);
}

.timeline-spine-line {
  flex: 1;
  width: 2px;
  background: linear-gradient(180deg, rgba(203, 213, 225, 0.9) 0%, rgba(226, 232, 240, 0.4) 100%);
  border-radius: 1px;
}

.dark .timeline-spine-line {
  background: linear-gradient(180deg, rgba(51, 65, 85, 0.8) 0%, rgba(30, 41, 59, 0.3) 100%);
}

.timeline-node:last-child .timeline-spine-line {
  background: linear-gradient(180deg, rgba(203, 213, 225, 0.8) 0%, transparent 100%);
}

/* 右侧内容主容器 */
.timeline-card-content {
  flex: 1;
  min-width: 0;
}

/* 标签胶囊动态高亮 */
.filter-tab.active {
  background-color: #1e293b;
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.industry-chip.active {
  background-color: #2563eb;
  color: #ffffff;
  border-color: #2563eb;
}

.status-chip.active {
  border-color: #0f172a;
  background-color: #f1f5f9;
  font-weight: 600;
}

/* 弹窗与滚动条 */
dialog::backdrop {
  background-color: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
}

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* 隐藏横向/纵向滚动条，支持原生触控手势滑动但消除丑陋滚动条 */
.scrollbar-none {
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}
.scrollbar-none::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

/* 渐变玻璃卡片 */
.glass-panel {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
}

/* =========================================================================
 * 移动端体验适配 (Mobile Responsive & Touch Targets)
 * ========================================================================= */
@media (max-width: 768px) {
  body {
    padding-bottom: calc(4.5rem + env(safe-area-inset-bottom, 0px));
  }

  .mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 45;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(12px);
    border-top: 1px solid #e2e8f0;
    padding-bottom: env(safe-area-inset-bottom, 0px);
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.05);
  }

  .mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0.25rem;
    font-size: 0.6875rem;
    font-weight: 600;
    color: #64748b;
    transition: all 0.15s ease-in-out;
  }

  .mobile-nav-item.active {
    color: #2563eb;
  }

  .mobile-nav-item.active svg,
  .mobile-nav-item.active span.icon {
    transform: scale(1.1);
  }

  /* 移动端表格横向平滑滑动 */
  .overflow-x-auto {
    -webkit-overflow-scrolling: touch;
  }

  /* 移动端卡片平铺对齐 */
  .timeline-container {
    padding-left: 0 !important;
  }

  .timeline-container::before,
  .timeline-dot {
    display: none !important;
  }
}

/* =========================================================================
 * 官方标准有效性查新证明打印样式 (Print Stylesheet)
 * ========================================================================= */
@media print {
  @page {
    size: A4 portrait;
    margin: 12mm 15mm;
  }

  body {
    background-color: #ffffff !important;
    color: #000000 !important;
    padding: 0 !important;
    font-size: 10pt;
  }

  /* 隐藏所有页面操作按钮、导航栏、搜索框和弹窗控制器 */
  header,
  footer,
  .mobile-bottom-nav,
  #bulletinsMainView,
  #schedulerBadgeBtn,
  #storageBadgeBtn,
  #userTierBtn,
  #userTierDropdown,
  #openAddModalBtn,
  #refreshBtn,
  #openSourcesModalBtn,
  .no-print,
  button,
  input,
  select {
    display: none !important;
  }

  /* 打印时容器全宽无阴影 */
  .max-w-7xl,
  .max-w-4xl,
  .max-w-2xl {
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-shadow: none !important;
    border: none !important;
  }

  /* 确保公章与红印高对比度打印 */
  svg text {
    print-color-adjust: exact;
    -webkit-print-color-adjust: exact;
  }

  table {
    border-collapse: collapse !important;
    width: 100% !important;
  }

  table, th, td {
    border: 1px solid #94a3b8 !important;
  }

  th {
    background-color: #f1f5f9 !important;
    color: #0f172a !important;
    print-color-adjust: exact;
    -webkit-print-color-adjust: exact;
  }
}

/* ==========================================================================
   标准知识图谱与多维关系链样式 (Knowledge Graph & Lineage Styles)
   ========================================================================== */
.graph-container {
  position: relative;
  width: 100%;
  background: radial-gradient(circle at 50% 50%, #f8fafc 0%, #f1f5f9 100%);
  border: 1px solid #e2e8f0;
  border-radius: 1rem;
  overflow: hidden;
}

.graph-canvas {
  width: 100%;
  height: 500px;
}

@media (min-width: 1024px) {
  .graph-canvas-lg {
    height: 620px;
  }
}

/* 代际更迭时间轴 (Lineage Stepper) */
.stepper-container {
  display: flex;
  align-items: stretch;
  gap: 1.5rem;
  overflow-x: auto;
  padding: 1.25rem 0.5rem;
  scrollbar-width: thin;
}

.stepper-item {
  position: relative;
  flex: 0 0 220px;
  display: flex;
  flex-direction: column;
}

.stepper-item:not(:last-child)::after {
  content: "➔";
  position: absolute;
  right: -1.1rem;
  top: 2rem;
  color: #94a3b8;
  font-weight: 900;
  font-size: 1.1rem;
}

/* 图谱右侧浮动信息卡 */
.graph-floating-panel {
  position: absolute;
  top: 1rem;
  right: 1rem;
  max-width: 290px;
  width: calc(100% - 2rem);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 0.75rem;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
  padding: 0.875rem;
  z-index: 20;
}

/* ============================================================ */
/* 苹果极简扁平风标准分类卡片 (Apple-Style Novelty Category Cards) */
/* ============================================================ */
.novelty-cat-card {
  position: relative;
  background-color: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 1.125rem;
  padding: 0.9rem 1rem;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  user-select: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.novelty-cat-card:hover:not(.active) {
  background-color: #ffffff;
  border-color: #60a5fa;
  box-shadow: 0 8px 24px -4px rgba(37, 99, 235, 0.12), 0 2px 6px -2px rgba(37, 99, 235, 0.04);
  transform: translateY(-2px);
}

.novelty-cat-card:hover:not(.active) .cat-name {
  color: #2563eb;
}

.novelty-cat-card:hover:not(.active) .cat-num {
  color: #1d4ed8;
}

/* 选中激活态：高能亮眼 Apple 经典蓝渐变底色 + 纯白文字 + 蓝光扩散立体阴影，拒绝黑色，一目了然！ */
.novelty-cat-card.active {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 60%, #1e40af 100%) !important;
  border-color: #1d4ed8 !important;
  box-shadow: 0 14px 30px -4px rgba(37, 99, 235, 0.42), 0 4px 12px -2px rgba(37, 99, 235, 0.22) !important;
  transform: translateY(-4px) scale(1.02);
  outline: 2.5px solid #bfdbfe !important;
  outline-offset: 1px;
}

.novelty-cat-card.active .cat-name {
  color: #ffffff !important;
  font-weight: 800 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}

.novelty-cat-card.active .cat-num {
  color: #ffffff !important;
  font-weight: 900 !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2) !important;
}

.novelty-cat-card.active .cat-sub {
  color: #dbeafe !important;
  font-weight: 600 !important;
}

.novelty-cat-card.active .cat-icon {
  background: rgba(255, 255, 255, 0.25) !important;
  border: 1.5px solid rgba(255, 255, 255, 0.45) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12) !important;
}

/* 激活徽章：右上角白色微型药丸胶囊 */
.novelty-cat-card .cat-active-badge {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 10px;
  line-height: 1;
  font-weight: 800;
  padding: 2.5px 7px;
  border-radius: 9999px;
  background-color: #ffffff;
  color: #1d4ed8;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
  opacity: 0;
  transform: scale(0.6);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

.novelty-cat-card.active .cat-active-badge {
  opacity: 1;
  transform: scale(1);
}

.novelty-cat-card .cat-num {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.025em;
  color: #1e293b;
  font-weight: 800;
  transition: color 0.2s ease;
}

.novelty-cat-card .cat-name {
  color: #334155;
  font-weight: 700;
  transition: color 0.2s ease;
}

.novelty-cat-card .cat-sub {
  color: #64748b;
  font-weight: 500;
  transition: color 0.2s ease;
}

/* ============================================================ */
/* 全站夜间模式 (Apple Dark Mode System) & 访问适配增强规则 */
/* ============================================================ */
html.dark {
  --primary: #3b82f6;
  --primary-hover: #60a5fa;
  --bg-main: #0b0f19;
  --card-bg: #131c31;
  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --border-color: #1e293b;
  color-scheme: dark;
}

/* 1. 基础表面与背景夜间适配 */
html.dark body {
  background-color: #0b0f19 !important;
  color: #f1f5f9 !important;
}

html.dark header {
  background-color: rgba(11, 15, 25, 0.94) !important;
  border-color: rgba(30, 41, 59, 0.8) !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4) !important;
}

html.dark .bg-white {
  background-color: #131c31 !important;
}

html.dark .bg-slate-50 {
  background-color: #0b0f19 !important;
}

html.dark .bg-slate-100 {
  background-color: #1e293b !important;
}

html.dark .bg-slate-200 {
  background-color: #293548 !important;
}

html.dark .border-slate-200,
html.dark .border-slate-100 {
  border-color: #1e293b !important;
}

html.dark .text-slate-900,
html.dark .text-slate-800 {
  color: #f8fafc !important;
}

html.dark .text-slate-700 {
  color: #cbd5e1 !important;
}

html.dark .text-slate-600 {
  color: #94a3b8 !important;
}

html.dark .text-slate-500,
html.dark .text-slate-400 {
  color: #64748b !important;
}

/* 2. 苹果风主导航分段器夜间适配 */
html.dark nav.md\:flex {
  background-color: rgba(30, 41, 59, 0.75) !important;
  border-color: rgba(51, 65, 85, 0.6) !important;
}

html.dark nav.md\:flex button.bg-white {
  background-color: #1e293b !important;
  color: #60a5fa !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4) !important;
  ring-color: rgba(255, 255, 255, 0.1) !important;
}

html.dark nav.md\:flex button:not(.bg-white) {
  color: #94a3b8 !important;
}

html.dark nav.md\:flex button:not(.bg-white):hover {
  color: #ffffff !important;
  background-color: rgba(255, 255, 255, 0.05) !important;
}

/* 3. 查新 7 大分类卡片夜间模式深度适配 */
html.dark #noveltyMainView section:first-child {
  background: linear-gradient(180deg, rgba(23, 32, 51, 0.8) 0%, rgba(15, 23, 42, 0.95) 100%) !important;
  border-color: #1e293b !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25) !important;
}

html.dark .novelty-cat-card:not(.active) {
  background-color: #172033 !important;
  border-color: #293548 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2) !important;
}

html.dark .novelty-cat-card:not(.active):hover {
  background-color: #1e293b !important;
  border-color: #3b82f6 !important;
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.5) !important;
}

html.dark .novelty-cat-card:not(.active) .cat-num {
  color: #f8fafc !important;
}

html.dark .novelty-cat-card:not(.active) .cat-name {
  color: #cbd5e1 !important;
}

html.dark .novelty-cat-card:not(.active) .cat-sub {
  color: #94a3b8 !important;
}

html.dark .novelty-cat-card:not(.active):hover .cat-name {
  color: #60a5fa !important;
}

html.dark .novelty-cat-card:not(.active):hover .cat-num {
  color: #93c5fd !important;
}

html.dark .novelty-cat-card.active {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 60%, #1e40af 100%) !important;
  border-color: #1d4ed8 !important;
  box-shadow: 0 16px 36px -4px rgba(37, 99, 235, 0.55), 0 4px 12px -2px rgba(37, 99, 235, 0.3) !important;
  outline: 2.5px solid #60a5fa !important;
}

html.dark .novelty-cat-card.active .cat-num {
  color: #ffffff !important;
}

html.dark .novelty-cat-card.active .cat-name {
  color: #ffffff !important;
}

html.dark .novelty-cat-card.active .cat-sub {
  color: #dbeafe !important;
}

html.dark .novelty-cat-card.active .cat-active-badge {
  background-color: #ffffff !important;
  color: #1d4ed8 !important;
}

/* 4. 输入框、搜索栏、弹窗、下拉菜单夜间模式适配 */
html.dark input,
html.dark textarea,
html.dark select {
  background-color: #172033 !important;
  border-color: #293548 !important;
  color: #f8fafc !important;
}

html.dark input::placeholder,
html.dark textarea::placeholder {
  color: #64748b !important;
}

html.dark #userProfileNavMenu,
html.dark .modal-content,
html.dark [id$="Modal"] > div > div {
  background-color: #131c31 !important;
  border-color: #1e293b !important;
  color: #f1f5f9 !important;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5) !important;
}

/* 5. 移动端底部导航与交互适配 */
html.dark .mobile-bottom-nav {
  background-color: rgba(11, 15, 25, 0.95) !important;
  border-color: #1e293b !important;
}

html.dark .mobile-nav-item {
  color: #64748b !important;
}

html.dark .mobile-nav-item.active {
  color: #3b82f6 !important;
}

/* 6. 表格、数据细目夜间模式适配 */
html.dark table th {
  background-color: #1e293b !important;
  color: #cbd5e1 !important;
  border-color: #293548 !important;
}

html.dark table td {
  border-color: #1e293b !important;
  color: #cbd5e1 !important;
}

html.dark tr:hover td {
  background-color: rgba(30, 41, 59, 0.6) !important;
}

/* 7. 药丸过滤标签夜间模式适配 */
html.dark .novelty-cat-pill:not(.active),
html.dark .novelty-status-pill:not(.active) {
  background-color: #1e293b !important;
  color: #cbd5e1 !important;
  border-color: #293548 !important;
}

html.dark .novelty-tag-btn {
  background-color: #1e293b !important;
  color: #cbd5e1 !important;
}

html.dark .novelty-tag-btn:hover {
  background-color: #2563eb !important;
  color: #ffffff !important;
}

/* 主题分段选择器样式 (Theme Segmented Controls) */
.theme-segmented-wrapper {
  background-color: #f1f5f9;
  border-color: #e2e8f0;
}
.theme-seg-btn {
  color: #64748b;
  cursor: pointer;
  user-select: none;
}
.theme-seg-btn:hover {
  color: #0f172a;
}
.theme-seg-btn.active {
  background-color: #ffffff !important;
  color: #2563eb !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  font-weight: 700;
}
html.dark .theme-segmented-wrapper {
  background-color: #0b0f19 !important;
  border-color: #1e293b !important;
}
html.dark .theme-seg-btn {
  color: #94a3b8 !important;
}
html.dark .theme-seg-btn:hover {
  color: #f8fafc !important;
}
html.dark .theme-seg-btn.active {
  background-color: #1e293b !important;
  color: #60a5fa !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

/* 顶部快速夜间模式按钮与用户导航胶囊适配 */
html.dark #themeToggleBtn {
  background-color: #131c31 !important;
  border-color: #1e293b !important;
  color: #f8fafc !important;
}
html.dark #themeToggleBtn:hover {
  background-color: #1e293b !important;
  color: #60a5fa !important;
}
html.dark #userProfileNavBtn {
  background-color: #131c31 !important;
  border-color: #1e293b !important;
  color: #f1f5f9 !important;
}
html.dark #userProfileNavBtn:hover {
  background-color: #1e293b !important;
}
html.dark #navUserName {
  color: #f8fafc !important;
}

/* ============================================================ */
/* 🍏 苹果原生级液态磨砂玻璃导航栏 (Apple Frosted Glass Header) */
/* ============================================================ */
.apple-glass-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.85) 0%, rgba(248, 250, 252, 0.72) 100%);
  backdrop-filter: blur(28px) saturate(185%) contrast(100%);
  -webkit-backdrop-filter: blur(28px) saturate(185%) contrast(100%);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.95), 0 4px 20px -2px rgba(15, 23, 42, 0.04);
  border-bottom: 1px solid rgba(226, 232, 240, 0.75);
  transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.apple-glass-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2.5px;
  background: linear-gradient(90deg, 
    rgba(59, 130, 246, 0) 0%, 
    rgba(59, 130, 246, 0.4) 25%, 
    rgba(99, 102, 241, 0.55) 50%, 
    rgba(6, 182, 212, 0.4) 75%, 
    rgba(59, 130, 246, 0) 100%
  );
  opacity: 0.9;
  pointer-events: none;
}

html.dark .apple-glass-header {
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.84) 0%, rgba(15, 23, 42, 0.72) 100%) !important;
  backdrop-filter: blur(28px) saturate(190%) contrast(102%) !important;
  -webkit-backdrop-filter: blur(28px) saturate(190%) contrast(102%) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.08), 0 6px 24px -2px rgba(0, 0, 0, 0.45) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
}

html.dark .apple-glass-header::before {
  opacity: 0.6;
  background: linear-gradient(90deg, 
    rgba(59, 130, 246, 0) 0%, 
    rgba(96, 165, 250, 0.35) 25%, 
    rgba(129, 140, 248, 0.45) 50%, 
    rgba(56, 189, 248, 0.35) 75%, 
    rgba(59, 130, 246, 0) 100%
  );
}

.apple-nav-segmented {
  background-color: rgba(226, 232, 240, 0.65);
  border: 1px solid rgba(203, 213, 225, 0.5);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.04);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

html.dark .apple-nav-segmented {
  background-color: rgba(30, 41, 59, 0.65) !important;
  border-color: rgba(51, 65, 85, 0.6) !important;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3) !important;
}

/* ============================================================ */
/* 全设备访问适配规则 (Responsive & Device Accessibility) */
/* ============================================================ */
html, body {
  max-width: 100vw;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
}

/* 移动端安全区域与底部边距适配 (iPhone 触控条与刘海屏适配) */
body {
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

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

.mobile-bottom-nav {
  padding-bottom: calc(0.35rem + env(safe-area-inset-bottom, 0px));
  padding-left: env(safe-area-inset-left, 0px);
  padding-right: env(safe-area-inset-right, 0px);
}

/* 触控横向平滑惯性滚动 */
.overflow-x-auto,
.table-responsive,
#noveltyCategoryPills,
#noveltyStatusPills {
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

/* 移动端弹窗与卡片尺寸舒适度适配 */
@media (max-width: 640px) {
  .modal-content,
  [id$="Modal"] > div > div {
    max-height: 88vh !important;
    max-width: 95vw !important;
    margin: auto !important;
  }
  
  .novelty-cat-card {
    padding: 0.75rem 0.85rem !important;
  }
  
  .novelty-cat-card .cat-num {
    font-size: 1.35rem !important;
  }
  
  header .max-w-\[1536px\] {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }
}

/* ============================================================ */
/* 苹果极简扁平搜索栏设计风格 (Apple Flat Search Style) */
/* ============================================================ */
.apple-search-bar {
  background-color: rgba(241, 245, 249, 0.85);
  border: 1.5px solid #e2e8f0;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.02);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.apple-search-bar:hover {
  background-color: rgba(241, 245, 249, 1);
  border-color: #cbd5e1;
}

.apple-search-bar:focus-within {
  background-color: #ffffff !important;
  border-color: #2563eb !important;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12), 0 8px 24px -4px rgba(37, 99, 235, 0.08) !important;
}

.apple-search-bar input {
  background-color: transparent !important;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  color: #0f172a !important;
}

.apple-search-bar input::placeholder {
  color: #94a3b8 !important;
}

.apple-search-btn {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #ffffff !important;
  border-radius: 0.85rem;
  font-weight: 600;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.25);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.apple-search-btn:hover {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  transform: translateY(-0.5px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35);
}

.apple-search-btn:active {
  transform: scale(0.97);
  box-shadow: 0 1px 3px rgba(37, 99, 235, 0.2);
}

.apple-search-clear-btn {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 9999px;
  background-color: #e2e8f0;
  color: #64748b;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.apple-search-clear-btn:hover {
  background-color: #cbd5e1;
  color: #1e293b;
}

/* 夜间模式适配 */
html.dark .apple-search-bar {
  background-color: rgba(19, 28, 49, 0.75) !important;
  border-color: #1e293b !important;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.2);
}

html.dark .apple-search-bar:hover {
  background-color: rgba(19, 28, 49, 0.95) !important;
  border-color: #293548 !important;
}

html.dark .apple-search-bar:focus-within {
  background-color: #0d1526 !important;
  border-color: #3b82f6 !important;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2), 0 8px 24px -4px rgba(0, 0, 0, 0.5) !important;
}

html.dark .apple-search-bar input {
  background-color: transparent !important;
  border: none !important;
  color: #f8fafc !important;
}

html.dark .apple-search-bar input::placeholder {
  color: #64748b !important;
}

html.dark .apple-search-clear-btn {
  background-color: #293548 !important;
  color: #94a3b8 !important;
}

html.dark .apple-search-clear-btn:hover {
  background-color: #334155 !important;
  color: #f1f5f9 !important;
}

html.dark .apple-search-btn {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.4);
}

html.dark .apple-search-btn:hover {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
}

/* ==========================================================================
   Apple 原生级液态磨砂玻璃导航栏与画质感光晕 (Frosted Liquid Glass Header)
   ========================================================================== */
.apple-glass-header {
  position: sticky;
  top: 0;
  z-index: 40;
  width: 100%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.82) 0%, rgba(248, 250, 252, 0.78) 100%) !important;
  backdrop-filter: blur(28px) saturate(190%) contrast(102%) !important;
  -webkit-backdrop-filter: blur(28px) saturate(190%) contrast(102%) !important;
  border-bottom: 1px solid rgba(226, 232, 240, 0.75) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.95), 0 4px 20px -2px rgba(15, 23, 42, 0.05) !important;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* 顶部环境流光微光弧线 (Subtle Aurora Accent Line) */
.apple-glass-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, 
    rgba(59, 130, 246, 0) 0%, 
    rgba(59, 130, 246, 0.5) 25%, 
    rgba(99, 102, 241, 0.7) 50%, 
    rgba(14, 165, 233, 0.5) 75%, 
    rgba(59, 130, 246, 0) 100%
  );
  z-index: 50;
  pointer-events: none;
}

/* Apple iOS 18 风格微透分段导航槽 (Apple Segmented Bar) */
.apple-nav-segmented {
  background: rgba(241, 245, 249, 0.75) !important;
  border: 1px solid rgba(226, 232, 240, 0.8) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04);
}

/* 夜间深色模式 (Apple Pro Dark Liquid Glass) */
html.dark .apple-glass-header {
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.82) 0%, rgba(15, 23, 42, 0.75) 100%) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.08), 0 8px 32px -4px rgba(0, 0, 0, 0.5) !important;
}

html.dark .apple-glass-header::before {
  background: linear-gradient(90deg, 
    rgba(59, 130, 246, 0) 0%, 
    rgba(59, 130, 246, 0.4) 25%, 
    rgba(129, 140, 248, 0.6) 50%, 
    rgba(56, 189, 248, 0.4) 75%, 
    rgba(59, 130, 246, 0) 100%
  );
}

html.dark .apple-nav-segmented {
  background: rgba(30, 41, 59, 0.6) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.25);
}

/* 彻底消除多主视图切换时的顶部间隙不一致问题 (标准动态、标准查新、标准族谱完全像素级等距) */
main > #bulletinsMainView,
main > #noveltyMainView,
main > #graphMainView {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 0 !important;
}
