/* Account progress extends Prep Sarthi's paper-and-ink design. */
body.progress-open .narrow{max-width:1120px}
.navright{display:flex;align-items:center;gap:12px;flex-wrap:wrap;justify-content:flex-end}
.pg{--pg-green:#29694e;--pg-soft:#e9efe8}
.pg [hidden],.pg-dialog [hidden]{display:none!important}
.pg button,.pg-dialog button{cursor:pointer}
.pg button:disabled{cursor:default;opacity:.5}
.pg button:focus-visible,.pg a:focus-visible,.pg-dialog :focus-visible,[data-pg]:focus-visible{outline:3px solid var(--accent);outline-offset:4px}
.pg-head{display:flex;align-items:flex-end;justify-content:space-between;gap:24px;margin:30px 0 26px}
.pg-head h1{font-size:clamp(42px,6vw,64px);margin:8px 0 12px}
/* Screen headings receive focus for orientation; interactive controls keep their visible rings. */
.pg-head h1[tabindex="-1"]:focus{outline:none}
.pg-head p{margin:0;max-width:550px;color:var(--muted)}
.pg-eyebrow{display:flex;align-items:center;gap:9px;font:500 11px var(--mono);letter-spacing:.11em;text-transform:uppercase;color:var(--muted)}
.pg-dot{width:7px;height:7px;border-radius:50%;background:var(--pg-green);display:inline-block}
.pg-toolbar{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.pg-subnav{display:flex;justify-content:space-between;gap:15px;align-items:center;border-bottom:1px solid var(--line);margin-bottom:24px;flex-wrap:wrap}
.pg-tabs{display:flex;gap:25px}
.pg-tab{font:500 14px var(--body);padding:14px 0;border:0;border-bottom:2px solid transparent;background:none;color:var(--muted)}
.pg-tab[aria-current="page"]{color:var(--ink);border-color:var(--accent)}
.pg-period{font:12px var(--mono);color:var(--muted);display:flex;align-items:center;gap:8px;padding-bottom:8px}
.pg-period select,.pg-filter select{width:auto;max-width:100%;padding:9px 30px 9px 10px;font:12px var(--body);background:var(--card)}
.pg-card{background:var(--card);border:1px solid var(--line);border-radius:16px;padding:25px;min-width:0}
.pg-card h2{font-size:29px;margin:5px 0 12px}
.pg-card h3{font:600 15px var(--body);line-height:1.5}
.pg-card p{margin:8px 0 14px}
.pg-card .label{font-size:10px}
.pg-grid{display:grid;grid-template-columns:minmax(0,1.75fr) minmax(0,1fr);gap:20px}
.pg-stack{display:grid;gap:20px;align-content:start}
.pg-stats{display:grid;grid-template-columns:repeat(4,1fr);margin:0 0 24px;border:1px solid var(--line);border-radius:14px;background:var(--card)}
.pg-stat{padding:20px 24px;border-right:1px solid var(--line)}
.pg-stat:last-child{border:0}
.pg-stat b{font:400 37px var(--display);display:block;line-height:1.15}
.pg-stat span{display:block;font-size:12px;color:var(--muted);margin-top:7px}
.pg-score-head{display:flex;justify-content:space-between;align-items:center;gap:14px;flex-wrap:wrap}
.pg-score-number{font:400 54px var(--display);line-height:1.1}
.pg-score-number small{font:14px var(--body);color:var(--muted)}
.pg-badge{display:inline-block;font:500 11px var(--body);padding:5px 9px;border-radius:6px;background:var(--bg2);color:var(--muted)}
.pg-badge.up{background:var(--pg-soft);color:var(--pg-green)}
.pg-badge.down{background:#f9eee4;color:#92512b}
.pg-chart{width:100%;height:auto;display:block;overflow:visible;margin-top:12px}
.pg-chart text{font:11px var(--mono);fill:var(--muted)}
.pg-chart .grid{stroke:var(--line);stroke-dasharray:3 5}
.pg-chart .line{fill:none;stroke:var(--accent);stroke-width:2.5;stroke-linecap:round;stroke-linejoin:round}
.pg-chart circle{fill:var(--card);stroke:var(--accent);stroke-width:2}
.pg-chart circle.excluded{stroke:var(--muted);fill:var(--bg2)}
.pg-chart a:hover circle,.pg-chart a:focus circle{fill:var(--accent);r:6}
.pg-chart-caption{display:flex;justify-content:space-between;gap:10px;font-size:11px;color:var(--muted)}
.pg-chart-stats{display:flex;gap:25px;padding-top:16px;border-top:1px solid var(--line);margin-top:14px;font-size:12px;color:var(--muted)}
.pg-chart-stats b{color:var(--ink);margin-left:5px}
.pg-focus{background:var(--dark);color:var(--dark-ink);border-color:var(--dark)}
.pg-focus .label,.pg-focus .muted{color:var(--dark-muted)}
.pg-focus h2{font-size:32px;line-height:1.12;margin:17px 0}
.pg-focus p{font-size:13px;color:var(--dark-muted)}
.pg-focus .pill{background:var(--dark-ink);color:var(--dark);margin-top:10px}
.pg-focus a,.pg-focus .pg-link{color:var(--dark-ink)}
.pg-link{background:transparent;border:0;color:var(--accent);padding:0;font:500 12px var(--body);text-decoration:underline;text-underline-offset:3px}
.pg-caption{font-size:12px;color:var(--muted);line-height:1.7}
.pg-empty{padding:30px 10px;text-align:center}
.pg-empty h2{font-size:32px}
.pg-empty p{max-width:420px;margin:12px auto 20px;color:var(--muted);font-size:14px}
.pg-note{padding:13px 16px;border:1px solid var(--line);border-radius:10px;font-size:12px;color:var(--muted);background:var(--bg2);margin-bottom:18px}
.pg-note button{margin-left:10px}
.pg-skills{display:grid;grid-template-columns:1fr 1fr;gap:0 24px}
.pg-skill{padding:17px 0;border-bottom:1px solid var(--line);min-width:0}
.pg-skill-head{display:flex;align-items:baseline;justify-content:space-between;gap:8px;font-size:12px}
.pg-skill-head strong{font-size:13px}
.pg-skill-head span{white-space:nowrap}
.pg-skill-head small{color:var(--muted);font-size:10px}
.pg-meter{height:5px;background:var(--bg2);border-radius:3px;margin:12px 0;position:relative}
.pg-meter i{height:100%;display:block;background:var(--accent);border-radius:3px}
.pg-skill .pg-caption{font-size:10px;display:flex;align-items:center;justify-content:space-between;gap:8px}
.pg-spark{width:90px;height:26px;flex-shrink:0}
.pg-spark polyline{stroke:var(--accent);stroke-width:1.8;fill:none}
.pg-calendar{display:grid;grid-template-columns:repeat(7,1fr);gap:6px;margin-top:20px}
.pg-day{aspect-ratio:1;min-width:0;border:1px solid var(--line);border-radius:8px;background:transparent;font:11px var(--mono);position:relative;color:var(--muted)}
.pg-day.practised{background:var(--pg-soft);border-color:#bacdb8;color:#204d38;font-weight:600}
.pg-day.practised:after{content:"";position:absolute;width:4px;height:4px;border-radius:50%;background:var(--pg-green);bottom:5px;left:calc(50% - 2px)}
.pg-day[aria-pressed="true"]{outline:2px solid var(--accent);outline-offset:1px}
.pg-weekday{text-align:center;font:10px var(--mono);color:var(--muted)}
.pg-reasons{padding-left:18px;font-size:13px;color:var(--muted)}
.pg-reasons li{margin:7px 0}
.pg-delivery{display:grid;grid-template-columns:repeat(5,1fr);gap:20px;margin-top:20px}
.pg-delivery b{font:32px var(--display);display:block}
.pg-delivery h3{font-size:12px;min-height:38px}
.pg-delivery .pg-caption{font-size:11px}
.pg-section-title{display:flex;justify-content:space-between;align-items:center;gap:15px;flex-wrap:wrap;margin-bottom:12px}
.pg-history-row{display:grid;grid-template-columns:42px 1fr auto;gap:14px;align-items:center;padding:18px 0;border-top:1px solid var(--line)}
.pg-history-score{font:26px var(--display);text-align:center;background:var(--bg2);border-radius:10px;padding:8px 0}
.pg-history-row h3{font:500 14px var(--body);line-height:1.45;margin:0 0 5px;overflow-wrap:anywhere}
.pg-history-row p{font-size:11px;color:var(--muted);margin:0}
.pg-history-actions{display:flex;gap:12px;align-items:center}
.pg-history-actions button{white-space:nowrap}
.pg-review{border-top:1px solid var(--line);padding:20px 0}
.pg-review:last-child{padding-bottom:0}
.pg-review h3{margin:6px 0;font-family:var(--display);font-size:25px}
.pg-review p{font-size:14px}
.pg-evidence{display:flex;gap:12px;flex-wrap:wrap;margin:12px 0}
.pg-tabs+div{min-width:0}
.pg-consent{font-size:14px;line-height:1.75}
.pg-consent ul{padding-left:20px}
.pg-switch{display:flex;gap:15px;align-items:center;justify-content:space-between;padding:16px 0;border-top:1px solid var(--line);border-bottom:1px solid var(--line);margin:18px 0}
.pg-toggle{appearance:none;width:44px!important;min-width:44px;height:26px;border:1px solid var(--muted)!important;border-radius:20px!important;background:var(--bg2);position:relative;cursor:pointer;padding:0!important;margin:0}
.pg-toggle:before{content:"";position:absolute;width:18px;height:18px;background:var(--muted);border-radius:50%;top:3px;left:3px}
.pg-toggle:checked{background:var(--accent);border-color:var(--accent)!important}
.pg-toggle:checked:before{left:21px;background:white}
.pg-dialog{max-width:570px;width:calc(100% - 32px);max-height:85dvh;overflow:auto;border:1px solid var(--line);border-radius:18px;background:var(--card);color:var(--ink);padding:28px;font-family:var(--body)}
.pg-dialog::backdrop{background:rgba(23,19,14,.4)}
.pg-dialog h2{font-size:34px;margin:8px 0 16px}
.pg-dialog .pg-toolbar{justify-content:flex-end;margin-top:24px}
.pg-dialog .pg-close{float:right;border:0;background:none;font-size:23px;color:var(--muted);padding:0 5px}
.pg-toast{position:fixed;bottom:22px;left:50%;transform:translateX(-50%);z-index:100;background:var(--ink);color:var(--bg);border-radius:12px;padding:14px 22px;max-width:calc(100% - 30px);width:max-content;font-size:13px;box-shadow:0 6px 30px #0002}
.pg-report-tools{margin:20px 0;display:grid;gap:16px}
.pg-transcript{margin-top:20px}
.pg-turn{padding:15px;border-top:1px solid var(--line);font-size:14px;white-space:pre-wrap;overflow-wrap:anywhere;scroll-margin-top:25px}
.pg-turn small{display:block;color:var(--muted);font:10px var(--mono);letter-spacing:.08em;text-transform:uppercase;margin-bottom:8px}
.pg-turn:focus{outline:2px solid var(--accent);background:var(--wash)}
.pg-compare{display:grid;grid-template-columns:1fr 1fr;gap:20px;margin:24px 0}
.pg-answer{white-space:pre-wrap;overflow-wrap:anywhere;font-size:15px;line-height:1.8}
.pg-after{border-top:3px solid var(--pg-green)}
.pg-preview{background:var(--bg2);border:1px solid var(--line);border-radius:18px;padding:30px;margin:22px 0}
.pg-preview h2{font-size:35px;margin:8px 0 12px}
.pg-preview p{font-size:14px;color:var(--muted);max-width:530px}
.pg-preview-steps{display:flex;gap:20px;border-top:1px solid var(--line);padding-top:18px;margin:22px 0;font:12px var(--mono);color:var(--muted)}
.pg-preview-steps span{flex:1}
@media(max-width:760px){.pg-grid{grid-template-columns:1fr}.pg-head{align-items:flex-start;flex-direction:column;gap:18px}.pg-stats{grid-template-columns:repeat(2,1fr)}.pg-stat:nth-child(2){border-right:0}.pg-stat:nth-child(-n+2){border-bottom:1px solid var(--line)}.pg-delivery{grid-template-columns:repeat(2,1fr)}.pg-compare{grid-template-columns:1fr}.pg-head h1{font-size:46px}.pg-subnav{gap:8px}.pg-period{width:100%}}
@media(max-width:440px){.nav{align-items:flex-start;gap:7px}.navright{gap:8px;max-width:210px}.navright .navlink{font-size:12px}.navright .chip{font-size:9px}.wm{font-size:15px;gap:5px}.wm i{font-size:19px}.pg-card{padding:20px}.pg-stat{padding:16px 20px}.pg-tabs{gap:22px}.pg-skills{grid-template-columns:1fr}.pg-history-row{grid-template-columns:36px 1fr;gap:12px}.pg-history-actions{grid-column:2}.pg-score-number{font-size:46px}.pg-preview-steps{gap:10px;font-size:10px}.pg-dialog{padding:22px}}
@media(prefers-reduced-motion:reduce){.pg *{scroll-behavior:auto!important;transition:none!important}}
/* Keep the next useful action near the top on a phone. */
@media(max-width:760px){
  .pg-grid{display:flex;flex-direction:column}
  .pg-grid>.pg-stack{display:contents}
  .pg-grid>div>section:first-child{order:0}
  .pg-grid .pg-focus{order:1}
  .pg-grid>aside>section:nth-child(2){order:2}
  .pg-grid>div>section:nth-child(2){order:3}
  .pg-grid>aside>section:nth-child(3){order:4}
}
