/* ==========================================================================
   婧文教育官网样式 —— 复刻 wenbita.cn（文笔塔）的框架与视觉样式
   设计令牌取自 wenbita.cn 实测计算样式：
     品牌藏青 #0f2b4d ／ 强调赭红 #b8321a ／ 底色 #fafafa ／ 文字 #111827
     标题衬线（Noto Serif SC 回退宋体）／ 正文无衬线 ／ 卡片白底 1px #e8e8e8 圆角 12
     区块上下留白 80px ／ 顶栏高 40px ／ 导航条高 92px、链接 34px 11px 内边距
   ========================================================================== */
:root {
  --pt-navy: #0f2b4d;
  --pt-navy-d: #0a1f3a;
  --pt-accent: #b8321a;
  --pt-accent-d: #9d2a15;
  --pt-ink: #111827;
  --pt-ink-2: #4b5563;
  --pt-ink-3: #6b7280;
  --pt-line: #e8e8e8;
  --pt-bg: #fafafa;
  --pt-band: #f1f5f9;
  --pt-card: #ffffff;
  --pt-shell: 1280px;
  --pt-radius: 12px;
  --pt-sans: -apple-system, BlinkMacSystemFont, "Noto Sans SC", "PingFang SC",
             "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --pt-serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "STSong",
               SimSun, Georgia, serif;
}

/* 覆盖主题默认的浅灰底，统一为文笔塔的 #fafafa */
body { background-color: var(--pt-bg) !important; font-family: var(--pt-sans); color: var(--pt-ink); }

.pt-shell { max-width: var(--pt-shell); margin: 0 auto; padding-left: 32px; padding-right: 32px; }

/* ============================ 顶部信息条 ============================ */
.pt-topbar { background: var(--pt-navy); color: rgba(255, 255, 255, .78); font-size: 14px; line-height: 1.5; }
.pt-topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 40px; }
.pt-topbar-lead { display: flex; align-items: center; gap: 18px; min-width: 0; }
.pt-topbar-date { white-space: nowrap; }
.pt-topbar a { color: inherit; text-decoration: none; }
.pt-topbar a:hover { color: #fff; }
.pt-topbar-notice { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pt-topbar-contact { white-space: nowrap; }
.pt-topbar-contact a { color: #fff; font-weight: 600; margin-left: 6px; }

/* ============================ 主导航（横向） ============================ */
.pt-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255, 255, 255, .97);
  -webkit-backdrop-filter: saturate(180%) blur(8px);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--pt-line);
  transition: box-shadow .25s ease;
}
.pt-header.menu-sticky { box-shadow: 0 6px 20px rgba(15, 43, 77, .08); }
.pt-header-inner { display: flex; align-items: center; gap: 24px; min-height: 92px; }

.pt-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; flex: 0 0 auto; }
.pt-brand img { width: 56px; height: 56px; object-fit: contain; display: block; }
.pt-brand-copy strong {
  display: block; font-family: var(--pt-serif); font-size: 22px; font-weight: 700;
  color: var(--pt-navy); letter-spacing: .02em; line-height: 1.25;
}
.pt-brand-copy small { display: block; font-size: 12px; color: var(--pt-ink-3); margin-top: 2px; }

/* 关键：导航始终横向排列（窄屏横向滚动，不折叠成竖列） */
.pt-nav {
  margin-left: auto; min-width: 0; flex: 0 1 auto;
  overflow-x: auto;
  scrollbar-width: none; -ms-overflow-style: none;
}
.pt-nav::-webkit-scrollbar { display: none; }
.pt-nav ul {
  display: flex; flex-wrap: nowrap; align-items: center; gap: 24px;
  list-style: none; margin: 0; padding: 0; width: max-content;
}
.pt-nav a {
  display: block; padding: 34px 4px; font-size: 16px; font-weight: 500;
  color: var(--pt-navy); text-decoration: none; white-space: nowrap;
  border-bottom: 2px solid transparent; transition: color .2s ease, border-color .2s ease;
}
.pt-nav a:hover { color: var(--pt-accent); border-bottom-color: var(--pt-accent); }

