/* ============================================================
   HeartRead Report — shared report styles
   Used by index.html (live report) and sample-report.html.
   Visual system per design spec: restrained purple palette,
   text-first, only two allowed motions (AuraCard gradient,
   module fade-in). Print + reduced-motion fallbacks included.
   ============================================================ */

.report-root,
.report-page {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: #2A2833;
  line-height: 1.78;
}

.report-header {
  text-align: center;
  margin-bottom: 36px;
  padding-bottom: 24px;
  border-bottom: 1px solid #E1D9E8;
}
.report-header h1 {
  color: #684280;
  font-weight: 500;
  font-size: 24px;
  margin-bottom: 6px;
}
.report-header .subtitle {
  color: #746E80;
  font-size: 14px;
}
.report-meta {
  margin-top: 12px;
  font-size: 13px;
  color: #868094;
}

/* ---- Report module card ---- */
.report-root .section,
.report-page .section {
  position: relative;
  background: #ffffff;
  border-radius: 16px;
  padding: 26px 28px;
  margin-bottom: 20px;
  box-shadow: 0 1px 6px rgba(104, 66, 128, 0.06);
  opacity: 0;
  transform: translateY(12px);
  animation: fadeInUp 0.6s ease forwards;
}
/* Fine corner-cut line decorations (top-left / bottom-right) */
.report-root .section::before,
.report-page .section::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 8px;
  width: 16px;
  height: 16px;
  border-top: 1px solid rgba(104, 66, 128, 0.22);
  border-left: 1px solid rgba(104, 66, 128, 0.22);
  border-radius: 4px 0 0 0;
  pointer-events: none;
}
.report-root .section::after,
.report-page .section::after {
  content: "";
  position: absolute;
  bottom: 8px;
  right: 8px;
  width: 16px;
  height: 16px;
  border-bottom: 1px solid rgba(104, 66, 128, 0.22);
  border-right: 1px solid rgba(104, 66, 128, 0.22);
  border-radius: 0 0 4px 0;
  pointer-events: none;
}

/* Staggered module fade-in (the only entrance motion allowed) */
.report-root .section:nth-of-type(1), .report-page .section:nth-of-type(1) { animation-delay: 0.05s; }
.report-root .section:nth-of-type(2), .report-page .section:nth-of-type(2) { animation-delay: 0.15s; }
.report-root .section:nth-of-type(3), .report-page .section:nth-of-type(3) { animation-delay: 0.25s; }
.report-root .section:nth-of-type(4), .report-page .section:nth-of-type(4) { animation-delay: 0.35s; }
.report-root .section:nth-of-type(5), .report-page .section:nth-of-type(5) { animation-delay: 0.45s; }
.report-root .section:nth-of-type(6), .report-page .section:nth-of-type(6) { animation-delay: 0.55s; }
.report-root .section:nth-of-type(7), .report-page .section:nth-of-type(7) { animation-delay: 0.65s; }
.report-root .section:nth-of-type(8), .report-page .section:nth-of-type(8) { animation-delay: 0.75s; }

@keyframes fadeInUp {
  to { opacity: 1; transform: translateY(0); }
}

.report-root .section h2,
.report-page .section h2 {
  font-size: 16px;
  font-weight: 500;
  color: #684280;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 9px;
}
/* Small diamond marker instead of emoji/icon fonts */
.report-root .section h2::before,
.report-page .section h2::before {
  content: "";
  width: 7px;
  height: 7px;
  background: #8C61AD;
  opacity: 0.7;
  transform: rotate(45deg);
  flex: none;
}

/* ---- Tags: outline + very low fill, text-marker feel ---- */
.tags-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 12px 0 16px;
}
.tag {
  background: rgba(104, 66, 128, 0.06);
  border: 1px solid rgba(104, 66, 128, 0.22);
  color: #684280;
  padding: 4px 13px;
  border-radius: 999px;
  font-size: 14px;
}

.field-label {
  font-size: 13px;
  color: #746E80;
  margin: 10px 0 2px;
}

.intensity-note {
  font-size: 15px;
  color: #4B4858;
  margin: 8px 0 12px;
}

/* ---- Quote block: pilcrow annotation mark + gradient left tint ---- */
.quote-block {
  position: relative;
  background: linear-gradient(90deg, rgba(154, 116, 188, 0.08), transparent 70%);
  padding: 14px 18px;
  margin: 14px 0;
  border-radius: 0 10px 10px 0;
}
.quote-block::before {
  content: "¶";
  position: absolute;
  top: 6px;
  right: 12px;
  font-size: 13px;
  color: #9A74BC;
  opacity: 0.6;
}
.quote-block cite {
  font-style: italic;
  color: #444152;
}
.quote-sup {
  font-size: 12px;
  vertical-align: super;
  color: #746E80;
}

