/* ============================================================
   PASSAGE by Khoshà — caselink.css
   Styles for the staff-side "Client case link" panel only
   (caselink.js). The client-facing page at /c/:token carries its own
   stylesheet, inline and nonced, from server/routes-caselink.js — it is
   served to people who have never loaded this app and must not depend
   on anything here.

   PREFIX: `ckl-`, not `cl-`. `.cl-*` is already taken by the client
   card in styles.css / mobile-lists.css (.cl-card, .cl-name, .cl-sub,
   .cl-journey …). Nothing collided today, but sharing a namespace with
   an unrelated component is how a future `.cl-name` in either file
   silently restyles the other — the same class of bug as the three
   token regexes that disagreed. A distinct prefix costs nothing.

   Every colour below is an existing KDS token from styles.css. Nothing
   new is introduced, and no rule here is written without the .ckl-
   prefix or the .ckl-panel scope, so this file cannot reach out and
   restyle anything that belongs to another screen.
   ============================================================ */

.ckl-panel { margin-top: 16px; }

/* ---- loading skeleton ---- */
.ckl-skel { display: flex; flex-direction: column; gap: 9px; }
.ckl-skel-bar {
  height: 13px; border-radius: 99px;
  background: linear-gradient(90deg, var(--bone-2) 0%, var(--bone) 50%, var(--bone-2) 100%);
  background-size: 200% 100%;
  animation: ckl-shimmer 1.3s ease-in-out infinite;
}
.ckl-skel-bar.short { width: 58%; }
@keyframes ckl-shimmer { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }

/* ---- copy ---- */
.ckl-blurb { font-size: 13.5px; color: var(--ink-soft); line-height: 1.65; margin-bottom: 14px; }
.ckl-note { font-size: 12.5px; color: var(--ink-faint); line-height: 1.6; margin-top: 12px; }
.ckl-err {
  font-size: 13px; line-height: 1.6; color: var(--red);
  background: rgba(140, 59, 46, .07); border: 1px solid rgba(140, 59, 46, .2);
  border-radius: 12px; padding: 11px 13px; margin-bottom: 12px;
}

/* ---- "has the client opened it?" ---- */
.ckl-status { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 13px; }
.ckl-when { font-size: 12px; color: var(--ink-faint); }

/* ---- the link itself ----
   Mobile-first: the input and the Copy button stack on a narrow screen
   so a 43-character token never forces the modal to scroll sideways. */
.ckl-urlrow { display: flex; flex-direction: column; gap: 8px; }
.ckl-url {
  flex: 1; min-width: 0; width: 100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12.5px; letter-spacing: -.01em;
  padding: 11px 13px; border: 1.5px solid var(--stroke); border-radius: 12px;
  background: var(--bone); color: var(--ink-soft);
  text-overflow: ellipsis; min-height: 44px;
}
.ckl-url:focus { outline: 3px solid var(--gold); outline-offset: 2px; }
.ckl-copy { flex: 0 0 auto; }
@media (min-width: 560px) {
  .ckl-urlrow { flex-direction: row; align-items: center; }
  .ckl-url { width: auto; }
}

.ckl-meta { font-size: 12px; color: var(--ink-faint); margin-top: 9px; }

/* ---- actions ---- */
.ckl-actions { display: flex; gap: 9px; flex-wrap: wrap; margin-top: 14px; align-items: center; }
.ckl-actions .btn { text-decoration: none; }
.ckl-danger { color: var(--red); }
.ckl-danger:hover { border-color: var(--red); color: var(--red); }

/* ---- the disclosure list ----
   An RCIC is professionally answerable for what this link publishes, so
   the two columns are deliberately blunt and always one click away.
   Collapsed by default: it is reassurance, not something to read twice. */
.ckl-disclose {
  margin-top: 14px; border: 1px solid var(--stroke-soft); border-radius: 14px;
  background: rgba(255, 255, 255, .5); overflow: hidden;
}
.ckl-disclose > summary {
  cursor: pointer; padding: 11px 14px; font-size: 12.5px; font-weight: 600;
  color: var(--gold-deep); list-style: none; min-height: 42px;
  display: flex; align-items: center; gap: 8px;
}
.ckl-disclose > summary::-webkit-details-marker { display: none; }
.ckl-disclose > summary::before {
  content: ""; width: 0; height: 0; flex: 0 0 auto;
  border-left: 5px solid currentColor; border-top: 4px solid transparent; border-bottom: 4px solid transparent;
  transition: transform .18s;
}
.ckl-disclose[open] > summary::before { transform: rotate(90deg); }
.ckl-disclose > summary:focus-visible { outline: 3px solid var(--gold); outline-offset: -3px; }

.ckl-disclose-body {
  display: grid; grid-template-columns: 1fr; gap: 14px;
  padding: 2px 14px 12px;
}
@media (min-width: 560px) { .ckl-disclose-body { grid-template-columns: 1fr 1fr; gap: 18px; } }
.ckl-disclose-col ul { margin: 7px 0 0; padding-left: 17px; }
.ckl-disclose-col li { font-size: 12.5px; color: var(--ink-soft); line-height: 1.55; margin-bottom: 3px; }
.ckl-yes, .ckl-no {
  font-size: 10px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase;
  padding: 3px 9px; border-radius: 99px;
}
.ckl-yes { background: rgba(30, 58, 51, .10); color: var(--green); }
.ckl-no { background: rgba(140, 59, 46, .10); color: var(--red); }
.ckl-disclose-warn {
  font-size: 12px; color: var(--ink-faint); line-height: 1.6;
  padding: 10px 14px; border-top: 1px solid var(--stroke-soft); background: var(--bone);
}