.pt-header-actions { display: flex; align-items: center; gap: 16px; flex: 0 0 auto; }
.pt-icon-btn {
  display: inline-flex; align-items: center; gap: 6px; font-size: 14px;
  color: var(--pt-navy); text-decoration: none;
}
.pt-icon-btn:hover { color: var(--pt-accent); }
.pt-cta {
  display: inline-block; background: var(--pt-navy); color: #fff; padding: 10px 20px;
  border-radius: 4px; font-size: 14px; font-weight: 600; text-decoration: none;
  transition: background .2s ease;
}
.pt-cta:hover { background: var(--pt-accent); }

/* ============================ Hero ============================ */
.pt-hero { background: var(--pt-navy); color: #fff; padding: 72px 0 60px; position: relative; overflow: hidden; }
.pt-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
  background-size: 32px 28px;
}
.pt-hero .pt-shell { position: relative; z-index: 1; }
.pt-kicker {
  display: inline-block; font-size: 14px; font-weight: 500; letter-spacing: .7px;
  color: #fff; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .3);
  padding: 8px 14px; border-radius: 4px; margin: 0 0 24px;
}
.pt-hero h1 {
  font-family: var(--pt-serif); font-size: 60px; font-weight: 700; line-height: 1.22;
  color: #fff; margin: 0 0 20px; max-width: 20em;
}
.pt-hero-sub { font-size: 17px; line-height: 1.95; color: rgba(255, 255, 255, .82); max-width: 46em; margin: 0; }
.pt-hero-cta { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 36px; }
.pt-button {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 32px; border-radius: 4px; font-size: 16px; font-weight: 500;
  text-decoration: none; border: 1px solid transparent; transition: all .22s ease;
}
.pt-button-accent { background: var(--pt-accent); color: #fff; }
.pt-button-accent:hover { background: var(--pt-accent-d); }
.pt-button-ghost { border-color: rgba(255, 255, 255, .55); color: #fff; }
.pt-button-ghost:hover { background: rgba(255, 255, 255, .14); }

.pt-stats {
  list-style: none; margin: 44px 0 0; padding: 24px 0 0; display: grid; gap: 16px;
  grid-template-columns: repeat(2, 1fr); border-top: 1px solid rgba(255, 255, 255, .22);
}
@media (min-width: 768px) { .pt-stats { grid-template-columns: repeat(4, 1fr); } }
.pt-stats strong { display: block; font-family: var(--pt-serif); font-size: 34px; font-weight: 700; line-height: 1.1; }
.pt-stats span { display: block; margin-top: 8px; font-size: 13px; color: rgba(255, 255, 255, .72); }

/* ============================ 区块通用 ============================ */
/* 板块：每条板块上沿一条分隔线 + 白/浅灰蓝交替，界限一眼可辨 */
.pt-section {
  padding: 60px 0;
  background: var(--pt-band);
  border-top: 1px solid rgba(15, 43, 77, .10);
}
.pt-section-alt { background: #fff; }
/* 浅网格纹理 */
.pt-section-grid {
  background-color: var(--pt-band);
  background-image: linear-gradient(rgba(15, 43, 77, .045) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(15, 43, 77, .045) 1px, transparent 1px);
  background-size: 32px 28px;
}
.pt-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 16px;
  flex-wrap: wrap; margin-bottom: 36px;
}
.pt-eyebrow {
  font-size: 14px; font-weight: 500; letter-spacing: .7px; text-transform: uppercase;
  color: var(--pt-accent); margin: 0 0 7px;
}
.pt-head h2 {
  position: relative; padding-left: 16px;
  font-family: var(--pt-serif); font-size: 30px; font-weight: 700;
  color: var(--pt-navy); margin: 0; line-height: 1.3;
}
.pt-head h2::before {
  content: ""; position: absolute; left: 0; top: .16em; bottom: .16em;
  width: 4px; border-radius: 2px; background: var(--pt-accent);
}
.pt-more { font-size: 15px; color: var(--pt-navy); text-decoration: none; white-space: nowrap; }
.pt-more:hover { color: var(--pt-accent); }

/* ============================ 最新动态 ============================ */
.pt-news { display: grid; grid-template-columns: 1fr; gap: 24px; }
@media (min-width: 900px) { .pt-news { grid-template-columns: 1.05fr 1fr; } }
.pt-news-lead {
  display: block; text-decoration: none; color: inherit; background: var(--pt-card);
  border: 1px solid var(--pt-line); border-radius: 8px; padding: 32px;
  transition: box-shadow .25s ease, transform .25s ease;
}
.pt-news-lead:hover { box-shadow: 0 14px 32px rgba(15, 43, 77, .10); transform: translateY(-2px); }
.pt-chip {
  display: inline-block; font-size: 12px; font-weight: 600; color: var(--pt-accent);
  background: rgba(184, 50, 26, .08); padding: 4px 10px; border-radius: 4px;
}
.pt-news-lead h3 {
  font-family: var(--pt-serif); font-size: 26px; font-weight: 700; line-height: 1.5;
  color: var(--pt-navy); margin: 16px 0 12px;
}
.pt-news-lead p { font-size: 15px; line-height: 1.9; color: var(--pt-ink-2); margin: 0; }
.pt-news-lead time { display: block; margin-top: 18px; font-size: 13px; color: var(--pt-ink-3); }
.pt-news-list { list-style: none; margin: 0; padding: 0; }
.pt-news-list li { border-bottom: 1px solid var(--pt-line); }
.pt-news-list li:first-child { border-top: 1px solid var(--pt-line); }
.pt-news-list a { display: flex; gap: 18px; align-items: flex-start; padding: 20px 4px; text-decoration: none; color: inherit; }
.pt-news-list time { font-size: 13px; color: var(--pt-ink-3); white-space: nowrap; font-variant-numeric: tabular-nums; padding-top: 2px; }
.pt-news-list .pt-t { display: block; color: var(--pt-ink); font-size: 16px; line-height: 1.6; font-weight: 500; }
.pt-news-list .pt-c { display: block; margin-top: 6px; font-size: 13px; line-height: 1.7; color: var(--pt-ink-3); font-weight: 400; }
.pt-news-list a:hover .pt-t { color: var(--pt-accent); }

/* ============================ 卡片墙 ============================ */
.pt-cards { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 640px) { .pt-cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .pt-cards-4 { grid-template-columns: repeat(4, 1fr); } .pt-cards-3 { grid-template-columns: repeat(3, 1fr); } }
.pt-card {
  background: var(--pt-card); border: 1px solid var(--pt-line); border-radius: var(--pt-radius);
  padding: 28px 24px; display: flex; flex-direction: column; gap: 10px;
  transition: box-shadow .25s ease, transform .25s ease, border-color .25s ease;
}
.pt-card:hover { box-shadow: 0 14px 32px rgba(15, 43, 77, .10); transform: translateY(-3px); border-color: rgba(15, 43, 77, .35); }
.pt-card h3 { font-family: var(--pt-serif); font-size: 19px; font-weight: 700; color: var(--pt-navy); margin: 0; line-height: 1.4; }
.pt-card .pt-kicker2 { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--pt-accent); }
.pt-card p { font-size: 14px; line-height: 1.85; color: var(--pt-ink-2); margin: 0; }
.pt-card .pt-count { font-size: 13px; color: var(--pt-ink-3); }
.pt-card .pt-link { margin-top: auto; padding-top: 12px; font-size: 14px; font-weight: 600; color: var(--pt-navy); text-decoration: none; }
.pt-card .pt-link:hover { color: var(--pt-accent); }
.pt-tag {
  align-self: flex-start; font-size: 12px; font-weight: 600; padding: 4px 10px;
  border-radius: 4px; background: rgba(15, 43, 77, .08); color: var(--pt-navy);
}

/* ============================ 服务对象 ============================ */
.pt-audience { display: flex; flex-wrap: wrap; gap: 10px; padding: 0; margin: 0; list-style: none; }
.pt-audience li {
  padding: 8px 16px; border-radius: 4px; font-size: 14px;
  border: 1px solid var(--pt-line); color: var(--pt-ink-2); background: var(--pt-card);
}
/* 紧凑分隔条（服务对象） */
.pt-section-strip { padding: 34px 0; }
.pt-strip-inner { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.pt-strip-label {
  margin: 0; font-family: var(--pt-serif); font-size: 18px; font-weight: 700;
  color: var(--pt-navy); white-space: nowrap;
  position: relative; padding-left: 14px;
}
.pt-strip-label::before {
  content: ""; position: absolute; left: 0; top: .16em; bottom: .16em;
  width: 4px; border-radius: 2px; background: var(--pt-accent);
}

/* ============================ 联系条 ============================ */
.pt-band { background: var(--pt-navy); color: #fff; padding: 64px 0; }
.pt-band-inner { display: flex; flex-wrap: wrap; gap: 32px; align-items: center; justify-content: space-between; }
.pt-band h2 { font-family: var(--pt-serif); font-size: 30px; font-weight: 700; margin: 0 0 14px; }
.pt-band p { margin: 0; font-size: 15px; line-height: 1.95; color: rgba(255, 255, 255, .82); }
.pt-band-tel { text-align: right; }
.pt-band-tel p { font-size: 13px; letter-spacing: .1em; color: rgba(255, 255, 255, .7); margin-bottom: 6px; }
.pt-band .pt-tel { font-family: var(--pt-serif); font-size: 34px; font-weight: 700; color: #fff; text-decoration: none; }
.pt-band .pt-tel:hover { color: #ffd9cf; }

/* ============================ 页脚（深色，对齐文笔塔） ============================ */
.pt-footer { background: #061220; color: rgba(255, 255, 255, .68); margin-top: 0; }
.pt-footer-top { display: grid; grid-template-columns: 1fr; gap: 40px; padding-top: 64px; padding-bottom: 40px; }
@media (min-width: 900px) { .pt-footer-top { grid-template-columns: 1.1fr 2fr; gap: 64px; } }
.pt-footer-brand { display: flex; gap: 16px; align-items: flex-start; }
.pt-footer-brand img { width: 52px; height: 52px; object-fit: contain; }
.pt-footer-brand strong { display: block; font-family: var(--pt-serif); font-size: 22px; font-weight: 700; color: #fff; margin-bottom: 10px; }
.pt-footer-brand p { margin: 0; font-size: 14px; line-height: 1.9; }
.pt-footer-cols { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }
@media (min-width: 768px) { .pt-footer-cols { grid-template-columns: repeat(3, 1fr); } }
.pt-footer h3 { font-size: 15px; font-weight: 600; color: #fff; margin: 0 0 18px; }
.pt-footer ul { list-style: none; margin: 0; padding: 0; }
.pt-footer li { margin-bottom: 12px; }
.pt-footer a { color: rgba(255, 255, 255, .68); text-decoration: none; font-size: 14px; line-height: 1.7; }
.pt-footer a:hover { color: #fff; text-decoration: underline; }
.pt-footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .12); padding-top: 22px; padding-bottom: 30px;
  display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; font-size: 13px;
}
.pt-footer-bottom a { font-size: 13px; }

/* ============================ 响应式 ============================ */
@media (max-width: 1400px) {
  .pt-nav a { font-size: 15px; }
}
@media (max-width: 1180px) {
  .pt-nav { -webkit-overflow-scrolling: touch; }
  .pt-nav ul { gap: 18px; }
  .pt-nav a { padding: 30px 2px; font-size: 15px; }
  .pt-hero h1 { font-size: 46px; }
}
@media (max-width: 820px) {
  .pt-brand-copy small { display: none; }
  .pt-header-actions .pt-cta { display: none; }
  .pt-header-inner { min-height: 72px; gap: 14px; }
  .pt-nav a { padding: 24px 2px; font-size: 14px; }
  .pt-brand img { width: 44px; height: 44px; }
  .pt-brand-copy strong { font-size: 19px; }
  .pt-hero { padding: 52px 0 44px; }
  .pt-hero h1 { font-size: 34px; }
  .pt-hero-sub { font-size: 15px; }
  .pt-section { padding: 44px 0; }
  .pt-head h2 { font-size: 24px; }
  .pt-shell { padding-left: 20px; padding-right: 20px; }
  .pt-band-tel { text-align: left; }
  .pt-band .pt-tel { font-size: 26px; }
  .pt-topbar-notice { display: none; }
}
@media (max-width: 560px) {
  .pt-nav ul { gap: 14px; }
  .pt-nav a { padding: 20px 2px; font-size: 13px; }
  .pt-hero h1 { font-size: 28px; }
  .pt-stats strong { font-size: 26px; }
}

/* ==========================================================================
   内页（归档 / 分类 / 标签 / 文章 / 单页）样式对齐文笔塔 —— 由 .pt-page 作用域限定
   ========================================================================== */
.pt-page { margin-top: 48px !important; margin-bottom: 56px !important; }

/* 标题：衬线 + 藏青 */
.pt-page h1 {
  font-family: var(--pt-serif); font-size: 30px !important; font-weight: 700 !important;
  color: var(--pt-navy) !important; line-height: 1.35; margin-bottom: 24px !important;
}
.pt-page h2 { font-family: var(--pt-serif); color: var(--pt-navy); }
.pt-page .text-3xl, .pt-page .text-4xl, .pt-page a.text-xl {
  font-family: var(--pt-serif) !important; color: var(--pt-navy) !important;
}
.pt-page a.text-xl { font-size: 19px !important; font-weight: 700 !important; }
.pt-page a.text-xl:hover, .pt-page .text-3xl a:hover { color: var(--pt-accent) !important; }

/* 卡片：白底 + 1px #e8e8e8 + 圆角 12 */
.pt-page .rounded-xl { border-radius: var(--pt-radius) !important; }
.pt-page .bg-white { background-color: var(--pt-card) !important; }
.pt-page .border-gray-300 { border-color: var(--pt-line) !important; }
.pt-page .hover\:border-gray-400:hover { border-color: rgba(15, 43, 77, .35) !important; }
.pt-page .shadow-sm, .pt-page .shadow { box-shadow: 0 2px 10px rgba(15, 43, 77, .05) !important; }
.pt-page .hover\:shadow:hover, .pt-page .hover\:shadow-md:hover { box-shadow: 0 14px 32px rgba(15, 43, 77, .10) !important; }

/* 分类 / 标签链接 */
.pt-page a.text-sm { color: var(--pt-ink-3); }
.pt-page a.text-sm:hover { color: var(--pt-accent) !important; }

/* 正文 */
.pt-page article, .pt-page .markdown-body {
  font-size: 16px; line-height: 1.95; color: #374151;
}
.pt-page article h2, .pt-page article h3, .pt-page article h4,
.pt-page .markdown-body h2, .pt-page .markdown-body h3, .pt-page .markdown-body h4 {
  font-family: var(--pt-serif); color: var(--pt-navy); font-weight: 700;
}
.pt-page article h2, .pt-page .markdown-body h2 { border-bottom: 1px solid var(--pt-line); padding-bottom: 8px; }
.pt-page article a, .pt-page .markdown-body a { color: var(--pt-accent); }
.pt-page article blockquote, .pt-page .markdown-body blockquote {
  border-left: 3px solid var(--pt-accent); background: #fdf6f4; color: var(--pt-ink-2);
}
.pt-page table { border-collapse: collapse; width: 100%; font-size: 15px; }
.pt-page table th, .pt-page table td { border: 1px solid var(--pt-line); padding: 9px 12px; }
.pt-page table thead th {
  background: #f4f7fa; font-family: var(--pt-serif); color: var(--pt-navy); font-weight: 700;
}
.pt-page table tbody tr:nth-child(even) { background: #fafafa; }
.pt-page img { border-radius: 8px; }

/* 分页 */
.pt-page select, .pt-page .pagination { font-size: 14px; color: var(--pt-ink-2); }

/* 顶部导航固定后，内页的吸顶元素下移，避免被头部遮住 */
.pt-page .sticky.top-20 { top: 7.5rem !important; }

/* ==========================================================================
   升级补充（无障碍 + 列表页标题层级）
   ========================================================================== */

/* 跳转到主内容（键盘 / 读屏用户第一个可达元素，平时移出视口） */
.pt-skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 9999;
  background: var(--pt-navy);
  color: #fff;
  padding: 10px 18px;
  border-radius: 0 0 8px 0;
  font-size: 14px;
  text-decoration: none;
}
.pt-skip-link:focus {
  left: 0;
  outline: 3px solid var(--pt-accent);
  outline-offset: 2px;
}

/* 列表页（分类 / 标签 / 分类总览 / 标签索引）的一级标题 */
.pt-page-title {
  font-family: var(--pt-serif);
  font-size: 28px;
  line-height: 1.35;
  font-weight: 700;
  color: var(--pt-navy);
  margin: 0 0 18px;
  padding-left: 14px;
  border-left: 4px solid var(--pt-accent);
}
@media (max-width: 640px) {
  .pt-page-title { font-size: 22px; margin-bottom: 14px; }
}

/* 键盘可见焦点（统一描边，避免默认样式被 Tailwind 重置掉） */
.pt-header a:focus-visible,
.pt-footer a:focus-visible,
.pt-nav a:focus-visible,
.pt-page a:focus-visible,
.pt-page button:focus-visible {
  outline: 3px solid var(--pt-accent);
  outline-offset: 2px;
  border-radius: 4px;
}
