/* Hallmark · macrostructure: Editorial Desk · genre: modern-minimal
 * design-system: prototype/design.md · page: 刊物广场
 */

.ph-page {
  min-height: 100vh;
  background:
    linear-gradient(90deg, transparent 0, transparent calc(50% - 1px), rgba(0,103,255,0.035) 50%, transparent calc(50% + 1px)),
    var(--bg-page);
}

.ph-shell {
  max-width: 1480px;
  margin: 0 auto;
  padding: 24px 24px 68px;
}

.ph-masthead {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: end;
  padding: 12px 0 18px;
  border-bottom: 3px solid var(--text-title);
}

.ph-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  color: var(--brand);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
}

.ph-title {
  margin: 0;
  color: var(--text-title);
  font-family: "Songti SC", "STSong", "SimSun", serif;
  font-size: 46px;
  line-height: 1.08;
  letter-spacing: 0.12em;
}

.ph-subtitle {
  margin: 9px 0 0;
  color: var(--text-secondary);
  font-family: "Songti SC", "STSong", "SimSun", serif;
  font-size: 15px;
  line-height: 1.7;
}

.ph-masthead-side {
  min-width: 260px;
  text-align: right;
}

.ph-date {
  color: var(--text-title);
  font-size: 13px;
  font-weight: 700;
}

.ph-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 7px;
  color: var(--text-muted);
  font-size: 10px;
}

.ph-live i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 4px var(--green-light);
}

.ph-masthead-actions {
  display: flex;
  justify-content: flex-end;
  gap: 7px;
  margin-top: 12px;
}

.ph-column-nav {
  position: sticky;
  top: var(--nav-height);
  z-index: 35;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 9px 0;
  overflow-x: auto;
  border-bottom: 1px solid var(--border-light);
  background: rgba(243,245,249,0.96);
  backdrop-filter: blur(12px);
}

.ph-column-nav a {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 11px;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}

.ph-column-nav a:hover,
.ph-column-nav a.active {
  border-color: var(--brand-200);
  background: var(--brand-50);
  color: var(--brand);
}

.ph-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 18px;
  align-items: start;
  margin-top: 18px;
}

.ph-main { min-width: 0; }
.ph-rail {
  position: sticky;
  top: calc(var(--nav-height) + 58px);
  display: grid;
  gap: 12px;
}

.ph-lead {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.55fr);
  overflow: hidden;
  border: 1px solid var(--border-light);
  background: var(--white);
}

.ph-lead-main {
  padding: 24px;
  border-right: 1px solid var(--border-light);
}

.ph-lead-label,
.ph-section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--brand);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.ph-lead h2 {
  max-width: 860px;
  margin: 13px 0 10px;
  color: var(--text-title);
  font-family: "Songti SC", "STSong", "SimSun", serif;
  font-size: 29px;
  line-height: 1.42;
}

.ph-lead-copy {
  margin: 0;
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.85;
}

.ph-lead-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 15px;
}

.ph-lead-tags span {
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  background: var(--bg-page);
  color: var(--text-secondary);
  font-size: 10px;
}

.ph-lead-side {
  display: flex;
  flex-direction: column;
  padding: 22px;
  background: var(--brand-50);
}

.ph-lead-side h3 {
  margin: 0 0 12px;
  color: var(--text-title);
  font-size: 13px;
}

.ph-brief-item {
  padding: 10px 0;
  border-top: 1px dashed var(--border-default);
}

.ph-brief-item:first-of-type { border-top: 0; }
.ph-brief-item b { color: var(--text-title); font-size: 11px; }
.ph-brief-item p { margin: 4px 0 0; color: var(--text-secondary); font-size: 11px; line-height: 1.65; }
.ph-lead-side .btn { margin-top: auto; }

.ph-section { margin-top: 28px; scroll-margin-top: calc(var(--nav-height) + 72px); }
.ph-section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--text-title);
}

.ph-section-head h2 {
  margin: 4px 0 0;
  color: var(--text-title);
  font-size: 21px;
}

.ph-section-head p {
  max-width: 700px;
  margin: 4px 0 0;
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.6;
}

