/* Shared citation-line styling for record-cite.js: the quiet "Source · Cite" metadata line
   under every minutes-derived record (public comment, official remarks) on /votes and /people.
   Selectors are written with two classes so they reliably beat the pages' own generic link-color
   rules (e.g. ".comment-meeting li a"), which otherwise outrank a single-class override. */

.comment-cite {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 4px 8px;
  margin: 4px 0 0;
  /* min-width: 0 -- as a flex item of a caller's own row (DataView's controls strip, on a
   * narrower page than this component's original callers), the default min-width: auto would
   * otherwise size this to its own widest un-wrapped content (the open citation panel's
   * permalink) before word-break gets a chance to reflow it, overflowing at phone width. */
  min-width: 0;
  max-width: 100%;
  color: var(--muted);
  font: .72rem/1.4 Arial, Helvetica, sans-serif;
  letter-spacing: .01em;
}

.comment-cite a.comment-cite-source {
  color: var(--muted);
  font-weight: 400;
  text-decoration: none;
}
.comment-cite a.comment-cite-source:hover,
.comment-cite a.comment-cite-source:focus-visible {
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}
/* The external-link arrow (added by external-links.js) stays, but lighter than its site-wide default. */
.comment-cite a.comment-cite-source.external-link::after,
.cite-panel a.cite-panel-link.external-link::after {
  font-weight: 400;
  opacity: .7;
}

/* The Cite icon-button: folds the old separate "Permalink" link into one disclosure control.
   A compact 24px pill (13px icon + small label) so it sits quietly beside "Source"; an invisible
   ::after band extends the tap target to 44px tall without making the pill look bigger. */
/* max-width:100% -- an inline-block's shrink-to-fit sizing can otherwise size to the citation
 * panel's widest unwrapped run (a long permalink with view state, e.g. DataView's ?v=... URL)
 * before word-break: break-all gets a chance to reflow it, overflowing at phone width. */
.cite-disclosure { display: inline-block; max-width: 100%; vertical-align: middle; }
.cite-disclosure > summary.cite-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 24px;
  min-width: 24px;
  padding: 1px 8px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  color: var(--accent-dark);
  font: 600 .72rem/1.2 Arial, Helvetica, sans-serif;
  cursor: pointer;
  list-style: none;
  user-select: none;
}
.cite-disclosure > summary.cite-toggle::after { content: ""; position: absolute; inset: -10px 0; }
.cite-disclosure > summary.cite-toggle::-webkit-details-marker { display: none; }
.cite-disclosure > summary.cite-toggle::marker { content: ""; }
.cite-disclosure > summary.cite-toggle:hover,
.cite-disclosure > summary.cite-toggle:focus-visible {
  border-color: var(--accent-dark);
}
.cite-toggle-label { font-size: .72rem; }
.cite-icon { width: 13px; height: 13px; flex: none; }

.cite-panel {
  display: grid;
  gap: 6px;
  width: 100%;
  margin: 6px 0 2px;
  padding: 10px 12px;
  border: 1px solid var(--rule);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font-size: .78rem;
  line-height: 1.5;
}
.cite-panel-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; margin: 0; min-width: 0; }
.cite-panel-label {
  flex: none;
  color: var(--muted);
  font-weight: 700;
  font-size: .66rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.cite-panel a.cite-panel-link { display: inline-block; min-width: 0; max-width: 100%; color: var(--accent-dark); word-break: break-all; }
.cite-panel-citation { min-width: 0; font-style: italic; color: var(--ink); }
.cite-copy {
  min-height: 32px;
  padding: 3px 10px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  background: transparent;
  color: var(--accent-dark);
  font: 600 .72rem Arial, Helvetica, sans-serif;
  cursor: pointer;
}
.cite-copy:hover, .cite-copy:focus-visible { border-color: var(--accent-dark); }
.cite-copy.is-done { border-color: var(--accent-dark); }
.cite-actions { display: inline-flex; flex-wrap: wrap; gap: 6px; }
/* One plain sentence under the rows, only when the link is a record's own share page. */
.cite-panel-hint { margin: 0; color: var(--muted); font-size: .72rem; }
