/* ── Destine Network Lab — N2 Canvas Render ──
   Quiet Luxury | Dark left rail | Ivory canvas | Muted gold
   Branch: lab/archive-network-n0-prototype-20260625
*/

/* ── Reset & Base ── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: #FAFAF7;
  color: #1C1A16;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── Layout ── */
.app {
  display: flex;
  width: 100%;
  height: 100vh;
}

/* ── Left Rail ── */
.rail {
  width: 220px;
  min-width: 220px;
  background: #0D0D0D;
  color: #b8ab96;
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(196,151,62,0.12);
  z-index: 10;
}

.rail-header {
  padding: 28px 20px 20px;
  border-bottom: 1px solid rgba(196,151,62,0.08);
}

.rail-title {
  font-size: 11px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #c4973e;
  font-weight: 500;
}

.rail-subtitle {
  font-size: 10px;
  color: #a99a84;
  margin-top: 6px;
  line-height: 1.4;
}

.rail-content {
  flex: 1;
  overflow-y: auto;
  padding: 16px 0;
}

/* ── Filter section label (hierarchy headers) ── */
.filter-section-label {
  font-size: 9px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #8a7a60;
  padding: 16px 20px 4px;
  font-weight: 500;
}

/* ── Sub-items under sections (indented) ── */
.filter-sub {
  padding: 5px 20px 5px 32px;
}

.filter-item {
  display: flex;
  align-items: center;
  padding: 6px 20px;
  cursor: pointer;
  font-size: 13px;
  color: #c8bda8;
  transition: all 0.15s ease;
  position: relative;
}

.filter-item:hover {
  color: #f0e0c0;
  background: rgba(196,151,62,0.05);
}

.filter-item.active {
  color: #f3dfb0;
  background: rgba(196,151,62,0.08);
}

.filter-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 10px;
  flex-shrink: 0;
  border: 1px solid rgba(255,255,255,0.08);
}

/* ── Top Bar ── */
.top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  height: 56px;
  background: #FAFAF7;
  border-bottom: 1px solid rgba(0,0,0,0.04);
  flex-shrink: 0;
}

.top-bar-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.top-bar-title {
  font-size: 18px;
  font-weight: 500;
  letter-spacing: 1px;
  color: #1C1A16;
}

.top-bar-badge {
  font-size: 10px;
  color: rgba(196,151,62,0.6);
  letter-spacing: 2px;
  text-transform: uppercase;
  border: 1px solid rgba(196,151,62,0.15);
  padding: 2px 8px;
  border-radius: 3px;
}

.top-bar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-reset {
  background: none;
  border: 1px solid rgba(0,0,0,0.08);
  padding: 6px 14px;
  font-size: 12px;
  color: #8a8275;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
}

.btn-reset:hover {
  border-color: #c4973e;
  color: #c4973e;
}

/* ── Insight Card (default right panel) ── */
.insight-type-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 3px;
  font-size: 10px;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.insight-meta {
  display: flex;
  gap: 16px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(0,0,0,0.04);
}

.insight-meta-item {
  display: flex;
  flex-direction: column;
}

.insight-meta-label {
  font-size: 9px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #8a8275;
  margin-bottom: 2px;
}

.insight-meta-value {
  font-size: 16px;
  font-weight: 500;
  color: #1C1A16;
}

.insight-section {
  margin-bottom: 20px;
}

.insight-section-label {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #c4973e;
  margin-bottom: 6px;
  font-weight: 500;
}

.insight-section-body {
  font-size: 13px;
  line-height: 1.7;
  color: #3a3530;
}

.insight-related-title {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #8a8275;
  margin-bottom: 8px;
  margin-top: 4px;
  font-weight: 500;
}

.insight-related-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 20px;
}

.insight-related-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: rgba(0,0,0,0.02);
  border-radius: 4px;
  font-size: 12px;
}

.insight-related-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  flex-shrink: 0;
}

.insight-related-text {
  flex: 1;
  color: #3a3530;
  line-height: 1.3;
}

.insight-related-source {
  font-size: 9px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #8a8275;
  flex-shrink: 0;
}

.insight-actions {
  padding-top: 12px;
  border-top: 1px solid rgba(0,0,0,0.04);
}

