/*
 * Design tokens: the ONLY place a colour hex appears (site:check css).
 * Calm, discreet, trustworthy: a warm off-white paper, white cards, ink
 * text, one muted rose accent (Lady's #E06A93, darkened for AA):
 *   --accent #9B3A61 on --paper 6.3:1, on white 6.6:1; white on it 6.6:1.
 *   --ink on --paper 14.9:1; --muted on --paper 6.7:1; --ink on --accent-wash 13.5:1.
 * System fonts only. Type scale: ratio 1.25 from the body size.
 */
:root {
  --paper: #FAF8F5;
  --card: #FFFFFF;
  --ink: #1F2328;
  --muted: #55595F;
  --line: #E6E1DB;
  --line-strong: #CEC6BE;
  /* The calendar's range hatch: 3.4:1 on white, 3.2:1 on --paper; --ink on it 4.6:1. */
  --hatch: #8F8A84;
  --accent: #9B3A61;
  --accent-deep: #82304F;
  --accent-wash: #F8EBF0;
  --accent-soft: #F3DEE6;
  --calm-wash: #F2F4F3;
  --focus: #1F2328;
  --shadow-color: #1F232814;
  --shadow-color-strong: #1F232822;

  --font-body: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans', sans-serif;

  --fs-base: 17px;
  --fs-sm: 0.875rem;
  --fs-0: 1rem;
  --fs-1: 1.25rem;
  --fs-2: 1.5625rem;
  --fs-3: 1.953rem;
  --fs-4: 2.441rem;
  --lh-tight: 1.15;
  --lh-body: 1.6;

  --s-1: 4px;
  --s-2: 8px;
  --s-3: 12px;
  --s-4: 16px;
  --s-5: 24px;
  --s-6: 32px;
  --s-7: 48px;
  --s-8: 64px;

  --r-card: 16px;
  --r-btn: 12px;
  --r-pill: 999px;
  --shadow-1: 0 1px 2px var(--shadow-color), 0 4px 16px var(--shadow-color);
  --shadow-2: 0 2px 4px var(--shadow-color), 0 12px 32px var(--shadow-color-strong);

  --wrap: 1180px;
  --measure: 70ch;
  --gutter: clamp(16px, 4vw, 40px);
  --tap: 44px;
}
@media (min-width: 900px) {
  :root {
    --fs-base: 18px;
  }
}

/* Base: reset, type, links, focus, the centred reading column. Mobile first. */
*,
*::before,
*::after {
  box-sizing: border-box;
}
[hidden] {
  display: none !important;
}
html {
  -webkit-text-size-adjust: 100%;
  font-size: var(--fs-base);
}
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-0);
  line-height: var(--lh-body);
  text-rendering: optimizeLegibility;
}
button,
input,
select {
  font: inherit;
  color: inherit;
}
img,
svg {
  max-width: 100%;
}
a {
  color: var(--accent);
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}
a:hover {
  color: var(--accent-deep);
  text-decoration-thickness: 2px;
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 6px;
}
details > summary {
  list-style: none;
  cursor: pointer;
}
details > summary::-webkit-details-marker {
  display: none;
}
h1,
h2,
h3 {
  line-height: var(--lh-tight);
  text-wrap: balance;
  color: var(--ink);
  letter-spacing: -0.015em;
}
h1 {
  font-size: var(--fs-3);
  font-weight: 750;
  margin: var(--s-2) 0 var(--s-4);
}
h2 {
  font-size: var(--fs-1);
  font-weight: 700;
  margin: var(--s-7) 0 var(--s-3);
}
h3 {
  font-size: var(--fs-0);
  font-weight: 700;
  margin: var(--s-5) 0 var(--s-2);
}
@media (min-width: 900px) {
  h1 {
    font-size: var(--fs-4);
  }
  h2 {
    font-size: var(--fs-2);
  }
}
p {
  margin: 0 0 var(--s-4);
}
ul,
ol {
  margin: 0 0 var(--s-4);
  padding-inline-start: 1.3em;
}
li {
  margin-bottom: var(--s-2);
}
small {
  color: var(--muted);
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding-inline: var(--gutter);
}
.main {
  flex: 1;
  padding-block: var(--s-5) var(--s-8);
}
.article {
  max-width: var(--measure);
  margin-inline: auto;
}
.article > section + section {
  border-top: 1px solid var(--line);
  margin-top: var(--s-7);
}
.article > section + section > h2:first-child {
  margin-top: var(--s-6);
}
.lead {
  font-size: var(--fs-1);
  line-height: 1.45;
  color: var(--muted);
  margin-bottom: var(--s-6);
}
/* Home (design round 2, H2): a slightly smaller hero and a shorter gap before the tool list. */
.main-hub h1 {
  font-size: 1.75rem;
}
.main-hub .lead {
  margin-bottom: var(--s-5);
}
.main-hub .article > section:first-of-type > h2:first-child {
  margin-top: var(--s-5);
}
@media (min-width: 900px) {
  .main-hub h1 {
    font-size: 2.2rem;
  }
}
/* Tool pages (design round 2, T5): a quieter lead, so the inputs come up. */
.main-tool .lead {
  font-size: var(--fs-sm);
  line-height: 1.6;
  margin-bottom: var(--s-4);
}
/* Round 3 (R3-1): a lighter H1 on tool pages (home keeps its hero). */
.main-tool h1 {
  margin-bottom: var(--s-3);
  font-weight: 650;
}
/* Tool pages on desktop (T4): the page column is the header's; prose keeps its measure, the tool uses the width. */
@media (min-width: 1024px) {
  .main-tool .article {
    max-width: none;
  }
  .main-tool .article > :not(.tool):not(.help-line) {
    max-width: var(--measure);
  }
}
.ic {
  flex: none;
  vertical-align: middle;
}
.skip {
  position: absolute;
  inset-inline-start: 12px;
  top: -60px;
  z-index: 10;
  background: var(--ink);
  color: var(--card);
  padding: 10px 14px;
  border-radius: var(--r-btn);
}
.skip:focus {
  top: 12px;
  color: var(--card);
}
.review-statement {
  background: var(--calm-wash);
  border-radius: var(--r-btn);
  padding: var(--s-3) var(--s-4);
}

