:root {
  --navy-950: #071a33;
  --navy-900: #0c2340;
  --navy-800: #163554;
  --navy-600: #47627d;
  --navy-400: #7f92a6;
  --blue: #1e62d0;
  --blue-soft: #eaf2ff;
  --canvas: #f4f7fb;
  --surface: #ffffff;
  --line: #e5ebf2;
  --shadow: 0 10px 32px rgba(21, 45, 75, 0.07);
  --low: #1f9d74;
  --medium: #c88918;
  --high: #df6a3e;
  --critical: #c53b51;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--canvas);
  color: var(--navy-900);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans Thai",
    "Leelawadee UI", Tahoma, sans-serif;
  -webkit-font-smoothing: antialiased;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

[hidden] {
  display: none !important;
}

.app-shell {
  width: 100%;
  max-width: 480px;
  min-height: 100vh;
  margin: 0 auto;
  background: #f9fbfd;
  box-shadow: 0 0 50px rgba(18, 43, 72, 0.08);
}

.topbar {
  position: sticky;
  z-index: 20;
  top: 0;
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  align-items: center;
  min-height: 76px;
  padding: max(12px, env(safe-area-inset-top)) 18px 10px;
  border-bottom: 1px solid rgba(224, 231, 239, 0.8);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
}

.brand {
  text-align: center;
}

.brand-title,
.brand-subtitle,
.section-kicker {
  margin: 0;
}

.brand-title {
  color: var(--navy-950);
  font-size: 16px;
  font-weight: 750;
  letter-spacing: -0.25px;
}

.brand-subtitle {
  margin-top: 3px;
  color: var(--navy-400);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 2.2px;
}

.icon-button {
  position: relative;
  display: grid;
  width: 40px;
  height: 40px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--navy-900);
  cursor: pointer;
}

.icon-button:hover {
  background: #f2f5f9;
}

.icon-button svg,
.bottom-nav svg,
.watchpoint-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

main {
  padding-bottom: 110px;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 29px 22px 25px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 98% 0%, rgba(38, 105, 211, 0.11), transparent 38%),
    linear-gradient(145deg, #ffffff 20%, #f5f9ff 100%);
}

.hero::after {
  position: absolute;
  top: -50px;
  right: -64px;
  width: 165px;
  height: 165px;
  border: 1px solid rgba(30, 98, 208, 0.08);
  border-radius: 50%;
  content: "";
}

.hero-meta,
.hero-footer,
.section-heading,
.risk-main,
.risk-signal,
.headline-meta,
.headline-risk {
  display: flex;
  align-items: center;
}

.hero-meta {
  gap: 10px;
}

.eyebrow {
  padding: 5px 9px;
  border-radius: 7px;
  background: var(--navy-900);
  color: white;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: 0.4px;
}

#report-date {
  color: var(--navy-600);
  font-size: 12px;
  font-weight: 600;
}

.hero h1 {
  max-width: 330px;
  margin: 16px 0 9px;
  color: var(--navy-950);
  font-size: clamp(27px, 7vw, 34px);
  line-height: 1.08;
  letter-spacing: -1.2px;
}

.executive-summary {
  max-width: 405px;
  margin: 0;
  color: #405b75;
  font-size: 14px;
  line-height: 1.75;
}

.hero-footer {
  justify-content: space-between;
  margin-top: 19px;
  padding-top: 15px;
  border-top: 1px solid rgba(218, 227, 237, 0.9);
  color: var(--navy-400);
  font-size: 10px;
  font-weight: 650;
}

.status-indicator i {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 6px;
  border-radius: 50%;
  background: #26a876;
  box-shadow: 0 0 0 4px rgba(38, 168, 118, 0.1);
}

.content-section {
  padding: 28px 18px 0;
}

.section-heading {
  justify-content: space-between;
  margin: 0 4px 15px;
}

.section-kicker {
  margin-bottom: 4px;
  color: var(--blue);
  font-size: 8px;
  font-weight: 850;
  letter-spacing: 1.7px;
}

.section-heading h2,
.watchpoint-card h2 {
  margin: 0;
  color: var(--navy-950);
  font-size: 20px;
  letter-spacing: -0.4px;
}

