/* The HAB Report Weekly (/weekly/). Written by the release tools. Site tokens only (site.css :root); no new colours,
   no new fonts. Chart text is HTML placed over the SVG by percentages, so it keeps its size on a phone. */
.wk { max-width: 760px; margin: 0 auto; padding: 48px 24px 64px; color: var(--ink-2); }
.wk p { margin: 0 0 1em; }
.wkchips { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.wk h1 { font-size: clamp(34px, 5vw, 46px); line-height: 1.1; letter-spacing: -0.03em; margin: 18px 0 12px; }
.wkdek { font-size: 19px; color: var(--muted); margin: 0 0 28px; }
.wktiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.wktile, .wkcard { background: var(--panel); border: 1px solid var(--line-2); border-radius: 14px; padding: 18px; }
.wklab { font-family: var(--mono); font-weight: 500; font-size: 12px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted-2); }
.wkbig { font-size: 34px; font-weight: 800; color: var(--white); margin: 6px 0 4px; letter-spacing: -0.02em; line-height: 1.1; }
.wkbig.warm { color: var(--warm); }
.wkctx { font-size: 14px; color: var(--muted); line-height: 1.4; }
.wksec { margin-top: 56px; }
.wk h2 { font-size: clamp(26px, 3.6vw, 32px); letter-spacing: -0.02em; margin: 8px 0 18px; }
.wklead { color: var(--white); }
.wkq { background: var(--panel-2); border-radius: 14px; padding: 20px 22px; margin: 24px 0; }
.wkq p { margin: 0; color: var(--white); font-weight: 700; font-size: 20px; line-height: 1.4; }
.wktake { background: var(--panel); border: 1px solid var(--line-2); border-left: 3px solid var(--link); border-radius: 14px; padding: 20px 22px; }
.wktake p { margin: 0.4em 0; }
.wkcards { display: grid; gap: 12px; }
.wkdc { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 16px; align-items: start; }
.wkday { font-family: var(--mono); font-weight: 500; font-size: 13px; color: var(--muted-2); text-transform: uppercase; letter-spacing: 0.1em; }
.wkdt { font-size: 22px; font-weight: 800; color: var(--white); line-height: 1.2; }
.wkdc b { color: var(--white); }
.wkdc p { margin: 4px 0 0; font-size: 16px; }
.wkdc.hl { background: var(--panel-2); border-color: var(--accent); }
.wkdc.wm { background: var(--warm-bg); border-color: color-mix(in srgb, var(--warm) 30%, var(--warm-bg)); }
.wkcta { background: var(--panel); border: 1px solid var(--line-2); border-radius: 16px; padding: 28px; margin-top: 56px; }
.wkcta h3 { font-size: 26px; margin: 8px 0 6px; letter-spacing: -0.02em; }
.wkcta p { margin: 0; color: var(--ink-2); }
.wkbtns { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 16px; }
.wkall { margin: 28px 0 0; font-size: 15px; }
/* charts */
.wkchart { background: var(--panel); border: 1px solid var(--line-2); border-radius: 16px; padding: 18px 20px 12px; margin: 22px 0; }
.wkct { font-size: 14px; color: var(--ink); font-weight: 700; margin: 0 0 10px; }
.wkplot { display: grid; grid-template-columns: 44px minmax(0, 1fr); column-gap: 8px; }
.wkgut { position: relative; }
.wkgut span { position: absolute; right: 0; transform: translateY(-50%); font-family: var(--mono); font-weight: 500; font-size: 12px; line-height: 1; color: var(--muted-2); white-space: nowrap; }
.wkarea { position: relative; }
.wkarea svg { display: block; width: 100%; height: auto; overflow: visible; }
.wkx { grid-column: 2; position: relative; height: 38px; margin-top: 4px; }
.wkx span { position: absolute; top: 0; transform: translateX(-50%); text-align: center; font-family: var(--mono); font-weight: 500; font-size: 12px; line-height: 1.3; color: var(--muted-2); white-space: nowrap; }
.wkx span b { display: block; font-weight: 500; color: var(--muted-2); }
.wkv { position: absolute; font-family: var(--mono); font-weight: 600; font-size: 13px; line-height: 1; color: var(--white); white-space: nowrap; --tx: -50%; --ty: calc(-100% - 8px); transform: translate(var(--tx), var(--ty)); }
.wkv.below { --ty: 8px; }
.wkv.start { --tx: 10px; }
.wkv.end { --tx: calc(-100% - 10px); }
.wkv.up { color: var(--link); }
.wkv.down { color: var(--warm); }
.wkv.flat { color: var(--muted-2); }
.wkchart .grid { stroke: var(--line); stroke-width: 1; }
.wkchart .zero { stroke: var(--edge); stroke-width: 1; }
.wkchart .shade { fill: var(--link); opacity: 0.12; }
.wkchart .seg { stroke-width: 3; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.wkchart .seg.up { stroke: var(--link); }
.wkchart .seg.down { stroke: var(--warm); }
.wkchart .seg.flat { stroke: var(--muted-2); }
.wkchart .dot { stroke: var(--panel); stroke-width: 2; }
.wkchart .dot.up, .wkchart .bar.up { fill: var(--link); }
.wkchart .dot.down, .wkchart .bar.down { fill: var(--warm); }
.wkchart .dot.flat, .wkchart .bar.flat { fill: var(--muted-2); }
/* archive */
.wkarchive h1 { margin-top: 12px; }
.wklist { list-style: none; margin: 32px 0 0; padding: 0; display: grid; gap: 14px; }
.wkissue a { display: block; background: var(--panel); border: 1px solid var(--line-2); border-radius: 14px; padding: 22px 24px; text-decoration: none; color: var(--ink-2); }
.wkissue a:hover { border-color: var(--link); color: var(--ink-2); }
.wkmeta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.wkhead { display: block; font-size: 24px; font-weight: 800; color: var(--white); letter-spacing: -0.02em; line-height: 1.2; margin: 8px 0 6px; }
.wkissue.latest .wkhead { font-size: clamp(26px, 3.6vw, 32px); }
.wksub { display: block; color: var(--muted); font-size: 16px; }
.wknone { color: var(--muted); }
@media (max-width: 640px) {
  .wk { padding: 40px 16px 56px; }
  .wktiles { grid-template-columns: 1fr; }
  .wkdc { grid-template-columns: 1fr; gap: 6px; }
  .wkdek { font-size: 17px; }
  .wkq p { font-size: 18px; }
  .wkchart { padding: 16px 14px 10px; }
  .wkplot { grid-template-columns: 40px minmax(0, 1fr); column-gap: 6px; }
  .wkcta { padding: 22px 20px; }
  .wkbtns .btn { width: 100%; }
}
/* covers: the picture fills the card from the right under a shade of the ground; the text keeps the solid left.
   On a phone the picture sits behind the text under a top-to-bottom shade. An issue without a cover is untouched. */
.wkissue.haspic a, .wkhero.haspic { position: relative; overflow: hidden; }
.wkissue.haspic a { min-height: 220px; }
.wkhero { background: var(--panel); border: 1px solid var(--line-2); border-radius: 14px; padding: 26px 28px 22px; margin-bottom: 26px; }
.wkhero.haspic { min-height: 260px; }
.wkhero h1 { margin: 14px 0 10px; }
.wkhero .wkdek { margin-bottom: 0; }
.wkpic { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: right center; }
.wkissue.haspic a::after, .wkhero.haspic::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, color-mix(in srgb, var(--ground) 97%, transparent) 0%, color-mix(in srgb, var(--ground) 95%, transparent) 58%, color-mix(in srgb, var(--ground) 45%, transparent) 76%, color-mix(in srgb, var(--ground) 0%, transparent) 100%); }
.haspic .wktxt { position: relative; z-index: 1; display: block; }
.wkissue.haspic .wktxt { max-width: 420px; }
.wkhero.haspic .wktxt { max-width: 420px; }
@media (max-width: 640px) {
  .wkissue.haspic a, .wkhero.haspic { min-height: 320px; padding-top: 118px; }
  .wkhero { padding-left: 20px; padding-right: 20px; }
  .wkissue.haspic a::after, .wkhero.haspic::after { background: linear-gradient(180deg, color-mix(in srgb, var(--ground) 30%, transparent) 0%, color-mix(in srgb, var(--ground) 92%, transparent) 38%, color-mix(in srgb, var(--ground) 97%, transparent) 100%); }
  .wkissue.haspic .wktxt, .wkhero.haspic .wktxt { max-width: none; }
}
