.lesson-feature {
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(230px,31%);
  align-items:center;
  gap:18px;
  margin-bottom:25px;
  padding:16px clamp(14px,2.8vw,32px);
  border:2px solid var(--ink);
  background:var(--stock);
  box-shadow:4px 4px var(--ink);
}
.lesson-feature .page-title { margin:5px 0 0;line-height:1.18; }
.lesson-feature p:not(.eyebrow) { margin:4px 0 9px; }
.lesson-feature-art {
  display:flex;
  justify-content:center;
  align-items:center;
  min-width:0;
  border:2px solid var(--ink);
  border-radius:5px;
  background:var(--lemon);
}
.schedule-feature .lesson-feature-art { background:var(--cyan); }
.lesson-feature-art img { width:50%;height:auto;max-height:139px;object-fit:contain; }
.lesson-feature-art .feature-left { transform:rotate(-7deg); }
.lesson-feature-art .feature-right { transform:rotate(6deg); }
.lesson-content > .lesson-feature { margin-bottom:14px;padding:0;border:0;background:transparent;box-shadow:none; }
.lesson-content > .lesson-feature .lesson-no { padding:0;border:0;background:none;letter-spacing:.12em; }
.lesson-content > .lesson-feature .lesson-feature-art img { max-height:82px; }

.simulation .sim-top p { margin:2px 0 0;font-size:.92rem; }
.simulation .chart-area .legend-lines { gap:4px 14px;flex-wrap:wrap; }
.cost-chart-frame { margin-bottom:.65rem; }
#cost-chart .cost-axis-titles text { fill:var(--green);font-size:14px;font-weight:750;stroke:none; }
#cost-chart .axis { fill:none;stroke:var(--green);stroke-width:1.4;stroke-linecap:round;stroke-linejoin:round; }
.legend-lines .legend-loss::before,.legend-lines .legend-profit::before {
  width:14px;height:12px;border:1px solid var(--ink);border-radius:3px;background:var(--diagram-pink);
}
.legend-lines .legend-profit::before { background:var(--diagram-green); }
.legend-lines .legend-previous::before { border-top:2px dotted var(--muted); }
.legend-lines .legend-cross::before { width:10px;height:10px;border:2px solid var(--ink);border-radius:50%;background:var(--lemon); }
#cost-chart .loss-region { fill:var(--diagram-pink); }
#cost-chart .profit-region { fill:var(--diagram-green); }
#cost-chart .point { fill:var(--lemon);stroke:var(--ink);stroke-width:2.5px; }
#cost-chart .expense-start { fill:var(--wine); }
#cost-chart .previous-expense { stroke:var(--muted);stroke-width:1.5px;stroke-dasharray:3 5; }
#cost-chart .previous-guide { stroke:var(--muted);stroke-dasharray:3 4; }
#cost-chart .previous-cross { fill:var(--stock);stroke:var(--ink);stroke-width:2px; }
#cost-chart .previous-cross-tag { fill:var(--stock);stroke:var(--line); }
#cost-chart .previous-cross-tag + text { stroke:none; }
#cost-chart .cross-shift { fill:none;stroke:var(--ink);stroke-width:2px;stroke-linecap:round;stroke-linejoin:round; }
.cost-recovery-flow { display:grid;grid-template-columns:minmax(0,1fr) 2.25rem minmax(0,1.3fr) 2.25rem minmax(0,1fr);align-items:center;gap:12px; }
.cost-recovery-flow section { align-self:stretch;padding-top:.45rem;border-top:2px solid var(--ink); }
.cost-recovery-flow h3 { margin:0 0 .55rem;font-size:1.05rem; }
.cost-recovery-flow p { margin:.4rem 0;font-size:.9rem; }
.cost-recovery-flow .flow-arrow { width:100%; }
.cost-recovery-value { display:flex;align-items:center;gap:8px;min-height:64px; }
.cost-recovery-value img { width:70px;height:auto; }
.cost-recovery-value strong { font-size:1.65rem;white-space:nowrap; }
.cost-unit-bar { display:grid;grid-template-columns:3fr 2fr;border:1px solid var(--ink);line-height:1.35; }
.cost-unit-bar span { padding:6px 2px;background:var(--cyan);text-align:center;font-weight:700; }
.cost-unit-bar span + span { border-left:1px solid var(--ink);background:var(--diagram-green); }
.cost-recovery-result { padding:.35rem .6rem;background:var(--diagram-highlight);text-align:center; }
.cost-recovery-result strong { font-size:1.45rem; }
@media(max-width:670px){
  .cost-recovery-flow { grid-template-columns:minmax(0,1fr); }
  .cost-recovery-flow .flow-arrow { width:1.6rem;justify-self:center;rotate:90deg; }
}
#chart-result { border:1px solid var(--ink);border-radius:var(--diagram-node-radius);background:var(--diagram-card);margin:7px 0 0; }
#chart-result:not([hidden]) { display:grid;grid-template-columns:repeat(3,minmax(0,1fr)); }
#chart-result p { padding:7px 8px;margin:0;line-height:1.4;text-align:center; }
#chart-result p:has(#cost-cross-result) { background:var(--diagram-highlight); }
#chart-result p + p { border-left:1px solid var(--ink); }
#chart-result b,#chart-result span { display:block; }
#chart-result b { font-size:.94rem; }
#chart-result span { font-size:1.05rem;font-weight:700; }
#cost-cross-result > span { display:inline;white-space:nowrap; }
#chart-result small { display:block;font-size:.88rem; }
@media(max-width:520px){
  #chart-result:not([hidden]){grid-template-columns:1fr}
  #chart-result p{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:1px 8px;text-align:start}
  #chart-result small{grid-column:1 / -1}
  #chart-result p + p{border-left:0;border-top:1px solid var(--line)}
}
.simulation .sim-controls { border:1.5px solid var(--ink);border-radius:var(--diagram-node-radius);background:var(--diagram-card);padding:13px 15px; }
.simulation .prediction { border-top:1.5px solid var(--ink); }