/* Chrome: a one-line header (wordmark + a <details> menu on phones; links never wrap), breadcrumbs, the help line, the footer. */
.top {
  background: var(--card);
  border-bottom: 1px solid var(--line);
}
.top-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  min-height: 64px;
  flex-wrap: nowrap;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: var(--tap);
  color: var(--ink);
  text-decoration: none;
  font-weight: 750;
  font-size: 1.06rem;
  letter-spacing: -0.015em;
  white-space: nowrap;
  min-width: 0;
}
.brand:hover {
  color: var(--ink);
}
.brand-mark {
  color: var(--ink);
  flex: none;
}
.brand-dot {
  fill: var(--accent);
}
.nav-desk {
  display: none;
  gap: var(--s-1);
  flex-wrap: nowrap;
}
.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 0 var(--s-3);
  border-radius: var(--r-pill);
  color: var(--ink);
  text-decoration: none;
  font-weight: 560;
  white-space: nowrap;
}
.nav-link:hover,
.nav-link[aria-current='page'] {
  background: var(--accent-wash);
  color: var(--accent-deep);
}
/* Round 3 (R3-1): lighter navigation on the tool pages. */
body:has(.main-tool) .nav-link {
  font-weight: 480;
}
.nav-mob {
  position: relative;
  flex: none;
}
.menu-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--tap);
  height: var(--tap);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-btn);
  background: var(--card);
}
.menu-btn .ic-close,
.nav-mob[open] .menu-btn .ic-open {
  display: none;
}
.nav-mob[open] .menu-btn .ic-close {
  display: inline-flex;
}
.menu-btn .ic-open {
  display: inline-flex;
}
.nav-mob nav {
  position: absolute;
  inset-inline-end: 0;
  top: calc(100% + var(--s-2));
  z-index: 5;
  min-width: 232px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-2);
  padding: var(--s-2);
  display: flex;
  flex-direction: column;
}
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--tap);
  padding: 0 var(--s-3);
  border-radius: var(--r-btn);
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
.nav-row[aria-current='page'],
.nav-row:hover {
  background: var(--accent-wash);
  color: var(--accent-deep);
}
@media (min-width: 820px) {
  .nav-desk {
    display: flex;
  }
  .nav-mob {
    display: none;
  }
}
.crumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--s-1);
  color: var(--muted);
  font-size: var(--fs-sm);
}
.crumbs a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  color: var(--muted);
}
.help-line {
  display: flex;
  gap: var(--s-2);
  /* Round 4 (M3): the icon sits on the first text line; padding keeps a wrapped line evenly spaced. */
  align-items: flex-start;
  line-height: 1.55;
  background: var(--calm-wash);
  border-inline-start: 3px solid var(--accent);
  border-radius: var(--r-btn);
  padding: var(--s-2) var(--s-3);
  margin: 0 0 var(--s-4);
  font-size: var(--fs-sm);
}
.help-line .ic {
  color: var(--accent);
  margin-top: 2px;
}
.help-line p {
  margin: 0;
}
.help-line a {
  /* Inline (not inline-flex): a 44 px target from vertical padding, which does not stretch the line box. */
  display: inline;
  padding-block: 14px;
  font-weight: 650;
  color: var(--accent-deep);
  white-space: nowrap;
}
.foot {
  background: var(--card);
  border-top: 1px solid var(--line);
  font-size: var(--fs-sm);
  color: var(--muted);
}
.foot-in {
  padding-block: var(--s-6) var(--s-7);
  display: grid;
  gap: var(--s-2);
}
.foot-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0 var(--s-5);
  margin-bottom: var(--s-3);
}
.foot-link {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  color: var(--ink);
}
.foot-link[aria-current='page'] {
  color: var(--accent-deep);
}
.independence {
  color: var(--ink);
  font-weight: 560;
  margin: 0;
}
.maint {
  margin: 0;
}

