/* Indian Economy course page (2026-12-01). Loads after polity-page.css and reuses its headings, price tag,
   try buttons, receipt notes and FAQ. New devices here: rising-chart pen arrow, ink numbers board, correction
   sheet with red-pen strikes, graph-paper worked example, module bar chart on an ink stage, ledger + stamp.
   Solid colours, no borders, no gradients (patterns are SVG lines). */

/* ---------- hero ---------- */
.ec-up{position:relative;display:inline-block;white-space:nowrap}
.ec-up svg{position:absolute;left:-2%;top:78%;width:104%;height:46%;overflow:visible;pointer-events:none}
.ec-up path{fill:none;stroke:var(--red);stroke-width:4;stroke-linecap:round;stroke-linejoin:round;vector-effect:non-scaling-stroke}
.ec-up.ec-js path{stroke-dasharray:1000;stroke-dashoffset:1000}
.ec-up.ec-js.on path{transition:stroke-dashoffset .8s cubic-bezier(.6,.1,.3,1) .2s;stroke-dashoffset:0}
.ec-up.ec-js.on path+path{transition-delay:.85s;transition-duration:.3s}
.ec-hero .pl-sub{margin-top:30px}

.ec-bg{position:absolute;inset:0;pointer-events:none}
.ec-bg-bars{position:absolute;right:0;bottom:0;width:min(46vw,620px);height:72%}
.ec-bg-bars rect{fill:var(--paper-deep)}
.ec-hero .pl-bg-hatch{position:absolute;width:240px;height:120px;right:calc(50% - 600px);top:-34px}
.ec-hero .pl-bg-hatch line{stroke:var(--ink);stroke-width:2;opacity:.13}
.ec-hero .pl-bg-dots{position:absolute;left:0;bottom:0;width:96px;height:200px}
.ec-hero .pl-bg-dots circle{fill:var(--ink);opacity:.2}
@media(max-width:959px){.ec-bg-bars{width:100%;height:38%;opacity:.8}.ec-hero .pl-bg-dots{display:none}.ec-hero .pl-bg-hatch{right:-40px;top:-50px;width:180px;height:90px}}

/* numbers board: an ink panel, rows of label / value / period; values flip up once */
.ec-board{position:relative;background:#151a2e;color:var(--paper);border-radius:22px;padding:26px 26px 22px;
  box-shadow:0 2px 4px rgba(21,26,46,.12),0 30px 60px -26px rgba(21,26,46,.55)}
@media(min-width:960px){.ec-board{padding:30px 32px 24px;transform:rotate(.6deg)}}
.ec-board-h{display:flex;align-items:center;gap:10px;margin-bottom:12px}
.ec-board-h b{font-family:var(--display);font-size:20px;font-weight:800;letter-spacing:-.01em}
.ec-board-h em{margin-left:auto;font-style:normal;font-size:12.5px;font-weight:700;color:rgba(249,246,238,.55);white-space:nowrap}
.ec-rows{list-style:none;display:grid}
.ec-rows li{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"l v" "p v";column-gap:16px;align-items:center;padding:11px 0}
.ec-l{grid-area:l;font-size:15px;font-weight:700;line-height:1.25}
.ec-rows em{grid-area:p;font-style:normal;font-size:12.5px;font-weight:600;color:rgba(249,246,238,.55);margin-top:2px}
.ec-v{grid-area:v;display:block;overflow:hidden;text-align:right;font-family:var(--display);font-size:clamp(22px,2.4vw,28px);font-weight:800;
  letter-spacing:-.02em;color:var(--hl);font-variant-numeric:tabular-nums;white-space:nowrap;line-height:1.15}
.ec-v span{display:inline-block}
.ec-board-f{margin-top:12px;font-size:13px;font-weight:600;line-height:1.45;color:rgba(249,246,238,.68)}
.ec-board-f b{color:var(--paper)}
.ec-board.ec-js .ec-v span{transform:translateY(110%)}
.ec-board.ec-js.on .ec-v span{transform:none;transition:transform .5s cubic-bezier(.2,.9,.3,1.15);transition-delay:calc(.2s + var(--i)*.14s)}
@media(max-width:420px){.ec-board{padding:22px 18px 18px}.ec-l{font-size:14px}}

/* ---------- correction sheet ---------- */
.ec-lede-c{text-align:center;margin-left:auto;margin-right:auto}
.ec-sheet{max-width:980px;margin:44px auto 0;background:var(--surface);border-radius:20px;padding:10px 28px 14px;
  box-shadow:0 1px 2px rgba(21,26,46,.06),0 22px 48px -22px rgba(21,26,46,.3)}