.section-note {
  color: var(--navy-400);
  font-size: 11px;
  font-weight: 600;
}

.risk-list,
.headline-list {
  overflow: hidden;
  margin: 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.risk-row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 10px;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: 78px;
  padding: 12px 14px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  transition: background-color 160ms ease;
}

.risk-row:hover,
.risk-row:focus-visible {
  background: #f8fbff;
}

.risk-row:focus-visible {
  z-index: 1;
  outline: 2px solid rgba(30, 98, 208, 0.35);
  outline-offset: -2px;
}

.risk-row:last-child,
.headline-item:last-child {
  border-bottom: 0;
}

.risk-main {
  min-width: 0;
  gap: 12px;
}

.category-icon {
  display: grid;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 13px;
  background: var(--icon-bg, #edf3fb);
  color: var(--icon-color, var(--blue));
  font-size: 19px;
  font-weight: 750;
}

.category-icon svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.category-copy {
  min-width: 0;
}

.category-name {
  overflow: hidden;
  margin: 0 0 4px;
  color: var(--navy-900);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.25;
  text-overflow: ellipsis;
}

.category-subtitle {
  overflow: hidden;
  margin: 0;
  color: var(--navy-400);
  font-size: 10.5px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.risk-signal {
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.row-chevron {
  color: #b4c0cd;
  font-size: 22px;
  font-weight: 300;
  line-height: 1;
}

.direction {
  color: var(--navy-400);
  font-size: 9px;
  font-weight: 700;
}

.direction::before {
  display: inline-block;
  margin-right: 4px;
  color: currentColor;
}

.direction-rising {
  color: #c55342;
}

.direction-rising::before {
  content: "↗";
}

.direction-stable::before {
  content: "→";
}

.direction-easing {
  color: var(--low);
}

.direction-easing::before {
  content: "↘";
}

.direction-unknown::before {
  content: "•";
}

.risk-badge {
  display: inline-flex;
  min-width: 62px;
  justify-content: center;
  padding: 5px 9px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.2px;
}

.risk-low {
  border-color: #caebdf;
  background: #edf9f4;
  color: var(--low);
}

.risk-medium {
  border-color: #f0dfb8;
  background: #fff8e9;
  color: #a96f09;
}

.risk-high {
  border-color: #f5d4c6;
  background: #fff2ed;
  color: var(--high);
}

.risk-critical {
  border-color: #f0c6cd;
  background: #fff0f3;
  color: var(--critical);
}

.count-pill {
  display: grid;
  min-width: 28px;
  height: 28px;
  padding: 0 8px;
  place-items: center;
  border-radius: 9px;
  background: var(--blue-soft);
  color: var(--blue);
  font-size: 11px;
  font-weight: 800;
}

.headline-list {
  list-style: none;
}

.headline-item {
  display: grid;
  grid-template-columns: 31px minmax(0, 1fr);
  gap: 11px;
  padding: 17px 15px 16px;
  border-bottom: 1px solid var(--line);
}

.headline-rank {
  color: #bdc8d5;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
}

.headline-title {
  margin: 0;
  color: var(--navy-900);
  font-size: 13.5px;
  font-weight: 700;
  line-height: 1.52;
}

.headline-meta {
  justify-content: space-between;
  gap: 8px;
  margin-top: 10px;
}

.category-tag {
  overflow: hidden;
  color: var(--blue);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.2px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.headline-risk {
  flex: 0 0 auto;
  gap: 5px;
  color: var(--navy-400);
  font-size: 9px;
  font-weight: 700;
}

.risk-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.text-low {
  color: var(--low);
}

.text-medium {
  color: #b77b11;
}

.text-high {
  color: var(--high);
}

.text-critical {
  color: var(--critical);
}

.watchpoint-section {
  padding-bottom: 8px;
}

.watchpoint-card {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 14px;
  padding: 20px 18px;
  border: 1px solid #d9e5f5;
  border-radius: 19px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(236, 244, 255, 0.96));
  box-shadow: 0 12px 30px rgba(30, 80, 145, 0.09);
}

.watchpoint-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 14px;
  background: var(--navy-900);
  color: white;
}

.watchpoint-icon svg {
  width: 21px;
  height: 21px;
}

.watchpoint-card h2 {
  font-size: 18px;
}

#watchpoint-text {
  margin: 8px 0 0;
  color: #49647d;
  font-size: 12.5px;
  line-height: 1.65;
}

.loading-card,
.error-message {
  padding: 20px;
  color: var(--navy-400);
  font-size: 12px;
  text-align: center;
}

.error-message {
  margin: 18px;
  border: 1px solid #f0c6cd;
  border-radius: 14px;
  background: #fff5f6;
  color: var(--critical);
}

.bottom-nav {
  position: fixed;
  z-index: 30;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  width: 100%;
  max-width: 480px;
  min-height: 72px;
  margin: 0 auto;
  padding: 8px 8px max(8px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 -10px 30px rgba(22, 49, 78, 0.05);
  backdrop-filter: blur(18px);
}

.detail-open .bottom-nav {
  display: none;
}

.detail-open main {
  padding-bottom: 38px;
}

.category-view {
  min-height: calc(100vh - 76px);
  background: #f8fafc;
}

.detail-toolbar {
  padding: 16px 18px 0;
  background: white;
}

.back-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 10px 0 4px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--navy-600);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.back-button:hover,
.back-button:focus-visible {
  background: #f1f5f9;
  color: var(--navy-900);
}

.back-button svg,
.source-link svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.category-hero {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 14px;
  padding: 20px 22px 26px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 100% 0%, rgba(30, 98, 208, 0.1), transparent 42%),
    white;
}