.btn-edit-profile {
  background: none;
  border: 1px solid rgba(196,151,62,0.3);
  color: #c4973e;
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
  width: 100%;
}

.btn-edit-profile:hover {
  background: rgba(196,151,62,0.04);
  border-color: #c4973e;
}

/* ── Editor Form (edit profile mode) ── */
.editor-form {
  padding: 4px 0;
}

.editor-field {
  margin-bottom: 16px;
}

.editor-label {
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #8a8275;
  display: block;
  margin-bottom: 4px;
}

.editor-input {
  width: 100%;
  padding: 8px 10px;
  font-size: 13px;
  font-family: inherit;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 4px;
  background: #FAFAF7;
  color: #1C1A16;
  outline: none;
  transition: border-color 0.15s ease;
}

.editor-input:focus {
  border-color: #c4973e;
}

.editor-range {
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  border-radius: 2px;
  background: rgba(0,0,0,0.06);
  outline: none;
  margin-top: 4px;
}

.editor-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #c4973e;
  cursor: pointer;
  border: 2px solid #FAFAF7;
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

.editor-textarea {
  width: 100%;
  padding: 8px 10px;
  font-size: 13px;
  font-family: inherit;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 4px;
  background: #FAFAF7;
  color: #1C1A16;
  outline: none;
  resize: vertical;
  line-height: 1.5;
  transition: border-color 0.15s ease;
}

.editor-textarea:focus {
  border-color: #c4973e;
}

.editor-actions {
  display: flex;
  gap: 8px;
  margin-top: 20px;
}

.btn-save {
  flex: 1;
  background: #c4973e;
  border: 1px solid #c4973e;
  color: #FAFAF7;
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 10px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
}

.btn-save:hover {
  background: #b8892e;
  border-color: #b8892e;
}

.btn-cancel {
  flex: 1;
  background: none;
  border: 1px solid rgba(0,0,0,0.08);
  color: #8a8275;
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 10px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
}

.btn-cancel:hover {
  border-color: #8a8275;
  color: #1C1A16;
}

.editor-danger {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid rgba(180,100,80,0.15);
}

.btn-remove {
  width: 100%;
  background: none;
  border: 1px solid rgba(180,100,80,0.25);
  color: #b8735a;
  font-size: 11px;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
}

.btn-remove:hover {
  background: rgba(180,100,80,0.04);
  border-color: #b8735a;
}

/* ── Main Content ── */
.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.canvas-wrapper {
  flex: 1;
  position: relative;
  overflow: hidden;
  background: #FAFAF7;
  cursor: grab;
}

.canvas-wrapper:active {
  cursor: grabbing;
}

.canvas-wrapper svg {
  display: block;
  width: 100%;
  height: 100%;
}

/* ── Graph Nodes ── */
.node-self circle {
  fill: #c4973e;
  stroke: rgba(196,151,62,0.4);
  stroke-width: 2px;
}

.node-self .node-label {
  fill: #1C1A16;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 1px;
}

.node-person circle {
  stroke: rgba(255,255,255,0.4);
  stroke-width: 1.5px;
}

.node-person .node-label {
  fill: #3a3530;
  font-size: 11px;
  font-weight: 400;
}

.node-question circle {
  stroke-dasharray: 3,3;
  stroke: rgba(255,255,255,0.3);
  stroke-width: 1.5px;
}

.node-question .node-label {
  fill: #5a4b3a;
  font-size: 10px;
  font-style: italic;
}

.node-action circle {
  stroke: rgba(255,255,255,0.3);
  stroke-width: 1px;
}

.node-action .node-label {
  fill: #5a5040;
  font-size: 10px;
}

.node-cycle circle {
  stroke: rgba(255,255,255,0.2);
  stroke-width: 1px;
  opacity: 0.7;
}

.node-cycle .node-label {
  fill: #7a7065;
  font-size: 10px;
}

/* ── Edge Lines ── */
.edge-line {
  stroke-opacity: 0.25;
  stroke-linecap: round;
}

