/* Opaque macOS-inspired workspace. Screen only: printed college forms keep their layout. */
@media screen {
  html[data-theme] {
    --mac-surface: #ffffff;
    --mac-raised: #f3f6f9;
    --mac-canvas: #edf2f7;
    --mac-sidebar: #e4ebf2;
    --mac-text: #243343;
    --mac-secondary: #526579;
    --mac-line: #cad4df;
    --mac-accent: #6858b5;
    --mac-accent-soft: #ebe8f8;
    --mac-shadow: 0 8px 24px #3449620c, 0 1px 3px #34496208;
    --mac-radius: 20px;
    --mac-table: #ffffff;
    --mac-header: #eaf0f6;
    --mac-hover: #f0f4fa;
    --purple: var(--mac-accent);
    --purple-dark: #403976;
    --purple-bg: var(--mac-accent-soft);
    --ink: var(--mac-text);
    --muted: var(--mac-secondary);
    --line: var(--mac-line);
    --bg: var(--mac-canvas);
    --shadow: var(--mac-shadow);
    --table-rule: #d6dee7;
    --table-rule-strong: #aab9ca;
    --theme-surface: var(--mac-surface);
    --theme-raised: var(--mac-raised);
    --theme-hover: var(--mac-hover);
    --theme-accent: var(--mac-accent);
    --green: #176547;
    --green-bg: #e3f3eb;
    --red: #a32f49;
    --red-bg: #fbe8ee;
    --amber: #795400;
  }
  html[data-theme='dark'] {
    --mac-surface: #293442;
    --mac-raised: #344150;
    --mac-canvas: #202b38;
    --mac-sidebar: #273544;
    --mac-text: #edf3fa;
    --mac-secondary: #becbd9;
    --mac-line: #4d5c6d;
    --mac-accent: #b9acff;
    --mac-accent-soft: #403a60;
    --mac-shadow: 0 8px 24px #1018212a, 0 1px 3px #10182120;
    --mac-table: #293442;
    --mac-header: #354455;
    --mac-hover: #344456;
    --purple-dark: #ded7ff;
    --table-rule: #48586a;
    --table-rule-strong: #718398;
    --green: #8ae2b8;
    --green-bg: #234a3d;
    --red: #ffb4c6;
    --red-bg: #593541;
    --amber: #f1d08a;
  }
  html[data-theme] body {
    background: linear-gradient(125deg, #c2d2df 0%, #dce3ec 55%, #d7d3e7 100%);
    color: var(--mac-text);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', College, sans-serif;
    font-size: 15px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
  }
  html[data-theme='dark'] body {
    background: linear-gradient(125deg, #172a3a, #29394e 55%, #343047);
  }
  html[data-theme]:has(dialog[open]) {
    overflow: hidden;
  }
  html[data-theme] :is(button, input, select, textarea) {
    font-family: inherit;
  }
  html[data-theme] :is(h1, h2, h3, strong) {
    color: var(--mac-text);
  }
  html[data-theme] h1 {
    font-size: clamp(28px, 2.6vw, 38px);
    font-weight: 650;
    letter-spacing: -1.2px;
    line-height: 1.2;
  }
  html[data-theme] h2 {
    font-size: 19px;
    font-weight: 650;
    letter-spacing: -0.45px;
  }
  html[data-theme] h3 {
    font-size: 17px;
    font-weight: 650;
  }
  html[data-theme]
    :is(
      .muted,
      .eyebrow,
      .page-heading p,
      .panel-head p,
      .page-footer,
      .profile small,
      .workspace-tag small,
      .breadcrumbs,
      .breadcrumbs strong
    ) {
    color: var(--mac-secondary);
  }
  html[data-theme] .eyebrow {
    font-size: 12px;
    font-weight: 650;
    letter-spacing: 1.6px;
  }
  html[data-theme] :is(.page-heading p, .panel-head p) {
    font-size: 14px;
    line-height: 1.6;
  }
  html[data-theme] .page-heading {
    align-items: flex-end;
    margin-bottom: 26px;
  }
  html[data-theme] .page-heading .eyebrow {
    margin-bottom: 10px;
  }
  html[data-theme] :is(input, select, textarea) {
    background-color: var(--mac-surface);
    color: var(--mac-text);
    border-color: var(--mac-line);
    border-radius: 11px;
    min-height: 44px;
    font-size: 16px;
    line-height: 1.5;
    padding: 10px 13px;
    accent-color: var(--mac-accent);
    box-shadow: 0 1px 2px #24334305;
  }
  html[data-theme] select {
    padding-right: 36px;
  }
  html[data-theme] :is(input, textarea)::placeholder {
    color: var(--mac-secondary);
    opacity: 1;
    font-size: 15px;
  }
  html[data-theme] :is(input, select, textarea):focus {
    border-color: var(--mac-accent);
    box-shadow: 0 0 0 3px var(--mac-accent-soft);
  }
  html[data-theme] :is(button, a):focus-visible {
    outline: 3px solid var(--mac-accent);
    outline-offset: 3px;
  }
  html[data-theme] :is(input[type='checkbox'], input[type='radio']) {
    min-height: 18px;
    width: 18px;
    height: 18px;
    padding: 0;
    box-shadow: none;
  }
  html[data-theme] .btn {
    min-height: 44px;
    border-radius: 11px;
    padding: 10px 17px;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.5;
    transition:
      background-color 0.15s,
      box-shadow 0.15s,
      transform 0.15s;
  }
  html[data-theme] .btn.primary {
    background: #6858b5;
    color: #fff;
    border: 1px solid #5d4da7;
    box-shadow:
      0 3px 7px #41387b20,
      inset 0 1px #897acb;
  }
  html[data-theme] .btn.primary:hover {
    background: #5b49a7;
    box-shadow: 0 5px 12px #41387b28;
  }
  html[data-theme] .btn.primary:active {
    transform: translateY(1px);
  }
  html[data-theme='dark'] .btn.primary {
    background: #a99aed;
    color: #211b3c;
    border-color: #b9acff;
    box-shadow:
      0 3px 8px #10182130,
      inset 0 1px #d1c7ff;
  }
  html[data-theme='dark'] .btn.primary:hover {
    background: #c0b3ff;
  }
  html[data-theme] :is(.btn.secondary, .icon-button, .theme-toggle) {
    background: var(--mac-surface);
    color: var(--mac-text);
    border: 1px solid var(--mac-line);
    box-shadow:
      0 2px 4px #24334308,
      inset 0 1px var(--mac-surface);
  }
  html[data-theme] :is(.btn.secondary, .icon-button, .theme-toggle):hover {
    background: var(--mac-hover);
    border-color: var(--table-rule-strong);
  }
  html[data-theme] :is(.icon-button, .theme-toggle) {
    width: 42px;
    min-width: 42px;
    height: 42px;
    min-height: 42px;
    border-radius: 11px;
  }
  html[data-theme] .text-button {
    color: var(--mac-accent);
    font-size: 14px;
  }
  html[data-theme] .badge {
    border-radius: 8px;
    font-size: 12px;
    padding: 4px 9px;
  }
  html[data-theme] :is(.lavender, .count, .department-badge, .group-badge) {
    background: var(--mac-accent-soft);
    color: var(--mac-accent);
  }
  html[data-theme] .neutral {
    background: var(--mac-raised);
    color: var(--mac-secondary);
  }
  html[data-theme] :is(.mint, .green-text) {
    color: var(--green);
  }
  html[data-theme] .mint {
    background: var(--green-bg);
  }
  html[data-theme] :is(.rose, .red-text) {
    color: var(--red);
  }
  html[data-theme] .rose {
    background: var(--red-bg);
  }
  html[data-theme] .amber {
    color: var(--amber);
    background: #fcf0d8;
  }
  html[data-theme='dark'] .amber {
    background: #51452c;
  }
  html[data-theme] .app-shell {
    margin: 16px;
    min-height: calc(100dvh - 32px);
    border-radius: 26px;
    box-shadow:
      0 22px 70px #24374b25,
      0 1px 4px #24374b10;
  }
  html[data-theme] .sidebar {
    inset: 16px auto 16px 16px;
    width: 244px;
    height: auto;
    padding: 20px 14px 0;
    background: var(--mac-sidebar);
    border: 1px solid var(--mac-line);
    border-radius: 26px 0 0 26px;
    overflow: hidden;
  }
  html[data-theme] .sidebar > .brand {
    margin: 0;
    flex-shrink: 0;
  }
  html[data-theme] .brand-logo-surface {
    border: 1px solid #d6dce6;
    border-radius: 11px;
    background: #fff;
    box-shadow: 0 2px 5px #24334306;
  }
  html[data-theme] .sidebar > .brand .college-logo {
    width: 154px;
    height: 58px;
  }
  html[data-theme] .workspace-tag {
    background: var(--mac-surface);
    border-color: var(--mac-line);
    border-radius: 13px;
    margin: 19px 0 18px;
    padding: 9px 10px;
    font-size: 14px;
    flex-shrink: 0;
  }
  html[data-theme] .workspace-icon {
    width: 33px;
    height: 33px;
    border-radius: 9px;
    background: var(--mac-accent-soft);
    color: var(--mac-accent);
  }
  html[data-theme] .nav-caption {
    padding-left: 10px;
    margin-bottom: 8px;
    color: var(--mac-secondary);
    font-size: 12px;
    letter-spacing: 1px;
  }
  html[data-theme] .sidebar > nav {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    padding: 2px 0 8px;
    scrollbar-width: thin;
  }
  html[data-theme] .nav-link {
    color: var(--mac-secondary);
    padding: 8px 10px;
    gap: 10px;
    min-height: 42px;
    border-radius: 11px;
    font-size: 14px;
    margin-bottom: 4px;
  }
  html[data-theme] .nav-link > .icon {
    width: 20px;
    height: 20px;
    color: var(--mac-accent);
  }
  html[data-theme] .nav-link:hover {
    background: var(--mac-raised);
    color: var(--mac-text);
  }
  html[data-theme] .nav-link.active {
    background: #6b5cb3;
    color: #fff;
    box-shadow:
      0 3px 7px #42357818,
      inset 0 1px #8c7fcb;
  }
  html[data-theme] .nav-link.active > .icon {
    color: #fff;
  }
  html[data-theme] .nav-link.active > i {
    display: none;
  }
  html[data-theme] .nav-count {
    background: var(--red-bg);
    color: var(--red);
    font-size: 12px;
    border-radius: 6px;
  }
  html[data-theme] .nav-link.active .nav-count {
    color: #42366f;
    background: #e4dcff;
  }
  html[data-theme] .sidebar-bottom {
    flex-shrink: 0;
    padding-top: 8px;
    margin-top: 0;
  }
  html[data-theme] .sidebar-note {
    display: none;
  }
  html[data-theme] .help-button {
    color: var(--mac-secondary);
    font-size: 13px;
    margin: 0 0 7px;
    padding: 8px 10px;
    min-height: 38px;
  }
  html[data-theme] .profile {
    position: relative;
    padding: 13px 2px 38px;
    border-color: var(--mac-line);
    gap: 8px;
  }
  html[data-theme] .profile strong {
    font-size: 13px;
  }
  html[data-theme] .profile small {
    font-size: 12px;
    display: block;
  }
  html[data-theme] .profile .role-mini {
    position: absolute;
    display: block;
    left: 2px;
    right: 2px;
    bottom: 13px;
    max-width: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  html[data-theme] .profile .icon-button {
    width: 32px;
    min-width: 32px;
    height: 34px;
    min-height: 34px;
  }
  html[data-theme] .avatar {
    background: var(--mac-accent-soft);
    color: var(--mac-accent);
    border: 2px solid var(--mac-surface);
  }
  html[data-theme] .main-shell {
    margin-left: 244px;
    width: calc(100% - 244px);
    background: var(--mac-canvas);
    border-radius: 0 26px 26px 0;
    border: 1px solid var(--mac-line);
    border-left: 0;
    min-height: calc(100dvh - 32px);
  }
  html[data-theme] .topbar {
    background: var(--mac-raised);
    border-color: var(--mac-line);
    height: 76px;
    min-height: 76px;
    padding: 0 28px;
    border-radius: 0 26px 0 0;
  }
  html[data-theme] .topbar-right {
    gap: 10px;
  }
  html[data-theme] .breadcrumbs {
    font-size: 13px;
    gap: 10px;
  }
  html[data-theme] .breadcrumbs strong {
    font-size: 13px;
    font-weight: 600;
  }
  html[data-theme] .save-state {
    color: var(--mac-secondary);
    font-size: 12px;
  }
  html[data-theme] .save-state > .icon {
    color: var(--green);
    width: 15px;
    height: 15px;
  }
  html[data-theme] .top-divider {
    background: var(--mac-line);
  }
  html[data-theme] .topbar-logo .college-logo {
    width: 112px;
    height: 43px;
  }
  html[data-theme] .topbar-logo .brand-logo-surface {
    padding: 2px 7px;
    border-radius: 9px;
  }
  html[data-theme] #main {
    padding: 30px 28px;
  }
  html[data-theme] .page-footer {
    color: var(--mac-secondary);
    margin: 0 28px;
    border-color: var(--mac-line);
    font-size: 12px;
  }
  html[data-theme] :is(.panel, .stat-card, .journal-info, .month-panel, .year-switch) {
    background: var(--mac-surface);
    border: 1px solid var(--mac-line);
    border-radius: var(--mac-radius);
    box-shadow: var(--mac-shadow);
  }
  html[data-theme] .panel-head {
    padding: 22px;
  }
  html[data-theme] .panel-head h2 {
    color: var(--mac-text);
    font-size: 19px;
  }
  html[data-theme] .panel-foot {
    color: var(--mac-secondary);
    background: var(--mac-raised);
    border-color: var(--mac-line);
  }
  html[data-theme] .heading-actions {
    gap: 10px;
    flex-wrap: wrap;
  }
  html[data-theme] .date-control {
    background: var(--mac-surface);
    border-color: var(--mac-line);
    border-radius: 11px;
    padding-left: 12px;
    color: var(--mac-secondary);
    min-height: 44px;
  }
  html[data-theme] .date-control input {
    background-color: var(--mac-surface);
    color: var(--mac-text);
    box-shadow: none;
    border: 0;
    padding: 8px 9px 8px 0;
    min-height: 42px;
    font-size: 15px;
  }
  html[data-theme] .search-field {
    background: var(--mac-surface);
    border-color: var(--mac-line);
    border-radius: 11px;
    color: var(--mac-secondary);
    padding: 7px 12px;
    min-height: 44px;
  }
  html[data-theme] .search-field input {
    background-color: var(--mac-surface);
    border: 0;
    border-radius: 0;
    color: var(--mac-text);
    min-height: 28px;
    padding: 0;
    box-shadow: none;
    font-size: 16px;
  }
  html[data-theme] .search-field:focus-within {
    border-color: var(--mac-accent);
    box-shadow: 0 0 0 3px var(--mac-accent-soft);
  }
  html[data-theme] .day-banner {
    background: #e1e8f4;
    border-color: #cbd6e7;
    border-radius: 22px;
    min-height: 164px;
    padding: 28px;
    box-shadow:
      inset 0 1px #f8fbff,
      var(--mac-shadow);
  }
  html[data-theme='dark'] .day-banner {
    background: #35445b;
    border-color: #52627b;
    box-shadow:
      inset 0 1px #465874,
      var(--mac-shadow);
  }
  html[data-theme] :is(.day-banner h2, .banner-progress strong) {
    color: var(--mac-text);
  }
  html[data-theme] .day-banner h2 {
    font-size: 30px;
    letter-spacing: -0.8px;
    margin: 10px 0 5px;
  }
  html[data-theme]
    :is(
      .day-label,
      .day-banner > div > span:last-child,
      .banner-progress > div:first-child,
      .banner-progress small
    ) {
    color: var(--mac-secondary);
  }
  html[data-theme] .banner-progress > span {
    color: var(--mac-secondary) !important;
  }
  html[data-theme] .banner-progress {
    margin-right: 110px;
  }
  html[data-theme] .banner-art {
    color: var(--mac-secondary);
  }
  html[data-theme] .banner-art > i {
    background: var(--mac-surface);
    color: var(--mac-accent);
    border-color: var(--mac-header);
  }
  html[data-theme] .progress {
    background: var(--mac-header);
    height: 7px;
    border-radius: 10px;
  }
  html[data-theme] .progress > i {
    background: var(--mac-accent);
    border-radius: 10px;
  }
  html[data-theme] .stats-grid {
    gap: 16px;
    margin-bottom: 24px;
  }
  html[data-theme] .stat-card {
    min-height: 142px;
    padding: 20px;
    gap: 12px;
  }
  html[data-theme] .stat-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
  }
  html[data-theme] .stat-icon > .icon {
    width: 21px;
    height: 21px;
  }
  html[data-theme] .stat-card strong {
    color: var(--mac-text);
    font-size: 34px;
    letter-spacing: -1px;
    font-weight: 650;
  }
  html[data-theme] :is(.stat-card > div > span, .stat-card small) {
    color: var(--mac-secondary);
    white-space: normal;
    font-size: 13px;
  }
  html[data-theme] .stat-card small {
    font-size: 12px;
  }
  html[data-theme] .stat-pill {
    position: static;
    align-self: flex-start;
    padding: 3px 7px;
    border-radius: 7px;
    font-size: 12px;
  }
  html[data-theme] .overview-layout {
    gap: 22px;
    grid-template-columns: minmax(0, 1fr) 280px;
  }
  html[data-theme] .table-scroll :is(th, td) {
    border-right-color: var(--table-rule);
    border-bottom-color: var(--table-rule);
  }
  html[data-theme] .table-scroll th {
    background: var(--mac-header);
    color: var(--mac-secondary);
    font-size: 12px;
    font-weight: 600;
  }
  html[data-theme] .table-scroll td {
    color: var(--mac-text);
    font-size: 14px;
    background: var(--mac-table);
  }
  html[data-theme] .table-scroll tbody tr:hover > td {
    background: var(--mac-hover);
  }
  html[data-theme] .table-scroll :is(.green-text, .numeric.green-text) {
    color: var(--green);
  }
  html[data-theme] .table-scroll :is(.red-text, .numeric.red-text) {
    color: var(--red);
  }
  html[data-theme] :is(.group-link strong, .overview-table .numeric, .table-percent strong) {
    color: var(--mac-text);
  }
  html[data-theme] .group-link > span:last-child {
    color: var(--mac-secondary);
  }
  html[data-theme] .journal-info {
    padding: 22px;
  }
  html[data-theme] .journal-info h2 {
    color: var(--mac-text);
    font-size: 26px;
  }
  html[data-theme] .journal-info p {
    color: var(--mac-secondary);
    font-size: 14px;
  }
  html[data-theme] .journal-group-icon {
    background: var(--mac-accent-soft);
    color: var(--mac-accent);
    border-radius: 15px;
  }
  html[data-theme] .journal-day-settings {
    background: var(--mac-raised);
    border-color: var(--mac-line);
    padding: 18px 20px;
    gap: 14px;
  }
  html[data-theme] .journal-day-settings label,
  html[data-theme] .day-setting-status {
    color: var(--mac-secondary);
  }
  html[data-theme] :is(.journal-legend > span, .journal-summary, .day-head small) {
    color: var(--mac-secondary);
    font-size: 12px;
  }
  html[data-theme] .journal-scroll {
    border-radius: 15px;
    border-color: var(--mac-line);
    scrollbar-width: auto;
  }
  html[data-theme] .journal-table .sticky-name {
    background: var(--mac-table);
    border-right-color: var(--table-rule-strong);
  }
  html[data-theme] .journal-table th.sticky-name {
    background: var(--mac-header);
    color: var(--mac-secondary);
  }
  html[data-theme] .journal-table .sticky-name strong {
    color: var(--mac-text);
    font-weight: 600;
    font-size: 14px;
  }
  html[data-theme] .journal-table .row-number {
    color: var(--mac-secondary) !important;
  }
  html[data-theme] .journal-table .current-day {
    background: var(--mac-accent-soft);
  }
  html[data-theme] .journal-table .day-head.current-day {
    background: var(--mac-accent-soft);
    color: var(--mac-accent);
  }
  html[data-theme] .journal-table .mark-td:focus-within {
    background: var(--mac-accent-soft);
  }
  html[data-theme] .mark {
    border-radius: 8px;
    font-weight: 650;
    font-size: 14px;
  }
  html[data-theme] .mark.present {
    background: var(--green-bg);
    color: var(--green);
  }
  html[data-theme] .mark.absent {
    background: var(--red-bg);
    color: var(--red);
  }
  html[data-theme] .mark.excused {
    background: var(--mac-accent-soft);
    color: var(--mac-accent);
  }
  html[data-theme] .mark.late {
    background: #fbefd8;
    color: #805100;
  }
  html[data-theme='dark'] .mark.late {
    background: #51452c;
    color: #f1d08a;
  }
  html[data-theme] .mark.blank {
    background: var(--mac-raised);
    color: var(--mac-secondary);
  }
  html[data-theme] .full-date-table :is(.sticky-curator, .sticky-group) {
    background: var(--mac-table);
    color: var(--mac-text);
  }
  html[data-theme] .full-date-table thead :is(.sticky-curator, .sticky-group) {
    background: var(--mac-header);
  }
  html[data-theme] .full-date-table tbody tr:hover :is(.sticky-curator, .sticky-group) {
    background: var(--mac-hover);
  }
  html[data-theme] .full-date-table .totals-row > :is(td, .sticky-curator, .sticky-group) {
    background: var(--mac-accent-soft);
    color: var(--mac-text);
  }
  html[data-theme] .calendar-day {
    color: var(--mac-text);
    border-radius: 10px;
    font-size: 14px;
  }
  html[data-theme] .calendar-day:hover {
    background: var(--mac-hover);
  }
  html[data-theme] .calendar-day.selected {
    background: #6858b5;
    color: #fff;
    border-color: #6858b5;
    box-shadow: 0 3px 8px #42357820;
  }
  html[data-theme='dark'] .calendar-day.selected {
    background: #b9acff;
    color: #211b3c;
    border-color: #b9acff;
  }
  html[data-theme] :is(.weekday, .calendar-description, .calendar-all) {
    color: var(--mac-secondary);
    font-size: 12px;
  }
  html[data-theme] .mini-calendar h2 {
    font-size: 17px;
  }
  html[data-theme] .social-callout {
    background: var(--mac-accent-soft);
    border-color: var(--mac-line);
    border-radius: 18px;
  }
  html[data-theme] .social-callout :is(h3, p, a) {
    color: var(--mac-text);
  }
  html[data-theme] :is(.social-intro, .social-student) {
    background: var(--mac-surface);
    border-color: var(--mac-line);
    border-radius: 18px;
  }
  html[data-theme] .social-intro :is(h2, strong),
  html[data-theme] .social-student strong {
    color: var(--mac-text);
  }
  html[data-theme] .social-intro p,
  html[data-theme] .social-student p {
    color: var(--mac-secondary);
  }
  html[data-theme] :is(.report-group-modes > label, .report-group-checklist) {
    background: var(--mac-surface);
    color: var(--mac-text);
    border-color: var(--mac-line);
    border-radius: 12px;
  }
  html[data-theme] .monthly-report-groups {
    background: var(--mac-raised);
    border-color: var(--mac-line);
    border-radius: 15px;
  }
  html[data-theme] .monthly-report-groups > legend {
    color: var(--mac-text);
  }
  html[data-theme] #report-form {
    container-type: inline-size;
  }
  html[data-theme] .paper-preview {
    background: #fff;
    color: #2d3138;
    border-color: #d3d8de;
  }
  html[data-theme] .report-preview .paper-preview :is(h3, p, strong) {
    color: #2d3138;
  }
  html[data-theme] .preview-table > i {
    background: #e5e7eb;
  }
  html[data-theme] .preview-table > div,
  html[data-theme] .preview-table > div > span,
  html[data-theme] .signature-line {
    border-color: #c7cdd5;
  }
  html[data-theme] .report-group-modes > label:has(input:checked) {
    background: var(--mac-accent-soft);
    border-color: var(--mac-accent);
  }
  html[data-theme] #toast {
    background: var(--mac-text);
    color: var(--mac-surface);
    font-size: 14px;
    border-radius: 13px;
    box-shadow: 0 8px 30px #18243530;
  }
  html[data-theme] #toast.error {
    background: #a32f49;
    color: #fff;
  }
  html[data-theme] .login-page {
    margin: 28px auto;
    width: min(1120px, calc(100% - 56px));
    min-height: calc(100dvh - 56px);
    background: var(--mac-surface);
    border: 1px solid var(--mac-line);
    border-radius: 28px;
    box-shadow: 0 24px 75px #24374b25;
    overflow: hidden;
  }
  html[data-theme] .login-art {
    background: #dce6f1;
    padding: 36px;
  }
  html[data-theme='dark'] .login-art {
    background: #31435a;
  }
  html[data-theme] .login-art:after {
    display: none;
  }
  html[data-theme] .login-art .brand-logo-surface {
    padding: 5px 12px;
  }
  html[data-theme] .login-message {
    padding: 35px 0;
    max-width: 390px;
  }
  html[data-theme] .login-message h1 {
    font-size: clamp(34px, 3.3vw, 46px);
    color: var(--mac-text);
    letter-spacing: -1.5px;
    line-height: 1.16;
  }
  html[data-theme] .login-message > p {
    font-size: 16px;
    color: var(--mac-secondary);
    line-height: 1.75;
  }
  html[data-theme] :is(.login-message > .eyebrow, .login-art-foot) {
    color: var(--mac-secondary);
  }
  html[data-theme] .art-calendar {
    background: var(--mac-surface);
    border: 1px solid var(--mac-line);
    border-radius: 20px;
    padding: 22px;
    transform: rotate(-3deg);
    box-shadow:
      0 12px 26px #24374b15,
      inset 0 1px var(--mac-surface);
  }
  html[data-theme] .art-calendar :is(strong, div:first-child > span, footer) {
    color: var(--mac-secondary);
  }
  html[data-theme] .art-dots i {
    background: var(--green-bg);
    color: var(--green);
    border-radius: 8px;
  }
  html[data-theme] .art-dots i.absent {
    background: var(--red-bg);
    color: var(--red);
  }
  html[data-theme] .login-form-wrap {
    background: var(--mac-surface);
    padding: 120px 48px 100px;
  }
  html[data-theme] .login-controls .theme-toggle {
    width: auto;
    padding-inline: 12px;
  }
  html[data-theme] .login-form {
    width: 350px;
  }
  html[data-theme] .login-form h2 {
    color: var(--mac-text);
    font-size: 32px;
    letter-spacing: -0.8px;
  }
  html[data-theme] .login-form :is(p, form > label, .login-note) {
    color: var(--mac-secondary);
  }
  html[data-theme] .login-form input {
    min-height: 48px;
    background-color: var(--mac-raised);
    color: var(--mac-text);
    border-color: var(--mac-line);
    font-size: 16px;
    border-radius: 12px;
  }
  html[data-theme] .login-form input[type='checkbox'] {
    min-height: 18px;
  }
  html[data-theme] .login-form .check-label {
    font-size: 14px;
  }
  html[data-theme] .login-form input::placeholder {
    color: var(--mac-secondary);
    font-size: 15px;
  }
  html[data-theme] .password-wrap button {
    color: var(--mac-secondary);
    top: 6px;
  }
  html[data-theme] .login-submit {
    min-height: 48px;
    border-radius: 12px;
    font-size: 16px;
  }
  html[data-theme] .login-form-wrap > footer {
    color: var(--mac-secondary);
    font-size: 12px;
  }
  html[data-theme] .spinner {
    border-color: var(--mac-line);
    border-top-color: var(--mac-accent);
  }
  @container (max-width: 600px) {
    html[data-theme] #report-form .report-form-grid {
      grid-template-columns: minmax(0, 1fr);
    }
  }
  @container (max-width: 420px) {
    html[data-theme] #report-form :is(.report-group-modes, .format-select) {
      display: grid;
      grid-template-columns: minmax(0, 1fr);
    }
  }
  @media (max-height: 850px) and (min-width: 761px) {
    html[data-theme] .sidebar > .brand {
      margin-bottom: 18px;
    }
    html[data-theme] .workspace-tag {
      display: none;
    }
    html[data-theme] .nav-link {
      min-height: 36px;
      padding: 6px 10px;
      margin-bottom: 3px;
    }
  }
  @media (max-width: 1350px) {
    html[data-theme] .overview-layout {
      grid-template-columns: minmax(0, 1fr);
    }
    html[data-theme] .right-rail {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 20px;
    }
    html[data-theme] .stat-card {
      padding: 18px;
      flex-direction: column;
      gap: 10px;
    }
    html[data-theme] .stat-pill {
      margin-top: auto;
    }
    html[data-theme] .topbar .breadcrumbs {
      display: none;
    }
    html[data-theme] .topbar-right {
      margin-left: auto;
    }
  }
  @media (max-width: 1050px) and (min-width: 761px) {
    html[data-theme] .sidebar {
      width: 216px;
    }
    html[data-theme] .main-shell {
      margin-left: 216px;
      width: calc(100% - 216px);
    }
    html[data-theme] .nav-link {
      font-size: 13px;
      gap: 9px;
    }
    html[data-theme] .topbar .save-state > span,
    html[data-theme] .topbar .top-divider {
      display: none;
    }
    html[data-theme] #main {
      padding: 26px 22px;
    }
    html[data-theme] .page-heading {
      flex-wrap: wrap;
    }
    html[data-theme] .banner-progress {
      margin-right: 0;
      width: 180px;
    }
    html[data-theme] .banner-art {
      display: none;
    }
    html[data-theme] .stats-grid {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }
  }
  @media (max-width: 980px) {
    html[data-theme] .login-page {
      grid-template-columns: minmax(0, 1fr);
      max-width: 580px;
    }
    html[data-theme] .login-art {
      display: none;
    }
    html[data-theme] .login-form-wrap {
      min-height: calc(100dvh - 58px);
    }
  }
  @media (max-width: 760px) {
    html[data-theme] body {
      background: var(--mac-canvas);
    }
    html[data-theme] .app-shell {
      margin: 0;
      min-height: 100dvh;
      border-radius: 0;
      box-shadow: none;
    }
    html[data-theme] .main-shell {
      margin-left: 0;
      width: 100%;
      min-height: 100dvh;
      border: 0;
      border-radius: 0;
    }
    html[data-theme] .sidebar {
      inset: 10px auto 10px 10px;
      width: min(290px, calc(100vw - 40px));
      border-radius: 22px;
      transform: translateX(calc(-100% - 20px));
      box-shadow: 12px 0 35px #18243525;
    }
    html[data-theme] .menu-open .sidebar {
      transform: translateX(0);
    }
    html[data-theme] .sidebar-backdrop {
      background: #aab6c4;
      backdrop-filter: none;
    }
    html[data-theme='dark'] .sidebar-backdrop {
      background: #18212d;
    }
    html[data-theme] .topbar {
      position: sticky;
      top: 0;
      z-index: 10;
      padding: 0 14px;
      min-height: 72px;
      height: 72px;
      border-radius: 0;
      gap: 8px;
    }
    html[data-theme] .topbar-right {
      gap: 8px;
    }
    html[data-theme] .topbar :is(.save-state, .top-divider, .breadcrumbs) {
      display: none;
    }
    html[data-theme] .topbar .mobile-menu {
      display: inline-flex;
      width: 42px;
      min-width: 42px;
    }
    html[data-theme] .topbar-logo .college-logo {
      width: 108px;
      height: 41px;
    }
    html[data-theme] .topbar-logo .brand-logo-surface {
      padding: 2px 5px;
    }
    html[data-theme] .topbar :is(.account-button, .theme-toggle) {
      min-height: 42px;
      min-width: 42px;
      width: 42px;
      height: 42px;
    }
    html[data-theme] #main {
      padding: 25px 16px;
    }
    html[data-theme] .page-heading {
      align-items: flex-start;
      flex-direction: column;
      gap: 18px;
      margin-bottom: 22px;
    }
    html[data-theme] .page-heading h1 {
      font-size: 30px;
    }
    html[data-theme] .heading-actions {
      width: 100%;
      align-items: stretch;
      gap: 10px;
    }
    html[data-theme]
      .heading-actions
      > :is(.date-control, .department-filter, .journal-group-filter) {
      flex: 1 1 160px;
    }
    html[data-theme] .heading-actions .btn {
      flex: 1 1 auto;
    }
    html[data-theme] .day-banner {
      display: block;
      padding: 22px;
      min-height: 0;
      border-radius: 19px;
    }
    html[data-theme] .day-banner h2 {
      font-size: 27px;
    }
    html[data-theme] .day-banner > div > span:last-child {
      max-width: none;
      font-size: 14px;
    }
    html[data-theme] .banner-progress {
      margin: 20px 0 0;
      width: 100%;
    }
    html[data-theme] .banner-art {
      display: none;
    }
    html[data-theme] .stats-grid {
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 12px;
    }
    html[data-theme] .stat-card {
      min-height: 170px;
      padding: 16px;
      border-radius: 18px;
      flex-direction: column;
    }
    html[data-theme] .stat-card > div > span {
      font-size: 13px;
    }
    html[data-theme] .stat-card strong {
      font-size: 32px;
    }
    html[data-theme] .stat-card small {
      font-size: 12px;
    }
    html[data-theme] .stat-icon {
      width: 35px;
      height: 35px;
    }
    html[data-theme] .panel {
      border-radius: 18px;
    }
    html[data-theme] .panel-head {
      padding: 20px 17px;
      flex-wrap: wrap;
    }
    html[data-theme] .panel-head h2 {
      font-size: 18px;
    }
    html[data-theme] .table-toolbar {
      padding-left: 17px;
      padding-right: 17px;
    }
    html[data-theme] .journal-info {
      padding: 18px;
      gap: 14px;
    }
    html[data-theme] .journal-table .sticky-name {
      min-width: 180px;
      max-width: 180px;
    }
    html[data-theme] .journal-table .mark-td {
      min-width: 46px;
      padding: 6px;
    }
    html[data-theme] .journal-table .mark {
      min-width: 34px;
      height: 36px;
    }
    html[data-theme] .journal-toolbar {
      padding: 16px;
    }
    html[data-theme] .page-footer {
      margin: 0 16px;
    }
    html[data-theme] .right-rail {
      grid-template-columns: minmax(0, 1fr);
    }
    html[data-theme] .login-page {
      margin: 16px;
      width: calc(100% - 32px);
      min-height: calc(100dvh - 32px);
      display: block;
      max-width: none;
      border-radius: 24px;
    }
    html[data-theme] .login-art {
      display: none;
    }
    html[data-theme] .login-form-wrap {
      min-height: calc(100dvh - 66px);
      padding: 128px 26px 100px;
      border-radius: 24px;
    }
    html[data-theme] .login-controls {
      top: 22px;
      left: 24px;
      right: 24px;
    }
    html[data-theme] .login-form-wrap > footer {
      left: 26px;
      right: 26px;
    }
    html[data-theme] .login-form h2 {
      font-size: 30px;
    }
  }
  @media (max-width: 600px) {
    html[data-theme] .journal-day-settings {
      flex-direction: column;
      align-items: stretch;
      padding: 18px;
    }
    html[data-theme] .journal-day-settings label {
      width: 100%;
      min-width: 0;
      max-width: none;
    }
    html[data-theme] .journal-day-settings select,
    html[data-theme] .journal-day-settings .date-control {
      width: 100%;
    }
    html[data-theme] .day-setting-status {
      margin-left: 0;
      text-align: left;
    }
  }
  @media (max-width: 380px) {
    html[data-theme] .topbar {
      padding: 0 10px;
    }
    html[data-theme] .topbar-right {
      gap: 6px;
    }
    html[data-theme] .topbar-logo .college-logo {
      width: 89px;
      height: 35px;
    }
    html[data-theme] .topbar .care-topbar-notice {
      max-width: 38px;
      min-width: 32px;
      padding: 6px;
    }
    html[data-theme] .stats-grid {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    html[data-theme] .stat-card {
      display: flex;
      padding: 14px;
    }
    html[data-theme] .stat-card .stat-pill {
      margin-top: auto;
    }
    html[data-theme] .login-form-wrap {
      padding-left: 21px;
      padding-right: 21px;
    }
  }
  @media (prefers-reduced-motion: reduce) {
    html[data-theme] *,
    html[data-theme] *::before,
    html[data-theme] *::after {
      animation-duration: 0.01ms !important;
      transition-duration: 0.01ms !important;
      scroll-behavior: auto !important;
    }
  }
}
