/* Risks page and page-level polish. Loaded after the brand layer. Flat graphics only; no data is drawn here. */

html body .learn-shell {
  max-width: 1120px;
  margin: 0 auto;
  padding: 48px 32px 96px;
}

html body .risk-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 24px 56px;
  align-items: end;
  padding-bottom: 40px;
  border-bottom: var(--sc-rule);
}

html body .risk-intro h1 {
  grid-column: 1;
  margin: 0 !important;
}

html body .risk-intro > p:not(.risk-kicker) {
  grid-column: 2;
  margin: 0;
  font-size: 17px;
  line-height: 1.6;
  color: var(--sc-ink-2);
}

html body .risk-kicker {
  grid-column: 1 / -1;
  font-size: 12px !important;
  font-weight: 600 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase;
  color: var(--sc-accent) !important;
  margin: 0 !important;
}

html body .risk-topics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  border-bottom: var(--sc-rule);
}

html body .risk-topics article {
  padding: 32px 32px 32px 0;
  border-bottom: var(--sc-rule);
}

html body .risk-topics article:nth-child(odd) {
  border-right: var(--sc-rule);
}

html body .risk-topics article:nth-child(even) {
  padding-left: 32px;
}

html body .risk-topics h2 {
  font-size: 20px !important;
  margin: 0 0 10px !important;
  padding-left: 48px;
  position: relative;
}

html body .risk-topics h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: -2px;
  width: 32px;
  height: 32px;
  background-color: var(--sc-accent);
  -webkit-mask: var(--sc-icon) center / contain no-repeat;
  mask: var(--sc-icon) center / contain no-repeat;
}

html body .risk-topics article:nth-child(1) { --sc-icon: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'><path d='M16 4 L28 26 H4 Z' fill='none' stroke='black' stroke-width='2.2' stroke-linejoin='round'/><line x1='16' y1='13' x2='16' y2='19' stroke='black' stroke-width='2.2'/><circle cx='16' cy='22.5' r='1.4' fill='black'/></svg>"); }
html body .risk-topics article:nth-child(2) { --sc-icon: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'><path d='M4 22 L11 14 L17 19 L28 8' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/><circle cx='28' cy='8' r='2' fill='black'/></svg>"); }
html body .risk-topics article:nth-child(3) { --sc-icon: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'><circle cx='16' cy='16' r='12' fill='none' stroke='black' stroke-width='2.2'/><path d='M16 9 V16 L21 19' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'/></svg>"); }
html body .risk-topics article:nth-child(4) { --sc-icon: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'><path d='M4 26 H28' stroke='black' stroke-width='2.2'/><rect x='7' y='16' width='4' height='10' fill='black'/><rect x='14' y='11' width='4' height='15' fill='black'/><rect x='21' y='6' width='4' height='20' fill='black'/></svg>"); }

html body .risk-topics p {
  margin: 0;
  padding-left: 48px;
  color: var(--sc-ink-2);
  font-size: 15px;
  line-height: 1.6;
}

html body .tokenized-stock-note {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  margin: 48px 0;
  padding: 24px 0 24px 24px;
  border-left: 2px solid var(--sc-accent);
}

html body .tokenized-stock-note h2 {
  font-size: 20px !important;
  margin: 0 0 8px !important;
}

html body .tokenized-stock-note p {
  margin: 0;
  color: var(--sc-ink-2);
}

html body .tokenized-stock-note > a {
  color: var(--sc-accent);
  font-weight: 600;
  white-space: nowrap;
}

html body .risk-example {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 48px;
  align-items: start;
  padding: 40px 0;
  border-top: var(--sc-rule);
}

html body .risk-example-copy h2 {
  margin: 0 0 16px !important;
}

html body .risk-example-copy p {
  margin: 0 0 12px;
  color: var(--sc-ink-2);
  line-height: 1.6;
}

html body .risk-example-graphic {
  border: var(--sc-rule);
  border-radius: var(--sc-radius-panel);
  padding: 24px;
  background: var(--sc-surface);
}

html body .risk-example-line {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--sc-ink-2);
  margin-bottom: 8px;
}

html body .risk-example-line strong {
  color: var(--sc-ink);
  font-variant-numeric: tabular-nums;
}

html body .risk-example-bar {
  height: 10px;
  background: var(--sc-elevated);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 20px;
}

html body .risk-example-bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
}

html body .risk-collateral-bar i {
  width: 100%;
  background: var(--sc-accent);
}

html body .risk-debt-bar i {
  width: 50%;
  background: var(--sc-ink-2);
}

html body .risk-example-marker {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-top: 16px;
  border-top: var(--sc-rule);
  font-size: 14px;
  color: var(--sc-ink-2);
}

html body .risk-example-marker strong {
  color: var(--sc-danger);
}

html body .risk-review-note {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 13px;
  color: var(--sc-ink-2) !important;
}

html body small,
html body .risk-icon,
html body .market-overview small,
html body .overview-stats small,
html body .market-overview .overview-stats small {
  color: var(--sc-ink-2) !important;
}

html body .faq-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 56px;
  padding-top: 40px;
  border-top: var(--sc-rule);
}

html body .faq details {
  border-bottom: var(--sc-rule);
  padding: 18px 0;
}

html body .faq details:first-child {
  border-top: var(--sc-rule);
}

html body .faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 16px;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

html body .faq summary::-webkit-details-marker {
  display: none;
}

html body .faq summary::after {
  content: "+";
  font-weight: 400;
  color: var(--sc-ink-2);
}

html body .faq details[open] summary::after {
  content: "−";
}

html body .faq details p {
  margin: 12px 0 0;
  color: var(--sc-ink-2);
  line-height: 1.6;
}

@media (max-width: 960px) {
  html body .risk-intro,
  html body .risk-example,
  html body .faq-layout,
  html body .tokenized-stock-note {
    grid-template-columns: minmax(0, 1fr);
  }

  html body .risk-intro > p:not(.risk-kicker) {
    grid-column: 1;
  }

  html body .risk-topics {
    grid-template-columns: minmax(0, 1fr);
  }

  html body .risk-topics article:nth-child(odd) {
    border-right: none;
  }

  html body .risk-topics article:nth-child(even) {
    padding-left: 0;
  }
}

@media (max-width: 640px) {
  html body .learn-shell {
    padding: 32px 16px 72px;
  }

  html body header .site-nav {
    order: 3;
    width: 100%;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  html body.app-mode header nav.site-nav > a[href] {
    display: inline-flex !important;
    white-space: nowrap;
  }

  html body header .wallet,
  html body header #wallet {
    min-height: 36px;
    padding: 8px 12px;
    white-space: nowrap;
    width: auto !important;
    min-width: max-content;
    max-width: none;
    font-size: 13px !important;
  }

  html body header .header-actions {
    margin-left: auto;
  }
}