/* ── Right Detail Panel ── */
.detail-panel {
  width: 0;
  overflow: hidden;
  background: #FAFAF7;
  border-left: 1px solid rgba(0,0,0,0.04);
  transition: width 0.25s ease;
  flex-shrink: 0;
}

.detail-panel.open {
  width: 340px;
  min-width: 340px;
}

.detail-inner {
  width: 340px;
  height: 100%;
  overflow-y: auto;
  padding: 24px;
}

.detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(0,0,0,0.04);
}

.detail-title {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 1px;
  color: #1C1A16;
}
.detail-title.is-test-label {
  color: #b0aba3;
  font-style: italic;
  opacity: 0.7;
}

.detail-close {
  background: none;
  border: none;
  font-size: 18px;
  color: #8a8275;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
}

.detail-close:hover {
  color: #1C1A16;
}

.detail-field {
  margin-bottom: 16px;
}

.detail-field-label {
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #8a8275;
  margin-bottom: 4px;
}

.detail-field-value {
  font-size: 14px;
  color: #1C1A16;
  line-height: 1.4;
}

.detail-field-value.type-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 3px;
  font-size: 11px;
  letter-spacing: 1px;
}

.detail-field-value.strength-bar {
  height: 4px;
  border-radius: 2px;
  background: rgba(0,0,0,0.06);
  position: relative;
  margin-top: 4px;
}

.detail-field-value.strength-bar .fill {
  height: 100%;
  border-radius: 2px;
  background: #c4973e;
  transition: width 0.3s ease;
}

.detail-summary {
  font-size: 13px;
  line-height: 1.6;
  color: #3a3530;
  margin-top: 12px;
  padding: 12px;
  background: rgba(0,0,0,0.02);
  border-radius: 4px;
  border-left: 2px solid rgba(196,151,62,0.3);
}

.detail-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 60%;
  color: #8a8275;
  font-size: 13px;
  text-align: center;
  line-height: 1.6;
  padding: 24px;
}

.detail-empty-icon {
  font-size: 32px;
  margin-bottom: 12px;
  opacity: 0.3;
}

/* ── Zoom Controls ── */
.zoom-controls {
  position: absolute;
  bottom: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  z-index: 5;
}

.zoom-btn {
  width: 32px;
  height: 32px;
  background: #FAFAF7;
  border: 1px solid rgba(0,0,0,0.06);
  color: #1C1A16;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  font-family: inherit;
}

.zoom-btn:hover {
  background: #f0ece4;
  border-color: #c4973e;
  color: #c4973e;
}

.zoom-btn:first-child {
  border-radius: 4px 4px 0 0;
}

.zoom-btn:last-child {
  border-radius: 0 0 4px 4px;
}

/* ── Node hover effect ── */
.node-g {
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.node-g:hover .node-label {
  font-weight: 500;
}

/* ── Mobile fallback: single column ── */
@media (max-width: 768px) {
  .app {
    flex-direction: column;
  }

  .rail {
    width: 100%;
    min-width: unset;
    max-height: 48px;
    overflow: hidden;
    flex-shrink: 0;
    flex-direction: row;
    align-items: center;
    padding: 0 12px;
  }

  .rail.expanded {
    max-height: 100vh;
    flex-direction: column;
    align-items: stretch;
    overflow-y: auto;
  }

  .rail-header {
    padding: 12px 12px;
    border-bottom: none;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
  }

  .rail-title {
    font-size: 10px;
  }

  .rail-subtitle {
    display: none;
  }

  .rail-content {
    display: none;
    padding: 8px 0;
  }

  .rail.expanded .rail-content {
    display: block;
  }

  .rail-toggle {
    display: block;
    margin-left: auto;
    background: none;
    border: 1px solid rgba(196,151,62,0.2);
    color: #c4973e;
    font-size: 10px;
    padding: 4px 8px;
    border-radius: 3px;
    cursor: pointer;
  }

  .top-bar {
    padding: 8px 12px;
    height: auto;
    flex-wrap: wrap;
    gap: 4px;
  }

  .top-bar-title {
    font-size: 14px;
  }

  .detail-panel {
    position: fixed;
    left: 14px;
    right: 14px;
    top: 16vh;
    bottom: 18px;
    width: auto;
    max-width: none;
    height: auto;
    max-height: 72vh;
    transform: translateY(12px);
    opacity: 0;
    pointer-events: none;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
    overscroll-behavior: contain;
    border-radius: 18px 18px 14px 14px;
    z-index: 2000;
    box-shadow: 0 24px 80px rgba(0,0,0,0.22);
    border-left: none;
    background: #FAFAF7;
    transition: transform 0.25s ease, opacity 0.25s ease;
    flex-shrink: 0;
  }

  .detail-panel.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
    width: auto;
    min-width: unset;
    border-top: none;
  }

  .detail-panel input,
  .detail-panel textarea,
  .detail-panel select,
  .detail-panel button {
    touch-action: manipulation;
  }

  .detail-inner {
    width: 100%;
    height: auto;
    overflow-y: visible;
  }

  .zoom-controls {
    z-index: 1001;
  }
}

