/* Stable Tracker V8.0 — lightweight additions; honors the active palette. */
.v8-onboarding,.v8-resume,.v8-support{display:block;margin:12px 0 18px;padding:14px 18px;border:1px solid var(--line);border-radius:14px;background:var(--panel)}
.v8-inline,.v8-settings-link,.v8-page-actions{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:10px 0}
.v8-inline>strong{flex:1;min-width:0}
.v8-shortcuts{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(130px,100%),1fr));gap:8px}
.v8-shortcuts>.btn{white-space:normal;min-height:40px}
.v8-editor{margin-top:12px;padding-top:12px;border-top:1px solid var(--line)}
.v8-editor>summary{cursor:pointer;font-weight:700;padding:5px 0}
.v8-editor label,.v8-export label{display:flex;flex-direction:column;gap:6px;margin:8px 0;font-size:13px}
.v8-editor label:has(input[type=checkbox]),.v8-export label:has(input[type=checkbox]),.v8-options label{flex-direction:row;align-items:center;gap:8px}
.v8-editor input[type=checkbox],.v8-options input[type=checkbox],.v8-today-row input{width:18px;height:18px;flex:none}
.v8-editor select,.v8-export select,.v8-export input[type=date],.v8-quality select{min-height:39px;max-width:100%;border:1px solid var(--line);border-radius:9px;background:var(--panel);color:var(--ink);padding:8px}
.v8-options{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(175px,100%),1fr));gap:8px;margin:10px 0}
.v8-today-row{display:flex;align-items:center;gap:10px;padding:10px 0;border-bottom:1px solid var(--line)}
.v8-today-link{text-align:left;background:transparent;border:0;color:var(--ink);font:inherit;font-size:13px;min-width:0;flex:1;padding:5px 0;overflow-wrap:anywhere}
.v8-today-link.is-done{text-decoration:line-through;opacity:.65}
.v8-quality{margin:12px 0 24px}.v8-section-head{display:flex;align-items:flex-start;flex-wrap:wrap;gap:10px}.v8-section-head>div{flex:1;min-width:170px}.v8-section-head h2,.v8-export h2,.v8-history h2{font:normal 23px Georgia,serif;margin:0 0 6px}.v8-section-head p{font-size:13px;color:var(--muted);margin:0}
.v8-quality label{display:block;margin:14px 0}.v8-quality-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(135px,100%),1fr));gap:8px;margin:12px 0}.v8-quality-stat{display:flex;flex-direction:column;align-items:flex-start;min-width:0;gap:6px;padding:12px;text-align:left;cursor:pointer;border-radius:10px;border:1px solid var(--line);background:var(--panel);color:var(--ink)}.v8-quality-stat.active{border-color:var(--wine);background:var(--wine-faint)}.v8-quality-stat strong{font:23px Georgia,serif}.v8-quality-stat span{font-size:12px;line-height:1.35}.v8-quality-results{display:flex;flex-wrap:wrap;gap:7px;margin:10px 0;max-height:330px;overflow:auto}.v8-quality-results .btn{white-space:normal}
.v8-history-list{max-height:60vh;overflow:auto}.v8-history-list article{padding:12px 0;border-top:1px solid var(--line)}.v8-history-list article>strong,.v8-history-list article>small{display:block;margin-bottom:6px}.v8-history-list article>small{color:var(--muted)}.v8-history-list details{margin:8px 0}.v8-history-list p{overflow-wrap:anywhere;font-size:12px}
.v8-dialog{border:1px solid var(--line);border-radius:18px;background:var(--panel);color:var(--ink);width:min(850px,calc(100vw - 24px));max-height:90dvh;overflow:auto;padding:0}.v8-dialog::backdrop{background:rgba(0,0,0,.37)}.v8-dialog-shell{padding:20px}.v8-dialog-shell>.v8-close{float:right}.v8-close{border:1px solid var(--line);background:var(--panel);color:var(--ink);border-radius:9px;width:36px;height:36px;font-size:20px;cursor:pointer}.v8-export fieldset{border:1px solid var(--line);border-radius:10px}.v8-export fieldset legend{font-size:13px}
#v8-active-stable{display:inline-flex;align-items:center;gap:5px;min-width:0;max-width:200px;font:600 12px -apple-system,BlinkMacSystemFont,sans-serif;color:var(--muted)}#v8-active-stable select{min-width:0;max-width:160px;height:36px;padding:4px 7px;font-size:12px;border:1px solid var(--line);border-radius:9px;background:var(--panel);color:var(--ink)}
.v8-help{display:inline-grid;place-items:center;vertical-align:middle;min-width:28px;height:28px;margin:3px 6px;border:1px solid var(--line);border-radius:50%;background:var(--panel);color:var(--wine);cursor:pointer;font-weight:700}
.v8-guide{position:fixed;z-index:180;right:16px;bottom:70px;width:min(345px,calc(100vw - 24px));padding:17px;border:2px solid var(--wine);border-radius:17px;background:var(--panel);color:var(--ink);box-shadow:0 12px 40px #0003}.v8-guide>div:first-child{display:flex;align-items:center;justify-content:space-between;gap:12px}.v8-guide h3{margin:10px 0;font-size:18px}.v8-guide p{font-size:13px;line-height:1.5}.v8-highlight{outline:3px solid var(--wine)!important;outline-offset:3px!important}
@media(max-width:1100px){#v8-active-stable>span{display:none}#v8-active-stable select{max-width:105px}}
@media(max-width:660px){#v8-active-stable{position:absolute;left:12px;top:calc(100% + 4px);max-width:calc(100vw - 24px);z-index:5;background:var(--panel);border-radius:9px}#v8-active-stable>span{display:inline}#v8-active-stable select{max-width:165px}.v208-topbar{margin-bottom:44px}.v8-guide{right:10px;bottom:55px}.v8-history-list{max-height:65dvh}}
@media print{.v8-guide,.v8-resume,.v8-dialog,.v8-editor{display:none!important}}
