/* Reference scheduling application. All rules remain inside this module. */
.rep-shell { display:grid; grid-template-columns:208px minmax(0,1fr); min-height:calc(100vh - 148px); background:#f8f9fb; border:1px solid #e5e7eb; border-radius:8px; overflow:hidden; font:14px/1.5 Arial,"PingFang SC","Microsoft YaHei",sans-serif; color:#1f2937; }
.rep-shell.menu-collapsed {grid-template-columns:64px minmax(0,1fr)}
.rep-nav {background:#fff;border-right:1px solid #e5e7eb;display:flex;flex-direction:column;min-width:0}
.rep-nav h1 {font-size:16px;line-height:24px;font-weight:600;font-family:inherit;margin:0;height:56px;display:grid;place-items:center;border-bottom:1px solid #e5e7eb}
.rep-nav nav {display:grid;padding:8px 0;gap:0}
.rep-nav nav button {height:40px;display:flex;align-items:center;gap:10px;border:0;border-right:2px solid transparent;border-radius:0;background:transparent;color:#4b5563;padding:0 12px;text-align:left;font:inherit;cursor:pointer;white-space:nowrap}
.rep-nav svg {width:18px;height:18px;flex:none;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.rep-nav nav .active {background:#f0f2ff;border-right-color:#607cf0;color:#5977dc;font-weight:600}
.rep-nav nav button:hover {background:#f3f4f6}
.rep-nav-user {margin-top:auto;border-top:1px solid #e5e7eb;padding:16px;display:grid;gap:3px}
.rep-nav-user strong {font-size:14px;font-weight:600}.rep-nav-user span {font-size:12px;color:#6b7280}
.rep-nav .rep-collapse {height:40px;border:0;border-radius:0;border-top:1px solid #e5e7eb;font-size:20px;color:#9ca3af;background:white}
.menu-collapsed .rep-nav h1 {font-size:13px}.menu-collapsed .rep-nav nav span,.menu-collapsed .rep-nav-user {display:none}.menu-collapsed .rep-nav nav button {justify-content:center;padding:0}
.rep-main {min-width:0;position:relative;overflow:hidden}.rep-content {padding:16px}.rep-recycle-bar {display:flex;justify-content:flex-end;padding:0 16px 10px;font-size:11px}
.rep-shell h2,.rep-dialog h2 {font-size:20px;line-height:28px;margin:0;font-weight:600;letter-spacing:0}
.rep-button {display:inline-flex;align-items:center;justify-content:center;gap:6px;height:34px;min-height:34px;border:1px solid #d1d5db;border-radius:3px;background:white;color:#4b5563;font:14px/1.2 Arial,"PingFang SC",sans-serif;cursor:pointer;padding:0 12px;white-space:nowrap;flex:none;margin:0;box-shadow:none;vertical-align:middle}
.rep-button.primary {color:white;background:#637eef;border-color:#637eef}.rep-button:hover {background:#f3f4f6}.rep-button.primary:hover {background:#526de3}
.rep-button.text {border-color:transparent;background:transparent;color:#5d75d6;padding:0 6px}.rep-button.danger {color:#ef4444}.rep-button:disabled {opacity:.45;cursor:default}
.rep-button.arrow {border:0;background:transparent;font-size:24px;width:32px;padding:0;color:#374151}
.rep-shell input,.rep-shell select,.rep-dialog input,.rep-dialog select,.rep-dialog textarea {font:14px/1.4 Arial,"PingFang SC",sans-serif;color:#1f2937;border:1px solid #d1d5db;border-radius:3px;padding:7px 11px;min-height:36px;background:#fff;margin:0;box-shadow:none;max-width:100%}
.rep-shell select,.rep-dialog select {padding-right:26px}.rep-shell input[type=checkbox],.rep-dialog input[type=radio] {width:14px;height:14px;min-height:0;margin:0;accent-color:#637eef;padding:0}
.rep-shell button:focus-visible,.rep-shell input:focus-visible,.rep-shell select:focus-visible,.rep-dialog :focus-visible {outline:2px solid #637eef;outline-offset:2px}
.rep-monthbar {display:flex;align-items:center;justify-content:space-between;gap:18px;flex-wrap:wrap;min-height:36px}
.rep-month-controls {display:flex;align-items:center;gap:8px;flex:none}.rep-month-controls select {min-height:30px;height:30px;padding:2px 8px;font-weight:600;width:auto}.rep-month-controls h2 {margin-left:18px;white-space:nowrap}
.rep-month-actions {display:flex;align-items:center;gap:10px;flex-wrap:wrap}.rep-month-actions>span {font-size:12px;color:#6b7280;white-space:nowrap}
.rep-weekbar {display:flex;align-items:center;justify-content:space-between;height:50px;font-size:12px;color:#6b7280}
.rep-grid-wrap {width:100%;overflow:auto;border:1px solid #e5e7eb;border-radius:6px;scrollbar-width:thin;background:white}
.rep-grid {border-collapse:collapse;width:100%;min-width:1400px;table-layout:fixed;font-size:11px;margin:0;background:white}
.rep-grid th {height:43px;text-align:left;padding:4px 8px;background:#f8f9fb;border:1px solid #e5e7eb;border-top:0;vertical-align:top;color:#6b7280;font-size:10px;font-weight:600}
.rep-grid th strong {display:block;font-size:14px;line-height:20px;color:#1f2937;font-weight:600}.rep-grid th.today {background:#eef0ff}.rep-grid th.today strong {color:#6078e1}
.rep-grid td {padding:0;vertical-align:top;border:1px solid #e5e7eb;border-top:0;width:200px;background:white;position:relative;overflow-wrap:anywhere}
.rep-grid td:first-child,.rep-grid th:first-child {border-left:0}.rep-grid td:last-child,.rep-grid th:last-child {border-right:0}
.rep-project-row {height:1px}.rep-project-row>td {height:inherit;border-bottom:1px solid #fff}
.rep-card {padding:7px 8px;min-height:66px;height:100%;box-sizing:border-box;cursor:grab;font-size:11px;line-height:18px;position:relative;border-radius:0;box-shadow:none;margin:0}
.rep-card header {display:flex;align-items:start;gap:5px;min-height:18px}.rep-grip {font-size:12px;line-height:18px;color:#9ca3af;flex:none;cursor:grab}
.rep-card-title {background:transparent;padding:0;border:0;color:#1f2937;font:600 14px/18px Arial,"PingFang SC",sans-serif;text-align:left;min-width:0;cursor:pointer;flex:1;overflow-wrap:anywhere}
.rep-color-dot {border:0;background:transparent;line-height:16px;font-size:14px;padding:0;width:14px;height:18px;flex:none;cursor:pointer;filter:brightness(.78);border-radius:50%}
.rep-card-delete {border:0;color:#9ca3af;background:transparent;padding:0;width:12px;height:18px;font:14px/18px Arial;opacity:.35;cursor:pointer;flex:none}.rep-card:hover .rep-card-delete {opacity:1}
.rep-subtitle {font-size:11px;line-height:14px;margin-left:16px;color:#374151;margin-bottom:4px}
.rep-card-entries {display:grid;gap:2px;padding-top:1px}.rep-entry {display:flex;align-items:center;gap:4px;cursor:grab;color:#111827;line-height:16px;font-weight:500;min-height:16px}
.rep-entry small {font-size:10px;color:#4b5563;margin-left:4px;font-weight:400}.rep-entry em {font-style:normal;font-size:9px;padding:1px 3px;margin-left:4px;background:#ffffff60;color:#6b7280;border-radius:3px;font-weight:400}
.rep-entry.pending {color:#6b7280}.rep-entry.external>span {color:#567be7}.rep-entry button {font:11px/14px Arial;margin-left:auto;color:#9ca3af;opacity:0;border:0;background:none;cursor:pointer;padding:0 2px;flex:none}.rep-entry:hover button,.rep-entry:focus-within button {opacity:1}.rep-entry button:hover {color:#ef4444}
.rep-add-cell {height:25px;text-align:center}.rep-add-cell .rep-button {height:25px;min-height:25px;font-size:10px;color:#9ca3af;width:100%}
.rep-grid .rep-seat-row td {background:#d8ecd9;min-height:92px;padding:3px 8px 7px;border-color:#c3e2c5}.rep-grid .rep-leave-row td {background:#f8f9fb;padding:3px 8px 7px}
.rep-pool-title {font-size:10px;line-height:15px;color:#2b5933}.rep-pool-title span {color:#b76b31}.rep-leave-row .rep-pool-title {color:#4b5563}
.rep-persons {display:flex;flex-wrap:wrap;column-gap:6px;row-gap:0;align-content:start;min-height:48px}.rep-leave-row .rep-persons {min-height:18px}
.rep-person {border:0;background:none;padding:0;display:inline-flex;align-items:center;gap:2px;color:#111827;cursor:grab;min-height:16px;font:11px/16px Arial,"PingFang SC",sans-serif;border-radius:0;white-space:nowrap}.rep-person:disabled {opacity:1;cursor:default}.rep-person:hover {text-decoration:underline}.rep-leave-row .rep-person {color:#6b7280!important}
.rep-manual {font-size:8px;opacity:.65}.rep-availability.rep-button {height:20px;min-height:20px;font-size:10px;padding:0;color:#43704b;opacity:.7}.rep-muted {font-size:11px;color:#9ca3af}
.rep-calendar-footer {display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:16px}.rep-calendar-footer>span {font-size:11px;color:#6b7280}.rep-overview {display:grid;gap:16px;margin-top:16px}.rep-grid.overview {min-width:980px}.rep-grid.overview td {width:140px}.rep-grid.overview .rep-card {font-size:10px}.rep-grid.overview .rep-card-title {font-size:12px;line-height:17px}
.rep-section-head {display:flex;align-items:center;justify-content:space-between;gap:16px;margin:4px 0 20px;min-height:34px}.rep-section-head p {margin:4px 0 0;color:#6b7280;font-size:13px}.rep-tabs {display:flex;gap:20px;border-bottom:1px solid #e5e7eb;margin:0 0 20px}.rep-tabs .rep-button {background:transparent;border:0;border-radius:0;height:42px;padding:0 2px;border-bottom:2px solid transparent}.rep-tabs .active {color:#637eef;border-bottom-color:#637eef}
.rep-category {display:flex;gap:8px;flex-wrap:wrap;margin-bottom:16px}.rep-category .active {color:#637eef;background:#eef1ff;border-color:#ccd5fa}
.rep-filters {display:flex;gap:12px;align-items:end;flex-wrap:wrap;margin-bottom:20px}.rep-filters>input {width:250px}.rep-filters>select {max-width:260px;min-width:120px}.rep-filters>label {display:grid;gap:6px;font-size:13px}.rep-filters input[type=number] {width:100px}
.rep-table-wrap {width:100%;overflow:auto;border:1px solid #e5e7eb;border-radius:5px;background:white}.rep-table {width:100%;border-collapse:collapse;font-size:13px;margin:0}.rep-table th {background:#f8f9fb;font-size:12px;font-weight:500;color:#6b7280;text-align:left;padding:11px 14px;border-bottom:1px solid #e5e7eb;white-space:nowrap}.rep-table td {padding:11px 14px;border-bottom:1px solid #edf0f3;text-align:left;vertical-align:middle;max-width:420px}.rep-table tr:last-child td {border-bottom:0}.rep-table td:last-child {white-space:nowrap}.rep-table .rep-button {font-size:12px;height:28px;min-height:28px;padding:0 4px}.rep-table pre {white-space:pre-wrap;max-height:280px;overflow:auto;font:11px/1.5 monospace}.rep-table details summary {white-space:normal;max-width:350px;cursor:pointer;font-size:11px;overflow-wrap:anywhere}
.rep-empty {padding:44px 16px!important;text-align:center!important;color:#9ca3af;font-size:13px}.rep-pagination {display:flex;justify-content:flex-end;align-items:center;gap:6px;margin-top:16px;font-size:12px;color:#6b7280}.rep-pagination>span {margin-right:10px}.rep-pagination .rep-button {height:30px;min-height:30px;font-size:12px;padding:0 10px}.rep-bulk {display:flex;gap:8px;margin-top:16px}
.rep-role-add {display:flex;gap:12px;margin-bottom:20px}.rep-role-add input {width:320px}.rep-role-list {display:grid;gap:0;border:1px solid #e5e7eb;border-radius:5px;background:white;max-width:720px}.rep-role-row {display:flex;align-items:center;gap:12px;padding:8px 14px;border-bottom:1px solid #e5e7eb}.rep-role-row:last-child {border:0}.rep-role-row strong {font-weight:500;margin-right:auto;font-size:13px}.rep-role-row .rep-button {font-size:12px}
.rep-stats {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-bottom:20px}.rep-stats>div {padding:20px;background:#fff;border:1px solid #e5e7eb;border-radius:6px;display:grid;gap:5px}.rep-stats span {color:#6b7280;font-size:12px}.rep-stats strong {font-size:24px;font-weight:600}.rep-settlement-groups {display:flex;flex-wrap:wrap;gap:12px;margin-bottom:20px}.rep-settlement-groups>div {padding:12px 16px;background:#eef1ff;border:1px solid #dce2fc;border-radius:5px;display:grid;gap:4px;min-width:150px}.rep-settlement-groups span {font-size:12px;color:#6b7280}.rep-status {color:#16a34a}.rep-tag {font-size:10px;padding:2px 5px;color:#6b7280;background:#f3f4f6;border-radius:3px;margin-left:5px}
.rep-dialog {padding:0;border:0;border-radius:8px;width:480px;max-width:calc(100vw - 32px);max-height:90vh;background:white;color:#1f2937;box-shadow:0 12px 40px #0002;font:14px/1.5 Arial,"PingFang SC",sans-serif}.rep-dialog.wide {width:720px}.rep-dialog::backdrop {background:#0006}.rep-dialog>header {display:flex;align-items:center;justify-content:space-between;padding:14px 20px;border-bottom:1px solid #e5e7eb}.rep-dialog h2 {font-size:16px;line-height:20px}.rep-dialog header button {font:24px/20px Arial;color:#9ca3af;background:transparent;border:0;cursor:pointer;padding:0}
.rep-dialog form {margin:0}.rep-dialog-body {padding:24px;max-height:calc(90vh - 120px);overflow:auto;position:relative;display:grid;gap:18px}.rep-dialog footer {padding:12px 20px;border-top:1px solid #e5e7eb;display:flex;justify-content:flex-end;gap:8px}.rep-field {display:grid;gap:6px;font-size:14px;min-width:0;margin:0}.rep-field>span {font-weight:500}.rep-field input,.rep-field select {width:100%;min-width:0}.rep-card-form-top {display:grid;grid-template-columns:minmax(0,1.55fr) minmax(0,1fr);gap:16px}.rep-project-picker {display:flex;align-items:center;border:1px solid #d1d5db;background:#f8f9fb;border-radius:3px;min-height:38px}.rep-project-picker input,.rep-project-picker select {border:0;background:transparent;flex:1;min-width:0;padding-right:6px}.rep-project-picker .rep-button {font-size:12px;padding:0 8px}.rep-project-picker .rep-color-dot {margin:0 2px}
.rep-date-field {padding:0;border:0;margin:0;display:grid;align-content:start;gap:8px;min-width:0}.rep-date-field legend {font-weight:500;padding:0;margin-bottom:7px}.rep-date-field>div {display:flex;align-items:center;gap:12px;font-size:13px}.rep-date-field label {display:flex;align-items:center;gap:4px}.rep-date-field input[type=date] {width:100%}
.rep-people-editor {border:1px solid #ccd3e4;background:#fafbff;border-radius:7px;padding:20px;display:grid;gap:12px}.rep-people-editor>strong {font-size:14px;font-weight:600}.rep-editor-entries {border:1px solid #d1d5db;border-radius:5px;background:white;padding:12px;display:grid;gap:6px;min-height:140px;align-content:start}.rep-editor-empty {padding:20px;color:#9ca3af;place-self:center}.rep-editor-entry {display:grid;grid-template-columns:12px minmax(65px,1fr) auto 42px minmax(90px,1fr) minmax(65px,1fr) 38px;gap:6px;align-items:center;min-height:36px}.rep-editor-entry strong {font-size:13px;font-weight:500}.rep-editor-entry em {font-style:normal;font-size:10px;color:#6b7280}.rep-editor-entry .rep-button {font-size:11px;padding:0;border:0}.rep-editor-entry input,.rep-editor-entry select {font-size:12px;width:100%;padding:6px;min-height:32px}.rep-editor-entry:has(>em) {grid-template-columns:12px minmax(65px,1fr) auto 42px minmax(90px,1fr) minmax(65px,1fr) 38px}.rep-editor-entry:not(:has(>em)) {grid-template-columns:12px minmax(65px,1fr) 42px minmax(90px,1fr) minmax(65px,1fr) 38px}
.rep-green {color:#3f7944;font-size:12px}.rep-editor-seat {display:flex;flex-wrap:wrap;gap:6px;border:1px solid #bddabf;background:#fbfffb;border-radius:5px;padding:8px;min-height:40px}.rep-editor-seat button {font:12px/18px Arial;border:0;background:#dff5dd;border-radius:12px;padding:2px 8px;color:#44764c;cursor:pointer}.rep-editor-seat small {font-size:12px;color:#9ca3af}.rep-add-pending {border:1px dashed #cbd0dc;border-radius:4px;background:transparent;color:#6b7280;height:34px;font:14px/1.2 Arial;cursor:pointer}.rep-people-editor input[type=search] {width:100%;border-color:#a9b8ea}.rep-search-results {display:grid;gap:4px;max-height:180px;overflow:auto}.rep-search-results button,.rep-replace-panel [data-pick] {text-align:left;padding:8px;border:1px solid #e5e7eb;background:white;border-radius:3px;font:13px/20px Arial;cursor:pointer}.rep-search-results small,.rep-replace-panel small {color:#6b7280;margin-left:12px}
.rep-more {border:1px solid #e5e7eb;border-radius:4px;font-size:13px}.rep-more summary {padding:8px 12px;cursor:pointer;color:#4b5563}.rep-more>div {padding:12px;display:grid;gap:12px}.rep-error {color:#dc2626;font-size:13px;padding:0 24px 10px}.rep-error:empty {display:none}.rep-hint {font-size:12px;color:#6b7280;margin:0}.rep-copy {width:100%;min-height:300px;font:12px/1.7 monospace!important}
.rep-replace-panel {position:absolute;inset:0;background:white;padding:24px;display:grid;gap:12px;align-content:start;overflow:auto;z-index:3}.rep-replace-panel>div:first-child {display:flex;justify-content:space-between;align-items:center}.rep-replace-panel [data-choices] {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.rep-color-pop {position:fixed;z-index:100;background:white;border:1px solid #e5e7eb;border-radius:6px;box-shadow:0 4px 20px #0002;padding:12px;display:grid;gap:8px;bottom:30px;right:30px;width:210px;font-size:12px}.rep-dialog .rep-color-pop {position:sticky;bottom:0;right:auto;margin-left:auto;z-index:4}.rep-color-pop label {display:grid;gap:6px}.rep-color-pop input {width:100%;height:35px;padding:3px}.rep-color-pop>div {display:flex;gap:5px;flex-wrap:wrap}.rep-color-pop [data-color] {width:20px;height:20px;border:1px solid #d1d5db;border-radius:4px;cursor:pointer}.rep-availability-row {display:flex;justify-content:space-between;align-items:center;gap:20px;padding:6px 0;border-bottom:1px solid #e5e7eb}.rep-availability-row strong {font-weight:500}.rep-availability-row select {width:140px}
.rep-drop {outline:2px solid #637eef!important;outline-offset:-2px;background-image:linear-gradient(#637eef12,#637eef12)!important}
@media(max-width:1100px){.rep-shell{grid-template-columns:160px minmax(0,1fr)}.rep-monthbar{align-items:start}.rep-month-actions{gap:6px}.rep-month-controls h2{margin-left:6px}.rep-stats{gap:8px}.rep-content{padding:12px}}
@media(max-width:700px){.rep-shell{grid-template-columns:64px minmax(0,1fr)}.rep-nav h1{font-size:12px}.rep-nav nav span,.rep-nav-user{display:none}.rep-nav nav button{justify-content:center;padding:0}.rep-content{padding:10px}.rep-month-controls{gap:2px;flex-wrap:wrap}.rep-month-controls h2{font-size:16px;width:100%;margin:6px 0}.rep-month-actions .rep-button{font-size:12px;height:32px;min-height:32px;padding:0 8px}.rep-month-actions>span{font-size:10px}.rep-section-head h2{font-size:18px}.rep-stats{grid-template-columns:1fr}.rep-calendar-footer{align-items:start;flex-wrap:wrap}.rep-dialog-body{padding:16px}.rep-card-form-top{grid-template-columns:1fr}.rep-people-editor{padding:12px}.rep-editor-entries{overflow:auto}.rep-editor-entry{min-width:480px}.rep-replace-panel{padding:16px}.rep-replace-panel [data-choices]{grid-template-columns:1fr}.rep-filters>input{width:100%}.rep-dialog{max-height:94vh}.rep-dialog-body{max-height:calc(94vh - 118px)}}
@media(prefers-reduced-motion:reduce){.rep-shell *,.rep-dialog *{scroll-behavior:auto}}

.rep-nav .rep-logout{justify-content:flex-start;height:36px;border:0;padding:0 16px;color:#4b5563;font-size:13px;background:white}.menu-collapsed .rep-logout{font-size:10px;padding:0 4px}

.rep-dragging,.rep-dragging *{user-select:none;cursor:grabbing!important}.rep-person,.rep-entry,.rep-card,.rep-role-row{touch-action:pan-x pan-y}

.rep-shell [hidden],.rep-dialog [hidden]{display:none!important}.rep-project-picker{height:38px}.rep-project-picker select,.rep-project-picker input{height:36px;min-height:36px}
