/* Scoped reader layout; branding and typography remain in styles.css. */
.court-reader { padding-top: 24px; padding-bottom: 48px; color: #173d58; }
.court-reader h1 { font-size: clamp(26px, 3.6vw, 38px); line-height: 1.25; margin: 12px 0; }
.court-reader h2 { font-size: 22px; line-height: 1.3; }
.court-reader h3 { font-size: 18px; line-height: 1.4; }
.court-reader p { line-height: 1.65; }
.court-reader a { color: #174f78; }
.court-reader [hidden] { display: none !important; }
.court-preview { margin: 0 0 18px; padding: 10px 14px; background: #eaf3f9; border: 1px solid #ccdeeb; border-radius: 7px; font-size: 13px; }
.court-intro { max-width: 940px; margin-bottom: 24px; }
.court-intro h1 { font-size:clamp(16px,5vw,32px); font-weight:600; }
.court-intro h1 > span { display:block; }
.court-intro p { margin:0 0 12px; font-family:inherit; font-size:16px; font-weight:400; line-height:1.65; color:inherit; }
.court-classification { padding: 14px 18px; border-left: 3px solid #367ca9; background: #f3f7fa; }
.court-search-layout { display: grid; grid-template-columns: 300px minmax(0,1fr); gap: 30px; align-items: start; margin-top: 24px; }
.court-reader .court-filters { display: block; margin: 0; border: 1px solid #ccdeeb; border-radius: 10px; overflow: hidden; }
.court-filters > summary { display: flex; align-items: center; gap: 10px; list-style: none; padding: 18px; font-size: 15px; font-weight: 800; color: #174f78; cursor: pointer; }
.court-filters > summary > span { margin-left: auto; }
.court-filters > summary::-webkit-details-marker,.court-topic > summary::-webkit-details-marker { display: none; }
.court-filters > div { padding: 0 14px 16px; }
.court-filters .small { margin: 8px 4px 14px; font-size: 11px; line-height: 1.75; color: #52748b; }
.court-reader .court-topic { margin: 0; border: 0; border-top: 1px solid #dbe5ed; border-radius: 0; background: transparent; box-shadow: none; overflow: visible; }
.court-topic > summary { display: flex; align-items: center; gap: 10px; list-style: none; padding: 13px 8px; font-size: 12px; line-height: 1.6; font-weight: 700; cursor: pointer; }
.court-topic > summary > span:first-child { flex: 1; min-width: 0; }
.court-topic > summary::after { content: '⌄'; color: #367ca9; }
.court-topic[open] > summary::after { content: '⌃'; }
.court-topic > summary:hover { background: #e5eff5; }
.court-topic-count { flex-shrink: 0; min-width: 24px; padding: 1px 4px; border-radius: 5px; background: #e7eff4; color: #52748b; font-size: 11px; text-align: center; font-variant-numeric: tabular-nums; }
.court-topic > div { padding: 0 0 10px 12px; }
.court-topic-choice { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px; margin: 2px 0; border-radius: 6px; text-decoration: none; line-height: 1.6; font-size: 11px; }
.court-topic-choice:hover, .court-topic-choice.selected { background: #e2eef7; color: #123e5d; }
.court-topic-choice.selected { box-shadow: inset 3px 0 #367ca9; font-weight: 800; }
.court-results-column { min-width: 0; }
.court-parameters { padding: 18px; border: 1px solid #ccdeeb; border-radius: 10px; }
.court-parameters h2 { margin: 0 0 18px; font-size: 20px; }
.court-parameters > summary { display:flex; align-items:center; gap:12px; min-height:44px; cursor:pointer; list-style:none; }
.court-parameters > summary::-webkit-details-marker { display:none; }
.court-parameters > summary h2 { flex:1; margin:0; }
.court-parameters > summary::after { content:'⌄'; color:#367ca9; }
.court-parameters[open] > summary { margin-bottom:18px; }
.court-parameters[open] > summary::after { content:'⌃'; }
.court-parameter-fields { display:grid; grid-template-columns:minmax(0,2fr) minmax(110px,.65fr) minmax(140px,1fr); gap:12px; }
.court-parameter-fields label { display: flex; flex-direction: column; gap: 8px; font-size: 13px; font-weight: 700; min-width: 0; }
.court-association-search { position:relative; min-width:0; }
.court-association-search [role="listbox"] { position:absolute; z-index:5; top:100%; left:0; right:0; margin:4px 0 0; padding:4px; max-height:280px; overflow-y:auto; list-style:none; background:#fff; border:1px solid #ccdeeb; border-radius:8px; box-shadow:0 4px 12px #173d5824; }
.court-association-search [role="option"] { display:flex; align-items:center; min-height:44px; padding:8px; font-size:13px; line-height:1.4; overflow-wrap:anywhere; cursor:pointer; }
.court-association-search [role="option"]:hover,.court-association-search [role="option"][aria-selected="true"] { background:#e2eef7; color:#123e5d; }
.court-parameter-fields input,.court-parameter-fields select { width: 100%; min-width: 0; min-height: 44px; padding: 10px; border: 1px solid #afc6d8; border-radius: 6px; font: inherit; background-color:#fefdf9; background-image:linear-gradient(#ffffffdf,#ffffffdf),url('/envelope-front-v3.jpg'); background-position:center; background-size:cover; color: #173d58; }
.court-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.court-parameter-form > .court-actions { margin-top:18px; }
.court-reader .outline { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; text-decoration: none; padding: 10px 16px; }
.court-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0; }
.court-chips:empty { margin: 0; }
.court-chips a { display: inline-flex; align-items: center; gap: 12px; padding: 8px 12px; background: #e2eef7; border: 1px solid #c2d7e6; border-radius: 18px; text-decoration: none; font-size: 13px; }
.court-results-head { margin: 24px 0 8px; }
.court-results-head h2 { margin-bottom: 8px; }
.court-results-head p { color: #52748b; font-size: 13px; }
.court-case-group { border: 1px solid #ccdeeb; border-radius: 10px; margin: 20px 0; overflow: hidden; }
.court-case-group > header { padding: 18px 20px 12px; }
.court-case-group,.court-case-group > header,.court-act-entry,.court-parameters,.court-reader .court-filters { background-color:#fbf8ef; background-image:linear-gradient(#ffffffb3,#ffffffb3),url('/envelope-front-v3.jpg'); background-position:center; background-size:cover; }
.court-card-topline { display:flex; align-items:flex-start; justify-content:space-between; gap:16px; }
.court-card-topline > .court-act-meta { margin:0; align-self:center; }
.court-case-stamp { display:inline-flex; flex-direction:column; align-self:center; gap:4px; min-width:0; min-height:44px; padding:7px 10px; border:3px double #9f3941a6; border-radius:2px; color:#9f3941; font:800 13px/1.35 'Courier New',monospace; letter-spacing:.3px; text-transform:uppercase; text-decoration:none; text-shadow:0 1px #fff,-.4px -.4px #64182433; box-shadow:inset 0 1px 2px #51442c24,0 1px #fff9; transform:rotate(-1deg); overflow-wrap:anywhere; }
.court-case-stamp small { font:inherit; font-size:11px; }
.court-case-stamp .court-source-link { text-decoration:underline; text-underline-offset:3px; text-transform:none; letter-spacing:0; }
.court-source-link > span { white-space:nowrap; }
.court-reader a.court-case-stamp { color:#9f3941; cursor:pointer; }
.court-reader a.court-case-stamp:is(:hover,:focus-visible) { color:#b52d39; border-color:#b52d39; background:#9f394112; }
.court-reader a.court-case-stamp:active { color:#752333; border-color:#752333; background:#9f39411a; box-shadow:inset 0 2px 3px #51442c33; transform:rotate(-1deg) translateY(1px); }
.court-card-shares { display:flex; flex-wrap:wrap; justify-content:flex-end; gap:8px; flex-shrink:0; max-width:60%; }
.court-card-shares .court-share { position:relative; padding:0; }
.court-case-group h3 { margin: 6px 0 12px; overflow-wrap: anywhere; }
.court-act-meta { display: block; font-size: 13px; color: #52748b; line-height: 1.5; }
.court-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.court-tags span { padding: 4px 9px; border-radius: 4px; background: #f0f5f9; font-size: 12px; }
.court-group-outcome { position:relative; z-index:1; margin:4px 0 0; padding:14px 20px; border-block:1px solid #ffffffd9; background-color:#fefdf9; background-image:linear-gradient(#ffffffdf,#ffffffdf),url('/envelope-front-v3.jpg'); background-position:center; background-size:cover; box-shadow:0 -2px 5px #51442c1a,0 2px 2px #51442c26,0 7px 12px #51442c33; }
.court-group-outcome h4 { margin: 0 0 8px; font-size: 13px; }
.court-group-outcome p { margin: 0; font-size: 14px; }
.court-act-entry { position: relative; }
.court-act { border-top: 0; }
.court-act-entry + .court-act-entry { border-top: 1px solid #ddd8ce; }
.court-act > summary { padding: 18px 20px; cursor: pointer; list-style: none; background: transparent; transition: background-color .16s ease; }
.court-act > summary::-webkit-details-marker { display: none; }
.court-act > summary:is(:hover, :focus-visible, :focus-within) { background-color: #173d581f; }
.court-act > summary:active { background-color: #173d5838; }
.court-act { scroll-margin-top: 145px; }
.court-act > summary { scroll-margin-top: 145px; }
.court-act-heading { font-size: 15px; font-weight: 700; line-height: 1.5; }
.court-read-action { display: flex; align-items: center; width: fit-content; min-height: 44px; margin-top: 12px; font-size: 17px; line-height: 1.4; font-weight: 800; color: #174f78; text-decoration: underline; text-underline-offset: 4px; }
.court-act-actions { display:flex; flex-wrap:wrap; align-items:flex-end; justify-content:space-between; gap:12px; margin-top:12px; }
.court-act-actions .court-read-action { margin-top:0; }
.court-instance-stamp { display:inline-flex; flex-direction:column; align-items:center; justify-content:center; gap:3px; margin-left:auto; max-width:100%; min-height:44px; padding:7px 10px; border:3px double #367459b3; border-radius:2px; color:#28634a; font:800 13px/1.35 'Courier New',monospace; letter-spacing:.3px; text-transform:uppercase; text-align:center; text-shadow:0 1px #fff,-.4px -.4px #163e2a33; box-shadow:inset 0 1px 2px #51442c24,0 1px #fff9; transform:rotate(-1deg); overflow-wrap:anywhere; }
.court-act-footer { display:flex; justify-content:flex-end; padding-top:20px; }
.court-act-body { padding: 0 20px 24px; background: #fff; }
.court-act-body section,.court-act-page section { margin: 24px 0; }
.court-prose { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.75; }
.court-material-language { background: #eaf3f9; padding: 12px 14px; font-size: 13px; border-radius: 6px; }
.court-quote { border: 1px solid #ccdeeb; border-radius: 6px; padding: 14px; }
.court-quote summary { cursor: pointer; font-weight: 700; }
.court-quote blockquote { margin: 16px 0 0; padding: 0 0 0 14px; border-left: 3px solid #9db9cd; }
.court-act-page { max-width: 900px; margin-top: 24px; }
.court-share { display:flex; flex-wrap:wrap; gap:10px; align-items:center; padding:12px 20px; font-size:13px; }
.court-site .court-share > button { background:#14578d; border:1px solid #14578d; color:#fff; font-weight:700; box-shadow:none; }
.court-site .court-share > button:hover { background:#1c6aa5; border-color:#1c6aa5; }
.court-share-link { overflow-wrap:anywhere; }
.court-card-shares .court-share-feedback { position:absolute; z-index:2; right:0; top:calc(100% + 8px); max-width:240px; width:max-content; }
.court-card-shares .court-share-feedback:has([role='status']:not(:empty)) { padding:8px 12px; border:1px solid #ccdeeb; border-radius:6px; background:#fff; }
.court-share-feedback a:not([hidden]) { display:block; margin-top:4px; }
.court-dialog-content > .court-share { justify-content:flex-end; }
.court-dialog { width:min(940px,calc(100% - 24px)); max-width:calc(100% - 24px); height:calc(100dvh - 24px); max-height:calc(100% - 24px); margin:auto; padding:0; overflow:hidden; border:1px solid #8aaec7; border-radius:12px; color:#173d58; background:#f7fbfe; }
.court-dialog[open] { display:flex; flex-direction:column; }
.court-dialog::backdrop { background:#102e48b3; }
.court-dialog-head { position:relative; min-height:60px; display:flex; align-items:center; justify-content:center; padding:8px 62px; border-bottom:1px solid #ccdeeb; background:#eaf3f9; }
.court-dialog-head h2 { margin:0; font-size:15px; line-height:1.4; text-align:center; }
.court-dialog-head button.outline { position:absolute; right:8px; top:50%; transform:translateY(-50%); min-width:44px; min-height:44px; width:44px; height:44px; padding:10px; font-size:26px; line-height:1; }
.court-dialog-content { flex:1; min-height:0; overflow:auto; }
.court-dialog-content .court-act-body { padding-top:16px; }
.court-dialog-tools { display:flex; flex-wrap:nowrap; align-items:center; justify-content:space-between; gap:8px; padding:8px 14px; border-bottom:1px solid #ccdeeb; }
.court-dialog-language-links { display:flex; flex-shrink:0; gap:6px; margin:0; padding:0; }
.court-dialog-tools .court-share { flex:0 1 auto; padding:0; justify-content:flex-end; }
.court-dialog-tools .court-share > button { padding:10px 12px; }
.court-pagination { gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.court-pagination a.outline { background: #fff; border: 1px solid #9dbbd0; border-radius: 4px; box-shadow: none; color: #174f78; font-size: 13px; }
.court-pagination [aria-disabled] { opacity: .55; }
.court-empty { padding: 24px; background: #fff; border: 1px solid #ccdeeb; border-radius: 10px; }
.court-reader :focus-visible,.court-site .language-controls a:focus-visible { outline: 3px solid #2876aa; outline-offset: 3px; }
.court-apply-mobile { display: none; }
.court-site .court-language-links a { min-width: 44px; min-height: 44px; padding: 10px; border: 1px solid #bed0de; border-radius: 6px; color: #174f78; font-weight: 700; text-align: center; text-decoration: none; }
.court-site .court-language-links a[aria-current] { background: #dcecf8; border-color: #367ca9; }
.court-skip { position: absolute; top: -100px; left: 16px; z-index: 10; }
.court-skip:focus { top: 10px; background: white; padding: 12px; }
@media (max-width: 1050px) {
  .court-search-layout { grid-template-columns: 265px minmax(0,1fr); gap: 20px; }
  .court-parameter-fields { grid-template-columns: 1fr 1fr; }
  .court-parameter-fields label:first-child { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .court-search-layout { display: block; }
  .court-reader { padding-top: 12px; }
  .court-reader .court-filters { margin-bottom: 18px; }
  .court-topic-choice { min-height:44px; font-size:12px; }
  .court-apply-mobile { display: inline-flex; margin-top: 14px; }
  .court-parameters { padding: 14px; }
  .court-parameter-fields { grid-template-columns:1fr; }
  .court-case-group > header,.court-act > summary { padding-left: 14px; padding-right: 14px; }
  .court-group-outcome { padding-left:14px; padding-right:14px; }
  .court-act-body { padding-left: 14px; padding-right: 14px; }
  .court-read-action { font-size:16px; }
}
@media (prefers-reduced-motion: reduce) {
  .court-act > summary { transition:none; }
}
