/* ARISAN — shared pieces added in the REF3 pass (Cofer / OpenBot / Olam teardown, 19 Nov 2026).
 * Header bar with CA pill + wallet/app button, technical-drawing labels ([ 01 / … ], FIG.),
 * crosshair corners, live chain dot. Palette stays "Afternoon Table".
 */

/* ---------- header bar (app.html) ---------- */
.bar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 14px;
  padding: 12px 20px; background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(8px); border-bottom: 1px solid var(--line);
}
.bar-brand { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font: 600 17px/1 var(--f-display); letter-spacing: .04em; }
.bar-nav { display: flex; gap: 2px; margin-left: 18px; }
.bar-nav a { text-decoration: none; font: 500 13.5px/1 var(--f-text); color: var(--ink-2); padding: 10px 11px; border-radius: 999px; transition: background .2s, color .2s; }
.bar-nav a:hover { background: var(--paper-2); color: var(--ink); }
.bar-nav a[aria-current="page"] { color: var(--ink); background: var(--paper-2); }
.bar .ca-pill { margin-left: auto; }

/* ---------- CA pill (header on every page) ---------- */
.ca-pill {
  display: inline-flex; align-items: center; gap: 8px; min-height: 36px;
  padding: 4px 6px 4px 12px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--paper-3); font: 500 12px/1 var(--f-mono); color: var(--ink-2); white-space: nowrap;
}
.ca-pill:empty { display: none; }
.ca-pill .ca-tick { color: var(--clay); font-weight: 600; }
.ca-pill .ca-soon { padding-right: 8px; }
.ca-pill .ca-addr { color: var(--ink); text-decoration: underline dotted; text-underline-offset: 3px; }
.ca-pill .ca-copy {
  font: 600 11.5px/1 var(--f-mono); border: 0; border-radius: 999px; padding: 8px 11px; cursor: pointer;
  background: var(--ink); color: var(--paper); transition: background .2s;
}
.ca-pill .ca-copy:hover { background: var(--clay); }
.ca-pill.is-live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--pine); box-shadow: 0 0 0 3px rgba(46,107,94,.18); }

/* ---------- wallet / app buttons ---------- */
.bar-wallet, .btn-app {
  display: inline-flex; align-items: center; gap: 8px; min-height: 40px;
  padding: 0 16px; border-radius: 999px; border: 1px solid var(--ink);
  background: var(--ink); color: var(--paper); font: 600 13.5px/1 var(--f-text);
  text-decoration: none; cursor: pointer; white-space: nowrap; transition: background .2s, border-color .2s, transform .15s;
}
.bar-wallet:hover, .btn-app:hover { background: var(--clay); border-color: var(--clay); }
.bar-wallet:active, .btn-app:active { transform: translateY(1px); }
.bar-wallet.is-on { background: var(--paper-3); color: var(--ink); border-color: var(--line); font-family: var(--f-mono); font-weight: 500; }
.bar-wallet.is-on::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--pine); }

/* ---------- technical-drawing labels ---------- */
.tag { display: inline-block; font: 500 11.5px/1 var(--f-mono); letter-spacing: .08em; color: var(--ink-2); text-transform: uppercase; }
.fig { font: 500 10.5px/1.3 var(--f-mono); letter-spacing: .1em; color: var(--ink-2); text-transform: uppercase; }
.mono { font-family: var(--f-mono); }
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--pine); box-shadow: 0 0 0 0 rgba(46,107,94,.5); animation: live-pulse 2.4s ease-out infinite; flex: none; }
@keyframes live-pulse { 0% { box-shadow: 0 0 0 0 rgba(46,107,94,.45); } 70%, 100% { box-shadow: 0 0 0 7px rgba(46,107,94,0); } }

/* crosshair corners: add .xh to any positioned box */
.xh { position: relative; }
.xh::before, .xh::after {
  content: "+"; position: absolute; font: 400 14px/1 var(--f-mono); color: var(--ink-2); opacity: .55; pointer-events: none;
}
.xh::before { top: 8px; left: 10px; }
.xh::after { bottom: 8px; right: 10px; }

/* status meta row (NETWORK / BLOCK / CONTRACT) */
.meta-row { display: flex; flex-wrap: wrap; gap: 0; border-top: 1px dashed var(--line); padding-top: 12px; }
.meta-row > div { padding: 0 16px; border-left: 1px solid var(--line); min-width: 0; }
.meta-row > div:first-child { padding-left: 0; border-left: 0; }
.meta-row dt { font: 500 10px/1 var(--f-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); margin-bottom: 6px; }
.meta-row dd { margin: 0; font: 500 12.5px/1.2 var(--f-mono); color: var(--ink); display: flex; align-items: center; gap: 6px; white-space: nowrap; }

@media (max-width: 760px) {
  .bar { flex-wrap: wrap; gap: 8px 10px; padding: 10px 16px; }
  .bar-nav { order: 3; width: 100%; margin-left: 0; justify-content: space-between; }
  .bar-nav a { padding: 11px 6px; font-size: 13px; }
  .bar .ca-pill { margin-left: auto; }
  .ca-pill .ca-soon { display: none; }
  .meta-row > div { padding: 0 10px; }
}
@media (prefers-reduced-motion: reduce) { .live-dot { animation: none; } }

/* header.site on rounds / flash */
header.site .ca-pill { margin-left: auto; }
header.site .btn-app { min-height: 38px; font-size: 13px; }
@media (max-width: 760px) { header.site .ca-pill { margin-left: auto; } header.site .btn-app { padding: 0 12px; } }

/* ---------- R3: trust pass ----------
 * The loud magenta ribbon is gone. Status lives in one quiet chip in the header (links to the status
 * board), and simulated data keeps a small, calm label instead of a shouting pill. */
.status-chip {
  display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 12px;
  border-radius: 999px; border: 1px solid var(--line); background: var(--paper-3);
  font: 500 12.5px/1 var(--f-text); color: var(--ink); text-decoration: none; white-space: nowrap;
  transition: border-color .2s, background .2s;
}
.status-chip i { width: 7px; height: 7px; border-radius: 50%; background: var(--brass); box-shadow: 0 0 0 3px rgba(217,162,58,.2); }
.status-chip:hover { border-color: var(--ink-2); background: #fff; }
.bar .status-chip { margin-left: auto; }
.bar .status-chip + .ca-pill { margin-left: 0; }
.sim-pill {
  background: transparent; color: var(--ink-2); border: 1px dashed color-mix(in srgb, var(--ink-2) 45%, transparent);
  font: 500 11px/1 var(--f-mono); letter-spacing: .02em; text-transform: none; padding: 4px 8px;
}
.sim-pill::before { background: var(--dusk); opacity: 1; }
@media (max-width: 760px) { .bar .status-chip { margin-left: 0; } }
.status-chip.is-live i { background: var(--pine); box-shadow: 0 0 0 3px rgba(46,107,94,.2); }

/* official social marks in the header */
.soc { display: inline-flex; align-items: center; gap: 4px; }
.soc-a { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: var(--ink); border: 1px solid var(--line); background: var(--paper-3); transition: background .2s, color .2s, border-color .2s; }
a.soc-a:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.soc-a.is-off { color: var(--ink-2); opacity: .5; border-style: dashed; cursor: help; }
header.site .soc { margin-left: auto; }
header.site .soc + .ca-pill { margin-left: 0; }
@media (max-width: 760px) { .soc-a { width: 34px; height: 34px; } }