@media (min-width: 769px) {
  .rail-toggle {
    display: none;
  }
}

/* ── Node label polish ── */
.node-label {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  pointer-events: none;
  user-select: none;
  fill: rgba(47,42,34,0.82) !important;
}

.node-g {
  cursor: pointer;
  transition: filter 0.15s ease;
}

.node-g:hover circle {
  filter: brightness(1.2);
}

/* ── Edge polish ── */
.edge-line {
  transition: stroke-opacity 0.2s ease;
  stroke: #8a7d65;
}

.graph-container .edge-line {
  stroke: #8a7d65;
}

/* ── Detail panel redesign ── */
.dp-card-top {
  margin-top: 4px;
}
.dp-card-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 22px;
  font-weight: 500;
  color: #1C1A16;
  line-height: 1.3;
  margin-bottom: 6px;
}
.dp-card-title.is-test-label {
  color: #b0aba3;
  font-style: italic;
  opacity: 0.7;
}
.dp-card-alias {
  font-size: 11px;
  color: #8a8275;
  margin-top: -2px;
  margin-bottom: 6px;
}
.dp-card-badge {
  display: inline-block;
  padding: 3px 10px;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-radius: 2px;
  margin-bottom: 12px;
}
.dp-score-row {
  margin: 8px 0 4px;
}
.dp-score-value {
  font-family: 'Cormorant Garamond', serif;
  font-size: 28px;
  font-weight: 500;
  color: #1C1A16;
  line-height: 1.1;
}
.dp-score-label {
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #8a8275;
  margin-top: 2px;
}
.dp-score-subtitle {
  font-size: 11px;
  font-weight: 400;
  color: #8a8275;
  margin: 0 0 6px;
}
.dp-summary {
  font-size: 12px;
  color: #5a5550;
  line-height: 1.5;
  margin: 8px 0 12px;
  font-style: italic;
}
.dp-section-title {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #8a8275;
  margin: 20px 0 10px;
  padding-top: 14px;
  border-top: 1px solid rgba(0,0,0,0.04);
}
.dp-guidance-card {
  background: #FAFAF7;
  border: 1px solid rgba(196,151,62,0.1);
  padding: 12px 14px;
  margin-bottom: 8px;
}
.dp-guidance-module-label {
  font-size: 11px;
  font-weight: 500;
  color: #1C1A16;
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}
.dp-guidance-field {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 2px 0;
  font-size: 11px;
  line-height: 1.6;
}
.dp-guidance-field-label {
  color: #8a8275;
  min-width: 100px;
  flex-shrink: 0;
}
.dp-guidance-field-value {
  color: #5a5550;
  text-align: right;
}
.dp-guidance-field-value.empty {
  color: #b8b0a0;
  font-style: italic;
}
.dp-history-empty {
  font-size: 12px;
  color: #b8b0a0;
  font-style: italic;
  padding: 4px 0;
}
.dp-details-toggle {
  font-size: 11px;
  color: #c4973e;
  cursor: pointer;
  padding: 10px 0 6px;
  user-select: none;
  letter-spacing: 0.06em;
}
.dp-details-toggle:hover {
  color: #d4a84b;
}
.dp-details-toggle-arrow {
  display: inline-block;
  font-size: 9px;
  margin-right: 4px;
  transition: transform 0.2s;
}
.dp-details-toggle.open .dp-details-toggle-arrow {
  transform: rotate(90deg);
}
.dp-details-content {
  padding: 4px 0 8px;
}
.dp-detail-row {
  display: flex;
  justify-content: space-between;
  padding: 4px 0;
  font-size: 11px;
  border-bottom: 1px solid rgba(0,0,0,0.03);
}
.dp-detail-row:last-child {
  border-bottom: none;
}
.dp-detail-row-label {
  color: #8a8275;
}
.dp-detail-row-value {
  color: #5a5550;
  text-align: right;
  max-width: 60%;
}
.dp-danger-zone {
  margin-top: 24px;
  padding-top: 12px;
  border-top: 1px solid rgba(184,115,90,0.12);
}
.dp-danger-label {
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(184,115,90,0.5);
  margin-bottom: 8px;
}

