/* ==============================================================================
   DECODER · ECU LAB — Proof Process Accordions Stylesheet
   web/components/proof.css
   ============================================================================== */

.app-shell.proof-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 0 0 40px;
  width: min(100%, 1440px);
  max-width: 1440px;
  margin: 0 auto;
  border: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.app-shell.proof-shell::before { content:none; }

.proof-topbar {
  margin-bottom: 24px;
  width:100%;
}

.proof-content-wrapper {
  width: 100%;
}

.proof-hero {
  padding: 24px;
  margin-bottom: 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle, rgba(0, 240, 255, 0.2));
  border-radius: var(--radius-lg, 12px);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
}

.proof-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono, monospace);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--cyan-bright);
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.3);
  padding: 4px 12px;
  border-radius: 9999px;
  margin-bottom: 12px;
}

.proof-title {
  font-family: var(--font-heading, "Inter", sans-serif);
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0 0 12px;
  line-height: 1.25;
}

.proof-lead {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--muted);
  margin: 0 0 20px;
  max-width: 820px;
}

.proof-actions-bar {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.proof-accordions-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.proof-accordion {
  background: var(--bg-card);
  border: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
  border-radius: var(--radius-md, 10px);
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  backdrop-filter: blur(8px);
}

.proof-accordion[open] {
  border-color: rgba(0, 240, 255, 0.4);
  box-shadow: 0 0 16px rgba(0, 240, 255, 0.1);
}

.proof-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  cursor: pointer;
  user-select: none;
  background: rgba(255, 255, 255, 0.02);
  transition: background 0.15s ease;
}

.proof-summary::-webkit-details-marker {
  display: none;
}

.proof-summary:hover {
  background: rgba(0, 240, 255, 0.05);
}

.summary-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.step-num {
  font-family: var(--font-mono, monospace);
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--cyan-bright);
  background: rgba(0, 240, 255, 0.12);
  border: 1px solid rgba(0, 240, 255, 0.3);
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.step-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.step-title {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  letter-spacing: -0.01em;
}

.step-desc {
  font-size: 0.8rem;
  color: var(--muted);
  font-family: var(--font-mono, monospace);
}

.summary-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.accordion-arrow {
  font-size: 0.75rem;
  color: var(--cyan-bright);
  transition: transform 0.25s ease;
}

.proof-accordion[open] .accordion-arrow {
  transform: rotate(180deg);
}

.proof-body {
  padding: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: var(--bg-subtle);
}

.proof-text {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text);
  margin: 0 0 16px;
}

.proof-field-group {
  margin-bottom: 16px;
}

.proof-field-group:last-child {
  margin-bottom: 0;
}

.proof-label {
  display: block;
  font-family: var(--font-mono, monospace);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--cyan-bright);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.proof-code-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  background: var(--bg-subtle);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm, 6px);
  padding: 10px 14px;
}

.proof-code {
  font-family: var(--font-mono, monospace);
  font-size: 0.85rem;
  color: var(--cyan-bright);
  word-break: break-all;
  flex: 1;
}

.gold-key {
  color: #f59e0b;
  font-weight: 700;
}

.proof-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.proof-pre {
  background: var(--bg-subtle);
  border: 1px solid rgba(0, 240, 255, 0.15);
  border-radius: var(--radius-sm, 6px);
  padding: 14px 16px;
  overflow-x: auto;
  font-family: var(--font-mono, monospace);
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--text);
  margin: 0 0 10px;
  max-height: 380px;
}

.proof-pre code {
  font-family: inherit;
  color: inherit;
}

@media (max-width: 640px) {
  .app-shell.proof-shell {
    padding: 0 0 32px;
  }
  .proof-title {
    font-size: 1.3rem;
  }
  .summary-left {
    gap: 10px;
  }
  .step-num {
    width: 30px;
    height: 30px;
    font-size: 0.9rem;
  }
  .step-title {
    font-size: 0.9rem;
  }
  .proof-code-row {
    flex-direction: column;
    align-items: stretch;
  }
}