/* ---- Reading-bias item: terracotta accent (deviation hint color) ---- */
.bias-item {
  border: 1px solid #E9D8CE;
  border-left: 3px solid #B9724E;
  background: rgba(249, 243, 239, 0.35);
  padding: 16px 18px;
  border-radius: 0 10px 10px 0;
  margin: 14px 0;
}
.bias-item h4 {
  font-size: 14px;
  color: #945A3C;
  margin-bottom: 6px;
  font-weight: 500;
}

/* ---- Dual-perspective micro markers ---- */
.perspective-row {
  position: relative;
  padding-left: 12px;
  margin: 10px 0;
}
.perspective-row.inner::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 3px;
  height: 18px;
  background: #9A74BC;
  opacity: 0.65;
}
.perspective-row.receiver::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 3px;
  height: 18px;
  background: #B9724E;
  opacity: 0.65;
}
.perspective-label {
  font-size: 13px;
  color: #777285;
  display: inline-block;
  margin: 6px 0 2px;
}

/* Soft divider with both ends fading to transparent */
.divider-soft {
  height: 1px;
  margin: 16px 0;
  background: linear-gradient(90deg, transparent, #DCD4E2, transparent);
  border: none;
}

/* ---- Insight weight: thin 2px side marker + weight 500 (no color change) ---- */
.insight-high {
  position: relative;
  padding-left: 14px;
  font-weight: 500;
}
.insight-high::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 2px;
  height: 20px;
  background: #9A74BC;
  opacity: 0.55;
}
.insight-normal {
  font-weight: 400;
}

/* ---- AuraCard: the single strong-color, single animated element ---- */
.aura-card {
  background: linear-gradient(145deg, #8C61AD, #684280, #7A5499);
  background-size: 200% 200%;
  animation: slowShimmer 8s ease-in-out infinite alternate;
  color: #ffffff;
  border-radius: 20px;
  padding: 30px 28px;
  margin: 12px 0 8px;
}
@keyframes slowShimmer {
  0% { background-position: 0% 0%; }
  100% { background-position: 100% 100%; }
}
.aura-card h3 {
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 12px;
}
.aura-keywords {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 14px;
}
.aura-kw {
  background: rgba(255, 255, 255, 0.2);
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 14px;
}
.aura-stamp {
  margin-top: 16px;
  font-size: 15px;
  opacity: 0.92;
}

.closing-note {
  background: #F8F5FB;
  padding: 20px 22px;
  border-radius: 14px;
  margin-top: 10px;
  font-size: 15px;
  color: #534F60;
}

/* ---- Footnote area at the bottom of the report ---- */
.footnote-area {
  margin-top: 28px;
  font-size: 12px;
  color: #746E80;
  border-top: 1px solid #E8E3ED;
  padding-top: 16px;
}

/* ============================================================
   Sample page — frosted-glass lock veil over paid modules
   ============================================================ */
.section.locked .lock-blur {
  filter: blur(5px);
  user-select: none;
  pointer-events: none;
}
.unlock-veil {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-align: center;
  padding: 24px;
  background: rgba(244, 241, 247, 0.55);
  border-radius: 16px;
}
.unlock-veil p {
  font-size: 15px;
  color: #2A2833;
  max-width: 420px;
  font-weight: 500;
}
.sample-banner {
  background: #684280;
  color: #ffffff;
  text-align: center;
  font-size: 13px;
  letter-spacing: 2px;
  padding: 7px 12px;
}

/* ============================================================
   Accessibility: reduced motion — kill every CSS animation
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .aura-card { animation: none !important; }
  .report-root .section,
  .report-page .section { animation: none !important; opacity: 1; transform: none; }
}

/* ============================================================
   Print / PDF fallback
   ============================================================ */
@media print {
  .report-root .section,
  .report-page .section {
    box-shadow: none;
    opacity: 1;
    transform: none;
    animation: none !important;
    page-break-inside: avoid;
  }
  .aura-card {
    animation: none !important;
    background: #684280; /* fixed solid fallback */
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .tag, .quote-block, .closing-note, .bias-item {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .unlock-veil { display: none; }
  .section.locked .lock-blur { filter: blur(5px); } /* sample stays locked in print */
  .sample-banner {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}