.dp-subline-status {
  background: rgba(196,151,62,0.04);
  border: 1px solid rgba(196,151,62,0.12);
  padding: 16px 14px;
  font-size: 12px;
  line-height: 1.6;
  color: #8a8275;
}
.dp-subline-status strong {
  display: block;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: #c4973e;
  font-weight: 500;
  margin-bottom: 4px;
}

/* ── Tab bar ── */
.dp-tab-bar {
  display: flex;
  border-bottom: 1px solid rgba(196,151,62,0.12);
  margin: 0 20px;
}
.dp-tab {
  flex: 1;
  padding: 10px 4px;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: #8a8275;
  cursor: pointer;
  font-family: inherit;
  transition: color 0.2s, border-color 0.2s;
}
.dp-tab:hover {
  color: #c4973e;
}
.dp-tab.dp-tab-active {
  color: #c4973e;
  border-bottom-color: #c4973e;
}
.dp-tab-content {
  padding: 0 20px;
}

/* ── Details section ── */
.dd-section {
  padding: 8px 0;
  border-bottom: 1px solid rgba(0,0,0,0.03);
}
.dd-label {
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #8a8275;
  margin-bottom: 3px;
}
.dd-value {
  font-size: 13px;
  color: #3a3530;
  line-height: 1.5;
}
.dd-value.dd-section-body {
  font-size: 13px;
  color: #5a5550;
  line-height: 1.6;
}
.ds-archetype-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 17px;
  font-weight: 500;
  color: #1C1A16;
}
.ds-score-value {
  font-family: 'Cormorant Garamond', serif;
  font-size: 16px;
  font-weight: 500;
  color: #1C1A16;
}
.ds-score-summary {
  font-size: 12px;
  color: #5a5550;
}

/* ── Ask Today button in card-top ── */
.dp-btn-ask-today {
  display: block;
  width: 100%;
  margin-top: 12px;
  padding: 10px 0;
  background: #c4973e;
  border: none;
  color: #0D0D0D;
  font-family: inherit;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  cursor: pointer;
  text-transform: uppercase;
  transition: opacity 0.15s ease;
}
.dp-btn-ask-today:hover {
  opacity: 0.85;
}

/* ── Ask Today results ── */
.dp-ask-result {
  padding-bottom: 4px;
}
.dp-ask-mode-label {
  font-size: 10px;
  letter-spacing: 0.1em;
  color: #8a8275;
  margin-bottom: 8px;
  text-transform: uppercase;
}
.dp-guidance-card-suggested {
  border-left: 2px solid rgba(196,151,62,0.25);
}
.dp-guidance-card-avoid {
  border-left: 2px solid rgba(184,115,90,0.2);
}
.dp-guidance-field-value {
  font-size: 13px;
  color: #3a3530;
  line-height: 1.65;
  display: block;
}
.dp-watch-item {
  padding: 6px 0;
  border-bottom: 1px solid rgba(0,0,0,0.03);
}
.dp-watch-item:last-child {
  border-bottom: none;
}
.dp-watch-type {
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #c4973e;
  display: inline-block;
}
.dp-watch-sep {
  font-size: 8px;
  color: #b8b0a0;
  display: inline-block;
  margin: 0 6px;
  vertical-align: middle;
}
.dp-watch-date {
  font-size: 10px;
  color: #8a8275;
  display: inline-block;
  margin-right: 6px;
}
.dp-watch-summary {
  font-size: 12px;
  color: #5a5550;
  display: block;
  margin-top: 2px;
  line-height: 1.5;
}
.dp-ask-details {
  margin-top: 12px;
  border: 1px solid rgba(196,151,62,0.12);
  border-radius: 4px;
}
.dp-ask-details-summary {
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #c4973e;
  padding: 8px 12px;
  cursor: pointer;
}
.dp-ask-details-body {
  padding: 0 12px 12px;
  font-size: 12px;
  color: #5a5550;
  line-height: 1.7;
}
.dp-loading-ask {
  font-size: 12px;
  color: #8a8275;
  font-style: italic;
  padding: 8px 0;
}
.dp-subline-status-mild {
  font-size: 12px;
  color: #8a8275;
  padding: 8px 0;
}

