/* Shared mobile and touch foundations for every Infinity screen. */

:where(button, [role="button"], a, input, select, textarea) {
  -webkit-tap-highlight-color: rgba(28, 42, 87, 0.14);
}

:where(button, [role="button"], a, input, select, textarea):focus-visible {
  outline: 3px solid rgba(44, 103, 242, 0.58);
  outline-offset: 2px;
}

:where(.table-wrap, .table-inner, .modal-table-wrap, .detail-body, .course-modal-body,
  .modal-body, .aa-cover-preview-body, .report-scroll, .timeline-list, .updates-list) {
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}

.mobile-scroll-hint,
.table-header-info {
  display: none;
}

.courses-filters-toggle {
  display: none;
}

.courses-filter-panel {
  display: contents;
}

.updates-filters-toggle {
  display: none;
}

.updates-filter-panel {
  display: contents;
}

.dashboard-table-views {
  display: none;
}

@media (pointer: coarse), (max-width: 900px) {
  :where(button, [role="button"], input:not([type="checkbox"]):not([type="radio"]), select,
    textarea, .btn, .w-button, .nav-link, .logout-button) {
    min-height: 44px;
    touch-action: manipulation;
  }

  :where(input, select, textarea) {
    font-size: 16px;
  }

  :where(.table-wrap, .table-inner, .modal-table-wrap, .aa-cover-preview-body, .report-scroll) {
    touch-action: pan-x pan-y;
  }

  :where(.modal-close, .course-modal-close, .detail-close, [data-id="close-modal"]) {
    align-items: center;
    display: inline-flex;
    height: 44px;
    justify-content: center;
    min-width: 44px;
  }

  .config-cog-btn {
    min-width: 44px;
  }

  .advanced-filters-toggle {
    min-height: 44px;
  }

  .table-header-info {
    align-items: center;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.34);
    border-radius: 999px;
    color: inherit;
    cursor: pointer;
    display: inline-flex;
    flex: 0 0 44px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 800;
    height: 44px;
    justify-content: center;
    line-height: 1;
    margin: -8px -6px -8px 4px;
    padding: 0;
    vertical-align: middle;
    width: 44px;
  }

  :where(.type-history-link, .student-link, .course-link, .timeline-link) {
    align-items: center;
    display: inline-flex;
    min-height: 44px;
  }
}

