/* ==========================================================================
   Document page (Whitepaper) — reading experience
   ========================================================================== */

.doc-header {
  padding: 22px 0;
  border-bottom: 1px solid rgba(197, 162, 111, 0.14);
  background: rgba(8, 8, 10, 0.72);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  position: sticky;
  top: 0;
  z-index: 50;
}
.doc-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.doc-header__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.doc {
  padding: 72px 0 100px;
  position: relative;
  z-index: 1;
}
.doc__container {
  display: flex;
  justify-content: center;
}
.doc__paper {
  max-width: 760px;
  width: 100%;
  padding: 64px;
  border-radius: 24px;
  box-shadow: 0 40px 100px -40px rgba(0, 0, 0, 0.65);
}

.doc__title {
  font-family: var(--font-serif);
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 600;
  margin: 10px 0 8px;
  line-height: 1.1;
}
.doc__subtitle {
  font-size: 16px;
  color: var(--text-dim);
  font-style: italic;
  margin-bottom: 8px;
}
.doc__divider {
  height: 1px;
  background: linear-gradient(90deg, rgba(197,162,111,0.5), rgba(197,162,111,0.05));
  margin: 32px 0;
}

.doc__paper section {
  margin-bottom: 34px;
}
.doc__paper section:last-of-type {
  margin-bottom: 0;
}
.doc__paper h2 {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 600;
  color: var(--gold-bright);
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.doc__paper h3 {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
  margin: 20px 0 8px;
}
.doc__paper h3:first-of-type {
  margin-top: 4px;
}
.doc__paper p {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-dim);
  margin-bottom: 12px;
}
.doc__paper ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 4px 0 12px;
}
.doc__paper li {
  position: relative;
  padding-left: 22px;
  font-size: 15px;
  line-height: 1.75;
  color: var(--text-dim);
}
.doc__paper li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
}
.doc__paper li strong {
  color: var(--text);
  font-weight: 600;
}

.doc__footer-note {
  font-size: 12.5px;
  color: var(--text-faint);
  text-align: center;
}

/* ---- v3 additions: tags, audit banner, callouts, data tables ---- */
.doc__tags {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 600;
  margin-top: 4px;
}

.doc__banner {
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: center;
  padding: 20px 24px;
  margin: 0 0 32px;
  border-radius: 16px;
  border: 1px solid rgba(111, 207, 151, 0.4);
  background: rgba(111, 207, 151, 0.08);
}
.doc__banner-title {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #6FCF97;
}
.doc__banner-sub { font-size: 12.5px; color: var(--text-dim); line-height: 1.6; }

.doc__callout {
  margin: 16px 0 4px;
  padding: 4px 20px;
  border-left: 3px solid var(--gold);
  background: rgba(197, 162, 111, 0.05);
  border-radius: 0 10px 10px 0;
}
.doc__callout p {
  font-size: 14px;
  font-style: italic;
  color: var(--text-dim);
  margin: 12px 0;
}

.doc__table-wrap { overflow-x: auto; margin: 16px 0 8px; }
.doc__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  min-width: 460px;
}
.doc__table caption {
  caption-side: top;
  text-align: left;
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  padding-bottom: 10px;
}
.doc__table thead th {
  text-align: left;
  font-weight: 600;
  color: var(--gold-bright);
  font-size: 11.5px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(197, 162, 111, 0.3);
}
.doc__table td {
  padding: 11px 14px;
  color: var(--text-dim);
  line-height: 1.6;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  vertical-align: top;
}
.doc__table tbody tr:last-child td { border-bottom: none; }
.doc__table td:first-child {
  color: var(--text);
  font-weight: 600;
  white-space: nowrap;
}
.doc__table td:first-child:not(:only-child) { width: 1%; }

@media (max-width: 620px) {
  .doc__paper { padding: 36px 26px; border-radius: 18px; }
  .doc { padding: 48px 0 70px; }
  .doc-header__inner { flex-wrap: wrap; row-gap: 12px; }
  .doc-header__actions { width: 100%; }
  .doc-header__actions .btn { flex: 1; padding: 9px 12px; font-size: 12.5px; white-space: nowrap; }
}
