/* Event management only. Builds on ticket-author.css; applies inside .ticket-events. */
.ticket-events #te-title:focus,.ticket-events h2[tabindex]:focus,.ticket-events #te-status:focus,.ticket-events .te-errors:focus{outline:none}
.ticket-events #te-title{overflow-wrap:anywhere}
.ticket-events #te-context{overflow-wrap:anywhere;font-weight:600;margin:0 0 8px}
.ticket-events #te-status{padding:12px 0;overflow-wrap:anywhere}
.ticket-events #te-status:not(:empty){background:#f4f3ee;border-radius:8px;padding:12px 16px}
.ticket-events #te-load-error{display:flex;flex-wrap:wrap;gap:12px;margin:16px 0}
.ticket-events #te-login{margin:12px 0}
.ticket-events .te-panel{margin:24px 0;padding:24px;background:#fff;border:1px solid #c9c7bd;border-radius:12px;overflow-wrap:anywhere}
.ticket-events .te-panel h2{margin-top:0}
.ticket-events .te-rows{list-style:none;margin:16px 0;padding:0}
.ticket-events .te-row{padding:16px 0;border-bottom:1px solid #c9c7bd;overflow-wrap:anywhere}
.ticket-events .te-row h2,.ticket-events .te-row h3{margin:0 0 4px;font-size:1.125rem;font-weight:700}
.ticket-events .te-row h2 a,.ticket-events .te-row h3 a{display:inline-flex;align-items:center;min-height:44px;max-width:100%}
.ticket-events .te-row p{margin:4px 0}
.ticket-events .te-row .actions{margin:12px 0 0}
.ticket-events .te-row-selected{background:#f4f3ee;box-shadow:-8px 0 0 #f4f3ee,8px 0 0 #f4f3ee}
.ticket-events .te-badge{display:inline-block;padding:0 10px;border:1px solid #555;border-radius:999px;font-size:.875rem;line-height:1.7;white-space:nowrap}
.ticket-events .te-summary{display:grid;grid-template-columns:minmax(96px,auto) minmax(0,1fr);gap:8px 16px;margin:16px 0;overflow-wrap:anywhere}
.ticket-events .te-summary dt{font-weight:600}
.ticket-events .te-summary dd{margin:0;white-space:pre-wrap}
.ticket-events .te-filter{display:grid;grid-template-columns:minmax(0,2fr) minmax(140px,1fr) auto;gap:12px;align-items:end;margin:16px 0}
.ticket-events .te-filter-single{grid-template-columns:minmax(0,1fr) auto}
.ticket-events .te-filter label{margin:0 0 8px}
.ticket-events .te-filter .btn{min-height:48px}
.ticket-events select{box-sizing:border-box;width:100%;min-height:48px;padding:10px 12px;border:1px solid #555;border-radius:8px;background:#fff;color:inherit;font:inherit}
.ticket-events [aria-invalid=true]{border-color:#b00020;border-width:2px}
.ticket-events .te-field-error{margin:6px 0 0;color:#b00020;font-size:.875rem;overflow-wrap:anywhere}
.ticket-events .te-errors{margin:16px 0;padding:12px 16px;border:2px solid #b00020;border-radius:8px;background:#fff;overflow-wrap:anywhere}
.ticket-events .te-warning{margin:12px 0 0;padding:8px 12px;border-left:4px solid #8a5a00;background:#fff8e6;overflow-wrap:anywhere}
.ticket-events .te-compare{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:24px}
.ticket-events .te-compare h3{margin:0 0 8px}
.ticket-events .te-compare dl{margin:0;overflow-wrap:anywhere}
.ticket-events .te-compare dt{font-weight:600;margin-top:8px}
.ticket-events .te-compare dd{margin:0;white-space:pre-wrap}
.ticket-events .te-visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
.ticket-events #te-unfiled{overflow-wrap:anywhere}
.ticket-events #te-unfiled a{display:inline-flex;align-items:center;min-height:44px}
.ticket-events #te-unfiled-hint{font-size:.875rem}
.ticket-events #di-event-context{margin:16px 0 24px;padding:16px 24px}
.ticket-events #di-event-context .actions{margin:12px 0 0}
.ticket-events #di-source-options{margin:8px 0 0}
.ticket-events #di-source-list{display:grid;gap:8px}
.ticket-events #di-source-error{margin:8px 0 0}
.ticket-events #di-next-hint{margin:12px 0 0;font-size:.875rem}
.ticket-events .di-option{display:flex;gap:12px;align-items:flex-start;min-height:44px;box-sizing:border-box;margin:0;padding:12px;border:1px solid #c9c7bd;border-radius:8px;background:#fff;font-weight:400;cursor:pointer;overflow-wrap:anywhere}
.ticket-events .di-option:has(input:checked){border:2px solid #111;padding:11px;background:#f4f3ee}
.ticket-events .di-option[data-unreadable]{cursor:not-allowed;background:#f4f3ee}
.ticket-events .di-option input{flex:none;width:22px;height:22px;margin:0;padding:0}
.ticket-events .di-option-text{display:grid;gap:2px;min-width:0}
.ticket-events .di-option-text strong{font-size:1rem;font-weight:700}
.ticket-events .di-option-text span{font-size:.875rem}
.ticket-events #di-relation{font-weight:600;overflow-wrap:anywhere}
.ticket-events .di-compare{margin:16px 0}
.ticket-events .di-compare>div{min-width:0;padding:16px;border-radius:8px;background:#fff}
.ticket-events #di-source-summary{border:1px dashed #555}
.ticket-events #di-target-summary{border:2px solid #111}
.ticket-events .di-diff{margin:6px 0 0;font-size:.875rem;overflow-wrap:anywhere}
.ticket-events #di-boundary{margin:16px 0 0;padding:12px 16px;border-radius:8px;background:#f4f3ee;overflow-wrap:anywhere}
.ticket-events #di-changed{margin:16px 0}
.ticket-events .te-panel h3{margin-top:0}
.ticket-events h3[tabindex]:focus{outline:none}
.ticket-events #di-imported .te-row p{overflow-wrap:anywhere}
.ticket-events .te-row h4{margin:0 0 4px;font-size:1rem;font-weight:700}
.ticket-events #di-imported a{display:inline-flex;align-items:center;min-height:44px;max-width:100%}
.ticket-events #di-next[aria-disabled=true],.ticket-events #di-confirm[aria-disabled=true],.ticket-events #di-change-source[aria-disabled=true]{opacity:.7;cursor:not-allowed}
@media(max-width:700px){
.ticket-author.ticket-events .te-row .actions{flex-direction:row;flex-wrap:wrap;gap:8px}
.ticket-author.ticket-events .te-row .actions>*{width:auto;flex:1 1 auto}
.ticket-events #di-event-context{padding:16px}
.ticket-events .te-panel{padding:16px}
.ticket-events .te-filter,.ticket-events .te-filter-single,.ticket-events .te-compare{grid-template-columns:minmax(0,1fr)}
.ticket-events .te-filter .btn{width:100%}
.ticket-events .te-summary{grid-template-columns:minmax(0,1fr);gap:0}
.ticket-events .te-summary dd{margin-bottom:8px}
}
/* Holder page. */
.ticket-pass{max-width:560px;margin:24px auto;overflow-wrap:anywhere}
.ticket-pass .tp-notice{margin:0 0 16px;padding:12px 16px;border-radius:8px;background:#f4f3ee;font-weight:600}
.ticket-pass .tp-state{margin:8px 0 0;text-align:center}
.ticket-pass .tp-state-in{font-weight:700}
.ticket-pass .tp-state-off{padding:12px 16px;border:2px solid #b00020;border-radius:8px;text-align:left;font-weight:600}
.ticket-pass .tp-closed{margin:12px 0 0;font-size:.875rem}
.ticket-pass .tp-owner{margin:24px 0 0;padding:16px 24px;border:1px solid #c9c7bd;border-radius:12px;background:#fff}
.ticket-pass .tp-owner h2{margin:0 0 12px}
.ticket-pass .tp-owner a{display:inline-flex;align-items:center;min-height:44px}
.ticket-pass .tp-boundary{margin:16px 0 0;font-size:.875rem}
/* Service page. */
/* Issuing and check-in screens. */
.ticket-events #te-issue{margin:16px 0 24px}
.ticket-events .te-issue-boundary{margin:12px 0 0;padding:12px 16px;border-radius:8px;background:#f4f3ee}
.ticket-events #te-issue-open[aria-disabled=true]{opacity:.7;cursor:not-allowed}
.ticket-events #te-issue-result{margin:16px 0 0}
.ticket-events h3[tabindex]:focus,.ticket-events #te-issue-title:focus,.ticket-events #te-confirm-title:focus,.ticket-events #te-checkin-result:focus{outline:none}
.ticket-events .te-qr{display:block;width:200px;max-width:100%;height:auto;margin:16px 0;background:#fff}
.ticket-events #te-ticket-link{font-size:.875rem}
.ticket-events #te-checkin-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin:16px 0}
.ticket-events #te-checkin-summary>div{padding:12px 8px;background:#fff;border:1px solid #c9c7bd;border-radius:8px;text-align:center}
.ticket-events #te-checkin-summary dt{font-size:.8125rem;font-weight:600}
.ticket-events #te-checkin-summary dd{margin:4px 0 0;font-size:1.25rem;font-weight:800;white-space:normal}
.ticket-events[data-mode=check-in] #te-status:empty{display:none}
.ticket-events .te-scan{margin:16px 0 32px;padding:16px;background:#fff;border:1px solid #c9c7bd;border-radius:12px}
.ticket-events .te-scan h2{margin-top:0}
.ticket-events .te-scan-view{position:relative;width:100%;max-width:420px;aspect-ratio:1/1;margin:0 auto 12px;border-radius:12px;overflow:hidden;background:#111}
.ticket-events .te-scan-view[hidden]{display:none}
.ticket-events #te-scan-video{display:block;width:100%;height:100%;object-fit:cover}
.ticket-events .te-scan-frame{position:absolute;inset:12%;border:3px solid #fff;border-radius:12px;box-shadow:0 0 0 999px rgba(0,0,0,.3)}
.ticket-events #te-scan-state{margin:0 0 12px}
.ticket-events #te-scan-state[data-state=denied],.ticket-events #te-scan-state[data-state=unsupported],.ticket-events #te-scan-state[data-state=lost]{padding:12px 16px;border:2px solid #8a5a00;border-radius:8px}
.ticket-events #te-checkin-help{margin:12px 0 0;font-size:.875rem}
.ticket-events #te-checkin-result{margin:0 0 12px;padding:16px}
.ticket-events .te-checkin-head{display:flex;align-items:center;gap:10px;margin:0;font-size:1.25rem;line-height:1.3}
.ticket-events #te-checkin-mark{flex:none;display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:50%;color:#fff;background:#b00020;font-weight:800}
.ticket-events #te-checkin-mark:empty{display:none}
.ticket-events #te-checkin-detail{margin:8px 0 0;overflow-wrap:anywhere}
.ticket-events #te-checkin-result .actions:empty{display:none}
.ticket-events #te-checkin-result[data-result=checked_in]{border:3px solid #1e7a3c;background:#eef8f1}
.ticket-events #te-checkin-result[data-result=checked_in] #te-checkin-mark{background:#1e7a3c}
.ticket-events #te-checkin-result[data-result=already]{border:3px solid #8a5a00;background:#fdf6e7}
.ticket-events #te-checkin-result[data-result=already] #te-checkin-mark{background:#8a5a00}
.ticket-events #te-checkin-result[data-result=unknown]{border:3px solid #47586b;background:#eef2f6}
.ticket-events #te-checkin-result[data-result=unknown] #te-checkin-mark{background:#47586b}
.ticket-events #te-checkin-result[data-result=cancelled],.ticket-events #te-checkin-result[data-result=bad],.ticket-events #te-checkin-result[data-result=invalid],.ticket-events #te-checkin-result[data-result=other_event]{border:3px solid #b00020;background:#fdf0f2}
.ticket-events #te-checkin-rows .te-row{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:12px;align-items:center}
.ticket-events #te-checkin-rows .te-row>*{grid-column:1}
.ticket-events #te-checkin-rows .te-row>.actions{grid-column:2;grid-row:1 / span 3;margin:0}
@media (max-width:360px){.ticket-events #te-checkin-summary{grid-template-columns:repeat(2,minmax(0,1fr))}}
.ticket-events .te-danger{margin:32px 0 0;padding:16px 0 0;border-top:1px solid #c9c7bd}
.ticket-events .te-danger summary,.ticket-events #te-bulk summary{min-height:44px;display:flex;align-items:center;cursor:pointer}
.ticket-events #te-bulk{margin:16px 0}
.ticket-events .te-row a.btn{min-height:44px}
/* Work screens on the shared paper and ink. */
.ticket-events{--te-ok:#176a43}
.ticket-events .author-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr);gap:32px;align-items:start}
.ticket-events .author-grid>*{min-width:0}
.ticket-events .author-preview{background:none;border:0;padding:0}
.ticket-events .author-boundary{font-size:14px;color:#404040}
.ticket-events label{display:block;margin:16px 0 8px;font-weight:650;overflow-wrap:anywhere}
.ticket-events label span{font-weight:400;font-size:14px;color:#404040}
.ticket-events input:not([type=checkbox]):not([type=radio]):not([type=file]),.ticket-events textarea{box-sizing:border-box;width:100%;min-height:48px;padding:12px;border:1px solid #555;border-radius:8px;background:#fff;color:#111;font:inherit}
.ticket-events input[type=file]{min-height:48px;max-width:100%}
.ticket-events fieldset{min-width:0;margin:0;padding:0;border:0}
.ticket-events legend{padding:0;font-weight:750}
.ticket-events .actions{display:flex;flex-wrap:wrap;gap:12px;margin:16px 0 0}
.ticket-events .btn{min-height:48px;white-space:normal;overflow-wrap:anywhere}
.ticket-events .te-issue-pick{margin:12px 0}
.ticket-events .te-pick{display:flex;gap:10px;align-items:center;min-height:44px;margin:4px 0;font-weight:600}
.ticket-events .te-pick input{flex:none;width:22px;height:22px;margin:0;accent-color:#111}
.ticket-events .te-pick span{font-size:inherit;color:inherit;font-weight:inherit;overflow-wrap:anywhere}
.ticket-events #te-issue-selection{font-weight:700;margin:4px 0}
.ticket-events #te-issue-open[aria-disabled=true]{background:#eee;border-color:#777;color:#555}
.ticket-events #te-tabs{margin:8px 0 20px}
.ticket-events #te-checkin-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin:16px 0}
.ticket-events #te-checkin-result[data-result=eligible]{border:3px solid #111;background:#fff}
.ticket-events #te-checkin-result[data-result=eligible] #te-checkin-mark{background:#111}
.ticket-events #te-checkin-result[data-result=offline]{border:3px solid #47586b;background:#eef2f6}
.ticket-events #te-checkin-result[data-result=offline] #te-checkin-mark{background:#47586b}
.ticket-pass{max-width:460px;margin:24px auto}
.ticket-pass .tp-qr{inline-size:min(100%,224px)}
.ticket-pass .t2w-ticket{max-inline-size:none}
.t2w-service .t2w-section .steps{margin-top:16px}
@media(max-width:799px){.ticket-events .author-grid{grid-template-columns:minmax(0,1fr);gap:24px}.ticket-events .te-filter{grid-template-columns:minmax(0,1fr)}}
.ticket-pass h1{margin:16px 0 4px}
/* D0: issuing steps, server-drawn review, duplicate decisions, owner state on the ticket page, optional camera */
.ticket-events .t2w-steps{display:flex;flex-wrap:wrap;gap:8px 20px;margin:12px 0 16px;padding:0;list-style:none}
.ticket-events .t2w-steps li{padding:4px 0;color:#444;line-height:1.5}
.ticket-events .t2w-steps li[aria-current=step]{color:#111;font-weight:800;box-shadow:inset 0 -3px #111}
.ticket-events #te-issue-people{margin:12px 0}
.ticket-events #te-issue-people summary{min-height:44px;display:flex;align-items:center;font-weight:700;cursor:pointer}
.ticket-events .te-people{margin:8px 0 0;padding-inline-start:24px;max-height:24rem;overflow:auto;overflow-wrap:anywhere}
.ticket-events .te-dup{margin:4px 0;padding:8px 12px;border:1px solid #8a5a00;border-radius:8px}
.ticket-events .te-dup legend{padding:0 4px;font-weight:700;overflow-wrap:anywhere}
.ticket-events .te-scan summary{min-height:48px;display:flex;align-items:center;font-weight:700;cursor:pointer}
.ticket-events #te-scan-state{margin:16px 0;font-weight:600}
.ticket-pass .tp-next{margin:12px 0 0}
.ticket-pass .tp-owner-state{margin:8px 0 12px;font-weight:700;overflow-wrap:anywhere}
.ticket-pass .tp-owner-state[data-state=cancelled]{color:#b00020}
/* Holder ticket only, independent of ink/ivory/custom/legacy theme classes. */
.ticket-pass .t2w-ticket.tp-card{--ticket-image-inset:24px}
.ticket-pass .t2w-ticket.tp-card>.design-event-logo{margin:var(--ticket-image-inset) var(--ticket-image-inset) 4px;max-height:56px;max-width:min(60%,240px);object-fit:contain}
.ticket-pass .t2w-ticket.tp-card>.design-ticket-art{width:calc(100% - var(--ticket-image-inset) - var(--ticket-image-inset));margin:12px var(--ticket-image-inset) 0;object-fit:contain;object-position:left center}
@media(max-width:799px){.ticket-pass .t2w-ticket.tp-card{--ticket-image-inset:20px}}
@media(max-width:430px){.ticket-pass .t2w-ticket.tp-card{--ticket-image-inset:16px}}
/* Same actual entry state in the two ticket lists; never inferred from action buttons. */
.ticket-events :is(#te-tickets,#te-checkin-rows) .te-badge[data-checked-in=true]{font-weight:750;color:#155c2b;background:#eef8f1;border-color:#1e7a3c}
/* Only the ticket-detail toolbar; recovery/consent/other action groups keep their layout. */
@media(max-width:700px){.ticket-events #te-ticket-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.ticket-events #te-ticket-actions>.btn{box-sizing:border-box;min-width:0;width:100%;min-height:48px;height:auto;white-space:normal;overflow-wrap:anywhere}.ticket-events #te-ticket-actions>#te-back{grid-column:1/-1}}
@media(max-width:380px){.ticket-events #te-ticket-actions{grid-template-columns:minmax(0,1fr)}}
