/* @purpose Public-face node style for JSLC estate modules (Briefings, Eretzdex, Markets).
 * Design basis: cobalt CLAUDE_DESIGN.md §3-§7 and design-submissions/00_SYSTEM.md.
 * Minimal, phone first, edge to edge under the shell bar, no title band (the shell signpost
 * carries the path), bold lede + quiet subline rows, detail in a glass side drawer.
 * Tokens mirror jslc.io shell-tokens.css (§5); light is the default, dark follows the shell. */
:root {
  --paper: #f6f7fa; --card: #ffffff; --ink: #111a2d; --muted: #536078; --rule: #8193bc;
  --line: rgba(17, 26, 45, .12); --cobalt: #002eac; --accent-subtle: rgba(0, 46, 172, .09);
  --glass: rgba(246, 247, 250, .74); --glass-solid: rgba(246, 247, 250, .96); --glass-line: rgba(17, 26, 45, .14);
  --scrim: rgba(4, 16, 46, .35);
  --font: Arial, Helvetica, sans-serif;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --paper: #0b1324; --card: #0f1d37; --ink: #f3f6ff; --muted: #b3bfd8; --rule: #465c8f;
  --line: rgba(243, 246, 255, .12); --cobalt: #93b4ff; --accent-subtle: rgba(147, 180, 255, .16);
  --glass: rgba(11, 19, 36, .74); --glass-solid: rgba(11, 19, 36, .96); --glass-line: rgba(243, 246, 255, .14);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]):not(.embedded) {
    --paper: #0b1324; --card: #0f1d37; --ink: #f3f6ff; --muted: #b3bfd8; --rule: #465c8f;
    --line: rgba(243, 246, 255, .12); --cobalt: #93b4ff; --accent-subtle: rgba(147, 180, 255, .16);
    --glass: rgba(11, 19, 36, .74); --glass-solid: rgba(11, 19, 36, .96); --glass-line: rgba(243, 246, 255, .14);
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100dvh; }
body {
  background: var(--paper); color: var(--ink);
  font: 400 13px/1.5 var(--font); -webkit-font-smoothing: antialiased;
  padding: 12px calc(max(12px, env(safe-area-inset-right)) + var(--overlay-right, 0px)) max(16px, env(safe-area-inset-bottom)) calc(max(12px, env(safe-area-inset-left)) + var(--overlay-left, 0px));
  transition: padding .28s cubic-bezier(.32, .72, 0, 1);
}
@media (prefers-reduced-motion: reduce) { body { transition: none; } }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--cobalt); outline-offset: 2px; }

/* Page head: eyebrow, 20px title, one-line lede. No band. */
.head { margin: 0 0 10px; }
.eyebrow { margin: 0; color: var(--muted); font: 700 8.75px/1.3 var(--font); letter-spacing: .08em; text-transform: uppercase; }
.title { margin: 2px 0 0; font-size: 20px; line-height: 1.25; font-weight: 700; }
.lede { margin: 2px 0 0; color: var(--muted); font-size: 12.5px; }
/* Inside a shell the 10px signpost already carries the path; drop the eyebrow to save vertical space. */
.embedded .head .eyebrow { display: none; }

/* Rows: bold lede, quiet subline, state word, chevron. 1px rules, no cards. */
.rows { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.row {
  display: grid; grid-template-columns: 1fr auto 14px; align-items: center; gap: 2px 10px;
  width: 100%; min-height: 44px; padding: 8px 2px; border: 0; border-bottom: 1px solid var(--line);
  background: none; text-align: left; cursor: pointer;
}
.row:hover { background: var(--accent-subtle); }
.row .l { font-weight: 700; font-size: 13px; }
.row .s { grid-column: 1; color: var(--muted); font-size: 11.5px; }
.row .w { grid-row: 1 / span 2; grid-column: 2; color: var(--muted); font-size: 11px; white-space: nowrap; }
.row .c { grid-row: 1 / span 2; grid-column: 3; width: 8px; height: 8px; border-top: 1.5px solid var(--muted); border-right: 1.5px solid var(--muted); transform: rotate(45deg); }

/* Side drawer: a glass overlay from the right, content-sized, never layout.
 * Phone: up to 90% width with a scrim. Tablet and desktop: 320px, no scrim. */
.scrim { position: fixed; inset: 0; z-index: 20; background: var(--scrim); opacity: 0; pointer-events: none; transition: opacity .2s; }
.scrim.on { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; z-index: 21; top: max(8px, env(safe-area-inset-top)); right: max(8px, env(safe-area-inset-right));
  width: min(90vw, 320px); max-height: calc(100dvh - 16px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
  display: flex; flex-direction: column; overflow: hidden;
  border: 1px solid var(--glass-line); border-radius: 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, .22);
  background: var(--glass); -webkit-backdrop-filter: blur(18px) saturate(150%); backdrop-filter: blur(18px) saturate(150%);
  transform: translateX(calc(100% + 24px)); transition: transform .28s cubic-bezier(.32, .72, 0, 1); visibility: hidden;
}
.drawer.on { transform: none; visibility: visible; }
@media (prefers-reduced-transparency: reduce) { .drawer { background: var(--glass-solid); -webkit-backdrop-filter: none; backdrop-filter: none; } }
@media (min-width: 760px) { .scrim { display: none; } }
.drawer .dh { display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px 8px 14px; border-bottom: 1px solid var(--line); }
.drawer .dh > div { flex: 1; min-width: 0; }
.drawer .dt { margin: 2px 0 0; font-size: 15px; font-weight: 700; line-height: 1.3; }
.drawer .x {
  position: relative; flex: none; width: 26px; height: 26px; border: 0; border-radius: 50%;
  background: color-mix(in srgb, var(--ink) 8%, transparent); color: var(--muted); font: 700 12px/1 var(--font); cursor: pointer;
}
.drawer .x::after { content: ""; position: absolute; inset: -9px; }
.drawer .db { padding: 10px 14px 14px; overflow-y: auto; overscroll-behavior: contain; }
.drawer .db p { margin: 0 0 8px; font-size: 12.5px; }
.drawer .db .note { color: var(--muted); font-size: 11.5px; }
@media (prefers-reduced-motion: reduce) { .drawer, .scrim { transition: none; } }
