.cv-slope-lab { margin: 2.5rem 0; padding: clamp(1rem,3vw,2rem); border: 2px solid var(--ink); border-radius: 17px; background: var(--white); color: var(--ink); min-width: 0; scroll-margin-top: 7rem; }
.article-body .cv-slope-lab h2 { margin: .35rem 0 1rem; font-size: clamp(1.5rem,4vw,2rem); line-height: 1.25; }
.article-body .cv-slope-lab h3 { margin: 0 0 .7rem; font-size: 1.2rem; line-height: 1.4; }
.article-body .cv-slope-lab p { font-size: 1rem; line-height: 1.65; }
.article-body .cv-slope-lab .cv-slope-kicker { margin: 0 0 .4rem; font-size: .8rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); }
.cv-slope-lab [hidden] { display: none !important; }
.cv-slope-controls { margin: 1.5rem 0; }
.cv-slope-controls fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.cv-slope-controls legend { font-size: 1.05rem; font-weight: 800; padding: 0 0 .8rem; }
.cv-slope-fields { display: grid; grid-template-columns: minmax(0,2fr) minmax(0,1fr); gap: 1rem; align-items: end; }
.cv-slope-controls label { display: block; min-width: 0; font-size: 1rem; font-weight: 700; }
.cv-slope-controls input, .cv-slope-controls select { display: block; width: 100%; min-width: 0; min-height: 48px; font: inherit; margin: .4rem 0; }
.cv-slope-controls input { accent-color: var(--ink); cursor: pointer; padding: .5rem 0; }
.cv-slope-controls select { padding: .6rem; color: var(--ink); background: #fff; border: 1px solid #678478; border-radius: 7px; }
.cv-slope-preview { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .65rem; margin: .8rem 0 1rem; }
.cv-slope-preview > div { display: flex; flex-direction: column; justify-content: space-between; min-width: 0; padding: .5rem .7rem; border-left: 3px solid var(--ink); background: #e8f0d3; }
.cv-slope-preview span { font-size: .875rem; }
.cv-slope-preview strong { font-size: 1.35rem; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.cv-slope-presets { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: .65rem; }
.cv-slope-presets button { min-height: 48px; font-size: .9375rem; white-space: normal; padding: .7rem .5rem; }
.cv-slope-lab :disabled { opacity: .55; cursor: not-allowed; }
.cv-slope-lab :focus-visible { outline: 3px solid var(--ink); outline-offset: 4px; }
.article-body .cv-slope-lab .cv-slope-help { font-size: .9375rem; color: #42594e; margin: .7rem 0; }
.cv-slope-workspace { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1.5rem; margin: 1.5rem 0; align-items: start; }
.cv-slope-workspace > div { min-width: 0; }
.cv-slope-chart { display: block; width: 100%; height: auto; background: #f7f8ef; border: 1px solid #799489; border-radius: 10px; }
.cv-slope-area { fill: #b8d94f; fill-opacity: .3; }
.cv-slope-horizontal { stroke: #126578; stroke-width: 3; stroke-dasharray: 7 4; }
.cv-slope-vertical { stroke: #a85924; stroke-width: 3; stroke-dasharray: 3 4; }
.cv-slope-inclined { stroke: #0b2d26; stroke-width: 5; stroke-linecap: round; }
.cv-slope-square, .cv-slope-arc { stroke: #0b2d26; stroke-width: 1.8; fill: none; }
.cv-slope-point { fill: #0b2d26; }
.cv-slope-chart text { font: 700 22px system-ui,sans-serif; fill: #0b2d26; paint-order: stroke; stroke: #f7f8ef; stroke-width: 5; stroke-linejoin: round; }
.cv-slope-chart .cv-slope-base-label { fill: #126578; }
.cv-slope-chart .cv-slope-rise-label { fill: #8a461a; }
.cv-slope-legend { display: flex; flex-wrap: wrap; gap: .6rem 1rem; list-style: none; padding: 0 !important; margin: .8rem 0 !important; font-size: .875rem; }
.cv-slope-legend li { display: flex; align-items: center; gap: .4rem; margin: 0 !important; }
.cv-slope-legend i { width: 22px; border-top: 3px solid #0b2d26; }
.cv-slope-legend .is-horizontal { border-top: 3px dashed #126578; }
.cv-slope-legend .is-vertical { border-top: 3px dotted #a85924; }
.cv-slope-formula { border-left: 3px solid var(--ink); padding: .7rem .8rem; background: #f1f3e5; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.cv-slope-distance { border-top: 1px solid var(--line-strong); padding-top: 1rem; }
.cv-slope-distance strong { white-space: nowrap; }
.cv-slope-boundary { border-left: 3px solid #a85924; padding: .8rem 1rem; background: #fff2e4; }
.cv-slope-reason, .cv-slope-question details { border: 1px solid var(--line-strong); border-radius: 9px; background: var(--paper); margin-top: 1.5rem; }
.cv-slope-lab summary { min-height: 48px; padding: .85rem 1rem; font-weight: 750; font-size: 1rem; cursor: pointer; }
.cv-slope-lab details p { margin: .4rem 1rem 1rem; }
.cv-slope-question { border-top: 1px solid var(--line-strong); padding-top: 1.5rem; margin-top: 1.5rem; }
.cv-slope-question details { margin-top: .75rem; }
.cv-slope-error { border: 1px solid #9b281d; color: #792116; background: #fff0eb; padding: .8rem; }
.cv-slope-status { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media(max-width:760px) { .cv-slope-workspace { grid-template-columns: minmax(0,1fr); } }
@media(max-width:620px) { .cv-slope-fields { grid-template-columns: minmax(0,1fr); } .cv-slope-presets { grid-template-columns: repeat(2,minmax(0,1fr)); } .cv-slope-preview { grid-template-columns: repeat(2,minmax(0,1fr)); } .cv-slope-preview > div:last-child { grid-column: 1/-1; } }
@media(max-width:380px) { .cv-slope-preview strong { font-size: 1.05rem; } }