/* Proof surfaces use the same theme tokens as the cabinet. */
.proof-shell,.proof-content-wrapper,.proof-container,.proof-accordion,.summary-left,.step-meta { min-width:0; }
.proof-summary { gap:16px; list-style:none; }
.proof-code-row { min-width:0; }
.proof-code { min-width:0; overflow-wrap:anywhere; }
.proof-body { border-color:var(--border); }
.proof-hero { box-shadow:0 8px 24px -16px var(--shadow); }
.theme-light .proof-shell .proof-hero,.theme-light .proof-shell .proof-accordion,.proof-shell.theme-light .proof-hero,.proof-shell.theme-light .proof-accordion { background:#fff; border-color:#cbd5e1; box-shadow:0 8px 24px -18px #33415540; }
.theme-light .proof-shell :is(.proof-body,.proof-code-row,.proof-pre),.proof-shell.theme-light :is(.proof-body,.proof-code-row,.proof-pre) { background:#f1f5f9; border-color:#cbd5e1; color:#1a2838; }
.theme-light .proof-shell .proof-code,.proof-shell.theme-light .proof-code { color:#075985; }
.theme-light .proof-shell .gold-key,.proof-shell.theme-light .gold-key { color:#92400e; }
.theme-light .proof-shell .proof-badge,.proof-shell.theme-light .proof-badge { background:#e0f2fe; border-color:#7dd3fc; color:#075985; }
.theme-light .proof-shell .step-num,.proof-shell.theme-light .step-num { background:#e0f2fe; border-color:#7dd3fc; color:#075985; }
@media(max-width:640px){.proof-topbar{flex-wrap:wrap;gap:12px}.proof-topbar .cockpit-actions-block{flex-wrap:wrap}.proof-summary{padding:16px;align-items:flex-start}.summary-right .chip{display:none}.proof-hero,.proof-body{padding:18px}.proof-pre{max-width:100%}.proof-buttons .button{white-space:normal}}
.proof-topbar .cockpit-operator-block{flex:1 1 auto;min-width:0}
.proof-topbar .cockpit-actions-block{margin-left:auto;flex:0 1 auto;width:auto}
.proof-topbar .proof-theme-button{display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:0 12px;white-space:nowrap}
.proof-topbar .proof-theme-button>span{width:auto;height:auto;display:inline}
.proof-shell .proof-summary{font-size:inherit;line-height:1.5}
.proof-shell .proof-accordion{margin-top:0}
.proof-shell .proof-text{max-width:90ch;margin-bottom:0}
.proof-shell .proof-text+.proof-field-group{margin-top:16px}
.proof-shell .proof-badge{max-width:100%;font-size:10px;line-height:1.5;letter-spacing:.08em}
.proof-shell .proof-code-row{gap:10px}
.proof-shell .proof-buttons .button{white-space:nowrap}
@media(max-width:640px){.proof-topbar .cockpit-operator-block{width:100%;flex-direction:row;align-items:center}.proof-topbar .operator-id-chip{font-size:9px;padding:6px 8px}.proof-topbar .cockpit-actions-block{width:100%;display:flex;margin-left:0;justify-content:space-between;gap:8px}.proof-topbar .cockpit-actions-block>.button{flex:1;padding:0 8px;font-size:10px}.proof-shell .proof-actions-bar>.button{flex:1 1 180px;justify-content:center}.proof-shell .proof-buttons{width:100%}.proof-shell .proof-buttons .button{flex:1;justify-content:center}.proof-shell .step-title{font-size:13px}.proof-shell .step-desc{font-size:11px}.proof-shell .summary-right{gap:0}}
@media(max-width:640px){.proof-topbar .cockpit-actions-block{display:grid;grid-template-columns:40px minmax(0,1fr) minmax(0,1fr)}.proof-topbar #proof-theme-toggle{padding:0}.proof-topbar #proof-theme-toggle>span{display:none}.proof-topbar .cockpit-actions-block>.button{width:100%;justify-content:center;white-space:nowrap}}