.ph-section-link {
  color: var(--brand);
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.ph-publication {
  display: grid;
  grid-template-columns: minmax(230px, 0.85fr) minmax(280px, 1.15fr) 140px;
  gap: 18px;
  align-items: center;
  padding: 18px 0;
  border-bottom: 1px solid var(--border-light);
}

.ph-publication:last-child { border-bottom: 0; }
.ph-publication-name {
  font-family: "Songti SC", "STSong", "SimSun", serif;
  color: var(--text-title);
  font-size: 24px;
  font-weight: 700;
}

.ph-publication-en {
  margin-top: 3px;
  color: var(--text-muted);
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.ph-publication-meta b {
  display: block;
  color: var(--text-title);
  font-size: 12px;
}

.ph-publication-meta p {
  margin: 5px 0 0;
  color: var(--text-secondary);
  font-size: 11px;
  line-height: 1.65;
}

.ph-publication-enter {
  text-align: right;
}

.ph-status {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  font-size: 9px;
  font-weight: 700;
}

.ph-status.live { background: var(--brand-100); color: var(--brand); }
.ph-status.pending { background: var(--bg-page); color: var(--text-muted); }

.ph-enter-link {
  display: block;
  margin-top: 10px;
  color: var(--brand);
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
}

.ph-policy-lead {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
  gap: 0;
  margin-top: 14px;
  border: 1px solid var(--border-light);
  background: var(--white);
}

.ph-policy-copy {
  padding: 20px;
  border-right: 1px solid var(--border-light);
}

.ph-policy-copy h3 {
  margin: 9px 0 8px;
  color: var(--text-title);
  font-size: 20px;
  line-height: 1.5;
}

.ph-policy-copy p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 12px;
  line-height: 1.8;
}

.ph-impact-chain {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 15px;
}

.ph-impact-chain span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 8px;
  border-radius: 5px;
  background: var(--bg-page);
  color: var(--text-body);
  font-size: 10px;
}

.ph-policy-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ph-policy-fact {
  padding: 16px;
  border-right: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

.ph-policy-fact:nth-child(2n) { border-right: 0; }
.ph-policy-fact:nth-last-child(-n+2) { border-bottom: 0; }
.ph-policy-fact span { color: var(--text-muted); font-size: 10px; }
.ph-policy-fact b { display: block; margin-top: 6px; color: var(--text-title); font-size: 12px; line-height: 1.5; }

.ph-overseas-grid {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 14px;
  margin-top: 14px;
}

.ph-region-rail {
  display: grid;
  gap: 6px;
  align-content: start;
}

.ph-region {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 11px;
  border: 1px solid var(--border-light);
  border-radius: 7px;
  background: var(--white);
  color: var(--text-secondary);
  font-size: 11px;
  cursor: pointer;
}

.ph-region:hover,
.ph-region.active {
  border-color: var(--brand);
  background: var(--brand-50);
  color: var(--brand);
}

.ph-region em { font-size: 9px; font-style: normal; }

.ph-overseas-list {
  border-top: 1px solid var(--text-title);
}

.ph-overseas-item {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr) 76px;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--border-light);
}

.ph-overseas-item time { color: var(--text-muted); font-size: 10px; }
.ph-overseas-item b { display: block; color: var(--text-title); font-size: 12px; line-height: 1.5; }
.ph-overseas-item p { margin: 5px 0 0; color: var(--text-secondary); font-size: 11px; line-height: 1.65; }
.ph-risk { justify-self: end; padding: 3px 8px; border-radius: var(--radius-pill); font-size: 9px; font-weight: 700; white-space: nowrap; }
.ph-risk.high { background: var(--red-light); color: var(--accent-red); }
.ph-risk.medium { background: var(--orange-light); color: var(--accent-orange); }
.ph-risk.watch { background: var(--brand-50); color: var(--brand); }

.ph-intel-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 13px;
  flex-wrap: wrap;
}

.ph-filter-tabs {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}

.ph-filter-tabs button {
  padding: 5px 9px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  background: var(--white);
  color: var(--text-secondary);
  font-size: 10px;
  cursor: pointer;
}

.ph-filter-tabs button.active,
.ph-filter-tabs button:hover {
  border-color: var(--brand);
  background: var(--brand-50);
  color: var(--brand);
}

.ph-feed {
  margin-top: 12px;
  border-top: 1px solid var(--text-title);
}

.ph-feed-item {
  display: grid;
  grid-template-columns: 74px 72px minmax(0, 1fr) 86px;
  gap: 10px;
  align-items: start;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-light);
}

.ph-feed-time { color: var(--text-muted); font-size: 10px; }
.ph-feed-type {
  display: inline-flex;
  justify-content: center;
  padding: 3px 6px;
  border-radius: 5px;
  background: var(--bg-page);
  color: var(--text-secondary);
  font-size: 9px;
}