.ec-sheet-h{display:none}
.ec-sheet ul{list-style:none}
.ec-sheet li{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"o c" "n n";gap:4px 14px;padding:16px 0;align-items:center}
.ec-old{grid-area:o;position:relative;justify-self:start;text-decoration:none;font-size:15px;font-weight:600;color:rgba(21,26,46,.55)}
.ec-old svg{position:absolute;left:-3%;top:28%;width:106%;height:50%;overflow:visible}
.ec-old path{fill:none;stroke:var(--red);stroke-width:2.6;stroke-linecap:round;vector-effect:non-scaling-stroke}
.ec-new{grid-area:n;display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 12px}
.ec-new b{font-size:17px;font-weight:800;line-height:1.3}
.ec-new em{font-style:normal;font-size:12.5px;font-weight:800;background:var(--hl);color:var(--ink);padding:3px 9px;border-radius:999px;white-space:nowrap}
.ec-code{grid-area:c;font-style:normal;font-family:var(--display);font-size:13px;font-weight:800;color:var(--paper);background:var(--ink);padding:4px 9px;border-radius:8px}
@media(min-width:860px){
  .ec-sheet{padding:8px 36px 16px}
  .ec-sheet-h{display:grid;grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr) 56px;gap:24px;padding:18px 0 10px;
    font-size:13px;font-weight:700;color:var(--ink-soft)}
  .ec-sheet li{grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr) 56px;grid-template-areas:"o n c";gap:24px;padding:15px 0}
  .ec-code{justify-self:end}
}
.ec-fix.ec-js .ec-old path{stroke-dasharray:400;stroke-dashoffset:400}
.ec-fix.ec-js .ec-new{opacity:0;transform:translateX(14px)}
.ec-fix.ec-js.on .ec-old path{stroke-dashoffset:0;transition:stroke-dashoffset .35s ease-out;transition-delay:calc(.15s + var(--i)*.28s)}
.ec-fix.ec-js.on .ec-new{opacity:1;transform:none;transition:opacity .3s,transform .35s cubic-bezier(.2,.9,.3,1.2);transition-delay:calc(.4s + var(--i)*.28s)}
.ec-year{max-width:980px;margin:22px auto 0;background:var(--hl);border-radius:16px;padding:16px 22px;font-size:15.5px;font-weight:600;line-height:1.5;text-align:center;text-wrap:balance}
.ec-year b{font-weight:800}

/* ---------- worked example on graph paper ---------- */
.ec-wx-sec{background:var(--paper-deep)}
.ec-wx-grid{display:grid;gap:44px;align-items:center}
@media(min-width:960px){.ec-wx-grid{grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:64px}}
.ec-wx-sec .pl-h2{font-size:clamp(28px,3.2vw,40px)}
.ec-note{position:relative;margin:0;background:#fffdf6;border-radius:18px;padding:28px 30px 26px;overflow:hidden;transform:rotate(-.7deg);
  box-shadow:0 1px 2px rgba(21,26,46,.06),0 26px 50px -24px rgba(21,26,46,.35)}
