.theory-chapter {
  margin: 1.4rem 0;
  padding: clamp(1rem, 2vw, 1.5rem);
  border: 1px solid color-mix(in srgb, var(--course-accent, #47b8c8) 40%, #cbd5e1);
  border-radius: 18px;
  background: linear-gradient(145deg, color-mix(in srgb, var(--course-accent, #47b8c8) 8%, #fff), #fff 62%);
  box-shadow: 0 14px 34px rgba(15, 23, 42, .07);
}
.theory-chapter > header { display:flex; gap:.8rem; align-items:flex-start; margin-bottom:.8rem; }
.theory-chapter .theory-icon { display:grid; place-items:center; flex:0 0 42px; height:42px; border-radius:12px; color:#fff; background:var(--course-accent, #47b8c8); }
.theory-chapter .theory-kicker { display:block; color:var(--course-accent-2, #2f718d); font-size:.72rem; font-weight:800; letter-spacing:.12em; text-transform:uppercase; }
.theory-chapter h3 { margin:.15rem 0 0; color:#0f2740; font-family:'Barlow Condensed', sans-serif; font-size:1.45rem; }
.theory-chapter p { color:#334155; line-height:1.78; }
.theory-chapter ul { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:.65rem; margin:1rem 0 0; padding:0; list-style:none; }
.theory-chapter li { padding:.75rem; border-radius:12px; background:rgba(255,255,255,.76); border:1px solid #e2e8f0; color:#334155; font-size:.9rem; }
.theory-chapter li i { margin-right:.35rem; color:var(--course-accent-2, #2f718d); }
.theory-formula { margin-top:1rem; padding:.8rem 1rem; border-radius:10px; color:#0f2740; background:color-mix(in srgb, var(--course-accent, #47b8c8) 12%, #fff); font-weight:800; text-align:center; }
.course-theory-media { margin:1.35rem 0; overflow:hidden; border-radius:18px; border:1px solid #dbe4ee; background:#f8fafc; }
.course-theory-media img { display:block; width:100%; max-height:430px; object-fit:contain; background:#fff; }
.course-theory-media figcaption { padding:.8rem 1rem; color:#475569; font-size:.88rem; line-height:1.5; }
.course-theory-media figcaption a { color:var(--course-accent-2, #2f718d); font-weight:700; }
.course-references { margin:1.3rem 0; padding:1rem 1.1rem; border-radius:14px; background:#f1f5f9; border-left:4px solid var(--course-accent, #47b8c8); }
.course-references h3 { margin:0 0 .55rem; color:#0f2740; font-size:1rem; }
.course-references a { color:#245f76; overflow-wrap:anywhere; }
.legacy-theory-dossier { margin:1.2rem 0 1.5rem; padding:1.2rem; border-radius:16px; background:linear-gradient(145deg,#f8fbfd,#eef6f8); border:1px solid #b9dce3; color:#263b4b; }
.legacy-theory-dossier h3 { margin:.15rem 0 .5rem; color:#102f43; }
.legacy-theory-dossier > p { line-height:1.7; }
.legacy-theory-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:.7rem; margin-top:1rem; }
.legacy-theory-item { padding:.85rem; border-radius:12px; background:#fff; border:1px solid #d8e8ec; }
.legacy-theory-item strong { display:block; margin-bottom:.25rem; color:#126b78; }
.legacy-theory-item span { line-height:1.55; }
.legacy-theory-refs { margin:.8rem 0 0; font-size:.88rem; }
.legacy-theory-refs a { color:#0f7180; font-weight:700; }
.legacy-module-deepening { margin:1.2rem 0 1.6rem; padding:clamp(1rem,2.2vw,1.45rem); border:1px solid #c4dce2; border-radius:18px; color:#263b4b; background:linear-gradient(145deg,#fff 0%,#f2f8fa 100%); box-shadow:0 14px 32px rgba(15,47,67,.08); }
.legacy-module-deepening > header { padding-bottom:.75rem; border-bottom:1px solid #d7e6ea; }
.legacy-module-deepening h3 { margin:.18rem 0 0; color:#102f43; font-size:clamp(1.25rem,2vw,1.55rem); }
.legacy-module-deepening > p { line-height:1.75; color:#334b5b; }
.legacy-deepening-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:.75rem; margin:1rem 0; }
.legacy-deepening-grid article { padding:1rem; border:1px solid #d9e7ea; border-radius:14px; background:#fff; }
.legacy-deepening-grid article > i { display:grid; place-items:center; width:2.2rem; height:2.2rem; margin-bottom:.55rem; border-radius:10px; color:#fff; background:#187988; }
.legacy-deepening-grid h4 { margin:0 0 .45rem; color:#174c5b; }
.legacy-deepening-grid p { margin:0; line-height:1.62; font-size:.94rem; color:#405665; }
.legacy-decision-route { margin:1rem 0; padding:1rem 1.1rem; border-radius:14px; border-left:4px solid #187988; background:#eaf5f7; }
.legacy-decision-route h4, .legacy-alert-box h4 { margin:0 0 .7rem; color:#174c5b; }
.legacy-decision-route ol { margin:0; padding-left:1.2rem; }
.legacy-decision-route li { margin:.48rem 0; line-height:1.55; }
.legacy-alert-box { margin:1rem 0; padding:1rem 1.1rem; border-radius:14px; border:1px solid #ecd6a8; background:#fff9e9; }
.legacy-alert-box > p { line-height:1.65; }
.legacy-alert-box ul { margin:.65rem 0 0; padding-left:1.2rem; }
.legacy-alert-box li { margin:.4rem 0; line-height:1.5; }
.legacy-learning-result { margin-bottom:0 !important; padding:.9rem 1rem; border-radius:12px; border:1px dashed #8bbac3; background:#f7fcfd; }
.optional-lab { margin:1rem 0; border:1px solid #cbd5e1; border-radius:12px; background:#f8fafc; }
.optional-lab > summary { cursor:pointer; padding:.9rem 1rem; color:#334155; font-weight:800; list-style:none; }
.optional-lab > summary::-webkit-details-marker { display:none; }
.optional-lab > summary::before { content:'+'; display:inline-grid; place-items:center; width:1.35rem; height:1.35rem; margin-right:.55rem; border-radius:50%; color:#fff; background:#347f8b; }
.optional-lab[open] > summary::before { content:'−'; }
.optional-lab > :not(summary) { margin-left:1rem !important; margin-right:1rem !important; }
@media (max-width:700px) {
  .theory-chapter ul, .legacy-theory-grid, .legacy-deepening-grid { grid-template-columns:1fr; }
  .theory-chapter { padding:1rem; }
}
