@import url("./homework-batch.css");
#operations {
  min-height: 100dvh;
}
.ops-header {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 10px 22px;
  border-bottom: 1px solid var(--line);
  background: #fff;
  min-height: 60px;
}
.ops-header img {
  width: 140px;
}
.ops-header nav {
  display: flex;
  gap: 4px;
  flex: 1;
}
.ops-header a {
  color: inherit;
  text-decoration: none;
  font-weight: 600;
  padding: 8px;
  border-radius: 8px;
}
.ops-header a[aria-current="page"] {
  background: var(--soft);
  color: var(--accent);
}
.ops-header small {
  color: var(--muted);
}
.ops-content {
  max-width: 1680px;
  margin: auto;
  padding: 18px 22px;
}
.ops-toolbar {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.ops-toolbar h1 {
  font-size: 22px;
  margin: 0 auto 0 0;
}
.ops-toolbar input,
.ops-toolbar select {
  width: auto;
  max-width: 100%;
  min-height: 38px;
}
.ops-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(310px, 390px);
  gap: 18px;
  align-items: start;
}
.ops-list,
.ops-editor,
.ops-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  min-width: 0;
}
.ops-editor {
  padding: 18px;
  position: sticky;
  top: 12px;
  max-height: calc(100dvh - 90px);
  overflow: auto;
}
.ops-editor h2,
.ops-card h2 {
  font-size: 18px;
  margin: 0 0 16px;
}
.ops-editor label {
  display: grid;
  gap: 6px;
  font-weight: 600;
  margin: 12px 0;
}
.ops-editor input,
.ops-editor textarea,
.ops-editor select {
  width: 100%;
  min-width: 0;
  padding: 10px;
  border: 1px solid #bccae0;
  border-radius: 8px;
  background: white;
}
.ops-editor textarea {
  min-height: 88px;
  resize: vertical;
}
.ops-editor button.primary {
  width: 100%;
  margin-top: 12px;
}
.ops-row {
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  padding: 12px 16px;
  min-height: 65px;
}
.ops-row:last-child {
  border-bottom: 0;
}
.ops-row .body {
  flex: 1;
  min-width: 0;
}
.ops-row strong,
.ops-row small {
  display: block;
}
.ops-row small {
  color: var(--muted);
  font-size: 13px;
  margin-top: 5px;
}
.ops-row p {
  margin: 7px 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.ops-row button {
  flex-shrink: 0;
}
.ops-tag {
  display: inline-block;
  font-size: 12px;
  padding: 4px 7px;
  background: var(--soft);
  color: var(--accent);
  border-radius: 5px;
}
.ops-empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--muted);
}
.ops-hint {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.6;
}
.ops-error {
  color: #a12b42;
  background: #fff0f3;
  padding: 10px;
  border-radius: 8px;
  overflow-wrap: anywhere;
}
.ops-card {
  padding: 24px;
}
.ops-login {
  max-width: 460px;
  margin: 7vh auto;
  padding: 28px;
}
.ops-login img {
  width: 160px;
  margin-bottom: 20px;
}
.ops-login h1 {
  font-size: 25px;
}
.ops-login .provider {
  display: block;
  text-align: center;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 9px;
  text-decoration: none;
  color: inherit;
  margin: 12px 0;
  font-weight: 700;
}
.ops-login .kakao {
  background: #fee500;
  color: #191919;
}
.ops-login .provider[aria-disabled="true"] {
  background: #edf0f4;
  color: #687a94;
  pointer-events: none;
}
.ops-login details {
  margin-top: 24px;
}
.ops-login input {
  width: 100%;
  padding: 10px;
  min-width: 0;
}
.ops-login label {
  display: grid;
  gap: 6px;
  margin: 12px 0;
}
.ops-login button {
  margin-top: 8px;
}
.ops-tabs {
  display: flex;
  gap: 6px;
  overflow: auto;
  margin-bottom: 14px;
}
.ops-form-message:empty {
  display: none;
}
.ops-day-buttons {
  display: flex;
  gap: 3px;
}
.ops-day-buttons button {
  padding: 6px 10px;
}
.ops-section-label {
  font-size: 13px;
  color: var(--muted);
  padding: 12px 16px;
  background: #f8faff;
}
.ops-kiosk {
  max-width: 470px;
  margin: 3vh auto;
  text-align: center;
}
.ops-kiosk h1 {
  font-size: 28px;
  margin: 12px 0;
}
.ops-kiosk input {
  font-size: 28px;
  text-align: center;
  width: 100%;
  height: 60px;
  letter-spacing: 12px;
}
.ops-keypad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 14px 0;
}
.ops-keypad button {
  font-size: 25px;
  min-height: 64px;
}
.ops-kiosk .ops-tabs {
  justify-content: center;
}
.ops-kiosk .primary {
  width: 100%;
  min-height: 48px;
}
.ops-secret {
  word-break: break-all;
  white-space: pre-wrap;
  padding: 12px;
  background: #f4f6fa;
  border-radius: 8px;
  font-size: 13px;
}
#ops-status {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  padding: 12px 20px;
  background: #18243c;
  color: white;
  border-radius: 10px;
  max-width: 90vw;
  display: none;
}
#ops-status.visible {
  display: block;
}
.ops-card summary {
  cursor: pointer;
  font-weight: 600;
}
.ops-list button.selected {
  outline: 2px solid var(--accent);
}
@media (max-width: 1000px) {
  .ops-header {
    gap: 10px;
    padding: 10px 14px;
    flex-wrap: wrap;
  }
  .ops-header nav {
    order: 3;
    flex-basis: 100%;
    overflow: auto;
  }
  .ops-header .ops-account {
    margin-left: auto;
  }
  .ops-layout {
    grid-template-columns: minmax(0, 1fr) 320px;
  }
  .ops-content {
    padding: 14px;
  }
}
@media (max-width: 680px) {
  .ops-layout {
    grid-template-columns: 1fr;
  }
  .ops-editor {
    position: static;
    max-height: none;
  }
  .ops-header nav a {
    white-space: nowrap;
  }
  .ops-header small {
    display: none;
  }
  .ops-toolbar {
    gap: 6px;
  }
  .ops-toolbar h1 {
    width: 100%;
    margin-bottom: 4px;
  }
  .ops-toolbar input {
    flex: 1;
    min-width: 120px;
  }
  .ops-row {
    padding: 12px;
  }
  .ops-row button {
    min-height: 44px;
  }
  .ops-login {
    margin: 18px 12px;
  }
  .ops-content {
    padding: 12px;
  }
  .ops-kiosk {
    margin: 14px;
  }
  .ops-day-buttons {
    width: 100%;
    justify-content: space-between;
  }
  .ops-day-buttons button {
    flex: 1;
    min-height: 44px;
  }
  .ops-tabs button {
    min-height: 44px;
  }
  .ops-card {
    padding: 18px;
  }
}

