:root{--bg:#101113;--panel:#181a1d;--panel2:#141619;--border:#34373d;--text:#f5f5f5;--muted:#a9adb4;--red:#d9272e;--green:#77cfa1;--radius:12px;color-scheme:dark;font-family:"Segoe UI",Arial,sans-serif}*{box-sizing:border-box}html,body{margin:0;min-height:100%;background:var(--bg);color:var(--text)}button,input{font:inherit}.hidden{display:none!important}.app-shell{min-height:100vh;background:radial-gradient(circle at 83% -10%,rgba(217,39,46,.14),transparent 28rem),var(--bg)}.app-header{position:sticky;top:0;z-index:20;display:flex;align-items:center;justify-content:space-between;gap:1rem;min-height:76px;padding:.85rem clamp(1rem,3vw,2.5rem);border-bottom:1px solid #2e3136;background:rgba(16,17,19,.94);backdrop-filter:blur(14px)}.brand-lockup{display:flex;align-items:center;gap:.85rem;min-width:0}.brand-mark{display:grid;place-items:center;width:48px;height:48px;border:2px solid var(--red);border-radius:10px;font-weight:900;letter-spacing:-.08em}.brand-lockup p{margin:0 0 .1rem;color:var(--red);font-size:.73rem;font-weight:800;letter-spacing:.16em;text-transform:uppercase}.brand-lockup h1{margin:0;font-size:clamp(1rem,2vw,1.35rem);line-height:1.15}.header-actions,.editor-topline>div,.dialog-actions,.signature-actions{display:flex;align-items:center;gap:.6rem}.button{min-height:40px;padding:.55rem 1rem;border:1px solid var(--red);border-radius:9px;background:var(--red);color:#fff;font-weight:700;cursor:pointer}.button:hover{filter:brightness(1.08)}.button:disabled{cursor:not-allowed;opacity:.45}.button.outline{border-color:#474b52;background:#1c1f22}.button.small{min-height:34px;padding:.35rem .75rem;font-size:.85rem}.button.large{min-height:46px;padding:.65rem 1.15rem}.mobile-history{display:none}.app-grid{display:grid;grid-template-columns:minmax(235px,290px) minmax(0,1fr);gap:clamp(1rem,2vw,2rem);width:min(1500px,100%);margin:0 auto;padding:clamp(1rem,2.5vw,2rem);align-items:start}.history-panel{position:sticky;top:100px;max-height:calc(100vh - 124px);overflow:auto;border:1px solid #303339;border-radius:16px;background:#151719}.panel-heading{display:flex;align-items:center;justify-content:space-between;padding:1rem;border-bottom:1px solid #303339}.panel-heading h2{margin:0;font-size:1rem}.panel-heading span{min-width:1.8rem;padding:.2rem .45rem;border-radius:999px;background:#282b30;color:#c4c7cc;font-size:.78rem;text-align:center}.history-empty{display:grid;min-height:160px;place-items:center;padding:1.5rem;color:#8e939b;text-align:center}.history-item{display:grid;grid-template-columns:1fr auto;gap:.75rem;width:100%;padding:.85rem 1rem;border:0;border-bottom:1px solid #2d3035;background:transparent;color:inherit;text-align:left;cursor:pointer}.history-item:hover,.history-item.active{background:#22252a;box-shadow:inset 3px 0 var(--red)}.history-item strong,.history-item span{display:block}.history-item strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.history-item span{margin-top:.18rem;color:#8f949c;font-size:.78rem}.history-item b{align-self:center;color:#9ea2a9}.editor-panel{min-width:0;overflow:hidden;border:1px solid #303339;border-radius:18px;background:var(--panel);box-shadow:0 24px 70px rgba(0,0,0,.25)}.editor-topline{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.8rem clamp(1rem,2.5vw,1.5rem);border-bottom:1px solid #303339;background:#151719}.status-badge,.save-indicator{display:inline-flex;align-items:center;gap:.3rem;border-radius:999px;font-size:.78rem}.status-badge{padding:.3rem .6rem;border:1px solid #42464d;color:#b7bbc1;font-weight:700;text-transform:uppercase;letter-spacing:.06em}.status-badge.complete{border-color:#2e805b;background:rgba(46,128,91,.16);color:#7ed8aa}.save-indicator{color:#92979f}.save-indicator.saved{color:var(--green)}.save-indicator.error{color:#ff8589}.app-message{margin:1rem 1.5rem 0;padding:.75rem .9rem;border:1px solid #474b52;border-radius:10px;background:#23262a;color:#d0d2d6}.app-message.error{border-color:rgba(239,68,68,.5);background:rgba(239,68,68,.08);color:#ffb0b3}.form-section,.technicians-section{padding:clamp(1rem,2.5vw,1.5rem)}.sheet-details{display:grid;grid-template-columns:minmax(0,2fr) minmax(180px,.75fr);gap:1rem;border-bottom:1px solid #303339}label,.lead-signature,.signature-field{display:grid;gap:.45rem}label>span,.lead-signature>span,.signature-field>span{color:#aeb2b8;font-size:.78rem;font-weight:700;letter-spacing:.045em;text-transform:uppercase}input{width:100%;min-height:44px;padding:.55rem .7rem;border:1px solid #41454c;border-radius:8px;background:#111315;color:#fff;outline:0}input:focus{border-color:var(--red);box-shadow:0 0 0 3px rgba(217,39,46,.2)}.technicians-section{border-bottom:1px solid #303339}.section-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem;margin-bottom:1rem}.section-heading h2{margin:0;font-size:1.05rem}.section-heading p{margin:.15rem 0 0;color:#8f949c;font-size:.85rem}.section-heading>span{color:#9a9fa7;font-size:.82rem;white-space:nowrap}.technician-list{display:grid;gap:.75rem}.technician-card{display:grid;grid-template-columns:42px minmax(180px,1.35fr) minmax(120px,.55fr) minmax(120px,.55fr) minmax(190px,.9fr) 36px;gap:.75rem;align-items:end;padding:.9rem;border:1px solid #34383e;border-radius:13px;background:var(--panel2)}.technician-number{align-self:center;color:#5e636b;font-family:monospace;font-size:.86rem;font-weight:700;text-align:center}.remove-tech,.icon-button{border:0;background:transparent;color:#858a92;cursor:pointer}.remove-tech{align-self:center;font-size:1.25rem}.remove-tech:hover{color:#ff7d82}.signature-control{display:grid;gap:.45rem}.signature-preview{display:flex;align-items:center;gap:.55rem;min-height:44px;padding:.25rem .55rem;border:1px solid #3d4147;border-radius:8px;background:#fff;overflow:hidden}.signature-preview img{width:92px;height:34px;object-fit:contain}.signature-preview span{margin-left:auto;color:#17663e;font-size:.72rem;font-weight:800}.signature-empty{display:flex;align-items:center;min-height:44px;padding:0 .65rem;border:1px dashed #484c54;border-radius:8px;color:#8e939b;font-size:.8rem}.signature-actions .button{min-height:32px;padding:.3rem .65rem;font-size:.78rem}.field-error{margin:.4rem 0 0;color:#ff8f93;font-size:.8rem}.add-technician{width:100%;min-height:44px;margin-top:.85rem;border-style:dashed}.lead-section{background:#151719}.lead-fields{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(180px,.6fr);gap:1rem}.lead-signature{max-width:520px;margin-top:1rem}.editor-actions{display:flex;justify-content:flex-end;gap:.7rem;padding:1rem clamp(1rem,2.5vw,1.5rem);border-top:1px solid #303339;background:#111315}.signature-dialog{width:min(760px,calc(100vw - 1rem));padding:0;border:1px solid #41454c;border-radius:14px;background:#1b1d20;color:#fff}.signature-dialog::backdrop{background:rgba(0,0,0,.72)}.signature-dialog-inner{display:grid;gap:1rem;padding:1.2rem}.dialog-heading{display:flex;justify-content:space-between;gap:1rem}.dialog-heading h2,.dialog-heading p{margin:0}.dialog-heading p{margin-top:.3rem;color:#a9adb4;font-size:.9rem}.icon-button{font-size:2rem;line-height:1}.signature-canvas-wrap{position:relative;overflow:hidden;border:2px solid #555b64;border-radius:10px;background:#fff}.signature-canvas-wrap canvas{display:block;width:100%;height:min(34vh,280px);touch-action:none;cursor:crosshair}.signature-canvas-wrap span{position:absolute;inset:0;display:grid;place-items:center;pointer-events:none;color:#a7a7a7;text-transform:uppercase;letter-spacing:.14em}.dialog-actions{justify-content:flex-end}.print-root{display:none}
@media(max-width:1100px){.app-grid{grid-template-columns:230px minmax(0,1fr);gap:1rem}.technician-card{grid-template-columns:36px minmax(180px,1fr) minmax(120px,.6fr) minmax(120px,.6fr) 36px}.signature-field{grid-column:2/5}}
@media(max-width:760px){.app-header{align-items:flex-start;padding:.75rem 1rem}.brand-mark{width:42px;height:42px}.brand-lockup h1{max-width:42vw;font-size:.95rem}.header-actions .button{padding-inline:.7rem;font-size:.78rem}.mobile-history{display:inline-block}.app-grid{display:block;padding:.75rem}.history-panel{display:none;position:static;max-height:48vh;margin-bottom:.75rem}.history-panel.open{display:block}.editor-panel{border-radius:14px}.editor-topline{align-items:flex-start}.editor-topline>div{align-items:flex-start;flex-direction:column;gap:.35rem}.sheet-details,.lead-fields{grid-template-columns:1fr}.technician-card{grid-template-columns:34px minmax(0,1fr) 36px;gap:.75rem;padding:.9rem .75rem}.technician-number{grid-row:1;grid-column:1}.name-field{grid-row:1;grid-column:2}.remove-tech{grid-row:1;grid-column:3}.time-in-field{grid-column:1/3}.time-out-field{grid-column:3/4}.signature-field{grid-column:1/4}.editor-actions{position:sticky;bottom:0;z-index:10;display:grid;grid-template-columns:1fr 1fr;padding:.75rem}.editor-actions .button{min-height:48px;padding:.5rem;white-space:normal}}
@media(max-width:420px){.time-in-field,.time-out-field{grid-column:1/4}.editor-actions{grid-template-columns:1fr}}
@page{size:letter landscape;margin:.28in}
@media print{html,body{width:auto;min-height:0;background:#fff!important;color:#000!important;color-scheme:light}.app-shell,.signature-dialog{display:none!important}.print-root{display:block!important}.print-sheet{width:10.44in;height:7.94in;margin:0;overflow:hidden;break-after:page;page-break-after:always;background:#fff;color:#000;font-family:Arial,sans-serif}.print-sheet:last-child{break-after:auto;page-break-after:auto}.print-title-row{display:grid;grid-template-columns:1fr 2fr 1fr;align-items:center;height:.42in;border:1.5px solid #000;border-bottom:0;padding:0 .12in}.print-title-row h1{margin:0;font-size:15pt;text-align:center}.print-title-row span:last-child{font-size:8.5pt;text-align:right}.print-meta,.print-lead-meta{display:grid;grid-template-columns:.78in 1fr .7in 1.6in;height:.42in;border:1.5px solid #000}.print-meta>*,.print-lead-meta>*{display:flex;align-items:center;padding:0 .1in;border-right:1px solid #000;font-size:10pt}.print-meta>*:last-child,.print-lead-meta>*:last-child{border-right:0}.print-meta strong,.print-lead-meta strong{justify-content:center;background:#ededed;font-size:9pt}.print-table{width:100%;border-collapse:collapse;table-layout:fixed}.print-table th,.print-table td{border:1px solid #000;padding:0 .1in;overflow:hidden;vertical-align:middle}.print-table th{height:.36in;background:#ededed;font-size:9pt}.print-table td{height:.48in;font-size:10pt;white-space:nowrap}.print-table th:nth-child(1),.print-table td:nth-child(1){width:47%}.print-table th:nth-child(2),.print-table td:nth-child(2),.print-table th:nth-child(3),.print-table td:nth-child(3){width:12%;text-align:center}.print-table th:nth-child(4),.print-table td:nth-child(4){width:29%;text-align:center}.print-table td img{display:block;max-width:2.4in;width:auto;height:.42in;margin:0 auto;object-fit:contain}.print-lead-meta{margin-top:.18in}.print-lead-signature{display:grid;grid-template-columns:.78in 1fr;height:1.28in;border:1.5px solid #000;border-top:0}.print-lead-signature strong{display:flex;justify-content:center;align-items:flex-start;padding-top:.12in;border-right:1px solid #000;background:#ededed;font-size:9pt}.print-lead-signature img{align-self:center;max-width:3.2in;width:auto;height:.85in;margin-left:.28in;object-fit:contain}}
