/* Isolated owner-only preview. Existing Roster and Party styles remain untouched. */
#navAttendance[hidden],#attendanceView[hidden]{display:none!important}
#navAttendance[aria-current]{background:#513b24!important;color:#f5d8a1!important}
.attendance-panel{min-height:0!important}.attendance-head{display:flex;justify-content:space-between;gap:12px;align-items:center;flex-wrap:wrap}
.attendance-head h2{margin:0}.attendance-head small{font:10px system-ui;color:#d4b675;border:1px solid #795935;padding:2px 6px;border-radius:5px;margin-left:6px}
.attendance-actions{display:flex;gap:5px;align-items:center;flex-wrap:wrap}.attendance-actions button{min-width:31px;padding:6px 9px;font-size:11px}
.attendance-actions strong{font:600 11px system-ui;color:#e0bb78;min-width:135px;text-align:center}
.attendance-scroll{overflow:auto;max-height:calc(100vh - 290px);border:1px solid #4c3927;border-radius:7px}
.attendance-matrix{border-collapse:separate;border-spacing:0;width:100%;font:11px system-ui;table-layout:auto}
.attendance-matrix th,.attendance-matrix td{padding:3px 5px!important;border-bottom:1px solid #33281f;min-width:36px;text-align:center;height:27px}
.attendance-matrix thead th{position:sticky;top:0;background:#211910;z-index:3;border-bottom:1px solid #826242}
.attendance-matrix th:first-child,.attendance-matrix td:first-child{position:sticky;left:0;min-width:125px;max-width:125px;text-align:left;z-index:2;background:#17120f;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.attendance-matrix thead th:first-child{z-index:5;background:#211910}
.attendance-matrix tr:nth-child(even) td{background-color:#1d1713}.attendance-matrix tr:nth-child(even) td:first-child{background-color:#1d1713}
.attendance-matrix .att-code{font-size:10px;white-space:nowrap}.attendance-matrix .att-day{font-size:9px;color:#ae9a80;display:block}
.attendance-matrix .att-count{display:flex;align-items:center;justify-content:center;gap:2px;margin-top:2px;font-size:9px;color:#ac9678}
.attendance-matrix input[type=checkbox]{width:13px;height:13px;accent-color:#d5af6d;cursor:pointer;margin:0}
.attendance-matrix .att-cell{cursor:pointer;background:transparent;border:0;padding:0;min-height:21px;min-width:26px;font-size:14px;color:#7b6d5d}
.attendance-matrix .att-present{color:#90c784}.attendance-matrix .att-pending{color:#efaf52}.attendance-matrix .att-percent{font-weight:700;color:#e0bb78;font-variant-numeric:tabular-nums}
.attendance-matrix th.att-off{opacity:.55}.attendance-matrix .att-off-col{opacity:.6}.att-foot{margin-top:8px!important}
@media(max-width:600px){.attendance-matrix th:first-child,.attendance-matrix td:first-child{min-width:90px;max-width:90px}.attendance-panel{padding:9px!important}.attendance-actions strong{min-width:115px}}
/* v73 analytics — scoped to owner Attendance page */
#attendanceView .att-insights{display:grid;grid-template-columns:repeat(4,minmax(120px,1fr));gap:8px;margin:10px 0}
#attendanceView .att-stat{background:#201811;border:1px solid #59402b;border-radius:8px;padding:10px;display:flex;flex-direction:column;gap:4px}
#attendanceView .att-stat small{color:#bda68a;font:11px system-ui}#attendanceView .att-stat strong{color:#f2d5a6;font:700 21px system-ui}
#attendanceView .att-panels{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:12px}
#attendanceView .att-panel{border:1px solid #5c412e;border-radius:8px;padding:12px;background:#1b1511;min-width:0}
#attendanceView .att-panel h3{font:600 14px system-ui;color:#e5c693;margin:0 0 9px}
#attendanceView .att-chip{margin:3px;padding:5px 8px;font:11px system-ui}
#attendanceView .att-history-line{display:flex;flex-direction:column;border-bottom:1px solid #4c3527;padding:7px 0;gap:3px;font:12px system-ui}
#attendanceView .att-history-line small{color:#b4a18a;font:10px system-ui}
#attendanceView .att-link{border:0;background:transparent;color:#ead2a7;text-align:left;font:11px system-ui;cursor:pointer;padding:1px}
#attendanceView .att-departed{color:#c69c85;font:9px system-ui;display:block}
#attendanceView .att-good{color:#94d0a2;font-weight:700}#attendanceView .att-bad{color:#e7a495;font-weight:700}
#attendanceView .att-template{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin:8px 0;font:11px system-ui}
#attendanceView .att-template input:not([type=checkbox]){max-width:185px;min-width:90px}#attendanceView .att-template select{max-width:80px}
#attendanceView .attendance-scroll{max-height:calc(100vh - 390px)}
@media(max-width:750px){#attendanceView .att-insights{grid-template-columns:repeat(2,minmax(0,1fr))}#attendanceView .att-panels{grid-template-columns:1fr}}

/* v73.2: evenly sized event columns, compact checkboxes without cycling */
#attendanceView .attendance-matrix{table-layout:fixed;width:max(100%, 820px)}
#attendanceView .attendance-matrix th,#attendanceView .attendance-matrix td{box-sizing:border-box;padding:5px 3px!important;min-width:0;width:52px;text-align:center}
#attendanceView .attendance-matrix th:first-child,#attendanceView .attendance-matrix td:first-child{width:155px;min-width:155px;max-width:155px;text-align:left;padding-left:7px!important}
#attendanceView .attendance-matrix th:nth-last-child(3),#attendanceView .attendance-matrix td:nth-last-child(3){width:93px}
#attendanceView .attendance-matrix th:nth-last-child(2),#attendanceView .attendance-matrix td:nth-last-child(2){width:76px}
#attendanceView .attendance-matrix th:last-child,#attendanceView .attendance-matrix td:last-child{width:65px}
#attendanceView .att-member-check{appearance:auto;width:16px;height:16px;accent-color:#d5af6d;cursor:pointer;vertical-align:middle;margin:0}
#attendanceView .att-member-check:disabled{cursor:wait;opacity:.6}
#attendanceView .att-count{height:16px;margin-top:4px}
#attendanceView .att-count input{width:13px;height:13px}

/* v73.3: owner-only search and crosshair guides */
#attendanceView .att-filter-bar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:10px 0 8px;font:12px system-ui;color:#d9bd8a}
#attendanceView .att-filter-bar label{font-weight:600;white-space:nowrap}
#attendanceView #attMemberSearch{box-sizing:border-box;min-width:180px;width:min(320px,100%);padding:8px 12px;border:1px solid #755737;border-radius:7px;background:#16120f;color:#f4dfc0;font:12px system-ui;outline-offset:2px}
#attendanceView #attMemberSearch:focus-visible{outline:2px solid #d6b370}
#attendanceView #attSearchResult{color:#af9d85;font:11px system-ui}
/* The selectors override alternating rows, sticky first column and disabled-event opacity without changing checkbox state. */
#attendanceView .attendance-matrix tr td.att-cross-row,#attendanceView .attendance-matrix tr th.att-cross-row{background-color:#3a2d1c!important}
#attendanceView .attendance-matrix tr td.att-cross-col,#attendanceView .attendance-matrix tr th.att-cross-col{background-color:#403322!important}
#attendanceView .attendance-matrix tr td.att-cross-intersect,#attendanceView .attendance-matrix tr th.att-cross-intersect{background-color:#695032!important;box-shadow:inset 0 0 0 1px #e4bc73}
@media(max-width:600px){#attendanceView .att-filter-bar{gap:6px}#attendanceView #attMemberSearch{min-width:140px;flex:1}}

/* v73.4 — keep table viewport stable when searching, and pin Member while scrolling horizontally. */
#attendanceView .attendance-scroll{
  height:clamp(320px,calc(100dvh - 410px),570px);
  min-height:320px;max-height:none;
  overflow:auto;position:relative;isolation:isolate;
  overscroll-behavior:contain;
}
#attendanceView .attendance-matrix{border-collapse:separate;border-spacing:0;}
#attendanceView .attendance-matrix th:first-child,
#attendanceView .attendance-matrix td:first-child{
  position:sticky!important;left:0!important;z-index:4;
  box-shadow:2px 0 0 #60452d;
  background-color:#17120f;
}
#attendanceView .attendance-matrix tbody tr:nth-child(even) td:first-child{background-color:#1d1713;}
#attendanceView .attendance-matrix thead th{position:sticky!important;top:0!important;z-index:5;}
#attendanceView .attendance-matrix thead th:first-child{z-index:7!important;background-color:#211910;}
/* Keep sticky cells highlighted during crosshair hover. */
#attendanceView .attendance-matrix td:first-child.att-cross-row,
#attendanceView .attendance-matrix th:first-child.att-cross-col{background-color:#403322!important;}
#attendanceView .attendance-matrix td:first-child.att-cross-intersect{background-color:#695032!important;}
@media(max-width:600px){
  #attendanceView .attendance-scroll{height:clamp(300px,calc(100dvh - 390px),490px);min-height:300px;}
}

/* v73.6 owner-only screenshot scanner */
#attendanceView .att-scanner{margin:10px 0;background:#1c1712}
#attendanceView .att-scanner h3 small{font:10px system-ui;color:#bc9c71}
#attendanceView .att-scan-controls{display:flex;align-items:end;flex-wrap:wrap;gap:10px;margin:10px 0}
#attendanceView .att-scan-controls label{display:flex;flex-direction:column;gap:4px;min-width:160px;font:11px system-ui;color:#d9bf95}
#attendanceView .att-scan-controls select,#attendanceView .att-scan-controls input[type=file],#attendanceView .att-scan-match,#attendanceView .att-scan-decision{max-width:100%;background:#18130f;color:#f2dbc0;border:1px solid #795d3a;border-radius:5px;padding:6px;font:11px system-ui}
#attendanceView .att-scan-controls button{padding:7px 12px}
#attendanceView .att-scan-controls small{font:10px system-ui;color:#c5ae91}
#attendanceView .att-scan-review{max-height:300px;overflow:auto;border:1px solid #4e3a28;border-radius:6px}
#attendanceView .att-scan-row{display:grid;grid-template-columns:minmax(90px,1fr) 105px minmax(140px,1.2fr) 140px;gap:7px;padding:7px;align-items:center;border-bottom:1px solid #3e2f21;font:11px system-ui}
#attendanceView .att-scan-raw{overflow-wrap:anywhere;color:#f0d4b0}
#attendanceView .att-scan-exact{color:#88c79b}#attendanceView .att-scan-uncertain{color:#efb35f}
#attendanceView .att-scan-summary{color:#e0bd81;margin:8px 0;font:12px system-ui}
#attendanceView .att-review-cell{background:#6a471b!important;box-shadow:inset 0 0 0 1px #e0a650}
#attendanceView .att-member-check.att-review-check{outline:2px solid #f2b04f;outline-offset:2px}
@media(max-width:650px){#attendanceView .att-scan-row{grid-template-columns:1fr 1fr}#attendanceView .att-scan-row>*{min-width:0}}

#attendanceView .att-scan-state{display:flex;align-items:center;gap:7px;white-space:nowrap;font:11px system-ui;cursor:pointer}
#attendanceView .att-scan-state input{accent-color:#cba05c;margin:0}
#attendanceView .att-scan-present{color:#75cca0}
#attendanceView .att-scan-pending{color:#e8bc70}

#attendanceView .att-scan-row{grid-template-columns:minmax(110px,1fr) 105px minmax(180px,1.35fr)}
#attendanceView .att-scan-resolution{min-width:0}
#attendanceView .att-scan-verified-ign{color:#86d5a9;font-weight:600}
#attendanceView .att-scan-uncertain{color:#e8bc70}
#attendanceView .att-scan-exact{color:#86d5a9}
@media(max-width:650px){#attendanceView .att-scan-row{grid-template-columns:minmax(95px,1fr) minmax(85px,1fr)}#attendanceView .att-scan-resolution{grid-column:1/-1}}
