/* ============================================================
   Auhmline Studio — legal document pages (docs.css)
   Termly-generated documents keep their own embedded styles;
   this file frames them as a light "paper" card on the dark
   site canvas and polishes the typography for readability.
   main.css is linked first and provides nav/footer/theme.
   ============================================================ */

/* Paper card for the Termly document itself */
.document-previewer-wrapper-a717db {
  background: #ffffff !important;
  color: #1a1a1a;
  border-radius: 20px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(244, 240, 236, 0.07);
  padding: clamp(24px, 5vw, 56px) clamp(20px, 5vw, 56px);
  max-width: 960px;
  margin: 0 auto;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* ---------- Termly typography polish ----------
   Higher specificity + !important beats the embedded Termly
   <style> block (Arial 14px) and its inline span styles. */

body .document-previewer-wrapper-a717db [data-custom-class='title'] {
  font-family: "Space Grotesk", Arial, sans-serif !important;
  font-size: clamp(26px, 4vw, 32px) !important;
  color: #0a0b0f !important;
  letter-spacing: -0.01em;
  line-height: 1.25 !important;
  padding-bottom: 16px;
  border-bottom: 2px solid #0a0b0f;
  margin-bottom: 18px;
}

body .document-previewer-wrapper-a717db [data-custom-class='subtitle'] {
  font-size: 14px !important;
  color: #6b675f !important;
  line-height: 1.7 !important;
}

body .document-previewer-wrapper-a717db [data-custom-class='heading_1'] {
  font-family: "Space Grotesk", Arial, sans-serif !important;
  font-size: 20px !important;
  color: #0a0b0f !important;
  letter-spacing: -0.01em;
  line-height: 1.35 !important;
  margin-top: 10px;
}

body .document-previewer-wrapper-a717db [data-custom-class='heading_2'] {
  font-family: "Space Grotesk", Arial, sans-serif !important;
  font-size: 16.5px !important;
  color: #14151a !important;
  line-height: 1.4 !important;
}

body .document-previewer-wrapper-a717db [data-custom-class='body_text'],
body .document-previewer-wrapper-a717db [data-custom-class='body_text'] * {
  font-size: 15.5px !important;
  line-height: 1.8 !important;
  color: #3d3a36 !important;
}

body .document-previewer-wrapper-a717db [data-custom-class='link'] {
  color: #0a7f8c !important;
  text-decoration: underline;
  word-break: break-word !important;
}

/* Anchor jumps should land below the fixed top bar */
.document-previewer-wrapper-a717db a[name] { scroll-margin-top: calc(var(--nav-h, 64px) + 24px); }

/* Keep Termly tables readable inside the card */
.document-previewer-wrapper-a717db table {
  border-collapse: collapse;
  width: 100%;
  margin: 16px 0;
}

.document-previewer-wrapper-a717db th,
.document-previewer-wrapper-a717db td {
  border: 1px solid #d8dbe0;
  padding: 8px 12px;
  font-size: 14px;
  text-align: left;
}

/* Links inside the document stay readable on white */
.document-previewer-wrapper-a717db a {
  word-break: break-word;
}

/* ---------- Back-to-home links (outside the Termly window) ---------- */
main .container > p:first-child a {
  display: inline-block;
  padding: 9px 20px;
  border-radius: 999px;
  background: var(--surface, rgba(9, 10, 14, 0.68));
  border: 1px solid var(--border, rgba(255, 255, 255, 0.09));
  font-weight: 500;
}

main .container > center a {
  display: inline-block;
  margin-top: 28px;
  padding: 10px 24px;
  border-radius: 999px;
  background: var(--surface, rgba(9, 10, 14, 0.68));
  border: 1px solid var(--border, rgba(255, 255, 255, 0.09));
}

main .container > center a h3 {
  font-family: var(--font-display, sans-serif);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text, #f4f0ec);
}

/* Small screens: let the card breathe */
@media (max-width: 640px) {
  .document-previewer-wrapper-a717db {
    border-radius: 14px;
    padding: 22px 18px;
  }
}
