/* Library: scope tabs above compact media filters. */
.topbar {
  gap: 24px;
  min-width: 0;
}
.topbar .breadcrumb {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  line-height: 1.5;
}
.topbar .breadcrumb span {
  margin: 0;
}
.topbar .breadcrumb-root {
  color: #85858e;
  white-space: nowrap;
}
.topbar .breadcrumb-separator {
  color: #505059;
}
.topbar .breadcrumb-current {
  color: #d9d9df;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.topbar .topright {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  flex-shrink: 0;
  width: auto;
  margin-left: auto;
}
.topbar .profile {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 6px 10px;
  border: 0;
  border-radius: 10px;
  min-width: 0;
  max-width: 260px;
  text-align: left;
  min-height: 52px;
}
.profile-panel {
  position: fixed;
  inset: auto 20px auto auto;
  margin: 0;
  box-sizing: border-box;
  width: min(440px, calc(100vw - 24px));
  padding: 24px;
  overflow-y: auto;
  background: #191c1d;
  color: #e9ece5;
  border: 1px solid #3b403b;
  border-radius: 20px;
  box-shadow: 0 22px 65px #0009;
}
.profile-panel::backdrop {
  background: transparent;
}
.profile-panel-head {
  display: flex;
  align-items: center;
  gap: 15px;
}
.profile-panel-avatar {
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #363f2c;
  border: 2px solid #c2e477;
  color: #e1f3bd;
  font-size: 28px;
}
.profile-panel h2 {
  margin: 0 0 7px;
  font-size: 21px;
  overflow-wrap: anywhere;
}
.profile-panel-head > div:nth-child(2) {
  min-width: 0;
  flex: 1;
}
.profile-role {
  color: #b9c5a7;
  font-size: 12px;
}
.profile-panel button {
  cursor: pointer;
}
.profile-panel-close {
  align-self: flex-start;
  padding: 3px;
  color: #939c96;
}
.profile-panel svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}
.profile-panel-info {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px 14px;
  margin: 22px 0;
  font-size: 13px;
}
.profile-panel-info > span {
  color: #949d97;
}
.profile-panel-info strong {
  font-weight: 400;
  overflow-wrap: anywhere;
}
.profile-quota {
  padding: 20px;
  border: 1px solid #343c31;
  border-radius: 13px;
  background: #242a22;
}
.profile-quota > div:first-child {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
}
.profile-quota span {
  font-size: 13px;
}
.profile-quota small {
  font-size: 12px;
  color: #a5b09b;
  font-weight: 400;
}
.profile-quota > strong {
  display: block;
  font-size: 28px;
  color: #cee897;
  margin: 12px 0 6px;
}
.profile-quota-track {
  height: 9px;
  margin-top: 15px;
  border-radius: 8px;
  overflow: hidden;
  background: #3c4437;
}
.profile-quota-track > span {
  display: block;
  height: 100%;
  background: #c1e57a;
  border-radius: inherit;
}
.profile-panel-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin: 20px 0;
}
.profile-panel-links button {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 10px;
  color: #c5cdc5;
  border-radius: 9px;
  text-align: left;
  font-size: 13px;
}
.profile-panel-links button:hover {
  background: #2c322b;
}
.profile-panel-logout {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  padding: 14px;
  background: #25292a;
  color: #b4bdb7;
  border-radius: 10px;
}
.profile-panel-logout:hover {
  background: #303637;
}
@media (max-width: 600px) {
  .profile-panel {
    right: 12px;
    padding: 18px;
  }
}
.topbar .profile:hover {
  background: #242427;
}
.topbar .profile .avatar {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  font-size: 16px;
}
.topbar .profile > div:last-child {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  min-width: 0;
}
.topbar .profile strong {
  display: block;
  max-width: 170px;
  font-size: 14px;
  font-weight: 550;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.topbar .profile small {
  display: block;
  font-size: 11px;
  color: #8d8d95;
  line-height: 1.3;
  margin: 0;
}
.topbar .topbar-logout {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  min-width: 38px;
  padding: 0;
  border: 1px solid #35353a;
  border-radius: 9px;
  color: #9a9aa3;
}
.topbar .topbar-logout:hover {
  background: #2a2a2e;
  border-color: #58585f;
  color: #f1f1f3;
}
.topbar-logout svg {
  width: 17px;
  height: 17px;
}
@media (max-width: 700px) {
  .topbar {
    gap: 10px;
    padding: 0 16px;
  }
  .topbar .breadcrumb {
    display: flex;
    flex: 1;
    gap: 0;
  }
  .topbar .breadcrumb-root,
  .topbar .breadcrumb-separator {
    display: none;
  }
  .topbar .breadcrumb-current {
    font-size: 13px;
  }
  .topbar .topright {
    gap: 8px;
    max-width: 70%;
  }
  .topbar .profile {
    gap: 8px;
    padding: 5px;
    max-width: 190px;
  }
  .topbar .profile strong {
    max-width: 110px;
    font-size: 13px;
  }
  .topbar .profile .avatar {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
    font-size: 14px;
  }
  .topbar .topbar-logout {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
  }
}
@media (min-width: 701px) {
  .account-table .school-account-columns {
    width: 100%;
    min-width: 1100px;
    table-layout: fixed;
  }
  .school-account-columns .account-col-select {
    width: 4%;
  }
  .school-account-columns .account-col-member {
    width: 20%;
  }
  .school-account-columns .account-col-role {
    width: 8%;
  }
  .school-account-columns .account-col-school {
    width: 14%;
  }
  .school-account-columns .account-col-class {
    width: 10%;
  }
  .school-account-columns .account-col-usage {
    width: 20%;
  }
  .school-account-columns .account-col-state {
    width: 12%;
  }
  .school-account-columns .account-col-actions {
    width: 12%;
  }
  .account-table .school-account-columns th,
  .account-table .school-account-columns td {
    box-sizing: border-box;
    padding: 16px 18px;
    vertical-align: middle;
    text-align: left;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .account-table .school-account-columns .account-select-cell {
    text-align: center;
    padding: 12px 8px;
    min-width: 0;
    width: auto;
  }
  .school-account-columns .account-member .subtext {
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .school-account-columns th {
    font-weight: 500;
  }
}
@media (max-width: 700px) {
  .school-account-columns colgroup {
    display: none;
  }
}
.library-page .pagehead {
  margin-bottom: 24px;
}
.library-toolbar {
  margin-bottom: 28px;
}
.library-toolbar-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid #343438;
}
.library-tabs {
  display: flex;
  align-items: center;
  gap: 28px;
  min-width: 0;
}
.library-tabs button {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 15px 0 17px;
  color: #909097;
  font-size: 15px;
  font-weight: 500;
  white-space: nowrap;
}
.library-tabs button svg {
  width: 17px;
  height: 17px;
}
.library-tabs button:hover {
  color: #e4e6de;
}
.library-tabs button[aria-pressed='true'] {
  color: #d7ef9c;
}
.library-tabs button[aria-pressed='true']:after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 2px;
  background: #c9e68c;
  border-radius: 2px;
}
.library-refresh {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 12px;
  margin-bottom: 3px;
  color: #a1a1a8;
  border: 1px solid #38383e;
  border-radius: 8px;
  font-size: 12px;
  white-space: nowrap;
}
.library-refresh svg {
  width: 15px;
  height: 15px;
}
.library-refresh:hover:not(:disabled) {
  background: #29292d;
  color: #e6e6e9;
  border-color: #57585e;
}
.library-refresh:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.library-toolbar-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 18px;
}
.library-types {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  padding: 4px;
  border: 1px solid #313136;
  border-radius: 10px;
  background: #1e1e21;
}
.library-types button {
  padding: 7px 17px;
  border-radius: 7px;
  color: #929299;
  font-size: 13px;
  min-height: 34px;
  white-space: nowrap;
}
.library-types button:hover {
  color: #e9e9ec;
  background: #ffffff06;
}
.library-types button[aria-pressed='true'] {
  background: #363936;
  color: #edf3e6;
  box-shadow: 0 1px 3px #0003;
}
.library-summary {
  color: #797981;
  font-size: 12px;
  text-align: right;
}
.library-student-picker {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 18px 0 0;
}
.library-student-picker label {
  margin: 0;
  font-size: 13px;
  color: #b6b6bd;
}
.library-student-picker select {
  width: 240px;
  max-width: 100%;
  padding: 10px 30px 10px 12px;
  border-radius: 9px;
}
.library-student-picker > span {
  font-size: 12px;
  color: #797981;
}
.library-grid {
  gap: 24px;
}
.library-card .project-cover {
  border-radius: 14px;
}
.library-image-button {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  cursor: zoom-in;
  overflow: hidden;
}
.library-image-button > img {
  transition: transform 0.25s;
}
.library-image-button:hover > img {
  transform: scale(1.025);
}
.library-image-button:focus-visible {
  outline-offset: -4px;
}
.library-preview-hint {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translate(-50%, 6px);
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 13px;
  border: 1px solid #ffffff26;
  border-radius: 30px;
  background: #141619d9;
  color: #f1f3ee;
  font-size: 12px;
  white-space: nowrap;
  opacity: 0;
  transition:
    opacity 0.18s,
    transform 0.18s;
  pointer-events: none;
  backdrop-filter: blur(8px);
}
.library-preview-hint svg {
  width: 14px;
  height: 14px;
}
.library-image-button:hover .library-preview-hint,
.library-image-button:focus-visible .library-preview-hint {
  opacity: 1;
  transform: translate(-50%, 0);
}
.library-card .project-caption {
  padding: 13px 2px 4px;
  gap: 10px;
}
.library-card .project-caption > strong {
  font-size: 14px;
  line-height: 1.6;
}
.library-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-width: 0;
}
.library-card-meta .asset-creator {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  color: #898991;
}
.library-card-meta a {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
  font-size: 12px;
  color: #bbcba0;
  text-decoration: none;
}
.library-card-meta a:hover {
  color: #e1efc7;
}
.library-card-meta a svg {
  width: 13px;
  height: 13px;
}
dialog.library-preview-dialog {
  width: min(1080px, calc(100vw - 40px));
  max-width: calc(100vw - 40px);
  max-height: calc(100dvh - 40px);
  padding: 24px;
  border-radius: 18px;
  overflow: auto;
  background: #1b1c1e;
}
dialog.library-preview-dialog h2 {
  font-size: 17px;
  margin: 0 40px 18px 0;
}
.library-lightbox {
  margin: 0;
}
.library-lightbox > img {
  display: block;
  width: 100%;
  height: auto;
  max-height: calc(100dvh - 230px);
  object-fit: contain;
  border-radius: 10px;
  background: #111214;
}
.library-lightbox figcaption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 18px;
}
.library-lightbox figcaption > div {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.library-lightbox strong {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  max-height: 110px;
  overflow: auto;
}
.library-lightbox figcaption > div > span {
  font-size: 12px;
  color: #8e9094;
}
.library-lightbox .secondary {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
  padding: 10px 14px;
  text-decoration: none;
  font-size: 13px;
}
.library-lightbox .secondary svg {
  width: 15px;
  height: 15px;
}
@media (max-width: 700px) {
  .library-page .pagehead {
    margin-bottom: 16px;
  }
  .library-tabs {
    gap: 22px;
  }
  .library-tabs button {
    font-size: 14px;
    min-height: 48px;
  }
  .library-refresh {
    padding: 8px 10px;
    font-size: 12px;
  }
  .library-toolbar-bottom {
    gap: 12px;
    align-items: flex-start;
    flex-wrap: wrap;
    padding-top: 14px;
  }
  .library-types {
    width: auto;
    max-width: 100%;
    gap: 2px;
  }
  .library-types button {
    padding: 7px 15px;
    min-height: 36px;
  }
  .library-summary {
    align-self: center;
    font-size: 11px;
  }
  .library-toolbar {
    margin-bottom: 22px;
  }
  .library-student-picker {
    gap: 10px;
  }
  .library-student-picker select {
    flex: 1;
    min-width: 0;
    width: auto;
  }
  .library-student-picker > span {
    width: 100%;
    padding-left: 36px;
  }
  .library-grid {
    gap: 22px;
  }
  .library-preview-hint {
    opacity: 1;
    transform: translate(-50%, 0);
    bottom: 10px;
    padding: 6px 10px;
    font-size: 11px;
  }
  dialog.library-preview-dialog {
    width: calc(100vw - 20px);
    max-width: calc(100vw - 20px);
    max-height: calc(100dvh - 20px);
    padding: 18px 14px;
    border-radius: 14px;
  }
  .library-lightbox > img {
    max-height: calc(100dvh - 250px);
  }
  .library-lightbox figcaption {
    align-items: flex-start;
    gap: 12px;
  }
  .library-lightbox .secondary {
    padding: 9px 10px;
    font-size: 12px;
  }
  .library-lightbox strong {
    font-size: 13px;
  }
}

.account-password-panel {
  border-top: 1px solid #3a3a40;
  margin-top: 28px;
  padding-top: 24px;
}
.account-password-panel h3 {
  font-size: 16px;
  margin: 0 0 10px;
  font-weight: 550;
}
.account-password-panel p {
  font-size: 13px;
  line-height: 1.8;
  margin: 0 0 18px;
}
.account-password-panel .secondary {
  margin-top: 18px;
  min-height: 42px;
}
.account-password-panel .error {
  margin-top: 10px;
}
.upstream-monitor {
  padding: 24px;
  margin-bottom: 24px;
  background: #222426;
  border: 1px solid #3b4040;
  border-radius: 14px;
  min-width: 0;
}
.upstream-monitor-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 14px;
  color: #dfe3df;
}
.upstream-monitor-heading .textbtn {
  font-size: 12px;
  color: #c0cfac;
  white-space: nowrap;
}
.upstream-remaining {
  display: flex;
  align-items: baseline;
  gap: 16px;
  flex-wrap: wrap;
  margin: 22px 0;
  color: #a4aaa5;
  font-size: 13px;
}
.upstream-remaining strong {
  font-size: 38px;
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: -1px;
  color: #edf2ea;
  overflow-wrap: anywhere;
}
.upstream-remaining strong small {
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0;
  margin-left: 8px;
  color: #9fa79b;
}
.upstream-remaining.is-low strong {
  color: #efa79d;
}
.upstream-monitor-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  border-top: 1px solid #383d39;
  padding-top: 17px;
}
.upstream-monitor-stats > div {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}
.upstream-monitor-stats span {
  font-size: 12px;
  color: #8f9790;
}
.upstream-monitor-stats b {
  font-size: 20px;
  color: #d9dfd5;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.upstream-monitor .upstream-monitor-breakdown {
  font-size: 12px;
  color: #9aa296;
  margin: 16px 0 0;
  line-height: 1.7;
}
.upstream-monitor .upstream-monitor-caption,
.upstream-monitor .upstream-monitor-pending {
  font-size: 12px;
  line-height: 1.8;
  color: #92968f;
  margin: 12px 0 0;
}
.upstream-monitor .upstream-monitor-pending {
  color: #d6b398;
}
.credits-summary-layout .upstream-monitor {
  margin-bottom: 0;
}
@media (max-width: 700px) {
  .upstream-monitor {
    padding: 20px;
  }
  .upstream-remaining {
    gap: 12px;
    margin: 20px 0;
  }
  .upstream-remaining strong {
    font-size: 32px;
  }
  .upstream-monitor-stats {
    gap: 14px;
  }
  .upstream-monitor-stats b {
    font-size: 18px;
  }
}