@media (max-width: 900px) {
  html {
    height: 100%;
    text-size-adjust: 100%;
  }

  body {
    min-height: 100%;
    min-height: 100dvh;
  }

  :where(.app, .workbench-shell) {
    min-height: 100dvh;
  }

  :where(.content, .main-content, .workspace-content) {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  :where(.table-wrap, .table-inner, .modal-table-wrap, .aa-cover-preview-body, .report-scroll) {
    scrollbar-color: rgba(28, 42, 87, 0.48) rgba(28, 42, 87, 0.08);
    scrollbar-width: thin;
  }

  :where(.table-wrap, .table-inner, .modal-table-wrap, .aa-cover-preview-body, .report-scroll)::-webkit-scrollbar {
    height: 10px;
    width: 10px;
  }

  :where(.table-wrap, .table-inner, .modal-table-wrap, .aa-cover-preview-body, .report-scroll)::-webkit-scrollbar-thumb {
    background: rgba(28, 42, 87, 0.42);
    border: 2px solid transparent;
    border-radius: 999px;
    background-clip: padding-box;
  }

  :where(.table-wrap, .table-inner, .modal-table-wrap, .aa-cover-preview-body, .report-scroll)::-webkit-scrollbar-track {
    background: rgba(28, 42, 87, 0.07);
  }

  .table-inner {
    scrollbar-width: thin;
  }

  .table-inner::-webkit-scrollbar {
    height: 10px;
  }

  .mobile-scroll-hint {
    align-items: center;
    color: #4b5c73;
    display: flex;
    flex: 0 0 auto;
    font-size: 12px;
    font-weight: 700;
    gap: 7px;
    line-height: 1.35;
    margin: 0;
    padding: 2px 2px 0;
  }

  .mobile-scroll-hint span {
    align-items: center;
    background: rgba(28, 42, 87, 0.1);
    border-radius: 999px;
    color: #1c2a57;
    display: inline-flex;
    flex: 0 0 28px;
    height: 28px;
    justify-content: center;
  }

  .dashboard-page .summary,
  .mccc-dashboard-page .summary {
    display: grid;
    grid-auto-columns: minmax(150px, 44vw);
    grid-auto-flow: column;
    grid-template-columns: none;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    padding: 2px 2px 6px;
    scroll-snap-type: inline proximity;
    scrollbar-width: thin;
    touch-action: pan-x;
  }

  .dashboard-page .summary > *,
  .mccc-dashboard-page .summary > * {
    min-height: 64px;
    scroll-snap-align: start;
  }

  .mccc-dashboard-page .content {
    gap: 8px;
    padding: 8px;
  }

  .mccc-dashboard-page .toolbar {
    align-items: stretch;
    display: grid;
    flex: 0 0 auto;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 6px;
    position: relative;
  }

  .mccc-dashboard-page .mccc-search-field label {
    border: 0;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    white-space: nowrap;
    width: 1px;
  }

  .mccc-dashboard-page .mccc-search-field input {
    height: 44px;
    padding-left: 14px;
  }

  .mccc-dashboard-page .mccc-filter-toggle {
    align-items: center;
    display: inline-flex;
    gap: 6px;
    height: 44px;
    justify-content: center;
    padding: 0 12px;
  }

  .mccc-dashboard-page .mccc-filter-count {
    align-items: center;
    background: #1c2a57;
    border-radius: 999px;
    color: #ffffff;
    display: inline-flex;
    font-size: 11px;
    height: 20px;
    justify-content: center;
    min-width: 20px;
    padding: 0 6px;
  }

  .mccc-dashboard-page .mccc-filter-count[hidden] {
    display: none;
  }

  .mccc-dashboard-page .mccc-filter-panel {
    background: #ffffff;
    border: 1px solid #cfd8e8;
    border-radius: 12px;
    box-shadow: 0 18px 42px rgba(28, 42, 87, 0.22);
    display: none;
    gap: 10px;
    grid-column: 1 / -1;
    grid-template-columns: 1fr;
    left: 0;
    padding: 12px;
    position: absolute;
    right: 0;
    top: 50px;
    z-index: 30;
  }

  .mccc-dashboard-page .mccc-filter-panel[data-mobile-open="true"] {
    display: grid;
  }

  .mccc-dashboard-page .mccc-refresh-btn {
    align-items: center;
    display: inline-flex;
    height: 44px;
    justify-content: center;
    min-width: 44px;
    padding: 0;
  }

  .mccc-dashboard-page .refresh-icon {
    display: inline;
    font-size: 22px;
    line-height: 1;
  }

  .mccc-dashboard-page .refresh-label {
    border: 0;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    white-space: nowrap;
    width: 1px;
  }

  .mccc-dashboard-page .summary {
    gap: 6px;
    grid-auto-columns: minmax(110px, 31vw);
    padding: 0 0 2px;
  }

  .mccc-dashboard-page .summary > * {
    min-height: 54px;
  }

  .mccc-dashboard-page .summary-card {
    border-radius: 10px;
    box-shadow: none;
    padding: 8px 10px;
  }

  .mccc-dashboard-page .summary-card p {
    font-size: 10px;
    line-height: 1.15;
  }

  .mccc-dashboard-page .summary-card strong {
    font-size: 19px;
    margin-top: 3px;
  }

  .mccc-dashboard-page .mccc-table-tools {
    display: block;
    flex: 0 0 auto;
    min-height: 38px;
    overflow: hidden;
  }

  .mccc-dashboard-page .mccc-table-views {
    display: flex;
    gap: 4px;
    overflow-x: auto;
    padding: 0 0 4px;
    scrollbar-width: none;
  }

  .mccc-dashboard-page .mccc-table-views::-webkit-scrollbar {
    display: none;
  }

  .mccc-dashboard-page .mccc-table-views button {
    background: #ffffff;
    border: 1px solid #d7deea;
    border-radius: 999px;
    color: #52627a;
    flex: 0 0 auto;
    font: 700 11px/1 "Roboto", "Segoe UI", sans-serif;
    min-height: 36px;
    padding: 0 12px;
  }

  .mccc-dashboard-page .mccc-table-views button[aria-selected="true"] {
    background: #1c2a57;
    border-color: #1c2a57;
    color: #ffffff;
  }

  .mccc-dashboard-page .mccc-table-tools .mobile-scroll-hint {
    display: none;
  }

  .mccc-dashboard-page .table-wrap {
    border-radius: 10px;
    box-shadow: 0 8px 22px rgba(28, 42, 87, 0.12);
    min-height: 180px;
  }

  .mccc-dashboard-page #studentTable {
    min-width: 100%;
    table-layout: auto;
    width: max-content;
  }

  .mccc-dashboard-page #studentTable .table-group-row {
    display: none;
  }

  .mccc-dashboard-page #studentTable thead tr:not(.table-group-row) th {
    top: 0;
  }

  .mccc-dashboard-page #studentTable :is(th, td)[data-mobile-view] {
    display: none;
  }

  .mccc-dashboard-page #studentTable :is(th, td)[data-mobile-view="identity"],
  .mccc-dashboard-page #studentTable[data-mobile-view="overview"] :is(th, td)[data-mobile-view="overview"],
  .mccc-dashboard-page #studentTable[data-mobile-view="courses"] :is(th, td)[data-mobile-view="courses"],
  .mccc-dashboard-page #studentTable[data-mobile-view="pace"] :is(th, td)[data-mobile-view="pace"],
  .mccc-dashboard-page #studentTable[data-mobile-view="time"] :is(th, td)[data-mobile-view="time"],
  .mccc-dashboard-page #studentTable[data-mobile-view="reservations"] :is(th, td)[data-mobile-view="reservations"] {
    display: table-cell;
  }

  .mccc-dashboard-page #studentTable th,
  .mccc-dashboard-page #studentTable td {
    border-bottom-color: #cbd4e3;
    border-right: 1px solid #cbd4e3;
    min-width: 112px;
    padding: 9px 10px;
  }

  .mccc-dashboard-page #studentTable th {
    font-size: 11px;
    line-height: 1.2;
  }

  .mccc-dashboard-page #studentTable td {
    font-size: 12px;
  }

  .mccc-dashboard-page #studentTable .sticky-col {
    max-width: 144px;
    min-width: 144px;
    width: 144px;
  }

  .mccc-dashboard-page #studentTable tbody tr:nth-child(even) {
    background: #f2f5fa;
  }

  .mccc-dashboard-page #studentTable .num,
  .mccc-dashboard-page #studentTable .time-cell,
  .mccc-dashboard-page #studentTable .reservation-cell {
    font-variant-numeric: tabular-nums;
    text-align: right;
  }

  .mccc-dashboard-page .footer-row {
    flex: 0 0 auto;
    min-height: 16px;
  }

  .dashboard-page .page {
    gap: 8px;
    padding: 8px;
  }

  .dashboard-page .filters,
  .dashboard-page .filters.is-expanded {
    align-items: stretch;
    background: transparent;
    border: 0;
    display: grid;
    flex: 0 0 auto;
    gap: 6px;
    grid-template-columns: 44px minmax(0, 1fr) minmax(0, 1fr);
    margin: 0;
    padding: 0;
    position: relative;
  }

  .dashboard-page .filter-search {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .dashboard-page .filter-search > label,
  .dashboard-page .filter-columns > label {
    border: 0;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    white-space: nowrap;
    width: 1px;
  }

  .dashboard-page .search-wrap,
  .dashboard-page .search-wrap input,
  .dashboard-page .reset-btn,
  .dashboard-page .column-select-button,
  .dashboard-page .advanced-filters-toggle {
    min-height: 44px;
  }

  .dashboard-page .config-cog-btn {
    grid-column: 1;
    grid-row: 2;
    height: 44px;
    left: auto;
    position: static;
    top: auto;
    width: 44px;
  }

  .dashboard-page .filter-columns {
    grid-column: 2;
    grid-row: 2;
  }

  .dashboard-page .filter-toggle-control {
    grid-column: 3;
    grid-row: 2;
  }

  .dashboard-page .column-select-button,
  .dashboard-page .advanced-filters-toggle {
    height: 44px;
    padding: 0 10px;
    text-align: center;
  }

  .dashboard-page .filters.is-expanded .filter-search {
    grid-column: 1 / -1;
  }

  .dashboard-page .filter-advanced-group,
  .dashboard-page .filters:not(.is-expanded) .filter-advanced-group {
    display: none;
  }

  .dashboard-page .filters.is-expanded .filter-advanced-group {
    background: #ffffff;
    border: 1px solid #cfd8e8;
    border-radius: 12px;
    box-shadow: 0 18px 42px rgba(28, 42, 87, 0.22);
    display: grid;
    gap: 10px;
    grid-column: 1 / -1;
    grid-template-columns: 1fr;
    left: 0;
    max-height: calc(100dvh - 116px);
    overflow: auto;
    padding: 12px;
    position: absolute;
    right: 0;
    top: 100px;
    z-index: 30;
  }

  .dashboard-page .type-select-panel,
  .dashboard-page .column-select-panel {
    max-width: calc(100vw - 16px);
    position: fixed;
    top: 108px;
    width: min(360px, calc(100vw - 16px));
  }

  .dashboard-page .type-select-panel {
    left: 8px;
    right: 8px;
  }

  .dashboard-page .column-select-panel {
    left: auto;
    right: 8px;
  }

  .dashboard-page .summary {
    gap: 6px;
    grid-auto-columns: minmax(106px, 29vw);
    margin: 0;
    padding: 0 0 2px;
  }

  .dashboard-page .summary > * {
    min-height: 54px;
  }

  .dashboard-page .summary .card {
    border-radius: 10px;
    box-shadow: none;
    padding: 7px 9px;
  }

  .dashboard-page .summary .card p {
    font-size: 10px;
    line-height: 1.15;
  }

  .dashboard-page .summary .card h3 {
    font-size: 19px;
  }

  .dashboard-page .dashboard-table-tools {
    display: grid;
    flex: 0 0 auto;
    gap: 5px;
    min-width: 0;
  }

  .dashboard-page .section-title {
    font-size: 13px;
    line-height: 1.2;
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .dashboard-page .dashboard-table-views {
    display: flex;
    gap: 4px;
    overflow-x: auto;
    padding: 0 0 3px;
    scrollbar-width: none;
  }

  .dashboard-page .dashboard-table-views::-webkit-scrollbar {
    display: none;
  }

  .dashboard-page .dashboard-table-views button {
    background: #ffffff;
    border: 1px solid #d7deea;
    border-radius: 999px;
    color: #52627a;
    flex: 0 0 auto;
    font: 700 11px/1 "Roboto", "Segoe UI", sans-serif;
    min-height: 36px;
    padding: 0 12px;
  }

  .dashboard-page .dashboard-table-views button[aria-selected="true"] {
    background: #1c2a57;
    border-color: #1c2a57;
    color: #ffffff;
  }

  .dashboard-page .dashboard-table-tools .mobile-scroll-hint {
    display: none;
  }

  .dashboard-page .table-wrap {
    border-radius: 10px;
    margin: 0;
    min-height: 180px;
  }

  .dashboard-page #studentDashboardTable {
    min-width: 100%;
    table-layout: auto;
    width: max-content;
  }

  .dashboard-page #studentDashboardTable colgroup {
    display: none;
  }

  .dashboard-page #studentDashboardTable :is(th, td)[class*="col-"]:not(.col-student_name),
  .dashboard-page #groundReservationsHeader,
  .dashboard-page #flightReservationsHeader,
  .dashboard-page #simReservationsHeader,
  .dashboard-page #reservationSubheadRow {
    display: none;
  }

  .dashboard-page #studentDashboardTable :is(th, td).col-student_name,
  .dashboard-page #studentDashboardTable[data-mobile-view="overview"] :is(th, td):is(.col-student_type, .col-enrolled_courses, .col-primary_instructor, .col-completed_attempted, .col-last7_completed),
  .dashboard-page #studentDashboardTable[data-mobile-view="pace"] :is(th, td):is(.col-scl_target, .col-strike_rate, .col-total_enrolled, .col-timeline_delta, .col-days_off_delivery, .col-expected_timeline, .col-timeline_extension, .col-est_completion),
  .dashboard-page #studentDashboardTable[data-mobile-view="time"] :is(th, td):is(.col-flight_time, .col-ground_time, .col-sim_time, .col-remedial_used, .col-remedial_purchased),
  .dashboard-page #studentDashboardTable[data-mobile-view="reservations"] :is(th, td):is(.col-ground_res_7, .col-ground_res_14, .col-flight_res_7, .col-flight_res_14, .col-sim_res_7, .col-sim_res_14),
  .dashboard-page #studentDashboardTable[data-mobile-view="support"] :is(th, td):is(.col-days_off, .col-remaining_days_off, .col-location, .col-unsats) {
    display: table-cell;
  }

  .dashboard-page #studentDashboardTable[data-mobile-view="reservations"] :is(#groundReservationsHeader, #flightReservationsHeader, #simReservationsHeader) {
    display: table-cell;
  }

  .dashboard-page #studentDashboardTable[data-mobile-view="reservations"] #reservationSubheadRow {
    display: table-row;
  }

  .dashboard-page #studentDashboardTable th,
  .dashboard-page #studentDashboardTable td {
    border-bottom-color: #cbd4e3;
    border-right: 1px solid #cbd4e3;
    min-width: 112px;
    padding: 9px 10px;
  }

  .dashboard-page #studentDashboardTable .col-student_name {
    max-width: 154px;
    min-width: 154px;
    overflow-wrap: anywhere;
    white-space: normal;
    width: 154px;
  }

  .dashboard-page #studentDashboardTable th[data-tooltip] {
    padding-right: 36px;
  }

  .dashboard-page .table-header-info {
    background: #ffffff;
    border: 1px solid #9aa8bd;
    color: #1c2a57;
    flex: none;
    font-size: 11px;
    height: 20px;
    margin: 0;
    min-height: 20px;
    min-width: 20px;
    position: absolute;
    right: 7px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
  }

  .dashboard-page .table-header-info::after {
    content: "";
    inset: -12px;
    position: absolute;
  }

  .dashboard-page #studentDashboardTable .num-col,
  .dashboard-page #studentDashboardTable .res-col {
    font-variant-numeric: tabular-nums;
    text-align: right;
  }

  .dashboard-page .table-scrollbar {
    display: none;
  }

  .aa-report-page .aa-report-table th[data-tooltip] {
    padding-right: 36px;
    white-space: normal;
  }

  .aa-report-page .aa-report-table .sort-label {
    display: block;
    white-space: normal;
  }

  .aa-report-page .table-header-info {
    background: #ffffff;
    border: 1px solid #9aa8bd;
    color: #1c2a57;
    flex: none;
    font-size: 11px;
    height: 20px;
    margin: 0;
    min-height: 20px;
    min-width: 20px;
    position: absolute;
    right: 7px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
  }

  .aa-report-page .table-header-info::after {
    content: "";
    inset: -12px;
    position: absolute;
  }

  .timeline-page .content,
  .mccc-timeline-page .content {
    gap: 8px;
    padding-bottom: max(8px, env(safe-area-inset-bottom));
    padding-top: 8px;
  }

  .timeline-page .toolbar,
  .mccc-timeline-page .toolbar {
    align-items: stretch;
    display: grid;
    gap: 8px;
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .timeline-page .toolbar .field,
  .mccc-timeline-page .toolbar .field {
    min-width: 0;
  }

  .timeline-page .toolbar .field label,
  .mccc-timeline-page .toolbar .field label {
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    height: 1px;
    overflow: hidden;
    position: absolute;
    white-space: nowrap;
    width: 1px;
  }

  .timeline-page .toolbar input,
  .mccc-timeline-page .toolbar input,
  .timeline-page .toolbar .btn,
  .mccc-timeline-page .toolbar .btn {
    height: 44px;
  }

  .timeline-page .summary-grid,
  .mccc-timeline-page .summary-grid,
  .updates-page .summary-grid {
    display: grid;
    grid-auto-columns: minmax(154px, 44vw);
    grid-auto-flow: column;
    grid-template-columns: none;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    padding: 2px 2px 6px;
    scroll-snap-type: inline proximity;
    scrollbar-width: thin;
    touch-action: pan-x;
  }

  .timeline-page .summary-grid > *,
  .mccc-timeline-page .summary-grid > *,
  .updates-page .summary-grid > * {
    min-height: 64px;
    scroll-snap-align: start;
  }

  .timeline-page .summary-grid,
  .mccc-timeline-page .summary-grid {
    gap: 6px;
    grid-auto-columns: minmax(142px, 39vw);
    padding: 0 0 4px;
  }

  .timeline-page .summary-grid > *,
  .mccc-timeline-page .summary-grid > * {
    min-height: 54px;
  }

  .timeline-page .summary-card,
  .mccc-timeline-page .summary-card {
    align-items: center;
    box-shadow: none;
    display: grid;
    gap: 4px;
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 7px 9px;
  }

  .timeline-page .summary-label,
  .mccc-timeline-page .summary-label {
    font-size: 10px;
    line-height: 1.15;
  }

  .timeline-page .summary-value,
  .mccc-timeline-page .summary-value {
    font-size: 19px;
    margin-top: 0;
  }

  .timeline-page .timeline-wrap,
  .mccc-timeline-page .timeline-wrap {
    border-radius: 10px;
    min-height: 200px;
  }

  .timeline-page .timeline-list,
  .mccc-timeline-page .timeline-list {
    padding: 12px 10px 12px 38px;
  }

  .timeline-page .timeline-list::before,
  .mccc-timeline-page .timeline-list::before {
    left: 17px;
  }

  .timeline-page .timeline-item::before,
  .mccc-timeline-page .timeline-item::before {
    left: -27px;
  }

  .updates-page .content {
    gap: 8px;
    padding-bottom: max(8px, env(safe-area-inset-bottom));
    padding-top: 8px;
  }

  .updates-page .intro-row {
    align-items: stretch;
    display: grid;
    gap: 5px;
    grid-template-columns: minmax(0, 1fr);
  }

  .updates-page .intro-copy h2 {
    font-size: 18px;
    line-height: 1.2;
  }

  .updates-page .intro-copy p {
    display: none;
  }

  .updates-page .summary-note {
    align-items: center;
    box-shadow: none;
    display: flex;
    gap: 7px;
    min-width: 0;
    padding: 6px 9px;
  }

  .updates-page .summary-note-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.035em;
    text-transform: uppercase;
  }

  .updates-page .summary-note-value {
    font-size: 12px;
    margin-top: 0;
  }

  .updates-page .toolbar {
    align-items: stretch;
    display: grid;
    gap: 8px;
    grid-template-columns: minmax(0, 1fr) auto;
    position: relative;
    z-index: 12;
  }

  .updates-page .toolbar .field.search {
    grid-column: auto;
    min-width: 0;
  }

  .updates-page .toolbar .field.search label {
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    height: 1px;
    overflow: hidden;
    position: absolute;
    white-space: nowrap;
    width: 1px;
  }

  .updates-page .toolbar .field.search input {
    height: 44px;
  }

  .updates-page .updates-filters-toggle {
    align-items: center;
    display: inline-flex;
    gap: 5px;
    grid-column: auto;
    justify-content: center;
  }

  .updates-page .filter-count {
    align-items: center;
    background: var(--accent, #1c2a57);
    border-radius: 999px;
    color: #ffffff;
    display: inline-flex;
    font-size: 10px;
    height: 18px;
    justify-content: center;
    min-width: 18px;
    padding: 0 5px;
  }

  .updates-page .filter-count[hidden] {
    display: none;
  }

  .updates-page .updates-filter-panel {
    background: #ffffff;
    border: 1px solid var(--line, #e2e7f0);
    border-radius: 12px;
    box-shadow: 0 18px 38px rgba(28, 42, 87, 0.18);
    display: none;
    gap: 10px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    left: 0;
    padding: 12px;
    position: absolute;
    right: 0;
    top: 52px;
  }

  .updates-page .updates-filter-panel.is-open {
    display: grid;
  }

  .updates-page .updates-filter-panel .field {
    min-width: 0;
  }

  .updates-page .updates-filter-panel select,
  .updates-page .updates-filter-panel .btn {
    height: 44px;
  }

  .updates-page .updates-filter-panel .btn {
    grid-column: 1 / -1;
  }

  .updates-page .summary-grid {
    gap: 6px;
    grid-auto-columns: minmax(116px, 31vw);
    padding: 0 0 4px;
  }

  .updates-page .summary-grid > * {
    min-height: 52px;
  }

  .updates-page .summary-card {
    align-items: center;
    box-shadow: none;
    display: grid;
    gap: 4px;
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 7px 9px;
  }

  .updates-page .summary-label {
    font-size: 10px;
    line-height: 1.15;
  }

  .updates-page .summary-value {
    font-size: 18px;
    margin-top: 0;
  }

  .updates-page .updates-wrap {
    border-radius: 10px;
    min-height: 180px;
  }

  .updates-page .updates-list {
    padding: 12px 10px 16px 38px;
  }

  .updates-page .updates-list::before {
    left: 17px;
  }

  .updates-page .month-heading {
    margin-left: -27px;
  }

  .updates-page .update-item::before {
    left: -27px;
  }

  .updates-page .update-card {
    padding: 11px;
  }

  .updates-page .update-details {
    border-top: 1px solid var(--line, #e2e7f0);
    margin-top: 10px;
    padding-top: 2px;
  }

  .updates-page .update-details summary {
    align-items: center;
    color: var(--accent, #1c2a57);
    cursor: pointer;
    display: flex;
    font-size: 12px;
    font-weight: 700;
    justify-content: space-between;
    list-style: none;
    min-height: 44px;
    touch-action: manipulation;
  }

  .updates-page .update-details summary::-webkit-details-marker {
    display: none;
  }

  .updates-page .update-details summary::after {
    content: "+";
    font-size: 20px;
    font-weight: 400;
  }

  .updates-page .update-details[open] summary::after {
    content: "−";
  }

  .updates-page .update-details .detail-list {
    margin-top: 4px;
  }

  .courses-page .table-wrap th:first-child,
  .courses-page .table-wrap td:first-child:not(.empty-state) {
    left: 0;
    max-width: 170px;
    min-width: 170px;
    position: sticky;
    white-space: normal;
    width: 170px;
  }

  .courses-page .table-wrap th:last-child,
  .courses-page .table-wrap td:last-child:not(.empty-state) {
    max-width: 86px;
    min-width: 86px;
    position: sticky;
    right: 0;
    width: 86px;
  }

  .courses-page .table-wrap th:first-child,
  .courses-page .table-wrap th:last-child {
    background: var(--accent, #1c2a57);
    z-index: 5;
  }

  .courses-page .table-wrap td:first-child:not(.empty-state),
  .courses-page .table-wrap td:last-child:not(.empty-state) {
    background: #ffffff;
    box-shadow: 5px 0 9px rgba(28, 42, 87, 0.08);
    z-index: 2;
  }

  .courses-page .table-wrap td:last-child:not(.empty-state) {
    box-shadow: -5px 0 9px rgba(28, 42, 87, 0.08);
  }

  .courses-page .table-wrap tbody tr:nth-child(even) td:first-child:not(.empty-state),
  .courses-page .table-wrap tbody tr:nth-child(even) td:last-child:not(.empty-state) {
    background: var(--panel-2, #f8faff);
  }

  .courses-page .actions-cell {
    display: table-cell;
  }

  .courses-page .content {
    gap: 8px;
    padding-bottom: max(8px, env(safe-area-inset-bottom));
    padding-top: 8px;
  }

  .courses-page .toolbar {
    align-items: stretch;
    display: grid;
    gap: 8px;
    grid-template-columns: minmax(0, 1fr) auto;
    position: relative;
    z-index: 12;
  }

  .courses-page .toolbar .field.search {
    grid-column: auto;
  }

  .courses-page .toolbar .field.search label {
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    height: 1px;
    overflow: hidden;
    position: absolute;
    white-space: nowrap;
    width: 1px;
  }

  .courses-page .toolbar .field.search input {
    height: 44px;
  }

  .courses-page .courses-filters-toggle {
    align-items: center;
    display: inline-flex;
    gap: 5px;
    justify-content: center;
  }

  .courses-page .filter-count {
    align-items: center;
    background: var(--accent, #1c2a57);
    border-radius: 999px;
    color: #ffffff;
    display: inline-flex;
    font-size: 10px;
    height: 18px;
    justify-content: center;
    min-width: 18px;
    padding: 0 5px;
  }

  .courses-page .filter-count[hidden] {
    display: none;
  }

  .courses-page .courses-filter-panel {
    background: #ffffff;
    border: 1px solid var(--line, #e2e7f0);
    border-radius: 12px;
    box-shadow: 0 18px 38px rgba(28, 42, 87, 0.18);
    display: none;
    gap: 10px;
    grid-template-columns: minmax(0, 1fr) auto;
    left: 0;
    padding: 12px;
    position: absolute;
    right: 0;
    top: 52px;
  }

  .courses-page .courses-filter-panel.is-open {
    display: grid;
  }

  .courses-page .courses-filter-panel .field {
    min-width: 0;
  }

  .courses-page .courses-filter-panel select,
  .courses-page .courses-filter-panel .btn {
    height: 44px;
  }

  .courses-page .footer-row {
    min-height: 18px;
  }

  .student-activity-page .email-report-table th:first-child,
  .student-activity-page .email-report-table td:first-child {
    left: 0;
    position: sticky;
  }

  .student-activity-page .email-report-table th:first-child {
    z-index: 4;
  }

  .student-activity-page .email-report-table td:first-child {
    background: #ffffff;
    box-shadow: 5px 0 9px rgba(28, 42, 87, 0.08);
    z-index: 2;
  }

  .student-activity-page .email-report-table tbody tr:nth-child(even) td:first-child {
    background: #f8faff;
  }

  .report-page .print-actions {
    flex-wrap: wrap;
  }

  .report-page .report-status {
    flex: 1 0 100%;
    margin: 0;
  }

  .report-page .print-actions button {
    flex: 1 1 120px;
  }

  .report-page .cover-sheet .editable-cell,
  .aa-report-page .aa-cover-preview-sheet [contenteditable="true"] {
    height: 44px;
  }

  :where(.course-modal, .detail-modal, .modal, .aa-cover-preview-overlay) {
    align-items: stretch;
    padding: max(8px, env(safe-area-inset-top)) max(8px, env(safe-area-inset-right))
      max(8px, env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left));
  }

  :where(.course-modal-card, .detail-card, .modal-card, .aa-cover-preview-dialog) {
    max-height: calc(100dvh - 16px);
    width: 100%;
  }

  .modal-card {
    display: flex;
    flex-direction: column;
  }

  .modal-card > form {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-height: 0;
  }

  .modal-card > form > .modal-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
  }

  .modal-card > form > .modal-footer {
    flex: 0 0 auto;
  }

  :where(.course-modal-header, .detail-header, .modal-header, .aa-cover-preview-header) {
    flex: 0 0 auto;
    padding: 12px;
  }

  :where(.course-modal-body, .detail-body, .modal-body, .aa-cover-preview-body) {
    min-height: 0;
    overflow: auto;
    padding: 12px;
  }

  :where(.modal-footer, .course-modal-footer) {
    padding: 12px;
    padding-bottom: max(12px, env(safe-area-inset-bottom));
  }

  .body-2 .div-block-388 {
    margin: 20px auto;
    max-width: calc(100% - 24px);
    padding: 24px 20px 28px;
    width: auto;
  }

  .body-2 .div-block-388-copy {
    margin: 20px auto;
    max-width: calc(100% - 24px);
    padding: 32px 20px;
    width: auto;
  }

  .body-2 .h2-coaefwfpy {
    font-size: clamp(24px, 7vw, 32px);
    line-height: 1.2;
    margin-left: auto;
    margin-right: auto;
    max-width: calc(100% - 32px);
  }

  .body-2 .inputfield.short,
  .body-2 .submitbutton.login {
    max-width: 100%;
    width: 100%;
  }

  .body-2 .textlink-2 {
    align-items: center;
    display: inline-flex;
    min-height: 44px;
    padding: 8px 0;
  }

  .body-2 .modalforgotpassword {
    padding: max(8px, env(safe-area-inset-top)) max(8px, env(safe-area-inset-right))
      max(8px, env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left));
  }

  .body-2 .modalcontent-5 {
    max-height: calc(100dvh - 16px);
    max-width: 100%;
    overflow: auto;
    padding-bottom: max(24px, env(safe-area-inset-bottom));
    width: 100%;
  }

  .body-2 .div-block-433 {
    max-width: calc(100% - 24px);
    padding: 14px 16px 20px;
    width: auto;
  }

  .body-2 .submit-button-holder-4 {
    padding-left: 20px;
    padding-right: 20px;
  }

  .body-2 .div-block-388-copy .submitbutton.login {
    max-width: 100%;
    width: 100%;
  }
}

@media (max-width: 900px) and (max-height: 700px) {
  .body-2 {
    overflow-y: auto;
  }

  .body-2 .div-block-3015 {
    min-height: 100dvh;
    position: static;
  }

  .body-2 .fcheader.dash {
    padding-bottom: 20px;
    padding-top: 14px;
  }

  .body-2 .image-20 {
    height: auto;
    width: 110px;
  }

  .body-2 .div-block-388 {
    margin: 12px auto;
    padding: 18px 20px 20px;
  }

  .body-2 .div-block-388-copy {
    margin: 12px auto;
    padding: 24px 20px;
  }

  .body-2 .h2-coaefwfpy {
    font-size: 22px;
    line-height: 1.2;
    margin: 12px auto 0;
  }

  .body-2 .h3 {
    font-size: 22px;
  }

  .body-2 .form-block-3 {
    margin-top: 14px;
  }

  .body-2 .form-3 {
    padding-bottom: 4px;
  }

  .body-2 .textlink-2 {
    padding-bottom: 4px;
    padding-top: 4px;
  }
}

@media (max-width: 640px) {
  .courses-page .mobile-scroll-hint {
    display: none;
  }

  .courses-page .mobile-card-table {
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    overflow-x: hidden;
    padding: 0 1px;
  }

  .courses-page .mobile-card-table table,
  .courses-page .mobile-card-table tbody {
    display: block;
    min-width: 0;
    width: 100%;
  }

  .courses-page .mobile-card-table thead {
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    height: 1px;
    overflow: hidden;
    position: absolute;
    white-space: nowrap;
    width: 1px;
  }

  .courses-page .mobile-card-table tbody {
    display: grid;
    gap: 8px;
  }

  .courses-page .mobile-card-table tbody tr {
    background: #ffffff;
    border: 1px solid #d7deea;
    border-left: 4px solid var(--accent, #1c2a57);
    border-radius: 12px;
    box-shadow: 0 5px 14px rgba(28, 42, 87, 0.08);
    display: grid;
    gap: 10px 8px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 12px;
    position: relative;
  }

  .courses-page .mobile-card-table tbody tr:nth-child(even) {
    background: #ffffff;
  }

  .courses-page .mobile-card-table tbody tr > td:not(.empty-state) {
    background: transparent;
    border: 0;
    box-shadow: none;
    display: flex;
    flex-direction: column;
    font-size: 13px;
    gap: 3px;
    max-width: none;
    min-width: 0;
    padding: 0;
    position: static;
    white-space: normal;
    width: auto;
  }

  .courses-page .mobile-card-table tbody td::before {
    color: var(--muted, #5b6b80);
    content: attr(data-label);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.045em;
    line-height: 1.2;
    text-transform: uppercase;
  }

  .courses-page .mobile-card-table tbody td:first-child:not(.empty-state) {
    color: var(--accent, #1c2a57);
    font-size: 14px;
    grid-column: 1 / -1;
    max-width: none;
    min-width: 0;
    padding-right: 64px;
    position: static;
    width: auto;
  }

  .courses-page .mobile-card-table tbody td:nth-child(5),
  .courses-page .mobile-card-table tbody td:nth-child(6),
  .courses-page .mobile-card-table tbody td:nth-child(7) {
    background: #f4f7fb;
    border-radius: 8px;
    font-variant-numeric: tabular-nums;
    padding: 8px;
  }

  .courses-page .mobile-card-table tbody tr > td.actions-cell:not(.empty-state) {
    display: block;
    max-width: none;
    min-width: 0;
    position: absolute;
    right: 10px;
    top: 10px;
    width: auto;
  }

  .courses-page .mobile-card-table tbody td.actions-cell::before {
    display: none;
  }

  .courses-page .mobile-card-table .actions-cell .btn {
    height: 36px;
    min-height: 36px;
    padding: 0 12px;
  }

  .courses-page .mobile-card-table tbody td.empty-state {
    display: block;
    grid-column: 1 / -1;
    padding: 24px 12px;
    text-align: center;
  }

  .courses-page .mobile-card-table tbody td.empty-state::before {
    display: none;
  }

  :where(.modal-footer, .modal-footer-actions, .course-modal-footer) {
    align-items: stretch;
    flex-direction: column;
  }

  :where(.modal-footer button, .modal-footer .btn, .modal-footer-actions button,
    .modal-footer-actions .btn, .course-modal-footer button) {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