/* Content components: method cards, details, tables (stacked on phones), the Lady section, the 404. */
.article details {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-btn);
  padding: 0 var(--s-4);
  margin-bottom: var(--s-3);
}
.article summary {
  display: flex;
  align-items: center;
  min-height: var(--tap);
  font-weight: 650;
}
.article details[open] {
  padding-bottom: var(--s-3);
}
.method-cards {
  list-style: none;
  padding: 0;
  display: grid;
  gap: var(--s-4);
  grid-template-columns: 1fr;
  margin: var(--s-5) 0;
}
@media (min-width: 680px) {
  .method-cards {
    grid-template-columns: 1fr 1fr;
  }
}
.method-cards li {
  margin: 0;
}
.method-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-content: start;
  gap: var(--s-2) var(--s-4);
  align-items: start;
  height: 100%;
  min-height: var(--tap);
  padding: var(--s-5);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-1);
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.method-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-2);
  color: var(--ink);
}
.method-card .ic {
  grid-row: span 2;
  width: 40px;
  height: 40px;
  padding: 8px;
  border-radius: var(--r-btn);
  background: var(--accent-wash);
  color: var(--accent);
}
.mc-title,
.mc-text {
  grid-column: 2;
}
/* H1: a quiet chevron says the whole card is a link. */
.mc-go {
  grid-column: 3;
  grid-row: 1 / span 2;
  align-self: center;
  display: inline-flex;
  color: var(--muted);
  transition: transform 0.15s, color 0.15s;
}
.method-card .mc-go .ic {
  width: 20px;
  height: 20px;
  padding: 0;
  background: none;
  color: inherit;
}
.method-card:hover .mc-go {
  color: var(--accent);
  transform: translateX(2px);
}
.mc-title {
  font-weight: 700;
  font-size: var(--fs-1);
  line-height: var(--lh-tight);
  color: var(--accent-deep);
}
.mc-text {
  color: var(--muted);
  font-size: var(--fs-sm);
  line-height: 1.5;
}
.table-wrap {
  display: block;
  overflow-x: auto;
  margin: var(--s-4) 0;
  border: 1px solid var(--line);
  border-radius: var(--r-btn);
  background: var(--card);
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: var(--fs-sm);
}
caption {
  text-align: start;
  font-weight: 700;
  padding: var(--s-3) var(--s-4) var(--s-2);
}
th,
td {
  text-align: start;
  vertical-align: top;
  padding: var(--s-3) var(--s-4);
  border-top: 1px solid var(--line);
}
thead th {
  color: var(--muted);
  font-weight: 600;
}
.cell-label {
  display: none;
}
@media (max-width: 560px) {
  .sources-table thead {
    display: none;
  }
  .sources-table tr {
    display: block;
    border-top: 1px solid var(--line);
    padding: var(--s-2) 0;
  }
  .sources-table th,
  .sources-table td {
    display: block;
    border: 0;
    padding: var(--s-1) var(--s-4);
  }
  .sources-table .cell-label {
    display: block;
    color: var(--muted);
    font-size: 0.8rem;
  }
}
.lady {
  max-width: var(--measure);
  margin: var(--s-7) auto 0;
  background: var(--calm-wash);
  border-radius: var(--r-card);
  padding: var(--s-5);
}
.lady h2 {
  margin-top: var(--s-1);
}
.lady-eyebrow {
  color: var(--muted);
  font-size: var(--fs-sm);
  font-weight: 600;
  margin: 0;
}
.badges {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
  align-items: center;
}
.badges a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
}
.badges img {
  display: block;
  height: 44px;
  width: auto;
}
/* The Google Play badge artwork carries its own transparent margin: shown taller so both badges read the same size. */
.badges img[src*='googleplay-badge'] {
  height: 58px;
  margin-block: -7px;
}
.nf {
  max-width: var(--measure);
  margin-inline: auto;
}
.nf-code {
  color: var(--muted);
  font-weight: 600;
  margin: var(--s-3) 0 0;
}
.nf-links {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--s-3);
}
.nf-card {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: 56px;
  padding: var(--s-3) var(--s-4);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-btn);
  color: var(--ink);
  text-decoration: none;
}
.nf-card .ic {
  color: var(--accent);
}
.nf-card:hover {
  border-color: var(--accent);
}

/* The tool card and its UI (tools/ui): form, result card, tables, export dialog, memory, refusals. */
.tool {
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-1);
  padding: var(--s-5);
  margin: 0 0 var(--s-6);
}
@media (min-width: 720px) {
  .tool {
    padding: var(--s-6);
  }
}
/*
 * Reserved height (CLS 0): the card holds, before AND after the script
 * mounts, at least the height of the mounted tool at the narrowest width of
 * each range, so mounting never pushes the page down and never pulls it up.
 * Measured on the built pages (heights only fall as the width grows within a
 * range); the smoke's tool-layout-shift check fails when copy or layout
 * outgrows them. 0 without JS (noscript.css).
 */