.task-charge {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.task-charge-note {
  display: block;
  margin-top: 5px;
  font-size: 11px;
  font-weight: 400;
  color: #8f8f99;
}
.task-billing-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 20px 0 24px;
}
.task-billing-summary > div {
  padding: 16px;
  background: #29292d;
  border: 1px solid #3b3b41;
  border-radius: 10px;
}
.task-billing-summary > div > span {
  display: block;
  font-size: 12px;
  color: #9999a3;
  margin-bottom: 10px;
}
.task-billing-summary strong {
  display: block;
  font-size: 20px;
  font-weight: 550;
  color: #ededf1;
}
.task-billing-summary .task-charge-note {
  font-size: 12px;
}
@media (max-width: 480px) {
  .task-billing-summary {
    gap: 10px;
  }
  .task-billing-summary > div {
    padding: 13px;
  }
  .task-billing-summary strong {
    font-size: 17px;
  }
}

.model-access-group {
  border: 1px solid #3b4039;
  border-radius: 10px;
  padding: 14px;
  margin: 16px 0;
  min-width: 0;
}
.model-access-group legend {
  padding: 0 7px;
  font-size: 14px;
  color: #c6d6b3;
}
.model-access-group .model-access-choice {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
  font-size: 13px;
  line-height: 1.6;
}
.model-access-choice input[type='checkbox'] {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  margin: 0;
  accent-color: #c6e77d;
}

.teacher-allocation-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 24px 0 32px;
  padding: 24px;
}
.teacher-allocation-card strong {
  display: block;
  margin: 12px 0;
  color: #cbe69b;
  font-size: 30px;
}
.teacher-allocation-card strong small {
  font-size: 13px;
  font-weight: 400;
}
.teacher-allocation-card button {
  flex-shrink: 0;
}
@media (max-width: 700px) {
  .teacher-allocation-card {
    align-items: flex-start;
    flex-direction: column;
  }
}
.student-import-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0;
}
.student-import-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 22px;
  margin: 22px 0 15px;
  padding: 16px;
  border: 1px solid #435336;
  border-radius: 10px;
  background: #262e21;
  color: #cfdfbb;
  font-size: 13px;
}
.student-import-preview {
  max-height: 280px;
  overflow: auto;
  border: 1px solid #393d38;
  border-radius: 10px;
}
.student-import-preview table {
  min-width: 680px;
}
dialog.student-import-dialog {
  width: min(960px, calc(100vw - 28px));
  max-width: calc(100vw - 28px);
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
}
