:root {
  --sidebar-width: 210px;
  --sidebar-width-collapsed: 60px;
  /* 사이드바 기본 블루 */
  --color-sidebar-bg: #34b6ed;
  --color-sidebar-bg-dark: #2492c0;
  --color-sidebar-border: rgba(255, 255, 255, 0.2);
  --color-sidebar-text: #ffffff;
  --color-sidebar-text-muted: rgba(255, 255, 255, 0.88);
  --color-main-bg: #ffffff;
  --color-surface: #ffffff;
  --color-border: #dde3f0;
  --color-border-subtle: #e5e9f3;
  --color-text-main: #111827;
  --color-text-muted: #6b7280;
  --color-accent: #0f75bd;
  --color-accent-soft: #e5f2ff;
  --color-danger: #e11d48;
  --radius-lg: 14px;
  --radius-md: 10px;
  --radius-pill: 999px;
  --shadow-soft: 0 10px 25px rgba(15, 23, 42, 0.06);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  overflow-x: auto;
  overflow-y: hidden;
}

body {
  min-height: 100vh;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background-color: var(--color-main-bg);
  color: var(--color-text-main);
}

button,
input,
select,
textarea {
  font: inherit;
}

.app {
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  min-height: 100vh;
  height: 100vh;
  min-width: 1280px;
}

.app.sidebar-collapsed {
  grid-template-columns: var(--sidebar-width-collapsed) minmax(0, 1fr);
}

.sidebar {
  display: flex;
  flex-direction: column;
  padding: 16px 14px;
  border-right: 1px solid var(--color-sidebar-border);
  background: linear-gradient(180deg, var(--color-sidebar-bg) 0%, var(--color-sidebar-bg-dark) 100%);
  transition: width 0.22s ease, padding 0.22s ease;
  width: var(--sidebar-width);
  color: var(--color-sidebar-text);
  height: 100vh;
}

.sidebar.collapsed {
  width: var(--sidebar-width-collapsed);
  padding-inline: 8px;
}

.sidebar-top {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 4px;
}

.sidebar-logo {
  width: 100%;
  height: 80px;
  background: url("./img/whiteLogo.png") no-repeat center center;
  background-size: 100% auto;
}

.sidebar.collapsed .sidebar-logo {
  display: none;
}

.sidebar-nav {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 6px;
}

.sidebar.collapsed .sidebar-nav {
  margin-top: 16px;
}

.sidebar-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  border: none;
  background: transparent;
  color: var(--color-sidebar-text-muted);
  font-size: 13px;
  cursor: pointer;
  transition: color 0.16s ease, box-shadow 0.2s ease;
}

.sidebar-item:hover,
.sidebar-item.active {
  color: #ffffff;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.sidebar-item-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  opacity: 0.92;
}

.sidebar-item.active .sidebar-item-icon {
  opacity: 1;
}

.sidebar-icon-svg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
}

.sidebar-icon-svg svg {
  width: 22px;
  height: 22px;
  display: block;
}

.sidebar.collapsed .sidebar-item-label {
  display: none;
}

.sidebar-google-divider {
  height: 1px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  margin: 8px 4px;
}

.sidebar-bottom {
  padding: 8px 4px 0;
}

.sidebar-user {
  font-size: 12px;
  line-height: 1.5;
  color: var(--color-sidebar-text-muted);
  word-break: break-all;
}

.sidebar-logout {
  margin-top: 10px;
  width: 100%;
  padding: 8px 12px;
  font-size: 12px;
  color: var(--color-sidebar-text-muted);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 8px;
  cursor: pointer;
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.sidebar-logout:hover {
  color: var(--color-sidebar-text);
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.5);
}

.sidebar-logout .sidebar-logout-label {
  white-space: nowrap;
}

.sidebar.collapsed .sidebar-logout .sidebar-logout-label {
  display: none;
}

.sidebar-logout .sidebar-logout-icon {
  flex-shrink: 0;
}

.sidebar-logout .sidebar-logout-icon.sidebar-icon-svg svg {
  width: 22px;
  height: 22px;
}

.main {
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  background-color: var(--color-main-bg);
}

.content {
  padding: 20px 32px 32px 16px;
  width: 100%;
  flex: 1;
  min-height: 0;
}

.topbar {
  flex-shrink: 0;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px 0 20px;
  background-color: var(--color-main-bg);
  border-bottom: 1px solid var(--color-border);
  z-index: 10;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topbar-company-name {
  font-size: 12px;
  font-weight: 300;
  color: #4b5563;
}

.topbar-logo {
  display: flex;
  align-items: center;
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  height: 40px;
}

.topbar-logo img {
  height: 36px;
  width: auto;
  object-fit: contain;
  display: block;
}

.topbar-right {
  display: flex;
  align-items: center;
}

.topbar-user {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 10px;
  border-radius: 8px;
  cursor: pointer;
  position: relative;
  color: var(--color-text-main);
}

.topbar-user:hover {
  background-color: var(--color-bg-sub, #f3f4f6);
}

.topbar-user-info {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  line-height: 1.3;
}

.topbar-user-name {
  font-weight: 600;
  font-size: 14px;
}

.topbar-user-title {
  font-size: 12px;
  color: var(--color-text-muted, #6b7280);
}

.topbar-user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  background-color: var(--color-border);
}

.topbar-user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.topbar-avatar-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 600;
  background-color: var(--color-accent);
  color: #fff;
}

.topbar-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 4px;
  min-width: 160px;
  padding: 6px 0;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  z-index: 20;
}

