:root {
  --navy: #17263d;
  --ink: #192a40;
  --muted: #536277;
  --line: #dce3ec;
  --bg: #f5f7fa;
  --orange: #b94c1e;
  --sidebar: 216px;
  --gutter: clamp(16px, 3vw, 36px);
  --surface-radius: 10px;
  --control-radius: 8px;
  --control-height: 44px;
  --motion-ease: cubic-bezier(.22, 1, .36, 1);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  color: var(--ink);
  font-size: 15px;
  font-synthesis: none;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); }
a { color: #305f9b; text-decoration: none; }
h1, h2, p { margin: 0; }
p { color: var(--muted); line-height: 1.65; }
small { color: var(--muted); font-size: .84rem; }
:focus-visible { outline: 2px solid #366cba; outline-offset: 3px; }
.skip { position: absolute; top: 8px; left: 10px; padding: 11px 14px; background: white; z-index: 10; transform: translateY(-150%); }
.skip:focus { transform: none; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.app { min-height: 100vh; display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); }
.sidebar {
  position: sticky;
  top: 0;
  align-self: start;
  height: 100vh;
  height: 100dvh;
  overflow-y: auto;
  padding: 26px 17px 20px;
  display: flex;
  flex-direction: column;
  background: var(--navy);
  color: #c1ccda;
}
.brand { display: flex; align-items: center; gap: 11px; margin: 0 0 26px 2px; color: white; font-size: 21px; font-weight: 750; }
.brand small { display: block; color: #c1ccda; font-weight: 500; }
.brand-mark { display: inline-grid; place-items: center; width: 36px; height: 36px; flex: 0 0 auto; border: 1px solid #758399; border-radius: 7px; color: #ff944f; font-size: 24px; line-height: 1; font-weight: 800; }
.sidebar-nav { display: flex; flex: 1; flex-direction: column; gap: 5px; }
.sidebar-nav .account-link { margin-top: auto; margin-bottom: 8px; }
.app-grid-icon { width: 15px; height: 15px; flex: 0 0 auto; color: #f18a46; background: radial-gradient(circle at center, currentColor 1.25px, transparent 1.6px) 0 0 / 5px 5px; }
.nav-link { display: flex; gap: 10px; min-height: 44px; align-items: center; color: #c3cedc; padding: 9px 13px; border-radius: 6px; font-size: .93rem; font-weight: 600; }
.sidebar-nav .shortcut-link { padding-inline-start: 38px; }
.nav-link:hover, .nav-link[aria-current] { color: white; background: #293b53; }
.nav-link[aria-current] { box-shadow: inset 3px 0 #f18a46; }
.sidebar :focus-visible { outline-color: #e5b68f; }
.sidebar-user { padding-top: 16px; display: flex; gap: 8px; align-items: center; border-top: 1px solid #ffffff26; font-size: .84rem; }
.avatar { display: grid; place-items: center; width: 30px; height: 30px; flex: 0 0 auto; border-radius: 50%; background: #32465f; color: #edf4ff; }
.user-meta { min-width: 0; flex: 1; }
.user-meta strong { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #eff4fb; }
.user-meta small { color: #bfcde0; display: block; margin-top: 2px; font-size: .72rem; }
button.sign-out { padding-inline: 7px; color: #e7edf5; background: transparent; border-color: transparent; font-size: .77rem; }
button.sign-out:hover { color: white; background: #293b53; border-color: transparent; }

.main { max-width: 1230px; width: 100%; justify-self: center; padding: clamp(22px, 3vw, 36px) var(--gutter) 48px; outline: none; }
.page-head { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; justify-content: space-between; margin-bottom: clamp(16px, 2vw, 24px); }
h1 { font-size: clamp(23px, 3vw, 28px); line-height: 1.35; font-weight: 750; letter-spacing: -.025em; }
h2 { font-size: 19px; line-height: 1.4; letter-spacing: -.01em; }
.back {
  display: inline-flex;
  min-height: 44px;
  max-width: 100%;
  margin: 0 0 16px;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid #293b53;
  border-radius: 6px;
  background: var(--navy);
  color: white;
  font-weight: 700;
  font-size: .88rem;
  overflow-wrap: anywhere;
}
.back:hover { background: #293b53; }
.back > span:first-child { color: #ffb482; font-size: 1.12rem; }
.back-destination { border-left: 1px solid #748198; padding-left: 8px; color: #e1e8f0; font-weight: 550; }

.panel { border: 1px solid var(--line); background: white; border-radius: var(--surface-radius); }
.app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 148px), 1fr));
  gap: clamp(10px, 1.5vw, 16px);
  max-width: 780px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.app-tile {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 13px;
  min-height: clamp(120px, 12vw, 156px);
  height: 100%;
  padding: 17px 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
  color: var(--ink);
  text-align: center;
  overflow-wrap: anywhere;
  font-weight: 690;
  transition: background-color 140ms, border-color 140ms, box-shadow 160ms, transform 160ms var(--motion-ease);
}
.app-tile:hover { border-color: #c38a64; background: #fffaf6; }
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .app-tile:hover { transform: translateY(-2px); box-shadow: 0 4px 12px #17263d12; }
  .app-tile:active { transform: translateY(0); }
}
.app-symbol {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: #edf1f7;
  color: #365172;
}
.app-symbol > span { position: relative; }
.app-symbol--memos { background: #fbeee5; color: #a3441b; }
.app-symbol--memos > span { width: 27px; height: 20px; border: 2px solid; border-radius: 4px; overflow: hidden; }
.app-symbol--memos > span::after {
  content: "";
  position: absolute;
  top: -10px;
  left: 3px;
  width: 15px;
  height: 15px;
  border: 2px solid;
  border-width: 0 2px 2px 0;
  border-radius: 2px;
  transform: rotate(45deg);
}
.app-symbol--calendar { background: #e8f1fc; color: #28578c; }
.app-symbol--calendar > span { width: 24px; height: 22px; border: 2px solid; border-radius: 4px; }
.app-symbol--calendar > span::before {
  content: "";
  position: absolute;
  top: -5px;
  left: 4px;
  width: 2px;
  height: 7px;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 10px 0 currentColor;
}
.app-symbol--calendar > span::after {
  content: "";
  position: absolute;
  inset: 4px 0 0;
  border-top: 2px solid;
  background: radial-gradient(circle, currentColor 1.2px, transparent 1.4px) center / 6px 5px no-repeat;
}
.app-symbol--board { background: #e8f3ee; color: #306952; }
.app-symbol--board > span { width: 23px; height: 26px; border: 2px solid; border-radius: 4px; }
.app-symbol--board > span::after {
  content: "";
  position: absolute;
  top: 5px;
  left: 4px;
  width: 11px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 0 5px currentColor, 0 10px currentColor;
}
.app-symbol--kbl-studio { background: var(--navy); color: #ff944f; font-size: 16px; font-weight: 800; }
.app-symbol--basol-erp { background: #fbeee5; color: #913b19; font-size: 16px; font-weight: 800; }
.app-empty { max-width: 480px; padding: 22px 24px; }
.app-empty p { margin-top: 6px; }

button, .button { display: inline-flex; justify-content: center; align-items: center; min-height: var(--control-height); padding: 9px 14px; border: 1px solid #cdd7e4; border-radius: var(--control-radius); background: white; color: var(--ink); cursor: pointer; font: inherit; font-weight: 650; font-size: .9rem; transition: background-color 140ms, border-color 140ms, transform 140ms; }
button:hover, .button:hover { background: #edf2f8; border-color: #a6b6ca; }
@media (prefers-reduced-motion: no-preference) {
  button:enabled:active, .button:active { transform: translateY(1px); }
}
.primary { background: var(--orange); border-color: var(--orange); color: white; }
.primary:hover { background: #9e3f18; border-color: #9e3f18; }

.panel table { width: 100%; text-align: left; border-collapse: collapse; }
th, td { padding: 12px clamp(10px, 1.45vw, 18px); border-bottom: 1px solid var(--line); }
thead th { background: #f5f7fa; font-size: .85rem; color: var(--muted); }
thead th:first-child { border-radius: var(--surface-radius) 0 0; }
thead th:last-child { border-radius: 0 var(--surface-radius) 0 0; }
tbody tr:last-child > * { border-bottom: 0; }
tbody th { overflow-wrap: anywhere; }
tbody th small { overflow-wrap: anywhere; display: block; margin-top: 3px; font-weight: 400; }
.table-actions { text-align: right; }
.account-organization { overflow-wrap: anywhere; }
.directory-search { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; max-width: 480px; }
.directory-search :is(button, .button) { flex-shrink: 0; }
.organization-list { display: grid; gap: 16px; }
.organization-list h2 { padding: 14px clamp(12px, 1.45vw, 18px); overflow-wrap: anywhere; }
.organization-list thead th { border-radius: 0; }
.record-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 8px; }
.status { display: inline-block; padding: 4px 8px; background: #edf1f7; border-radius: 4px; color: #43536b; font-size: .8rem; font-weight: 650; }
.status.active { background: #eaf4ed; color: #346448; }

.fields { display: grid; gap: 16px; }
.otp-enrollment-qr { display: grid; justify-items: start; gap: 12px; }
.otp-enrollment-qr :is(h3, p) { margin: 0; }
.otp-enrollment-qr img { display: block; width: 17rem; max-width: 100%; height: auto; image-rendering: pixelated; }
.field { display: grid; gap: 6px; }
.account-form { max-width: 650px; padding: clamp(16px, 2.5vw, 28px); }
label { display: grid; gap: 6px; font-size: .88rem; font-weight: 650; }
label small { font-weight: 400; line-height: 1.5; }
input:not([type="hidden"]), select { width: 100%; min-width: 0; min-height: var(--control-height); padding: 8px 11px; border: 1px solid #cbd5e2; border-radius: var(--control-radius); background: white; color: var(--ink); font: inherit; font-size: 16px; }
input[readonly] { background: #f5f7fa; color: var(--muted); }
.form-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; padding-top: 6px; }
.message { margin: 0 0 14px; padding: 10px 12px; border: 1px solid #dce3ec; border-radius: 6px; background: #f4f7fb; font-size: .88rem; line-height: 1.55; }
.message.success { background: #edf7ef; color: #346448; border-color: #c8dfce; }
.message.error { background: #fff2ef; color: #993b2f; border-color: #edc4bd; }
.message.hint { background: #fff6e9; color: #81511f; border-color: #ead4b6; }
.fields .message { margin: 0; }
.error-panel { max-width: 650px; padding: 24px; }
.error-panel p { margin-bottom: 12px; }

.login-layout { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); }
.login-brand { background: var(--navy); color: white; padding: 32px; display: flex; justify-content: center; align-items: center; }
.login-wordmark { display: grid; width: min(100%, 330px); grid-template-columns: auto 1fr; align-items: center; column-gap: 13px; }
.login-wordmark .brand-mark { grid-row: span 2; width: 54px; height: 54px; font-size: 34px; }
.login-wordmark strong { font-size: 34px; line-height: 1; letter-spacing: -.03em; }
.login-wordmark > span:last-child { color: #c1ccda; font-size: 16px; }
.login-main { display: grid; place-items: center; padding: 24px; outline: none; }
.login-card { width: min(100%, 400px); padding: 29px; border: 1px solid var(--line); border-radius: 8px; background: white; }
.login-card h1 { margin-bottom: 20px; }

@media (max-width: 760px) {
  .app { display: block; }
  .sidebar { position: static; height: auto; padding: 10px 16px 8px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, auto); gap: 8px; align-items: center; }
  .brand { margin: 0; min-height: 44px; }
  .sidebar-nav { grid-column: 1 / -1; grid-row: 2; flex-direction: row; flex-wrap: wrap; }
  .sidebar-nav .nav-link { padding-inline: 9px; }
  .sidebar-nav .account-link { margin: 0 0 0 auto; }
  .sidebar-user { margin: 0; padding: 0; border: none; grid-row: 1; grid-column: 2; }
  .sidebar-user .avatar { display: none; }
  .user-meta { max-width: 100px; }
  .main { padding-bottom: 36px; }
}
@media (max-width: 600px) {
  .app-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 420px; }
  .app-symbol { width: 49px; height: 49px; border-radius: 12px; }
  .panel table, tbody, tbody tr, tbody td, tbody th { display: block; }
  thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  tbody tr { padding: 13px 15px; border-bottom: 1px solid var(--line); }
  tbody tr:last-child { border-bottom: 0; }
  tbody th, tbody td { border: 0; padding: 4px 0; }
  tbody td[data-label] { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
  tbody td[data-label]::before { content: attr(data-label); color: var(--muted); font-size: .86rem; }
  tbody td:has(.account-organization)::before { flex-shrink: 0; }
  .record-actions { justify-content: flex-start; padding-top: 8px; }
  .table-actions:has(> .button) { text-align: left; padding-top: 8px; }
  .login-layout { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .login-brand { justify-content: start; padding: 21px 20px; }
  .login-wordmark .brand-mark { width: 40px; height: 40px; font-size: 25px; }
  .login-wordmark strong { font-size: 23px; }
  .login-wordmark > span:last-child { font-size: 13px; }
  .login-main { align-items: start; padding: 26px 16px; }
  .login-card { padding: 22px; }
}
@media (max-width: 360px) {
  .sidebar { padding-inline: 12px; }
  .user-meta { max-width: 66px; }
  .main { padding-inline: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after, dialog::backdrop { transition: none !important; }
}

.module-dialog { width: min(100% - 32px, 500px); }
.module-dialog header p { margin-top: 5px; }
.module-choices { margin: 0; padding: 0; overflow-y: auto; max-height: 48vh; border: 1px solid var(--line); border-radius: 6px; }
.module-choice { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 8px 12px; cursor: pointer; }
.module-choice + .module-choice { border-top: 1px solid var(--line); }
.module-choice input[type="checkbox"] { width: 18px; min-height: 18px; flex: 0 0 auto; accent-color: var(--orange); }

.work-tabs { display: flex; flex-wrap: wrap; gap: 14px; margin: 0 0 13px; border-bottom: 1px solid var(--line); }
.work-tabs a { display: inline-flex; align-items: center; min-height: 44px; gap: 7px; padding: 6px 9px; border-bottom: 3px solid transparent; color: var(--muted); font-weight: 650; font-size: .9rem; }
.work-tabs a:hover { color: var(--ink); }
.work-tabs [aria-current] { border-color: var(--orange); color: var(--ink); }
.status.unread { color: #894019; background: #fceadf; }
.empty-state { padding: 28px 20px; text-align: center; font-size: .93rem; }
.date-cell { white-space: nowrap; font-variant-numeric: tabular-nums; }
.content-link, button.text-button { color: #254f83; text-align: left; font-weight: 690; overflow-wrap: anywhere; }
.content-link:hover, button.text-button:hover { text-decoration: underline; }
button.text-button { display: inline; min-height: 32px; background: transparent; padding: 3px 0; border: 0; font: inherit; }
.pagination { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 12px; padding: 14px 0 0; color: var(--muted); font-size: .86rem; }
button:disabled { cursor: default; color: #56647a; background: #edf1f6; border-color: #dce3ec; }
textarea { min-width: 0; width: 100%; padding: 10px 11px; border: 1px solid #cbd5e2; border-radius: 6px; color: var(--ink); font: inherit; font-size: 16px; line-height: 1.55; resize: vertical; }
.work-detail, .discussion { max-width: 880px; padding: 23px 24px; }
.work-detail .page-head { margin-bottom: 10px; }
.work-detail h1 { overflow-wrap: anywhere; }
.detail-meta { display: flex; flex-wrap: wrap; gap: 9px 22px; margin: 0; }
.detail-meta div { display: flex; gap: 6px; font-size: .85rem; }
.detail-meta dt { color: var(--muted); flex-shrink: 0; }
.detail-meta dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.content-body { white-space: pre-wrap; overflow-wrap: anywhere; color: var(--ink); }
.work-detail .content-body { margin-top: 19px; padding: 18px 0; border-top: 1px solid var(--line); }
.delete-control summary { width: fit-content; margin-left: auto; padding: 10px 8px; color: #9d3c32; cursor: pointer; font-size: .86rem; font-weight: 650; }
.confirm-form { padding: 4px 0; }
button.danger { color: #9d3029; border-color: #edc4bd; background: #fff4f1; }
button.danger:hover { background: #ffebe6; }
.discussion { margin-top: 14px; }
.comment-list, .agenda ul { list-style: none; margin: 0; padding: 0; }
.comment-list li { border-bottom: 1px solid var(--line); padding: 11px 0; }
.comment-list li:target { background: #fbf2e9; }
.comment-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 0 12px; margin-bottom: 3px; }
.comment-meta .delete-control { margin-left: auto; }
.comment-form { margin-top: 16px; }
.field-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px 12px; }
.field-note { font-size: .82rem; }
label :is(input, select, textarea) { font-weight: 450; }
.checkline { display: flex; align-items: center; gap: 8px; width: fit-content; min-height: 36px; }
.checkline input[type="checkbox"] { width: 17px; min-height: 17px; margin: 0; accent-color: var(--orange); }

.calendar-toolbar { min-height: 64px; padding: 11px 15px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.calendar-toolbar nav { display: flex; gap: 5px; }
.calendar-toolbar nav a { min-width: 39px; padding-inline: 9px; }
.calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.weekday { background: #f5f7fa; text-align: center; padding: 8px 0; color: var(--muted); font-size: .82rem; font-weight: 650; }
.calendar-day { min-width: 0; min-height: 88px; display: grid; grid-auto-rows: max-content; gap: 3px; border-top: 1px solid var(--line); border-right: 1px solid var(--line); padding: 6px; color: var(--ink); font-size: .8rem; }
.calendar-day:nth-child(7n) { border-right: 0; }
.calendar-day:focus-visible { outline-offset: -3px; }
.calendar-day.outside { background: #f7f8fb; color: #6a778b; }
a.calendar-day:hover { background: #f2f6fc; }
.calendar-day[aria-current="date"] { background: #fff5eb; box-shadow: inset 0 0 0 2px #d77038; }
.calendar-number { justify-self: start; display: grid; place-items: center; min-width: 20px; min-height: 20px; }
.today .calendar-number { border-radius: 50%; color: white; background: var(--navy); font-weight: 700; }
.event-chip { display: block; min-width: 0; border-radius: 3px; padding: 2px 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; background: #edf2fb; color: #244578; font-size: .78rem; }
.event-chip.shared { background: #eaf4ed; color: #346448; }
.event-extra { color: var(--muted); }
.event-dot { display: none; }
.agenda { margin-top: 14px; }
.agenda-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 16px; border-bottom: 1px solid var(--line); }
.agenda li { display: grid; grid-template-columns: 53px minmax(0, 1fr) auto; gap: 10px; align-items: center; min-height: 44px; padding: 10px 16px; }
.agenda li + li { border-top: 1px solid var(--line); }
.agenda-time { color: var(--muted); font-size: .84rem; font-variant-numeric: tabular-nums; }

@media (max-width: 600px) {
  .work-detail, .discussion { padding: 16px; }
  .calendar-day { min-height: 43px; padding: 4px; place-items: center; }
  .calendar-number { justify-self: center; }
  .event-chip, .event-extra { display: none; }
  .event-dot { display: block; width: 5px; height: 5px; background: #a0441a; border-radius: 50%; }
}

.page-actions, .board-actions, .day-action-buttons { display: flex; flex-wrap: wrap; align-items: start; gap: 8px; }
.board-actions { justify-content: flex-end; }
.board-description { margin: 0 0 14px; }
dialog {
  --dialog-dim: #17263d76;
  --dialog-offset: translateY(8px) scale(.99);
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
  padding: clamp(16px, 2.5vw, 24px);
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--ink);
  box-shadow: 0 14px 54px #17263d32;
}
dialog::backdrop { background: var(--dialog-dim); }
.work-dialog {
  --dialog-gutter: clamp(14px, 3vw, 24px);
  --dialog-height: calc(100dvh - 32px);
  width: min(100% - 32px, 600px);
  overflow: hidden;
  padding: 0;
}
.work-dialog.day-context {
  position: fixed;
  inset: 8px auto auto 8px;
  margin: 0;
  --dialog-dim: #17263d26;
  --dialog-offset: translateY(4px);
  --dialog-height: calc(100dvh - 16px);
  width: min(100% - 16px, 380px);
  max-height: calc(100dvh - 16px);
}

.work-dialog [data-dialog-content] {
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 34px);
  max-height: calc(var(--dialog-height) - 2px);
}
.dialog-head {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px var(--dialog-gutter);
  border-bottom: 1px solid var(--line);
}
.dialog-head button { flex: 0 0 auto; }
.work-dialog [data-dialog-content] > form { display: flex; flex-direction: column; min-height: 0; gap: 0; }
.work-dialog :is(.work-form-content, .day-dialog-content) {
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 16px var(--dialog-gutter);
  scroll-padding-block: 12px;
}
.work-dialog [data-dialog-content] > form > .form-actions {
  flex: 0 0 auto;
  border-top: 1px solid var(--line);
  padding: 10px var(--dialog-gutter);
}
.work-dialog [aria-busy="true"] button[type="submit"] { cursor: wait; }
@media (max-width: 600px) {
  .work-dialog [data-dialog-content] > form > .form-actions .primary { width: 100%; }
}

@media (prefers-reduced-motion: no-preference) {
  @supports (transition-behavior: allow-discrete) {
    dialog {
      opacity: 0;
      transform: var(--dialog-offset);
      transition: opacity 140ms ease-in, transform 140ms ease-in,
        display 140ms allow-discrete, overlay 140ms allow-discrete;
    }
    dialog[open] {
      opacity: 1;
      transform: none;
      transition-duration: 190ms;
      transition-timing-function: var(--motion-ease);
    }
    dialog::backdrop {
      background: transparent;
      transition: background-color 140ms ease-in, display 140ms allow-discrete, overlay 140ms allow-discrete;
    }
    dialog[open]::backdrop { background: var(--dialog-dim); transition-duration: 190ms; }
    @starting-style {
      dialog[open] { opacity: 0; transform: var(--dialog-offset); }
      dialog[open]::backdrop { background: transparent; }
    }
  }
}
.day-action-list { list-style: none; margin: 12px 0 0; padding: 0; }
.day-action-list li { display: grid; gap: 5px; padding: 10px 0; border-top: 1px solid var(--line); }
@media (max-width: 600px) {
  .board-actions { justify-content: flex-start; }
}

.layout-order {
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: 6px;
}
.layout-order li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  padding: 9px 12px;
}
.layout-order li + li { border-top: 1px solid var(--line); }
.layout-order li > span { color: var(--ink); font-weight: 650; overflow-wrap: anywhere; }
.layout-moves { display: flex; gap: 6px; }
.layout-moves button { padding-inline: 10px; white-space: nowrap; }

@media (max-width: 600px) {
  .personal-tabs { gap: 6px; }
  .personal-tabs a { padding-inline: 6px; }
}

.board-grade-choices { min-width: 0; margin: 12px 0 0; padding: 6px 12px 10px; border: 1px solid var(--line); border-radius: 6px; }
.board-grade-choices legend { padding-inline: 4px; color: var(--ink); font-size: .88rem; font-weight: 650; }
.board-grade-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 166px), 1fr)); gap: 2px 10px; max-height: min(300px, 42vh); overflow-y: auto; overscroll-behavior: contain; }
.board-grade-list .checkline { width: 100%; padding: 4px; cursor: pointer; }
.board-rule:has(option[value="all"]:checked) .board-grade-choices { display: none; }
