/* v8.0 · 직원 라운지 보안 — 이메일 인증 · 기기 · 접근 권한 */
.mdsec-otp { max-width: 560px; margin: 0 auto; display: flex; flex-direction: column; gap: 14px; }
.mdsec-otp h2 { margin: 0; font-size: 1.25rem; }
.mdsec-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; justify-content: space-between; }
.mdsec-code { display: flex; flex-direction: column; gap: 12px; }
.mdsec-code input[name=code] { font-size: 1.6rem; letter-spacing: .4em; text-align: center; min-height: 56px; font-weight: 800; }
.mdsec-keep { display: flex; gap: 8px; align-items: flex-start; font-size: .92rem; line-height: 1.5; }
.mdsec-keep small { color: var(--color-text-mute, #A89685); }
.mdsec-keep input { margin-top: 4px; width: 18px; height: 18px; }
.mdsec-list { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.mdsec-list li { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; padding: 10px 12px; border: 1px solid var(--color-border, #E8DDD3); border-radius: 10px; }
.mdsec-list li small { flex: 1 1 100%; color: var(--color-text-mute, #A89685); }
.mdsec-list li form { margin-left: auto; }
.mdsec-tag { font-size: .72rem; font-weight: 800; padding: 1px 8px; border-radius: 999px; background: var(--color-accent-bg, rgba(143,174,146,.12)); color: var(--color-accent-dark, #6B8F72); }
.mdsec { display: flex; flex-direction: column; gap: 12px; }
.mdsec-nav { display: flex; flex-wrap: wrap; gap: 6px; }
.mdsec-card { display: flex; flex-direction: column; gap: 12px; }
.mdsec-matrix-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.mdsec-matrix { border-collapse: collapse; min-width: 100%; font-size: .85rem; }
.mdsec-matrix th, .mdsec-matrix td { padding: 6px 8px; border-bottom: 1px solid var(--color-border, #E8DDD3); text-align: center; white-space: nowrap; }
.mdsec-matrix thead th { font-size: .76rem; vertical-align: bottom; }
.mdsec-matrix tbody th { text-align: left; position: sticky; left: 0; background: var(--color-bg-card, #fff); }
.mdsec-matrix tbody th small { color: var(--color-text-mute, #A89685); font-weight: 500; }
.mdsec-cell input { width: 20px; height: 20px; }
.mdsec-cell.is-lock { opacity: .35; }
.mdsec-devtable td, .mdsec-devtable th { font-size: .85rem; vertical-align: top; }

/* v9.17 이메일 인증 탭 고르기 */
.mdsec-sens { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px 14px; margin: 8px 0 12px; }

/* v9.54 · 직원 정보 · 권한 — 휴대폰 (원장 지시) */
.mdst-sum { display: none; }
@media (max-width: 760px) {
  /* 탭: 한 줄로 밀어서 보기 */
  .mdsec-nav--staff { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; margin: 0 -4px; padding: 0 4px 2px; }
  .mdsec-nav--staff::-webkit-scrollbar { display: none; }
  .mdsec-nav--staff .mds-tab { flex: none; white-space: nowrap; }
  .mdsec .mds-card { padding: 14px; }

  /* 권한: 계정마다 카드 — 이름 · 등급, 아래에 탭 이름이 붙은 체크 두 줄 */
  .mdsec-matrix-wrap { overflow: visible; }
  .mdsec-matrix tbody tr { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 10px; padding: 12px; }
  .mdsec-matrix tbody th { position: static; grid-column: 1 / -1; padding: 0 0 2px; border: 0; font-size: 1rem; background: transparent; }
  .mdsec-matrix tbody td { display: block; width: auto; padding: 0; border: 0; text-align: left; white-space: normal; }
  .mdsec-matrix tbody td:nth-of-type(1) { grid-column: 1 / -1; margin-bottom: 4px; }
  .mdsec-matrix tbody td:nth-of-type(1) select { width: 100%; min-height: 40px; }
  .mdsec-matrix tbody td[data-l] { display: flex; align-items: center; gap: 8px; min-height: 40px; padding: 6px 10px; border: 1px solid var(--color-border, #E8DDD3); border-radius: 10px; font-size: .86rem; line-height: 1.3; }
  .mdsec-matrix tbody td[data-l]::after { content: attr(data-l); }
  .mdsec-matrix tbody td[data-l] .mdsec-cell { display: flex; flex: none; }
  .mdsec-matrix tbody td[data-l] .mdsec-cell input { width: 20px; height: 20px; margin: 0; }
  .mdsec-matrix tr.is-lock td[data-l] { background: var(--color-surface, #FBF2E8); color: var(--color-text-mute, #A89685); }

  /* 기기 · 열람 기록: 칸 이름표를 앞에, 촘촘하게 */
  .mdsec-devtable tbody tr, .mdsec-views tbody tr { padding: 12px 14px; }
  .mdsec-devtable tbody th { display: block; padding: 0 0 6px; border: 0; font-size: 1rem; }
  .mdsec-devtable td, .mdsec-views td { display: grid !important; grid-template-columns: 76px 1fr; gap: 8px; padding: 3px 0 !important; border: 0 !important; font-size: .86rem; line-height: 1.5; }
  .mdsec-devtable td[data-l]::before, .mdsec-views td[data-l]::before { content: attr(data-l); color: var(--color-text-mute, #A89685); font-size: .78rem; font-weight: 700; }
  .mdsec-devtable td.mdsec-act { display: block !important; padding-top: 8px !important; }
  .mdsec-devtable td.mdsec-act .mds-btn { width: 100%; min-height: 40px; }
  .mdsec-find { flex-wrap: nowrap; }
  .mdsec-find input[name=vq] { flex: 1 1 auto; min-width: 0; min-height: 42px; padding: 8px 12px; border: 1px solid var(--color-border, #E8DDD3); border-radius: 10px; font-size: 16px; }
  .mdsec-find .mds-btn { flex: none; width: auto; min-height: 42px; padding: 0 16px; }

  /* 직원 명단: 한 사람 한 줄 — 누르면 고치기 칸 */
  .mdst-sum { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 48px; padding: 10px 4px; border: 0; background: none; font: inherit; text-align: left; color: inherit; cursor: pointer; }
  .mdst-sum b { font-size: 1rem; }
  .mdst-sum small { color: var(--color-text-mute, #A89685); font-size: .82rem; }
  .mdst-sum__i { margin-left: auto; font-size: 1.3rem; color: var(--color-text-mute, #A89685); transition: transform .15s; }
  .mdst-item.is-open > .mdst-sum .mdst-sum__i, .mdst-new.is-open > .mdst-sum .mdst-sum__i { transform: rotate(90deg); }
  .mdsec-staff-tight, .mdst-rows { gap: 0; }
  .mdst-item, .mdst-item:first-child { padding: 0; }
  .mdst-item:not(.is-open) > :not(.mdst-sum) { display: none !important; }
  .mdst-item.is-open { padding-bottom: 12px; }
  .mdst-new:not(.is-open) > :not(.mdst-title):not(.mdst-sum) { display: none !important; }
  .mdst-new > .mdst-title { margin-bottom: 0; }
  .mdst-sum--new { color: var(--color-primary-dark, #7B4F38); font-weight: 700; }
}
/* v9.90 · 권한 표 한눈에 (원장 지시) — 가로로 넘기지 않게 칸을 좁히고 머리는 두 줄 */
.mdsec-matrix { width: 100%; min-width: 0; table-layout: auto; font-size: .82rem; }
.mdsec-matrix th, .mdsec-matrix td { padding: 4px 3px; }
.mdsec-matrix thead th { white-space: normal; word-break: keep-all; line-height: 1.2; font-size: .72rem; font-weight: 700; color: var(--color-text-sub, #7A6B5F); min-width: 46px; max-width: 74px; vertical-align: bottom; padding-bottom: 8px; }
.mdsec-matrix thead th .mdsec-ico { display: block; font-size: 1.05rem; line-height: 1.3; margin-bottom: 2px; }
.mdsec-matrix thead th .mdsec-lab { display: block; }
.mdsec-matrix thead th.mdsec-h-who, .mdsec-matrix thead th.mdsec-h-grade { text-align: left; max-width: none; }
.mdsec-matrix tbody th { position: static; white-space: nowrap; padding-left: 8px; padding-right: 10px; font-size: .88rem; }
.mdsec-matrix tbody th small { display: block; font-size: .7rem; line-height: 1.2; }
.mdsec-matrix td select { font-size: .8rem; padding: 3px 4px; min-height: 0; height: 30px; max-width: 108px; }
.mdsec-matrix .mdsec-grade { font-size: .74rem; white-space: nowrap; }
.mdsec-cell { display: inline-flex; padding: 4px; cursor: pointer; }
.mdsec-cell input { width: 18px; height: 18px; margin: 0; cursor: pointer; }
.mdsec-matrix tbody tr:hover > * { background: var(--color-surface, #F6F1EA); }
.mdsec-matrix tbody tr:nth-child(5n) > * { border-bottom-color: var(--color-border-strong, #D9CBBE); }
@media (max-width: 900px) {
  .mdsec-matrix { width: auto; min-width: 100%; }
  .mdsec-matrix tbody th { position: sticky; left: 0; z-index: 1; background: var(--color-bg-card, #fff); box-shadow: 1px 0 0 var(--color-border, #E8DDD3); }
}
/* v9.91 · 직원 명단 한눈에 (원장 지시) — 화면 크기와 상관없이 한 사람 한 줄, 누르면 고치기 칸 */
.mdst-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.mdst-stats { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.mdst-stats li { font-size: .86rem; color: var(--color-text-sub, #7A6B5F); background: var(--color-surface, #F6F1EA); border-radius: 999px; padding: 5px 12px; }
.mdst-stats b { font-size: 1.05rem; color: var(--color-text, #3D2F26); margin: 0 2px; }
.mdst-help { flex: 1 1 100%; }
.mdst-help > summary { cursor: pointer; font-size: .82rem; color: var(--color-text-mute, #A89685); }
.mdst-help[open] > summary { margin-bottom: 6px; }
.mdst-bar { display: flex; flex-direction: column; gap: 10px; margin: 2px 0 12px; }
.mdst-q { width: 100%; min-height: 46px; padding: 10px 14px; border: 1px solid var(--color-border, #E8DDD3); border-radius: 12px; font-size: 16px; background: #fff; box-sizing: border-box; }
.mdst-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.mdst-chips small { opacity: .7; margin-left: 2px; }
.mdst-none { margin: 0; color: var(--color-text-mute, #A89685); }
.mdst-dept[hidden], .mdst-item[hidden] { display: none !important; }
.mdst-rows { gap: 0; }
.mdst-item, .mdst-item:first-child { padding: 0; border-top: 1px solid var(--color-border, #EDDFD0); }
.mdst-item:first-child { border-top: 0; }
.mdst-item:not(.is-open) > :not(.mdst-sum) { display: none !important; }
.mdst-item.is-open { padding-bottom: 14px; background: linear-gradient(var(--color-surface, #FBF7F2), transparent 60px); }
.mdst-new:not(.is-open) > :not(.mdst-title):not(.mdst-sum) { display: none !important; }
.mdst-new > .mdst-title { margin-bottom: 0; }
.mdst-sum { display: grid; grid-template-columns: 40px minmax(120px, 1.3fr) 1fr 1fr 1.3fr auto 18px; align-items: center; gap: 12px; width: 100%; min-height: 56px; padding: 8px 6px; border: 0; background: none; font: inherit; text-align: left; color: inherit; cursor: pointer; border-radius: 10px; }
.mdst-sum:hover { background: var(--color-surface, #F6F1EA); }
.mdst-sum--new { display: flex; color: var(--color-primary-dark, #7B4F38); font-weight: 700; min-height: 44px; }
.mdst-sum__ph { width: 40px; height: 40px; border-radius: 50%; overflow: hidden; background: var(--color-surface, #EFE7DE); display: grid; place-items: center; font-weight: 800; color: var(--color-text-sub, #7A6B5F); }
.mdst-sum__ph img { width: 100%; height: 100%; object-fit: cover; }
.mdst-sum__who { display: flex; flex-direction: column; min-width: 0; }
.mdst-sum__who b { font-size: 1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mdst-sum__who small { color: var(--color-text-mute, #A89685); font-size: .8rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mdst-sum__c { font-size: .86rem; color: var(--color-text-sub, #7A6B5F); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mdst-sum__c[data-empty] { color: var(--color-border-strong, #D4C6B8); }
.mdst-acc { font-size: .72rem; font-weight: 800; padding: 3px 9px; border-radius: 999px; white-space: nowrap; justify-self: end; }
.mdst-acc--on { background: rgba(62, 138, 91, .12); color: #2F7A4C; }
.mdst-acc--none { background: #F3EEE8; color: #9A8B7E; }
.mdst-acc--pending { background: #FFF3D6; color: #9A6B00; }
.mdst-acc--shared { background: rgba(52, 120, 200, .12); color: #22598F; }
.mdst-sum__i { font-size: 1.3rem; color: var(--color-text-mute, #A89685); transition: transform .15s; justify-self: end; }
.mdst-item.is-open > .mdst-sum .mdst-sum__i, .mdst-new.is-open > .mdst-sum .mdst-sum__i { transform: rotate(90deg); }
.mdst-item.is-open > .mdst-sum { background: transparent; }
.mdst-item.is-open > :not(.mdst-sum) { margin-top: 6px; }
@media (max-width: 760px) {
  .mdst-sum { grid-template-columns: 40px minmax(0, 1fr) auto 18px; gap: 10px; }
  .mdst-sum__c { display: none; }
  .mdst-chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .mdst-chips .mds-tab { flex: 0 0 auto; }
}
.mdst-mgr-h { margin: 22px 2px 8px; font-size: .95rem; font-weight: 800; color: var(--color-text-sub, #7A6B5F); } /* v9.91 */
.mdst-pend a { font-weight: 700; margin-left: 6px; }

/* v9.172 · 권한 표 항상 한눈에 (원장 지시) — 컴퓨터 화면에서는 가로 스크롤 없이 칸 수대로 폭을 나눔, 칸 이름은 세로로. 탭이 늘면 칸이 조금씩 좁아질 뿐 */
.mdsec-help { margin: 0 0 10px; }
.mdsec-help summary { cursor: pointer; font-size: .86rem; font-weight: 700; color: var(--color-text-sub, #7A6B5F); }
.mdsec-help summary small { font-weight: 500; color: var(--color-text-mute, #A89685); }
.mdsec-help .mds-hint { margin: 6px 0 0; }
@media (min-width: 761px) {
  .mdsec-matrix-wrap { overflow: visible; }
  .mdsec-matrix { table-layout: fixed; width: 100%; min-width: 0; }
  .mdsec-matrix thead th { position: sticky; top: 0; z-index: 2; background: var(--color-bg-card, #fff); min-width: 0; max-width: none; padding: 6px 0 8px; vertical-align: bottom; box-shadow: 0 1px 0 var(--color-border, #E8DDD3); }
  .mdsec-matrix thead th.mdsec-h-who { width: 104px; padding-left: 8px; }
  .mdsec-matrix thead th.mdsec-h-grade { width: 116px; }
  .mdsec-matrix thead th .mdsec-ico { margin: 0 auto 4px; font-size: 1rem; }
  .mdsec-matrix thead th .mdsec-lab { writing-mode: vertical-rl; white-space: nowrap; margin: 0 auto; max-height: 9em; font-size: .74rem; line-height: 1.15; letter-spacing: -.02em; }
  .mdsec-matrix thead th.is-tog { cursor: pointer; border-radius: 8px 8px 0 0; }
  .mdsec-matrix thead th.is-tog:hover, .mdsec-matrix thead th.is-tog:focus { color: var(--color-primary, #2e7d5b); outline: none; }
  .mdsec-matrix tbody th { position: static; overflow: hidden; text-overflow: ellipsis; box-shadow: none; }
  .mdsec-matrix td { padding: 4px 0; overflow: hidden; }
  .mdsec-matrix td select { width: 100%; max-width: 110px; }
  .mdsec-matrix .mdsec-cell { padding: 3px 0; justify-content: center; }
  .mdsec-matrix .is-col { background: rgba(46, 125, 91, .07); }
  .mdsec-matrix tbody tr:hover > .is-col { background: rgba(46, 125, 91, .14); }
}

/* v9.174 · 권한 페이지 다듬기 (원장 지시) — 범례 한 줄 · 간격 · 등급 모양 · 아래 붙는 저장 */
.mdsec-legend { list-style: none; margin: 0 0 18px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 8px; }
.mdsec-legend li { font-size: .8rem; color: var(--color-text-sub, #7A6B5F); background: var(--color-surface, #F6F1EA); border-radius: 999px; padding: 4px 11px; display: inline-flex; align-items: center; gap: 5px; line-height: 1.3; }
.mdsec-legend li b { color: var(--color-text, #3A2E25); font-weight: 700; }
.mdsec-legend__lock { width: 14px; height: 14px; border-radius: 4px; background: #e9e5e0; border: 1px solid #d8d1c9; display: inline-block; }
.mdsec-matrix .mdsec-grade { display: inline-block; font-size: .74rem; font-weight: 700; border-radius: 999px; padding: 3px 10px; background: var(--color-surface, #F6F1EA); color: var(--color-text-sub, #7A6B5F); }
.mdsec-matrix .mdsec-grade--owner { background: #e3f4ea; color: #1f6b45; }
.mdsec-matrix .mdsec-grade--mgr { background: #e8f0fb; color: #22598f; }
.mdsec-matrix td select { border: 1px solid var(--color-border, #E8DDD3); border-radius: 8px; background: #fff; height: 32px; padding: 0 6px; font-size: .8rem; }
.mdsec-matrix .mdsec-lk { display: block; font-size: .68rem; line-height: 1; margin-top: 4px; }
.mdsec-save { position: sticky; bottom: 0; z-index: 3; display: flex; align-items: center; gap: 12px; margin: 16px -4px 0; padding: 12px 4px; background: linear-gradient(to top, var(--color-bg-card, #fff) 75%, rgba(255,255,255,0)); }
.mdsec-save .mds-btn { flex: 0 0 auto; min-width: 180px; min-height: 46px; }
.mdsec-save .mds-btn.is-dirty { box-shadow: 0 0 0 3px rgba(46, 125, 91, .25); }
.mdsec-save small { color: var(--color-text-mute, #A89685); font-size: .8rem; }
@media (min-width: 761px) {
  .mdsec-card { padding: 22px 24px 8px; }
  .mdsec-matrix thead th { padding: 4px 0 10px; }
  .mdsec-matrix thead th.mdsec-h-who, .mdsec-matrix thead th.mdsec-h-grade { padding-left: 12px; font-size: .78rem; vertical-align: bottom; }
  .mdsec-matrix thead th .mdsec-ico { font-size: 1.1rem; margin-bottom: 6px; }
  .mdsec-matrix thead th .mdsec-lab { font-size: .76rem; color: var(--color-text, #3A2E25); }
  .mdsec-matrix tbody th { padding: 10px 6px 10px 12px; font-size: .9rem; }
  .mdsec-matrix tbody th small { margin-top: 1px; }
  .mdsec-matrix td { padding: 6px 0; }
  .mdsec-matrix tbody td:nth-of-type(1) { padding-left: 8px; padding-right: 10px; }
  .mdsec-matrix .mdsec-h-first, .mdsec-matrix .mdsec-c-first { border-left: 1px solid var(--color-border, #E8DDD3); }
  .mdsec-matrix tbody tr:nth-child(even) > * { background: #fcfbf9; }
  .mdsec-matrix tbody tr:hover > * { background: var(--color-surface, #F6F1EA); }
  .mdsec-matrix .mdsec-cell input { width: 17px; height: 17px; accent-color: #2e7d5b; }
  .mdsec-matrix .mdsec-cell input:disabled { opacity: .45; }
}
@media (max-width: 760px) {
  .mdsec-legend { margin-bottom: 12px; }
  .mdsec-legend li:last-child { display: none; }
  .mdsec-save .mds-btn { flex: 1; }
  .mdsec-save small { display: none; }
}

/* v9.194 · 직원 명단 다듬기 (원장 「디자인적으로 개선」) — 표처럼: 칸 이름은 묶음 머리줄에 한 번, 한 사람 한 줄 44px, 이름 · 직책 한 줄, 숫자는 같은 폭, 찾기 · 부서 칩은 한 줄로 붙어 따라옴 */
.mdst .mds-card { padding: 16px 20px; border-radius: 14px; }
.mdst-head.mds-card { padding: 14px 20px; margin-bottom: 10px; }
.mdst-stats li { font-size: .84rem; padding: 4px 11px; }
.mdst-stats b { font-size: 1rem; }
.mdst-bar { position: sticky; top: var(--wp-admin--admin-bar--height, 0px); z-index: 5; display: grid; grid-template-columns: minmax(200px, 300px) 1fr; align-items: center; gap: 8px 14px; margin: 0 0 10px; padding: 8px 0; background: var(--color-bg, #FAF6F1); }
.mdst-bar .mdst-none { grid-column: 1 / -1; }
.mdst-q { min-height: 40px; padding: 8px 14px; border-radius: 10px; font-size: 15px; }
.mdst-chips { gap: 5px; }
.mdst-chips .mds-tab { min-height: 34px; padding: 4px 12px; font-size: .82rem; }
.mdst-dept { margin-bottom: 10px; }
.mdst-dept > .mdst-title { margin: 0 0 2px; font-size: .98rem; }
.mdst-dept > .mdst-title small { font-size: .8rem; }
.mdst-cols, .mdst-sum { display: grid; grid-template-columns: 32px minmax(170px, 1.5fr) .8fr .9fr 1.1fr 92px 16px; align-items: center; gap: 10px; }
.mdst-cols { padding: 8px 6px 6px; border-bottom: 1px solid var(--color-border, #EDDFD0); font-size: .7rem; font-weight: 800; letter-spacing: .03em; color: var(--color-text-mute, #A89685); white-space: nowrap; }
.mdst-cols > span:nth-child(6) { text-align: right; }
.mdst-sum { min-height: 44px; padding: 4px 6px; border-radius: 8px; }
.mdst-item, .mdst-item:first-child { border-top: 1px solid var(--color-border, #F1E8DE); }
.mdst-item:first-child { border-top: 0; }
.mdst-sum__meta { display: contents; }
.mdst-sum__ph { width: 30px; height: 30px; font-size: .82rem; background: var(--color-surface-alt, #F5E8D8); }
.mdst-sum__who { flex-direction: row; align-items: baseline; gap: 8px; }
.mdst-sum__who b { font-size: .94rem; flex: 0 1 auto; }
.mdst-sum__who small { font-size: .78rem; flex: 1 1 auto; }
.mdst-sum__c { font-size: .86rem; font-variant-numeric: tabular-nums; }
.mdst-sum__c[data-empty] { color: var(--color-border-strong, #D4C6B8); }
.mdst-sum__tel { letter-spacing: .01em; }
.mdst-acc { font-size: .7rem; font-weight: 700; padding: 2px 8px; }
.mdst-acc--none { background: transparent; color: var(--color-border-strong, #C9BBAD); border: 0; padding-inline: 0; font-weight: 600; }
.mdst-acc--on::before, .mdst-acc--pending::before, .mdst-acc--shared::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 5px; background: currentColor; vertical-align: 1px; }
.mdst-sum__i { font-size: 1.1rem; }
.mdst-item.is-open > .mdst-sum { background: var(--color-surface, #F6F1EA); border-radius: 8px 8px 0 0; }
.mdst-item.is-open { background: var(--color-surface, #FBF7F2); border-radius: 0 0 8px 8px; margin: 0 -6px; padding: 0 6px 12px; }
.mdst-mgr-h { margin: 18px 2px 8px; font-size: .78rem; letter-spacing: .06em; color: var(--color-text-mute, #A89685); }
.mdst-new > .mdst-title { margin-bottom: 0; }
.mdst-sum--new { min-height: 40px; padding: 4px 6px; }
@media (max-width: 1100px) { .mdst-cols, .mdst-sum { grid-template-columns: 32px minmax(150px, 1.4fr) .8fr .9fr 1.1fr 84px 16px; gap: 8px; } }
@media (max-width: 760px) {
  .mdst-bar { grid-template-columns: 1fr; gap: 6px; padding: 6px 0; }
  .mdst-cols { display: none; }
  .mdst-sum { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto 16px; grid-template-areas: "ph who acc i" "ph meta meta i"; gap: 1px 10px; min-height: 52px; padding: 7px 4px; }
  .mdst-sum__ph { grid-area: ph; align-self: center; }
  .mdst-sum__who { grid-area: who; }
  .mdst-acc { grid-area: acc; }
  .mdst-sum__i { grid-area: i; align-self: center; }
  .mdst-sum__meta { grid-area: meta; display: flex; flex-wrap: wrap; gap: 0 12px; }
  .mdst-sum__c { display: inline; font-size: .78rem; }
  .mdst-sum__c[data-empty] { display: none; }
  .mdst-sum__bd::before { content: "🎂 "; } .mdst-sum__hd::before { content: "🎉 "; } .mdst-sum__tel::before { content: "📞 "; }
  .mdst-item.is-open { margin: 0 -4px; padding: 0 4px 12px; }
}
@media (prefers-color-scheme: dark) {
  .mdst-bar { background: var(--color-bg, #1B1612); }
  .mdst-acc--none { color: var(--color-text-mute, #8A7D70); border-color: var(--color-border, #3A2E24); }
}
/* v9.250 · 휴대폰 손질 (원장 지시 2026-10-20) */
.mdsec-nav--staff { margin-bottom: 10px; } /* 탭 줄이 아래 카드에 붙어 있던 것 */
@media (max-width: 760px) {
  /* 「+ 새 직원 넣기」 — 사진 칸(32px)에 글자가 끼어 한 글자씩 세로로 서던 것 */
  .mdst-sum.mdst-sum--new { display: flex; align-items: center; justify-content: space-between; grid-template-areas: none; }
}
@media (max-width: 600px) {
  /* 내 정보 · 로그인한 기기 — 로그아웃 단추를 오른쪽에 붙여 한 기기 한 덩어리를 낮게 */
  .mdsec-list li { position: relative; padding-right: 118px; min-height: 64px; }
  .mdsec-list li form { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); margin: 0; }
  .mdsec-list li form .mds-btn { min-height: 40px; padding: 6px 14px; width: auto; }
}

/* v9.272 · 직원 메모 (원장 지시) — 고치기 칸 · 계정 칸 아래, 날짜 · 쓴 사람이 남는 메모 */
.mdst-memo-n { font-style: normal; font-weight: 600; font-size: .72rem; color: var(--color-text-mute, #A89685); margin-left: 4px; }
.mdst-item > .mdst-memo { flex: 1 0 100%; order: 11; box-sizing: border-box; margin: 8px 0 0; padding: 10px 12px; border: 1px solid var(--color-border, #EDDFD0); border-radius: 10px; background: #fff; }
.mdst-memo__h { font-size: .8rem; font-weight: 800; color: var(--color-text-sub, #7A6B5F); margin-bottom: 6px; }
.mdst-memo__h small { font-weight: 600; color: var(--color-text-mute, #A89685); margin-left: 2px; }
.mdst-memo__list { list-style: none; margin: 0 0 8px; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.mdst-memo__list li { position: relative; padding: 8px 36px 8px 10px; border-radius: 8px; background: var(--color-surface, #FBF7F2); }
.mdst-memo__meta { font-size: .72rem; color: var(--color-text-mute, #A89685); margin-bottom: 2px; }
.mdst-memo__body { font-size: .9rem; line-height: 1.5; color: var(--color-text, #3D2F26); white-space: normal; word-break: break-word; }
.mdst-memo__del { position: absolute; top: 4px; right: 4px; margin: 0; }
.mdst-memo__del button { width: 32px; height: 32px; border: 0; border-radius: 50%; background: none; color: var(--color-text-mute, #A89685); cursor: pointer; font-size: .9rem; }
.mdst-memo__del button:hover { color: var(--color-danger, #C66B5E); background: rgba(198, 107, 94, .08); }
.mdst-memo__add { display: flex; gap: 8px; align-items: flex-end; margin: 0; }
.mdst-memo__add textarea { flex: 1 1 auto; min-width: 0; min-height: 44px; padding: 8px 10px; font: inherit; font-size: .92rem; line-height: 1.45; border: 1px solid var(--color-border, #EDDFD0); border-radius: 9px; background: #fff; color: var(--color-text, #3D2F26); resize: vertical; box-sizing: border-box; }
.mdst-memo__add .mds-btn { flex: none; min-height: 44px; padding: 0 16px; white-space: nowrap; }
@media (max-width: 640px) { .mdst-memo__add { flex-direction: column; align-items: stretch; } .mdst-memo__add textarea { width: 100%; min-height: 72px; font-size: 16px; } .mdst-memo__add .mds-btn { width: 100%; } }

/* v9.274 · 직원 명단 다듬기 (원장 「디자인 개선 · 모바일 최적화」)
 *  열린 고치기 칸: 사진은 왼쪽 세로 한 칸, 입력칸은 4칸 격자(날짜 · 이메일이 잘리지 않게), 저장은 오른쪽 아래
 *  「사진 지움」 체크가 40px 네모로 커지던 것 · 🗑 단추가 사진 밑에 홀로 떨어지던 것 → 맨 아래 「명단에서 삭제」 글자 단추
 *  「＋ 새 직원 넣기」가 컴퓨터에서도 한 글자씩 세로로 서던 것 */
.mdst .mdst-sum.mdst-sum--new { display: flex; align-items: center; justify-content: space-between; gap: 8px; grid-template-columns: none; grid-template-areas: none; }
.mdst .mdst-item.is-open > .mdst-row,
.mdst .mdst-new.is-open > .mdst-row { flex: 1 0 100%; box-sizing: border-box; display: grid; grid-template-columns: 76px repeat(4, minmax(0, 1fr)); gap: 12px 12px; align-items: end; margin-top: 8px; padding: 14px 14px 12px; border: 1px solid var(--color-border, #EDDFD0); border-radius: 12px; background: var(--color-white, #fff); }
.mdst .mdst-row .mdst-f--photo { grid-column: 1; grid-row: 1 / span 3; align-self: start; align-items: center; gap: 6px; }
.mdst .mdst-row .mdst-f--photo > span:first-child { order: 2; font-size: .7rem; font-weight: 600; letter-spacing: 0; }
.mdst .mdst-row .mdst-photo { width: 64px; height: 64px; }
.mdst .mdst-row .mdst-f--email { grid-column: span 2; }
.mdst .mdst-row .mdst-f > span { font-size: .72rem; letter-spacing: 0; }
.mdst .mdst-row .mdst-f input, .mdst .mdst-row .mdst-f select { min-height: 40px; padding: 6px 10px; font-size: .9rem; box-sizing: border-box; min-width: 0; }
.mdst .mdst-row .mdst-f--chk { grid-column: 2 / span 2; flex-direction: row; align-items: center; gap: 8px; min-height: 40px; font-size: .84rem; color: var(--color-text-sub, #7A6B5F); cursor: pointer; }
.mdst .mdst-row .mdst-f--chk input { flex: none; width: 18px; height: 18px; min-height: 0; margin: 0; padding: 0; accent-color: var(--color-danger, #C66B5E); }
.mdst .mdst-row .mdst-save { grid-column: -2 / -1; justify-self: end; min-width: 120px; min-height: 42px; }
.mdst .mdst-item > .mdst-del { order: 12; flex: 1 0 100%; display: flex; justify-content: flex-end; margin: 6px 0 0; }
.mdst .mdst-del .mdst-delbtn { min-height: 36px; min-width: 0; padding: 0 12px; border: 0; border-radius: 8px; background: none; font-size: .8rem; font-weight: 600; color: var(--color-text-mute, #A89685); }
.mdst .mdst-del .mdst-delbtn:hover { background: rgba(198, 107, 94, .08); color: var(--color-danger, #C66B5E); }
.mdst .mdst-item > .mda-acc { margin: 8px 0 0; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--color-border, #EDDFD0); background: var(--color-white, #fff); }
.mdst .mdst-item.is-open { padding-bottom: 14px; }
@media (max-width: 1100px) {
  .mdst .mdst-item.is-open > .mdst-row, .mdst .mdst-new.is-open > .mdst-row { grid-template-columns: 76px repeat(3, minmax(0, 1fr)); }
  .mdst .mdst-row .mdst-f--photo { grid-row: 1 / span 4; }
}
@media (max-width: 760px) {
  .mdst .mdst-item.is-open > .mdst-row, .mdst .mdst-new.is-open > .mdst-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important; gap: 10px; padding: 12px; }
  .mdst .mdst-row .mdst-f--photo { grid-column: 1 / -1; grid-row: auto; flex-direction: row; justify-content: flex-start; gap: 12px; }
  .mdst .mdst-row .mdst-f--photo > span:first-child { order: 2; font-size: .8rem; }
  .mdst .mdst-row .mdst-photo { width: 56px; height: 56px; }
  .mdst .mdst-row .mdst-f--name, .mdst .mdst-row .mdst-f--email, .mdst .mdst-row .mdst-f--phone, .mdst .mdst-row .mdst-f--chk, .mdst .mdst-row .mdst-save { grid-column: 1 / -1; }
  .mdst .mdst-row .mdst-f input, .mdst .mdst-row .mdst-f select { font-size: 16px; min-height: 44px; }
  .mdst .mdst-row .mdst-save { justify-self: stretch; width: 100%; min-height: 46px; }
  .mdst .mdst-del .mdst-delbtn { min-height: 40px; }
}