.tool[data-tool="depo"] {
  --tool-min: 1068px;
}
.tool[data-tool="patch"] {
  --tool-min: 1167px;
}
.tool[data-tool="ring"] {
  --tool-min: 1167px;
}
.tool[data-tool="pack"] {
  --tool-min: 1167px;
}
@media (min-width: 360px) {
  .tool[data-tool="depo"] {
    --tool-min: 989px;
  }
  .tool[data-tool="patch"] {
    --tool-min: 1116px;
  }
  .tool[data-tool="ring"] {
    --tool-min: 1089px;
  }
  .tool[data-tool="pack"] {
    --tool-min: 1116px;
  }
}
@media (min-width: 390px) {
  .tool[data-tool="depo"] {
    --tool-min: 989px;
  }
  .tool[data-tool="patch"] {
    --tool-min: 1089px;
  }
  .tool[data-tool="ring"] {
    --tool-min: 1061px;
  }
  .tool[data-tool="pack"] {
    --tool-min: 1089px;
  }
}
@media (min-width: 412px) {
  .tool[data-tool="depo"] {
    --tool-min: 979px;
  }
  .tool[data-tool="patch"] {
    --tool-min: 1051px;
  }
  .tool[data-tool="ring"] {
    --tool-min: 1051px;
  }
  .tool[data-tool="pack"] {
    --tool-min: 1051px;
  }
}
@media (min-width: 430px) {
  .tool[data-tool="depo"] {
    --tool-min: 928px;
  }
  .tool[data-tool="patch"] {
    --tool-min: 1027px;
  }
  .tool[data-tool="ring"] {
    --tool-min: 1027px;
  }
  .tool[data-tool="pack"] {
    --tool-min: 1027px;
  }
}
@media (min-width: 480px) {
  .tool[data-tool="depo"] {
    --tool-min: 904px;
  }
  .tool[data-tool="patch"] {
    --tool-min: 1004px;
  }
  .tool[data-tool="ring"] {
    --tool-min: 1004px;
  }
  .tool[data-tool="pack"] {
    --tool-min: 1004px;
  }
}
@media (min-width: 720px) {
  .tool[data-tool="depo"] {
    --tool-min: 920px;
  }
  .tool[data-tool="patch"] {
    --tool-min: 1009px;
  }
  .tool[data-tool="ring"] {
    --tool-min: 1009px;
  }
  .tool[data-tool="pack"] {
    --tool-min: 1009px;
  }
}
@media (min-width: 900px) {
  .tool[data-tool="depo"] {
    --tool-min: 920px;
  }
  .tool[data-tool="patch"] {
    --tool-min: 1021px;
  }
  .tool[data-tool="ring"] {
    --tool-min: 1021px;
  }
  .tool[data-tool="pack"] {
    --tool-min: 1021px;
  }
}
@media (min-width: 1024px) {
  .tool[data-tool="depo"] {
    --tool-min: 694px;
  }
  .tool[data-tool="patch"] {
    --tool-min: 824px;
  }
  .tool[data-tool="ring"] {
    --tool-min: 795px;
  }
  .tool[data-tool="pack"] {
    --tool-min: 795px;
  }
}
.tool[data-tool] {
  min-height: var(--tool-min);
}
.tool > .bcd-app,
.tool > .tool-fallback {
  margin-bottom: var(--s-5);
}
.tool-msg {
  color: var(--muted);
  font-size: var(--fs-sm);
}
.tool-load-failed {
  display: none;
}
.tool:not([data-ready]) .tool-load-failed {
  display: block;
  animation: bcd-reveal 0s linear 4s both;
}
.tool-load-failed.now {
  display: block;
  animation: none;
}
@keyframes bcd-reveal {
  from {
    visibility: hidden;
  }
  to {
    visibility: visible;
  }
}
/* Round 3 (R3-7): the provenance line, quiet, under the tool page's H1. */
.trust-strip {
  display: flex;
  flex-wrap: wrap;
  column-gap: var(--s-2);
  align-items: center;
  margin: calc(-1 * var(--s-2)) 0 var(--s-2);
  color: var(--muted);
  font-size: var(--fs-sm);
}
/* Narrow screens: the source on its own line, then "Page updated … · Sources" (no separator starts a line). */
@media (max-width: 479px) {
  .trust-strip > :first-child {
    flex-basis: 100%;
  }
  .trust-strip > [aria-hidden]:nth-child(2) {
    display: none;
  }
}
.trust-strip a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
}
.bcd-form {
  display: grid;
  gap: var(--s-4);
}
.bcd-field {
  display: grid;
  gap: var(--s-2);
}
.bcd-field label,
.bcd-fieldset legend {
  font-weight: 650;
}
.bcd-fieldset {
  border: 0;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0;
}
.bcd-fieldset legend {
  margin-bottom: var(--s-1);
  padding: 0;
}
.bcd-fieldset .bcd-choice {
  align-items: center;
}
.bcd-fieldset .bcd-choice input {
  margin: 0;
}
.bcd-field select,
.bcd-field input {
  width: 100%;
  max-width: 28rem;
  min-height: 48px;
  padding: var(--s-2) var(--s-3);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-btn);
  background: var(--card);
  color: var(--ink);
  font: inherit;
  font-size: var(--fs-0);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.bcd-field select:hover,
