/* /trust/ (owner, 24 Nov 2026: "hero images too big", "flat bgs", "so boring"). The hero and grounds come from
   assets/css/company.css. This file draws the access path (two gates, one organization boundary, the audit trail beside
   it, a signal travelling down), the key-controls strip, the roles matrix and the document shelf. Tokens only. */

/* ------------------------------------------------------------ hero: numbered points and the access path */
.tr-pts { display: grid; gap: var(--sp-2); margin: var(--sp-6) 0 0; padding: 0; list-style: none; }
.tr-pts li { display: flex; align-items: center; gap: var(--sp-3); font: 500 var(--fs-md)/1.3 var(--display); color: var(--ink-50); }
.tr-pts b { display: grid; place-items: center; flex: none; width: 24px; height: 24px; border-radius: var(--r-xs); background: var(--teal-400); font: 600 var(--fs-xs)/1 var(--mono); color: var(--navy-950); }
.ctrl { max-width: 600px; margin-left: auto; }
.ctrl-body { display: grid; grid-template-columns: minmax(0, 1fr) 150px; gap: var(--sp-4); }
.layers { position: relative; display: grid; gap: 20px; margin: 0; padding: 0; list-style: none; }
.layers::before { content: ''; position: absolute; left: 50%; top: 20px; width: 6px; height: 6px; margin-left: -3px; border-radius: var(--r-full); background: var(--teal-300);
  box-shadow: 0 0 12px var(--teal-400); z-index: 2; animation: tr-down 3.2s var(--ease-standard) infinite; }
@keyframes tr-down { 0% { top: 20px; opacity: 0; } 10% { opacity: 1; } 85% { opacity: 1; } 100% { top: calc(100% - 60px); opacity: 0; } }
.layer { position: relative; padding: 12px 14px; border: 1px solid var(--teal-a40); border-radius: var(--r-md); background: linear-gradient(180deg, var(--navy-800), var(--navy-850)); box-shadow: var(--e1); }
.layer + .layer::before { content: ''; position: absolute; left: 50%; top: -21px; width: 1px; height: 20px; background: var(--teal-400); opacity: 0.6; }
.layer .k, .audit .k { display: block; margin-bottom: 6px; font: 500 var(--fs-xs)/1 var(--mono); letter-spacing: var(--tr-label); color: var(--teal-300); text-transform: uppercase; }
.layer b, .audit b { display: block; font: 500 var(--fs-sm)/1.3 var(--display); color: var(--ink-50); }
.layer.actor { border-style: dashed; border-color: var(--line-strong); background: color-mix(in srgb, var(--navy-950) 50%, transparent); text-align: center; box-shadow: none; }
.layer.bound { border-color: var(--teal-400); box-shadow: 0 0 0 4px var(--teal-a12), 0 20px 50px -20px var(--teal-a40); }
.layer.data { border-color: var(--line-strong); background: linear-gradient(180deg, color-mix(in srgb, var(--navy-700) 60%, transparent), var(--navy-850)); }
.layer .sub, .audit .sub { display: block; margin-top: 8px; padding-left: 12px; border-left: 1px solid var(--teal-a40); font-size: var(--fs-xs); color: var(--ink-200); }
.audit { position: relative; display: flex; flex-direction: column; justify-content: center; padding: 14px; border: 1px dashed var(--teal-a40); border-radius: var(--r-md);
  background: linear-gradient(180deg, var(--teal-a06), transparent); }
.audit .sub { padding: 0; border: 0; }
.audit-lines { display: grid; gap: 6px; margin: 14px 0; }
.audit-lines i { height: 4px; border-radius: var(--r-xs); background: var(--teal-a24); transform-origin: left; animation: tr-log 4.2s var(--ease-decelerate) infinite; }
.audit-lines i:nth-child(odd) { width: 80%; }
.audit-lines i:nth-child(2) { animation-delay: .5s; } .audit-lines i:nth-child(3) { animation-delay: 1s; } .audit-lines i:nth-child(4) { animation-delay: 1.5s; }
.audit-lines i:nth-child(5) { animation-delay: 2s; } .audit-lines i:nth-child(6) { animation-delay: 2.5s; } .audit-lines i:nth-child(7) { animation-delay: 3s; }
@keyframes tr-log { 0% { transform: scaleX(0); background: var(--teal-400); } 20% { transform: scaleX(1); background: var(--teal-400); } 40%, 100% { transform: scaleX(1); background: var(--teal-a24); } }
.audit .co-live { align-self: flex-start; padding: 4px 8px; }

/* ------------------------------------------------------------ key controls: a strip between the hero and the roles */
.tr-keys { position: relative; padding: 0; background: linear-gradient(180deg, var(--navy-850), var(--pt-900)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--teal-a24); }
.tr-keys ul { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 0; padding: 0; list-style: none; }
.tr-keys li { position: relative; display: grid; gap: 6px; padding: var(--sp-6) var(--sp-5); }
.tr-keys li + li { border-left: 1px solid var(--line); }
.tr-keys li::before { content: ''; position: absolute; left: var(--sp-5); top: -1px; width: 32px; height: 2px; background: var(--teal-400); }
.tr-keys span { font: 500 var(--fs-xs)/1 var(--mono); letter-spacing: var(--tr-label); text-transform: uppercase; color: var(--teal-300); }
.tr-keys b { font: 600 var(--fs-lg)/1.3 var(--display); color: var(--ink-50); }