.category-hero .category-icon {
  width: 52px;
  height: 52px;
  border-radius: 16px;
}

.category-hero .category-icon svg {
  width: 25px;
  height: 25px;
}

.category-hero-copy {
  min-width: 0;
}

.category-hero h1 {
  margin: 2px 0 6px;
  color: var(--navy-950);
  font-size: 24px;
  line-height: 1.2;
  letter-spacing: -0.7px;
}

.category-hero-copy > p:last-child {
  margin: 0;
  color: var(--navy-600);
  font-size: 12px;
  line-height: 1.55;
}

.category-detail-risk {
  display: flex;
  grid-column: 1 / -1;
  align-items: center;
  gap: 8px;
  padding-left: 66px;
}

.category-detail-risk .direction {
  font-size: 10px;
}

.detail-news-section {
  padding: 28px 18px 0;
}

.detail-news-section .section-heading {
  align-items: flex-end;
}

.detail-news-section .section-heading h2 {
  font-size: 19px;
}

.category-news-list {
  display: grid;
  gap: 14px;
}

.category-news-card,
.empty-news-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: white;
  box-shadow: var(--shadow);
}

.category-news-card {
  padding: 17px 16px;
}

.news-card-topline,
.news-card-risk,
.news-card-footer,
.source-link {
  display: flex;
  align-items: center;
}

.news-card-topline {
  justify-content: space-between;
  gap: 10px;
}

.news-card-topline time {
  color: var(--navy-400);
  font-size: 10px;
  font-weight: 700;
}

.news-card-risk {
  gap: 7px;
}

.news-card-risk .risk-badge {
  min-width: 56px;
}

.category-news-card h3 {
  margin: 15px 0 8px;
  color: var(--navy-950);
  font-size: 15px;
  line-height: 1.5;
  letter-spacing: -0.15px;
}

.news-detail {
  margin: 0;
  color: var(--navy-600);
  font-size: 12px;
  line-height: 1.7;
}

.news-watchpoint {
  margin-top: 15px;
  padding: 12px 13px;
  border-left: 3px solid var(--blue);
  border-radius: 4px 11px 11px 4px;
  background: #f2f7ff;
}

.news-watchpoint span,
.news-source span {
  display: block;
  color: var(--blue);
  font-size: 7.5px;
  font-weight: 850;
  letter-spacing: 1.3px;
}

.news-watchpoint p {
  margin: 5px 0 0;
  color: #3e5973;
  font-size: 11px;
  line-height: 1.6;
}