.schedule-plate { border:2px solid var(--ink); }
.schedule-plate .plate-heading { border-bottom-color:var(--ink); }
.schedule-plate .schedule-milestone {
  border:1.5px solid var(--ink);
  border-radius:3px;
  background:var(--cyan);
  padding:4px 9px;
}
.schedule-plate .schedule-milestone.finish { background:var(--lemon); }
.schedule-plate .network .schedule-milestone { position:relative; margin-bottom:18px; }
.schedule-plate .network .schedule-milestone.finish { margin:18px auto 0; }
.schedule-plate .network .schedule-milestone::after {
  content:"";
  position:absolute;
  top:100%;
  left:50%;
  width:14px;
  height:17px;
  translate:-50% 0;
  background:#762c38;
  clip-path:polygon(38% 0,62% 0,62% 50%,95% 50%,100% 56%,57% 96%,50% 100%,43% 96%,0 56%,5% 50%,38% 50%);
}
.schedule-plate .network .schedule-milestone.finish::after { top:auto; bottom:100%; }
.schedule-plate .join-label { color:var(--ink);border:1.5px solid var(--ink);background:var(--diagram-pink);text-decoration:none; }
.schedule-plate .join-label:hover { background:var(--lemon); }
.schedule-plate .join-label small span { display:block; }
.schedule-plate .join-label small span:empty { display:none; }
.schedule-plate .critical-result { background:var(--diagram-pink); }
.schedule-plate .time-bar { border:1px solid var(--green);background:var(--cyan); }
.schedule-figure:has(.network:not([data-critical="none"])) .time-bar:is([data-bar="A"],[data-bar="D"]),
.schedule-figure:has(.network:is([data-critical="B"],[data-critical="both"])) .time-bar[data-bar="B"],
.schedule-figure:has(.network:is([data-critical="C"],[data-critical="both"])) .time-bar[data-bar="C"] {
  border-color:#762c38;
  background:repeating-linear-gradient(135deg,#762c38 0 3px,var(--pink) 3px 7px);
}
.schedule-figure :is(.serial-network,.network)[hidden] { display:none; }
.serial-network { display:grid;gap:12px;padding:8px 0 14px; }
.serial-network > .schedule-milestone { justify-self:start;margin:0; }
.serial-network ol { display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:24px;margin:0;padding:0;list-style:none; }
.serial-network li { position:relative;display:grid;text-align:center;justify-items:center;line-height:1.45; }
.serial-network li img { width:76px;height:57px;object-fit:contain; }
.serial-network li:not(:last-child)::after { content:"";position:absolute;left:calc(100% + 2px);width:20px;height:16px;top:23px;background:var(--green);clip-path:var(--diagram-step-arrow); }
.serial-footer { display:flex;justify-content:space-between;align-items:center;gap:10px; }
.serial-footer a { font-size:.88rem; }
.serial-footer .finish { flex:none;margin:0; }
@media (min-width:681px) {
  .serial-network { grid-template-columns:repeat(4,minmax(0,1fr));column-gap:24px; }
  .serial-network > .schedule-milestone { justify-self:center; }
  .serial-network ol { grid-column:1/-1; }
  .serial-footer { display:contents; }
  .serial-footer a { grid-column:2/4;align-self:start;text-align:center;border-top:1px solid var(--line);padding-top:6px; }
  .serial-footer .finish { grid-column:4;justify-self:center; }
}
@media (max-width:700px) {
  .serial-network ol { grid-template-columns:1fr;gap:18px; }
  .serial-network li:not(:last-child)::after { width:15px;top:calc(100% + 1px);left:calc(50% - 7.5px);rotate:90deg; }
}

@media(min-width:1000px) {
  .schedule-plate .schedule-time .critical-result {
    display:flex;
    align-items:baseline;
    justify-content:space-between;
    flex-wrap:wrap;
    gap:4px 15px;
    grid-column:1 / -1;
    grid-row:1;
    margin:0 0 8px;
  }
  .schedule-plate .schedule-time :is(.time-head,.time-result) { grid-row:2; }
  .schedule-plate .schedule-time :is(.time-chart,.schedule-controls) { grid-row:3 / span 2; }
}

@media(max-width:660px) {
  .lesson-feature { grid-template-columns:minmax(0,1fr); }
  .lesson-feature-art { display:none; }
}