.topbar-dropdown-divider {
  height: 1px;
  margin: 4px 0;
  background-color: #e5e7eb;
}

.topbar-dropdown-logout {
  color: #b91c1c;
}

.topbar-dropdown[hidden] {
  display: none;
}

.topbar-dropdown-item {
  display: block;
  width: 100%;
  padding: 10px 16px;
  border: none;
  background: none;
  text-align: left;
  font-size: 14px;
  color: var(--color-text-main);
  cursor: pointer;
}

.topbar-dropdown-item:hover {
  background-color: var(--color-bg-sub, #f3f4f6);
}

.mypage-layout {
  max-width: 560px;
  margin: 0 auto;
}

.mypage-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 24px 32px;
}

.mypage-profile {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  margin-top: 20px;
}

.mypage-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  background-color: var(--color-border);
}

.mypage-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mypage-avatar-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: 600;
  background-color: var(--color-accent);
  color: #fff;
}

.mypage-info {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 20px;
  margin: 0;
  font-size: 14px;
}

.mypage-info dt {
  color: var(--color-text-muted, #6b7280);
  font-weight: 500;
}

.mypage-info dd {
  margin: 0;
  color: var(--color-text-main);
}

.icon-button {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  background-color: #ffffff;
  color: var(--color-text-main);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 16px;
  transition: background-color 0.12s ease, border-color 0.12s ease, transform 0.06s ease;
}

.icon-button:hover {
  background-color: #f3f4f6;
  border-color: #cbd5f0;
  transform: translateY(-1px);
}

.sidebar .icon-button {
  background-color: rgba(255, 255, 255, 0.12);
  border-color: var(--color-sidebar-border);
  color: var(--color-sidebar-text);
  border-radius: 8px;
}

.sidebar .icon-button:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.4);
}

.sidebar-toggle .sidebar-icon-svg {
  width: 24px;
  height: 24px;
}

.sidebar-toggle .sidebar-icon-svg svg {
  width: 22px;
  height: 22px;
}

/* 햄버거 버튼은 다른 아이콘과 크기만 맞추고, 테두리는 제거 */
.sidebar-toggle.icon-button {
  border: none;
  background: transparent;
  width: 32px;
  height: 32px;
  padding: 0;
}

.page-loading,
.page-error,
.page-empty {
  padding: 24px;
  border-radius: 14px;
  border: 1px solid var(--color-border);
  background: #f9fbff;
  color: var(--color-text-muted);
}

.page-error {
  border-color: #fecdd3;
  background: #fff1f2;
  color: #9f1239;
}

.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
}

.login-card {
  padding: 48px 64px 40px;
  border-radius: var(--radius-lg);
  background: var(--color-surface);
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--color-border);
  text-align: center;
}

.login-logo {
  max-width: 260px;
  width: 100%;
  height: auto;
  margin-bottom: 32px;
}

.login-google-button {
  display: inline-block;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 500;
  color: #fff;
  background: #4285f4;
  border-radius: 8px;
  text-decoration: none;
  transition: background 0.15s ease, box-shadow 0.15s ease;
}

.login-google-button:hover {
  background: #3367d6;
  box-shadow: 0 2px 8px rgba(66, 133, 244, 0.35);
}

.home-staff-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: start;
  min-height: 0;
}

.home-staff-section {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 0;
  border: 1px solid var(--color-border, #e0e0e0);
  border-radius: var(--radius-lg, 8px);
  background: var(--color-surface, #fff);
  padding: 1rem;
}

.home-staff-heading {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0 0 0.75rem 0;
  color: var(--color-text, #1a1a1a);
  flex-shrink: 0;
}

.home-staff-content {
  flex: 1;
  min-height: 0;
  max-height: calc(100vh - 180px);
  overflow: auto;
}

.card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  box-shadow: var(--shadow-soft);
}

.attendance-layout {
  display: grid;
  grid-template-columns: 304px 1fr;
  gap: 24px;
  min-height: calc(100vh - 40px);
  min-width: 1200px;
}

.attendance-left {
  min-width: 304px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.attendance-right {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.attendance-right-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--color-border-subtle);
}

.attendance-right-title {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: var(--color-text-main);
}

.attendance-right-profile {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.profile-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--color-border-subtle);
}

.profile-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  background: var(--color-accent);
  border: 2px solid var(--color-border-subtle);
}

.left-main-card {
  padding: 20px;
  height: 100%;
  border-right: 1px solid var(--color-border-subtle);
}

.left-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 18px;
}

.page-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.page-title {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: var(--color-text-main);
}

.page-subtitle,
.left-date,
.field-label,
.hint-text,
.week-header-hours,
.month-work-card-title {
  color: var(--color-text-muted);
}

