/* Shared mobile review, installation and guided help. */
[hidden]{display:none!important}
button,a,input,textarea,select{-webkit-tap-highlight-color:transparent}
:focus-visible{outline:3px solid var(--primary);outline-offset:3px}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
.review-page,.help-page{max-width:1200px;margin:auto;padding:24px 24px calc(40px + env(safe-area-inset-bottom))}
.duty-review{margin-top:32px;min-width:0;scroll-margin-top:100px}
.review-heading{display:flex;justify-content:space-between;align-items:center;gap:12px}
.review-heading h2,.review-heading h3{margin:4px 0;font-size:22px}.eyebrow{font-size:12px;letter-spacing:.08em;color:var(--primary);font-weight:700}
.review-month{border:1px solid var(--hairline);border-radius:24px;padding:8px 12px;font-size:14px;white-space:nowrap}
.review-legend,.scroll-hint{font-size:13px;color:var(--muted);line-height:1.7}.duty-review p{line-height:1.7}
.review-tools{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:12px;margin:20px 0 8px}
.review-tools label{display:flex;align-items:center;gap:8px;font-size:14px;margin:0}.review-tools input{width:180px;min-height:44px;border:1px solid var(--hairline);border-radius:12px;padding:8px 12px;background:var(--canvas);color:var(--ink);font:inherit}
#review-summary{font-size:13px;color:var(--muted)}
.duty-scroll{width:100%;max-height:65vh;max-height:65dvh;overflow:auto;overscroll-behavior:contain;border:1px solid var(--hairline);border-radius:16px;isolation:isolate;-webkit-overflow-scrolling:touch}
.duty-table{border-collapse:separate;border-spacing:0;font-size:14px;width:max-content;min-width:100%}
.duty-table th,.duty-table td{padding:3px;border-bottom:1px solid var(--hairline-soft);border-right:1px solid var(--hairline-soft);text-align:center;background:var(--canvas)}
.duty-table thead th{position:sticky;top:0;z-index:2;height:40px;background:var(--surface-soft)}
.duty-table tbody th,.duty-table thead th:first-child{position:sticky;left:0;z-index:1;min-width:110px;max-width:160px;padding:8px;font-size:13px;white-space:nowrap;text-align:left}
.duty-table thead th:first-child{z-index:3}.duty-table tbody th{background:var(--surface-soft)}
.duty-cell{display:block;width:46px;height:44px;min-width:46px;min-height:44px;margin:0;border:1px solid transparent;border-radius:7px;padding:0;font:700 13px var(--font);cursor:pointer}
.duty-cell.uncertain{border:1.5px dashed var(--primary)}.duty-cell:active{transform:scale(.95)}.chip-unknown{background:var(--surface-strong);color:var(--ink)}
.publish-panel{margin-top:20px;padding:20px;border:1px solid var(--hairline-soft);border-radius:16px;background:var(--surface-soft)}
.publish-panel label{display:flex;align-items:center;gap:10px;min-height:44px;margin:0}.publish-panel input{width:22px;height:22px;flex:none;accent-color:var(--primary)}
.publish-panel .btn{min-height:48px;height:auto;white-space:normal}.publish-panel button:disabled{opacity:.5;cursor:not-allowed}.publish-panel p:empty{display:none}
#shift-dialog{border:1px solid var(--hairline);border-radius:24px;background:var(--canvas);color:var(--ink);width:min(460px,calc(100% - 24px));max-height:85vh;max-height:85dvh;padding:0;overflow:auto;box-shadow:var(--shadow-lift)}
#shift-dialog::backdrop{background:rgba(0,0,0,.48)}.shift-dialog-inner{padding:24px}.dialog-close{width:44px;height:44px;flex:none;border:0;border-radius:50%;background:var(--surface-strong);color:var(--ink);font-size:28px;margin:0;padding:0;cursor:pointer}
#shift-original{display:block;width:200px;height:120px;object-fit:contain;background:white;border:1px solid var(--hairline);border-radius:12px;margin:16px auto}
.shift-options{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px}.shift-choice{min-width:0;min-height:64px;border:2px solid transparent;border-radius:12px;padding:6px 2px;margin:0;cursor:pointer;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px}
.shift-choice[aria-pressed=true]{border-color:var(--primary)}.shift-choice b{font-size:17px}.shift-choice span{font-size:12px}
.photo-details{margin:16px 0;border:1px solid var(--hairline);border-radius:14px;padding:14px}.photo-details summary{cursor:pointer;min-height:32px}.photo-details img{display:block;width:100%;margin-top:16px}
.calibration-page .layout>*{min-width:0}.calibration-page textarea{font:16px/1.7 var(--font);padding:12px;border:1px solid var(--hairline);border-radius:12px;background:var(--canvas);color:var(--ink)}
.calibration-page input[type=range]{min-height:44px;accent-color:var(--primary)}.calibration-page #check,.calibration-page #reset{border:1px solid var(--hairline);border-radius:12px;background:var(--surface-soft);color:var(--ink);min-height:48px;font:600 15px var(--font)}
.calibration-page #check{background:var(--primary);color:white;border-color:transparent;width:100%}.calibration-page #preview{border-radius:12px}.calibration-page #result{scroll-margin-top:100px}
.help-trigger{min-height:44px;border:1px solid var(--hairline);border-radius:22px;background:var(--canvas);color:var(--ink);padding:8px 13px;font:600 13px var(--font);cursor:pointer;white-space:nowrap;flex:none}
.nav .brand small{max-width:160px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.help-page>header{padding:24px 0}.help-page h1{font-size:30px;letter-spacing:-1px}.help-page p,.help-page li{line-height:1.8}.help-page .lead{max-width:650px;color:var(--muted)}
.help-overview{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin:24px 0}.help-card{padding:22px;background:var(--surface-soft);border:1px solid var(--hairline-soft);border-radius:20px}.help-card h2{font-size:18px;margin:8px 0}.help-number{color:var(--primary);font-weight:700;font-size:13px}
.help-page details{border-bottom:1px solid var(--hairline);padding:18px 0}.help-page summary{font-weight:600;cursor:pointer;min-height:30px}.help-page details p{color:var(--muted)}
.install-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}.install-grid ol{padding-left:24px}.install-grid li{margin-bottom:10px}.install-grid a{color:var(--primary)}.help-brand-icon{width:64px;height:64px;border-radius:16px}.help-note{font-size:14px;color:var(--muted)}
.guide-cover{position:fixed;inset:0;z-index:10000;background:transparent}.guide-ring{position:fixed;z-index:10001;border:2px solid #f35a8b;border-radius:14px;box-shadow:0 0 0 9999px rgba(0,0,0,.64);pointer-events:none;transition:top .15s,left .15s,width .15s,height .15s}
.guide-card{position:fixed;z-index:10002;left:50%;bottom:max(20px,env(safe-area-inset-bottom));transform:translateX(-50%);width:min(420px,calc(100% - 24px));max-height:48vh;max-height:48dvh;overflow:auto;padding:22px;background:var(--canvas);color:var(--ink);border:1px solid var(--hairline);border-radius:22px;box-shadow:var(--shadow-lift)}
.guide-card h2{font-size:20px;margin:10px 0}.guide-card p{font-size:14px;line-height:1.7;margin:10px 0 16px}.guide-top{display:flex;align-items:center;justify-content:space-between}.guide-top span{color:var(--primary);font-size:13px;font-weight:700}.guide-actions{display:flex;gap:8px;justify-content:flex-end}.guide-card button{min-height:44px}.guide-card .btn{height:44px;padding:0 16px}.guide-card a{font-size:13px;color:var(--muted);display:inline-block;margin-top:16px}
@media(max-width:744px){
 .nav{flex-wrap:wrap;gap:6px;padding-top:max(8px,env(safe-area-inset-top));height:auto;min-height:64px}.nav .brand{min-width:0}.nav .brand small{max-width:105px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.nav .help-trigger{padding:8px 10px}
 .review-page,.help-page{padding:20px 12px calc(32px + env(safe-area-inset-bottom))}.calibration-page{margin:8px auto!important;padding:12px!important;padding-bottom:calc(32px + env(safe-area-inset-bottom))!important}.calibration-page h1{font-size:23px}
 .duty-table tbody th,.duty-table thead th:first-child{min-width:90px;max-width:110px;font-size:12px}.review-heading h2{font-size:20px}.review-tools input{width:150px;font-size:16px}.review-tools{align-items:flex-start;flex-direction:column}.publish-panel{padding:14px}.publish-panel .btn{width:100%;padding:12px}
 .shift-dialog-inner{padding:16px}.shift-options{gap:5px}.help-overview,.install-grid{grid-template-columns:1fr}.help-card{padding:18px}
 input,select,textarea{font-size:16px}.mrow{flex-wrap:wrap}.mrow .entries{min-width:0;overflow-wrap:anywhere}.url-box{flex-wrap:wrap}.url-box input{font-size:16px!important;min-width:0}
}
@media(prefers-reduced-motion:reduce){.guide-ring{transition:none}}