/* ------------------------------------------------------------ roles: the matrix, Kurikara Labs' column lit */
.tr-matrix { overflow: hidden; background: var(--white); border: 1px solid var(--paper-line); box-shadow: 0 1px 2px color-mix(in srgb, var(--navy-950) 6%, transparent), 0 20px 48px -24px color-mix(in srgb, var(--navy-950) 32%, transparent); }
.tr-matrix .ktable th { background: var(--paper); }
.tr-matrix .ktable :is(th, td):nth-child(2) { background: color-mix(in srgb, var(--teal-400) 7%, var(--white)); }
.tr-matrix .ktable th:nth-child(2) { color: var(--teal-ink); box-shadow: inset 0 3px 0 var(--teal-ink); }
.tr-matrix .ktable td { vertical-align: middle; }
.tr-matrix .ktable tbody tr { transition: background var(--dur-base) var(--ease-standard); }
.tr-matrix .ktable tbody tr:hover { background: var(--paper); }
.tr-yes { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--paper-ink); }
.tr-yes::before { content: ''; width: 10px; height: 10px; border-radius: var(--r-full); background: var(--teal-ink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--teal-400) 22%, transparent); }

/* ------------------------------------------------------------ controls: questions beside the document shelf */
.tr-split { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--sp-5); align-items: start; }
.tr-shelf { position: sticky; top: calc(var(--hh, 72px) + var(--sp-5)); padding: var(--sp-5); border-radius: var(--r-md); border: 1px solid var(--line);
  background: radial-gradient(80% 50% at 100% 0%, var(--teal-a12), transparent 70%), linear-gradient(180deg, var(--navy-825), var(--navy-900)); box-shadow: var(--edge-hi), var(--e1); }
.tr-shelf-h { margin: 0 0 var(--sp-3); font: 500 var(--fs-xs)/1 var(--mono); letter-spacing: var(--tr-eyebrow); text-transform: uppercase; color: var(--teal-300); }
.tr-shelf .doc-rows { padding: 0; }
.tr-shelf .doc-row { grid-template-columns: 36px minmax(0, 1fr) auto; padding: var(--sp-3) var(--sp-2); margin-inline: calc(var(--sp-2) * -1); border-radius: var(--r-sm); transition: background var(--dur-base) var(--ease-standard); }
.tr-shelf a.doc-row:hover { background: var(--teal-a06); }
.tr-shelf .doc-row .card-ic { width: 36px; height: 44px; border-radius: 4px 12px 4px 4px; background: linear-gradient(180deg, var(--navy-700), var(--navy-800)); border: 1px solid var(--line-strong); color: var(--teal-300); }
.tr-shelf .doc-row .card-ic svg { width: 16px; height: 16px; }
.tr-shelf .doc-row .lnk { font-size: var(--fs-sm); }

/* ------------------------------------------------------------ responsive */
@media (max-width: 1023px) {
  .ctrl { margin: 0 auto; }
  .tr-keys ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tr-keys li:nth-child(3) { border-left: 0; }
  .tr-keys li:nth-child(n+3) { border-top: 1px solid var(--line); }
  .tr-split { grid-template-columns: minmax(0, 1fr); }
  .tr-shelf { position: static; }
}
@media (max-width: 767px) {
  .ctrl-body { grid-template-columns: minmax(0, 1fr); }
  .audit-lines { display: none; }
  .tr-keys li { padding: var(--sp-5) var(--sp-4); }
  .tr-keys li::before { left: var(--sp-4); }
  .tr-keys b { font-size: var(--fs-md); }
}
@media (prefers-reduced-motion: reduce) {
  .layers::before, .audit-lines i { animation: none; }
  .layers::before { display: none; }
}

/* Performance (2 Dec 2026): the same two loops, drawn without repainting the panel. The travelling dot was moved by
   `top` (a layout and a repaint every frame): it is now painted at the top of a strip that spans its path (20 px from
   the top to 60 px from the bottom) and the strip moves by transform. The log lines brighten through a fading layer
   instead of an animated background. */
.layers::before { top: 20px; bottom: 60px; height: auto; width: 24px; margin-left: -12px; border-radius: 0; box-shadow: none;
  background: radial-gradient(circle 3px at 50% 3px, var(--teal-300) 2.5px, transparent 3px), radial-gradient(circle 12px at 50% 3px, color-mix(in srgb, var(--teal-400) 55%, transparent), transparent 12px);
  will-change: transform, opacity; animation-name: tr-down-move; }
@keyframes tr-down-move { 0% { transform: translateY(0); opacity: 0; } 10% { opacity: 1; } 85% { opacity: 1; } 100% { transform: translateY(100%); opacity: 0; } }
.audit-lines i { position: relative; animation-name: tr-log-move; }
.audit-lines i::after { content: ''; position: absolute; inset: 0; border-radius: inherit; background: var(--teal-400); opacity: 0; animation: tr-log-lit 4.2s var(--ease-decelerate) infinite; animation-delay: inherit; }
@keyframes tr-log-move { 0% { transform: scaleX(0); } 20%, 100% { transform: scaleX(1); } }
@keyframes tr-log-lit { 0%, 20% { opacity: 1; } 40%, 100% { opacity: 0; } }