.left-date,
.left-time {
  white-space: nowrap;
}

.left-time {
  font-size: clamp(22px, 4.5vw, 42px);
  font-weight: 700;
  color: var(--color-text-main);
  letter-spacing: -0.02em;
}

.attendance-status-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  border: 1px solid transparent;
}

.attendance-status-badge.status-none {
  background-color: #f3f4f6;
  color: #4b5563;
  border-color: #e5e7eb;
}

.attendance-status-badge.status-working {
  background-color: #dcfce7;
  color: #166534;
  border-color: #22c55e;
}

.attendance-status-badge.status-off {
  background-color: #e0f2fe;
  color: #075985;
  border-color: #38bdf8;
}

.left-metrics {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 18px;
}

.metric-note {
  margin-top: 4px;
  font-size: 12px;
  color: #6b7280;
}

.metric-card {
  border-radius: 10px;
  border: 1px solid var(--color-border);
  background-color: #f9fbff;
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.metric-label {
  font-size: 12px;
  color: var(--color-text-muted);
}

.metric-value {
  font-size: 14px;
  font-weight: 700;
  color: var(--color-text-main);
  white-space: nowrap;
}

.attendance-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.attendance-buttons {
  display: flex;
  gap: 8px;
}

.attendance-buttons .btn {
  flex: 1;
  justify-content: center;
}

select:focus,
input[type="text"]:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 1px rgba(15, 117, 189, 0.35);
}

.btn {
  border-radius: var(--radius-pill);
  border: 1px solid var(--color-border);
  background-color: #ffffff;
  color: var(--color-text-main);
  font-size: 13px;
  padding: 9px 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background-color 0.12s ease, border-color 0.12s ease, transform 0.06s ease, box-shadow 0.1s ease;
}

.btn.primary {
  border-color: var(--color-accent);
  background-color: var(--color-accent);
  color: #ffffff;
  font-weight: 600;
}

.btn.secondary {
  border-color: #10b981;
  background-color: #10b981;
  color: #ffffff;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(148, 163, 184, 0.35);
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.status-card,
.calendar-card,
.admin-filters-card,
.admin-table-card {
  padding: 18px 20px;
}

.admin-tabs-card {
  padding-bottom: 8px;
}

.admin-tabs {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: #e5f2ff;
}

.admin-tab {
  border: none;
  background: transparent;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 13px;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: background 0.12s ease, color 0.12s ease;
}

.admin-tab.active {
  background: #ffffff;
  color: var(--color-accent);
  font-weight: 600;
}

.admin-memo {
  margin-right: 8px;
}

.admin-delete-button {
  padding: 4px 8px;
  font-size: 11px;
  border-radius: 999px;
  border: 1px solid #fecaca;
  background: #fef2f2;
  color: #b91c1c;
  cursor: pointer;
}

.admin-delete-button:hover {
  background: #fee2e2;
  border-color: #fca5a5;
}

.admin-users-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.admin-users-controls input {
  flex: 1;
}

.admin-users-table th:nth-child(1),
.admin-users-table td:nth-child(1) {
  width: 22%;
}

.admin-users-table th:nth-child(2),
.admin-users-table td:nth-child(2) {
  width: 14%;
}

.admin-users-table th:nth-child(3),
.admin-users-table td:nth-child(3),
.admin-users-table th:nth-child(4),
.admin-users-table td:nth-child(4) {
  width: 14%;
}

.admin-users-table th:nth-child(5),
.admin-users-table td:nth-child(5),
.admin-users-table th:nth-child(6),
.admin-users-table td:nth-child(6) {
  width: 10%;
}

.admin-users-table th:nth-child(7),
.admin-users-table td:nth-child(7) {
  width: 16%;
}

.admin-seats-card {
  overflow: hidden;
}

.admin-seats-header {
  align-items: flex-start;
}

.admin-seat-description {
  margin: 6px 0 0;
  font-size: 13px;
  color: var(--color-text-muted);
}

.admin-seats-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 360px;
}

.admin-seats-actions input {
  flex: 1;
}

.admin-seats-layout {
  display: grid;
  grid-template-columns: minmax(560px, 1.25fr) minmax(340px, 0.9fr);
  gap: 18px;
  align-items: start;
  margin-top: 16px;
}

.admin-seats-list-panel,
.admin-seats-preview-panel,
.admin-seat-editor-panel {
  border: 1px solid var(--color-border);
  border-radius: 14px;
  background: #f8fbff;
}

.admin-seats-preview-panel {
  padding: 14px;
}

.admin-seats-preview-head {
  margin-bottom: 12px;
}

.admin-seats-preview-title,
.admin-seat-editor-head h4 {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
}

.admin-seats-preview-hint,
.admin-seat-editor-head p,
.admin-seat-modal-subtitle {
  margin: 6px 0 0;
  font-size: 12px;
  color: var(--color-text-muted);
}

.admin-seats-table th:nth-child(1),
.admin-seats-table td:nth-child(1) {
  width: 18%;
}

.admin-seats-table th:nth-child(2),
.admin-seats-table td:nth-child(2) {
  width: 24%;
}