.news-card-footer {
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.news-source {
  min-width: 0;
}

.news-source span {
  color: var(--navy-400);
}

.news-source strong {
  display: block;
  overflow: hidden;
  margin-top: 4px;
  color: var(--navy-900);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.source-link {
  flex: 0 0 auto;
  gap: 5px;
  min-height: 34px;
  padding: 0 10px;
  border-radius: 10px;
  background: var(--navy-900);
  color: white;
  font-size: 9px;
  font-weight: 750;
  text-decoration: none;
}

.source-link svg {
  width: 14px;
  height: 14px;
}

.empty-news-card {
  padding: 34px 20px;
  color: var(--navy-400);
  font-size: 12px;
  text-align: center;
}

.nav-item {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  border-radius: 12px;
  color: #8b9bac;
  font-size: 8.5px;
  font-weight: 650;
  text-decoration: none;
}

.nav-item svg {
  width: 20px;
  height: 20px;
  stroke-width: 1.7;
}

.nav-item.active {
  color: var(--blue);
}

.nav-item.active svg {
  fill: rgba(30, 98, 208, 0.08);
  stroke-width: 2;
}

@media (min-width: 481px) {
  body {
    padding: 24px 0;
  }

  .app-shell {
    min-height: calc(100vh - 48px);
    overflow: hidden;
    border: 1px solid #e1e7ee;
    border-radius: 28px;
  }

  .topbar {
    top: 24px;
  }

  .bottom-nav {
    bottom: 24px;
    border: 1px solid var(--line);
    border-radius: 0 0 28px 28px;
  }
}

@media (max-width: 355px) {
  .risk-row {
    padding-right: 10px;
    padding-left: 10px;
  }

  .category-icon {
    width: 38px;
    height: 38px;
  }

  .risk-badge {
    min-width: 55px;
    padding-right: 7px;
    padding-left: 7px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

/* Demo-aligned homepage presentation */
body {
  background: #eef1f5;
}

.app-shell {
  background: #fff;
}

.topbar {
  min-height: 88px;
  padding: max(18px, env(safe-area-inset-top)) 22px 14px;
}

.brand-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
}

.brand-subtitle {
  font-size: 9px;
}

main {
  padding-bottom: 104px;
}

.hero {
  padding: 34px 24px 18px;
  border-bottom: 0;
  background: #fff;
}

.hero::after {
  display: none;
}

#report-date {
  display: block;
  color: #334b7b;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.7px;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 400px;
  margin: 12px 0;
  font-size: clamp(29px, 8vw, 36px);
}

.executive-summary {
  color: #536478;
  font-size: 13px;
  line-height: 1.65;
}

.content-section {
  padding: 25px 20px 0;
}

.section-heading {
  margin: 0 3px 12px;
}

.section-heading h2,
.watchpoint-card h2 {
  font-size: 15px;
  letter-spacing: 0.35px;
  text-transform: uppercase;
}

.section-note {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 10px;
}

.section-note svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.section-link {
  color: var(--navy-600);
  font-size: 11px;
  font-weight: 600;
}

.risk-list,
.headline-list {
  border-radius: 16px;
  box-shadow: 0 7px 24px rgba(21, 45, 75, 0.055);
}

.risk-row {
  grid-template-columns: minmax(0, 1.3fr) minmax(94px, 0.82fr) auto;
  min-height: 88px;
  padding: 13px;
}

.category-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
}

.category-name {
  overflow: visible;
  font-size: 13.5px;
  text-overflow: clip;
}

.category-subtitle {
  display: -webkit-box;
  overflow: hidden;
  font-size: 10px;
  line-height: 1.3;
  white-space: normal;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.risk-signal {
  align-items: flex-start;
  gap: 2px;
}

.direction {
  font-size: 9.5px;
  white-space: nowrap;
}

.direction::before {
  margin-right: 5px;
  font-size: 19px;
  font-weight: 400;
  vertical-align: -2px;
}

.direction-unknown::before {
  content: "−";
}

.direction-stable::before {
  content: "−";
}

.direction-easing::before {
  content: "↓";
}

.direction-note {
  padding-left: 24px;
  color: var(--navy-400);
  font-size: 8.5px;
  font-weight: 550;
}

.risk-level-cell {
  display: flex;
  justify-content: flex-end;
}

.risk-badge {
  min-width: 57px;
}

.headline-item {
  grid-template-columns: 27px minmax(0, 1fr) 12px;
  align-items: center;
  gap: 11px;
  padding: 15px 14px;
}

.headline-rank {
  display: grid;
  width: 25px;
  height: 27px;
  place-items: center;
  border-radius: 6px;
  background: #eaf1ff;
  color: var(--navy-900);
  font-family: inherit;
  font-size: 11px;
  font-weight: 800;
}

.headline-item:first-child .headline-rank,
.headline-item:nth-child(2) .headline-rank {
  background: #ffe4e8;
}

.headline-title {
  font-size: 13px;
}

.headline-meta {
  justify-content: flex-start;
  margin-top: 7px;
}

.headline-risk {
  gap: 0;
  padding-left: 8px;
  border-left: 1px solid #ccd5df;
}

.headline-chevron,
.card-chevron {
  color: #aab6c3;
  font-size: 24px;
  font-weight: 300;
  line-height: 1;
}

.watchpoint-section {
  padding-top: 18px;
  padding-bottom: 8px;
}

.watchpoint-card {
  grid-template-columns: 48px minmax(0, 1fr) 12px;
  align-items: center;
  padding: 18px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 7px 24px rgba(21, 45, 75, 0.055);
}

.watchpoint-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #fff0f2;
  color: #dc4055;
}

.watchpoint-card .section-kicker {
  margin-bottom: 0;
  color: #d43950;
  font-size: 9px;
  letter-spacing: 0.3px;
}

.watchpoint-card h2 {
  display: none;
}

#watchpoint-text {
  margin: 4px 0 0;
  color: var(--navy-900);
  font-size: 12.5px;
  font-weight: 650;
  line-height: 1.55;
}

