*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy:       #305696;
  --navy-mid:   #25447a;
  --navy-light: #4570b8;
  --gold:       #7ab338;
  --gold-light: #94c95a;
  --blue-accent:#009de2;
  --green-tint: #ebf4e1;
  --white:      #ffffff;
  --off-white:  #eef3fa;
  --s100:       #eef1f6;
  --s200:       #dde3ed;
  --s400:       #8e9db5;
  --s600:       #395b81;
  --s800:       #1e2a3a;
  --green:      #7ab338;
  --green-pale: #ebf4e1;
  --red:        #c0392b;
  --red-pale:   #fdf0ee;
  --amber:      #d97706;
  --amber-pale: #fffbeb;
  --blue-pale:  #e3f3fc;
  --r-sm: 8px; --r-md: 12px; --r-lg: 18px; --r-xl: 26px; --r-pill: 100px;
  --sh-sm: 0 1px 3px rgba(48,86,150,.08), 0 1px 2px rgba(48,86,150,.06);
  --sh-md: 0 4px 12px rgba(48,86,150,.10);
  --sh-lg: 0 10px 30px rgba(48,86,150,.14);
}

html { scroll-behavior: smooth; overflow-x: hidden; }
body { font-family: 'Nunito Sans', system-ui, sans-serif; font-size: 15px; line-height: 1.6; color: var(--s800); background: var(--off-white); -webkit-font-smoothing: antialiased; overflow-x: hidden; }

