/* Shared law and article reader design. Legal content remains unchanged. */
body.mley-reader-design {
  --reader-blue: #2454bd;
  --reader-ink: #20313f;
  --reader-muted: #63717e;
  --reader-border: #dfe5eb;
  --reader-link: #2454bd;
  --reader-background: #f4f6f8;
  --reader-surface: var(--bg-surface);
  --reader-soft: var(--bg-surface-2);
  --reader-hover: var(--bg-surface-3);
  --reader-disabled: var(--text-subtle);
  --reader-focus: #adc6ff;
  --reader-shadow: 0 5px 22px rgba(26, 44, 66, .045);
  --reader-font: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--reader-background);
}
:root[data-theme="dark"] body.mley-reader-design {
  --reader-ink: var(--text-color);
  --reader-muted: var(--text-muted);
  --reader-border: var(--border-color);
  --reader-link: var(--accent-color);
  --reader-background: var(--bg-body);
  --reader-focus: var(--accent-color);
  --reader-shadow: var(--shadow-card);
}
body.mley-reader-design #contain_id {
  max-width: 1120px;
  padding-inline: clamp(16px, 3vw, 40px);
  padding-bottom: 100px;
  color: var(--reader-ink);
  font-family: var(--reader-font);
}
body.mley-reader-design #contain_id :is(.card, .mley-article-footer) {
  border: 1px solid var(--reader-border);
  border-radius: 22px;
  background: var(--reader-surface);
  color: var(--reader-ink);
  box-shadow: var(--reader-shadow);
}
body.mley-reader-design #contain_id .card > .card-body {
  padding: clamp(22px, 3vw, 36px);
}
body.mley-reader-design #contain_id .card { margin-bottom: 20px; }
body.mley-reader-design #contain_id :is(h1,h2,h3,h4,h5,h6,p,a,button,input,select,summary) {
  font-family: var(--reader-font);
}
body.mley-reader-design #contain_id > .mley-breadcrumbs-shell .mley-breadcrumbs {
  gap: 6px;
  margin: 12px 0 20px !important;
  padding: 0 4px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  font-size: 13px;
  line-height: 1.6;
}
body.mley-reader-design #contain_id > .mley-breadcrumbs-shell .breadcrumb-item :is(a,span) { color: var(--reader-muted); }
body.mley-reader-design #contain_id > .mley-breadcrumbs-shell .breadcrumb-item.active { color: var(--reader-ink); }
body.mley-reader-design #contain_id .mley-law-search-card {
  --search-accent: var(--reader-link);
  --search-accent-hover: var(--reader-link);
  --search-ink: var(--reader-ink);
  --search-muted: var(--reader-muted);
  --search-border: var(--reader-border);
  --search-surface: var(--reader-surface);
  --search-ring: rgba(36,84,189,.12);
}
body.mley-reader-design #contain_id .mley-law-search-card .mley-search-submit {
  --search-accent: var(--reader-blue);
  --search-accent-hover: #193f95;
  color: #fff !important;
}
body.mley-reader-design #contain_id .mley-law-search-card > .card-body { padding: 0; }
body.mley-reader-design #contain_id .mley-law-search-card { padding: clamp(22px, 3vw, 36px); }
body.mley-reader-design #contain_id .mley-law-search-name { max-height: none; }
body.mley-reader-design #contain_id :is(.mley-law-search-card,.mley-reader-heading) .mley-home-logo-mark {
  background: var(--reader-blue);
  color: #fff;
}
body.mley-reader-design #contain_id .mley-law-search-key { padding: 4px 9px; background: var(--reader-soft); }
body.mley-reader-design #contain_id .mley-law-search-navigation a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 13px;
  color: var(--reader-link);
  text-decoration: none;
}
body.mley-reader-design #contain_id .mley-law-search-navigation a:hover { text-decoration: underline; }
body.mley-reader-design #contain_id .mley-law-search-map { margin-top: 20px; padding-top: 4px; }
body.mley-reader-design #contain_id .mley-law-search-map__hint { font-size: 12px; }
body.mley-reader-design #contain_id .mley-detail-block {
  padding: 22px 30px;
  border-radius: 18px;
  margin-bottom: 12px;
}
body.mley-reader-design #contain_id .mley-detail-block h5 { margin: 0; font-size: 16px; line-height: 1.65; }
body.mley-reader-design #contain_id .article {
  font-size: 17px;
  line-height: 1.85;
}
body.mley-reader-design #contain_id .mley-detail-article-card {
  padding: clamp(22px, 3vw, 36px);
}
body.mley-reader-design #contain_id .article p { font-size: inherit; line-height: inherit; }
body.mley-reader-design #contain_id .article p.text-right:empty { display: none; }
body.mley-reader-design #contain_id .badge-primary {
  background: var(--reader-blue) !important;
  color: #fff !important;
  border: 1px solid var(--reader-blue);
  padding: 7px 12px;
  box-shadow: none;
  font-size: 14px !important;
  font-weight: 650 !important;
  vertical-align: baseline;
}
body.mley-reader-design #contain_id .mley-article-card-footer {
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid var(--reader-border);
  gap: 12px;
}
body.mley-reader-design #contain_id .mley-article-card-footer .badge-light {
  padding: 7px 11px;
  border: 1px solid var(--reader-border);
  background: var(--reader-surface);
  color: var(--reader-muted);
  font-size: 12px;
  font-weight: 500;
  box-shadow: none;
}
body.mley-reader-design #contain_id .mley-article-card-footer .mley-share-trigger {
  min-height: 40px;
  border-radius: 10px;
  color: var(--reader-link);
}
body.mley-reader-design #contain_id .mley-reader-heading { display: block; padding: clamp(22px, 3vw, 36px); }
.mley-reader-heading__eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  color: var(--reader-link);
  font-size: 10px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: .13em;
  text-transform: uppercase;
}
.mley-reader-heading__mark {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 23px;
  padding-right: 7px;
  background: var(--reader-blue);
  color: #fff;
  clip-path: polygon(0 0,78% 0,100% 50%,78% 100%,0 100%);
  font-size: 16px;
  font-weight: 900;
  letter-spacing: -.05em;
  text-transform: none;
}
.mley-reader-heading__text { display: grid !important; grid-template-columns: minmax(0,1fr) auto; gap: 0 20px; width: 100%; }
.mley-reader-heading__text > :is(h1,p) { grid-column: 1; }
.mley-reader-heading__text > .mley-view-pdf-action { grid-column: 2; grid-row: 1 / 3; align-self: center; }
body.mley-reader-design #contain_id .mley-reader-heading h1 {
  margin: 0 0 7px;
  color: var(--reader-ink);
  font-size: clamp(28px, 2.8vw, 37px);
  font-weight: 650;
  letter-spacing: -.035em;
  line-height: 1.2;
}
.mley-reader-heading__law { margin: 0; color: var(--reader-muted); font-size: 15px; line-height: 1.6; }
body.mley-reader-design #contain_id .mley-reader-heading .mley-view-pdf {
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid var(--reader-blue);
  border-radius: 11px;
  background: var(--reader-blue);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: none;
}
.mley-reader-heading__nav { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 25px; padding-top: 14px; border-top: 1px solid var(--reader-border); }
.mley-reader-heading__nav > :is(a,span) {
  display: inline-flex; align-items: center; gap: 8px; min-height: 40px;
  padding: 8px 12px; border: 1px solid transparent; border-radius: 9px;
  color: var(--reader-muted); font-size: 13px; font-weight: 550; text-decoration: none;
}
.mley-reader-heading__nav a:hover { background: var(--reader-hover); color: var(--reader-link); }
.mley-reader-heading__nav > [aria-disabled="true"] { color: var(--reader-disabled); }
.mley-reader-heading__nav a:nth-child(2) { color: var(--reader-link); margin-inline: auto; }
body.mley-reader-design #contain_id .mley-article-graph .card-body { padding: 25px 30px; }
body.mley-reader-design #contain_id .mley-article-graph h2 { color: var(--reader-ink); font-size: 19px; font-weight: 650; letter-spacing: -.02em; }
body.mley-reader-design #contain_id .article-graph-toolbar { display: flex; gap: 12px; margin-block: 16px; }
body.mley-reader-design #contain_id .article-graph-toolbar .btn {
  min-height: 40px; padding: 7px 14px; border: 1px solid var(--reader-border); border-radius: 9px !important;
  background: var(--reader-surface); color: var(--reader-muted); font-size: 13px; box-shadow: none;
}
body.mley-reader-design #contain_id .article-graph-view-switch { padding: 3px; background: var(--reader-soft); border: 0; border-radius: 11px; }
body.mley-reader-design #contain_id .article-graph-view-switch .btn { border-color: transparent; background: transparent; }
body.mley-reader-design #contain_id .article-graph-view-switch .btn[aria-pressed="true"] { background: var(--reader-surface); color: var(--reader-link); border-color: var(--reader-border); }
body.mley-reader-design #contain_id .mley-article-footer { padding: 22px 30px; }
body.mley-reader-design #contain_id .mley-article-footer__nav a { min-height: 44px; border: 1px solid var(--reader-border); border-radius: 10px; color: var(--reader-link); background: var(--reader-surface); font-size: 13px; }
body.mley-reader-design #contain_id .mley-article-footer__disclosure > summary { min-height: 52px; font-size: 14px; color: var(--reader-ink); }
body.mley-reader-design #contain_id :is(button,a,input,summary):focus-visible { outline: 3px solid var(--reader-focus); outline-offset: 3px; }
body.mley-reader-design #contain_id .mley-search-box input:focus-visible { outline: 0; }
@media (max-width: 600px) {
  body.mley-reader-design #contain_id { padding-inline: 12px; }
  body.mley-reader-design #contain_id :is(.card,.mley-article-footer) { border-radius: 18px; }
  body.mley-reader-design #contain_id .card > .card-body,
  body.mley-reader-design #contain_id .mley-article-graph .card-body,
  body.mley-reader-design #contain_id .mley-article-footer { padding: 22px 20px; }
  body.mley-reader-design #contain_id .mley-law-search-card > .card-body { padding: 0; }
  body.mley-reader-design #contain_id .article { font-size: 16px; line-height: 1.8; }
  .mley-reader-heading__text { grid-template-columns: minmax(0,1fr); }
  .mley-reader-heading__text > .mley-view-pdf-action { grid-column: 1; grid-row: 3; justify-self: start; margin-top: 16px; }
  .mley-reader-heading__nav { gap: 0; margin-top: 20px; }
  .mley-reader-heading__nav a { padding-inline: 8px; font-size: 12px; }
  .mley-reader-heading__eyebrow { margin-bottom: 15px; }
}
@media (prefers-reduced-motion: reduce) { body.mley-reader-design #contain_id * { scroll-behavior: auto; } }