.admin-seats-table th:nth-child(3),
.admin-seats-table td:nth-child(3),
.admin-seats-table th:nth-child(4),
.admin-seats-table td:nth-child(4) {
  width: 14%;
}

.admin-seats-table th:nth-child(5),
.admin-seats-table td:nth-child(5) {
  width: 10%;
}

.admin-seats-table th:nth-child(6),
.admin-seats-table td:nth-child(6) {
  width: 20%;
}

.admin-seat-row-selected td {
  background: #eef6ff !important;
}

.admin-seat-canvas,
.admin-seat-editor-canvas {
  position: relative;
  width: 100%;
  min-height: 420px;
  border-radius: 14px;
  overflow: hidden;
  background:
    linear-gradient(rgba(148, 163, 184, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.08) 1px, transparent 1px),
    linear-gradient(135deg, #f8fbff 0%, #eef6ff 100%);
  background-size: 24px 24px, 24px 24px, auto;
  border: 1px dashed rgba(148, 163, 184, 0.55);
}

.admin-seat-editor-canvas {
  min-height: 340px;
  cursor: grab;
}

.admin-seat-canvas-empty {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  font-size: 13px;
}

.admin-seat-block {
  position: absolute;
  border: 1px solid #2563eb;
  background: rgba(191, 219, 254, 0.78);
  border-radius: 12px;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  text-align: left;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.12);
  color: #1e3a8a;
}

.admin-seat-block.is-empty {
  border-style: dashed;
  background: rgba(255, 255, 255, 0.75);
  color: #475569;
}

.admin-seat-block.is-selected {
  border-width: 2px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.18);
}

.admin-seat-block.is-muted {
  opacity: 0.5;
}

.admin-seat-block.is-draft {
  z-index: 2;
  background: rgba(66, 133, 244, 0.9);
  color: #ffffff;
  cursor: grab;
}

.admin-seat-block-name {
  font-size: 13px;
  font-weight: 700;
}

.admin-seat-block-user {
  font-size: 11px;
  line-height: 1.3;
  opacity: 0.95;
}

.admin-seat-modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 60;
  padding: 24px;
}

.admin-seat-modal[hidden] {
  display: none;
}

.admin-seat-modal-dialog {
  width: min(1080px, calc(100vw - 48px));
  max-height: calc(100vh - 48px);
  overflow: auto;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.28);
}

.admin-seat-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 20px 22px 0;
}

.admin-seat-modal-title {
  margin: 0;
  font-size: 20px;
}

.admin-seat-modal-close {
  border: none;
  background: #eef4ff;
  color: var(--color-text-main);
  width: 36px;
  height: 36px;
  border-radius: 999px;
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}

.admin-seat-modal-body {
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(380px, 1.05fr);
  gap: 18px;
  padding: 18px 22px 0;
}

.admin-seat-form-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.admin-seat-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
}

.admin-seat-field-checkbox {
  flex-direction: row;
  align-items: center;
  gap: 8px;
  padding-top: 4px;
}

.admin-seat-field-checkbox input {
  width: 16px;
  height: 16px;
}

.admin-seat-range-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.admin-seat-input-pair {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 8px;
  align-items: center;
}

.admin-seat-input-pair input[type="number"] {
  border-radius: 10px;
}

.admin-seat-input-pair input[type="range"] {
  width: 100%;
}

.admin-seat-editor-panel {
  padding: 14px;
}

.admin-seat-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 18px 22px 22px;
}

.card-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.card-title {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
}

.status-profile-dot {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  background: linear-gradient(135deg, #f97316, #facc15);
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.summary-item {
  padding: 12px;
  border-radius: 12px;
  background: #f8fbff;
  border: 1px solid var(--color-border-subtle);
}

.summary-value {
  margin-top: 6px;
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text-main);
}

.calendar-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 16px;
}

.calendar-title {
  min-width: 88px;
  text-align: center;
  font-size: 15px;
  font-weight: 700;
  color: var(--color-text-main);
}

.month-work-card {
  margin: 0 0 16px 0;
  padding: 14px 18px;
  border-radius: 10px;
  border: 1px solid var(--color-border-subtle);
  background-color: #f9fbff;
}

.month-work-card-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.month-work-guideline {
  font-size: 13px;
  color: var(--color-text-muted);
}

.month-work-total {
  white-space: nowrap;
  font-size: 26px;
  font-weight: 700;
  color: var(--color-accent);
}

.month-work-gauge-wrap {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.month-work-gauge {
  height: 12px;
  border-radius: 999px;
  background: #f8fafc;
  border: 1px solid var(--color-border-subtle);
  overflow: hidden;
}

.month-work-gauge-inner {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #22c55e, #eab308);
  transition: width 0.2s ease;
}

.month-work-gauge-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--color-text-muted);
}

.month-work-remaining {
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.6;
}

.month-work-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  font-size: 13px;
  color: var(--color-text-main);
}

.month-work-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.month-work-legend .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.month-work-legend .dot-basic {
  background: #22c55e;
}

.month-work-legend .dot-overtime {
  background: #eab308;
}

.weekly-section-title {
  margin: 0 0 10px 0;
  font-size: 14px;
}

