:root {
  --wet-blue: #123c5a;
  --wet-teal: #0b6b73;
  --wet-pale: #eef6f7;
  --wet-warm: #fff8e7;
  --wet-line: #b7cbd1;
}

body {
  color: #20272b;
  line-height: 1.58;
}

h1,
h2,
h3 {
  color: var(--wet-blue);
  font-weight: 650;
}

/* Learning outcomes */

.learning-outcomes {
  background: #f2f7fa;
  border: 1px solid #9eb8c5;
  border-top: 5px solid var(--wet-blue);
  padding: 1rem 1.25rem;
  margin: 1.25rem 0 1.6rem;
  border-radius: 5px;
}

.learning-outcomes > :first-child {
  margin-top: 0;
  color: var(--wet-blue);
}

.learning-outcomes > :last-child {
  margin-bottom: 0;
}

/* Definitions */

.definition-box {
  background: linear-gradient(135deg, #eef7f7 0%, #f7fbfb 100%);
  border: 1px solid #9cc4c7;
  border-left: 5px solid var(--wet-teal);
  padding: 0.95rem 1.15rem;
  margin: 1.15rem 0;
  border-radius: 4px;
  box-shadow: 0 1px 2px rgba(18, 60, 90, 0.08);
}

.definition-box > :first-child {
  margin-top: 0;
  color: var(--wet-blue);
}

.definition-box > :last-child {
  margin-bottom: 0;
}

/* Theorems */

.theorem-box {
  background: #f7f4fb;
  border: 1px solid #b9add0;
  border-left: 5px solid #57447a;
  padding: 1rem 1.15rem;
  margin: 1.25rem 0;
  border-radius: 4px;
  box-shadow: 0 2px 5px rgba(65, 45, 95, 0.09);
}

.theorem-box > :first-child {
  margin-top: 0;
  color: #40305f;
}

.theorem-box > :last-child {
  margin-bottom: 0;
}

/* Worked examples */

.worked-example {
  background: #fff;
  border: 1px solid #b7c5cc;
  border-radius: 6px;
  box-shadow: 0 3px 10px rgba(18, 60, 90, 0.10);
  margin: 1.6rem 0 0.7rem;
  overflow: hidden;
  padding: 1.15rem 1.25rem 1.2rem;
}

.worked-example-title {
  display: block;
  background: linear-gradient(90deg, var(--wet-blue), #205f76);
  color: #fff;
  letter-spacing: 0.01em;
  margin: -1.15rem -1.25rem 1.05rem;
  padding: 0.8rem 1.25rem;
  font-size: 1.08rem;
  font-weight: 650;
}

/* Try It activities */

.try-it {
  background: #f6f8fa;
  border: 1px solid #cad5da;
  border-left: 4px solid #537f92;
  padding: 0.85rem 1rem;
  margin: 0.6rem 0 1.5rem;
  border-radius: 4px;
}

/* Applied problems */

.applied-problem {
  background: #fff8e7;
  border: 1px solid #d9c994;
  border-left: 5px solid #9a6b16;
  padding: 1rem 1.15rem;
  margin: 1.5rem 0;
  border-radius: 5px;
  box-shadow: 0 2px 5px rgba(90, 65, 20, 0.08);
}

.applied-problem > :first-child {
  margin-top: 0;
  color: #68480f;
}

.applied-problem > :last-child {
  margin-bottom: 0;
}

/* Practice sets and answers */

.practice-set {
  border-top: 2px solid #d5e0e4;
  margin-top: 1.6rem;
  padding-top: 0.3rem;
}

.answer-dropdown {
  background: #f5f8fa;
  border: 1px solid var(--wet-line);
  border-radius: 4px;
  padding: 0.55rem 0.75rem;
  margin: 0.45rem 0 1.1rem;
}

.answer-dropdown summary {
  color: var(--wet-blue);
  cursor: pointer;
}

.answer-dropdown[open] {
  padding-bottom: 0.8rem;
}

.print-answer {
  display: none;
}

/* GitBook navigation layout */

.book-summary nav[role="navigation"] {
  min-height: 100%;
}

.book-summary ul.summary {
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.book-summary ul.summary > li {
  flex-shrink: 0;
}

/* Main navigation entries */

.book-summary ul.summary li a {
  font-size: 15px;
  line-height: 1.45;
}

/* Book title above the contents */

.book-summary ul.summary li.toc-title a {
  color: var(--wet-blue);
  font-size: 18px;
  font-weight: 650;
  line-height: 1.3;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

/* Footer below the contents */

.book-summary ul.summary li.toc-footer {
  margin-top: auto;
  padding: 1rem 1.1rem;
  border-top: 1px solid #d6dde2;
  color: #5b6770;
  font-size: 13px;
  line-height: 1.5;
  cursor: default;
}

.book-summary ul.summary li.toc-footer span,
.book-summary ul.summary li.toc-footer a {
  font-size: 13px;
  line-height: 1.5;
}

.book-summary ul.summary li.toc-footer:hover {
  background: transparent;
}

/* Print formatting */

@media print {
  .answer-dropdown {
    display: block;
    background: #f5f8fa;
    border-left: 3px solid var(--wet-teal);
  }

  details.answer-dropdown:not([open]) > *:not(summary) {
    display: block !important;
  }

  .print-answer {
    display: none;
  }

  .worked-example,
  .definition-box,
  .theorem-box,
  .learning-outcomes,
  .applied-problem {
    break-inside: avoid;
  }
}