/* v3.87: Staff-only legibility and responsive form hardening.
 * Isolated stylesheet loaded after the existing frontend styles.
 */
.asp-root.asp-staff-view { --asp-staff-field-bg:#17111f; --asp-staff-field-fg:#f8f5ff; --asp-staff-field-border:#655477; }
.asp-root.asp-staff-view .asp-staff-empty {
  display:block!important; width:100%; box-sizing:border-box; margin:18px 0;
  padding:20px 24px!important; border:1px solid #544365!important;
  border-radius:15px; background:#271d33!important; color:#f8f4ff!important;
  font-size:16px; font-weight:600; line-height:1.55; text-align:left;
  overflow-wrap:anywhere; -webkit-text-fill-color:#f8f4ff!important;
}
.asp-root.asp-staff-view .asp-staff-empty :is(span,strong,small,a) {color:#f8f4ff!important; -webkit-text-fill-color:#f8f4ff!important}
.asp-root.asp-staff-view :is(.asp-front-manager-filters,.asp-front-account-form,.asp-staff-form-grid,.asp-staff-edit-grid,.asp-staff-panel) {min-width:0;max-width:100%;box-sizing:border-box}
.asp-root.asp-staff-view :is(.asp-front-manager-filters,.asp-front-account-form,.asp-staff-form-grid) label {color:#f8f4ff!important; -webkit-text-fill-color:#f8f4ff!important; min-width:0; overflow-wrap:break-word}
.asp-root.asp-staff-view :is(.asp-front-manager-filters,.asp-front-account-form,.asp-staff-form-grid,.asp-staff-edit-grid) :is(input:not([type=checkbox]):not([type=radio]):not([type=submit]),select,textarea) {
 box-sizing:border-box; max-width:100%; min-width:0; border:1px solid var(--asp-staff-field-border)!important;
 background:var(--asp-staff-field-bg)!important; color:var(--asp-staff-field-fg)!important;
 -webkit-text-fill-color:var(--asp-staff-field-fg)!important; color-scheme:dark; line-height:1.4;
}
.asp-root.asp-staff-view :is(input,textarea)::placeholder {color:#c5b9d3!important;opacity:1}
.asp-root.asp-staff-view :is(.asp-front-account-form,.asp-front-manager-filters,.asp-staff-form-grid) :is(fieldset,legend,small,p) {color:#eee5fa;overflow-wrap:anywhere}
.asp-root.asp-staff-view .asp-front-manager-filters {display:grid!important;grid-template-columns:repeat(auto-fit,minmax(min(100%,205px),1fr))!important;gap:15px!important;align-items:end;}
.asp-root.asp-staff-view .asp-front-manager-filters>label {flex:none!important;width:100%;min-width:0!important;grid-column:auto}
.asp-root.asp-staff-view .asp-front-manager-filters>label:first-child {min-width:0!important;grid-column:auto}
.asp-root.asp-staff-view .asp-front-manager-filters :is(button,a) {min-height:46px;align-self:end}
.asp-root.asp-staff-view .asp-front-manager-filters>a {justify-content:center}
.asp-root.asp-staff-view :is(.asp-front-manager-filters,.asp-staff-form-grid) input[type=checkbox] {width:18px!important;height:18px!important;min-width:18px;accent-color:#9858ef}
.asp-root.asp-staff-view[data-theme=light] {--asp-staff-field-bg:#fff;--asp-staff-field-fg:#242131;--asp-staff-field-border:#c9bed8}
.asp-root.asp-staff-view[data-theme=light] .asp-staff-empty {background:#f4eefb!important;color:#272039!important;border-color:#d6cbe7!important;-webkit-text-fill-color:#272039!important}
.asp-root.asp-staff-view[data-theme=light] .asp-staff-empty :is(span,strong,small,a) {color:#272039!important;-webkit-text-fill-color:#272039!important}
.asp-root.asp-staff-view[data-theme=light] :is(.asp-front-manager-filters,.asp-front-account-form,.asp-staff-form-grid) label {color:#282237!important;-webkit-text-fill-color:#282237!important}
.asp-root.asp-staff-view[data-theme=light] :is(.asp-front-account-form,.asp-front-manager-filters,.asp-staff-form-grid) :is(fieldset,legend,small,p){color:#40364f}
.asp-root.asp-staff-view[data-theme=light] :is(.asp-front-manager-filters,.asp-front-account-form,.asp-staff-form-grid,.asp-staff-edit-grid) :is(input:not([type=checkbox]):not([type=radio]):not([type=submit]),select,textarea){color-scheme:light}
@media(max-width:680px){.asp-root.asp-staff-view .asp-front-manager-filters{grid-template-columns:minmax(0,1fr)!important;padding:14px!important}.asp-root.asp-staff-view .asp-front-manager-filters :is(button,a){width:100%;justify-content:center}.asp-root.asp-staff-view .asp-staff-empty{padding:16px!important}}

/* 3.91: correct white-on-white branch/role cards (reported in dark mode). */
.asp-root.asp-staff-view:not([data-theme="light"]) .asp-front-account-form .asp-branch-assignments,
.asp-root.asp-staff-view[data-theme="dark"] .asp-front-account-form .asp-branch-assignments {
  background:#21182b!important;border:1px solid #6a517f!important;color:#f8f3ff!important;
}
.asp-root.asp-staff-view:not([data-theme="light"]) .asp-front-account-form .asp-branch-assignments :is(legend,p,span,strong),
.asp-root.asp-staff-view[data-theme="dark"] .asp-front-account-form .asp-branch-assignments :is(legend,p,span,strong){
  color:#f8f3ff!important;-webkit-text-fill-color:#f8f3ff!important;opacity:1!important;
}
.asp-root.asp-staff-view:not([data-theme="light"]) .asp-front-account-form .asp-branch-check,
.asp-root.asp-staff-view[data-theme="dark"] .asp-front-account-form .asp-branch-check{
  background:#30243d!important;border:1px solid #705a87!important;color:#fff!important;
}
.asp-root.asp-staff-view:not([data-theme="light"]) .asp-front-account-form .asp-branch-check:has(input:checked),
.asp-root.asp-staff-view[data-theme="dark"] .asp-front-account-form .asp-branch-check:has(input:checked){
  background:#432c5d!important;border-color:#c09aff!important;
}
.asp-root.asp-staff-view .asp-front-account-form .asp-branch-check input[type=checkbox]{
  opacity:1!important;accent-color:#a665ff!important;flex-shrink:0!important;
}
.asp-root.asp-staff-view[data-theme="light"] .asp-front-account-form .asp-branch-assignments{
  background:#f7f4fc!important;border-color:#cfc4df!important;
}
.asp-root.asp-staff-view[data-theme="light"] .asp-front-account-form .asp-branch-check{
  background:#fff!important;color:#292035!important;border-color:#cfc4df!important;
}
.asp-root.asp-staff-view[data-theme="light"] .asp-front-account-form .asp-branch-assignments :is(legend,p,span,strong){
  color:#292035!important;-webkit-text-fill-color:#292035!important;
}
.asp-root.asp-login-view .asp-login-form input:not([type="checkbox"]){
  color:#fff!important;-webkit-text-fill-color:#fff!important;caret-color:#fff!important;
}
.asp-root.asp-login-view .asp-login-form input::placeholder{color:#bcb5d7!important;-webkit-text-fill-color:#bcb5d7!important;opacity:1!important}
.asp-root.asp-login-view .asp-login-form input:-webkit-autofill,
.asp-root.asp-login-view .asp-login-form input:-webkit-autofill:hover,
.asp-root.asp-login-view .asp-login-form input:-webkit-autofill:focus{
  -webkit-text-fill-color:#fff!important;-webkit-box-shadow:0 0 0 1000px #1b2044 inset!important;caret-color:white!important;
}
.asp-root.asp-staff-view .asp-staff-account-view-actions{display:flex;flex-wrap:wrap;align-items:center;gap:12px;margin:12px 0}
.asp-root.asp-staff-view .asp-staff-account-view-actions .asp-staff-preview-form button{min-height:43px}
.asp-root.asp-staff-view .asp-staff-account-view-actions form:last-child button{background:#c61927;color:#fff}
.asp-root.asp-staff-view .asp-general-student-preview{display:flex;flex-wrap:wrap;align-items:center;gap:12px;padding:16px 20px;margin:10px 0 24px;border:1px solid #685282;border-radius:14px;background:#281c38;color:#f8f3ff}
.asp-root.asp-staff-view .asp-general-student-preview button,
.asp-root.asp-staff-view .asp-staff-content-preview-button,
.asp-guide-pdf-preview button{background:#7443be;color:#fff;border:1px solid #bd97ed;border-radius:12px;padding:11px 17px;font:inherit;font-weight:800;cursor:pointer;min-height:44px}
.asp-root.asp-staff-view .asp-general-student-preview small{color:#eee1ff;font-size:13px}
.asp-root.asp-staff-view .asp-staff-content-preview-button{background:#322348;color:#f8f4ff;width:fit-content;max-width:100%}
.asp-root.asp-staff-view .asp-staff-photo-download{display:inline-flex;align-items:center;gap:6px;width:max-content;max-width:100%;text-decoration:none;background:#281d38;color:#f5e7ff;border:1px solid #7953a4;border-radius:9px;padding:9px 13px;font-weight:800}
.asp-guide-pdf-preview{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:12px 0}
.asp-guide-pdf-preview small{color:inherit;opacity:.8}
.asp-root .asp-countdown{gap:14px}
.asp-root .asp-countdown .asp-countdown-image{max-width:170px;width:clamp(70px,20vw,170px);height:120px;object-fit:cover;border-radius:14px;flex-shrink:0}
@media(max-width:600px){.asp-root .asp-countdown .asp-countdown-image{height:95px;width:95px}.asp-root.asp-staff-view .asp-general-student-preview{padding:12px}}

.asp-root.asp-staff-view .asp-general-demo-link{background:#7443be;color:#fff;text-decoration:none;border:1px solid #bd97ed;border-radius:12px;padding:11px 17px;font:inherit;font-weight:800;display:inline-flex}
/* v4.00.2: preview navigation is clickable. Server guards and simulation
   prevent real issuance/editing without disabling search, cards or links. */
.asp-root.asp-generic-student-demo :is(.asp-card-actions a,.asp-nav-icon,.asp-redeem-hero,.asp-partner-modal-actions a,.asp-inbox-link,.asp-profile-link){pointer-events:auto!important;opacity:1!important;cursor:pointer!important}

.asp-category-search{display:block;width:100%;min-height:40px;margin:6px 0;border:1px solid #7953a7;border-radius:10px;padding:9px 12px;background:#20172d;color:#fff}.asp-category-search::placeholder{color:#c6b9d7}.asp-searchable-category{display:block;min-width:190px}.asp-searchable-category select{display:block;width:100%}


/* v4.00 · Accessible workspace surfaces, announcement board and event/countdown editor. */
.asp-root.asp-dashboard-view.asp-staff-view[data-theme="light"] .asp-staff-layout :is(.asp-staff-panel,.asp-staff-table,.asp-staff-edit-grid>details,.asp-staff-category-management,.asp-staff-category-choice,.asp-staff-category-editor){background:#fff!important;color:#252032!important;border-color:#e2d9ec!important;}
.asp-root.asp-dashboard-view.asp-staff-view[data-theme="light"] .asp-staff-layout :is(.asp-staff-panel,.asp-staff-category-management,.asp-event-edit-row) :is(h2,h3,h4,summary,strong,label,span,p,small){color:#29213b;}
.asp-root.asp-dashboard-view.asp-staff-view[data-theme="light"] .asp-staff-layout :is(.asp-staff-panel,.asp-event-entry-form,.asp-countdown-settings-form,.asp-announcement-form) :is(input:not([type=checkbox]):not([type=radio]):not([type=file]),select,textarea){color-scheme:light;background:#fff!important;color:#21192b!important;-webkit-text-fill-color:#21192b!important;border:1px solid #cec5db!important;}
.asp-root.asp-dashboard-view.asp-staff-view[data-theme="light"] .asp-staff-layout :is(input,textarea)::placeholder{color:#71677d!important;-webkit-text-fill-color:#71677d!important;opacity:1;}
.asp-root.asp-dashboard-view.asp-staff-view[data-theme="dark"] .asp-staff-layout :is(.asp-staff-panel,.asp-staff-category-management,.asp-staff-category-choice,.asp-event-edit-row){background:#1a1423!important;color:#f7f1ff!important;border-color:#554069!important;}
.asp-root.asp-dashboard-view.asp-staff-view[data-theme="dark"] .asp-staff-layout :is(.asp-staff-panel,.asp-staff-category-management,.asp-event-edit-row) :is(h2,h3,h4,summary,strong,label,span,p,small){color:#f6efff;}
.asp-root.asp-dashboard-view.asp-staff-view[data-theme="dark"] .asp-staff-layout :is(.asp-event-entry-form,.asp-countdown-settings-form,.asp-announcement-form) :is(input:not([type=checkbox]):not([type=radio]),select,textarea){color-scheme:dark;background:#292036!important;color:#fff!important;-webkit-text-fill-color:#fff!important;border:1px solid #765994!important;}
.asp-root.asp-staff-view .asp-staff-panel :is(.asp-staff-table>article,.asp-staff-edit-grid>details,.asp-staff-category-choice){max-width:100%;overflow-wrap:anywhere;}
.asp-root.asp-staff-view .asp-staff-panel :is(button[type=submit],.asp-event-entry-form button,.asp-countdown-settings-form button){background:linear-gradient(115deg,#863ae7,#6826c2)!important;color:#fff!important;-webkit-text-fill-color:#fff!important;border:1px solid #aa79e9!important;border-radius:13px!important;min-height:46px;padding:11px 19px;font-weight:800;box-shadow:0 7px 18px rgba(93,31,155,.16);}
.asp-root.asp-staff-view .asp-staff-panel :is(button[type=submit],.asp-event-entry-form button,.asp-countdown-settings-form button):hover{filter:brightness(1.08);}
.asp-root.asp-staff-view :is(.asp-event-entry-form,.asp-countdown-settings-form){display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;padding:22px;margin:17px 0 26px;border-radius:20px;border:1px solid #e5d9ef;background:#fbf9ff;}
.asp-root.asp-staff-view :is(.asp-event-entry-form,.asp-countdown-settings-form)>:is(h3,p,.asp-event-wide){grid-column:1/-1;}
.asp-root.asp-staff-view :is(.asp-event-entry-form,.asp-countdown-settings-form) label{display:flex;flex-direction:column;gap:7px;min-width:0;font-weight:750;}
.asp-root.asp-staff-view :is(.asp-event-entry-form,.asp-countdown-settings-form) :is(input:not([type=checkbox]),select,textarea){box-sizing:border-box;width:100%;min-width:0;padding:11px 13px;border:1px solid #d5c9e4;border-radius:12px;min-height:44px;}
.asp-root.asp-staff-view .asp-countdown-enable{grid-column:1/-1;display:flex!important;flex-direction:row!important;align-items:center;gap:12px;padding:12px 15px;border-radius:12px;background:rgba(129,69,214,.09);}
.asp-root.asp-staff-view .asp-countdown-enable input{width:20px!important;height:20px!important;accent-color:#8742db;}
.asp-root.asp-staff-view :is(.asp-event-entry-form,.asp-countdown-settings-form)>button{justify-self:start;align-self:end;}
.asp-root.asp-staff-view[data-theme="dark"] :is(.asp-event-entry-form,.asp-countdown-settings-form){background:#241b31;border-color:#594473;}
.asp-root.asp-staff-view .asp-event-management .asp-section-subtitle{margin:25px 0 14px;font-size:22px;}
.asp-root.asp-staff-view .asp-staff-temporary-announcements{overflow:hidden;}
.asp-root.asp-staff-view .asp-announcement-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:19px;padding:18px 0 0;align-items:start;}
.asp-root.asp-staff-view .asp-announcement-form :is(h3,.asp-announcement-help,.asp-staff-switch,.asp-popup-media){grid-column:1/-1;}
.asp-root.asp-staff-view .asp-announcement-form h3{margin:0;font-size:clamp(21px,2.8vw,28px);}
.asp-root.asp-staff-view .asp-announcement-form .asp-announcement-help{padding:12px 17px;margin:0;border-radius:12px;background:rgba(134,62,212,.07);}
.asp-root.asp-staff-view .asp-announcement-form>label{display:flex;flex-direction:column;gap:9px;min-width:0;font-weight:750;}
.asp-root.asp-staff-view .asp-announcement-form>label:has(textarea){grid-column:1/-1;}
.asp-root.asp-staff-view .asp-announcement-form>small{grid-column:1/-1;margin:-14px 0 2px;color:#6e637a;}
.asp-root.asp-staff-view .asp-announcement-form textarea{display:block;box-sizing:border-box;width:100%!important;min-height:136px!important;max-width:100%;padding:13px 15px;resize:vertical;}
.asp-root.asp-staff-view .asp-announcement-form :is(input:not([type=checkbox]),select){box-sizing:border-box;width:100%;min-width:0;min-height:46px;border-radius:12px;padding:10px 14px;}
.asp-root.asp-staff-view .asp-announcement-form .asp-staff-switch{display:flex;flex-direction:row;align-items:center;gap:13px;padding:14px 17px;border-radius:12px;background:#f9edf1;font-weight:850;}
.asp-root.asp-staff-view .asp-announcement-form .asp-staff-switch input{width:20px!important;height:20px!important;accent-color:#8737dd;}
.asp-root.asp-staff-view .asp-announcement-form>button{grid-column:1/-1;justify-self:start;}
.asp-root.asp-staff-view[data-theme="dark"] .asp-announcement-form :is(.asp-staff-switch,.asp-announcement-help){background:#2b203c;color:#f7efff;}
.asp-root.asp-staff-view .asp-board{max-width:100%;margin:26px auto;}
.asp-root.asp-staff-view .asp-board :is(.asp-board-heading,.asp-board-editor,.asp-board-item){border-radius:20px;box-shadow:0 9px 30px rgba(30,19,55,.065);}
.asp-root.asp-staff-view .asp-board .asp-board-filters{display:grid;grid-template-columns:repeat(3,minmax(0,1fr)) auto auto;align-items:end;gap:12px;}
.asp-root.asp-staff-view .asp-board .asp-board-filters>label{min-width:0;}
.asp-root.asp-staff-view .asp-board .asp-board-editor summary{padding:9px;}
.asp-root.asp-staff-view .asp-board .asp-board-list{gap:14px;}
.asp-root.asp-staff-view[data-theme="dark"] .asp-board .asp-board-item{box-shadow:0 12px 28px rgba(0,0,0,.25);}
@media(max-width:900px){.asp-root.asp-staff-view .asp-board .asp-board-filters{grid-template-columns:repeat(2,minmax(0,1fr))}.asp-root.asp-staff-view .asp-board .asp-board-filters>:first-child{grid-column:1/-1}}
@media(max-width:680px){.asp-root.asp-staff-view :is(.asp-event-entry-form,.asp-countdown-settings-form,.asp-announcement-form){grid-template-columns:minmax(0,1fr);padding:15px;}.asp-root.asp-staff-view .asp-board .asp-board-filters{grid-template-columns:minmax(0,1fr)}.asp-root.asp-staff-view .asp-board .asp-board-filters>:first-child{grid-column:auto}}

/* 4.032: explicit foregrounds for referral badges in both staff themes. */
.asp-root.asp-staff-view .asp-staff-referral-history .asp-batch-review .asp-request-status {
  display:inline-flex;align-items:center;width:fit-content;margin:5px 0;
  padding:5px 11px;border-radius:999px;font-size:12px;line-height:1.4;
  font-weight:800;opacity:1!important;text-shadow:none!important;
}
.asp-root.asp-staff-view .asp-staff-referral-history .asp-batch-review .asp-request-status.pending {
  background:#ffdf87!important;color:#493100!important;-webkit-text-fill-color:#493100!important;
}
.asp-root.asp-staff-view .asp-staff-referral-history .asp-batch-review .asp-request-status.approved {
  background:#bff0d2!important;color:#10472a!important;-webkit-text-fill-color:#10472a!important;
}
.asp-root.asp-staff-view .asp-staff-referral-history .asp-batch-review .asp-request-status.rejected {
  background:#ffc3ce!important;color:#691329!important;-webkit-text-fill-color:#691329!important;
}
.asp-root.asp-staff-view .asp-staff-referral-history .asp-batch-review .asp-request-status.archived {
  background:#d9c9ed!important;color:#38224e!important;-webkit-text-fill-color:#38224e!important;
}