.weekly-overview {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.week-block {
  border-radius: 10px;
  border: 1px solid var(--color-border-subtle);
  background-color: #f9fbff;
}

.week-header {
  width: 100%;
  padding: 10px 12px;
  border: none;
  background: transparent;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
}

.week-header-label {
  font-weight: 700;
}

.week-body {
  padding: 0 0 12px;
}

.attendance-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  table-layout: fixed;
}

.attendance-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  table-layout: fixed;
}

.attendance-table th,
.attendance-table td {
  padding: 10px 12px;
  text-align: left;
  white-space: nowrap;
}

.attendance-table thead tr {
  border-bottom: 2px solid var(--color-border-subtle);
}

.attendance-table th {
  font-weight: 600;
  color: var(--color-text-muted);
  background: #f8fafc;
}

.attendance-table tbody tr.attendance-table-row {
  cursor: pointer;
}

.attendance-table tbody tr.attendance-table-row:hover {
  background: #f1f5f9;
}

.attendance-table tbody tr.attendance-table-row.day-row-selected {
  background: #eff6ff;
  outline: 2px solid var(--color-accent);
  outline-offset: -2px;
}

.attendance-timeline-row {
  background: #f8fafc;
}

.attendance-timeline-row.day-row-selected {
  background: #eff6ff;
  outline: 2px solid var(--color-accent);
  outline-offset: -2px;
}

.attendance-timeline-cell {
  padding: 12px !important;
  vertical-align: top;
}

.attendance-timeline-wrap {
  padding-top: 8px;
}

.day-row-combined {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.day-row-header-grid {
  display: grid;
  grid-template-columns: 1.5fr 1.5fr 1.5fr 1.5fr 1.5fr 1.5fr 1.5fr;
  align-items: center;
}

.day-row-header-grid .day-cell {
  white-space: nowrap;
}

.day-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 24px;
}

.day-weekday {
  color: var(--color-text-muted);
  margin-left: 2px;
}

.day-number-today {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 24px;
  border-radius: 999px;
  background: var(--color-accent-soft);
  color: var(--color-accent);
  font-weight: 700;
}

.attendance-timeline {
  width: 100%;
}

.timeline-hours {
  position: relative;
  height: 20px;
  margin-bottom: 4px;
}

.timeline-hour {
  position: absolute;
  transform: translateX(-50%);
  font-size: 11px;
  color: var(--color-text-muted);
}

.timeline-track {
  position: relative;
  height: 36px;
  background: transparent;
}

.timeline-tick {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 0;
  border-left: 1px dotted #cbd5e1;
  transform: translateX(-1px);
}

.timeline-bar {
  position: absolute;
  top: 6px;
  bottom: 6px;
  border-radius: 4px;
  min-width: 4px;
}

.sidebar-staff-button {
  width: 100%;
  border: none;
  background: transparent;
  color: inherit;
  padding: 8px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  border-radius: 10px;
  transition: background-color 0.15s ease, box-shadow 0.15s ease;
  margin-bottom: 8px;
}

.sidebar-staff-button:hover {
  background: rgba(148, 163, 184, 0.08);
}

.sidebar-staff-label {
  font-size: 14px;
}

.sidebar.collapsed .sidebar-staff-label {
  display: none;
}

.staff-overlay {
  position: fixed;
  inset: 0;
  background: rgba(17, 24, 39, 0.25);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 40;
}

.staff-overlay.open {
  display: flex;
}

.staff-panel {
  width: min(960px, calc(100vw - 32px));
  max-height: 80vh;
  background: var(--color-surface);
  color: var(--color-text-main);
  border-radius: 18px;
  box-shadow: var(--shadow-soft), 0 0 0 1px var(--color-border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.staff-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--color-border);
}

.staff-panel-title {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--color-text-main);
}

.staff-view-toggle {
  margin-top: 10px;
  display: inline-flex;
  gap: 6px;
  padding: 4px;
  border-radius: 999px;
  background: var(--color-border-subtle);
  border: 1px solid var(--color-border);
}

.staff-view-button {
  border: none;
  background: transparent;
  color: var(--color-text-muted);
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
}

.staff-view-button.active {
  background: var(--color-accent-soft);
  color: var(--color-accent);
}

.staff-panel-close {
  border: none;
  background: transparent;
  padding: 4px;
  border-radius: 999px;
  cursor: pointer;
  color: var(--color-text-main);
}

.staff-panel-close:hover {
  background: var(--color-border-subtle);
}

.staff-panel-body {
  padding: 12px 18px 16px;
  overflow: auto;
}

.staff-search-row {
  margin-bottom: 10px;
}

.staff-search-input {
  width: 100%;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  padding: 7px 14px;
  font-size: 13px;
  background: var(--color-surface);
  color: var(--color-text-main);
}

.staff-search-input::placeholder {
  color: var(--color-text-muted);
}

.staff-panel-content,
.staff-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.staff-loading,
.staff-empty,
.staff-error {
  font-size: 13px;
  color: var(--color-text-muted);
}

.staff-dept-section {
  border-radius: 12px;
  background: var(--color-accent-soft);
  border: 1px solid var(--color-border);
  overflow: hidden;
}