h1, h2, h3 { font-family: 'Poppins', sans-serif; font-weight: 700; line-height: 1.2; color: var(--navy); }
h1 { font-size: clamp(1.5rem, 3vw, 2rem); }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.05rem; }
p { color: var(--s600); }
a { color: var(--navy); text-decoration: none; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; padding: .6rem 1.3rem; border-radius: var(--r-pill); font-family: 'Poppins', sans-serif; font-size: .85rem; font-weight: 600; cursor: pointer; border: none; transition: transform .1s ease, background-color .15s ease, box-shadow .15s ease; white-space: nowrap; }
.btn:active:not(:disabled) { transform: scale(.97); }
.btn:disabled { opacity: .5; pointer-events: none; }
.btn-primary { background: var(--navy); color: #fff; }
.btn-primary:hover { background: var(--navy-mid); transform: translateY(-1px); box-shadow: var(--sh-md); }
.btn-gold { background: var(--gold); color: #fff; }
.btn-gold:hover { background: #6a9e2e; transform: translateY(-1px); box-shadow: var(--sh-md); }
.btn-outline { background: transparent; color: var(--navy); border: 1.5px solid var(--s200); }
.btn-outline:hover { border-color: var(--navy); background: var(--s100); }
.btn-ghost { background: transparent; color: var(--s600); border-radius: var(--r-md); }
.btn-ghost:hover { background: var(--s100); color: var(--s800); }
.btn-danger { background: var(--red); color: #fff; }
.btn-danger:hover { background: #a93226; }
.btn-sm { padding: .4rem .9rem; font-size: .78rem; }
.btn-lg { padding: .85rem 1.8rem; font-size: .95rem; }
.btn-icon { padding: .45rem; border-radius: 50%; }
.w-full { width: 100%; justify-content: center; }

/* Form */
.input, .textarea, .select {
  width: 100%; padding: .58rem .8rem; border: 1.5px solid var(--s200);
  border-radius: var(--r-sm); font-family: inherit; font-size: .875rem;
  color: var(--s800); background: var(--white); outline: none; transition: border-color .2s ease, box-shadow .2s ease;
}
.input:focus, .textarea:focus, .select:focus { border-color: var(--navy); box-shadow: 0 0 0 3px rgba(48,86,150,.12); }
.input::placeholder, .textarea::placeholder { color: var(--s400); }
.textarea { resize: vertical; min-height: 80px; line-height: 1.5; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238e9db5' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .7rem center; padding-right: 2rem; cursor: pointer; }
label { display: block; font-size: .78rem; font-weight: 500; color: var(--s600); margin-bottom: .3rem; }
.form-group { display: flex; flex-direction: column; }
.hint { font-size: .72rem; color: var(--s400); margin-top: .25rem; }
.field-error { font-size: .72rem; color: var(--red); margin-top: .25rem; }
.field-ok { font-size: .72rem; color: var(--green); margin-top: .25rem; }

/* Cards */
.card { background: var(--white); border-radius: var(--r-lg); box-shadow: var(--sh-sm); overflow: hidden; }
.status-bar-row { position: relative; padding-left: 5px; }
.status-bar-row::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--s200); }
.status-bar-row.sb-draft::before     { background: var(--s400); }
.status-bar-row.sb-submitted::before { background: var(--blue-accent); }
.status-bar-row.sb-review::before    { background: var(--gold); }
.status-bar-row.sb-action::before    { background: var(--amber); }
.status-bar-row.sb-approved::before  { background: var(--green); }
.status-bar-row.sb-denied::before    { background: var(--red); }
.status-bar-row.sb-archived::before  { background: var(--s200); }
.card-header { padding: 1rem 1.25rem; border-bottom: 1px solid var(--s100); }
.card-body { padding: 1.25rem; }

/* Badges */
.badge { display: inline-flex; align-items: center; padding: .18rem .6rem; border-radius: 100px; font-size: .7rem; font-weight: 600; }
.badge-draft     { background: var(--s100); color: var(--s600); }
.badge-submitted { background: var(--blue-pale); color: var(--navy); }
.badge-review    { background: var(--amber-pale); color: var(--amber); }
.badge-action    { background: #fff3cd; color: #856404; }
.badge-approved  { background: var(--green-pale); color: var(--green); }
.badge-denied    { background: var(--red-pale); color: var(--red); }
.badge-archived  { background: var(--s100); color: var(--s400); }
.badge-filed     { background: var(--blue-pale); color: var(--navy); }
.badge-hearing   { background: var(--amber-pale); color: var(--amber); }
.banner-warning { display: flex; align-items: flex-start; gap: .6rem; background: #fffbeb; border: 1px solid rgba(217,119,6,.25); color: #8a5a07; border-radius: var(--r-md); padding: .75rem 1rem; font-size: .85rem; line-height: 1.5; }
.banner-warning svg { flex-shrink: 0; margin-top: .1rem; color: #d97706; }
.badge-decision  { background: var(--green-pale); color: var(--green); }
.badge-emp       { background: var(--navy); color: var(--white); }
.badge-admin     { background: var(--gold); color: var(--white); }

/* Layout */
.app-shell { display: flex; min-height: 100vh; }
.sidebar { width: 230px; height: 100vh; background: var(--sidebar-bg, var(--white)); border-right: 1px solid var(--s100); display: flex; flex-direction: column; flex-shrink: 0; position: fixed; top: 0; left: 0; bottom: 0; z-index: 100; transition: transform .25s; overflow-y: hidden; }
.sidebar-logo { padding: 1.25rem 1rem; border-bottom: 1px solid var(--s100); position: relative; flex-shrink: 0; }
.sidebar-logo h2 { color: var(--navy); font-size: .95rem; margin-bottom: .1rem; }
.sidebar-logo span { font-size: .68rem; color: var(--s400); font-family: inherit; }
.notif-modal-bg { position: fixed; inset: 0; background: rgba(15,23,42,.5); z-index: 999; display: none; align-items: center; justify-content: center; padding: 1rem; }
.notif-modal-bg.open { display: flex; animation: modalFadeIn .15s ease; }
@keyframes modalFadeIn { from { opacity: 0; } to { opacity: 1; } }
.notif-modal { background: var(--white); border-radius: var(--r-lg); width: 420px; max-width: 100%; max-height: 70vh; display: flex; flex-direction: column; box-shadow: var(--sh-lg); overflow: hidden; animation: modalPopIn .18s ease; }
@keyframes modalPopIn { from { opacity: 0; transform: scale(.96) translateY(6px); } to { opacity: 1; transform: scale(1) translateY(0); } }
.notif-panel-header { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.25rem; border-bottom: 1px solid var(--s100); flex-shrink: 0; }
.notif-panel-header h4 { font-size: .95rem; color: var(--navy); font-family: 'Poppins', sans-serif; font-weight: 700; }
.notif-modal-list { overflow-y: auto; flex: 1; }
.notif-item { display: flex; flex-direction: column; gap: .15rem; padding: .85rem 1.25rem; border-bottom: 1px solid var(--s100); cursor: pointer; transition: background .15s; }
.notif-item:hover { background: var(--s100); }
.notif-item.unread { background: var(--blue-pale); }
.notif-item-title { font-size: .85rem; font-weight: 700; color: var(--navy); font-family: 'Poppins', sans-serif; }
.notif-item-view { display: flex; align-items: center; gap: .2rem; font-size: .7rem; font-weight: 700; color: var(--navy); opacity: 0; transform: translateX(-4px); transition: opacity .15s, transform .15s; flex-shrink: 0; }
.notif-item:hover .notif-item-view { opacity: 1; transform: translateX(0); }
.notif-item-delete { background: none; border: none; cursor: pointer; color: var(--s400); display: flex; padding: .15rem; border-radius: 50%; flex-shrink: 0; opacity: 0; transition: opacity .15s, background .15s, color .15s; }
.notif-item:hover .notif-item-delete { opacity: 1; }
.notif-item-delete:hover { background: var(--red-pale); color: var(--red); }
.notif-item-body { font-size: .8rem; color: var(--s600); font-family: 'Nunito Sans', sans-serif; }
.notif-item-time { font-size: .72rem; color: var(--s400); margin-top: .1rem; }
.notif-empty { padding: 3rem 1.25rem; text-align: center; color: var(--s400); font-size: .85rem; }

/* Custom chart tooltip (work-summary graph) — fast fade-in, themed, replaces the slow/plain native browser tooltip */
.chart-tooltip { position: absolute; transform: translate(-50%, -100%); background: var(--navy); color: #fff; font-size: .72rem; font-weight: 600; padding: .35rem .6rem; border-radius: var(--r-sm); pointer-events: none; opacity: 0; transition: opacity .08s ease; white-space: nowrap; z-index: 10; box-shadow: var(--sh-md); }
.chart-tooltip.visible { opacity: 1; }
.chart-tooltip::after { content: ''; position: absolute; top: 100%; left: 50%; transform: translateX(-50%); border: 5px solid transparent; border-top-color: var(--navy); }

/* Custom confirm dialog (replaces native browser confirm()) */
.ads-confirm-bg { position: fixed; inset: 0; background: rgba(15,23,42,.5); z-index: 1000; display: none; align-items: center; justify-content: center; padding: 1rem; }
.ads-confirm-bg.open { display: flex; animation: modalFadeIn .15s ease; }
.ads-confirm-box { background: var(--white); border-radius: var(--r-lg); width: 420px; max-width: 100%; padding: 1.5rem; box-shadow: var(--sh-lg); animation: modalPopIn .18s ease; }
.sidebar-nav { flex: 1; min-height: 0; overflow-y: auto; padding: .75rem .6rem; display: flex; flex-direction: column; gap: .2rem; }
.nav-item { display: flex; align-items: center; gap: .65rem; padding: .58rem .8rem; border-radius: var(--r-sm); color: var(--s600); font-size: .83rem; font-weight: 500; cursor: pointer; border: none; background: none; width: 100%; text-align: left; text-decoration: none; transition: all .15s; }
.nav-item:hover { background: var(--blue-pale); color: var(--navy); }
.nav-item.active { background: var(--navy); color: #fff; }
.nav-item svg { width: 15px; height: 15px; flex-shrink: 0; }
.nav-section-label { font-size: .63rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--s400); padding: .6rem .8rem .2rem; }
.sidebar-footer { padding: .6rem; border-bottom: 1px solid var(--s100); flex-shrink: 0; }
.sidebar-user { display: flex; align-items: center; gap: .6rem; padding: .45rem .8rem; margin-bottom: .35rem; }
.sidebar-avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--blue-pale); color: var(--navy); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.sidebar-user-name { font-size: .78rem; font-weight: 500; color: var(--s800); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user-email { font-size: .67rem; color: var(--s400); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Dark sidebar variant (Burns) — applied via a class toggle on .sidebar, never
   touching the default light styling above, so ADS's sidebar is completely
   unaffected. Covers every text element that would otherwise be unreadable
   dark-gray-on-blue once the background switches. */
.sidebar.sidebar-dark { background: var(--navy); border-right: none; }
.sidebar.sidebar-dark .sidebar-logo { border-bottom-color: rgba(255,255,255,.15); }
.sidebar.sidebar-dark .sidebar-logo h2 { color: #fff; }
.sidebar.sidebar-dark .sidebar-logo span { color: rgba(255,255,255,.6); }
.sidebar.sidebar-dark #notif-bell-btn { color: rgba(255,255,255,.75); }
.sidebar.sidebar-dark .nav-section-label { color: rgba(255,255,255,.5); }
.sidebar.sidebar-dark .nav-item { color: rgba(255,255,255,.8); }
.sidebar.sidebar-dark .nav-item:hover { background: rgba(255,255,255,.12); color: #fff; }
.sidebar.sidebar-dark .nav-item.active { background: #fff; color: var(--navy); }
.sidebar.sidebar-dark .sidebar-footer { border-bottom-color: rgba(255,255,255,.15); }
.sidebar.sidebar-dark .sidebar-user-name { color: #fff; }
.sidebar.sidebar-dark .sidebar-user-email { color: rgba(255,255,255,.6); }
.sidebar.sidebar-dark .brand-toggle { background: rgba(255,255,255,.12) !important; }
.main-content { margin-left: 230px; flex: 1; min-height: 100vh; }

/* Page */
.page { padding: 1.75rem 2.5rem; width: 100%; max-width: 1400px; margin: 0 auto; }
.page-wide { padding: 1.75rem 2.5rem; width: 100%; max-width: 1600px; margin: 0 auto; }
.page-narrow { padding: 1.75rem 2.5rem; width: 100%; max-width: 760px; margin: 0 auto; }

/* Stack / Row / Grid */
.stack { display: flex; flex-direction: column; }
.gap-sm { gap: .5rem; } .gap-md { gap: .9rem; } .gap-lg { gap: 1.4rem; }
.row { display: flex; align-items: center; }
.row-between { display: flex; align-items: center; justify-content: space-between; }
.row-gap-sm { gap: .45rem; } .row-gap-md { gap: .75rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: .85rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: .85rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: .85rem; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: .85rem; }
.account-grid { display: flex; flex-direction: column; gap: 1.25rem; max-width: 640px; }
.account-grid > .card { margin-bottom: 0 !important; }

/* Tab tiles (case-detail navigation, redesigned from thin pill tabs to clickable cards) */
.tab-tile-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-bottom: 1.25rem; }
.tab-tile { display: flex; flex-direction: column; align-items: center; gap: .5rem; background: var(--white); border: 1.5px solid var(--s200); border-radius: var(--r-lg); padding: 1rem .75rem; cursor: pointer; transition: all .18s; box-shadow: var(--sh-sm); text-align: center; }
.tab-tile:hover { border-color: var(--navy-light); transform: translateY(-2px); box-shadow: var(--sh-md); }
.tab-tile.active { border-color: var(--navy); background: var(--blue-pale); }
.tab-tile-icon { width: 36px; height: 36px; border-radius: 50%; background: var(--s100); display: flex; align-items: center; justify-content: center; color: var(--s600); transition: all .18s; }
.tab-tile.active .tab-tile-icon { background: var(--navy); color: #fff; }
.tab-tile-label { font-size: .8rem; font-weight: 600; color: var(--s600); text-align: center; }
.tab-tile.active .tab-tile-label { color: var(--navy); }
.flex-1 { flex: 1; }
.shrink-0 { flex-shrink: 0; }
.flex-wrap { flex-wrap: wrap; }

/* Tabs */
.tabs { display: flex; gap: .15rem; border-bottom: 2px solid var(--s100); margin-bottom: 1.1rem; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: thin; }
.tab { padding: .5rem .9rem; font-size: .82rem; font-weight: 500; cursor: pointer; border: none; background: none; color: var(--s400); border-bottom: 2px solid transparent; margin-bottom: -2px; transition: all .15s; font-family: inherit; white-space: nowrap; flex-shrink: 0; }
.tab:hover { color: var(--navy); }
.tab.active { color: var(--navy); border-bottom-color: var(--navy); }

/* Stat cards */
.stat-card .stat-number { font-family: 'Poppins', sans-serif; font-size: 1.9rem; font-weight: 600; color: var(--navy); }
.stat-card .stat-label { font-size: .73rem; color: var(--s400); margin-top: .1rem; }
.stat-card .stat-icon { margin-bottom: .35rem; }

/* Expandable row */
.expand-btn { width: 100%; background: none; border: none; cursor: pointer; padding: .9rem 1.1rem; display: flex; align-items: center; justify-content: space-between; text-align: left; transition: background .12s; font-family: inherit; }
.expand-btn:hover { background: var(--s100); }
.expand-body { border-top: 1px solid var(--s100); padding: 1.1rem; }

/* Modal */
.modal-backdrop { position: fixed; inset: 0; background: rgba(15,39,68,.45); backdrop-filter: blur(3px); z-index: 200; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.modal { background: var(--white); border-radius: var(--r-xl); box-shadow: var(--sh-lg); width: 100%; max-width: 540px; max-height: 90vh; overflow-y: auto; }
.modal-lg { max-width: 680px; }
.modal-header { padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--s100); display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.modal-header h2 { font-size: 1.05rem; }
.modal-body { padding: 1.25rem 1.5rem; }
.modal-footer { padding: 1rem 1.5rem; border-top: 1px solid var(--s100); display: flex; justify-content: flex-end; gap: .65rem; }

/* Alert banner */
.alert-banner { border-radius: var(--r-md); padding: .9rem 1.1rem; display: flex; align-items: flex-start; gap: .75rem; }
@keyframes bannerPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(217,119,6,.15); } 50% { box-shadow: 0 0 0 6px rgba(217,119,6,.08); } }
.alert-amber { background: var(--amber-pale); border: 1.5px solid #fcd34d; }
.alert-navy  { background: var(--navy); }

/* Toast */
.toast { position: fixed; bottom: 1.25rem; right: 1.25rem; color: var(--white); padding: .7rem 1.1rem; border-radius: var(--r-md); font-size: .85rem; font-weight: 500; z-index: 999; box-shadow: var(--sh-md); animation: slideIn .2s ease; }
.toast-success { background: var(--green); }
.toast-error   { background: var(--red); }
@keyframes slideIn { from { transform: translateY(10px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* Empty state */
.empty-state { text-align: center; padding: 3rem 1.5rem; }
.empty-state svg { color: var(--s200); margin: 0 auto .85rem; display: block; }
.empty-state .empty-title { font-weight: 500; color: var(--s600); margin-bottom: .3rem; }

/* Chip */
.chip { display: inline-flex; align-items: center; padding: .18rem .6rem; background: var(--s100); border-radius: 100px; font-size: .7rem; font-weight: 500; color: var(--s600); }

/* Search */
.search-wrap { position: relative; }
.search-wrap svg { position: absolute; left: .7rem; top: 50%; transform: translateY(-50%); color: var(--s400); pointer-events: none; }
.search-wrap .input { padding-left: 2.1rem; }

/* Spinner */
.spinner { width: 2rem; height: 2rem; border-radius: 50%; border: 3px solid var(--s200); border-top-color: var(--navy); animation: spin .7s linear infinite; }
.spinner-sm { width: .9rem; height: .9rem; border-radius: 50%; border: 2px solid var(--s200); border-top-color: var(--navy); animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.center { display: flex; align-items: center; justify-content: center; min-height: 60vh; }

/* Text utils */
.text-muted { color: var(--s400); font-size: .82rem; }
.text-sm { font-size: .85rem; }
.text-xs { font-size: .75rem; }
.font-600 { font-weight: 600; }
.mt-1 { margin-top: .25rem; }
.mt-2 { margin-top: .5rem; }
.mt-3 { margin-top: .75rem; }
.mt-4 { margin-top: 1rem; }
.mb-2 { margin-bottom: .5rem; }
.mb-3 { margin-bottom: .75rem; }
.mb-4 { margin-bottom: 1rem; }

/* Mobile header */
.mobile-header { display: none; align-items: center; justify-content: space-between; padding: 1rem 1.25rem; background: var(--white); border-bottom: 1px solid var(--s100); position: sticky; top: 0; z-index: 50; }
.sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 99; }

@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: none; }
  .sidebar-overlay.open { display: block; }
  .main-content { margin-left: 0; }
  .mobile-header { display: flex; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .page, .page-wide { padding: 1rem; }
  .hide-mobile { display: none !important; }
  /* The sidebar itself no longer scrolls as one unit — instead, only the nav
     list scrolls internally if it's too tall for the screen, while the logo
     header and the footer (account name + sign-out) stay permanently pinned
     and visible without ever needing to scroll to reach them. The actual
     height/overflow fix now lives in the base .sidebar/.sidebar-nav rules
     above (the real bug was min-height:100vh conflicting with position:fixed
     anchored to both top and bottom, which could make the sidebar taller than
     the viewport on ANY screen size, not just mobile) — this block now only
     needs the tighter spacing that's specific to small screens. */
  .sidebar-logo { padding: .85rem 1rem; }
  .sidebar-nav { padding: .5rem .6rem; gap: .1rem; }
  .nav-item { padding: .48rem .8rem; font-size: .8rem; }
  .nav-section-label { padding: .4rem .8rem .15rem; }
  .sidebar-footer { padding: .4rem; }
  .sidebar-user { padding: .35rem .8rem; margin-bottom: .2rem; }
}

/* Required info list */
.req-item { display: flex; align-items: center; gap: .6rem; padding: .5rem .75rem; background: var(--s100); border-radius: var(--r-sm); }
.req-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--amber); flex-shrink: 0; }

/* Portal type toggle (login page) */
.portal-toggle { display: flex; background: var(--s100); border-radius: var(--r-md); padding: .25rem; margin-bottom: 1.75rem; gap: .25rem; }
.portal-toggle-btn { flex: 1; padding: .5rem 1rem; border-radius: calc(var(--r-md) - .25rem); border: none; background: none; cursor: pointer; font-family: inherit; font-size: .85rem; font-weight: 600; color: var(--s400); transition: all .15s; }
.portal-toggle-btn[data-portal="client"].active { background: var(--navy); color: #fff; box-shadow: var(--sh-sm); }
.portal-toggle-btn[data-portal="employee"].active { background: var(--white); color: var(--navy); box-shadow: var(--sh-sm); }

/* Hover-action cards (dashboard boxes, list rows) — lift + reveal "View" on hover */
.hover-card { position: relative; transition: transform .18s, box-shadow .18s; }
.hover-card:hover { transform: translateY(-3px); box-shadow: var(--sh-md); }
.hover-view-tag { position: absolute; top: .7rem; right: .7rem; font-size: .7rem; font-weight: 700; color: var(--navy); background: var(--green-tint); padding: .2rem .6rem; border-radius: var(--r-pill); opacity: 0; transform: translateX(4px); transition: opacity .18s, transform .18s; }
.hover-card:hover .hover-view-tag { opacity: 1; transform: translateX(0); }
.hover-row { transition: background .15s, transform .15s; }
.hover-row:hover { background: var(--s100); transform: translateX(2px); }
.hover-row:hover .hover-row-arrow { color: var(--navy); transform: translateX(2px); }
.hover-row-arrow { transition: color .15s, transform .15s; }
.member-row { transition: background .15s; }
.member-row:hover { background: var(--s100); }
.member-row-view { opacity: 0; transform: translateX(-4px); transition: opacity .15s, transform .15s; margin-left: .3rem; }
.member-row:hover .member-row-view { opacity: 1; transform: translateX(0); }

/* Collapsible sections */
.collapsible-header { display: flex; align-items: center; justify-content: space-between; cursor: pointer; user-select: none; padding: .15rem 0; }
.collapsible-chevron { transition: transform .2s; color: var(--s400); flex-shrink: 0; }
.collapsible-header.open .collapsible-chevron { transform: rotate(180deg); }
.collapsible-body { overflow: hidden; max-height: 0; transition: max-height .25s ease; }
.collapsible-body.open { max-height: 2000px; }

/* Divider */
.divider { height: 1px; background: var(--s100); margin: 1rem 0; }

/* ── Progress bar (application steps / case status) ── */
.progress-track { display: flex; align-items: flex-start; margin-bottom: 2rem; overflow-x: auto; padding: .4rem .25rem .25rem; }
.progress-step-wrap { display: flex; flex-direction: column; align-items: center; flex: 1; min-width: 70px; position: relative; }
.progress-dot { width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .78rem; font-weight: 600; border: 2px solid var(--s200); color: var(--s400); background: var(--white); z-index: 2; transition: background .3s, border-color .3s, color .3s, box-shadow .3s; }
.progress-dot.done { background: var(--green); border-color: var(--green); color: var(--white); animation: wizard-pop .3s ease; }
.progress-dot.active { border-color: var(--navy); color: var(--navy); background: var(--white); box-shadow: 0 0 0 3px rgba(48,86,150,.12); animation: progress-pulse 2s ease-in-out infinite; }
.progress-dot.denied { background: var(--red); border-color: var(--red); color: var(--white); animation: wizard-pop .3s ease; }
.progress-line { position: absolute; top: 15px; left: 50%; right: -50%; height: 2px; background: var(--s200); z-index: 1; }
.progress-line.done { background: var(--green); transition: background .4s; }
@keyframes progress-pulse { 0%, 100% { box-shadow: 0 0 0 3px rgba(48,86,150,.12); } 50% { box-shadow: 0 0 0 6px rgba(48,86,150,.06); } }
.progress-label { font-size: .68rem; color: var(--s400); margin-top: .5rem; text-align: center; max-width: 85px; }
.progress-label.active { color: var(--navy); font-weight: 600; }
.progress-label.done { color: var(--green); }

/* ── Multi-step form wizard ── */
.wizard-steps { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: .35rem 0; margin-bottom: 2rem; width: 100%; }
@media (min-width: 700px) { .wizard-steps { flex-wrap: nowrap; } }
.wizard-step { display: flex; align-items: center; flex-shrink: 0; cursor: pointer; }
.wizard-step:hover .wizard-circle:not(.active) { border-color: var(--navy-light); }
.wizard-circle { width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .72rem; font-weight: 600; border: 2px solid var(--s200); color: var(--s400); background: var(--white); transition: background .25s, border-color .25s, color .25s, transform .25s; }
.wizard-circle svg { display: block; }
.wizard-circle.done { background: var(--navy); border-color: var(--navy); color: var(--white); animation: wizard-pop .3s ease; }
.wizard-circle.active { border-color: var(--navy); color: var(--navy); box-shadow: 0 0 0 4px rgba(48,86,150,.12); }
@keyframes wizard-pop { 0% { transform: scale(.7); } 60% { transform: scale(1.12); } 100% { transform: scale(1); } }
@keyframes pageFadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.page, .page-wide, .page-narrow { animation: pageFadeIn .35s ease both; }
@keyframes rowIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
@keyframes confettiFall { 0% { transform: translateY(0) translateX(0) rotate(0deg); opacity: .9; } 100% { transform: translateY(105vh) translateX(var(--drift)) rotate(560deg); opacity: 0; } }
.row-anim { animation: rowIn .35s ease both; }
.wizard-label { font-size: .72rem; font-weight: 500; margin-left: .45rem; white-space: nowrap; color: var(--s400); }
.wizard-label.active { color: var(--navy); font-weight: 600; }
.wizard-label.done { color: var(--s600); }
.wizard-connector { flex: 1 1 2rem; min-width: 1.25rem; max-width: 4.5rem; height: 2px; background: var(--s200); margin: 0 .4rem; transition: background .35s; }
.wizard-connector.done { background: var(--navy); }

/* Mobile wizard indicator — one big animated step circle instead of the full row,
   which gets cramped on narrow screens. Hidden on desktop via show-mobile below. */
.wizard-mobile { display: none; align-items: center; gap: .85rem; margin-bottom: 1.5rem; }
.wizard-mobile-circle { width: 48px; height: 48px; border-radius: 50%; background: var(--navy); color: #fff; display: flex; align-items: center; justify-content: center; font-family: 'Poppins', sans-serif; font-size: 1.1rem; font-weight: 700; flex-shrink: 0; animation: wizardMobilePop .35s ease; }
@keyframes wizardMobilePop { from { transform: scale(.7); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.wizard-mobile-label { font-weight: 700; font-size: .92rem; color: var(--navy); margin-bottom: .1rem; }
.wizard-mobile-sub { font-size: .78rem; color: var(--s400); }
.show-mobile { display: none; }
@media (max-width: 768px) {
  .show-mobile { display: flex; }
}

/* ── SSN reveal input ── */
.ssn-reveal-wrap { position: relative; }
.ssn-reveal-btn { position: absolute; right: .65rem; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--s400); display: flex; padding: .25rem; }

/* ── Permission grid (Team & Roles) ── */
.perm-row { display: flex; align-items: center; justify-content: space-between; padding: .75rem 0; border-bottom: 1px solid var(--s100); gap: 1rem; }
.perm-row:last-child { border-bottom: none; }
.perm-label { font-size: .85rem; color: var(--s800); }
.toggle-switch { position: relative; width: 42px; height: 24px; flex-shrink: 0; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider { position: absolute; cursor: pointer; inset: 0; background: var(--s200); border-radius: 100px; transition: background .2s; }
.toggle-slider::before { content: ''; position: absolute; width: 18px; height: 18px; left: 3px; bottom: 3px; background: var(--white); border-radius: 50%; transition: transform .2s; box-shadow: 0 1px 2px rgba(0,0,0,.15); }
.toggle-switch input:checked + .toggle-slider { background: var(--green); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(18px); }
.toggle-switch input:disabled + .toggle-slider { opacity: .5; cursor: not-allowed; }

/* ── File upload ── */
.file-drop-zone { border: 2px dashed var(--s200); border-radius: var(--r-md); padding: 1.5rem; text-align: center; cursor: pointer; transition: all .15s; }
.file-drop-zone:hover, .file-drop-zone.drag-over { border-color: var(--navy-light); background: var(--blue-pale); }
.file-row { display: flex; align-items: center; gap: .65rem; padding: .65rem .85rem; background: var(--s100); border-radius: var(--r-sm); }
.file-status-pending  { color: var(--amber); }
.file-status-accepted { color: var(--green); }
.file-status-declined { color: var(--red); }

/* ── Work summary stat tiles ── */
.work-stat { text-align: center; padding: 1rem; background: var(--s100); border-radius: var(--r-md); }
.work-stat-num { font-family: 'Poppins', sans-serif; font-size: 1.5rem; font-weight: 600; color: var(--navy); }
.work-stat-lbl { font-size: .7rem; color: var(--s400); margin-top: .2rem; }

/* ── FAQ accordion ── */
.faq-item { border-bottom: 1px solid var(--s100); }
.faq-item:last-child { border-bottom: none; }
.faq-q { width: 100%; text-align: left; background: none; border: none; cursor: pointer; padding: .9rem 0; display: flex; justify-content: space-between; align-items: center; font-size: .88rem; font-weight: 500; color: var(--s800); font-family: inherit; }
.faq-a { padding: 0 0 .9rem; font-size: .85rem; color: var(--s600); line-height: 1.65; }

/* ── Pill checkbox (required items list) ── */
.check-row { display: flex; align-items: center; gap: .65rem; padding: .6rem .8rem; border-radius: var(--r-sm); cursor: pointer; transition: background .12s; }
.check-row:hover { background: var(--s100); }
.check-row input[type="checkbox"] { width: 17px; height: 17px; accent-color: var(--navy); cursor: pointer; }
