.ci-module {
  --ci-ink: #132c53;
  --ci-paper: #fffdf5;
  color: var(--ci-ink);
}
.ci-module * {
  box-sizing: border-box;
}
.ci-module h1 {
  font-size: clamp(1.9rem, 4.5vw, 3rem);
  line-height: 1.12;
  margin: 10px 0 20px;
}
.ci-module h2 {
  font-size: 1.5rem;
  margin: 8px 0 14px;
}
.ci-module p {
  line-height: 1.65;
}
.ci-module button {
  font: inherit;
  font-weight: 800;
  min-height: 48px;
  border: 2px solid var(--ci-ink);
  border-radius: 13px;
  color: var(--ci-ink);
  background: #ffe443;
  box-shadow: 3px 3px 0 var(--ci-ink);
  padding: 12px 18px;
  cursor: pointer;
}
.ci-module button:hover:not(:disabled) {
  transform: translateY(-2px);
}
.ci-module button:active:not(:disabled) {
  transform: translate(2px, 2px);
  box-shadow: none;
}
.ci-module :is(button, input, summary, a, [tabindex]):focus-visible {
  outline: 4px solid #2378c6;
  outline-offset: 4px;
}
.ci-module .ci-secondary {
  background: var(--ci-paper);
}
.ci-eyebrow {
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.09em;
}
.ci-hero {
  display: grid;
  grid-template-columns: 1fr 220px;
  align-items: center;
  gap: 30px;
  padding: 30px;
  margin: 10px 7px 34px 0;
  border: 3px solid var(--ci-ink);
  border-radius: 24px;
  box-shadow: 7px 7px 0 var(--ci-ink);
  background: #bca9ff;
}
.ci-hero p {
  max-width: 580px;
}
.ci-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 20px;
}
.ci-hero-example {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  background: var(--ci-paper);
  border: 3px solid var(--ci-ink);
  border-radius: 19px;
  padding: 22px 14px;
  transform: rotate(3deg);
  box-shadow: 5px 5px 0 var(--ci-ink);
}
.ci-hero-example :is(span, strong) {
  font-size: 1.65rem;
  font-weight: 900;
}
.ci-hero-example strong {
  background: #ffe443;
  border-radius: 8px;
  padding: 5px 12px;
}
.ci-hero-example small {
  font-size: 0.83rem;
}
.ci-section-head {
  display: flex;
  gap: 15px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
.ci-badge {
  padding: 7px 12px;
  border: 2px solid var(--ci-ink);
  border-radius: 30px;
  background: var(--ci-paper);
  font-size: 0.85rem;
  font-weight: 800;
}
.ci-lessons progress {
  width: 100%;
  height: 13px;
  accent-color: #6842bc;
  margin: 5px 0 22px;
}
.ci-lesson-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 15px;
}
.ci-module .ci-lesson-card {
  display: flex;
  align-items: center;
  gap: 15px;
  text-align: left;
  background: var(--ci-paper);
  padding: 18px;
}
.ci-lesson-card strong,
.ci-lesson-card small {
  display: block;
}
.ci-lesson-card strong {
  line-height: 1.35;
}
.ci-lesson-card small {
  font-weight: 400;
  font-size: 0.83rem;
  margin-top: 7px;
}
.ci-lesson-number {
  width: 36px;
  height: 36px;
  border: 2px solid var(--ci-ink);
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #bca9ff;
  flex-shrink: 0;
}
.ci-complete .ci-lesson-number {
  background: #a8ebbb;
}
.ci-note {
  font-size: 0.91rem;
  color: #40506a;
}
.ci-calculator {
  border: 3px solid var(--ci-ink);
  border-radius: 22px;
  background: var(--ci-paper);
  padding: 28px;
  margin: 32px 0;
}
.ci-fields {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 24px 0;
}
.ci-fields label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.94rem;
  font-weight: 800;
}
.ci-fields input {
  width: 100%;
  min-height: 48px;
  border: 2px solid #75839a;
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  background: white;
  color: var(--ci-ink);
}
.ci-fields button {
  grid-column: 1 / -1;
  justify-self: start;
  min-width: 180px;
}
.ci-totals {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 24px 0;
}
.ci-totals > div {
  border: 2px solid #c3c7d6;
  border-radius: 14px;
  padding: 17px;
  min-width: 0;
  background: #f2f2f8;
}
.ci-totals span {
  display: block;
  font-size: 0.88rem;
  line-height: 1.4;
}
.ci-totals strong {
  display: block;
  font-size: clamp(1rem, 2.2vw, 1.55rem);
  margin-top: 9px;
  overflow-wrap: anywhere;
}
.ci-totals .ci-total {
  background: #e9e0ff;
  border-color: #6842bc;
}
.ci-chart {
  margin: 26px 0;
}
.ci-chart figcaption {
  font-weight: 800;
  font-size: 1.15rem;
}
.ci-chart svg {
  display: block;
  width: 100%;
  max-height: 360px;
  margin-top: 12px;
}
.ci-chart svg text {
  font:
    14px "Segoe UI",
    Arial,
    sans-serif;
  fill: #40506a;
}
.ci-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 22px;
  font-size: 0.86rem;
  line-height: 1.5;
}
.ci-legend span::before {
  content: "";
  display: inline-block;
  width: 24px;
  margin-right: 8px;
  vertical-align: middle;
  border-top: 4px solid #6842bc;
}
.ci-legend .ci-green::before {
  border-color: #13785d;
  border-style: dashed;
}
.ci-legend .ci-gray::before {
  border-color: #44556f;
  border-style: dotted;
}
.ci-details {
  background: var(--ci-paper);
  border: 1px solid #c3c7d6;
  border-radius: 12px;
  padding: 15px 18px;
  margin: 15px 0;
}
.ci-details summary {
  cursor: pointer;
  font-weight: 800;
  line-height: 1.4;
}
.ci-details p {
  font-size: 0.94rem;
}
.ci-details a {
  color: #56349e;
  text-underline-offset: 3px;
}
.ci-table-scroll {
  overflow-x: auto;
  margin-top: 15px;
}
.ci-module table {
  border-collapse: collapse;
  width: 100%;
  min-width: 440px;
  font-size: 0.91rem;
}
.ci-module th,
.ci-module td {
  text-align: right;
  padding: 10px;
  border-bottom: 1px solid #c3c7d6;
}
.ci-module th:first-child {
  text-align: left;
}
.ci-module th {
  background: #f0eaff;
}
.ci-diary-link {
  background: #a8ebbb;
  border: 3px solid var(--ci-ink);
  border-radius: 18px;
  padding: 24px;
  display: flex;
  align-items: center;
  gap: 24px;
  justify-content: space-between;
}
.ci-diary-link p {
  max-width: 660px;
  margin-bottom: 0;
}
.ci-diary-link button {
  flex-shrink: 0;
}
.ci-lesson {
  max-width: 850px;
  margin: 0 auto;
  padding: 28px;
  border: 3px solid var(--ci-ink);
  border-radius: 24px;
  background: var(--ci-paper);
}
.ci-lesson > .ci-section-head {
  margin: 26px 0 15px;
}
.ci-story {
  font-size: 1.12rem;
}
.ci-example {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: #efe8ff;
  border: 2px solid var(--ci-ink);
  border-radius: 16px;
  padding: 22px 18px;
  margin: 28px 0;
}
.ci-example span {
  font-weight: 800;
  text-align: center;
  line-height: 1.45;
}
.ci-example-end {
  background: #ffe443;
  padding: 7px 12px;
  border-radius: 9px;
}
.ci-module fieldset {
  border: 0;
  padding: 0;
  margin: 0 0 22px;
  min-width: 0;
}
.ci-module legend {
  font-weight: 800;
  line-height: 1.5;
  font-size: 1.13rem;
  padding: 0;
  margin: 0 0 17px;
}
.ci-choices {
  display: grid;
  gap: 12px;
}
.ci-choice {
  display: flex;
  align-items: center;
  gap: 13px;
  border: 2px solid #78859b;
  border-radius: 13px;
  padding: 16px;
  min-height: 60px;
  cursor: pointer;
  line-height: 1.45;
  background: white;
}
.ci-choice:has(input:checked),
.ci-chosen {
  border-color: #6842bc;
  background: #ede6ff;
}
.ci-choice input {
  width: 22px;
  height: 22px;
  margin: 0;
  accent-color: #6842bc;
  flex-shrink: 0;
}
.ci-module fieldset:disabled .ci-choice {
  cursor: default;
}
.ci-feedback {
  border: 2px solid var(--ci-ink);
  border-radius: 15px;
  padding: 22px;
  margin-top: 22px;
  background: #fff1bd;
}
.ci-feedback-correct {
  background: #d5f4dc;
}
.ci-feedback h2 {
  font-size: 1.25rem;
}
.ci-report li {
  line-height: 1.6;
}
@media (max-width: 760px) {
  .ci-hero {
    grid-template-columns: 1fr;
    padding: 23px;
  }
  .ci-hero-example {
    display: none;
  }
  .ci-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .ci-totals {
    grid-template-columns: 1fr;
  }
  .ci-totals > div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
  }
  .ci-totals strong {
    margin-top: 0;
  }
  .ci-diary-link {
    flex-direction: column;
    align-items: stretch;
  }
  .ci-calculator {
    padding: 20px;
  }
}
@media (max-width: 520px) {
  .ci-lesson-grid {
    grid-template-columns: 1fr;
  }
  .ci-hero {
    margin-right: 5px;
    box-shadow: 5px 5px 0 var(--ci-ink);
  }
  .ci-lesson {
    padding: 18px;
    border-radius: 18px;
  }
  .ci-story {
    font-size: 1rem;
  }
  .ci-module h1 {
    font-size: 1.9rem;
  }
  .ci-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .ci-fields {
    gap: 14px 10px;
  }
  .ci-fields label {
    font-size: 0.85rem;
  }
  .ci-fields input {
    padding: 10px 8px;
  }
  .ci-calculator {
    padding: 17px;
  }
  .ci-section-head {
    gap: 9px;
  }
  .ci-legend {
    display: grid;
    gap: 9px;
  }
  .ci-example {
    padding: 16px 10px;
    gap: 9px;
  }
  .ci-example span {
    font-size: 0.91rem;
  }
  .ci-chart svg text {
    font-size: 16px;
  }
  .ci-note {
    font-size: 0.85rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  .ci-module button:hover:not(:disabled),
  .ci-module button:active:not(:disabled) {
    transform: none;
  }
}
