:root {
  --brand-red: #9f1c33;
  --brand-red-dark: #7c1527;
  --navy: #16213f;
  --text-dark: #2b2b2b;
  --gray-bg: #f4f4f5;
  --border-light: #e6e6e8;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text-dark);
  background: #e8e8ea;
}

.page {
  max-width: 1100px;
  margin: 0 auto;
  background: #fff;
  min-height: 100vh;
  box-shadow: 0 0 24px rgba(0,0,0,0.08);
}

/* ---- 顶部导航菜单 ---- */
.top-nav {
  background: #fff;
  border-bottom: 1px solid var(--border-light);
}
.top-nav-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 14px 24px;
  overflow-x: auto;
  white-space: nowrap;
}
.top-nav-link {
  color: #555;
  font-size: 13.5px;
  text-decoration: none;
  flex: 0 0 auto;
}
.top-nav-link:hover { color: var(--brand-red); }
.top-nav-link.active { color: var(--brand-red); font-weight: 700; }

/* ---- header ---- */
.header {
  background: var(--brand-red);
  color: #fff;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.header .brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.header .brand img { height: 42px; display: block; }
.header .brand-text .cn { font-size: 18px; font-weight: 700; line-height: 1.3; }
.header .brand-text .en { font-size: 11px; letter-spacing: 1px; opacity: 0.9; }
.header .brand-text .sub { font-size: 10px; opacity: 0.85; margin-top: 2px; }
.header .doc-title { text-align: right; }
.header .doc-title .cn { font-size: 20px; font-weight: 700; }
.header .doc-title .en { font-size: 11px; opacity: 0.9; }
.header .doc-title .date { font-size: 11px; opacity: 0.9; margin-top: 4px; }

/* ---- 右侧功能区：搜索 / 历史报价日历 / 广告位 ---- */
.body-layout {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  padding: 0 24px;
}
.main-col { flex: 1 1 auto; min-width: 0; }
.main-col .content { padding: 24px 0; }
.side-col {
  flex: 0 0 300px;
  width: 300px;
  padding: 0 0 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.side-search {
  background: var(--navy);
  border-radius: 12px;
  padding: 18px 16px;
  color: #fff;
}
.side-search h3 { margin: 0 0 4px; font-size: 16px; color: #fff; }
.side-search p { margin: 0 0 14px; font-size: 11px; opacity: 0.85; line-height: 1.5; }
.side-search .search-input-wrap {
  background: #fff;
  border-radius: 8px;
  padding: 9px 12px;
  margin-bottom: 8px;
}
.side-search input[type="text"] {
  width: 100%;
  border: none;
  outline: none;
  font-size: 13px;
  color: #333;
  background: transparent;
  font-family: inherit;
}
.side-search .search-error { color: #ffd3d3; font-size: 11px; margin-bottom: 8px; }
.side-search button[type="submit"] {
  width: 100%;
  background: var(--brand-red);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 11px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  font-family: inherit;
}
.side-search button[type="submit"]:hover { background: var(--brand-red-dark); }
.side-search .hint { font-size: 10px; opacity: 0.6; margin-top: 10px; text-align: center; }

.cal-panel {
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: 12px;
  padding: 14px 16px 10px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}
.cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.cal-nav {
  background: none;
  border: none;
  color: var(--brand-red);
  font-size: 16px;
  cursor: pointer;
  padding: 2px 10px;
  line-height: 1;
}
.cal-title { font-weight: 700; color: #333; font-size: 14px; }
.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  font-size: 11px;
  color: #999;
  margin-bottom: 6px;
}
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.cal-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 30px;
  border-radius: 6px;
  font-size: 12.5px;
  text-decoration: none;
  color: #ccc;
}
.cal-empty { visibility: hidden; }
.cal-no-report { color: #c7c7c9; }
a.cal-has-report {
  color: var(--brand-red);
  font-weight: 700;
  background: #fdeef0;
}
a.cal-has-report:hover { background: var(--brand-red); color: #fff; }

/* ---- content ---- */
.intro { font-size: 15px; line-height: 1.7; margin: 0 0 28px; }
.intro b { color: var(--brand-red); }

.section-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--brand-red);
  letter-spacing: 1px;
  margin: 0 0 14px;
  padding-left: 10px;
  border-left: 4px solid var(--brand-red);
}

/* ---- daily picks ---- */
.picks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}
.pick-card {
  border: 1px solid var(--border-light);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.pick-card .pick-head {
  background: var(--brand-red);
  color: #fff;
  text-align: center;
  font-weight: 700;
  font-size: 15px;
  padding: 10px 8px;
}
.pick-card .pick-stocks {
  padding: 18px 12px;
  text-align: center;
  font-size: 13.5px;
  line-height: 1.9;
  flex-grow: 1;
}
.pick-card .pick-foot {
  background: var(--gray-bg);
  padding: 14px 12px 12px;
  text-align: center;
}
.pick-card .coupon-label { font-size: 11px; color: #777; }
.pick-card .coupon-value { font-size: 26px; font-weight: 800; color: var(--brand-red); margin: 2px 0 10px; }
.pick-card .tenor-row {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid #e0e0e2;
  padding-top: 8px;
  font-size: 12px;
}
.pick-card .tenor-row .tenor-label { color: #777; }
.pick-card .tenor-row .tenor-value { font-weight: 700; }

/* ---- common terms ---- */
.terms-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 32px;
  font-size: 13px;
}
.terms-table td {
  padding: 12px 14px;
  border: 1px solid var(--border-light);
  width: 25%;
}
.terms-table tr:nth-child(even) { background: var(--gray-bg); }
.terms-table .t-label { color: #444; font-weight: 600; }
.terms-table .t-value { font-weight: 700; }
.terms-table .t-value.highlight { color: var(--brand-red); }

/* ---- features ---- */
.features-list { list-style: none; margin: 0 0 28px; padding: 0; }
.features-list li {
  position: relative;
  padding: 0 0 0 20px;
  margin-bottom: 12px;
  font-size: 13.5px;
  line-height: 1.7;
}
.features-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 8px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--brand-red);
}

.disclaimer {
  font-size: 11.5px;
  color: #888;
  line-height: 1.8;
  border-top: 1px solid var(--border-light);
  padding-top: 16px;
}

/* ---- footer ---- */
.footer {
  background: var(--navy);
  color: #fff;
  padding: 22px 24px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 16px;
}
.footer .contact-title { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.footer .footer-note, .footer .footer-publisher { font-size: 11px; opacity: 0.75; max-width: 420px; line-height: 1.6; }
.footer .qr-group { display: flex; gap: 14px; flex-wrap: wrap; }
.footer .qr-item { text-align: center; font-size: 10px; width: 100px; }
.footer .qr-item img {
  width: 100px; height: 100px; object-fit: cover;
  background: #fff; border-radius: 6px; margin-bottom: 4px;
  display: block;
}
.footer .qr-item .qr-placeholder {
  width: 100px; height: 100px; background: rgba(255,255,255,0.15);
  border-radius: 6px; margin-bottom: 4px;
}

.empty-state {
  padding: 60px 24px;
  text-align: center;
  color: #888;
}

/* ---- 侧栏广告位（300x630） ---- */
.side-ad { text-align: center; }
.side-ad a { display: block; }
.side-ad img {
  width: 100%;
  max-width: 300px;
  height: auto;
  border-radius: 10px;
  display: block;
  margin: 0 auto;
}

/* ---- 搜索结果页 ---- */
.search-results { display: flex; flex-direction: column; gap: 12px; margin-bottom: 28px; }
.search-result-item {
  display: block;
  border: 1px solid var(--border-light);
  border-radius: 10px;
  padding: 14px 16px;
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.15s, border-color 0.15s;
}
.search-result-item:hover { border-color: var(--brand-red); box-shadow: 0 2px 10px rgba(159,28,51,0.12); }
.sr-date { font-weight: 700; color: var(--brand-red); margin-bottom: 4px; font-size: 14px; }
.sr-intro { font-size: 12.5px; color: #666; margin-bottom: 8px; line-height: 1.6; }
.sr-matches { display: flex; flex-wrap: wrap; gap: 6px; }
.sr-match-tag {
  background: var(--gray-bg);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 11.5px;
  color: #444;
}

@media (max-width: 480px) {
  .header { flex-direction: column; align-items: flex-start; }
  .header .doc-title { text-align: left; }
  .footer { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 860px) {
  .body-layout { flex-direction: column; padding: 0 16px; }
  .main-col .content { padding: 20px 0; }
  .side-col { flex: 1 1 auto; width: 100%; padding: 0 0 20px; }
  .side-ad, .side-ad img { max-width: 300px; margin: 0 auto; }
}