.ph-feed-item b { display: block; color: var(--text-title); font-size: 11px; line-height: 1.5; }
.ph-feed-item p { margin: 4px 0 0; color: var(--text-secondary); font-size: 10px; line-height: 1.6; }
.ph-feed-source { color: var(--text-muted); font-size: 9px; text-align: right; }

.ph-rail .ph-feed-item {
  grid-template-columns: minmax(0, 1fr);
  gap: 5px;
}

.ph-rail .ph-feed-time,
.ph-rail .ph-feed-type,
.ph-rail .ph-feed-source {
  grid-row: auto;
  justify-self: start;
  text-align: left;
}

.ph-rail-panel {
  padding: 13px;
  border: 1px solid var(--border-light);
  background: var(--white);
}

.ph-rail-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
  color: var(--text-title);
  font-size: 12px;
  font-weight: 700;
}

.ph-calendar {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 9px;
  padding: 8px 0;
  border-top: 1px solid var(--border-light);
}

.ph-calendar:first-of-type { border-top: 0; }
.ph-calendar-date { color: var(--brand); font-size: 11px; font-weight: 700; }
.ph-calendar b { display: block; color: var(--text-title); font-size: 11px; }
.ph-calendar span { display: block; margin-top: 3px; color: var(--text-muted); font-size: 9px; }

.ph-subscribe-list { display: grid; gap: 8px; }
.ph-subscribe {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--text-secondary);
  font-size: 11px;
}

.ph-toggle {
  width: 32px;
  height: 18px;
  padding: 2px;
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--border-default);
  cursor: pointer;
}

.ph-toggle::after {
  content: '';
  display: block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--white);
  transition: transform 150ms var(--ease-out);
}

.ph-toggle.on { background: var(--brand); }
.ph-toggle.on::after { transform: translateX(14px); }

.ph-toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 1200;
  padding: 9px 16px;
  border-radius: var(--radius-pill);
  background: var(--text-title);
  color: var(--white);
  font-size: 11px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 8px);
  transition: opacity 150ms var(--ease-out), transform 150ms var(--ease-out);
}

.ph-toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 1100px) {
  .ph-layout { grid-template-columns: minmax(0, 1fr); }
  .ph-rail { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ph-lead { grid-template-columns: minmax(0, 1fr); }
  .ph-lead-main { border-right: 0; border-bottom: 1px solid var(--border-light); }
}

@media (max-width: 760px) {
  .ph-shell { padding: 16px 14px 50px; }
  .ph-masthead { grid-template-columns: minmax(0, 1fr); }
  .ph-masthead-side { text-align: left; }
  .ph-masthead-actions { justify-content: flex-start; }
  .ph-title { font-size: 34px; }
  .ph-publication { grid-template-columns: minmax(0, 1fr); gap: 9px; }
  .ph-publication-enter { text-align: left; }
  .ph-policy-lead,
  .ph-overseas-grid { grid-template-columns: minmax(0, 1fr); }
  .ph-policy-copy { border-right: 0; border-bottom: 1px solid var(--border-light); }
  .ph-rail { grid-template-columns: minmax(0, 1fr); }
  .ph-feed-item { grid-template-columns: 62px minmax(0, 1fr); }
  .ph-feed-type, .ph-feed-source { grid-row: 2; }
  .ph-feed-source { text-align: left; }
}

/* Publication modules switch in place instead of stacking every column. */
.ph-shell {
  padding: 14px 24px 40px;
}

.ph-masthead {
  gap: 18px;
  padding: 8px 0 14px;
}

.ph-column-nav {
  position: sticky;
  top: calc(var(--nav-height) + 44px);
  z-index: 32;
  margin: 0 -8px;
  padding: 7px 8px;
  background: rgba(243, 245, 249, 0.96);
  backdrop-filter: blur(12px);
}

.ph-column-nav a {
  min-height: 32px;
  padding: 0 11px;
  border: 1px solid transparent;
}

.ph-column-nav a.active {
  border-color: var(--brand-200);
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.ph-layout {
  margin-top: 12px;
}

.ph-section {
  margin-top: 0;
}

[data-ph-panel][hidden] {
  display: none !important;
}

[data-ph-panel]:not([hidden]) {
  animation: ph-module-in 180ms var(--ease-out) both;
}

@keyframes ph-module-in {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  [data-ph-panel]:not([hidden]) { animation: none; }
}
