/* Styles propres aux capacités CM1. */
.mdj-capacites-cm1 .cm1-hero-start {display:inline-flex;gap:10px;align-items:center;background:#ffdd91;color:#29425a;text-decoration:none;padding:11px 20px;border-radius:14px;font-weight:900;box-shadow:0 5px 0 #d9b06a}
.mdj-capacites-cm1 .cm1-hero-start:hover {background:#ffebb9}
.mdj-capacites-cm1 .cm1-large {font-size:1.09rem;line-height:1.56}
.mdj-capacites-cm1 .cm1-examples {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:11px;margin:20px 0}
.mdj-capacites-cm1 .cm1-example {display:flex;flex-direction:column;align-items:center;text-align:center;background:#eef8fc;border:1px solid #d5e9f1;border-radius:17px;padding:9px 8px 14px;min-width:0}
.mdj-capacites-cm1 .cm1-example svg {height:95px;max-width:100%;display:block}
.mdj-capacites-cm1 .cm1-example strong {font-size:.92rem;color:#175574}
.mdj-capacites-cm1 .cm1-example span {color:#276b76;font-weight:850;font-size:.91rem}
.mdj-capacites-cm1 .cm1-main-equality {background:#e9f8fa;border-radius:18px;border:2px dashed #7ecbd0;padding:16px 10px;display:flex;gap:8px;align-items:center;justify-content:center;flex-wrap:wrap;margin-bottom:17px}
.mdj-capacites-cm1 .cm1-main-equality span {color:#105977;font-size:clamp(.97rem,2.1vw,1.39rem);font-weight:950;white-space:nowrap}
.mdj-capacites-cm1 .cm1-main-equality b {color:#d27d2c;font-size:1.15rem}
.mdj-capacites-cm1 .cm1-rule-grid {display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:20px 0 24px}
.mdj-capacites-cm1 .cm1-rule {display:flex;flex-direction:column;gap:5px;background:#f6fafc;border:1px solid #dceaf0;padding:15px 17px;border-radius:15px}
.mdj-capacites-cm1 .cm1-rule strong {color:#135e7e}
.mdj-capacites-cm1 .cm1-rule span {font-size:.88rem;color:#4a6271}
.mdj-capacites-cm1 .cm1-rule code {display:block;margin-top:3px;color:#0a6e67;font-family:inherit;font-weight:900;font-size:1.06rem}
.mdj-capacites-cm1 .cm1-table-caption {font-size:.97rem}
.mdj-capacites-cm1 .cm1-table-wrap {overflow-x:auto;padding-bottom:4px}
.mdj-capacites-cm1 .cm1-units {display:grid;grid-template-columns:repeat(6,minmax(85px,1fr));gap:5px;min-width:550px;margin:9px 0}
.mdj-capacites-cm1 .cm1-units>div {display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:73px;padding:9px 2px;background:#eaf3f8;border:1px solid #d0e4ea;border-radius:12px;text-align:center;position:relative}
.mdj-capacites-cm1 .cm1-units>div:not(:last-child)::after {content:'›';font-size:22px;font-weight:900;line-height:1;background:#fff;color:#167c89;position:absolute;right:-11px;top:24px;border-radius:100%;width:18px;z-index:1}
.mdj-capacites-cm1 .cm1-units strong {font-size:1.24rem;color:#135b7a}
.mdj-capacites-cm1 .cm1-units small {font-size:.7rem;font-weight:600;color:#586d7b}
.mdj-capacites-cm1 .cm1-units>.cm1-unit-focus {background:#def7ee;border-color:#94d4c3}
.mdj-capacites-cm1 .cm1-table-foot {font-size:.84rem;color:var(--muted);margin-bottom:4px!important}
.mdj-capacites-cm1 .cm1-feedback {border-radius:12px;background:#f1f8fb;padding:12px 14px;font-weight:800;color:#205f7b;min-height:53px;margin-bottom:0!important}
.mdj-capacites-cm1 .cm1-pour-scene {display:flex;gap:18px;align-items:center;justify-content:center;background:#eff9fc;border-radius:19px;padding:19px 12px;min-height:248px}
.mdj-capacites-cm1 .cm1-jug {position:relative;width:127px;height:204px;border:5px solid #1e748c;border-top:9px solid #1e748c;border-radius:5px 5px 18px 18px;background:#fff;overflow:hidden}
.mdj-capacites-cm1 .cm1-jug::before {content:"";position:absolute;left:0;right:0;top:0;bottom:0;background:linear-gradient(90deg,#ffffff69,transparent 65%);z-index:2;pointer-events:none}
.mdj-capacites-cm1 .cm1-jug-fill {position:absolute;bottom:0;left:0;right:0;height:0%;background:linear-gradient(160deg,#9ce9f5,#30b6d2);transition:height .45s ease}
.mdj-capacites-cm1 .cm1-jug-lines {position:absolute;inset:0;z-index:3;display:flex;flex-direction:column;justify-content:space-between;padding:1px 5px 4px;pointer-events:none}
.mdj-capacites-cm1 .cm1-jug-lines span {font-size:.71rem;font-weight:850;color:#20546c;border-top:1px dashed #4386a1;line-height:1.2;padding-top:1px}
.mdj-capacites-cm1 .cm1-jug-total {display:flex;flex-direction:column;gap:2px;max-width:110px}
.mdj-capacites-cm1 .cm1-jug-total strong {font-size:1.72rem;line-height:1.2;color:#17627d}
.mdj-capacites-cm1 .cm1-jug-total span {font-size:.85rem;color:#597080}
.mdj-capacites-cm1 .cm1-converter-card {background:#f8fcff}
.mdj-capacites-cm1 .cm1-converter {display:flex;gap:9px;align-items:end;flex-wrap:wrap;margin:15px 0 6px}
.mdj-capacites-cm1 .cm1-field {display:flex;flex-direction:column;gap:4px}
.mdj-capacites-cm1 .cm1-field:first-child {flex:1 1 105px}
.mdj-capacites-cm1 .cm1-field label {font-size:.79rem;font-weight:800;color:#365b6b}
.mdj-capacites-cm1 .cm1-field input,.mdj-capacites-cm1 .cm1-field select {padding:10px 11px;border:2px solid #bacfdc;border-radius:10px;background:white;min-height:46px;max-width:100%;color:#163d55}
.mdj-capacites-cm1 .cm1-field input {width:120px;max-width:100%}
.mdj-capacites-cm1 .cm1-field select {min-width:85px}
.mdj-capacites-cm1 .cm1-arrow {font-size:1.9rem;color:#0b867f;line-height:1.5;font-weight:900}
.mdj-capacites-cm1 .cm1-help {color:#5b6d7b;font-size:.83rem;margin-top:2px!important}
.mdj-capacites-cm1 .cm1-converter-result {background:#e7f6f0;color:#155745;border:1px solid #9bd5c7;border-radius:14px;padding:12px 16px;margin-top:15px;font-size:1.15rem;font-weight:800}
.mdj-capacites-cm1 .cm1-converter-result span {display:block;font-size:.87rem;font-weight:600;margin-top:2px}
.mdj-capacites-cm1 .cm1-converter-result.cm1-error {background:#fff0ec;color:#923a2c;border-color:#e9ab9d}
.mdj-capacites-cm1 .cm1-qnum {display:inline-grid;place-items:center;background:#e1f4ef;color:#116e62;width:29px;height:29px;border-radius:9px;font-weight:950;margin-right:5px}
/* Adaptations CM1 : les composants génériques restent dans mdj-common.css. */
body.mdj-capacites-cm1 {font-size:17px;line-height:1.6}
.mdj-capacites-cm1 .hero-inner {padding-block:32px 48px;gap:24px}
.mdj-capacites-cm1 .hero h1 {font-size:clamp(2rem,4vw,3rem)}
.mdj-capacites-cm1 .hero h1 em {color:#fbd88e;font-style:normal}
.mdj-capacites-cm1 .hero-start,.mdj-capacites-cm1 .cm1-hero-start {margin-top:20px}
.mdj-capacites-cm1 .hero .hero-tags {margin-bottom:10px}
.mdj-capacites-cm1 .hero-art svg {max-height:285px}
.mdj-capacites-cm1 main {padding-top:28px;padding-bottom:35px}
.mdj-capacites-cm1 section.module {margin-bottom:32px}
.mdj-capacites-cm1 .num {background:#0a827d;color:#fff}
.mdj-capacites-cm1 .test-item {min-width:0;margin:0;border-left:0;border-right:0;border-bottom:0;padding:16px 0}
.mdj-capacites-cm1 .test-item legend {padding:0 0 6px;font-size:1rem}
.mdj-capacites-cm1 .test-item .options {grid-template-columns:repeat(3,minmax(0,1fr))}
.mdj-capacites-cm1 .test-item .options input {min-width:19px;min-height:19px;margin:0}
.mdj-capacites-cm1 .test-item .options label {align-items:center;min-height:48px}
.mdj-capacites-cm1 .button-row button {min-height:46px}
.mdj-capacites-cm1 .cm1-workshop button:disabled {opacity:.55;cursor:default}
@media(max-width:720px){
 .mdj-capacites-cm1 .hero-inner {padding-block:28px 42px}
 .mdj-capacites-cm1 .cm1-examples {grid-template-columns:repeat(2,minmax(0,1fr))}
 .mdj-capacites-cm1 .cm1-rule-grid,.mdj-capacites-cm1 .test-item .options {grid-template-columns:1fr}
}
@media(max-width:420px){.mdj-capacites-cm1 .cm1-converter {gap:7px}.mdj-capacites-cm1 .cm1-converter button {width:100%}.mdj-capacites-cm1 .cm1-main-equality {gap:5px}}
@media(prefers-reduced-motion:reduce){.mdj-capacites-cm1 .cm1-jug-fill {transition:none}}
@media print{.mdj-capacites-cm1 .cm1-hero-start,.mdj-capacites-cm1 .cm1-converter {display:none!important}.mdj-capacites-cm1 .test-item {break-inside:avoid}}