.staff-dept-header {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin: 0;
  padding: 8px 10px;
  border: none;
  border-radius: 0;
  background: transparent;
  cursor: pointer;
  font: inherit;
  color: var(--color-text-main);
  text-align: left;
  transition: background 0.15s ease;
}

.staff-dept-header:hover {
  background: rgba(15, 117, 189, 0.08);
}

.staff-dept-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.staff-dept-chevron svg {
  width: 16px;
  height: 16px;
}

.staff-dept-section.staff-dept-section--collapsed .staff-dept-chevron {
  transform: rotate(-90deg);
}

.staff-dept-title {
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--color-text-main);
}

.staff-dept-count {
  margin-left: auto;
  font-size: 11px;
  font-weight: 500;
  color: var(--color-text-muted);
}

.staff-dept-list {
  list-style: none;
  margin: 0;
  padding: 4px 10px 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: opacity 0.15s ease;
}

.staff-dept-section.staff-dept-section--collapsed .staff-dept-list {
  display: none;
}

.staff-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 6px;
  border-radius: 8px;
}

.staff-item + .staff-item {
  border-top: 1px dashed var(--color-border);
}

.staff-item-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.staff-item-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.staff-item-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--color-text-main);
}

.staff-item-title {
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 999px;
  background: var(--color-accent-soft);
  color: var(--color-accent);
}

.staff-item-meta {
  font-size: 11px;
  color: var(--color-text-muted);
}

.staff-item-status-wrap {
  display: flex;
  align-items: center;
}

.staff-item-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 70px;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
}

.staff-status-미출근 {
  background: var(--color-border-subtle);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
}

.staff-status-근무중 {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.staff-status-퇴근완료 {
  background: var(--color-accent-soft);
  color: var(--color-accent);
  border: 1px solid #93c5fd;
}

.staff-status-미배정 {
  background: var(--color-border-subtle);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
}

.staff-seat-board {
  position: relative;
  min-height: 520px;
  border-radius: 16px;
  overflow: auto;
  background:
    linear-gradient(var(--color-border-subtle) 1px, transparent 1px),
    linear-gradient(90deg, var(--color-border-subtle) 1px, transparent 1px),
    var(--color-surface);
  background-size: 28px 28px, 28px 28px, auto;
  border: 1px solid var(--color-border);
}

.staff-seat-card {
  position: absolute;
  border-radius: 12px;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  border: 1px solid transparent;
  box-shadow: var(--shadow-soft);
}

.staff-seat-before {
  background: var(--color-border-subtle);
  border-color: var(--color-border);
  color: var(--color-text-main);
}

.staff-seat-working {
  background: #dcfce7;
  border-color: #86efac;
  color: #15803d;
}

.staff-seat-done {
  background: var(--color-accent-soft);
  border-color: #93c5fd;
  color: var(--color-accent);
}

.staff-seat-empty {
  background: var(--color-surface);
  border-color: var(--color-border);
  color: var(--color-text-muted);
}

.staff-seat-card-name {
  font-size: 13px;
  font-weight: 700;
  color: inherit;
}

.staff-seat-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.staff-seat-card-title {
  font-size: 12px;
  line-height: 1.3;
  opacity: 0.9;
}

.staff-seat-card-user {
  font-size: 12px;
  line-height: 1.3;
}

.staff-seat-card-meta {
  min-height: 0;
  font-size: 11px;
}

.staff-seat-card-status {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 70px;
}

.timeline-bar-work {
  background: linear-gradient(90deg, #0ea5e9, #22c55e);
}

.timeline-bar-label {
  position: absolute;
  left: 6px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
}

.admin-layout {
  display: grid;
  gap: 16px;
}

.admin-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 180px;
}

select,
input[type="text"] {
  border-radius: var(--radius-pill);
  border: 1px solid var(--color-border);
  background-color: #ffffff;
  color: var(--color-text-main);
  font-size: 12px;
  padding: 8px 12px;
}

.table-wrapper {
  margin-top: 16px;
  border-radius: 10px;
  border: 1px solid var(--color-border);
  overflow: auto;
  background-color: #ffffff;
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.table thead {
  background-color: #f3f6fb;
}

.table th,
.table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--color-border-subtle);
  text-align: left;
  white-space: nowrap;
}

.table th {
  font-weight: 600;
  color: var(--color-text-muted);
}

.table tbody tr:nth-child(even) td {
  background-color: #fafbff;
}

.table-empty {
  text-align: center;
  color: var(--color-text-muted);
}

.calendar-card[hidden],
.attendance-leave-panel[hidden] {
  display: none;
}

/* 모바일/태블릿 전환은 사용하지 않음.
   화면을 줄여도 항상 데스크탑 레이아웃을 유지하고,
   필요 시 브라우저 가로 스크롤로 보도록 한다. */

.approval-layout {
  display: grid;
  grid-template-columns: 304px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  min-height: calc(100vh - 40px);
  min-width: 1200px;
}

