.cg-tvs { --tvs-border:var(--line-soft,#ddd); }
.cg-tvs [hidden] { display:none !important; }
.cg-tvs .tvs-heading { display:flex;align-items:center;gap:20px; }
.cg-tvs .tvs-heading svg { width:80px;height:80px;flex:0 0 80px;color:var(--bordeaux); }
.cg-tvs form { padding:28px; }
.cg-tvs .tvs-fields { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px; }
.cg-tvs label { display:block;font-size:15px;font-weight:600;min-width:0; }
.cg-tvs input,.cg-tvs select { display:block;width:100%;box-sizing:border-box;min-width:0;min-height:48px;margin-top:8px;padding:12px;border:1px solid var(--tvs-border);border-radius:8px;background:var(--paper,#fff);font:inherit;font-size:16px;color:var(--ink); }
.cg-tvs small { display:block;font-size:13px;line-height:1.55;font-weight:400;color:var(--ink-soft);margin-top:7px; }
.cg-tvs fieldset { min-width:0;margin:28px 0;padding:24px;border:1px solid var(--tvs-border);border-radius:14px; }
.cg-tvs legend { padding:0 8px;font-weight:750;font-size:19px; }
.cg-tvs .tvs-check { display:flex;align-items:flex-start;gap:10px;margin:22px 0;font-weight:400; }
.cg-tvs .tvs-check input { width:20px;min-height:20px;flex:0 0 20px;margin:3px 0; }
.cg-tvs .tvs-actions { display:flex;flex-wrap:wrap;gap:12px;margin-top:24px; }
.cg-tvs .tvs-remove { margin-top:20px;background:none;border:0;color:var(--bordeaux);text-decoration:underline;min-height:44px;cursor:pointer;font:inherit; }
.cg-tvs .tvs-error { color:#9b251d;margin:18px 0;font-weight:650; }
.cg-tvs .tvs-total { background:var(--bordeaux);color:white;border-radius:14px;padding:24px;margin-bottom:24px; }
.cg-tvs .tvs-total strong { display:block;font-size:clamp(32px,6vw,48px);line-height:1.2;overflow-wrap:anywhere; }
.cg-tvs .tvs-results { margin:0 28px 28px; }
.cg-tvs .tvs-result-card { padding:22px;border:1px solid var(--tvs-border);border-radius:14px;margin:20px 0; }
.cg-tvs .tvs-result-card h3 { font-size:20px;margin:0 0 14px; }
.cg-tvs dl { display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;margin:16px 0; }
.cg-tvs dd { margin:0;font-weight:700; }
.cg-tvs details { margin-top:18px; }
.cg-tvs summary { min-height:44px;cursor:pointer;font-weight:650; }
.cg-tvs .tvs-breakdown { padding-left:22px;font-size:14px;line-height:1.8; }
.cg-tvs .tvs-note { padding:18px;background:var(--surface);border-radius:10px;line-height:1.7;margin:22px 0; }
.cg-tvs a { text-underline-offset:3px; }
.cg-tvs button:focus-visible,.cg-tvs input:focus-visible,.cg-tvs select:focus-visible,.cg-tvs summary:focus-visible { outline:3px solid var(--bordeaux);outline-offset:3px; }
@media(max-width:600px){.cg-tvs form{padding:20px 16px}.cg-tvs fieldset{padding:20px 14px}.cg-tvs .tvs-fields{grid-template-columns:1fr;gap:18px}.cg-tvs .tvs-results{margin:0 16px 20px}.cg-tvs .tvs-heading{align-items:flex-start;gap:12px}.cg-tvs .tvs-heading svg{width:48px;height:48px;flex-basis:48px}.cg-tvs .tvs-actions .btn{width:100%;white-space:normal}.cg-tvs dl{font-size:14px}.cg-tvs .tvs-result-card{padding:18px 14px}}
/* Une seule couche de marges, y compris dans le cadre des outils existants. */
.cg-simulateur.cg-tvs { padding:0; }
.cg-tvs .tvs-heading { padding:28px 28px 0; }
.cg-tvs .btn-outline { background:transparent;color:var(--bordeaux);border:1px solid var(--bordeaux); }
@media(max-width:600px){.cg-tvs .tvs-heading{padding:20px 16px 0}.cg-tvs .tvs-heading h2{font-size:24px;line-height:1.25}.cg-tvs .tvs-heading>div{min-width:0}}

/* Parcours guidé : repères de carte grise et questions progressives. */
.cg-tvs .tvs-start { margin:24px 28px 0;line-height:1.65; }
.cg-tvs .tvs-card-guide { background:#f7f1ef;border-radius:12px;padding:16px 20px; }
.cg-tvs .tvs-card-guide summary,.cg-tvs .tvs-help summary,.cg-tvs .tvs-exemptions summary { display:list-item;padding:10px 0;line-height:1.5; }
.cg-tvs .tvs-card-map { display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.3fr);gap:22px;align-items:start;margin:20px 0; }
.cg-tvs .tvs-card-map svg { width:100%;height:auto; }
.cg-tvs dl.tvs-card-keys { grid-template-columns:42px minmax(0,1fr);font-size:14px;line-height:1.55;margin:0;gap:14px 10px; }
.cg-tvs .tvs-card-keys dt { font-weight:800;color:var(--bordeaux); }
.cg-tvs .tvs-card-keys dd { font-weight:400; }
.cg-tvs .tvs-step { border-top:1px solid var(--tvs-border);margin-top:28px;padding-top:20px; }
.cg-tvs .tvs-step h3 { display:flex;align-items:center;gap:10px;font-size:20px;line-height:1.4;margin:0 0 20px; }
.cg-tvs .tvs-step h3>span { display:grid;place-items:center;flex:0 0 30px;height:30px;border-radius:50%;background:#356b79;color:#fff;font-size:15px; }
.cg-tvs .tvs-badge { display:inline-block;margin-left:4px;padding:1px 7px;border-radius:5px;background:#edf3f4;color:#2b5560;font-size:13px; }
.cg-tvs .tvs-optional { font-weight:400;color:var(--ink-soft); }
.cg-tvs .tvs-hint { padding:14px 16px;border-left:3px solid #356b79;background:#edf3f4;margin:20px 0;line-height:1.65;font-size:14px; }
.cg-tvs .tvs-help { margin:20px 0 24px;line-height:1.65; }
.cg-tvs .tvs-help p,.cg-tvs .tvs-card-guide p { font-size:14px;margin:12px 0; }
.cg-tvs .tvs-help ul { padding-left:22px;font-size:14px; }
.cg-tvs .tvs-help li+li { margin-top:12px; }
.cg-tvs .tvs-results { scroll-margin-top:110px; }
.cg-tvs .tvs-result-card dd { text-align:right;overflow-wrap:anywhere; }
.cg-tvs .tvs-total p { margin:8px 0 0;font-size:15px; }
.cg-tvs input[type=date],.cg-tvs select { max-width:100%; }
@media(max-width:600px){.cg-tvs .tvs-start{margin:20px 16px 0}.cg-tvs .tvs-card-map{grid-template-columns:1fr}.cg-tvs .tvs-card-guide{padding:12px 14px}.cg-tvs .tvs-step h3{font-size:18px}.cg-tvs .tvs-card-map svg{max-width:340px;margin:auto}.cg-tvs .tvs-results{scroll-margin-top:90px}.cg-tvs .tvs-result-card dl{grid-template-columns:minmax(0,1fr) minmax(0,.8fr)}}

/* Aide contextuelle, immédiatement après le choix d’exonération. */
.cg-tvs .tvs-exemption-help { margin-top:22px;padding:20px;border:1px solid #d7e3e5;border-radius:12px;background:#f1f6f6;line-height:1.65; }
.cg-tvs .tvs-exemption-help h4 { margin:0 0 14px;font-size:19px;line-height:1.4;color:#2b5560; }
.cg-tvs .tvs-exemption-help p { margin:0 0 16px;font-size:15px; }
.cg-tvs .tvs-exemption-help p:last-child { margin-bottom:0; }
.cg-tvs .tvs-exemption-effect { border-top:1px solid #d7e3e5;padding-top:16px; }
.cg-tvs .tvs-exemption-help .tvs-exemption-source,.cg-tvs .tvs-exemption-footnote { font-size:13px;line-height:1.6; }
.cg-tvs .tvs-exemption-footnote { margin-top:14px;color:var(--ink-soft); }
@media(max-width:600px){.cg-tvs .tvs-exemption-help{padding:16px}.cg-tvs .tvs-exemption-help h4{font-size:18px}}