.ops-account-menu {
  position: relative;
  margin-left: auto;
  flex-shrink: 0;
}
.ops-account-menu summary {
  cursor: pointer;
  list-style: none;
  padding: 10px;
  border-radius: 8px;
}
.ops-account-menu > div {
  position: absolute;
  right: 0;
  top: 100%;
  z-index: 20;
  padding: 8px;
  background: white;
  box-shadow: 0 8px 24px #142a4b20;
  border: 1px solid var(--line);
  border-radius: 10px;
  min-width: 160px;
  display: grid;
  gap: 4px;
}
@media (max-width: 680px) {
  .ops-header img {
    width: 116px;
  }
  .ops-header {
    gap: 4px;
  }
  .ops-toolbar h1 {
    width: auto;
    margin: 0 auto 0 0;
  }
  .ops-toolbar {
    margin-bottom: 10px;
  }
  .ops-tabs {
    margin-bottom: 10px;
  }
}
.ops-layout > .ops-list {
  max-height: calc(100dvh - 230px);
  overflow: auto;
  overscroll-behavior: contain;
}
@media (max-width: 680px) {
  .ops-layout > .ops-list {
    max-height: 45dvh;
    min-height: 70px;
  }
}
.server-lessons-layout {
  display: grid;
  grid-template-columns: minmax(210px, 300px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.server-lesson-row {
  display: block;
  width: 100%;
  text-align: left;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: white;
  padding: 13px 14px;
  white-space: normal;
}
.server-lesson-row strong,
.server-lesson-row small {
  display: block;
  overflow-wrap: anywhere;
}
.server-lesson-row small {
  color: var(--muted);
  margin-top: 5px;
  font-weight: 400;
}
.server-lesson-row.selected {
  background: var(--soft);
  box-shadow: inset 3px 0 var(--accent);
}
.server-lesson-editor {
  max-height: calc(100dvh - 240px);
  position: static;
}
.server-lesson-editor fieldset {
  border: 0;
  padding: 0;
  margin: 0;
  min-width: 0;
}
.server-lesson-editor textarea {
  min-height: 74px;
}
.server-lesson-editor pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.server-lesson-actions {
  display: flex;
  gap: 8px;
  position: sticky;
  bottom: -18px;
  background: white;
  padding: 12px 0;
}
.server-lesson-actions button.primary {
  width: auto;
  margin: 0;
}
.lesson-days small {
  margin-left: 5px;
  color: var(--muted);
}
@media (max-width: 700px) {
  .server-lessons-layout {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .server-lesson-list {
    max-height: 190px !important;
  }
  .server-lesson-editor {
    max-height: none;
  }
  .lesson-days {
    display: flex;
    gap: 3px;
  }
  .lesson-days button {
    flex: 1;
    padding: 8px 4px;
  }
  .lesson-days small {
    display: block;
    margin: 2px 0 0;
  }
  .server-lesson-actions {
    bottom: 0;
  }
}

.access-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}
.ops-login label {
  display: grid;
  gap: 6px;
  margin: 14px 0;
  font-weight: 600;
}
.ops-login textarea {
  min-height: 90px;
  resize: vertical;
  width: 100%;
}
.ops-login details {
  margin-top: 20px;
}
.access-pending {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  text-align: left;
  overflow-wrap: anywhere;
}
.access-request-row {
  width: 100%;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  text-align: left;
  background: white;
}
.access-request-row[aria-pressed="true"] {
  background: var(--soft);
  color: var(--accent);
}
.access-request-row strong,
.access-request-row small {
  display: block;
}
.access-request-row small {
  font-size: 12px;
  color: var(--muted);
  margin-top: 5px;
}
[data-family-grant][hidden],
[data-staff-grant][hidden] {
  display: none;
}