.approval-sidebar {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.approval-sidebar-head,
.approval-form-header,
.approval-modal-header,
.approval-modal-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.approval-form-list,
.approval-approver-list,
.approval-approver-options,
.approval-selected-approvers,
.admin-leave-approver-options,
.admin-leave-approver-selected {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.approval-form-item {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid var(--color-border);
  background: var(--color-accent-soft);
  cursor: pointer;
}

.approval-form-title {
  font-weight: 700;
}

.approval-form-caption,
.approval-pending-hint,
.approval-year-filter span,
.attendance-leave-year span {
  color: var(--color-text-muted);
  font-size: 12px;
}

.approval-balance-card,
.attendance-leave-cards,
.approval-documents-grid,
.approval-approver-picker,
.admin-leave-approvers-layout {
  display: grid;
  gap: 18px;
}

.approval-balance-card,
.attendance-leave-cards {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.approval-balance-item {
  padding: 14px;
  border-radius: 12px;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.approval-balance-item span {
  font-size: 12px;
  color: var(--color-text-muted);
}

.approval-balance-item strong {
  font-size: 22px;
  color: var(--color-accent);
}

.approval-main {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 16px 0;
}

.approval-form-card {
  padding: 22px;
}

.approval-year-chip {
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--color-accent-soft);
  color: var(--color-accent);
  font-weight: 600;
}

.approval-sheet-grid {
  display: grid;
  gap: 16px;
}

.approval-sheet-block {
  border: 1px solid var(--color-border);
  border-radius: 14px;
  padding: 16px;
  background: #fbfdff;
}

.approval-block-title {
  margin: 0 0 12px;
  font-size: 15px;
}

.approval-info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.approval-info-grid div,
.approval-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.approval-info-grid span,
.approval-field span {
  font-size: 12px;
  color: var(--color-text-muted);
}

.approval-field-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.approval-field input,
.approval-field select,
.approval-field textarea,
.approval-year-filter input,
.attendance-leave-year input,
.admin-inline-number,
.admin-inline-select,
.admin-leave-approver-panel input {
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 10px 12px;
  background: var(--color-surface);
}

.approval-approver-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.approval-approver-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  background: var(--color-surface);
}

.approval-approver-order {
  min-width: 52px;
  text-align: center;
  padding: 8px 10px;
  border-radius: 10px;
  background: var(--color-accent-soft);
  color: var(--color-accent);
  font-weight: 700;
}

.approval-approver-meta,
.approval-selected-meta,
.admin-leave-selected-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.approval-approver-meta span,
.approval-chain-text,
.approval-selected-meta span,
.admin-leave-selected-meta span {
  color: var(--color-text-muted);
  font-size: 12px;
}

.approval-form-actions {
  margin-top: 16px;
  display: flex;
  justify-content: flex-end;
}

.approval-documents-grid,
.approval-approver-picker,
.admin-leave-approvers-layout {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.approval-request-actions {
  display: flex;
  gap: 8px;
}

.approval-status {
  display: inline-flex;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}

.approval-status-pending {
  background: #fef3c7;
  color: #92400e;
}

.approval-status-approved {
  background: #dcfce7;
  color: #166534;
}

.approval-status-rejected,
.approval-status-cancelled {
  background: #fee2e2;
  color: #991b1b;
}

.approval-modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.28);
  display: grid;
  place-items: center;
  z-index: 60;
}

.approval-modal[hidden] {
  display: none;
}

.approval-modal-dialog {
  width: min(1040px, calc(100vw - 40px));
  max-height: calc(100vh - 40px);
  overflow: auto;
  background: var(--color-surface);
  border-radius: 18px;
  box-shadow: var(--shadow-soft);
  padding: 22px;
}

.approval-modal-subtitle {
  margin: 6px 0 0;
  color: var(--color-text-muted);
  font-size: 12px;
}

.approval-modal-close {
  border: none;
  background: transparent;
  font-size: 28px;
  cursor: pointer;
}

.approval-modal-body {
  margin: 20px 0;
}

.approval-picker-panel,
.admin-leave-approver-panel {
  border: 1px solid var(--color-border);
  border-radius: 14px;
  padding: 14px;
  background: #fbfdff;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.approval-picker-title {
  font-weight: 700;
}

.approval-approver-options,
.approval-selected-approvers,
.admin-leave-approver-options,
.admin-leave-approver-selected {
  max-height: 360px;
  overflow: auto;
}

.approval-approver-option,
.admin-leave-approver-option {
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 12px;
  background: var(--color-surface);
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.approval-approver-option.selected,
.admin-leave-approver-option.selected {
  border-color: var(--color-accent);
  background: var(--color-accent-soft);
}

.approval-approver-option span,
.approval-approver-option em,
.admin-leave-approver-option span,
.admin-leave-approver-option em {
  color: var(--color-text-muted);
  font-size: 12px;
  font-style: normal;
}

.approval-selected-item,
.admin-leave-selected-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
}

.approval-selected-actions,
.admin-leave-selected-actions {
  display: flex;
  gap: 6px;
}

.approval-selected-actions button,
.admin-leave-selected-actions button {
  border: 1px solid var(--color-border);
  border-radius: 999px;
  padding: 6px 10px;
  background: var(--color-surface);
  cursor: pointer;
}

.attendance-subtabs {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 12px;
}

.attendance-subtab {
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-text-muted);
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  font-weight: 600;
  text-align: left;
  width: 100%;
}