.bottom-nav {
  grid-template-columns: repeat(4, 1fr);
  min-height: 78px;
}

.nav-item {
  font-size: 9px;
}

.nav-item svg {
  width: 22px;
  height: 22px;
}

@media (max-width: 370px) {
  .risk-row {
    grid-template-columns: minmax(0, 1.25fr) minmax(86px, 0.75fr) auto;
  }

  .category-icon {
    width: 43px;
    height: 43px;
  }

  .direction {
    font-size: 8.5px;
  }
}

/* News navigation and briefing article views */
.section-link {
  padding: 4px 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.section-link:hover,
.section-link:focus-visible {
  color: var(--blue);
}

.headline-item {
  cursor: pointer;
}

.headline-item:hover,
.headline-item:focus-visible {
  background: #f8fbff;
}

.headline-item:focus-visible,
.category-news-card:focus-visible,
.today-headline-card:focus-visible {
  outline: 2px solid rgba(30, 98, 208, 0.32);
  outline-offset: -2px;
}

.category-news-card {
  display: block;
  width: 100%;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition:
    border-color 160ms ease,
    transform 160ms ease,
    box-shadow 160ms ease;
}

.category-news-card:hover {
  border-color: #d4dfec;
  box-shadow: 0 13px 34px rgba(21, 45, 75, 0.1);
  transform: translateY(-1px);
}

.news-card-open {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 15px;
  color: var(--blue);
  font-size: 10px;
  font-weight: 750;
}

.subpage-view {
  min-height: calc(100vh - 88px);
  background: #f8fafc;
}

.subpage-header {
  padding: 24px 22px 27px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 100% 0%, rgba(30, 98, 208, 0.08), transparent 42%),
    #fff;
}

.subpage-header h1 {
  margin: 5px 0 7px;
  color: var(--navy-950);
  font-size: 27px;
  line-height: 1.2;
  letter-spacing: -0.7px;
}

.subpage-header > p:last-child {
  margin: 0;
  color: var(--navy-600);
  font-size: 12px;
  font-weight: 650;
}

.today-headlines-list {
  display: grid;
  gap: 13px;
  padding: 20px 18px 36px;
}

