:root {
  color-scheme: light;
  --navy: #132c42;
  --gold: #b38a4d;
  --ink: #243746;
  --muted: #536675;
  --paper: #f7f6f1;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.8 system-ui, "Microsoft YaHei", sans-serif; }
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, figure { margin: 0; }
h2 { font-size: clamp(22px, 3vw, 30px); line-height: 1.4; }
.wrap { width: min(1200px, calc(100% - 48px)); margin-inline: auto; }
.skip { position: absolute; left: 12px; top: -100px; background: white; padding: 8px; z-index: 10; }
.skip:focus { top: 12px; }
.header { background: var(--navy); color: white; }
.nav { display: flex; justify-content: space-between; align-items: center; min-height: 84px; gap: 20px; }
.brand { display: flex; align-items: center; gap: 12px; font-size: 23px; font-weight: 700; letter-spacing: 2px; white-space: nowrap; line-height: 1.2; }
.brand small { display: block; font-size: 10px; letter-spacing: 3px; color: #e3c48d; margin-top: 5px; }
nav { display: flex; flex-wrap: wrap; gap: 26px; font-size: 14px; }
.edition { display: flex; justify-content: space-between; gap: 10px; padding: 20px 0 12px; color: var(--muted); font-size: 12px; letter-spacing: 1px; }
.hero { display: grid; grid-template-columns: 45% 55%; background: var(--navy); color: white; }
.hero-copy { padding: clamp(25px, 4vw, 55px); align-self: center; }
.eyebrow { color: #8a642d; font-size: 11px; font-weight: 700; letter-spacing: 2px; margin-bottom: 12px; }
.hero .eyebrow, .result .eyebrow { color: #e5c58e; }
h1 { font-size: clamp(20px, 2.4vw, 32px); line-height: 1.5; overflow-wrap: anywhere; }
h1 span { display: block; font-size: clamp(28px, 3.7vw, 48px); color: #f1d9ae; margin: 12px 0 22px; }
.hero-copy > p:not(.eyebrow) { color: #dce6ee; }
.cta { display: inline-flex; gap: 30px; background: #e2c28b; color: #132c42; padding: 12px 22px; margin-top: 24px; font-weight: 700; }
.hero figure { position: relative; min-width: 0; }
.hero figure img { width: 100%; height: 100%; object-fit: cover; }
figcaption { position: absolute; bottom: 0; right: 0; background: #132c42e8; color: white; font-size: 11px; padding: 6px 12px; }
.dimensions { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid #d9d5ca; margin-bottom: 44px; background: white; }
.dimensions article { padding: 24px; border-right: 1px solid #dedad0; }
.dimensions article:last-child { border: 0; }
.dimensions b { color: #98713a; font-size: 23px; font-family: Georgia, serif; }
.dimensions h2 { font-size: 18px; margin: 5px 0; }
.dimensions p { font-size: 14px; color: var(--muted); }
section { scroll-margin-top: 16px; }
.section-head { margin-bottom: 24px; }
.section-head > p:last-child:not(.eyebrow) { color: var(--muted); margin-top: 8px; }
.workbench { padding: 34px; background: #fff; border: 1px solid #dedad0; }
.work-grid { display: grid; grid-template-columns: 1.25fr 1fr; gap: 32px; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; margin-top: 12px; }
label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 5px; }
input { width: 100%; min-width: 0; padding: 10px; border: 1px solid #9faeb8; border-radius: 3px; font: inherit; color: var(--ink); background: white; }
.actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 20px; }
button { padding: 10px 14px; border: 1px solid var(--navy); background: var(--navy); color: white; font: inherit; font-size: 14px; cursor: pointer; border-radius: 3px; }
.secondary { background: white; color: var(--navy); }
:focus-visible { outline: 3px solid #c88a31; outline-offset: 3px; }
.result { background: var(--navy); color: white; padding: 26px; min-width: 0; overflow-wrap: anywhere; }
.result h3 { font-size: 24px; }
.result dl { margin: 18px 0; }
.result dl div { display: flex; justify-content: space-between; align-items: center; gap: 12px; border-bottom: 1px solid #ffffff35; padding: 12px 0; }
.result dd { margin: 0; color: #f2d7a8; font-size: 22px; font-weight: 700; }
.result p, .result small { color: #dae6ef; }
.result small { display: block; margin-top: 12px; }
.journal { margin: 48px 0; }
.journal article { display: grid; grid-template-columns: 130px 1fr; gap: 24px; border-top: 1px solid #d6d3c8; padding: 24px 0; }
.journal article > span { font-size: 14px; color: #8a642d; font-weight: 700; }
.journal h3 { font-size: 20px; margin-bottom: 8px; }
.journal article p { color: var(--muted); }
.sources { display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; background: #e8e9e4; padding: 32px; }
.sources p:not(.eyebrow) { margin-top: 12px; }
.source-links { display: grid; align-content: center; gap: 10px; }
.source-links a { background: white; border-left: 3px solid var(--gold); padding: 12px 16px; }
.faq { margin: 44px 0; }
.faq h2 { margin-bottom: 18px; }
details { border-top: 1px solid #d6d3c8; padding: 16px 0; }
summary { cursor: pointer; font-weight: 600; }
details p { margin-top: 12px; color: var(--muted); }
footer { background: var(--navy); color: #e1e8ed; padding: 30px 0; }
.footer-inner p { font-size: 14px; margin: 8px 0; }
@media (max-width: 760px) {
  .wrap { width: calc(100% - 28px); }
  .nav { align-items: flex-start; flex-direction: column; padding: 18px 0; gap: 14px; }
  nav { gap: 10px 20px; }
  .edition { flex-wrap: wrap; }
  .hero, .work-grid, .sources { grid-template-columns: 1fr; }
  .hero figure img { height: auto; aspect-ratio: 16/10; }
  .dimensions { grid-template-columns: 1fr 1fr; }
  .dimensions article { padding: 16px; border-bottom: 1px solid #dedad0; }
  .workbench, .sources { padding: 20px; }
  .journal article { grid-template-columns: 1fr; gap: 5px; }
  .result { padding: 18px; }
}
@media (max-width: 360px) {
  .fields { grid-template-columns: 1fr; }
  .result dd { font-size: 18px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* Market access and comparison workspace */
.quick { background: white; border: 1px solid #dedad0; padding: 28px; margin: 24px 0; }
.quick-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.quick-grid a { padding: 16px; background: #f7f6f1; border-top: 3px solid var(--gold); min-width: 0; }
.quick-grid b, .quick-grid span { display: block; }
.quick-grid span { font-size: 13px; color: var(--muted); margin-top: 5px; }
select { width: 100%; min-width: 0; padding: 10px; border: 1px solid #9faeb8; background: white; color: var(--ink); font: inherit; border-radius: 3px; }
.sector-row { min-width: 0; margin: 18px 0; padding: 18px; border: 1px solid #d9d5ca; }
.sector-row legend { padding: 0 8px; color: #8a642d; font-weight: 700; }
.sector-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.remove { margin-top: 12px; }
#results { margin-top: 24px; }
#ranking { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.rank-card { border: 1px solid #ffffff35; padding: 16px; margin-top: 14px; }
.rank-card h3 { color: #f2d7a8; font-size: 19px; }
.rank-card meter { width: 100%; height: 20px; }
.formula { margin-top: 16px; font-size: 14px; color: var(--muted); }
.method { padding: 24px 0; border-bottom: 1px solid #d6d3c8; }
.method p { margin-top: 12px; }
button:disabled { opacity: .5; cursor: not-allowed; }
@media (max-width: 760px) {
  .quick { padding: 18px; }
  .quick-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sector-grid, #ranking { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sector-row { padding: 12px; }
}
@media (max-width: 480px) {
  .sector-grid, #ranking { grid-template-columns: 1fr; }
  .quick-grid a { padding: 12px; }
  .workbench { padding: 16px; }
}