.attendance-subtab.active {
  background: var(--color-accent-soft);
  color: var(--color-accent);
  border-color: #bfdbfe;
}

.attendance-leave-panel {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.attendance-leave-year,
.approval-year-filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.admin-inline-number,
.admin-inline-select {
  width: 100%;
}

.attendance-left-nav {
  margin-top: 16px;
}

.attendance-left-divider {
  height: 1px;
  background: var(--color-border-subtle);
  margin-bottom: 8px;
}

.approval-layout.approval-layout-v2 {
  display: grid;
  grid-template-columns: 304px minmax(0, 1fr);
  gap: 24px;
  min-height: calc(100vh - 40px);
  min-width: 1200px;
}

.approval-left,
.approval-right {
  min-width: 0;
}

.approval-left-card {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.approval-left-actions {
  display: flex;
}

.approval-new-button {
  width: 100%;
}

.approval-left-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.approval-left-section-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text-main);
}

.approval-left-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.approval-left-item {
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  text-align: left;
  color: var(--color-text-main);
  cursor: pointer;
}

.approval-left-item:hover,
.approval-left-item.active {
  background: #f4f8ff;
  border-color: var(--color-border);
}

.approval-frequent-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.approval-form-item-compact {
  background: #fff;
}

.approval-right {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.approval-home-card,
.approval-list-card,
.approval-form-page {
  padding: 22px;
}

.approval-search-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.approval-search-input,
.approval-template-group-title + input,
.approval-template-list input,
.approval-modal input {
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 10px 12px;
  background: #fff;
}

.approval-home-sections {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.approval-doc-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.approval-doc-row {
  cursor: pointer;
}

.approval-doc-row:hover {
  background: #f8fbff;
}

.approval-form-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 18px;
}

.approval-form-toolbar-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.approval-form-meta-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.approval-form-meta-block {
  border: 1px solid var(--color-border-subtle);
  border-radius: 12px;
  padding: 14px;
  background: #fbfdff;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.approval-cc-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  border-radius: 999px;
  background: #f8fafc;
  border: 1px solid var(--color-border);
  font-size: 13px;
  margin-right: 8px;
  margin-bottom: 8px;
}

.approval-cc-chip span {
  color: var(--color-text-muted);
  font-size: 12px;
}

.approval-form-sheet-wrap {
  border: 1px solid var(--color-border-subtle);
  border-radius: 16px;
  background: #fff;
  padding: 24px;
}

.approval-form-sheet {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.approval-form-sheet-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
}

.approval-form-sheet-title {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
}

.approval-form-signatures {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.approval-form-sign-slot {
  min-width: 120px;
  padding: 10px 12px;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: #f8fbff;
}

.approval-form-sign-role {
  font-size: 12px;
  color: var(--color-text-muted);
}

.approval-form-sign-slot em {
  font-style: normal;
  color: var(--color-text-muted);
  font-size: 12px;
}

.approval-form-meta-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.approval-form-meta-item,
.approval-form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.approval-form-meta-item span,
.approval-form-field span {
  font-size: 12px;
  color: var(--color-text-muted);
}

.approval-form-content-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.approval-form-field input,
.approval-form-field select,
.approval-form-field textarea,
.approval-search-input,
.approval-template-dialog input,
.admin-inline-input {
  width: 100%;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 10px 12px;
  background: #fff;
  font: inherit;
}

.approval-form-field-full {
  grid-column: 1 / -1;
}

.approval-template-dialog {
  width: min(1120px, calc(100vw - 40px));
}

.approval-template-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.95fr);
  gap: 16px;
}

.approval-template-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 520px;
  overflow: auto;
}

.approval-template-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.approval-template-group-title {
  font-size: 13px;
  font-weight: 700;
}

.approval-template-item {
  width: 100%;
  text-align: left;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 10px 12px;
  background: #fff;
  cursor: pointer;
}

.approval-template-item.selected {
  border-color: var(--color-accent);
  background: var(--color-accent-soft);
}

.approval-template-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.approval-template-detail-grid div {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.approval-template-detail-grid span {
  font-size: 12px;
  color: var(--color-text-muted);
}

.approval-template-detail-full {
  grid-column: 1 / -1;
}

.approval-approver-picker-wide {
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr);
}

.approval-approver-option-card {
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 12px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  background: #fff;
}

.approval-approver-option-main {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.approval-approver-option-main span,
.approval-approver-option-main em {
  font-size: 12px;
  color: var(--color-text-muted);
  font-style: normal;
}

.approval-approver-option-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.admin-inline-input {
  min-width: 0;
}

@media (max-width: 1200px) {
  .approval-layout,
  .approval-layout.approval-layout-v2,
  .approval-documents-grid,
  .approval-approver-picker,
  .admin-leave-approvers-layout,
  .approval-template-body,
  .approval-form-meta-panel,
  .approval-form-content-grid,
  .approval-form-meta-grid {
    grid-template-columns: 1fr;
  }
}