.bcd-field input:hover {
  border-color: var(--muted);
}
.bcd-field select:focus,
.bcd-field input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-wash);
}
/* A native select, styled: no system arrow; the wrapper draws a quiet chevron. */
.bcd-select {
  position: relative;
  display: block;
  max-width: 28rem;
}
.bcd-select::after {
  content: '';
  position: absolute;
  inset-inline-end: 18px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}
.bcd-field select {
  appearance: none;
  padding-inline-end: 44px;
  text-overflow: ellipsis;
}
.bcd-field input[aria-invalid='true'] {
  border-color: var(--accent);
  border-width: 2px;
}
.bcd-choice {
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
  min-height: var(--tap);
}
.bcd-choice input {
  flex: none;
  width: 24px;
  height: 24px;
  margin: 2px 0 0;
  accent-color: var(--accent);
}
.bcd-choice label {
  font-weight: 450;
}
.bcd-hint {
  color: var(--muted);
  font-size: var(--fs-sm);
  margin: 0;
}
.bcd-error {
  color: var(--accent-deep);
  font-weight: 650;
  margin: 0;
}
.bcd-status {
  color: var(--muted);
  font-size: var(--fs-sm);
  margin: 0 0 var(--s-4);
}
.bcd-notice {
  background: var(--accent-wash);
  border-inline-start: 4px solid var(--accent);
  border-radius: var(--r-btn);
  padding: var(--s-3) var(--s-4);
}
.bcd-notice p {
  margin: 0 0 var(--s-1);
}
.bcd-notice a {
  display: inline-flex;
  min-height: var(--tap);
  align-items: center;
  font-weight: 650;
}
.bcd-conflict {
  background: var(--calm-wash);
  border-radius: var(--r-btn);
  padding: var(--s-4);
}
.bcd-conflict p {
  margin-bottom: var(--s-2);
}
.bcd-link-button {
  justify-self: start;
  min-height: var(--tap);
  padding: 0;
  border: 0;
  background: none;
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 var(--s-5);
  border-radius: var(--r-btn);
  font-weight: 650;
  cursor: pointer;
}
.btn-primary {
  background: var(--accent);
  color: var(--card);
  border: 1px solid var(--accent);
}
.btn-primary:hover {
  background: var(--accent-deep);
}
.btn-secondary {
  background: var(--card);
  color: var(--accent-deep);
  border: 1px solid var(--line-strong);
}
.btn-secondary:hover {
  border-color: var(--accent);
}
.bcd-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
}
.bcd-result {
  margin-top: var(--s-6);
  padding-top: var(--s-5);
  border-top: 1px solid var(--line);
}
.bcd-result h2 {
  margin-top: 0;
}
.bcd-result-card {
  background: var(--accent-wash);
  border-radius: var(--r-card);
  padding: var(--s-5);
  margin-bottom: var(--s-5);
}
.bcd-result-card > .bcd-meta:first-child,
.bcd-result-card > .bcd-eyebrow + .bcd-meta {
  font-weight: 650;
  color: var(--accent-deep);
  margin-bottom: var(--s-2);
}
.bcd-big-date {
  margin: 0 0 var(--s-3);
  line-height: var(--lh-tight);
}
.bcd-weekday {
  display: block;
  font-size: var(--fs-sm);
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.bcd-big-date time {
  display: block;
  font-size: var(--fs-3);
  font-weight: 750;
  letter-spacing: -0.02em;
}
.bcd-meta {
  margin: 0 0 var(--s-1);
  color: var(--ink);
}
.bcd-past {
  margin: var(--s-3) 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-3);
  align-items: center;
}
.bcd-past-tag {
  font-size: var(--fs-sm);
  font-weight: 650;
  color: var(--muted);
}
/* The headline's eyebrow ("Next") and its relation to the list. */
.bcd-eyebrow {
  margin: 0 0 var(--s-1);
  font-size: var(--fs-sm);
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.bcd-note {
  margin: var(--s-2) 0 0;
  font-size: var(--fs-sm);
  color: var(--muted);
}
/* The result list: stacked rows (a date token, the label, a quiet past tag), grouped by cycle / pack. */
.bcd-group {
  margin: 0 0 var(--s-5);
}
.bcd-group-h {
  margin: 0 0 var(--s-2);
  font-size: var(--fs-sm);
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.bcd-rows {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: var(--s-2);
}
.bcd-row {
  display: flex;
  align-items: center;
  gap: var(--s-4);
  margin: 0;
  padding: var(--s-2) var(--s-3);
  background: var(--paper);
  border-radius: var(--r-btn);
}
.bcd-row[data-state='bcd-past'] {
  background: none;
  color: var(--muted);
  padding-block: var(--s-1);
}
.bcd-token {
  flex: none;
  display: grid;
  justify-items: center;
  width: 3.5rem;
  padding: var(--s-1) 0;
  border-radius: var(--r-btn);
  background: var(--accent-wash);
  color: var(--accent-deep);
  line-height: 1.15;
}
.bcd-row[data-state='bcd-past'] .bcd-token {
  background: var(--calm-wash);
  color: var(--muted);
}
.bcd-token-wd,
.bcd-token-m {
  font-size: 0.72rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.bcd-token-d {
  font-size: var(--fs-1);
  font-weight: 750;
}
.bcd-row-main {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.bcd-row-label {
  font-weight: 600;
  line-height: 1.35;
}
.bcd-row-sub {
  font-size: var(--fs-sm);
  color: var(--muted);
}
.bcd-row-past {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
}
/* The decorative calendar (aria-hidden; the list is the source of truth; never printed). */
.bcd-cal {
  margin: 0 0 var(--s-5);
}
.bcd-cal-months {
  display: flex;
  gap: var(--s-3);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: var(--s-2);
}
.bcd-cal-month {
  flex: 0 0 min(82%, 17rem);
  scroll-snap-align: start;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: var(--s-3);
}
.bcd-cal-title {
  margin: 0 0 var(--s-2);
  text-align: center;
  font-size: var(--fs-sm);
  font-weight: 650;
}
.bcd-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  text-align: center;
  font-size: 0.8rem;
}
.bcd-cal-h {
  color: var(--muted);
  font-weight: 600;
  padding-bottom: 2px;
}
.bcd-cal-d {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1;
  border-radius: 50%;
}
.bcd-cal-d[data-mark='range'] {
  background: var(--accent-wash);
  border-radius: 6px;
}
.bcd-cal-d[data-mark='date'] {
  background: var(--accent);
  color: var(--card);
  font-weight: 700;
}
.bcd-cal-d[data-today] {
  box-shadow: inset 0 0 0 2px var(--ink);
}
.bcd-cal-legend {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-1) var(--s-4);
  padding: 0;
  margin: var(--s-2) 0 0;
  font-size: var(--fs-sm);
  color: var(--muted);
}
.bcd-cal-legend li {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
}
.bcd-cal-legend li::before {
  content: '';
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.bcd-cal-legend [data-mark='date']::before {
  background: var(--accent);
}
.bcd-cal-legend [data-mark='range']::before {
  background: var(--accent-wash);
  border-radius: 3px;
}
.bcd-cal-legend [data-today]::before {
  box-shadow: inset 0 0 0 2px var(--ink);
}
/* Desktop (T4): inputs left, results right; the page column lines up with the header. */
@media (min-width: 1024px) {
  .bcd-app {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    column-gap: var(--s-7);
    align-items: start;
  }
  .bcd-app > * {
    grid-column: 2;
  }
  .bcd-app > .bcd-status {
    grid-column: 1 / -1;
    grid-row: 1;
  }
  .bcd-app > .bcd-form {
    grid-column: 1;
    grid-row: 2 / span 3;
  }
  .bcd-app > .bcd-result {
    grid-row: 2;
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
  }
  .bcd-app > .bcd-refusals {
    grid-row: 3;
  }
  .bcd-app > .bcd-result:not([hidden]) ~ .bcd-refusals {
    margin-top: 0;
  }
  .bcd-app > .bcd-memory {
    grid-row: 4;
  }
  .bcd-cal-month {
    flex-basis: calc(50% - var(--s-3) / 2);
  }
}
.bcd-table {
  overflow-x: auto;
  margin: 0 0 var(--s-4);
  border: 1px solid var(--line);
  border-radius: var(--r-btn);
}
.bcd-facts {
  background: var(--calm-wash);
  border-radius: var(--r-btn);
  padding: var(--s-3) var(--s-4);
}
.bcd-facts h3 {
  margin-top: 0;
}
.bcd-facts ul {
  margin: 0;
}
.bcd-label-discreet,
.bcd-print-only {
  display: none;
}
.bcd-refusals,
.bcd-memory {
  margin-top: var(--s-5);
}
.bcd-refusals {
  border: 1px solid var(--line);
  border-radius: var(--r-btn);
  padding: 0 var(--s-4);
}
.bcd-refusals summary {
  display: flex;
  align-items: center;
  min-height: var(--tap);
  font-weight: 650;
}
.bcd-refusals[open] {
  padding-bottom: var(--s-3);
}
.bcd-memory {
  display: grid;
  gap: var(--s-2);
  padding-top: var(--s-4);
  border-top: 1px solid var(--line);
}
.bcd-memory .btn {
  justify-self: start;
}
.bcd-memory-list {
  margin: 0;
}
.bcd-live {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.bcd-dialog {
  max-width: min(36rem, calc(100vw - 2 * var(--s-4)));
  border: 0;
  border-radius: var(--r-card);
  box-shadow: var(--shadow-2);
  padding: var(--s-5);
}
.bcd-dialog::backdrop {
  background: var(--shadow-color-strong);
}
.bcd-dialog h2 {
  margin-top: 0;
}
.bcd-dialog-list {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: var(--s-2) var(--s-4);
  font-size: var(--fs-sm);
  margin: var(--s-4) 0;
}
.bcd-dialog-list dt {
  font-weight: 650;
}
.bcd-dialog-list dd {
  margin: 0;
  overflow-wrap: anywhere;
}
@media (max-width: 480px) {
  .bcd-dialog-list {
    grid-template-columns: 1fr;
  }
}
.bcd-notes {
  font-size: var(--fs-sm);
  color: var(--muted);
}
/*
 * Design round 3 (r2 panel): lighter type, compact past rows, one marker per
 * event type, fewer boxes, months that wrap instead of a clipped carousel,
 * a sticky form column on desktop.
 */
/* R3-1: secondary labels regular; the heading and the Next action keep priority. */
.bcd-field label,
.bcd-fieldset legend {
  font-weight: 550;
}
.bcd-row-label {
  font-weight: 450;
}
.bcd-eyebrow,
.bcd-group-h {
  font-weight: 550;
}
.bcd-big-date time {
  font-size: var(--fs-2);
  font-weight: 700;
}
.bcd-token-d {
  font-weight: 650;
}
.bcd-result h2 {
  font-weight: 650;
}
/* R3-2: a past row is one muted line: a small date, the label, a quiet "Passed". */
.bcd-row[data-state='bcd-past'] .bcd-token {
  display: flex;
  gap: var(--s-1);
  width: auto;
  min-width: 3.5rem;
  padding: 0;
  background: none;
  color: var(--muted);
  font-size: var(--fs-sm);
}
.bcd-row[data-state='bcd-past'] .bcd-token > * {
  font-size: var(--fs-sm);
  font-weight: 450;
  text-transform: none;
  letter-spacing: 0;
}
.bcd-row[data-state='bcd-past'] .bcd-row-label,
.bcd-row[data-state='bcd-past'] .bcd-row-sub {
  font-size: var(--fs-sm);
}
.bcd-row-past {
  margin-inline-start: auto;
  font-size: 0.75rem;
  font-weight: 500;
}
/* R3-3: one restrained marker per event type (the legend names them with the list's labels). */
.bcd-cal-d[data-mark='start'] {
  background: var(--accent);
  color: var(--card);
  font-weight: 650;
}
.bcd-cal-d[data-mark='step'] {
  box-shadow: inset 0 0 0 2px var(--accent);
  color: var(--accent-deep);
  font-weight: 650;
}
.bcd-cal-d[data-mark='end'] {
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-weight: 650;
  border-radius: 6px;
}
.bcd-cal-d[data-mark='range'] {
  background: var(--calm-wash);
  border-radius: 6px;
}
.bcd-cal-d[data-today] {
  box-shadow: none;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}
.bcd-cal-d[data-mark='step'][data-today] {
  box-shadow: inset 0 0 0 2px var(--accent);
}
.bcd-cal-legend [data-mark='start']::before {
  background: var(--accent);
}
.bcd-cal-legend [data-mark='step']::before {
  box-shadow: inset 0 0 0 2px var(--accent);
}
.bcd-cal-legend [data-mark='end']::before {
  background: var(--accent-soft);
  border-radius: 3px;
}
.bcd-cal-legend [data-mark='range']::before {
  background: var(--calm-wash);
  border-radius: 3px;
}
.bcd-cal-legend [data-today]::before {
  box-shadow: none;
  width: 12px;
  height: 2px;
  border-radius: 0;
  background: var(--ink);
}
.bcd-cal-legend li {
  align-items: baseline;
}
.bcd-cal-legend li::before {
  flex: none;
  align-self: center;
}
/* R3-4 + R3-6: months wrap in a grid (no clipped carousel, nothing focusable), on soft backgrounds, no borders. */
.bcd-cal-months {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(8.5rem, 1fr));
  gap: var(--s-3);
  overflow: visible;
  padding-bottom: 0;
}
.bcd-cal-month,
.bcd-app > .bcd-result .bcd-cal-month {
  width: auto;
  flex-basis: auto;
  border: 0;
  background: var(--paper);
  padding: var(--s-2);
}
.bcd-cal-grid {
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 1px;
  font-size: 0.72rem;
}
.bcd-cal-month {
  min-width: 0;
  overflow: hidden;
}
.bcd-refusals {
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  padding: 0;
}
@media (min-width: 1024px) {
  .bcd-cal-months {
    grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
  }
}
/* The form is not sticky (round-4 decision N1): it scrolls with the page at every size, so its own button can never be hidden. */
/*
 * Design round 4 (the final round; r3 panel): one full-width month per row on
 * phones with bigger cells, a compact legend above the calendar, "today" as a
 * dot that never collides with an event ring, lighter result padding, and on
 * desktop a 5/12 + 7/12 split with the form as the one card.
 */
/* M2: the legend is a short key above the months. */
.bcd-cal-legend {
  margin: 0 0 var(--s-3);
  gap: var(--s-1) var(--s-4);
}
@media (max-width: 719px) {
  .bcd-cal-legend {
    flex-direction: column;
    gap: var(--s-1);
  }
}
/* M1: one month per row on phones; bigger cells with room around the numerals. */
@media (max-width: 719px) {
  .bcd-cal-months {
    grid-template-columns: minmax(0, 1fr);
  }
  .bcd-cal-month {
    padding: var(--s-3);
  }
  .bcd-cal-grid {
    gap: var(--s-1);
    font-size: 0.9rem;
  }
}
.bcd-cal-d {
  position: relative;
}
/* Today: a small dot under the number (never an outline that meets an event ring). */
.bcd-cal-d[data-today],
.bcd-cal-d[data-mark='step'][data-today] {
  text-decoration: none;
}
.bcd-cal-d[data-mark='step'][data-today] {
  box-shadow: inset 0 0 0 2px var(--accent);
}
.bcd-cal-d[data-today]::after {
  content: '';
  position: absolute;
  bottom: 12%;
  left: 50%;
  width: 4px;
  height: 4px;
  margin-left: -2px;
  border-radius: 50%;
  background: currentColor;
}
.bcd-cal-legend [data-today]::before {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ink);
  margin-inline: 3px;
}
/* M4: lighter result padding; clear space between the Next card and the calendar. */
.bcd-result-card {
  padding: var(--s-4) var(--s-5);
  margin-bottom: var(--s-6);
}
.bcd-result h2 {
  margin-bottom: var(--s-3);
}
/* D1: form labels medium, not bold (H1, then section heads, then labels, then help text). */
.bcd-field label,
.bcd-fieldset legend {
  font-weight: 500;
}
@media (min-width: 1024px) {
  /* D2: 5/12 + 7/12; the form is the tool's one card, so no blank panel runs on under it. */
  .tool[data-tool] {
    background: none;
    border: 0;
    box-shadow: none;
    padding: 0;
  }
  .bcd-app {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    column-gap: var(--s-7);
  }
  .bcd-app > .bcd-form {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--r-card);
    box-shadow: var(--shadow-1);
    padding: var(--s-6);
  }
  .bcd-app > .bcd-result,
  .bcd-app > .bcd-refusals,
  .bcd-app > .bcd-memory {
    padding-top: var(--s-2);
  }
  /* On the page's paper, the soft fills become white. */
  .bcd-row,
  .bcd-cal-month {
    background: var(--card);
  }
  .bcd-row[data-state='bcd-past'] {
    background: none;
  }
  /* D3: two months per row at most, bigger cells. */
  .bcd-cal-months {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--s-4);
  }
  .bcd-cal-month {
    padding: var(--s-4);
  }
  .bcd-cal-grid {
    gap: var(--s-1);
    font-size: 0.85rem;
  }
}
/* Round-4 decision N1: from 720 px, two months per row at most (no narrow three-up grid). */
@media (min-width: 720px) {
  .bcd-cal-months {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
/* SPEC §3.8 (claim review e): a withheld product's official label link (cloned from the page's hidden list). */
.tool-official {
  display: none;
}
.bcd-status a,
.bcd-notice a[data-product] {
  overflow-wrap: anywhere;
}
/* The lead's readability call: the shading is visible on cream and white, with a hatch as a non-colour cue. */
.bcd-cal-d[data-mark='range'],
.bcd-cal-legend [data-mark='range']::before {
  background: repeating-linear-gradient(135deg, var(--hatch) 0 2px, var(--line) 2px 6px);
}
/* The hatch key beside a day marker on one legend line. */
.bcd-cal-key {
  flex: none;
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: repeating-linear-gradient(135deg, var(--hatch) 0 2px, var(--line) 2px 6px);
}
.bcd-status ul {
  margin: var(--s-1) 0 0;
}

/*
 * Print: black on white; the discreet default (SPEC §3.9): only the dates,
 * under "Reminder dates", every method word shown as "Reminder". With the
 * export dialog's "descriptive titles" ticked, the method words print too.
 */
@media print {
  /* No browser header or footer: they would print the page title and address, which name the method (C3-3). */
  @page {
    margin: 0;
  }
  body {
    padding: 0;
    background: var(--card);
    font-size: 12pt;
  }
  /*
   * With no page margin, the content keeps its own (D3): at least 12 mm on
   * every printed page, repeated on each page fragment (clone), so a date row
   * never starts at the paper's edge where a printer may clip it.
   */
  .main {
    padding: 12mm 15mm !important;
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
  }
  .top,
  .foot,
  .crumbs,
  .lady,
  .skip,
  .help-line,
  .trust-strip,
  .tool-msg,
  .article > :not(.tool),
  .article > h1,
  .lead,
  .bcd-app > :not(.bcd-result),
  .bcd-result .bcd-actions,
  .bcd-result h2,
  .bcd-facts,
  .bcd-dialog,
  .bcd-cal,
  .bcd-now,
  .review-statement {
    display: none !important;
  }
  .tool,
  .bcd-result-card {
    border: 0;
    box-shadow: none;
    padding: 0;
    background: var(--card);
  }
  .bcd-print-only {
    display: block;
    font-weight: 700;
    font-size: 16pt;
  }
  .bcd-label-full {
    display: none;
  }
  .bcd-label-discreet {
    display: inline;
  }
  [data-descriptive] .bcd-label-full {
    display: inline;
  }
  [data-descriptive] .bcd-label-discreet {
    display: none;
  }
  a {
    color: var(--ink);
    text-decoration: none;
  }
}