.today-headline-card {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 12px;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 17px 15px;
  border: 1px solid var(--line);
  border-radius: 17px;
  background: #fff;
  box-shadow: var(--shadow);
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.today-headline-card:hover {
  border-color: #d4dfec;
}

.today-headline-number {
  align-self: start;
  color: #c1ccd7;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  font-weight: 700;
}

.today-headline-copy {
  min-width: 0;
}

.today-headline-copy h2 {
  margin: 7px 0 6px;
  color: var(--navy-950);
  font-size: 14px;
  line-height: 1.48;
}

.today-headline-copy > p {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: var(--navy-600);
  font-size: 11px;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.today-headline-meta {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 11px;
}

.today-headline-meta .direction {
  font-size: 9px;
}

.news-article-view {
  background: #fff;
}

#news-detail-content {
  padding: 0 22px 48px;
}

.news-article-header {
  padding: 28px 0 32px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.news-article-category {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 7px;
  background: var(--blue-soft);
  color: var(--blue);
  font-size: 9px;
  font-weight: 800;
}

.news-article-header time {
  display: block;
  margin-top: 13px;
  color: var(--navy-400);
  font-size: 10px;
  font-weight: 700;
}

.news-article-risk {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 12px;
}

.news-article-header h1 {
  margin: 22px 0 15px;
  color: var(--navy-950);
  font-size: clamp(27px, 7.5vw, 34px);
  line-height: 1.32;
  letter-spacing: -0.8px;
}

.news-article-lead {
  margin: 0;
  color: #405b75;
  font-size: 15px;
  line-height: 1.9;
}

.article-briefing-section,
.article-watchpoint,
.article-source {
  margin: 0;
  padding: 28px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}

.article-summary {
  background: #fff;
}

.article-watchpoint {
  margin: 26px 0;
  padding: 20px 20px 20px 22px;
  border: 0;
  border-left: 3px solid var(--blue);
  border-radius: 0 8px 8px 0;
  background: #f5f8fd;
}

.article-briefing-section h2,
.article-watchpoint h2,
.article-source h2 {
  margin: 4px 0 12px;
  color: var(--navy-950);
  font-size: 20px;
  line-height: 1.45;
}

.article-briefing-section > p:last-child,
.article-watchpoint > p:last-child {
  margin: 0;
  color: var(--navy-600);
  font-size: 14.5px;
  line-height: 1.9;
}

.article-source {
  padding-top: 30px;
  border-bottom: 0;
}

.article-source-count {
  margin: 0 0 15px;
  color: var(--navy-400);
  font-size: 11px;
}

.article-source-list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 16px 0 0 20px;
  border-top: 1px solid var(--line);
  color: var(--navy-400);
}

.article-source-list li {
  padding-left: 3px;
}

.article-source-list a,
.article-source-list span {
  overflow-wrap: anywhere;
  color: var(--navy-700);
  font-size: 13px;
  line-height: 1.65;
}

.article-source-list a {
  color: var(--blue);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.article-source-empty {
  margin: 16px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  color: var(--navy-400);
  font-size: 13px;
}

.article-source-row {
  display: grid;
  gap: 13px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
}

.article-source-row strong,
.article-source-row span {
  display: block;
}

.article-source-row strong {
  color: var(--navy-900);
  font-size: 13px;
}

.article-source-row span {
  margin-top: 4px;
  color: var(--navy-400);
  font-size: 10px;
}

.article-source-row a {
  overflow-wrap: anywhere;
  color: var(--blue);
  font-size: 11px;
  line-height: 1.55;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* App menu and primary navigation update */
.header-spacer {
  width: 40px;
  height: 40px;
}

.menu-open {
  overflow: hidden;
}

.menu-backdrop {
  position: fixed;
  z-index: 50;
  inset: 0;
  background: rgba(7, 26, 51, 0.32);
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 180ms ease;
}

.menu-backdrop.open {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
}

.app-menu {
  position: fixed;
  z-index: 60;
  top: 0;
  bottom: 0;
  left: max(0px, calc((100vw - 480px) / 2));
  width: min(84vw, 350px);
  padding: max(22px, env(safe-area-inset-top)) 20px 28px;
  border-radius: 0 24px 24px 0;
  background: #fff;
  box-shadow: 20px 0 50px rgba(7, 26, 51, 0.18);
  opacity: 0;
  pointer-events: none;
  transform: translateX(-105%);
  visibility: hidden;
  transition:
    transform 220ms ease,
    opacity 160ms ease,
    visibility 0s linear 220ms;
}

.app-menu.open {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
  visibility: visible;
  transition:
    transform 220ms ease,
    opacity 160ms ease;
}

.menu-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.menu-header p,
.menu-header span,
.drawer-label {
  margin: 0;
}

.menu-header p {
  color: var(--navy-950);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  font-weight: 750;
}

.menu-header span {
  display: block;
  margin-top: 4px;
  color: var(--navy-400);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 1.8px;
}

.menu-close {
  display: grid;
  width: 36px;
  height: 36px;
  padding: 0 0 3px;
  place-items: center;
  border: 0;
  border-radius: 11px;
  background: #f2f5f9;
  color: var(--navy-600);
  font-size: 25px;
  line-height: 1;
  cursor: pointer;
}

.drawer-nav {
  display: grid;
  gap: 7px;
  padding-top: 17px;
}

.drawer-nav button {
  width: 100%;
  padding: 12px 11px;
  border: 0;
  border-radius: 11px;
  background: transparent;
  color: var(--navy-900);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
}

.drawer-nav button:hover,
.drawer-nav button:focus-visible {
  background: #f3f7fc;
  color: var(--blue);
}

.drawer-label {
  padding: 12px 11px 2px;
  color: var(--navy-400);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

.drawer-categories {
  display: grid;
  gap: 2px;
  margin: 0 0 9px 10px;
  padding-left: 10px;
  border-left: 1px solid #dbe3ed;
}

.drawer-categories button {
  padding-top: 9px;
  padding-bottom: 9px;
  color: var(--navy-600);
  font-size: 11.5px;
  font-weight: 650;
}

.bottom-nav {
  grid-template-columns: repeat(3, 1fr);
}

.nav-item {
  border: 0;
  background: transparent;
  font-family: inherit;
  cursor: pointer;
}

.watchlist-items {
  padding: 8px 22px 112px;
}

.watchlist-category {
  padding: 26px 0 8px;
  border-top: 1px solid var(--line);
}

.watchlist-category:first-child {
  border-top: 0;
}

.watchlist-category > h2 {
  margin: 0 0 22px;
  color: var(--navy-950);
  font-size: 20px;
  line-height: 1.35;
}

.watchlist-date-group {
  margin-bottom: 24px;
}

.watchlist-date-group h3 {
  margin: 0 0 9px;
  color: var(--navy-400);
  font-size: 11px;
  font-weight: 750;
}

.watchlist-date-group ul {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.watchlist-date-group li {
  position: relative;
  border-bottom: 1px solid #edf1f5;
}

.watchlist-date-group li:last-child {
  border-bottom: 0;
}

.watchlist-date-group li::before {
  position: absolute;
  top: 20px;
  left: 0;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--blue);
  content: "";
}

.watchlist-date-group button,
.watchlist-date-group li > p {
  display: flex;
  width: 100%;
  align-items: flex-start;
  gap: 12px;
  margin: 0;
  padding: 14px 0 14px 15px;
  border: 0;
  background: transparent;
  color: var(--navy-800);
  font-family: inherit;
  font-size: 13px;
  line-height: 1.75;
  text-align: left;
}

.watchlist-date-group button {
  cursor: pointer;
}

.watchlist-date-group button > span:first-child,
.watchlist-date-group li > p > span {
  flex: 1;
}

.watchlist-date-group button:active {
  background: #f8faff;
}

.watchlist-link-mark {
  flex: 0 0 auto;
  color: var(--navy-300);
  font-size: 20px;
  line-height: 1.1;
}

@media (prefers-reduced-motion: reduce) {
  .app-menu,
  .menu-backdrop {
    transition: none;
  }
}
