/* Remove weird floating top box */
body > div:first-child,
body > iframe:first-child,
body > section:first-child {
  display: none !important;
}

/* If Termly injects a badge/logo */
[class*="badge"],
[class*="logo"],
[class*="floating"],
[id*="badge"],
[id*="logo"] {
  display: none !important;
}


* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root{
  --bg: #f3f3f3;
  --card: #ffffff;
  --border: #e7e7e7;

  --text: #111111;
  --muted: #555555;

  --gold: #d4af37;
}

body {
  background: var(--bg) !important;
  font-family: Arial, Helvetica, sans-serif !important;
  color: var(--text) !important;

  padding: 20px 20px 60px !important;
  line-height: 1.8 !important;
}

/* REMOVE weird floating top elements */
body > div:first-child:empty,
body > div:first-child:not(:has(*)) {
  display: none !important;
}

/* Main Termly container */
body > * {
  max-width: 1050px !important;

  margin: 0 auto !important;

  background: #ffffff !important;

  border: 1px solid #e7e7e7 !important;
  border-radius: 30px !important;

  padding: 70px !important;

  box-shadow:
    0 10px 40px rgba(0,0,0,0.04) !important;
}


/* Main heading */
h1 {
  font-size: 4rem !important;
  font-weight: 800 !important;

  color: #000 !important;

  margin-top: -10px !important;
  margin-bottom: 18px !important;

  letter-spacing: -2px !important;
  line-height: 1 !important;

  position: relative;
}

/* Gold accent line */
h1::after {
  content: "";

  display: block;

  width: 120px;
  height: 5px;

  margin-top: 18px;

  border-radius: 20px;

  background:
    linear-gradient(
      90deg,
      var(--gold),
      transparent
    );
}

/* Section headings */
h2, h3, h4, h5, h6 {
  color: #000 !important;

  margin-top: 50px !important;
  margin-bottom: 18px !important;

  font-weight: 700 !important;
}

/* Text */
p, li, td, th {
  color: var(--muted) !important;
  font-size: 1.03rem !important;
}

/* Paragraph spacing */
p {
  margin-bottom: 18px !important;
}

/* Lists */
ul, ol {
  padding-left: 24px !important;
  margin-bottom: 28px !important;
}

li {
  margin-bottom: 12px !important;
}

/* Links */
a {
  color: #000 !important;
  text-decoration: underline !important;
  text-decoration-color: var(--gold) !important;
  text-underline-offset: 4px;
}

/* Tables */
table {
  width: 100% !important;
  border-collapse: collapse !important;
  margin: 30px 0 !important;
}

td, th {
  border: 1px solid var(--border) !important;
  padding: 14px !important;
}

/* Remove ugly inline backgrounds Termly sometimes adds */
div, section, article {
  background-color: transparent !important;
}

/* Mobile */
@media (max-width: 768px){

  body{
    padding: 20px 12px !important;
  }

  body > *{
    padding: 34px 24px !important;
    border-radius: 22px !important;
  }

  h1{
    font-size: 2.6rem !important;
  }

  h2{
    font-size: 1.5rem !important;
  }
}	

/* Pull title upward */
h1:first-of-type {
  margin-top: -25px !important;
}

/* Hide Termly logo/banner safely */
span[style*="background: url(data:image/svg+xml;base64"] {
  display: none !important;
}