.dp-guidance-section {
  padding: 12px 20px 0;
}
.dp-guidance-empty {
  font-size: 12px;
  color: #8a8275;
  font-style: italic;
  padding: 4px 0 12px;
}

/* ── DaoVow Voice body ── */
.dp-voice-body {
  font-size: 14px;
  color: #3a3530;
  line-height: 1.75;
  padding: 4px 0 12px;
  font-family: 'Cormorant Garamond', serif;
}

/* ── Voice Blocks (DS three-block format) ── */
.dp-voice-block {
  margin-bottom: 16px;
}
.dp-voice-block:last-child {
  margin-bottom: 0;
}
.dp-voice-block-title {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #8a8275;
  margin-bottom: 6px;
  font-family: 'Inter', -apple-system, sans-serif;
}
.dp-voice-block-body {
  font-size: 14px;
  color: #3a3530;
  line-height: 1.75;
  font-family: 'Cormorant Garamond', serif;
}

/* ── Signal Details collapsed section ── */
.dp-signal-details {
  margin-top: 4px;
  border-top: 1px solid rgba(0,0,0,0.04);
  padding-top: 8px;
}
.dp-signal-details-summary {
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #8a8275;
  cursor: pointer;
  padding: 4px 0;
}
.dp-signal-details-body {
  padding: 4px 0;
}

/* ── Subline History (detail panel) ── */
#subline-history-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
#subline-history-container.dp-history-empty,
#subline-history-container.dp-history-loading {
  display: block;
}
.dp-history-empty {
  font-size: 12px;
  color: #9a9487;
  font-style: italic;
  padding: 8px 0 4px;
  line-height: 1.5;
}
.dp-history-loading {
  font-size: 12px;
  color: #b0a89b;
  padding: 8px 0 4px;
}

/* History card */
.dh-card {
  background: #f7f6f2;
  border: 1px solid #eae7e0;
  border-radius: 6px;
  padding: 10px 12px;
  margin-bottom: 2px;
}
.dh-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}
.dh-date {
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #8a8275;
}
.dh-badges {
  display: flex;
  gap: 4px;
}
.dh-badge {
  font-size: 9px;
  line-height: 1;
  padding: 2px 5px;
  border-radius: 3px;
  letter-spacing: 0.04em;
}
.dh-badge-fallback {
  background: #efeae2;
  color: #7a7265;
}
.dh-badge-ds {
  background: #e2e8f0;
  color: #4a5568;
}
.dh-badge-memory {
  background: #e6ede6;
  color: #4a6a4a;
}
.dh-badge-meihua {
  background: #ede6e6;
  color: #6a4a4a;
}
.dh-badge-timing {
  background: #e6edf0;
  color: #4a6a7a;
}
.dh-title {
  font-size: 12px;
  font-weight: 500;
  color: #2c2823;
  margin-bottom: 3px;
}
.dh-summary {
  font-size: 12px;
  color: #5a5548;
  line-height: 1.55;
  margin-bottom: 4px;
}
.dh-detail {
  display: flex;
  gap: 6px;
  font-size: 11px;
  line-height: 1.5;
  margin-top: 2px;
}
.dh-detail-label {
  color: #8a8275;
  flex-shrink: 0;
  min-width: 40px;
}
.dh-detail-text {
  color: #4a4538;
}