.ec-grid-bg{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}
.ec-grid-bg path{fill:none;stroke:#3d6fd1;stroke-width:1;opacity:.13}
.ec-note>*{position:relative}
.ec-note>.ec-grid-bg{position:absolute}
.ec-note-h{display:flex;flex-direction:column;gap:4px;margin-bottom:14px}
.ec-note-h span{font-size:12.5px;font-weight:800;color:var(--red)}
.ec-note-h b{font-family:var(--display);font-size:clamp(19px,2vw,22px);font-weight:800;letter-spacing:-.01em;line-height:1.2}
.ec-note-b{font-size:15.5px;line-height:1.6;color:var(--ink)}
.ec-note-b p,.ec-note-b ol,.ec-note-b ul{margin:0 0 10px}
.ec-note-b ol{padding-left:22px;display:grid;gap:4px}
.ec-note-b li::marker{font-weight:800;color:var(--red)}
.ec-note-b strong{font-weight:800;color:var(--red)}
.ec-note-b>:last-child{margin-bottom:0}
@media(max-width:480px){.ec-note{padding:22px 20px 20px}.ec-note-b{font-size:15px}}
.ec-note.ec-js .ec-note-b>*{opacity:0;transform:translateY(6px)}
.ec-note.ec-js.on .ec-note-b>*{opacity:1;transform:none;transition:opacity .35s,transform .35s}
.ec-note.ec-js.on .ec-note-b>:nth-child(2){transition-delay:.3s}
.ec-note.ec-js.on .ec-note-b>:nth-child(3){transition-delay:.6s}
.ec-note.ec-js.on .ec-note-b>:nth-child(4){transition-delay:.9s}
.ec-note.ec-js.on .ec-note-b>:nth-child(5){transition-delay:1.2s}
.ec-note.ec-js.on .ec-note-b>:nth-child(n+6){transition-delay:1.5s}

/* ---------- modules as bars, on an ink stage ---------- */
.ec-map{padding-top:0}
@media(min-width:900px){.ec-map{padding-top:0}}
.ec-stage{position:relative;overflow:hidden;background:#151a2e;color:var(--paper);border-radius:22px;padding:56px 24px 48px;
  box-shadow:0 30px 60px -30px rgba(21,26,46,.55);margin-top:72px}
@media(min-width:900px){.ec-stage{padding:72px 56px 60px;margin-top:104px}}
.ec-stage>*{position:relative;z-index:1}
.ec-stage .amb{z-index:0}
.ec-bars{list-style:none;display:grid;gap:14px 44px;margin:40px auto 0;max-width:1040px}
@media(min-width:860px){.ec-bars{grid-template-columns:1fr 1fr}}
.ec-bars li{display:grid;gap:6px}
.ec-bt{display:flex;gap:10px;align-items:baseline;font-size:14.5px;font-weight:700;line-height:1.3;color:rgba(249,246,238,.9)}
.ec-bt i{font-style:normal;font-family:var(--display);font-weight:800;color:var(--hl);min-width:14px}
.ec-bar{display:flex;align-items:center;gap:10px;height:14px}
.ec-bar span{display:block;height:10px;border-radius:5px;background:rgba(249,246,238,.82);width:calc(var(--w) * .86)}
.ec-bar b{font-family:var(--display);font-size:14px;font-weight:800;font-variant-numeric:tabular-nums;color:var(--paper)}
.ec-hot .ec-bar span{background:var(--red)}
.ec-hot .ec-bt{color:var(--paper)}
.ec-stage.ec-js .ec-bar span{width:0}
.ec-stage.ec-js.on .ec-bar span{width:calc(var(--w) * .86);transition:width .7s cubic-bezier(.3,.7,.3,1);transition-delay:calc(var(--i)*.05s)}
.ec-map-go{text-align:center;margin-top:40px}

/* ---------- ledger + stamp ---------- */
.ec-ledger{position:relative;max-width:480px;margin:44px auto 0;background:var(--surface);border-radius:20px;padding:28px 30px 26px;
  box-shadow:0 1px 2px rgba(21,26,46,.06),0 26px 50px -24px rgba(21,26,46,.35)}
.ec-lg-t{display:flex;justify-content:space-between;align-items:baseline;gap:12px}
.ec-lg-t b{font-family:var(--display);font-size:22px;font-weight:800;letter-spacing:-.01em}
.ec-lg-t span{font-size:13px;font-weight:700;color:var(--ink-soft)}
.ec-lg{list-style:none;margin-top:16px;display:grid}
.ec-lg li{display:grid;grid-template-columns:minmax(0,1fr) auto 24px;gap:12px;align-items:center;padding:11px 0;font-size:15px;font-weight:700}
.ec-lg em{font-style:normal;font-size:13.5px;font-weight:600;color:var(--ink-soft);white-space:nowrap}
.ec-lg b{width:24px;height:24px;border-radius:50%;background:var(--hl);display:grid;place-items:center}
.ec-lg .ic{width:14px;height:14px}
.ec-lg-total{display:flex;justify-content:space-between;align-items:baseline;margin-top:14px;padding:12px 16px;background:var(--paper-deep);border-radius:12px}
.ec-lg-total span{font-size:15px;font-weight:700;color:var(--ink-soft)}
.ec-lg-total b{font-family:var(--display);font-size:40px;font-weight:800;letter-spacing:-.02em}
.ec-stamp{position:absolute;right:-14px;top:-18px;transform:rotate(8deg);background:var(--red);color:#fff;font-family:var(--display);font-size:13.5px;font-weight:800;
  padding:7px 13px;border-radius:8px;box-shadow:3px 3px 0 var(--ink);white-space:nowrap}
@media(max-width:520px){.ec-stamp{right:8px;top:-20px}.ec-ledger{padding:30px 20px 22px}}
.ec-ledger.ec-js .ec-stamp{opacity:0;transform:rotate(8deg) scale(1.6)}
.ec-ledger.ec-js.on .ec-stamp{opacity:1;transform:rotate(8deg);transition:opacity .2s .4s,transform .35s cubic-bezier(.3,1.6,.5,1) .4s}

@media (prefers-reduced-motion:reduce){.ec-board *,.ec-fix *,.ec-note *,.ec-stage *,.ec-ledger *{transition:none!important}}

/* the worked example's givens (a small table from the lesson, e.g. the made-up slabs) */
.ec-note-b table{width:100%;border-collapse:separate;border-spacing:0 4px;margin:0 0 14px;font-size:14px}
.ec-note-b th{text-align:left;font-size:12.5px;font-weight:800;color:var(--ink-soft);padding:0 10px 2px}
.ec-note-b td{background:rgba(21,26,46,.05);padding:7px 10px;font-weight:600}
.ec-note-b td:first-child{border-radius:8px 0 0 8px}
.ec-note-b td:last-child{border-radius:0 8px 8px 0;font-weight:800;white-space:nowrap}

/* phones: the old line gets the full width so its strike sits on one line; the lesson code moves next to the new line */
@media(max-width:859px){
  .ec-sheet li{grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"o o" "n c";align-items:start}
  .ec-old{white-space:nowrap;font-size:14.5px}
  .ec-code{margin-top:2px}
}
.ec-board-h{flex-wrap:wrap}
.ec-board-h b{white-space:nowrap}
.ec-lg-t b,.ec-lg-t span{white-space:nowrap}
@media(max-width:520px){
  .ec-lg-t b{font-size:19px}
  .ec-lg-t span{font-size:12px}
  .ec-lg li{font-size:14px;gap:8px}
  .ec-lg em{font-size:12.5px}
}
