:root {
  --brand-orange: #ff8300;
  --brand-green: #61a60e;
  --brand-gray: #54565a;
  --paper: #f4f1ea;
  --surface: #fffdf8;
  --surface-2: #ebe8df;
  --ink: #242528;
  --muted: #64666a;
  --line: #d9d4c8;
  --line-soft: #e9e4d9;
  --lime: #dbeec2;
  --lime-dark: var(--brand-green);
  --violet: #7560cf;
  --violet-soft: #ece8fb;
  --coral: #d87559;
  --coral-soft: #fae8e1;
  --blue: #4b82a8;
  --blue-soft: #e4eff5;
  --manual: #2186a6;
  --manual-soft: #dff3f8;
  --manual-project: #2186a6;
  --manual-project-soft: #dff3f8;
  --manual-absence: #2f9d75;
  --manual-absence-soft: #e0f5ec;
  --manual-note: #77766f;
  --manual-note-soft: #eceae3;
  --day-notice: #b83b2d;
  --day-notice-soft: #fff0c7;
  --rental-notice: #176f78;
  --rental-notice-soft: #dff4ef;
  --project-day: #fff200;
  --project-day-border: #d6c900;
  --day-width: 112px;
  --day-min-width: 88px;
  --day-preferred-width: 132px;
  --name-width: 230px;
  --radius: 12px;
  --shadow: 0 20px 60px rgba(36, 37, 40, .14);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { min-width: 320px; min-height: 100%; background: var(--paper); }
body { margin: 0; min-height: 100vh; background: var(--paper); overflow-x: hidden; overflow-y: auto; }
button, input, select, textarea { font: inherit; }
button { color: inherit; }
button, select { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid rgba(97, 166, 14, .24); outline-offset: 2px; }
.hidden { display: none !important; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.app-shell {
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  display: block;
  overflow: visible;
}
.topbar {
  height: 76px;
  display: grid;
  grid-template-columns: auto minmax(180px, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 0 32px;
  border-bottom: 1px solid var(--line);
  background: rgba(244, 241, 234, .94);
  backdrop-filter: blur(14px);
  position: sticky;
  top: 0;
  z-index: 30;
}
.brand { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand strong { display: block; font-family: inherit; font-size: 20px; line-height: 1; letter-spacing: .04em; }
.brand small { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .15em; }
.brand-mark { width: 42px; height: 54px; display: grid; place-items: center; background: transparent; overflow: visible; }
.brand-mark img { width: 38px; height: 49px; display: block; object-fit: contain; }
.top-actions, .hero-actions, .period-control, .view-controls { display: flex; align-items: center; gap: 9px; }
.today-presence { position: relative; min-width: 0; justify-self: start; }
.today-presence-button { min-height: 36px; padding: 0 10px; display: inline-flex; align-items: center; gap: 8px; border: 1px solid rgba(217,212,200,.9); border-radius: 9px; background: rgba(255,253,248,.7); text-align: left; box-shadow: 0 2px 10px rgba(36,37,40,.04); }
.today-presence-button:hover, .today-presence-button[aria-expanded="true"] { background: white; border-color: #cfc8b8; }
.today-presence-button strong { color: var(--ink); font-size: 11px; line-height: 1; white-space: nowrap; }
.today-presence-icon { width: 18px; height: 18px; position: relative; flex: 0 0 18px; color: var(--brand-green); }
.today-presence-icon i { position: absolute; width: 6px; height: 6px; top: 2px; border-radius: 50%; background: currentColor; }
.today-presence-icon i:nth-child(1) { left: 1px; opacity: .65; }
.today-presence-icon i:nth-child(2) { left: 6px; z-index: 1; }
.today-presence-icon i:nth-child(3) { right: 1px; opacity: .65; }
.today-presence-icon::after { content: ''; position: absolute; left: 2px; right: 2px; bottom: 1px; height: 7px; border-radius: 8px 8px 4px 4px; background: currentColor; opacity: .9; }
.today-presence-chevron { margin-left: 1px; color: var(--muted); font-size: 13px; line-height: 1; transition: transform .16s ease; }
.today-presence-button[aria-expanded="true"] .today-presence-chevron { transform: rotate(180deg); }
.today-presence-panel { position: absolute; z-index: 80; top: calc(100% + 10px); left: 0; width: min(1120px, calc(100vw - 40px)); max-height: min(520px, calc(100vh - 110px)); display: grid; grid-template-columns: repeat(4, 230px); gap: 10px; padding: 10px; overflow: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: 0 18px 48px rgba(36,37,40,.18); }
.today-presence-column { min-width: 0; display: grid; align-content: start; gap: 6px; padding: 9px; border-radius: 10px; background: #fbfaf6; }
.today-presence-column > strong { margin-bottom: 3px; display: flex; justify-content: space-between; color: var(--ink); font-size: 11px; text-transform: uppercase; letter-spacing: .07em; }
.today-presence-column > strong b { min-width: 22px; height: 20px; display: grid; place-items: center; border-radius: 999px; background: var(--surface-2); font-size: 10px; letter-spacing: 0; }
.today-presence-column span { min-width: 0; padding: 7px 8px; border-radius: 8px; background: white; color: var(--ink); font-size: 11px; font-weight: 800; box-shadow: inset 0 0 0 1px var(--line-soft); }
.today-presence-column span > strong { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; min-width: 0; font: inherit; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.today-presence-column span > strong i { width: 7px; height: 7px; border-radius: 999px; background: var(--presence-color, #77766f); box-shadow: 0 0 0 2px color-mix(in srgb, var(--presence-color, #77766f) 18%, transparent); flex: 0 0 auto; }
.today-presence-column span > strong small { color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .02em; white-space: nowrap; }
.today-presence-column.absent span { border-left: 3px solid var(--coral); }
.today-presence-column.home-office span { border-left: 3px solid #4aa3ff; }
.today-presence-column.production span { border-left: 3px solid var(--violet); }
.today-presence-column.present span { border-left: 3px solid var(--brand-green); }
.today-presence-column em, .today-presence-column small { display: block; margin-top: 2px; color: var(--muted); font-size: 9px; font-style: normal; font-weight: 700; line-height: 1.3; }
.sync-state { display: flex; gap: 8px; align-items: center; color: var(--muted); font-size: 12px; margin-right: 8px; }
.user-chip { min-height: 39px; display: inline-flex; align-items: center; gap: 8px; padding: 5px 10px; border: 1px solid var(--line); border-radius: 999px; background: rgba(255, 253, 248, .86); font-size: 12px; }
.user-chip span { max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 800; }
.user-chip small { padding: 2px 7px; border-radius: 999px; background: rgba(97, 166, 14, .14); color: #3e7209; font-weight: 850; }
.logout-form { display: contents; }
.logout-form button { margin: 0; padding: 0; border: 0; background: transparent; color: var(--muted); font: inherit; font-weight: 750; cursor: pointer; }
.logout-form button:hover { color: var(--ink); }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--brand-green); box-shadow: 0 0 0 4px rgba(97, 166, 14, .14); }
.sync-state.error .status-dot { background: var(--coral); box-shadow: 0 0 0 4px rgba(216, 117, 89, .12); }
.sync-state.loading .status-dot { background: var(--brand-orange); animation: pulse 1s infinite; }

.button { min-height: 39px; border: 1px solid transparent; border-radius: 8px; padding: 0 14px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; color: inherit; font-weight: 700; font-size: 13px; text-decoration: none; transition: transform .16s, box-shadow .16s, background .16s; }
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0); }
.button-primary { background: var(--brand-green); border-color: #4f8f0b; color: white; }
.button-primary:hover { box-shadow: 0 6px 20px rgba(97, 166, 14, .24); }
.button-dark { background: var(--ink); color: white; }
.button-dark:hover { box-shadow: 0 6px 20px rgba(32, 33, 30, .2); }
.button-important { border-color: #9e2f23; background: var(--day-notice); color: white; box-shadow: 0 5px 16px rgba(184,59,45,.16); }
.button-important:hover { background: #a93226; box-shadow: 0 7px 22px rgba(184,59,45,.24); }
.button-important > .hero-action-icon { width: 19px; height: 19px; display: grid; place-items: center; border-radius: 6px; background: rgba(255,255,255,.18); font-size: 13px; font-weight: 850; }
.button-export { border-color: #a8c78c; background: #f3f9ed; color: #467d16; }
.button-export:hover { border-color: #84ad61; background: #eaf5df; box-shadow: 0 6px 18px rgba(87,139,38,.13); }
.button-export > .hero-action-icon { font-size: 14px; font-weight: 850; }
.button-ghost { border-color: var(--line); background: var(--surface); }
.button-danger { background: transparent; color: #a33f31; border-color: #e8c1b8; }
.button-icon { font-size: 16px; line-height: 1; }
.logs-count { min-width: 30px; height: 20px; padding: 0 8px; display: grid; place-items: center; border-radius: 10px; background: var(--brand-orange); color: white; font-size: 9px; font-weight: 850; }
.sync-icon { font-size: 20px; }
.button.loading .sync-icon { animation: spin .8s linear infinite; }
.button:disabled { opacity: .6; cursor: wait; transform: none; }
.login-page { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: radial-gradient(circle at 20% 15%, rgba(97, 166, 14, .14), transparent 32%), radial-gradient(circle at 80% 85%, rgba(255, 131, 0, .12), transparent 32%), var(--paper); }
.login-card { width: min(440px, 100%); padding: 34px; border: 1px solid var(--line); border-radius: 22px; background: rgba(255, 253, 248, .94); box-shadow: var(--shadow); }
.login-logo { width: 58px; height: auto; display: block; margin-bottom: 18px; }
.login-card h1 { margin: 6px 0 8px; font-size: clamp(32px, 7vw, 48px); line-height: .95; letter-spacing: -.05em; }
.login-card p { color: var(--muted); line-height: 1.55; }
.login-card .button { width: 100%; margin-top: 12px; }
.auto-sync-control { position: relative; flex: 0 0 auto; }
.auto-sync-button { position: relative; width: 39px; height: 39px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); }
.auto-sync-button > span { font-size: 23px; line-height: 1; transform: translateY(-1px); }
.auto-sync-button > i { position: absolute; right: 5px; bottom: 5px; width: 7px; height: 7px; border: 1px solid var(--surface); border-radius: 50%; background: var(--brand-orange); opacity: 0; }
.auto-sync-button:hover, .auto-sync-button[aria-expanded="true"] { background: white; border-color: #c9c5b9; }
.auto-sync-button.active { border-color: rgba(97,166,14,.45); background: rgba(97,166,14,.12); }
.auto-sync-button.active > i { opacity: 1; }
.auto-sync-menu { position: absolute; z-index: 70; top: calc(100% + 9px); right: 0; width: min(300px, calc(100vw - 20px)); padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 18px 45px rgba(34,32,25,.18); }
.auto-sync-menu-head { padding: 9px 10px 11px; border-bottom: 1px solid var(--line-soft); }
.auto-sync-menu-head strong, .auto-sync-menu-head small { display: block; }
.auto-sync-menu-head strong { font-size: 12px; }
.auto-sync-menu-head small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.auto-sync-menu > button { width: 100%; min-height: 49px; padding: 8px 9px; display: flex; align-items: center; gap: 10px; border: 0; border-radius: 8px; background: transparent; text-align: left; }
.auto-sync-menu > button:hover { background: var(--surface-2); }
.auto-sync-menu > button > span { min-width: 0; flex: 1; }
.auto-sync-menu > button strong, .auto-sync-menu > button small { display: block; }
.auto-sync-menu > button strong { font-size: 11px; }
.auto-sync-menu > button small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.auto-sync-menu > button > i { width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; background: rgba(97,166,14,.16); color: var(--brand-green); font-style: normal; font-size: 10px; font-weight: 900; opacity: 0; }
.auto-sync-menu > button.active { background: rgba(97,166,14,.12); }
.auto-sync-menu > button.active > i { opacity: 1; }
.auto-sync-menu > p { margin: 7px 9px 3px; color: var(--muted); font-size: 8px; line-height: 1.4; }

main {
  min-height: calc(100vh - 76px);
  min-height: calc(100dvh - 76px);
  padding: 30px 32px 38px;
  display: block;
}
.hero-row { width: 100%; display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin: 0 0 24px; }
.hero-tools { max-width: 760px; display: grid; justify-items: end; gap: 10px; }
.hero-actions { flex-wrap: nowrap; }
.hero-actions .hero-action-button {
  min-height: 42px;
  padding: 0 13px;
  gap: 8px;
  border-radius: 9px;
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 3px 10px rgba(36,37,40,.055);
}
.hero-actions .hero-action-button:hover { box-shadow: 0 7px 18px rgba(36,37,40,.12); }
.hero-action-icon {
  width: 19px;
  height: 19px;
  flex: 0 0 19px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: rgba(32,33,30,.065);
  font-size: 13px;
  line-height: 1;
  font-weight: 850;
}
.button-export > .hero-action-icon { background: rgba(70,125,22,.1); font-size: 14px; }
.button-important > .hero-action-icon,
.button-dark > .hero-action-icon {
  width: 19px;
  height: 19px;
  flex: 0 0 19px;
  border-radius: 6px;
  background: rgba(255,255,255,.18);
  font-size: 13px;
}
.rentman-log-box { width: min(610px, 100%); display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: start; gap: 11px; padding: 12px 13px; border: 1px solid #cc6900; border-radius: 10px; background: linear-gradient(135deg, #a85000, var(--brand-orange)); color: white; box-shadow: 0 7px 20px rgba(255, 131, 0, .18); }
.rentman-log-box.personio-only { border-color: #b65d49; background: linear-gradient(135deg, #994935, var(--coral)); box-shadow: 0 7px 20px rgba(216, 117, 89, .2); }
.rentman-log-box.mixed-sources { border-color: #7a5a36; background: linear-gradient(135deg, #69514a, #b86a45); }
.rentman-log-symbol { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; background: rgba(255,255,255,.18); color: white; font-size: 13px; font-weight: 900; }
.rentman-log-copy { min-width: 0; }
.rentman-log-copy small, .rentman-log-copy strong { display: block; }
.rentman-log-copy > small { color: #fff0dc; font-size: 8px; font-weight: 850; text-transform: uppercase; letter-spacing: .11em; }
.rentman-log-copy > strong { margin-top: 2px; font-size: 11px; }
.rentman-log-copy ul { margin: 5px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 3px 12px; list-style: none; color: #f8e8e4; font-size: 9px; line-height: 1.35; }
.rentman-log-copy li::before { content: "•"; margin-right: 5px; color: #fff0dc; }
.rentman-log-copy li b { color: white; font-weight: 900; }
.rentman-log-copy li.more { color: #fff0dc; font-weight: 750; }
.rentman-log-details, .rentman-log-dismiss { align-self: center; border: 1px solid rgba(255,255,255,.28); border-radius: 7px; background: rgba(255,255,255,.1); color: white; font-weight: 800; }
.rentman-log-details { padding: 7px 9px; font-size: 9px; }
.rentman-log-dismiss { width: 28px; height: 28px; padding: 0; display: grid; place-items: center; font-size: 17px; line-height: 1; }
.rentman-log-details:hover, .rentman-log-dismiss:hover { background: rgba(255,255,255,.18); }
.attendance-warning-box { width: min(610px, 100%); display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 11px; padding: 11px 13px; border: 1px solid #d76756; border-radius: 10px; background: #fff1ee; color: #87372c; box-shadow: 0 7px 20px rgba(174,62,45,.1); }
.attendance-warning-symbol { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; background: #d95f4f; color: white; font-size: 13px; font-weight: 900; }
.attendance-warning-box small, .attendance-warning-box strong { display: block; }
.attendance-warning-box small { color: #a64b3e; font-size: 8px; font-weight: 900; text-transform: uppercase; letter-spacing: .1em; }
.attendance-warning-box strong { margin-top: 2px; color: #702d24; font-size: 11px; }
.attendance-warning-box p { margin: 4px 0 0; color: #995045; font-size: 9px; line-height: 1.35; }
.attendance-warning-box a { padding: 7px 10px; border: 1px solid rgba(149,57,43,.25); border-radius: 7px; background: white; color: #87372c; font-size: 9px; font-weight: 850; text-decoration: none; }
.attendance-warning-box a:hover { background: #ffe5e0; }
.eyebrow { margin: 0 0 6px; text-transform: uppercase; letter-spacing: .16em; font-size: 10px; font-weight: 800; color: var(--brand-green); }
h1 { margin: 0; font-family: inherit; font-weight: 500; font-size: clamp(34px, 4vw, 54px); line-height: 1; letter-spacing: -.04em; }
.subline { margin: 9px 0 0; color: var(--muted); font-size: 14px; }

.workspace { width: 100%; height: auto; min-height: 520px; display: grid; grid-template-columns: clamp(220px, 13vw, 300px) minmax(0, 1fr); align-items: stretch; margin: 0; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: var(--surface); box-shadow: 0 8px 40px rgba(84, 86, 90, .08); }
.sidebar { min-height: 0; overflow: visible; padding: 22px 17px 18px; background: #ebe8df; border-right: 1px solid var(--line); display: flex; flex-direction: column; scrollbar-color: #cbc8be transparent; }
.sidebar-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 17px; }
.sidebar-head strong { font-size: 14px; }
.icon-button { width: 34px; height: 34px; border: 0; border-radius: 8px; background: transparent; display: inline-grid; place-items: center; font-size: 18px; }
.icon-button:hover { background: rgba(32, 33, 30, .07); }
.icon-button.bordered { border: 1px solid var(--line); background: var(--surface); }
.search-field { height: 38px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); display: flex; align-items: center; gap: 7px; padding: 0 10px; color: var(--muted); }
.search-field input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 12px; color: var(--ink); }
.group-filter-field { margin-top: 10px; display: grid; gap: 5px; }
.group-filter-field > span { color: var(--muted); font-size: 8px; font-weight: 800; text-transform: uppercase; letter-spacing: .09em; }
.group-filter-field select { width: 100%; height: 38px; min-width: 0; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); padding: 0 30px 0 10px; color: var(--ink); font-size: 11px; }
.filter-list { margin: 17px 0 21px; display: grid; gap: 4px; }
.filter { width: 100%; height: 37px; border: 0; background: transparent; border-radius: 8px; display: flex; align-items: center; gap: 10px; padding: 0 10px; color: #555750; font-size: 12px; text-align: left; }
.filter:hover { background: rgba(255,255,255,.55); }
.filter.active { background: var(--surface); color: var(--ink); box-shadow: 0 1px 4px rgba(28, 27, 22, .06); font-weight: 700; }
.filter.muted { opacity: .45; }
.filter b { margin-left: auto; min-width: 21px; height: 21px; border-radius: 11px; display: grid; place-items: center; background: rgba(32,33,30,.07); font-size: 10px; }
.filter-symbol { width: 9px; height: 9px; border-radius: 3px; background: #999; }
.filter-symbol.all { border-radius: 50%; background: var(--ink); }
.filter-symbol.rentman { background: var(--violet); }
.filter-symbol.personio { background: var(--coral); }
.filter-symbol.manual { background: var(--manual); }
.filter-symbol.manual-project { background: var(--manual-project); }
.filter-symbol.manual-absence { background: var(--manual-absence); }
.filter-symbol.manual-note { background: var(--manual-note); }
.filter-symbol.day-notice { background: var(--day-notice); box-shadow: 0 0 0 3px rgba(184,59,45,.12); }
.filter-symbol.rental-notice { background: var(--rental-notice); box-shadow: 0 0 0 3px rgba(23,111,120,.12); }
.display-options { margin-bottom: 18px; padding: 13px 11px 11px; border: 1px solid #d5d1c6; border-radius: 10px; background: rgba(255,255,255,.48); }
.display-options .eyebrow { margin-bottom: 8px; }
.display-option { width: 100%; min-height: 39px; border: 0; border-top: 1px solid rgba(120,118,108,.13); background: transparent; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 2px; color: var(--muted); text-align: left; }
.display-option:first-of-type { border-top: 0; }
.display-option span, .display-option strong, .display-option small { display: block; }
.display-option strong { color: var(--ink); font-size: 10.5px; line-height: 1.2; }
.display-option small { margin-top: 2px; font-size: 8.5px; }
.display-option i { position: relative; flex: 0 0 30px; width: 30px; height: 17px; border-radius: 999px; background: #c5c3bc; transition: background .15s; }
.display-option i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 11px; height: 11px; border-radius: 50%; background: white; box-shadow: 0 1px 3px rgba(0,0,0,.18); transition: transform .15s; }
.display-option.active i { background: var(--brand-green); }
.display-option.active i::after { transform: translateX(13px); }
.legend { border-top: 1px solid var(--line); padding-top: 18px; }
.legend > div { display: flex; gap: 10px; align-items: center; margin: 11px 0; }
.legend-swatch { width: 26px; height: 15px; border-radius: 4px; }
.legend-swatch.project { background: var(--violet-soft); border-left: 3px solid var(--violet); }
.legend-swatch.absence { background: var(--coral-soft); border-left: 3px solid var(--coral); }
.legend-swatch.manual { background: var(--manual-soft); border-left: 3px solid var(--manual); }
.legend-swatch.manual-project { background: var(--manual-project-soft); border-left: 3px solid var(--manual-project); }
.legend-swatch.manual-absence { background: var(--manual-absence-soft); border-left: 3px solid var(--manual-absence); }
.legend-swatch.manual-note { background: var(--manual-note-soft); border-left: 3px solid var(--manual-note); }
.legend-swatch.day-notice { background: var(--day-notice-soft); border: 1px solid #e0a049; border-left: 4px solid var(--day-notice); }
.legend-swatch.rental-notice { background: var(--rental-notice-soft); border: 1px solid #89c6bd; border-left: 4px solid var(--rental-notice); }
.legend-swatch.project-day { height: 10px; margin-top: 2px; background: var(--project-day); border: 1px solid var(--project-day-border); border-radius: 4px; }
.legend strong, .legend small { display: block; }
.legend strong { font-size: 11px; line-height: 1.2; }
.legend small { color: var(--muted); font-size: 9px; margin-top: 1px; }
.sidebar-note { margin-top: 14px; display: flex; align-items: flex-start; gap: 9px; padding: 12px; border-radius: 9px; background: rgba(217, 240, 108, .32); font-size: 10px; color: #5e6250; line-height: 1.45; }
.sidebar-note > span { color: #788d22; font-size: 16px; }
.sidebar-note p { margin: 0; }
.sidebar-note strong { color: var(--ink); display: block; }

.planner { min-width: 0; max-width: 100%; position: relative; overflow: hidden; background: var(--surface); }
.planner-toolbar { height: 68px; padding: 0 18px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.period-label { width: 240px; min-width: 240px; flex: 0 0 240px; border: 0; background: transparent; display: flex; align-items: center; justify-content: center; gap: 8px; font-family: inherit; font-size: 16px; white-space: nowrap; }
.today-button { height: 34px; padding: 0 10px; border: 0; background: transparent; font-weight: 700; font-size: 11px; color: var(--muted); }
.next-assignment-button { color: #5d50a3; white-space: nowrap; }
.next-assignment-button:hover { background: var(--violet-soft); border-radius: 7px; }
.view-controls { border: 1px solid var(--line); padding: 3px; border-radius: 8px; }
.view-controls button { border: 0; border-radius: 5px; height: 28px; padding: 0 10px; background: transparent; color: var(--muted); font-size: 10px; font-weight: 700; }
.view-controls button.active { background: var(--ink); color: white; }

.timeline-scroll { width: 100%; max-width: 100%; min-width: 0; height: auto; min-height: 452px; overflow-x: auto; overflow-y: visible; scrollbar-color: #cbc8be transparent; overscroll-behavior-x: contain; }
.timeline-scroll::-webkit-scrollbar { width: 12px; height: 12px; }
.timeline-scroll::-webkit-scrollbar-thumb { border: 3px solid transparent; border-radius: 999px; background: #cbc8be; background-clip: content-box; }
.timeline-scroll::-webkit-scrollbar-track { background: transparent; }
.timeline { width: 100%; min-width: calc(var(--name-width) + var(--day-width) * 14); }
.timeline-header { display: grid; position: sticky; top: 0; z-index: 15; min-height: 64px; background: var(--surface); border-bottom: 1px solid var(--line); }
.timeline-floating-header { position: fixed; z-index: 29; display: none; height: 64px; overflow: hidden; border-bottom: 1px solid var(--line); background: var(--surface); box-shadow: 0 7px 18px rgba(36,37,40,.11); pointer-events: none; }
.timeline-floating-header.visible { display: block; }
.timeline-floating-header-content { position: relative; top: auto; z-index: 1; width: max-content; height: 64px; min-height: 64px; }
.timeline-floating-header-content .corner-cell { z-index: 3; }
.timeline-notices { position: sticky; top: 64px; z-index: 16; background: #fff9e8; box-shadow: 0 6px 18px rgba(110,54,25,.13); }
.important-notice-row { position: relative; height: 50px; display: grid; border-bottom: 1px solid #edc98e; background: #fffaf0; }
.important-notice-side { position: sticky; left: 0; z-index: 4; display: flex; align-items: center; gap: 6px; padding-left: 16px; border-right: 1px solid #d9b778; background: #fff0cb; color: #84372c; font-size: 9px; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; white-space: nowrap; }
.important-notice-side > b { width: 19px; height: 19px; display: grid; place-items: center; border-radius: 50%; background: var(--day-notice); color: white; font-size: 11px; letter-spacing: 0; }
.important-notice-side > i { min-width: 18px; height: 18px; display: grid; place-items: center; border-radius: 999px; background: rgba(184,59,45,.12); color: var(--day-notice); font-style: normal; font-size: 9px; letter-spacing: 0; }
.important-notice-row.rental-row { border-bottom-color: rgba(91,169,159,.38); background: #f6fbf9; }
.important-notice-row.rental-row .important-notice-side { border-right-color: rgba(91,169,159,.48); background: #e8f5f1; color: #286a66; }
.important-notice-row.rental-row .important-notice-side > b { background: var(--rental-notice); }
.important-notice-row.rental-row .important-notice-side > i { background: rgba(23,111,120,.12); color: var(--rental-notice); }
.important-notice-day { border-right: 1px solid #f0dfbd; }
.important-notice-day.weekend { background: #f8f1e4; }
.important-notice-day.holiday { background: #e7e3da; }
.important-notice-bar { position: absolute; z-index: 3; top: 4px; height: 42px; min-width: 0; display: grid; grid-template-columns: 22px minmax(0,1fr) auto; align-items: center; gap: 7px; padding: 4px 9px 4px 6px; overflow: hidden; border: 1px solid #d98b39; border-left: 4px solid var(--day-notice); border-radius: 8px; background: linear-gradient(90deg, #ffe7a8, var(--day-notice-soft)); color: #67291f; box-shadow: 0 2px 7px rgba(122,50,29,.16); text-align: left; }
.important-notice-bar:hover { border-color: #c86c29; box-shadow: 0 5px 14px rgba(122,50,29,.22); transform: translateY(-1px); }
.important-notice-bar > b { width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; background: var(--day-notice); color: white; font-size: 10px; font-weight: 900; }
.important-notice-copy { min-width: 0; display: grid; gap: 2px; }
.important-notice-copy > strong, .important-notice-copy > small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.important-notice-copy > strong { font-size: 10px; font-weight: 900; line-height: 1.15; }
.important-notice-copy > small { font-size: 8px; font-weight: 650; line-height: 1.1; opacity: .82; }
.important-notice-bar > em { padding: 2px 6px; border-radius: 999px; background: rgba(255,255,255,.62); color: currentColor; font-size: 7px; font-style: normal; font-weight: 850; white-space: nowrap; }
.important-notice-bar.private { border-style: dashed; background: linear-gradient(90deg, #fff0cb, #fff8e7); }
.important-notice-bar.rental { isolation: isolate; display: block; padding: 0; border-color: rgba(91,169,159,.42); border-left-width: 1px; background: rgba(226,243,239,.28); color: #164f55; box-shadow: 0 2px 7px rgba(23,111,120,.07); }
.important-notice-bar.rental.private { background: rgba(244,251,248,.24); }
.rental-endpoint { position: absolute; z-index: 1; top: -1px; bottom: -1px; width: min(calc(var(--day-width) - 5px), 50%); display: flex; flex-direction: column; justify-content: center; gap: 2px; min-width: 0; padding: 4px 8px; overflow: hidden; border: 1px solid rgba(91,169,159,.7); background: rgba(184,229,220,.9); text-align: left; }
.important-notice-bar.private .rental-endpoint { border-style: dashed; background: rgba(226,243,239,.94); }
.rental-endpoint.rental-pickup { left: -1px; border-left: 4px solid var(--rental-notice); border-radius: 8px 5px 5px 8px; }
.rental-endpoint.rental-return { right: -1px; border-right: 4px solid var(--rental-notice); border-radius: 5px 8px 8px 5px; text-align: right; }
.rental-endpoint strong,
.rental-endpoint small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rental-endpoint strong { font-size: 10px; font-weight: 850; line-height: 1.08; }
.rental-endpoint small { font-size: 8px; font-weight: 650; line-height: 1.08; opacity: .82; }
.timeline-projects { position: sticky; top: 64px; z-index: 14; background: #fffdf5; box-shadow: 0 5px 14px rgba(49, 45, 28, .09); }
.project-overview-row { position: relative; display: grid; height: 31px; border-bottom: 1px solid #e9dfbd; background: #fffdf5; }
.project-overview-side { position: sticky; left: 0; z-index: 3; display: flex; align-items: center; gap: 7px; padding-left: 18px; border-right: 1px solid var(--line); background: #f8f3dd; color: #7b682b; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; }
.project-overview-side b { min-width: 18px; height: 18px; display: grid; place-items: center; border-radius: 9px; background: #fff200; color: #3f3a00; font-size: 9px; letter-spacing: 0; }
.project-overview-day { border-right: 1px solid #eee6ca; }
.project-overview-day.weekend { background: #fbf6e4; }
.project-overview-day.holiday { background: #e5e2da; }
.project-overview-bar { position: absolute; z-index: 2; top: 4px; height: 23px; padding: 3px 8px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; border: 1px solid #d6c900; border-radius: 6px; background: #fff200; color: #3f3a00; box-shadow: 0 1px 3px rgba(111, 86, 14, .16); font-family: inherit; font-size: 9px; font-weight: 800; line-height: 15px; text-align: left; cursor: default; }
.project-overview-bar.option { border: 2px dashed #c9b83b; padding: 2px 7px; background: #fff7b8; color: #655b18; box-shadow: 0 1px 3px rgba(111, 86, 14, .1); }
.corner-cell, .employee-cell { position: sticky; left: 0; z-index: 12; background: var(--surface); border-right: 1px solid var(--line); }
.corner-cell { display: flex; align-items: center; padding-left: 18px; color: var(--muted); font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .12em; }
.day-head { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; border-right: 1px solid var(--line-soft); font-size: 10px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.day-head.day-notice-trigger { cursor: pointer; }
.day-head.day-notice-trigger:hover { box-shadow: inset 0 0 0 1px rgba(77, 107, 17, .22); }
.day-head strong { font-family: inherit; font-size: 22px; line-height: 1.1; font-weight: 500; color: var(--ink); letter-spacing: 0; }
.day-head.weekend { background: #faf8f2; }
.day-head.today { background: rgba(217,240,108,.22); }
.day-head.holiday { background: #e4e2dc; }
.day-head .holiday-name { max-width: calc(100% - 8px); overflow: hidden; color: #686a64; font-size: 7px; font-weight: 700; line-height: 1.1; letter-spacing: .02em; text-overflow: ellipsis; white-space: nowrap; }
.day-head.today::after { content: ""; width: 5px; height: 5px; border-radius: 50%; background: #8da52c; position: absolute; bottom: 5px; }
.timeline-row { display: grid; min-height: 92px; border-bottom: 1px solid var(--line-soft); position: relative; }
.timeline-row:hover .day-cell:not(.weekend):not(.holiday) { background: #fffefb; }
.employee-cell { padding: 17px 13px 13px 18px; display: flex; align-items: flex-start; gap: 10px; }
.avatar { flex: 0 0 34px; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: white; font-size: 10px; font-weight: 800; letter-spacing: .03em; background: var(--avatar-color, #7357d6); box-shadow: 0 0 0 3px color-mix(in srgb, var(--avatar-color, #7357d6) 34%, transparent), inset 0 0 0 1px rgba(0,0,0,.08); overflow: hidden; }
.avatar.has-image { background: var(--avatar-color, #7357d6); padding: 2px; box-shadow: 0 0 0 3px color-mix(in srgb, var(--avatar-color, #7357d6) 38%, transparent), 0 1px 4px rgba(36,37,40,.12); }
.avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; background: white; }
.employee-info { min-width: max-content; padding-top: 1px; }
.employee-info strong, .employee-info small { display: block; white-space: nowrap; }
.employee-info small { overflow: hidden; text-overflow: ellipsis; }
.employee-info strong { font-size: 12px; }
.employee-name { display: flex !important; align-items: center; gap: 5px; overflow: visible !important; text-overflow: clip !important; }
.employee-info small { color: var(--muted); font-size: 9px; margin-top: 3px; }
.group-tags { max-width: 100%; margin-top: 5px; display: flex; flex-wrap: wrap; gap: 3px; }
.group-tags i { max-width: 100%; padding: 2px 6px; overflow: hidden; border: 1px solid #cbc6b8; border-radius: 5px; background: #dedacf; color: #41423d; font-style: normal; font-size: 8.5px; font-weight: 800; line-height: 13px; text-overflow: ellipsis; white-space: nowrap; }
.linked-icons { display: inline-flex; flex: 0 0 auto; gap: 3px; margin-top: 0; vertical-align: middle; }
.linked-icons i { width: 16px; height: 16px; border-radius: 4px; display: grid; place-items: center; font-style: normal; font-weight: 800; font-size: 8px; }
.linked-icons .r { color: var(--violet); background: var(--violet-soft); }
.linked-icons .p { color: var(--coral); background: var(--coral-soft); }
.day-cell { position: relative; border-right: 1px solid var(--line-soft); background: var(--surface); }
.day-cell.weekend { background: #faf8f2; }
.day-cell.today { background: rgba(217,240,108,.1); }
.day-cell.holiday { background: #ebe9e3; }
.day-personio-time { position: absolute; z-index: 9; right: 5px; bottom: 4px; left: 5px; display: flex; flex-direction: column; align-items: center; gap: 1px; min-height: 22px; padding-top: 3px; overflow: hidden; border-top: 1px solid rgba(132,134,127,.13); background: color-mix(in srgb, var(--surface) 92%, transparent); color: #73766f; font-size: 8px; font-weight: 500; line-height: 1.15; text-align: center; opacity: .9; pointer-events: none; }
.day-personio-time > span { display: block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-events { position: absolute; z-index: 8; top: 7px; left: var(--name-width); right: 0; height: calc(100% - 14px); pointer-events: none; }
.timeline-row.has-personio-times .row-events { bottom: 32px; height: auto; }
.entry-card { pointer-events: auto; position: absolute; min-height: 56px; height: 56px; top: 0; border: 0; border-radius: 8px; padding: 7px 10px 6px; text-align: left; overflow: hidden; box-shadow: 0 1px 2px rgba(36, 34, 29, .05); transition: transform .14s, box-shadow .14s; }
.entry-card:hover { transform: translateY(-2px); box-shadow: 0 7px 18px rgba(43, 40, 31, .12); z-index: 3; }
.entry-resize-handle { position: absolute; z-index: 8; top: 4px; bottom: 4px; width: 10px; border-radius: 5px; cursor: ew-resize; opacity: 0; touch-action: none; transition: opacity .14s, background-color .14s; }
.entry-resize-handle.start { left: 1px; }
.entry-resize-handle.end { right: 1px; }
.entry-card:hover .entry-resize-handle, .entry-card:focus-visible .entry-resize-handle, .entry-card.resizing .entry-resize-handle { opacity: 1; background: color-mix(in srgb, currentColor 20%, transparent); }
.entry-card.resizing { z-index: 20; transform: none; box-shadow: 0 10px 25px rgba(36, 34, 29, .22); transition: none; }
.entry-resize-label { display: none; position: absolute; z-index: 9; top: 50%; left: 50%; max-width: calc(100% - 28px); padding: 4px 7px; overflow: hidden; border-radius: 6px; background: rgba(31, 32, 35, .9); color: white; font-size: 9px; font-weight: 700; line-height: 1; text-overflow: ellipsis; white-space: nowrap; transform: translate(-50%, -50%); pointer-events: none; }
.entry-card.resizing .entry-resize-label { display: block; }
body.resizing-entry, body.resizing-entry * { cursor: ew-resize !important; user-select: none !important; }
@media (pointer: coarse) { .entry-resize-handle { width: 16px; opacity: .65; background: color-mix(in srgb, currentColor 16%, transparent); } }
.entry-card.project { background: var(--violet-soft); border-left: 3px solid var(--violet); color: #45377e; }
.entry-card.absence { background: var(--coral-soft); border-left: 3px solid var(--coral); color: #874331; }
.entry-card.split-absence { padding-right: 8px; }
.entry-card.split-absence strong { padding-right: 0; }
.entry-card .half-day-pill { display: inline-flex; align-items: center; width: fit-content; max-width: 100%; margin-top: 4px; padding: 1px 5px; border-radius: 999px; background: rgba(255,255,255,.36); font-size: 7.5px; line-height: 1.1; font-weight: 500; text-transform: none; letter-spacing: 0; white-space: nowrap; color: rgba(135,67,49,.82); }
.entry-card.pending-absence { background: #fff3df; border: 1px dashed var(--brand-orange); border-left: 3px solid var(--brand-orange); color: #855018; }
.entry-card.pending-absence::before { content: "offen"; position: absolute; right: 7px; top: 5px; padding: 1px 6px; border-radius: 999px; background: rgba(255, 131, 0, .16); color: #855018; font-size: 7px; font-weight: 900; text-transform: uppercase; letter-spacing: .06em; }
.entry-card.manual { background: var(--manual-soft); border-left: 3px solid var(--manual); color: #14566b; }
.entry-card.manualProject { background: linear-gradient(180deg, #e7f7fb, var(--manual-project-soft)); border-left: 3px solid var(--manual-project); color: #14566b; }
.entry-card.manualAbsence { background: linear-gradient(180deg, #e7f8ef, var(--manual-absence-soft)); border-left: 3px solid var(--manual-absence); color: #1f664e; }
.entry-card.manualNote { background: var(--manual-note-soft); border-left: 3px solid var(--manual-note); color: #464640; }
.entry-card.manualProject, .entry-card.manualAbsence, .entry-card.manualNote { padding: 7px 10px 6px; }
.entry-card.manualProject .card-meta, .entry-card.manualAbsence .card-meta, .entry-card.manualNote .card-meta { margin-top: 6px; opacity: .62; font-size: 8px; }
.entry-card.combined { background: linear-gradient(100deg, var(--violet-soft), var(--coral-soft)); border-left: 3px solid var(--violet); }
.entry-card strong, .entry-card small { display: block; overflow: hidden; overflow-wrap: anywhere; }
.entry-card strong { padding-right: 42px; font-size: 11px; line-height: 1.12; white-space: nowrap; text-overflow: ellipsis; }
.entry-card small { font-size: 9px; line-height: 1.12; opacity: .78; margin-top: 3px; white-space: nowrap; text-overflow: ellipsis; }
.entry-card .card-meta { display: flex; align-items: center; gap: 4px; margin-top: 5px; font-size: 8px; line-height: 1; opacity: .72; white-space: nowrap; overflow: hidden; }
.entry-card .card-meta i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; flex: 0 0 auto; }
.manual-entry-title { padding-right: 0 !important; font-size: 11px !important; line-height: 1.1 !important; letter-spacing: -.01em; text-transform: none; }
.manual-entry-fields { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; padding-right: 2px; overflow: hidden; }
.manual-entry-fields span { min-width: 0; display: block; padding: 3px 7px; border-radius: 999px; background: rgba(255,255,255,.64); overflow: hidden; font-size: 9px; line-height: 1.22; font-weight: 800; box-shadow: inset 0 0 0 1px rgba(255,255,255,.42); }
.manual-entry-fields span.keep-full { flex: 1 1 100%; max-width: 100%; border-radius: 7px; }
.manual-entry-fields span.can-truncate { flex: 1 1 100%; max-width: 100%; }
.manual-entry-fields span::after { content: ": " attr(data-value); min-width: 0; overflow: visible; text-overflow: clip; white-space: normal; overflow-wrap: anywhere; }
.manual-entry-fields span.can-truncate::after { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.manual-entry-fields b { opacity: .72; font-size: 7.5px; font-weight: 900; text-transform: uppercase; letter-spacing: .05em; white-space: nowrap; overflow: visible; }
.entry-detail-popover { position: fixed; z-index: 200; width: min(420px, calc(100vw - 24px)); padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--ink); box-shadow: 0 18px 50px rgba(36, 37, 40, .22); pointer-events: none; }
.entry-detail-popover.project { border-left: 5px solid var(--violet); }
.entry-detail-popover.absence, .entry-detail-popover.pending-absence { border-left: 5px solid var(--coral); }
.entry-detail-popover.manualProject { border-left: 5px solid var(--manual-project); }
.entry-detail-popover.manualAbsence { border-left: 5px solid var(--manual-absence); }
.entry-detail-popover.manualNote { border-left: 5px solid var(--manual-note); }
.day-notice-modal-head .eyebrow { color: var(--day-notice); }
.important-notice-intro { margin: 0 0 16px; padding: 11px 12px; display: flex; align-items: center; gap: 10px; border: 1px solid #e4b266; border-radius: 9px; background: #fff4d4; color: #74372a; font-size: 10px; line-height: 1.4; }
.important-notice-intro > strong { width: 24px; height: 24px; flex: 0 0 24px; display: grid; place-items: center; border-radius: 50%; background: var(--day-notice); color: white; font-size: 14px; }
.rental-address-field { position: relative; }
.rental-address-autocomplete { position: relative; display: block; }
.rental-address-autocomplete > input { width: 100%; font-weight: 400; }
.rental-address-suggestions { position: absolute; z-index: 40; top: calc(100% + 5px); left: 0; right: 0; max-height: 220px; padding: 5px; overflow-y: auto; border: 1px solid var(--line); border-radius: 9px; background: white; box-shadow: 0 14px 32px rgba(35,39,34,.18); }
.rental-address-suggestions button { width: 100%; padding: 9px 10px; border: 0; border-radius: 6px; background: transparent; color: var(--ink); font-size: 10px; font-weight: 700; line-height: 1.35; text-align: left; }
.rental-address-suggestions button:hover,
.rental-address-suggestions button:focus { outline: 0; background: var(--lime-soft); }
.entry-detail-popover header { margin-bottom: 10px; }
.entry-detail-popover header small { display: block; color: var(--muted); font-size: 9px; font-weight: 850; text-transform: uppercase; letter-spacing: .12em; }
.entry-detail-popover header strong { display: block; margin-top: 2px; font-size: 15px; line-height: 1.15; }
.entry-detail-popover dl { margin: 0; display: grid; gap: 7px; }
.entry-detail-popover dl div { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 10px; align-items: start; }
.entry-detail-popover dt { color: var(--muted); font-size: 9px; font-weight: 850; text-transform: uppercase; letter-spacing: .08em; }
.entry-detail-popover dd { margin: 0; font-size: 12px; font-weight: 750; line-height: 1.35; overflow-wrap: anywhere; }
.entry-overflow-badge { pointer-events: auto; position: absolute; min-width: 30px; height: 22px; padding: 0 8px; border: 1px solid var(--line); border-radius: 999px; background: var(--ink); color: white; font-size: 10px; font-weight: 900; box-shadow: 0 5px 14px rgba(36, 37, 40, .16); }
.entry-overflow-badge:hover { transform: translateY(-1px); }
.overflow-popover { position: fixed; z-index: 210; width: min(320px, calc(100vw - 20px)); padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); box-shadow: 0 18px 48px rgba(36, 37, 40, .2); }
.overflow-popover > strong { display: block; padding: 4px 6px 8px; color: var(--muted); font-size: 9px; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; }
.overflow-popover > button { width: 100%; min-height: 44px; padding: 8px 9px; border: 0; border-radius: 8px; background: transparent; text-align: left; color: inherit; cursor: pointer; }
.overflow-popover > button:hover { background: var(--surface-2); }
.overflow-popover span, .overflow-popover small { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.overflow-popover span { font-size: 12px; font-weight: 850; }
.overflow-popover small { margin-top: 2px; color: var(--muted); font-size: 10px; }

.empty-state { position: absolute; inset: 69px 0 0; background: rgba(255,254,250,.92); z-index: 20; display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--muted); }
.empty-state > span { font-size: 34px; }
.empty-state strong { color: var(--ink); margin-top: 8px; }
.empty-state p { margin: 5px; font-size: 12px; }

.modal { width: min(690px, calc(100vw - 28px)); max-height: min(900px, calc(100vh - 28px)); padding: 0; border: 0; border-radius: 16px; background: var(--surface); box-shadow: var(--shadow); color: var(--ink); }
.modal::backdrop { background: rgba(26, 26, 23, .43); backdrop-filter: blur(3px); }
.modal-small { width: min(570px, calc(100vw - 28px)); }
.export-dialog { width: min(1280px, calc(100vw - 24px)); height: min(940px, calc(100dvh - 24px)); max-height: calc(100dvh - 24px); overflow: hidden; }
.export-dialog[open] { display: block; }
.export-dialog > form { height: 100%; display: flex; flex-direction: column; overflow: hidden; }
.export-dialog .modal-head, .export-dialog .modal-foot { flex: 0 0 auto; }
.export-dialog-subline { margin: 5px 0 0; color: var(--muted); font-size: 10px; }
.export-dialog-body { flex: 1 1 auto; min-height: 0; padding: 20px 28px 26px; display: grid; grid-template-columns: minmax(320px, .72fr) minmax(560px, 1.28fr); grid-template-areas: "period employees" "content employees"; align-content: stretch; gap: 18px; overflow: hidden; background: #fbfaf6; }
.export-dialog-body > .export-section:nth-child(1) { grid-area: period; align-self: start; }
.export-dialog-body > .export-section:nth-child(2) { grid-area: employees; min-height: 0; display: flex; flex-direction: column; }
.export-dialog-body > .export-section:nth-child(3) { grid-area: content; align-self: start; }
.export-section { overflow: hidden; border: 1px solid var(--line); border-radius: 13px; background: white; }
.export-section > header { min-height: 58px; padding: 12px 15px; display: flex; align-items: center; gap: 11px; border-bottom: 1px solid var(--line-soft); background: #f8f8f4; }
.export-section > header > span { width: 28px; height: 28px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 9px; background: var(--lime-soft); color: var(--brand-green); font-size: 11px; font-weight: 900; }
.export-section > header > div { min-width: 0; display: grid; gap: 3px; }
.export-section > header strong { font-size: 12px; }
.export-section > header small { color: var(--muted); font-size: 9px; }
.export-scope-options { padding: 13px 15px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.export-scope-options label { min-height: 62px; padding: 10px 12px; display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 10px; background: #fffefa; cursor: pointer; }
.export-scope-options label:has(input:checked) { border-color: #9ec37c; background: #f4faee; box-shadow: inset 3px 0 0 var(--brand-green); }
.export-scope-options input { accent-color: var(--brand-green); }
.export-scope-options span { min-width: 0; display: grid; gap: 3px; }
.export-scope-options strong { font-size: 10px; }
.export-scope-options small { color: var(--muted); font-size: 8px; }
.export-date-fields { padding: 0 15px 15px; display: grid; grid-template-columns: repeat(2, minmax(0, 220px)); gap: 12px; }
.export-employee-toolbar { min-height: 54px; padding: 9px 12px; display: grid; grid-template-columns: minmax(220px, 1fr) auto auto auto; align-items: center; gap: 10px; border-bottom: 1px solid var(--line-soft); }
.export-employee-toolbar > label { height: 36px; padding: 0 10px; display: flex; align-items: center; gap: 7px; border: 1px solid var(--line); border-radius: 8px; background: #fffefa; }
.export-employee-toolbar input { min-width: 0; width: 100%; border: 0; outline: 0; background: transparent; font: inherit; font-size: 9px; }
.export-employee-toolbar > strong { color: #55733c; font-size: 9px; white-space: nowrap; }
.export-employee-list { flex: 1 1 auto; min-height: 0; max-height: none; padding: 13px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-content: start; gap: 9px; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; }
.export-employee-item { min-width: 0; min-height: 58px; padding: 8px 9px; display: grid; grid-template-columns: auto auto minmax(0, 1fr) auto; align-items: center; gap: 8px; border: 1px solid var(--line-soft); border-radius: 9px; background: #fbfaf6; cursor: pointer; }
.export-employee-item:hover { border-color: #cbc5b6; background: white; }
.export-employee-item.selected { border-color: rgba(97,166,14,.42); background: rgba(217,240,108,.11); }
.export-employee-item input { position: absolute; opacity: 0; pointer-events: none; }
.export-employee-item > span { min-width: 0; }
.export-employee-item strong, .export-employee-item small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.export-employee-item strong { font-size: 9px; }
.export-employee-item small { margin-top: 3px; color: var(--muted); font-size: 7px; }
.export-employee-item > b { width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; background: var(--brand-green); color: white; font-size: 9px; opacity: 0; }
.export-employee-item.selected > b { opacity: 1; }
.export-employee-empty { grid-column: 1 / -1; margin: 0; padding: 26px; color: var(--muted); font-size: 9px; text-align: center; }
.export-type-list { padding: 13px 15px; display: flex; flex-wrap: wrap; gap: 7px; }
.export-type-option { min-height: 31px; padding: 5px 10px 5px 6px; display: inline-flex; align-items: center; gap: 7px; border: 1px solid #dedbd2; border-radius: 999px; background: #fff; color: #64645e; font-size: 8px; font-weight: 750; cursor: pointer; transition: border-color .15s ease, background .15s ease, color .15s ease; }
.export-type-option:hover { border-color: #a9c98c; }
.export-type-option.selected { border-color: #b8d896; background: #f5faef; color: #426d1d; }
.export-type-option input { position: absolute; opacity: 0; pointer-events: none; }
.export-type-option span { white-space: nowrap; }
.export-type-list i { width: 17px; height: 17px; display: grid; place-items: center; border-radius: 50%; background: var(--brand-green); color: white; font-size: 8px; font-style: normal; }
.export-type-option:not(.selected) i { background: #eceae4; color: transparent; }
.export-type-list p { margin: 0; color: #a23c2f; font-size: 9px; }
@media (max-width: 1000px) {
  .export-dialog-body { grid-template-columns: 1fr; grid-template-areas: "period" "employees" "content"; align-content: start; overflow-y: auto; scrollbar-gutter: stable; }
  .export-dialog-body > .export-section:nth-child(2) { min-height: 430px; }
  .export-employee-list { flex-basis: auto; min-height: 340px; max-height: 52dvh; }
}
#dayNoticeDialog { width: min(680px, calc(100vw - 28px)); }
.notice-manager-dialog { width: min(820px, calc(100vw - 28px)); height: min(820px, calc(100dvh - 28px)); max-height: calc(100dvh - 28px); padding: 0; overflow: hidden; overscroll-behavior: contain; }
.notice-manager-dialog[open] { display: flex; flex-direction: column; }
body:has(.notice-manager-dialog[open]) { overflow: hidden; }
.notice-manager-head p:last-child { margin: 5px 0 0; color: var(--muted); font-size: 10px; }
.notice-manager-list { flex: 1 1 auto; min-height: 0; max-height: none; padding: 18px 24px 22px; display: flex; flex-direction: column; align-items: stretch; gap: 18px; overflow-y: auto; overscroll-behavior: contain; background: #fbfaf6; scrollbar-gutter: stable; }
.notice-manager-section { flex: 0 0 auto; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: white; }
.notice-manager-section > header { min-height: 46px; padding: 8px 12px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line-soft); background: #fff5e3; }
.notice-manager-section.rental > header { background: #eaf6f3; }
.notice-manager-section > header > span { display: flex; align-items: center; gap: 9px; }
.notice-manager-section > header b { width: 23px; height: 23px; display: grid; place-items: center; border-radius: 50%; background: var(--day-notice); color: white; font-size: 10px; }
.notice-manager-section.rental > header b { background: var(--rental-notice); }
.notice-manager-section > header strong { font-size: 12px; }
.notice-manager-section > header em { min-width: 23px; height: 23px; display: grid; place-items: center; border-radius: 999px; background: rgba(36,34,29,.07); font-size: 9px; font-style: normal; font-weight: 850; }
.notice-manager-section > div { display: grid; }
.notice-manager-item { min-height: 64px; padding: 10px 12px; display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 10px; border-bottom: 1px solid var(--line-soft); }
.notice-manager-item:last-child { border-bottom: 0; }
.notice-manager-item-icon { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; background: #fff0cb; color: var(--day-notice); font-size: 11px; font-weight: 900; }
.notice-manager-section.rental .notice-manager-item-icon { background: #e2f3ef; color: var(--rental-notice); }
.notice-manager-item-copy { min-width: 0; display: grid; gap: 3px; }
.notice-manager-item-copy strong,
.notice-manager-item-copy small,
.notice-manager-item-copy em { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.notice-manager-item-copy strong { color: var(--ink); font-size: 11px; }
.notice-manager-item-copy small { color: #595b55; font-size: 9px; font-weight: 650; }
.notice-manager-item-copy em { color: var(--muted); font-size: 8px; font-style: normal; }
.notice-manager-actions { display: flex; align-items: center; justify-content: flex-end; gap: 7px; }
.notice-manager-planner { min-height: 30px; padding: 6px 10px; border: 1px solid #9eb2df; border-radius: 8px; background: #f3f6ff; color: #244f9d; font-size: 9px; font-weight: 800; white-space: nowrap; }
.notice-manager-planner:hover:not(:disabled) { border-color: #5d7fc3; background: #e8efff; }
.notice-manager-planner.complete { border-color: #b8d798; background: #f1f8e9; color: #477523; }
.notice-manager-planner:disabled { cursor: default; opacity: .72; }
.notice-manager-planner-link { min-height: 30px; display: inline-flex; align-items: center; justify-content: center; padding: 6px 10px; border: 1px solid #9eb2df; border-radius: 8px; background: #fff; color: #244f9d; font-size: 9px; font-weight: 800; line-height: 1; text-decoration: none; white-space: nowrap; }
.notice-manager-planner-link:hover { border-color: #5d7fc3; background: #f3f6ff; }
.notice-manager-delete { width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid #e5beb5; border-radius: 8px; background: #fff8f6; color: #a63f31; font-size: 18px; line-height: 1; }
.notice-manager-delete:hover { border-color: #d88b7d; background: #fff0ed; }
@media (max-width: 700px) {
  .notice-manager-item { grid-template-columns: 30px minmax(0, 1fr); }
  .notice-manager-actions { grid-column: 2; justify-content: flex-start; }
}
.notice-manager-empty { min-height: 210px; display: grid; place-items: center; align-content: center; gap: 7px; color: var(--muted); text-align: center; }
.notice-manager-empty > b { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: var(--lime-soft); color: var(--brand-green); font-size: 17px; }
.notice-manager-empty > strong { color: var(--ink); font-size: 12px; }
.notice-manager-empty > small { font-size: 9px; }
.notice-manager-dialog .modal-head,
.notice-manager-dialog .modal-foot { flex: 0 0 auto; }
.notice-manager-dialog .modal-foot > small { color: var(--muted); font-size: 8px; }
.modal-head { padding: 22px 24px 17px; display: flex; align-items: flex-start; justify-content: space-between; border-bottom: 1px solid var(--line); }
.modal-head h2 { margin: 0; font-family: inherit; font-size: 28px; font-weight: 500; letter-spacing: -.02em; }
.close-button { margin: -5px -7px 0 0; font-size: 25px; color: var(--muted); }
.form-grid { padding: 21px 24px; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { min-width: 0; display: grid; gap: 6px; }
.field-wide { grid-column: 1 / -1; }
.field-group { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field > span { font-size: 11px; font-weight: 800; }
.field > small { color: var(--muted); font-size: 9px; font-weight: 650; line-height: 1.35; }
.field em { font-style: normal; font-weight: 600; color: var(--muted); background: var(--surface-2); padding: 2px 5px; border-radius: 4px; margin-left: 4px; font-size: 8px; text-transform: uppercase; letter-spacing: .06em; }
.field input:not([type=color]), .field select, .field textarea { width: 100%; min-width: 0; border: 1px solid var(--line); background: white; border-radius: 8px; padding: 10px 11px; color: var(--ink); outline: 0; font-size: 12px; }
.field input:not([type=color]), .field select { height: 40px; }
.field textarea { resize: vertical; min-height: 82px; line-height: 1.5; }
.field .field-help { color: var(--muted); font-size: 9px; font-weight: 500; line-height: 1.4; }
.note-visibility-field { margin: 0; padding: 0; border: 0; }
.note-visibility-field legend { margin-bottom: 8px; color: var(--ink); font-size: 11px; font-weight: 800; }
.note-visibility-field legend em { margin-left: 6px; padding: 0; border-radius: 0; color: #8b6313; background: none; font-size: 8px; font-style: normal; letter-spacing: .08em; text-transform: uppercase; }
.note-visibility-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.note-visibility-options label { display: flex; min-width: 0; gap: 10px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: #fff; cursor: pointer; transition: border-color .16s ease, background .16s ease, box-shadow .16s ease; }
.note-visibility-options label:has(input:checked) { border-color: var(--brand-green); background: #f3f9e9; box-shadow: 0 0 0 2px rgba(97, 166, 14, .12); }
.note-visibility-options input { width: auto !important; height: auto !important; margin-top: 2px; accent-color: var(--brand-green); }
.note-visibility-options span { display: grid; min-width: 0; gap: 2px; }
.note-visibility-options strong { font-size: 11px; }
.note-visibility-options small { color: var(--muted); font-size: 9px; line-height: 1.35; }
.note-visibility-field > .field-help { display: block; margin-top: 7px; }
.audience-picker { display: grid; gap: 8px; margin-top: 10px; padding: 11px; border: 1px solid var(--line); border-radius: 12px; background: #f8f8f5; }
.audience-picker > strong { color: var(--ink); font-size: 10px; }
.audience-choice-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; max-height: 150px; overflow-y: auto; padding-right: 3px; }
.audience-choice-list label { display: flex; align-items: center; gap: 7px; min-width: 0; padding: 7px 9px; border: 1px solid #deddd5; border-radius: 9px; background: white; color: var(--ink); font-size: 10px; cursor: pointer; }
.audience-choice-list label:has(input:checked) { border-color: var(--brand-green); background: #f1f8e5; }
.audience-choice-list input { width: auto !important; height: auto !important; flex: 0 0 auto; accent-color: var(--brand-green); }
.audience-choice-list span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.audience-choice-list .audience-empty { grid-column: 1 / -1; padding: 8px; color: var(--muted); font-size: 9px; }
.expiry-datetime-field { margin-top: 12px; }
@media (max-width: 620px) { .note-visibility-options, .field-group, .audience-choice-list { grid-template-columns: 1fr; } }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #c4c0b5; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--violet); box-shadow: 0 0 0 3px rgba(117,96,207,.1); }
.field input.overridden, .field select.overridden, .field textarea.overridden { border-color: var(--blue); background: #f7fbfd; }
.weekday-toggle-group { display: flex; flex-wrap: wrap; gap: 7px; }
.weekday-toggle-group button { width: 38px; height: 34px; border: 1px solid var(--line); border-radius: 8px; background: white; color: var(--muted); font-size: 11px; font-weight: 900; cursor: pointer; }
.weekday-toggle-group button:hover { border-color: var(--brand-green); color: var(--brand-green); }
.weekday-toggle-group button.active { border-color: var(--brand-green); background: var(--brand-green); color: white; box-shadow: 0 4px 12px rgba(97,166,14,.2); }
.source-value { display: none; color: var(--muted); font-size: 9px; }
.source-value.visible { display: block; }
.source-value button { border: 0; padding: 0; background: transparent; color: #5d50a3; font-size: inherit; font-weight: 700; }
.color-field { grid-template-columns: auto 1fr; align-items: center; }
.color-field > span { grid-column: 1 / -1; }
.color-field input[type=color] { width: 54px; height: 38px; border: 1px solid var(--line); border-radius: 8px; padding: 4px; background: white; }
.color-field small { color: var(--muted); font-size: 9px; }
.source-banner { margin: 20px 24px 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: 9px; display: flex; align-items: center; gap: 11px; background: #faf9f5; }
.source-banner .source-logo { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 7px; color: white; background: var(--violet); font-weight: 900; }
.source-banner.personio .source-logo { background: var(--coral); }
.source-banner.combined .source-logo { background: linear-gradient(135deg, var(--violet), var(--coral)); }
.source-banner strong, .source-banner small { display: block; }
.source-banner strong { font-size: 11px; }
.source-banner small { color: var(--muted); font-size: 9px; margin-top: 2px; }
.modal-foot { padding: 15px 24px 20px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 9px; }
.spacer { flex: 1; }
.helper-text { color: var(--muted); font-size: 9px; max-width: 300px; line-height: 1.4; }

.team-list { padding: 8px 24px 22px; max-height: 480px; overflow: auto; }
.team-row { width: 100%; border-bottom: 1px solid var(--line-soft); background: transparent; padding: 8px 2px; display: flex; align-items: center; gap: 7px; text-align: left; transition: background .14s, transform .14s; }
.team-row:hover { background: #faf9f5; }
.team-row.dragging { opacity: .48; }
.team-row.drop-before { box-shadow: inset 0 3px 0 var(--violet); }
.team-row.drop-after { box-shadow: inset 0 -3px 0 var(--violet); }
.drag-handle { flex: 0 0 23px; color: #aaa79d; font-size: 16px; text-align: center; cursor: grab; user-select: none; }
.drag-handle:active { cursor: grabbing; }
.team-edit { min-width: 0; flex: 1; border: 0; background: transparent; padding: 5px 3px; display: flex; align-items: center; gap: 11px; text-align: left; }
.team-edit:hover strong { color: var(--violet); }
.team-row .avatar { width: 38px; height: 38px; flex-basis: 38px; }
.team-member-copy { flex: 1; min-width: 0; }
.team-row strong, .team-row small { display: block; }
.team-row strong { font-size: 12px; }
.team-row small { color: var(--muted); font-size: 9px; margin-top: 2px; }
.team-member-copy .group-tags { margin-top: 4px; }
.team-member-copy .group-tags i { background: var(--surface-2); }
.team-row .external-ids { font-size: 9px; color: var(--muted); text-align: right; }
.sort-actions { display: grid; grid-template-columns: 25px 25px; gap: 3px; }
.sort-actions button { width: 25px; height: 25px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--muted); font-size: 12px; line-height: 1; }
.sort-actions button:hover:not(:disabled) { border-color: var(--violet); color: var(--violet); }
.sort-actions button:disabled { opacity: .3; cursor: default; }

.settings-modal { width: min(1040px, calc(100vw - 28px)); }
.settings-modal > form { display: flex; max-height: min(900px, calc(100vh - 28px)); flex-direction: column; }
.settings-tabs { padding: 12px 24px 0; display: flex; gap: 6px; border-bottom: 1px solid var(--line); }
.settings-tabs button { min-height: 36px; margin-bottom: -1px; padding: 0 13px; border: 1px solid transparent; border-radius: 8px 8px 0 0; background: transparent; color: var(--muted); font-size: 10px; font-weight: 850; cursor: pointer; }
.settings-tabs button.active { border-color: var(--line); border-bottom-color: var(--surface); background: var(--surface); color: var(--ink); }
.settings-content { min-height: 420px; overflow: auto; }
.settings-section-head { margin: 22px 24px 12px; display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.settings-section-head h3, .settings-section-head p { margin: 0; }
.settings-section-head h3 { font-size: 14px; }
.settings-section-head p { margin-top: 4px; color: var(--muted); font-size: 10px; line-height: 1.4; }
.settings-rule-table, .permission-matrix { margin: 0 24px 18px; overflow: hidden; border: 1px solid var(--line); border-radius: 11px; }
.settings-rule-row { display: grid; grid-template-columns: minmax(210px, 1fr) 145px 145px; align-items: center; min-height: 48px; border-bottom: 1px solid var(--line-soft); }
.settings-rule-row:last-child { border-bottom: 0; }
.settings-rule-row.header { min-height: 36px; background: var(--surface-2); color: var(--muted); font-size: 8px; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; }
.settings-rule-row > * { padding: 9px 13px; }
.settings-rule-row > * + * { border-left: 1px solid var(--line-soft); }
.settings-rule-row strong, .settings-rule-row small { display: block; }
.settings-rule-row strong { font-size: 11px; }
.settings-rule-row small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.settings-check { display: inline-flex; align-items: center; justify-content: center; gap: 7px; color: var(--muted); font-size: 9px; font-weight: 750; cursor: pointer; }
.settings-check input { width: 17px; height: 17px; accent-color: var(--brand-green); }
.settings-select-row { margin: 0 24px 14px; padding: 13px 15px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border: 1px solid var(--line); border-radius: 10px; font-size: 11px; font-weight: 800; }
.settings-select-row select { min-width: 210px; height: 36px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; background: white; color: var(--ink); }
.settings-info { margin: 0 24px 20px; padding: 11px 13px; border-radius: 9px; background: rgba(217,240,108,.2); color: #626653; font-size: 9px; line-height: 1.5; }
.permission-matrix { overflow-x: auto; }
.permission-grid { min-width: 760px; display: grid; grid-template-columns: minmax(250px, 1fr) repeat(3, 145px); }
.permission-grid > * { min-height: 42px; padding: 9px 13px; display: flex; align-items: center; border-right: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.permission-grid > *:nth-child(4n) { border-right: 0; }
.permission-grid .permission-head { min-height: 38px; background: var(--surface-2); color: var(--muted); font-size: 8px; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; }
.permission-grid .permission-label { display: block; }
.permission-grid .permission-label strong, .permission-grid .permission-label small { display: block; }
.permission-grid .permission-label strong { font-size: 10px; }
.permission-grid .permission-label small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.permission-grid label { justify-content: center; }
.role-editor-toolbar, .role-assignment-add { margin: 0 24px 18px; padding: 14px; display: grid; grid-template-columns: minmax(170px, 240px) minmax(220px, 1fr) auto auto auto; align-items: end; gap: 10px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface-2); }
.role-editor-toolbar label, .role-assignment-add label { min-width: 0; display: grid; gap: 5px; }
.role-editor-toolbar label > span, .role-assignment-add label > span { color: var(--muted); font-size: 8px; font-weight: 900; letter-spacing: .07em; text-transform: uppercase; }
.role-editor-toolbar select, .role-editor-toolbar input, .role-assignment-add select, .role-assignment-add input { width: 100%; height: 37px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); font: inherit; font-size: 10px; }
.permission-modules { margin: 0 24px 22px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.permission-module { overflow: hidden; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); }
.permission-module > header { min-height: 54px; padding: 10px 13px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line-soft); background: var(--surface-2); }
.permission-module > header span, .permission-module > header strong, .permission-module > header small { display: block; }
.permission-module > header strong { font-size: 11px; }
.permission-module > header small { margin-top: 2px; color: var(--muted); font-size: 8px; font-weight: 500; }
.permission-module > header b { flex: 0 0 auto; padding: 4px 7px; border-radius: 10px; background: #e5e2da; color: var(--muted); font-size: 8px; }
.permission-item { position: relative; min-height: 54px; padding: 9px 12px; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 10px; border-bottom: 1px solid var(--line-soft); cursor: pointer; }
.permission-item:last-child { border-bottom: 0; }
.permission-item > span, .permission-item strong, .permission-item small { min-width: 0; display: block; }
.permission-item strong { font-size: 10px; }
.permission-item small { margin-top: 2px; color: var(--muted); font-size: 8px; line-height: 1.35; }
.permission-item input { position: absolute; z-index: 2; right: 12px; width: 34px; height: 19px; margin: 0; opacity: 0; cursor: pointer; }
.permission-item > i { position: relative; width: 34px; height: 19px; border-radius: 12px; background: #d8d5cd; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); transition: background .15s ease; }
.permission-item > i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 13px; height: 13px; border-radius: 50%; background: white; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .15s ease; }
.permission-item.enabled { background: rgba(217,240,108,.09); }
.permission-item.enabled > i { background: var(--brand-green); }
.permission-item.enabled > i::after { transform: translateX(15px); }
.permission-item:has(input:disabled) { cursor: default; opacity: .76; }
.employee-access-head { margin-top: 30px; }
.role-employee-access { margin: 0 24px 24px; overflow: hidden; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); }
.role-employee-access-toolbar { padding: 12px; display: grid; grid-template-columns: minmax(190px, 1fr) minmax(210px, 1fr) minmax(220px, .9fr) auto; align-items: center; gap: 9px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.employee-access-mode { min-height: 52px; padding: 8px 10px; display: flex; align-items: center; gap: 9px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); cursor: pointer; }
.employee-access-mode:has(input:checked) { border-color: rgba(97,166,14,.7); background: rgba(217,240,108,.17); box-shadow: inset 3px 0 0 var(--brand-green); }
.employee-access-mode input { accent-color: var(--brand-green); }
.employee-access-mode span, .employee-access-mode strong, .employee-access-mode small { display: block; }
.employee-access-mode strong { font-size: 10px; }
.employee-access-mode small { margin-top: 2px; color: var(--muted); font-size: 7px; line-height: 1.3; }
.employee-access-search { display: grid; gap: 5px; }
.employee-access-search > span { color: var(--muted); font-size: 8px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
.employee-access-search input { width: 100%; height: 37px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); font: inherit; font-size: 10px; }
.employee-access-actions { display: grid; gap: 4px; justify-items: start; }
.employee-access-actions button { white-space: nowrap; }
.employee-access-actions button:disabled { cursor: default; opacity: .4; }
.role-employee-access-summary { min-height: 43px; padding: 8px 12px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--line-soft); }
.role-employee-access-summary strong { font-size: 10px; }
.role-employee-access-summary span { color: var(--muted); font-size: 8px; }
.role-employee-list { max-height: 390px; padding: 10px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; overflow-y: auto; }
.role-employee-item { min-width: 0; min-height: 54px; padding: 7px 9px; display: grid; grid-template-columns: auto auto minmax(0, 1fr) auto; align-items: center; gap: 8px; border: 1px solid var(--line-soft); border-radius: 8px; background: #fbfaf6; cursor: pointer; }
.role-employee-item:hover { border-color: #ccc6b7; background: white; }
.role-employee-item.selected { border-color: rgba(97,166,14,.38); background: rgba(217,240,108,.1); }
.role-employee-item input { width: 15px; height: 15px; accent-color: var(--brand-green); }
.role-employee-item > i { width: 29px; height: 29px; display: grid; place-items: center; border-radius: 50%; background: var(--employee-color, #77766f); color: white; font-size: 8px; font-style: normal; font-weight: 900; box-shadow: 0 0 0 3px color-mix(in srgb, var(--employee-color, #77766f) 20%, transparent); }
.role-employee-item > span, .role-employee-item strong, .role-employee-item small { min-width: 0; display: block; }
.role-employee-item strong { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.role-employee-item small { margin-top: 2px; overflow: hidden; color: var(--muted); font-size: 7px; text-overflow: ellipsis; white-space: nowrap; }
.role-employee-item > b { width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; background: var(--brand-green); color: white; font-size: 9px; opacity: 0; }
.role-employee-item.selected > b { opacity: 1; }
.role-employee-list.all-mode .role-employee-item { cursor: default; opacity: .76; }
.role-employee-empty { grid-column: 1 / -1; margin: 0; padding: 28px; color: var(--muted); font-size: 9px; text-align: center; }
.account-assignment-head { margin-top: 28px; }
.role-assignment-add { grid-template-columns: minmax(220px, 1fr) minmax(170px, 240px) auto; }
.role-assignment-list { margin: 0 24px 18px; overflow: hidden; border: 1px solid var(--line); border-radius: 11px; }
.role-assignment-row { min-height: 48px; padding: 8px 12px; display: flex; align-items: center; gap: 12px; border-bottom: 1px solid var(--line-soft); }
.role-assignment-row:last-child { border-bottom: 0; }
.role-assignment-row > span, .role-assignment-row strong, .role-assignment-row small { display: block; }
.role-assignment-row > span { min-width: 0; flex: 1; }
.role-assignment-row strong { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.role-assignment-row small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.role-assignment-row button { width: 29px; height: 29px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); color: #a33f31; cursor: pointer; }
.role-assignment-empty { margin: 0; padding: 18px; color: var(--muted); font-size: 9px; text-align: center; }
.privacy-note { margin: 20px 24px; padding: 11px 13px; display: flex; gap: 10px; align-items: flex-start; border-radius: 8px; background: rgba(217,240,108,.24); }
.privacy-note > span { font-size: 19px; }
.privacy-note p { margin: 0; color: #626653; font-size: 10px; line-height: 1.4; }
.privacy-note strong { display: block; color: var(--ink); }
.integration-card { margin: 0 24px 16px; padding: 17px; border: 1px solid var(--line); border-radius: 11px; }
.integration-head { display: flex; align-items: center; gap: 12px; margin-bottom: 15px; }
.integration-logo { width: 38px; height: 38px; border-radius: 9px; display: grid; place-items: center; color: white; font-family: inherit; font-weight: 800; font-size: 20px; }
.rentman-logo { background: var(--violet); }
.personio-logo { background: var(--coral); }
.integration-head h3, .integration-head p { margin: 0; }
.integration-head h3 { font-size: 14px; }
.integration-head p { color: var(--muted); font-size: 9px; margin-top: 2px; }
.connection-pill { margin-left: auto; padding: 5px 8px; border-radius: 10px; background: var(--surface-2); color: var(--muted); font-size: 8px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.connection-pill.connected { color: #526617; background: rgba(217,240,108,.4); }
.integration-card .form-grid { padding: 0; }
.integration-actions { margin-top: 9px; display: flex; align-items: center; justify-content: space-between; }
.integration-actions small { color: var(--muted); font-size: 9px; }
.text-button { border: 0; background: transparent; padding: 0; color: #a33f31; font-size: 9px; font-weight: 700; }

.timeline-row.duplicate-target::after { content: "Hier duplizieren"; position: absolute; z-index: 25; inset: 4px 6px 4px var(--name-width); display: grid; place-items: center; border: 2px dashed var(--brand-green); border-radius: 9px; background: rgba(217,240,108,.18); color: #526617; font-size: 10px; font-weight: 900; pointer-events: none; }
.entry-card.can-duplicate { cursor: grab; }
.entry-card.can-duplicate:active { cursor: grabbing; }
.entry-card.duplicate-hold { box-shadow: 0 0 0 2px color-mix(in srgb, var(--brand-green) 55%, transparent), 0 7px 18px rgba(43,40,31,.12); }
.entry-card.duplicate-source { opacity: .58; }
.entry-duplicate-ghost { position: fixed; z-index: 500; width: 230px; max-width: calc(100vw - 24px); padding: 9px 11px; border: 1px solid rgba(36,37,40,.14); border-left: 4px solid var(--brand-green); border-radius: 9px; background: var(--surface); color: var(--ink); box-shadow: 0 14px 34px rgba(36,37,40,.25); pointer-events: none; transform: translate(13px, 13px); }
.entry-duplicate-ghost strong, .entry-duplicate-ghost small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.entry-duplicate-ghost strong { font-size: 11px; }
.entry-duplicate-ghost small { margin-top: 3px; color: var(--muted); font-size: 8px; }
body.duplicating-entry, body.duplicating-entry * { cursor: copy !important; user-select: none !important; }

.logs-modal { width: min(920px, calc(100vw - 28px)); }
.logs-tabs { width: max-content; margin: 16px 24px 2px; padding: 4px; display: flex; gap: 5px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); }
.logs-tabs button { min-height: 34px; padding: 0 13px; display: inline-flex; align-items: center; gap: 8px; border: 0; border-radius: 7px; background: transparent; color: var(--muted); font-size: 10px; font-weight: 850; }
.logs-tabs button b { min-width: 20px; height: 20px; padding: 0 6px; display: grid; place-items: center; border-radius: 999px; background: rgba(36,37,40,.08); font-size: 8px; }
.logs-tabs button.active { background: var(--ink); color: white; }
.logs-tabs button.active b { background: rgba(255,255,255,.16); }
.logs-intro { margin: 18px 24px 4px; color: var(--muted); font-size: 10px; line-height: 1.5; }
.logs-list { max-height: min(600px, calc(100vh - 245px)); overflow: auto; padding: 10px 24px 22px; display: grid; gap: 15px; }
.logs-empty { min-height: 240px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: var(--muted); }
.logs-empty > span { font-size: 28px; }
.logs-empty strong { margin-top: 8px; color: var(--ink); font-size: 13px; }
.logs-empty p { max-width: 360px; margin: 5px 0 0; font-size: 10px; line-height: 1.5; }
.log-batch { border: 1px solid var(--line); border-radius: 11px; overflow: hidden; background: #fcfbf7; }
.log-batch > header { padding: 13px 15px; display: flex; align-items: center; justify-content: space-between; gap: 15px; border-bottom: 1px solid var(--line); background: #f1eee5; }
.log-batch header time, .log-batch header strong { display: block; }
.log-batch header time { color: var(--brand-orange); font-size: 9px; font-weight: 850; text-transform: uppercase; letter-spacing: .05em; }
.log-batch header strong { margin-top: 2px; font-size: 13px; }
.log-batch header p { margin: 0; color: var(--muted); font-size: 9px; text-align: right; }
.log-change { border-bottom: 1px solid var(--line-soft); background: white; }
.log-change:last-child { border-bottom: 0; }
.log-change summary { position: relative; padding: 11px 14px 11px 22px; display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; align-items: center; gap: 11px; list-style: none; cursor: pointer; user-select: none; touch-action: manipulation; }
.log-change summary::-webkit-details-marker { display: none; }
.log-change summary::before { content: "›"; position: absolute; left: 8px; top: 50%; color: var(--muted); transform: translateY(-50%); transition: transform .15s; }
.log-change[open] summary::before { transform: translateY(-50%) rotate(90deg); }
.log-change-kind { color: var(--muted); font-size: 8px; font-weight: 850; text-transform: uppercase; letter-spacing: .06em; }
.log-change-title { min-width: 0; }
.log-change-title strong, .log-change-title small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.log-change-title strong { font-size: 11px; }
.log-change-title small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.log-action { min-width: 61px; padding: 4px 7px; border-radius: 10px; background: var(--surface-2); color: var(--muted); font-size: 8px; font-weight: 850; text-align: center; text-transform: uppercase; letter-spacing: .05em; }
.log-change.added .log-action { background: rgba(217,240,108,.35); color: #556516; }
.log-change.removed .log-action { background: var(--coral-soft); color: #8b4432; }
.log-change.changed .log-action { background: var(--blue-soft); color: #376b8d; }
.log-fields { padding: 3px 14px 13px 110px; display: grid; gap: 5px; }
.log-field { display: grid; grid-template-columns: minmax(100px, .8fr) minmax(120px, 1fr) 20px minmax(120px, 1fr); align-items: center; gap: 7px; font-size: 9px; }
.log-field > strong { color: var(--muted); font-size: 9px; }
.log-value { min-width: 0; padding: 6px 7px; border-radius: 6px; overflow-wrap: anywhere; background: var(--surface-2); }
.log-value strong { font-weight: 900; color: inherit; }
.log-value > i { margin: 0 0 5px; display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 7px; font-style: normal; font-weight: 850; text-transform: uppercase; letter-spacing: .06em; }
.log-value > i em { padding: 2px 5px; border-radius: 999px; background: rgba(97, 166, 14, .12); color: #477b10; font-size: 6px; font-style: normal; white-space: nowrap; }
.log-value.before { color: #7e5c55; }
.log-value.after { background: #edf3f6; color: #315f7c; }
.log-diff-added { margin: 0 -1px; padding: 1px 2px; border-radius: 3px; background: #dff29c; box-shadow: inset 0 -2px 0 rgba(82, 139, 19, .36); color: #263d12; font-weight: 800; }
.log-diff-removed { padding: 2px 5px; border-radius: 4px; background: #f6d7cf; color: #8b4432; font-weight: 800; }
.log-arrow { color: var(--muted); text-align: center; }
.log-no-details { margin: 5px 0; color: var(--muted); font-size: 9px; }

.logs-page { height: auto; min-height: 100vh; overflow-x: hidden; overflow-y: auto; background: var(--paper); }
.logs-page-shell { height: auto; min-height: 100dvh; display: block; }
.logs-page-header { min-height: 106px; padding: 17px clamp(18px, 2.3vw, 38px); display: grid; grid-template-columns: auto minmax(330px, 1fr) auto; align-items: center; gap: clamp(20px, 3vw, 48px); border-bottom: 1px solid var(--line); background: rgba(244, 241, 234, .96); }
.logs-page-title { min-width: 0; padding-left: clamp(20px, 2.5vw, 40px); border-left: 1px solid var(--line); }
.logs-title-line { display: flex; align-items: center; gap: 9px; }
.logs-title-line .eyebrow { margin: 0; }
.logs-source-badge { padding: 4px 7px; border-radius: 10px; background: rgba(97,166,14,.13); color: var(--brand-green); font-size: 8px; font-weight: 850; text-transform: uppercase; letter-spacing: .06em; }
.logs-page-title h1 { margin: 4px 0 0; font-size: clamp(25px, 2.3vw, 39px); }
.logs-page-title > p { margin: 6px 0 0; color: var(--muted); font-size: clamp(10px, .8vw, 13px); }
.logs-page-actions { display: flex; align-items: center; gap: 8px; }
.logs-page-actions .button.loading .button-icon { animation: spin .8s linear infinite; }
.logs-page-main { min-height: 0; padding: clamp(13px, 1.5vw, 24px) clamp(16px, 2.3vw, 38px); display: grid; grid-template-rows: auto auto; gap: clamp(10px, 1vw, 16px); }
.logs-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(8px, 1vw, 14px); }
.logs-summary article { position: relative; min-width: 0; padding: clamp(10px, 1vw, 15px) clamp(12px, 1.2vw, 18px); overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.logs-summary article::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--brand-green); opacity: .75; }
.logs-summary article.rentman::before { background: var(--violet); }
.logs-summary article.personio::before { background: var(--coral); }
.logs-summary small, .logs-summary strong, .logs-summary span { display: block; }
.logs-summary small { color: var(--muted); font-size: clamp(8px, .55vw, 10px); font-weight: 850; text-transform: uppercase; letter-spacing: .07em; }
.logs-summary strong { margin-top: 5px; overflow: hidden; font-size: clamp(19px, 1.55vw, 27px); line-height: 1.05; text-overflow: ellipsis; white-space: nowrap; }
.logs-summary span { margin-top: 5px; overflow: hidden; color: var(--muted); font-size: clamp(8px, .52vw, 10px); text-overflow: ellipsis; white-space: nowrap; }
.logs-page-panel { min-height: 0; display: grid; grid-template-rows: auto auto auto; overflow: visible; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); box-shadow: 0 8px 34px rgba(50,48,38,.06); }
.logs-page-panel-head { min-height: 54px; padding: 10px 16px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid var(--line); background: #f1eee5; }
.logs-page-panel-head h2, .logs-page-panel-head p { margin: 0; }
.logs-page-panel-head h2 { font-size: 13px; }
.logs-page-panel-head p, .logs-page-panel-head > small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.logs-page-panel-head > small { flex: 0 0 auto; margin: 0; }
.logs-page-toolbar { padding: 9px 14px; border-bottom: 1px solid var(--line-soft); background: #fbfaf6; }
.logs-page-tabs { width: max-content; max-width: 100%; padding: 4px; display: flex; gap: 5px; overflow-x: auto; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.logs-page-tabs button { min-height: 34px; padding: 0 13px; display: inline-flex; align-items: center; gap: 8px; border: 0; border-radius: 7px; background: transparent; color: var(--muted); font-size: 10px; font-weight: 850; white-space: nowrap; }
.logs-page-tabs button b { min-width: 20px; height: 20px; padding: 0 6px; display: grid; place-items: center; border-radius: 999px; background: rgba(36,37,40,.08); font-size: 8px; }
.logs-page-tabs button.active { background: var(--ink); color: white; }
.logs-page-tabs button.active b { background: rgba(255,255,255,.16); }
.logs-page-content { min-height: 260px; padding: 14px; display: grid; align-content: start; gap: 13px; overflow: visible; background: #fbfaf6; border-radius: 0 0 13px 13px; }
.logs-page-batch { box-shadow: 0 4px 16px rgba(50,48,38,.04); }
.logs-page-batch.current { border-color: rgba(97,166,14,.55); box-shadow: 0 0 0 2px rgba(97,166,14,.08), 0 6px 20px rgba(50,48,38,.06); }
.logs-page-batch > header { min-height: 69px; padding: 10px 14px; display: grid; grid-template-columns: auto minmax(155px, .8fr) auto minmax(210px, 1fr) auto auto; align-items: center; justify-content: stretch; gap: 12px; cursor: pointer; user-select: none; }
.logs-page-batch > header:hover { background: #ebe8de; }
.logs-page-batch > header:focus-visible { outline: 3px solid rgba(97,166,14,.24); outline-offset: -3px; }
.logs-page-batch:not(.expanded) > .log-changes { display: none; }
.log-batch-chevron { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 7px; background: rgba(36,37,40,.07); color: var(--muted); font-size: 16px; font-weight: 900; transition: transform .16s, background .16s; }
.logs-page-batch.expanded .log-batch-chevron { transform: rotate(180deg); background: rgba(97,166,14,.18); color: #526617; }
.log-source-icon { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 9px; background: var(--violet); color: white; font-size: 13px; font-weight: 900; }
.logs-page-batch.personio .log-source-icon { background: var(--coral); }
.log-batch-time time, .log-batch-time small { display: block; }
.log-batch-time time { color: var(--ink); font-size: 11px; font-weight: 850; text-transform: none; letter-spacing: 0; }
.log-batch-time small { margin-top: 3px; color: var(--muted); font-size: 8px; font-weight: 700; }
.log-batch-count { min-width: 74px; display: flex; align-items: baseline; gap: 5px; }
.log-batch-count strong { margin: 0; font-size: 20px; line-height: 1; }
.log-batch-count span { color: var(--muted); font-size: 8px; font-weight: 750; }
.logs-page-batch > header > p { text-align: left; }
.log-new-pill { min-width: 55px; padding: 5px 8px; border-radius: 999px; background: rgba(217,240,108,.48); color: #526617; font-size: 8px; font-weight: 900; text-align: center; text-transform: uppercase; letter-spacing: .06em; }
.logs-page-batch .log-change summary { min-height: 57px; grid-template-columns: 112px minmax(0, 1fr) auto; padding-top: 9px; padding-bottom: 9px; }
.logs-page-batch .log-change:hover { background: #fdfcf8; }
.logs-page-batch .log-change summary:hover { box-shadow: inset 3px 0 0 rgba(117,96,207,.4); }
.logs-page-batch.personio .log-change summary:hover { box-shadow: inset 3px 0 0 rgba(216,117,89,.45); }
.logs-page-batch .log-change-kind { padding: 4px 7px; width: fit-content; border-radius: 6px; background: var(--surface-2); }
.logs-page-batch.personio .log-change-kind { background: var(--coral-soft); color: #8b4432; }
.logs-page-batch .log-change-title strong { font-size: 12px; }
.logs-page-batch .log-change-title small { font-size: 9px; }
.logs-page-batch .log-fields { padding: 4px 16px 16px 134px; gap: 8px; }
.logs-page-batch .log-field { grid-template-columns: minmax(125px, .7fr) minmax(190px, 1fr) 25px minmax(190px, 1fr); gap: 9px; font-size: 10px; }
.logs-page-batch .log-field > strong { font-size: 10px; }
.logs-page-batch .log-value { min-height: 36px; padding: 7px 9px; line-height: 1.45; }
.logs-page-batch .log-value i { display: block; margin-bottom: 3px; color: currentColor; font-size: 7px; font-style: normal; font-weight: 900; opacity: .62; text-transform: uppercase; letter-spacing: .06em; }
.logs-loading, .logs-error { min-height: 260px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: var(--muted); }
.logs-loading span { width: 26px; height: 26px; margin-bottom: 10px; border: 3px solid var(--line); border-top-color: var(--brand-green); border-radius: 50%; animation: spin .8s linear infinite; }
.logs-loading strong, .logs-error strong { color: var(--ink); font-size: 12px; }
.logs-error p { max-width: 420px; margin: 5px 0 0; font-size: 10px; }

.statistics-page { min-height: 100vh; overflow-x: hidden; overflow-y: auto; background: var(--paper); }
.statistics-page-shell { min-height: 100dvh; height: auto; display: grid; grid-template-rows: auto auto; align-content: start; }
.statistics-page-header { min-height: 106px; padding: 17px clamp(18px, 2.3vw, 38px); display: grid; grid-template-columns: auto minmax(330px, 1fr) auto; align-items: center; gap: clamp(20px, 3vw, 48px); border-bottom: 1px solid var(--line); background: rgba(244, 241, 234, .96); }
.statistics-page-title { min-width: 0; padding-left: clamp(20px, 2.5vw, 40px); border-left: 1px solid var(--line); }
.statistics-title-line { display: flex; align-items: center; gap: 9px; }
.statistics-title-line .eyebrow { margin: 0; }
.statistics-source-badge { padding: 4px 7px; border-radius: 10px; background: rgba(97,166,14,.13); color: var(--brand-green); font-size: 8px; font-weight: 850; text-transform: uppercase; letter-spacing: .06em; }
.statistics-page-title h1 { margin: 4px 0 0; font-size: clamp(25px, 2.3vw, 39px); }
.statistics-page-title > p { margin: 6px 0 0; color: var(--muted); font-size: clamp(10px, .8vw, 13px); }
.statistics-page-actions { display: flex; align-items: center; gap: 8px; }
.statistics-page-actions .button.loading .button-icon { animation: spin .8s linear infinite; }
.statistics-page-main { min-height: 0; padding: clamp(13px, 1.5vw, 24px) clamp(16px, 2.3vw, 38px); display: grid; grid-template-rows: auto auto; align-content: start; gap: clamp(10px, 1vw, 16px); }

.config-page { min-height: 100vh; overflow-x: hidden; overflow-y: auto; background: var(--paper); }
.config-page-shell { min-height: 100dvh; display: grid; grid-template-rows: auto 1fr; }
.config-page-header { min-height: 106px; padding: 17px clamp(18px, 2.3vw, 38px); display: grid; grid-template-columns: auto minmax(330px, 1fr) auto; align-items: center; gap: clamp(20px, 3vw, 48px); border-bottom: 1px solid var(--line); background: rgba(244,241,234,.96); }
.config-page-title { min-width: 0; padding-left: clamp(20px, 2.5vw, 40px); border-left: 1px solid var(--line); }
.config-title-line { display: flex; align-items: center; gap: 8px; }
.config-title-line .eyebrow { margin: 0; }
.config-source-badge { padding: 3px 7px; border-radius: 999px; background: rgba(217,240,108,.32); color: #526617; font-size: 7px; font-weight: 900; text-transform: uppercase; letter-spacing: .06em; }
.config-page-title h1 { margin: 4px 0 0; font-size: clamp(25px, 2.3vw, 39px); }
.config-page-title > p { margin: 6px 0 0; color: var(--muted); font-size: clamp(10px, .8vw, 13px); }
.config-page-actions { display: flex; align-items: center; gap: 8px; }
.config-page-main { min-height: 0; padding: clamp(13px, 1.5vw, 24px) clamp(16px, 2.3vw, 38px); }
.config-page-panel { min-height: calc(100dvh - 154px); display: grid; grid-template-rows: auto auto 1fr; overflow: hidden; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); box-shadow: 0 8px 34px rgba(50,48,38,.06); }
.config-page-panel-head { min-height: 58px; padding: 11px 16px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid var(--line); background: #f1eee5; }
.config-page-panel-head h2, .config-page-panel-head p { margin: 0; }
.config-page-panel-head h2 { font-size: 14px; }
.config-page-panel-head p { margin-top: 3px; color: var(--muted); font-size: 9px; }
#configSaveState { color: #526617; font-size: 9px; font-weight: 800; }
#configSaveState.error { color: #a33f31; }
.config-page-tabs { padding: 10px 14px 0; display: flex; gap: 6px; overflow-x: auto; overflow-y: hidden; border-bottom: 1px solid var(--line); background: #fbfaf6; }
.config-page-tabs button { min-height: 37px; margin-bottom: -1px; padding: 0 14px; border: 1px solid transparent; border-radius: 8px 8px 0 0; background: transparent; color: var(--muted); font-size: 10px; font-weight: 850; white-space: nowrap; cursor: pointer; }
.config-page-tabs button.active { border-color: var(--line); border-bottom-color: var(--surface); background: var(--surface); color: var(--ink); }
.config-page-panel form { min-height: 0; display: grid; grid-template-rows: 1fr auto; }
.config-page-content { min-height: 0; overflow: visible; padding: 2px 0 12px; }
.config-page-content .privacy-note { margin-top: 18px; }
.config-page-foot { position: sticky; bottom: 0; z-index: 10; padding: 13px 16px; display: flex; align-items: center; gap: 9px; border-top: 1px solid var(--line); background: rgba(255,254,250,.96); backdrop-filter: blur(8px); }
.config-access-denied { min-height: 420px; padding: 40px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); }
.config-access-denied strong { font-size: 18px; }
.config-access-denied p { margin: 7px 0 18px; color: var(--muted); }
.role-preview-page { min-height: 100dvh; overflow-y: auto; background: var(--surface-2); }
.role-preview-shell { min-height: 100dvh; }
.role-preview-header { min-height: 102px; padding: 14px clamp(18px, 2vw, 34px); display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 28px; border-bottom: 1px solid var(--line); background: rgba(247,244,237,.97); }
.role-preview-title { padding-left: 28px; border-left: 1px solid var(--line); }
.role-preview-title h1, .role-preview-title p { margin: 0; }
.role-preview-title h1 { margin-top: 3px; font-size: clamp(25px, 2.1vw, 34px); line-height: 1; }
.role-preview-title > p:last-child { margin-top: 6px; color: var(--muted); font-size: 9px; }
.role-preview-main { padding: clamp(12px, 1.5vw, 24px); display: grid; gap: 14px; }
.role-preview-control { position: sticky; z-index: 20; top: 0; padding: 11px 14px; display: grid; grid-template-columns: minmax(210px, 300px) auto auto 1fr; align-items: center; gap: 18px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,254,250,.96); box-shadow: 0 8px 26px rgba(41,39,33,.07); backdrop-filter: blur(10px); }
.role-preview-control label { display: grid; grid-template-columns: auto minmax(130px, 1fr); align-items: center; gap: 9px; }
.role-preview-control label > span, .role-preview-control small { color: var(--muted); font-size: 8px; font-weight: 850; text-transform: uppercase; letter-spacing: .05em; }
.role-preview-control select { height: 37px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; background: white; font: inherit; font-size: 11px; font-weight: 800; }
.role-preview-control > div { padding-left: 17px; border-left: 1px solid var(--line); }
.role-preview-control > div small, .role-preview-control > div strong { display: block; }
.role-preview-control > div strong { margin-top: 2px; font-size: 15px; }
.role-preview-note { justify-self: end; padding: 6px 9px; border-radius: 12px; background: rgba(217,240,108,.25); color: #60701e; font-size: 8px; font-weight: 800; }
.role-preview-page-tabs { display: flex; gap: 4px; }
.role-preview-page-tabs button { height: 33px; padding: 0 9px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); color: var(--muted); font: inherit; font-size: 8px; font-weight: 800; cursor: pointer; }
.role-preview-page-tabs button.active { border-color: var(--ink); background: var(--ink); color: white; }
.role-live-preview { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); box-shadow: 0 10px 30px rgba(41,39,33,.07); }
.role-live-preview > header { min-height: 49px; padding: 8px 12px; display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 15px; border-bottom: 1px solid var(--line); background: #f4f1e9; }
.role-live-preview > header small, .role-live-preview > header strong { display: block; }
.role-live-preview > header small { color: var(--brand-green-dark); font-size: 7px; font-weight: 900; letter-spacing: .07em; text-transform: uppercase; }
.role-live-preview > header strong { margin-top: 2px; font-size: 12px; }
.role-live-preview > header > span { display: flex; align-items: center; gap: 6px; color: #60701e; font-size: 8px; font-weight: 800; }
.role-live-preview > header > span i { width: 7px; height: 7px; border-radius: 50%; background: var(--brand-green); }
.role-live-preview > header > a { color: var(--ink); font-size: 8px; font-weight: 800; }
.role-live-preview iframe { width: 100%; height: clamp(590px, calc(100dvh - 228px), 920px); display: block; border: 0; background: #f7f4ed; }
.role-preview-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.role-preview-card { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 8px 25px rgba(41,39,33,.04); }
.role-preview-card.wide { grid-column: 1 / -1; }
.role-preview-card > header { min-height: 58px; padding: 11px 14px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line); background: #f4f1e9; }
.role-preview-card > header small, .role-preview-card > header h2 { display: block; margin: 0; }
.role-preview-card > header small { color: var(--brand-green-dark); font-size: 7px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.role-preview-card > header h2 { margin-top: 2px; font-size: 15px; }
.role-preview-card > header > b { padding: 5px 8px; border-radius: 10px; background: rgba(217,240,108,.35); color: #526617; font-size: 8px; }
.role-preview-card.locked { background: #f4f2ed; }
.role-preview-card.locked > header > b { background: #e2dfd7; color: var(--muted); }
.role-preview-locked-copy { min-height: 210px; padding: 28px; display: grid; place-items: center; color: var(--muted); font-size: 10px; text-align: center; }
.role-mini-app { margin: 13px; overflow: hidden; border: 1px solid var(--line); border-radius: 9px; background: #fffefa; }
.role-mini-topbar { min-height: 45px; padding: 6px 8px; display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--line); background: #f5f2ea; }
.role-mini-brand { display: flex; align-items: center; gap: 5px; font-size: 8px; }
.role-mini-brand img { width: 25px; height: 25px; object-fit: contain; }
.role-mini-today { padding: 5px 7px; border: 1px solid var(--line); border-radius: 6px; font-size: 6px; font-weight: 750; }
.role-mini-actions { margin-left: auto; display: flex; gap: 4px; }
.role-mini-actions i, .role-mini-hero i { padding: 5px 7px; border: 1px solid var(--line); border-radius: 5px; background: white; font-style: normal; font-size: 6px; font-weight: 800; }
.role-mini-presence { padding: 5px 8px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; background: #fbfaf6; }
.role-mini-presence b { padding: 5px; border: 1px solid var(--line); border-radius: 5px; font-size: 6px; }
.role-mini-hidden, .role-preview-hidden { color: var(--muted); }
.role-preview-hidden { min-height: 28px; padding: 5px 9px; display: flex; align-items: center; gap: 7px; border-top: 1px dashed #d7d2c5; border-bottom: 1px dashed #d7d2c5; background: #f2f0eb; }
.role-preview-hidden span { padding: 3px 5px; border-radius: 5px; background: #dedbd3; font-size: 6px; font-weight: 900; text-transform: uppercase; }
.role-preview-hidden small { font-size: 7px; }
.role-mini-hero { min-height: 46px; padding: 8px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.role-mini-hero span:first-child small, .role-mini-hero span:first-child strong { display: block; }
.role-mini-hero span:first-child small { color: var(--brand-green-dark); font-size: 6px; font-weight: 850; text-transform: uppercase; }
.role-mini-hero span:first-child strong { font-size: 12px; }
.role-mini-hero span:last-child { display: flex; gap: 4px; }
.role-mini-warning { margin: 0 8px 7px; padding: 6px 8px; display: flex; align-items: center; gap: 7px; border: 1px solid #ea7667; border-radius: 7px; background: #fff1ee; }
.role-mini-warning > b { width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; background: #d95649; color: white; font-size: 8px; }
.role-mini-warning small, .role-mini-warning strong { display: block; }
.role-mini-warning small { color: #a6493e; font-size: 5px; font-weight: 800; text-transform: uppercase; }
.role-mini-warning strong { margin-top: 1px; font-size: 7px; }
.role-mini-calendar { min-height: 178px; display: grid; grid-template-columns: 118px 1fr; border-top: 1px solid var(--line); }
.role-mini-calendar aside { padding: 8px; display: flex; flex-direction: column; gap: 6px; border-right: 1px solid var(--line); background: #eeece5; }
.role-mini-calendar aside b { color: var(--brand-green-dark); font-size: 6px; letter-spacing: .08em; }
.role-mini-calendar aside span { font-size: 8px; font-weight: 800; }
.role-mini-calendar aside i { padding: 4px; border-radius: 4px; background: white; font-style: normal; font-size: 6px; }
.role-mini-calendar section { min-width: 0; }
.role-mini-days { height: 39px; display: grid; grid-template-columns: 150px repeat(3, 1fr); border-bottom: 1px solid var(--line); }
.role-mini-days > * { padding: 5px; display: grid; place-items: center; border-right: 1px solid var(--line); font-size: 5px; text-align: center; }
.role-mini-days > b { justify-items: start; align-items: center; padding-left: 8px; }
.role-mini-days strong { font-size: 10px; }
.role-mini-days .holiday { background: #dddcd7; }
.role-mini-days small { font-size: 4px; }
.role-mini-row { position: relative; min-height: 67px; padding: 8px 8px 8px 158px; border-bottom: 1px solid var(--line); }
.role-mini-row > b { position: absolute; left: 8px; top: 11px; font-size: 7px; }
.role-mini-row > i { min-height: 24px; padding: 6px; display: block; border-left: 3px solid #7458dc; border-radius: 5px; background: #ece8ff; font-style: normal; font-size: 7px; font-weight: 800; }
.role-mini-row > i.personio { border-color: #eb755e; background: #fde9e3; }
.role-mini-row > small { display: block; margin-top: 5px; color: var(--muted); font-size: 6px; }
.role-preview-card > footer { padding: 8px 13px; display: flex; align-items: center; flex-wrap: wrap; gap: 5px; border-top: 1px solid var(--line); }
.role-preview-card > footer small { margin-right: 3px; color: var(--muted); font-size: 7px; }
.role-preview-card > footer span { padding: 3px 5px; border-radius: 5px; background: #e8e5de; color: #77736a; font-size: 6px; font-weight: 750; }
.role-mini-page { min-height: 230px; padding: 14px; }
.role-mini-page > strong { font-size: 11px; }
.role-mini-page nav { margin-top: 12px; display: flex; gap: 5px; }
.role-mini-page nav i { padding: 5px 7px; border: 1px solid var(--line); border-radius: 6px; font-style: normal; font-size: 7px; font-weight: 800; }
.role-mini-page nav i:first-child { background: var(--ink); color: white; }
.role-mini-subtabs { margin-top: 7px; display: flex; gap: 4px; }
.role-mini-subtabs span { padding: 4px 6px; border-radius: 5px; background: #eeece5; font-size: 6px; }
.role-mini-table { margin-top: 12px; display: grid; grid-template-columns: 1.4fr 1fr; overflow: hidden; border: 1px solid var(--line); border-radius: 7px; }
.role-mini-table > * { min-height: 29px; padding: 7px; border-right: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); font-size: 7px; }
.role-mini-table b { background: #eceae3; font-size: 6px; text-transform: uppercase; }
.role-mini-log { margin-top: 13px; display: grid; gap: 5px; }
.role-mini-log > * { padding: 7px; border: 1px solid var(--line); border-radius: 6px; font-size: 7px; }
.role-mini-log > b { background: #eeece5; }
.role-mini-settings { margin-top: 13px; display: grid; gap: 6px; }
.role-mini-settings span { padding: 8px; display: flex; align-items: center; justify-content: space-between; border: 1px solid var(--line); border-radius: 6px; }
.role-mini-settings b { font-size: 7px; }
.role-mini-settings small { color: #5d701a; font-size: 6px; }
.role-preview-permissions { overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.role-preview-permissions > header { min-height: 67px; padding: 12px 15px; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); background: #f4f1e9; }
.role-preview-permissions h2, .role-preview-permissions small, .role-preview-permissions p { margin: 0; }
.role-preview-permissions small { color: var(--brand-green-dark); font-size: 7px; font-weight: 900; text-transform: uppercase; }
.role-preview-permissions h2 { margin-top: 2px; font-size: 16px; }
.role-preview-permissions p { color: var(--muted); font-size: 8px; }
.role-preview-permissions > div { padding: 13px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.role-preview-permissions article { padding: 10px; display: grid; align-content: start; gap: 5px; border: 1px solid var(--line); border-radius: 8px; }
.role-preview-permissions article > strong { margin-bottom: 4px; font-size: 9px; }
.role-preview-permissions article > span { display: flex; align-items: center; gap: 6px; color: #99958d; font-size: 7px; }
.role-preview-permissions article > span i { width: 14px; height: 14px; display: grid; place-items: center; border-radius: 50%; background: #e5e2dc; font-style: normal; font-size: 7px; }
.role-preview-permissions article > span.on { color: var(--ink); font-weight: 700; }
.role-preview-permissions article > span.on i { background: var(--brand-green); color: white; }
.statistics-summary { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(8px, 1vw, 14px); }
.statistics-summary article { min-width: 0; padding: clamp(10px, 1vw, 15px) clamp(12px, 1.2vw, 18px); border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.statistics-summary small, .statistics-summary strong, .statistics-summary span { display: block; }
.statistics-summary small { color: var(--muted); font-size: clamp(8px, .55vw, 10px); font-weight: 850; text-transform: uppercase; letter-spacing: .07em; }
.statistics-summary strong { margin-top: 5px; font-size: clamp(20px, 1.7vw, 28px); line-height: 1; }
.statistics-summary strong i { color: var(--muted); font-size: .5em; font-style: normal; font-weight: 700; }
.statistics-summary span { margin-top: 5px; color: var(--muted); font-size: clamp(8px, .52vw, 10px); }
.statistics-panel { min-height: 0; display: grid; grid-template-rows: auto auto; overflow: visible; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); box-shadow: 0 8px 34px rgba(50,48,38,.06); }
.statistics-panel-head { min-height: 54px; padding: 10px 16px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid var(--line); background: #f1eee5; }
.statistics-panel-head h2, .statistics-panel-head p { margin: 0; }
.statistics-panel-head h2 { font-size: 13px; }
.statistics-panel-head p, .statistics-panel-head > small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.statistics-panel-head > small { flex: 0 0 auto; margin: 0; }
.statistics-content { min-height: 0; overflow: visible; display: grid; grid-template-rows: auto auto; align-content: start; gap: 12px; padding: 14px; background: #fbfaf6; }
.statistics-tabs { display: flex; align-items: center; gap: 7px; padding: 5px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); width: max-content; max-width: 100%; overflow-x: auto; }
.statistics-tabs button { min-height: 32px; border: 0; border-radius: 7px; padding: 0 13px; background: transparent; color: var(--muted); font-size: 10px; font-weight: 850; white-space: nowrap; }
.statistics-tabs button.active { background: var(--brand-green); color: white; }
.statistics-time-subtabs { flex: 0 0 auto; padding: 12px 14px; display: grid; grid-template-columns: repeat(auto-fit, minmax(205px, 1fr)); gap: 9px; border-bottom: 1px solid var(--line-soft); background: #f7f6f1; }
.statistics-time-subtabs .statistics-time-view-card { min-width: 0; min-height: 62px; padding: 9px 11px; display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 9px; border: 1px solid var(--line); border-radius: 10px; background: white; color: var(--ink); text-align: left; transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease; }
.statistics-time-subtabs .statistics-time-view-card:hover { border-color: #b7b2a7; box-shadow: 0 4px 14px rgba(45,43,36,.07); transform: translateY(-1px); }
.statistics-time-subtabs .statistics-time-view-card > i { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 8px; background: #eeece5; color: #5f615a; font-size: 11px; font-style: normal; font-weight: 900; }
.statistics-time-subtabs .statistics-time-view-card > span { min-width: 0; display: grid; gap: 2px; padding: 0; background: transparent; text-align: left; }
.statistics-time-subtabs .statistics-time-view-card > span strong { overflow: hidden; text-overflow: ellipsis; color: inherit; font-size: 10px; font-weight: 900; white-space: nowrap; }
.statistics-time-subtabs .statistics-time-view-card > span small { overflow: hidden; text-overflow: ellipsis; color: var(--muted); font-size: 8px; font-weight: 600; white-space: nowrap; }
.statistics-time-subtabs .statistics-time-view-card > b { min-width: 25px; padding: 4px 6px; border-radius: 999px; background: #eeece4; color: #555750; font-size: 8px; text-align: center; }
.statistics-time-subtabs .statistics-time-view-card.active { border-color: #242522; background: #242522; color: white; box-shadow: 0 5px 16px rgba(36,37,34,.14); }
.statistics-time-subtabs .statistics-time-view-card.active > i { background: var(--brand-green); color: white; }
.statistics-time-subtabs .statistics-time-view-card.active > span small { color: rgba(255,255,255,.68); }
.statistics-time-subtabs .statistics-time-view-card.active > b { background: rgba(255,255,255,.15); color: white; }
.statistics-section { min-height: 0; overflow: visible; display: flex; flex-direction: column; border: 1px solid var(--line-soft); border-radius: 11px; background: white; }
.statistics-section > header { min-height: 50px; flex: 0 0 auto; padding: 11px 14px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid var(--line-soft); background: #fffefa; }
.statistics-section > header h3, .statistics-section > header p { margin: 0; }
.statistics-section > header h3 { font-size: 12px; }
.statistics-section > header p { color: var(--muted); font-size: 9px; text-align: right; }
.statistics-project-filter { flex: 0 0 auto; padding: 11px 14px; display: flex; flex-wrap: wrap; align-items: end; gap: 12px; border-bottom: 1px solid var(--line-soft); background: #fbfaf6; }
.statistics-filter-field { min-width: 0; width: min(420px, 100%); display: grid; gap: 5px; }
.statistics-filter-field-compact { width: min(260px, 100%); }
.statistics-project-filter label { color: var(--muted); font-size: 9px; font-weight: 850; text-transform: uppercase; letter-spacing: .07em; }
.statistics-project-filter select { width: 100%; height: 36px; border: 1px solid var(--line); border-radius: 8px; background: white; padding: 0 10px; color: var(--ink); font-size: 11px; font-weight: 750; }
.statistics-attendance-warning { flex: 0 0 auto; margin: 11px 14px 0; padding: 10px 12px; display: flex; align-items: center; gap: 10px; border: 1px solid #efb8ad; border-radius: 9px; background: #fff0ed; color: #85382c; }
.statistics-attendance-warning-icon { width: 25px; height: 25px; flex: 0 0 25px; display: grid; place-items: center; border-radius: 50%; background: #dc5f4d; color: white; font-size: 13px; font-weight: 850; }
.statistics-attendance-warning strong, .statistics-attendance-warning p { display: block; margin: 0; }
.statistics-attendance-warning strong { font-size: 11px; }
.statistics-attendance-warning p { margin-top: 2px; font-size: 9px; line-height: 1.4; }
.statistics-time-overview { padding: 11px 14px; display: grid; grid-template-columns: repeat(auto-fit, minmax(155px, 1fr)); gap: 8px; border-bottom: 1px solid var(--line-soft); background: white; }
.statistics-time-overview article { min-width: 0; padding: 9px 11px; display: flex; align-items: center; gap: 9px; border: 1px solid var(--line-soft); border-radius: 9px; background: #fbfaf7; }
.statistics-time-overview article > i { width: 27px; height: 27px; flex: 0 0 27px; display: grid; place-items: center; border-radius: 8px; background: #e8e6df; color: #66645d; font-size: 10px; font-style: normal; font-weight: 900; }
.statistics-time-overview article > span { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px; }
.statistics-time-overview article small { overflow: hidden; text-overflow: ellipsis; color: var(--muted); font-size: 8px; font-weight: 800; white-space: nowrap; }
.statistics-time-overview article strong { font-size: 14px; font-variant-numeric: tabular-nums; }
.statistics-time-overview article.recorded > i { background: #e9f4dc; color: #4c7f19; }
.statistics-time-overview article.absent > i { background: #e1eff6; color: #397293; }
.statistics-time-overview article.empty > i { background: #eceae4; color: #757169; }
.statistics-time-overview article.weekend > i { background: #e5e3de; color: #6c6962; }
.statistics-time-overview article.holiday > i { background: #ddd9cf; color: #5f5a50; }
.statistics-time-overview article.project > i { background: #ebe7fb; color: #6650b7; }
.statistics-filter-empty { padding: 30px 16px; display: grid; place-items: center; gap: 4px; border-bottom: 1px solid var(--line-soft); color: var(--muted); text-align: center; }
.statistics-filter-empty strong { color: var(--ink); font-size: 11px; }
.statistics-filter-empty span { font-size: 9px; }
.statistics-table-wrap { width: 100%; min-height: 0; flex: 0 0 auto; overflow-x: auto; overflow-y: visible; background: white; }
.statistics-table-wrap.compact { max-height: 360px; flex: 0 1 360px; }
.statistics-table { width: 100%; height: auto; min-width: max-content; border-spacing: 0; border-collapse: separate; font-size: 12px; }
.statistics-table th, .statistics-table td { height: 62px; padding: 8px 18px; border-right: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); text-align: center; white-space: nowrap; }
.statistics-table tr:last-child th, .statistics-table tr:last-child td { border-bottom: 0; }
.statistics-table th:last-child, .statistics-table td:last-child { border-right: 0; }
.statistics-table thead th { position: sticky; top: 0; z-index: 2; height: 42px; background: #eeece4; color: #555750; font-size: 9px; font-weight: 850; text-transform: uppercase; letter-spacing: .07em; }
.statistics-table .statistics-employee { position: sticky; left: 0; z-index: 1; min-width: 355px; text-align: left; }
.statistics-table thead .statistics-employee { z-index: 3; }
.statistics-table tbody .statistics-employee { background: white; }
.statistics-employee-inner { display: flex; align-items: center; gap: 10px; }
.statistics-rank { width: 23px; flex: 0 0 23px; color: #777970; font-size: 10px; font-weight: 850; text-align: right; font-variant-numeric: tabular-nums; }
.statistics-rank::before { content: "#"; color: #aaa79d; }
.statistics-table tbody tr:hover th, .statistics-table tbody tr:hover td { background: #fbfaf6; }
.statistics-table tbody tr:hover .statistics-employee { background: #fbfaf6; }
.statistics-time-table tbody tr.statistics-day-band-0 th,
.statistics-time-table tbody tr.statistics-day-band-0 td,
.statistics-time-table tbody tr.statistics-day-band-0 .statistics-employee { background: #fff; }
.statistics-time-table tbody tr.statistics-day-band-1 th,
.statistics-time-table tbody tr.statistics-day-band-1 td,
.statistics-time-table tbody tr.statistics-day-band-1 .statistics-employee { background: #f6f5f0; }
.statistics-time-table tbody tr.statistics-day-band-0:hover th,
.statistics-time-table tbody tr.statistics-day-band-0:hover td,
.statistics-time-table tbody tr.statistics-day-band-0:hover .statistics-employee,
.statistics-time-table tbody tr.statistics-day-band-1:hover th,
.statistics-time-table tbody tr.statistics-day-band-1:hover td,
.statistics-time-table tbody tr.statistics-day-band-1:hover .statistics-employee { background: #f1efe7; }
.statistics-time-table tbody tr.statistics-time-missing th,
.statistics-time-table tbody tr.statistics-time-missing td,
.statistics-time-table tbody tr.statistics-time-missing .statistics-employee { background: #fff0ed !important; color: #943a2d; }
.statistics-time-table tbody tr.statistics-time-missing { box-shadow: inset 4px 0 0 #dc5f4d; }
.statistics-time-table tbody tr.statistics-time-missing .statistics-total { background: #ffdcd5 !important; color: #8e3024; }
.statistics-missing-label { display: inline-flex !important; width: max-content; margin: 0 auto; padding: 3px 7px; border-radius: 999px; background: #ffd9d2; color: #96392c !important; font-size: 9px !important; font-weight: 850 !important; line-height: 1; }
.statistics-time-table tbody tr.statistics-time-absence th,
.statistics-time-table tbody tr.statistics-time-absence td,
.statistics-time-table tbody tr.statistics-time-absence .statistics-employee { background: #eef6fa !important; color: #315f7c; }
.statistics-time-table tbody tr.statistics-time-absence { box-shadow: inset 4px 0 0 var(--blue); }
.statistics-time-table tbody tr.statistics-time-absence .statistics-total { background: var(--blue-soft) !important; color: #315f7c; }
.statistics-time-table tbody tr.statistics-time-empty th,
.statistics-time-table tbody tr.statistics-time-empty td,
.statistics-time-table tbody tr.statistics-time-empty .statistics-employee { background: #f3f2ee !important; color: #77736b; }
.statistics-time-table tbody tr.statistics-time-empty { box-shadow: inset 4px 0 0 #b7b3aa; }
.statistics-time-table tbody tr.statistics-time-empty .statistics-total { background: #ebe9e3 !important; color: #656159; }
.statistics-no-time-label { display: inline-flex; align-items: center; border-radius: 999px; padding: 3px 7px; background: #e3e1da; color: #625f58; font-size: 9px; font-weight: 750; white-space: nowrap; }
.statistics-time-table { min-width: 1480px; }
.statistics-time-table .statistics-employee { min-width: 300px; }
.statistics-time-table .statistics-date-cell { min-width: 145px; font-weight: 900; }
.statistics-time-table .statistics-status-cell { min-width: 190px; text-align: left; }
.statistics-time-table .statistics-project-cell { min-width: 320px; max-width: 430px; text-align: left; white-space: normal; }
.statistics-time-table-missing { width: 100%; min-width: 1480px; table-layout: auto; }
.statistics-day-status { display: inline-flex; align-items: center; width: max-content; padding: 4px 8px; border-radius: 999px; font-size: 9px; font-weight: 900; line-height: 1; white-space: nowrap; }
.statistics-day-status.recorded { background: #e7f2d9; color: #477517; }
.statistics-day-status.absent { background: #d9ebf4; color: #315f7c; }
.statistics-day-status.mixed { background: #e8e2f8; color: #604c9d; }
.statistics-day-status.missing { background: #ffd9d2; color: #96392c; }
.statistics-day-status.empty { background: #e5e3dd; color: #656159; }
.statistics-day-status.weekend { background: #e3e1dc; color: #625f58; }
.statistics-day-status.holiday { background: #dcd8ce; color: #5d584e; }
.statistics-time-table tbody tr.statistics-time-weekend > * { background: #f4f3ef !important; color: #6b6861; }
.statistics-time-table tbody tr.statistics-time-weekend > :first-child { box-shadow: inset 4px 0 0 #c8c5bc; }
.statistics-time-table tbody tr.statistics-time-holiday > * { background: #eeece6 !important; color: #625e55; }
.statistics-time-table tbody tr.statistics-time-holiday > :first-child { box-shadow: inset 4px 0 0 #b9b4a8; }
.statistics-weekend-label { display: inline-flex; padding: 4px 8px; border-radius: 999px; background: #e3e1dc; color: #625f58; font-size: 9px; font-weight: 800; white-space: nowrap; }
.statistics-status-cell > small { margin-top: 5px !important; max-width: 190px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.statistics-project-links { display: grid; gap: 5px; }
.statistics-project-links > span { min-width: 0; padding-left: 8px; display: grid; gap: 1px; border-left: 3px solid #7357d6; }
.statistics-project-links strong, .statistics-project-links small { max-width: 390px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.statistics-project-links strong { font-size: 11px; }
.statistics-project-links small { margin: 0 !important; font-size: 8px !important; }
.statistics-project-none { display: inline-flex; padding: 4px 7px; border-radius: 6px; background: rgba(120,118,110,.08); color: #77736b; font-size: 9px; font-weight: 700; white-space: nowrap; }
.statistics-absence-label, .statistics-absence-type { display: inline-flex !important; width: max-content; padding: 3px 7px; border-radius: 999px; background: #d6e9f3; color: #315f7c !important; font-size: 9px !important; font-weight: 850 !important; line-height: 1; }
.statistics-absence-label { margin: 0 auto; }
.statistics-absence-type { margin: 0; }
.statistics-table .avatar { width: 36px; height: 36px; flex: 0 0 36px; font-size: 10px; }
.statistics-employee-copy { min-width: 0; }
.statistics-employee-copy > strong, .statistics-employee-copy > small { display: block; max-width: 245px; overflow: hidden; text-overflow: ellipsis; }
.statistics-employee-copy > strong { display: flex; align-items: center; gap: 7px; font-size: 12px; }
.statistics-employee-copy > strong > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.statistics-employee-copy > small { margin-top: 1px; color: var(--muted); font-size: 9px; font-weight: 500; }
.statistics-groups { max-width: 245px; margin-top: 4px; display: flex; align-items: baseline; gap: 5px; color: #373a34; font-size: 10px; line-height: 1.2; }
.statistics-groups b { flex: 0 0 auto; color: #5950a0; font-size: 9px; font-weight: 850; }
.statistics-groups > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 750; }
.statistics-groups.empty > span { color: #92938d; font-weight: 600; }
.statistics-table td { min-width: 90px; font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums; }
.statistics-time-table td strong, .statistics-time-table td small { display: block; text-align: left; }
.statistics-time-table td small { margin-top: 2px; color: var(--muted); font-size: 9px; font-weight: 600; }
.statistics-table td.positive-hours { color: #3d6d08; background: rgba(97,166,14,.12); }
.statistics-table td.negative-hours { color: #9b3e2d; background: var(--coral-soft); }
.statistics-table td.zero { color: #bbb8ae; font-weight: 600; }
.statistics-table .statistics-total { min-width: 96px; background: rgba(97,166,14,.12); color: #3d6d08; font-weight: 900; }
.statistics-table thead .statistics-total { background: rgba(97,166,14,.18); }
.statistics-violation-button { width: 19px; height: 19px; flex: 0 0 19px; display: inline-grid; place-items: center; border: 0; border-radius: 50%; background: #d94f3d; color: white; font-size: 11px; font-weight: 900; line-height: 1; box-shadow: 0 0 0 3px rgba(217,79,61,.12); cursor: pointer; }
.statistics-violation-button:hover { background: #b83b2c; transform: translateY(-1px); }
.statistics-law-note { margin: 11px 14px; padding: 11px 13px; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 10px; border: 1px solid #e6c69c; border-radius: 9px; background: #fff8ea; color: #6e4a1f; }
.statistics-law-note strong { font-size: 10px; }
.statistics-law-note span { font-size: 10px; font-weight: 700; }
.statistics-law-note small { grid-column: 2; color: #896b48; font-size: 9px; line-height: 1.4; }
.statistics-violation-projects { padding: 0 14px 12px; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 8px; }
.statistics-violation-projects article { min-width: 0; padding: 11px 12px; display: grid; gap: 3px; border: 1px solid #efc2b9; border-left: 4px solid #d94f3d; border-radius: 8px; background: #fff8f6; }
.statistics-violation-projects small { color: #a45648; font-size: 8px; font-weight: 850; text-transform: uppercase; letter-spacing: .08em; }
.statistics-violation-projects strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.statistics-violation-projects span { color: #825044; font-size: 9px; }
.statistics-violation-projects span b { color: #aa3526; font-size: 12px; }
.statistics-violations-table td strong { display: block; text-align: left; }
.statistics-violations-wrap { min-height: 0; overflow-x: auto; overflow-y: visible; }
.statistics-violations-table th, .statistics-violations-table td { height: 76px; }
.statistics-violations-table td { vertical-align: middle; }
.statistics-violation-dates, .statistics-violation-reasons { overflow: visible; }
.statistics-violation-dates { min-width: 145px; padding-right: 5px; display: grid; gap: 3px; line-height: 1.3; }
.statistics-violation-dates span { display: block; }
.statistics-violation-reasons { min-width: 250px; padding-right: 5px; }
.statistics-violation-total { background: #fff0ed; color: #a33425; font-size: 15px !important; font-weight: 900 !important; }
.statistics-violation-reason { display: block; width: max-content; max-width: 360px; margin: 3px 0; padding: 4px 7px; overflow: hidden; text-overflow: ellipsis; border-radius: 999px; background: #fff0ed; color: #8e382c; font-size: 9px; font-weight: 750; text-align: left; }
.statistics-violation-dialog { width: min(680px, calc(100vw - 30px)); max-height: min(760px, calc(100vh - 30px)); padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: white; color: var(--ink); box-shadow: 0 24px 70px rgba(37,34,27,.28); }
.statistics-violation-dialog::backdrop { background: rgba(30,29,25,.48); backdrop-filter: blur(2px); }
.statistics-violation-dialog > header { padding: 17px 19px; display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line-soft); background: #fffefa; }
.statistics-violation-dialog > header small { color: #b04636; font-size: 8px; font-weight: 900; text-transform: uppercase; letter-spacing: .1em; }
.statistics-violation-dialog > header h2 { margin: 3px 0 0; font-size: 23px; }
.statistics-violation-dialog > header p { margin: 4px 0 0; color: var(--muted); font-size: 10px; }
.statistics-violation-dialog > header > button { width: 30px; height: 30px; border: 1px solid var(--line); border-radius: 7px; background: white; font-size: 18px; }
.statistics-violation-dialog-body { padding: 16px 19px; overflow-y: auto; display: grid; gap: 9px; }
.statistics-violation-dialog-body article { padding: 12px; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; border: 1px solid #efc2b9; border-radius: 9px; background: #fff8f6; }
.statistics-violation-dialog-body article > span { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; background: #d94f3d; color: white; font-weight: 900; }
.statistics-violation-dialog-body article strong { color: #7f3025; font-size: 12px; }
.statistics-violation-dialog-body article p { margin: 4px 0; color: #613e38; font-size: 10px; line-height: 1.5; }
.statistics-violation-dialog-body article small { color: #a14233; font-size: 9px; font-weight: 850; }
.statistics-violation-disclaimer { margin: 5px 0 0; color: var(--muted); font-size: 9px; line-height: 1.5; }
.statistics-violation-dialog > footer { padding: 12px 19px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line-soft); }
.statistics-violation-dialog > footer a { color: #5d559f; font-size: 10px; font-weight: 800; }
.statistics-loading, .statistics-empty, .statistics-error { height: 100%; min-height: 220px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: var(--muted); }
.statistics-loading span { width: 26px; height: 26px; margin-bottom: 10px; border: 3px solid var(--line); border-top-color: var(--violet); border-radius: 50%; animation: spin .8s linear infinite; }
.statistics-loading strong, .statistics-empty strong, .statistics-error strong { color: var(--ink); font-size: 12px; }
.statistics-empty > span { margin-bottom: 7px; font-size: 28px; }
.statistics-empty p, .statistics-error p { max-width: 390px; margin: 5px 0 0; font-size: 10px; line-height: 1.5; }
.statistics-error { color: #8b4432; }

.match-modal { width: min(760px, calc(100vw - 28px)); }
.match-intro { margin: 18px 24px 8px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.match-list { padding: 6px 24px 22px; max-height: min(520px, calc(100vh - 240px)); overflow: auto; display: grid; gap: 10px; }
.match-row { border: 1px solid var(--line); border-radius: 11px; padding: 14px; background: #fcfbf7; }
.match-source { display: flex; align-items: center; gap: 10px; }
.match-source .integration-logo { width: 30px; height: 30px; border-radius: 7px; font-size: 14px; flex: 0 0 auto; }
.match-source-copy { min-width: 0; }
.match-source-copy small, .match-source-copy strong { display: block; }
.match-source-copy small { color: var(--muted); font-size: 8px; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; }
.match-source-copy strong { margin-top: 2px; font-size: 13px; overflow-wrap: anywhere; }
.match-suggestions { margin: 12px 0 0 40px; display: flex; flex-wrap: wrap; align-items: center; gap: 7px; }
.match-suggestions-label { width: 100%; color: var(--muted); font-size: 9px; }
.match-suggestion { border: 1px solid #cbc5e8; border-radius: 7px; background: #f8f6ff; color: #514499; padding: 7px 9px; font-size: 10px; font-weight: 750; }
.match-suggestion:hover { border-color: var(--violet); background: white; }
.match-score { margin-left: 4px; color: var(--muted); font-size: 8px; font-weight: 700; }
.match-empty, .match-resolved { margin: 12px 0 0 40px; color: var(--muted); font-size: 9px; }
.match-resolved { color: #526617; font-weight: 800; }

.toast-region { position: fixed; z-index: 100; right: 22px; bottom: 22px; display: grid; gap: 9px; pointer-events: none; }
.toast { min-width: 250px; max-width: 390px; padding: 12px 14px; border-radius: 9px; background: var(--ink); color: white; box-shadow: 0 12px 30px rgba(0,0,0,.2); font-size: 11px; line-height: 1.4; animation: toast-in .22s ease-out; }
.toast.error { background: #8f3f00; }
.toast strong { display: block; color: var(--lime); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 2px; }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 50% { opacity: .35; } }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

@media (max-width: 950px) {
  .topbar { height: auto; min-height: 76px; padding: 8px 18px; grid-template-columns: auto 1fr; }
  .today-presence { grid-column: 1 / -1; width: 100%; }
  .today-presence-button { width: 100%; }
  .today-presence-panel { width: calc(100vw - 36px); grid-template-columns: 1fr; }
  .sync-state, .statistics-button-label { display: none; }
  main { padding: 22px 18px; }
  .workspace { grid-template-columns: 1fr; }
  .sidebar { border-right: 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto; gap: 12px 18px; }
  .sidebar-head, .search-field { margin: 0; }
  .group-filter-field, .filter-list, .display-options { grid-column: 1 / -1; }
  .filter-list { grid-template-columns: repeat(4, 1fr); margin: 0; }
  .legend, .sidebar-note { display: none; }
  .timeline-scroll { max-height: none; }
  .logs-page-header { grid-template-columns: auto minmax(0, 1fr); gap: 12px 22px; }
  .logs-page-header .brand { grid-row: 1 / 3; }
  .logs-page-title { padding-left: 22px; }
  .logs-page-actions { grid-column: 2; }
  .logs-page-batch > header { grid-template-columns: auto minmax(150px, 1fr) auto auto auto; }
  .logs-page-batch > header > p { grid-column: 2 / 6; }
  .logs-page-batch .log-new-pill { grid-column: 4; grid-row: 1; }
  .logs-page-batch .log-batch-chevron { grid-column: 5; grid-row: 1; }
  .statistics-page-header { grid-template-columns: auto minmax(0, 1fr); gap: 12px 22px; }
  .statistics-page-header .brand { grid-row: 1 / 3; }
  .statistics-page-title { padding-left: 22px; }
  .statistics-page-actions { grid-column: 2; }
  .config-page-header { grid-template-columns: auto minmax(0, 1fr); gap: 12px 22px; }
  .config-page-header .brand { grid-row: 1 / 3; }
  .config-page-title { padding-left: 22px; }
  .config-page-actions { grid-column: 2; }
}

@media (max-width: 680px) {
  :root { --name-width: 160px; --day-width: 98px; --day-min-width: 98px; }
  .topbar { height: 65px; padding: 0 12px; }
  .today-presence { display: none; }
  .brand small, .desktop-only, .sync-state { display: none; }
  .sync-button-label { display: none; }
  .top-actions { gap: 5px; }
  .top-actions .button { padding: 0 10px; }
  main { padding: 18px 10px 24px; }
  .hero-row { align-items: flex-start; flex-direction: column; margin-bottom: 18px; }
  .hero-tools { width: 100%; max-width: none; justify-items: stretch; }
  .rentman-log-box { grid-template-columns: auto minmax(0, 1fr) auto; }
  .rentman-log-symbol { grid-column: 1; grid-row: 1; }
  .rentman-log-copy { grid-column: 2; grid-row: 1; }
  .rentman-log-dismiss { grid-column: 3; grid-row: 1; }
  .rentman-log-details { grid-column: 2; grid-row: 2; justify-self: start; }
  .hero-actions { width: 100%; }
  .hero-actions .button { flex: 1; padding: 0 8px; }
  h1 { font-size: 38px; }
  .subline { font-size: 12px; }
  .workspace { border-radius: 11px; }
  .sidebar { grid-template-columns: 1fr; padding: 14px; }
  .filter-list { grid-template-columns: repeat(2, 1fr); }
  .planner-toolbar { height: auto; min-height: 104px; align-items: stretch; flex-direction: column; padding: 12px; gap: 9px; }
  .period-control { justify-content: space-between; }
  .next-assignment-button { display: none; }
  .period-label { width: auto; min-width: 0; flex: 1 1 0; font-size: 14px; }
  .view-controls { align-self: flex-start; }
  .modal { max-height: calc(100vh - 10px); width: calc(100vw - 10px); }
  .export-dialog { height: calc(100dvh - 10px); max-height: calc(100dvh - 10px); }
  .export-dialog-body { padding: 13px; }
  .export-scope-options, .export-date-fields { grid-template-columns: 1fr; }
  .export-employee-toolbar { grid-template-columns: 1fr 1fr; }
  .export-employee-toolbar > label { grid-column: 1 / -1; }
  .export-employee-toolbar > strong { grid-column: 1 / -1; }
  .export-employee-list { grid-template-columns: 1fr; }
  .modal-head { padding: 18px 17px 14px; }
  .modal-head h2 { font-size: 24px; }
  .form-grid { grid-template-columns: 1fr; padding: 17px; gap: 13px; }
  .field-wide { grid-column: auto; }
  .modal-foot { padding: 13px 17px 17px; flex-wrap: wrap; }
  .source-banner, .privacy-note, .integration-card, .match-intro { margin-left: 17px; margin-right: 17px; }
  .integration-card .form-grid { padding: 0; }
  .helper-text { display: none; }
  .team-list { padding: 8px 17px 18px; }
  .match-list { padding: 6px 17px 18px; }
  .logs-intro { margin-left: 17px; margin-right: 17px; }
  .logs-list { padding: 10px 17px 18px; }
  .logs-page-header { min-height: 124px; padding: 12px; gap: 10px 14px; }
  .logs-page-header .brand { grid-row: 1; align-self: start; }
  .logs-page-title { grid-column: 1 / -1; grid-row: 2; padding: 9px 0 0; border-left: 0; border-top: 1px solid var(--line); }
  .logs-page-title h1 { font-size: 25px; }
  .logs-page-title > p { display: none; }
  .logs-page-actions { grid-column: 2; grid-row: 1; justify-self: end; }
  .logs-page-main { padding: 10px; gap: 8px; }
  .logs-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; }
  .logs-summary article { padding: 9px 8px 9px 11px; }
  .logs-summary strong { font-size: 18px; }
  .logs-page-panel-head { min-height: 48px; padding: 8px 10px; }
  .logs-page-panel-head p { display: none; }
  .logs-page-content { padding: 8px; }
  .logs-page-batch > header { grid-template-columns: auto minmax(0, 1fr) auto auto; gap: 8px; }
  .logs-page-batch > header > p { grid-column: 2 / 5; }
  .logs-page-batch .log-new-pill { grid-column: 3; grid-row: 1; }
  .logs-page-batch .log-batch-chevron { grid-column: 4; grid-row: 1; }
  .logs-page-batch .log-change summary { grid-template-columns: 1fr auto; }
  .logs-page-batch .log-change-kind { grid-column: 1; }
  .logs-page-batch .log-change-title { grid-column: 1; }
  .logs-page-batch .log-action { grid-column: 2; grid-row: 1 / 3; }
  .logs-page-batch .log-fields { padding: 8px 12px 14px; }
  .logs-page-batch .log-field { grid-template-columns: 1fr 20px 1fr; }
  .logs-page-batch .log-field > strong { grid-column: 1 / -1; }
  .statistics-button-label { display: none; }
  .statistics-page-header { min-height: 124px; padding: 12px; gap: 10px 14px; }
  .statistics-page-header .brand { grid-row: 1; align-self: start; }
  .statistics-page-title { grid-column: 1 / -1; grid-row: 2; padding: 9px 0 0; border-left: 0; border-top: 1px solid var(--line); }
  .statistics-page-title h1 { font-size: 25px; }
  .statistics-page-title > p { display: none; }
  .statistics-page-actions { grid-column: 2; grid-row: 1; justify-self: end; }
  .statistics-page-main { padding: 10px; gap: 8px; }
  .config-page-header { min-height: 124px; padding: 12px; gap: 10px 14px; }
  .config-page-header .brand { grid-row: 1; align-self: start; }
  .config-page-title { grid-column: 1 / -1; grid-row: 2; padding: 9px 0 0; border-left: 0; border-top: 1px solid var(--line); }
  .config-page-title h1 { font-size: 25px; }
  .config-page-title > p { display: none; }
  .config-page-actions { grid-column: 2; grid-row: 1; justify-self: end; }
  .config-page-main { padding: 10px; }
  .config-page-panel { min-height: calc(100dvh - 144px); }
  .config-page-panel-head { min-height: 48px; padding: 8px 10px; }
  .config-page-panel-head p { display: none; }
  .config-page-tabs { padding-left: 8px; padding-right: 8px; }
  .settings-rule-row { grid-template-columns: minmax(160px, 1fr) 108px 108px; }
  .settings-rule-row > * { padding: 8px; }
  .settings-select-row { align-items: stretch; flex-direction: column; }
  .settings-select-row select { width: 100%; min-width: 0; }
  .role-editor-toolbar, .role-assignment-add { margin-left: 12px; margin-right: 12px; grid-template-columns: 1fr; align-items: stretch; }
  .permission-modules { margin-left: 12px; margin-right: 12px; grid-template-columns: 1fr; }
  .role-employee-access { margin-left: 12px; margin-right: 12px; }
  .role-employee-access-toolbar { grid-template-columns: 1fr; }
  .role-employee-list { grid-template-columns: 1fr; }
  .role-assignment-list { margin-left: 12px; margin-right: 12px; }
  .role-editor-toolbar .button, .role-assignment-add .button { width: 100%; }
  .config-page-foot { padding: 10px; }
  .statistics-summary { gap: 5px; }
  .statistics-summary article { padding: 9px 8px; }
  .statistics-summary small { min-height: 20px; font-size: 7px; }
  .statistics-summary strong { font-size: 18px; }
  .statistics-summary span { display: none; }
  .statistics-panel-head { min-height: 48px; padding: 8px 10px; }
  .statistics-panel-head p, .statistics-panel-head > small { display: none; }
  .statistics-table .statistics-employee { min-width: 285px; }
  .statistics-employee-copy > strong, .statistics-employee-copy > small, .statistics-groups { max-width: 175px; }
  .statistics-table th, .statistics-table td { height: 58px; padding: 7px 12px; }
  .log-change summary { grid-template-columns: 1fr auto; }
  .log-change-kind { grid-column: 1; }
  .log-change-title { grid-column: 1; }
  .log-action { grid-column: 2; grid-row: 1 / 3; }
  .log-fields { padding-left: 14px; }
  .log-field { grid-template-columns: 1fr 20px 1fr; }
  .log-field > strong { grid-column: 1 / -1; }
  .match-suggestions, .match-empty, .match-resolved { margin-left: 0; }
  .toast-region { left: 10px; right: 10px; bottom: 10px; }
  .toast { max-width: none; min-width: 0; }
}

@media (max-width: 1100px) {
  .role-preview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .role-preview-permissions > div { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .role-preview-control { grid-template-columns: minmax(210px, 1fr) auto 1fr; }
  .role-preview-note { display: none; }
  .role-preview-page-tabs { justify-self: end; }
}

@media (max-width: 700px) {
  .role-preview-header { min-height: 124px; padding: 12px; grid-template-columns: auto auto; gap: 10px; }
  .role-preview-title { grid-column: 1 / -1; grid-row: 2; padding: 9px 0 0; border-left: 0; border-top: 1px solid var(--line); }
  .role-preview-title h1 { font-size: 25px; }
  .role-preview-title > p:last-child { display: none; }
  .role-preview-header > .button { grid-column: 2; grid-row: 1; }
  .role-preview-main { padding: 10px; }
  .role-preview-control { position: static; grid-template-columns: 1fr 1fr; gap: 9px; }
  .role-preview-control label { grid-column: 1 / -1; grid-template-columns: 1fr; }
  .role-preview-control > div { padding-left: 0; border-left: 0; }
  .role-preview-page-tabs { grid-column: 1 / -1; justify-self: stretch; overflow-x: auto; }
  .role-preview-page-tabs button { flex: 1 0 auto; }
  .role-live-preview > header { grid-template-columns: 1fr auto; }
  .role-live-preview > header > span { display: none; }
  .role-live-preview iframe { height: 680px; }
  .role-preview-grid { grid-template-columns: 1fr; }
  .role-preview-card.wide { grid-column: auto; }
  .role-mini-today { display: none; }
  .role-mini-actions i { font-size: 0; }
  .role-mini-actions i::first-letter { font-size: 7px; }
  .role-mini-presence { grid-template-columns: repeat(2, 1fr); }
  .role-mini-calendar { grid-template-columns: 82px 1fr; }
  .role-mini-days { grid-template-columns: 92px repeat(3, 1fr); }
  .role-mini-row { padding-left: 100px; }
  .role-preview-permissions > header { align-items: flex-start; flex-direction: column; }
  .role-preview-permissions > div { grid-template-columns: 1fr; }
}

@media (max-width: 430px) {
  .brand > span:last-child { display: none; }
  .statistics-page-actions .button { min-height: 36px; padding: 0 9px; font-size: 11px; }
  .statistics-page-title h1 { font-size: 22px; }
  .statistics-source-badge { font-size: 7px; }
}

@media (max-height: 760px) {
  .logs-page-header { min-height: 88px; padding-top: 9px; padding-bottom: 9px; }
  .logs-page-title > p { display: none; }
  .logs-page-title h1 { font-size: 25px; }
  .logs-page-main { padding-top: 9px; padding-bottom: 9px; gap: 8px; }
  .logs-summary article { padding-top: 8px; padding-bottom: 8px; }
  .logs-summary strong { font-size: 20px; }
  .logs-summary span { display: none; }
  .logs-page-panel-head { min-height: 45px; padding-top: 7px; padding-bottom: 7px; }
  .statistics-page-header { min-height: 88px; padding-top: 9px; padding-bottom: 9px; }
  .statistics-page-title > p { display: none; }
  .statistics-page-title h1 { font-size: 25px; }
  .statistics-page-main { padding-top: 9px; padding-bottom: 9px; gap: 8px; }
  .statistics-summary article { padding-top: 8px; padding-bottom: 8px; }
  .statistics-summary strong { font-size: 20px; }
  .statistics-summary span { display: none; }
  .statistics-panel-head { min-height: 45px; padding-top: 7px; padding-bottom: 7px; }
  .statistics-table th, .statistics-table td { height: 54px; padding-top: 6px; padding-bottom: 6px; }
}

/* Modern configuration workspace */
.config-page {
  --config-canvas: #f4f5f2;
  --config-panel: #ffffff;
  --config-panel-muted: #f7f8f5;
  --config-border: #e2e5df;
  --config-border-strong: #d4d9d1;
  --config-text: #1f2421;
  --config-muted: #68716b;
  --config-accent: #5b9f17;
  --config-accent-soft: #eef7e3;
  background:
    radial-gradient(circle at 80% 0%, rgba(97,166,14,.055), transparent 28rem),
    var(--config-canvas);
  color: var(--config-text);
}
.config-page-shell { min-height: 100dvh; }
.config-page-header {
  position: sticky;
  z-index: 30;
  top: 0;
  min-height: 90px;
  padding: 15px clamp(20px, 3vw, 52px);
  grid-template-columns: auto minmax(300px, 1fr) auto;
  gap: clamp(24px, 3vw, 48px);
  border-color: rgba(217,221,214,.9);
  background: rgba(250,251,248,.9);
  box-shadow: 0 1px 0 rgba(255,255,255,.7);
  backdrop-filter: blur(18px);
}
.config-page-header .brand { gap: 11px; }
.config-page-header .brand-mark { width: 38px; height: 50px; }
.config-page-header .brand-mark img { width: 35px; height: 46px; }
.config-page-header .brand strong { font-size: 18px; }
.config-page-header .brand small { font-size: 9px; }
.config-page-title {
  padding-left: clamp(22px, 2.4vw, 38px);
  border-color: var(--config-border);
}
.config-title-line { align-items: center; }
.config-page-title h1 {
  margin-top: 2px;
  color: var(--config-text);
  font-size: clamp(25px, 2vw, 34px);
  font-weight: 760;
  letter-spacing: -.035em;
}
.config-page-title > p { margin-top: 4px; color: var(--config-muted); font-size: 12px; }
.config-source-badge {
  padding: 4px 8px;
  border: 1px solid #dcebcf;
  border-radius: 999px;
  background: var(--config-accent-soft);
  color: #477e10;
  font-size: 8px;
}
.config-page .config-back-button {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--config-border-strong);
  border-radius: 11px;
  background: white;
  color: var(--config-text);
  box-shadow: 0 4px 14px rgba(37,45,39,.045);
}
.config-page .config-back-button:hover { border-color: #bdc5bb; box-shadow: 0 8px 22px rgba(37,45,39,.08); }
.config-page-main {
  width: min(1760px, 100%);
  margin: 0 auto;
  padding: clamp(18px, 2vw, 32px) clamp(18px, 3vw, 52px) clamp(28px, 4vw, 58px);
}
.config-page-panel {
  min-height: calc(100dvh - 144px);
  display: grid;
  grid-template-rows: auto 1fr;
  overflow: hidden;
  border: 1px solid var(--config-border);
  border-radius: 20px;
  background: var(--config-panel);
  box-shadow: 0 18px 55px rgba(41,48,42,.075);
}
.config-page-panel-head {
  min-height: 86px;
  padding: 18px 24px;
  border-color: var(--config-border);
  background: linear-gradient(135deg, #fbfcfa, #f7f9f5);
}
.config-page-panel-head h2 { margin-top: 3px; color: var(--config-text); font-size: 18px; letter-spacing: -.015em; }
.config-page-panel-head p { margin-top: 4px; color: var(--config-muted); font-size: 10px; }
.config-panel-kicker {
  display: block;
  color: var(--config-accent);
  font-size: 8px;
  font-weight: 850;
  letter-spacing: .11em;
  text-transform: uppercase;
}
#configSaveState {
  min-height: 28px;
  padding: 7px 10px;
  border-radius: 999px;
  background: var(--config-accent-soft);
  color: #477e10;
  font-size: 9px;
}
#configSaveState:empty { display: none; }
#configSaveState.error { background: #fff0ed; color: #ad4536; }
#configSaveState.unsaved { padding-left: 24px; position: relative; background: #fff2db; color: #8b5715; }
#configSaveState.unsaved::before { content: ''; position: absolute; left: 10px; top: 50%; width: 7px; height: 7px; margin-top: -3.5px; border-radius: 50%; background: #e89a29; }
.config-page-workspace {
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  align-items: stretch;
}
.config-page-tabs {
  min-width: 0;
  padding: 22px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: visible;
  border: 0;
  border-right: 1px solid var(--config-border);
  background: var(--config-panel-muted);
}
.config-nav-intro { padding: 3px 10px 12px; }
.config-nav-intro > span {
  color: var(--config-muted);
  font-size: 8px;
  font-weight: 850;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.config-nav-intro p { margin: 5px 0 0; color: var(--config-muted); font-size: 10px; line-height: 1.4; }
.config-page-tabs button {
  width: 100%;
  min-height: 62px;
  margin: 0;
  padding: 9px 10px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  color: var(--config-muted);
  text-align: left;
  white-space: normal;
  transition: border-color .16s ease, background .16s ease, box-shadow .16s ease, transform .16s ease;
}
.config-page-tabs button:hover { transform: translateX(2px); background: rgba(255,255,255,.72); color: var(--config-text); }
.config-page-tabs button.active {
  border-color: var(--config-border);
  background: white;
  color: var(--config-text);
  box-shadow: 0 7px 22px rgba(40,48,41,.075);
}
.config-tab-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #e9ece7;
  color: #536057;
  font-size: 17px;
  font-weight: 700;
}
.config-page-tabs button.active .config-tab-icon { background: var(--config-accent-soft); color: var(--config-accent); }
.config-tab-copy, .config-tab-copy strong, .config-tab-copy small { min-width: 0; display: block; }
.config-tab-copy strong { color: inherit; font-size: 11px; font-weight: 780; }
.config-tab-copy small { margin-top: 3px; color: var(--config-muted); font-size: 8px; font-weight: 550; }
.config-tab-arrow { color: #a6ada7; font-size: 19px; }
.config-page-tabs button.active .config-tab-arrow { color: var(--config-accent); }
.config-nav-note {
  margin-top: auto;
  padding: 12px 10px;
  display: flex;
  align-items: flex-start;
  gap: 9px;
  border: 1px solid #dfe9d6;
  border-radius: 12px;
  background: rgba(238,247,227,.76);
}
.config-nav-note > span { width: 20px; height: 20px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; background: var(--config-accent); color: white; font-size: 10px; }
.config-nav-note p, .config-nav-note strong, .config-nav-note small { display: block; margin: 0; }
.config-nav-note strong { font-size: 9px; }
.config-nav-note small { margin-top: 3px; color: var(--config-muted); font-size: 7px; line-height: 1.4; }
.config-page-workspace > form {
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-rows: 1fr auto;
  background: white;
}
.config-page-content { min-width: 0; min-height: 0; padding: 0; overflow: visible; }
.config-page-content > [data-config-panel] { min-width: 0; padding: 28px; }
.config-page-content > [data-config-panel="integrations"]:not(.hidden) {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-content: start;
  gap: 18px;
}
.config-page-content > [data-config-panel="integrations"] > .privacy-note { grid-column: 1 / -1; }
.config-page .integration-group-heading {
  grid-column: 1 / -1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--config-text);
}
.config-page .integration-group-heading > span {
  padding: 5px 8px;
  border-radius: 999px;
  background: #eef2ec;
  color: #5d695f;
  font-size: 7px;
  font-weight: 850;
  letter-spacing: .11em;
  text-transform: uppercase;
}
.config-page .integration-group-heading > div { min-width: 0; display: grid; gap: 2px; }
.config-page .integration-group-heading strong { font-size: 13px; }
.config-page .integration-group-heading small { color: var(--config-muted); font-size: 9px; }
.config-page .microsoft-group-heading { margin-top: 6px; padding-top: 20px; border-top: 1px solid var(--config-border); }
.config-page .privacy-note {
  margin: 0;
  min-height: 58px;
  padding: 13px 15px;
  align-items: center;
  border: 1px solid #deead3;
  border-radius: 12px;
  background: #f4f9ee;
}
.config-page .privacy-note > span { width: 30px; height: 30px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 9px; background: white; color: var(--config-accent); font-size: 16px; box-shadow: 0 2px 8px rgba(52,76,31,.07); }
.config-page .privacy-note p { color: var(--config-muted); font-size: 10px; }
.config-page .privacy-note strong { margin-bottom: 2px; font-size: 11px; }
.config-page .integration-card {
  min-width: 0;
  min-height: 250px;
  margin: 0;
  padding: 22px;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--config-border);
  border-radius: 16px;
  background: white;
  box-shadow: 0 8px 28px rgba(39,47,40,.055);
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}
.config-page .integration-card:hover { transform: translateY(-1px); border-color: #d3d9d1; box-shadow: 0 13px 36px rgba(39,47,40,.08); }
.config-page .integration-head { margin-bottom: 24px; gap: 13px; }
.config-page .integration-logo { width: 44px; height: 44px; border-radius: 12px; font-size: 20px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.18); }
.config-page .rentman-logo { background: linear-gradient(145deg, #7765d7, #6754c1); }
.config-page .personio-logo { background: linear-gradient(145deg, #dd8065, #ca664d); }
.config-page .microsoft-logo { background: linear-gradient(145deg, #2f6fb4, #1d5593); }
.config-page .planner-logo { background: linear-gradient(145deg, #4c6fbf, #31559f); }
.config-page .integration-card-wide { grid-column: 1 / -1; min-height: 0; }
.config-page .microsoft-integration-card { grid-column: 1 / -1; background: linear-gradient(180deg, #fff 0%, #f9fbfe 100%); }
.config-page .planner-integration-card { grid-column: 1 / -1; background: linear-gradient(180deg, #fff 0%, #fbfcff 100%); }
.config-page .planner-setup-note,
.config-page .planner-dependency-note {
  min-height: 48px;
  margin: -5px 0 18px;
  padding: 11px 13px;
  display: flex;
  align-items: center;
  gap: 9px;
  border: 1px solid #dbe3f2;
  border-radius: 11px;
  background: #f3f6fc;
  color: #536176;
  font-size: 9px;
  line-height: 1.45;
}
.config-page .planner-setup-note > span,
.config-page .planner-dependency-note > span { color: #3d64ad; font-size: 15px; }
.config-page .planner-setup-note p,
.config-page .planner-dependency-note p { margin: 0; }
.config-page .microsoft-credentials-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.config-page .microsoft-secret-field { grid-column: 1 / -1; }
.config-page .planner-target-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.config-page .planner-target-toolbar { margin: 1px 0 14px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.config-page .planner-target-toolbar > div { display: grid; gap: 2px; }
.config-page .planner-target-toolbar strong { color: var(--config-text); font-size: 12px; }
.config-page .planner-target-toolbar small { color: var(--config-muted); font-size: 8px; }
.config-page .planner-target-list { display: grid; gap: 14px; }
.config-page .planner-target-empty { min-height: 150px; padding: 24px; display: grid; place-items: center; align-content: center; gap: 5px; border: 1px dashed #cfd6cf; border-radius: 13px; background: rgba(248,250,247,.72); text-align: center; }
.config-page .planner-target-empty > span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: var(--config-accent-soft); color: var(--config-accent); font-size: 20px; }
.config-page .planner-target-empty strong { margin-top: 3px; font-size: 11px; }
.config-page .planner-target-empty p { margin: 0; color: var(--config-muted); font-size: 8px; }
.config-page .planner-target-card { overflow: hidden; border: 1px solid #dce1dc; border-radius: 14px; background: rgba(255,255,255,.9); box-shadow: 0 5px 18px rgba(40,54,43,.045); }
.config-page .planner-target-head { min-height: 62px; padding: 12px 14px; display: flex; align-items: center; gap: 10px; border-bottom: 1px solid #e4e8e3; background: #f7f9f7; }
.config-page .planner-target-number { width: 30px; height: 30px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 9px; background: #eaf0fb; color: #31599c; font-size: 11px; font-weight: 850; }
.config-page .planner-target-head > div:nth-child(2) { min-width: 0; display: grid; gap: 2px; }
.config-page .planner-target-head strong { overflow: hidden; color: var(--config-text); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.config-page .planner-target-head small { color: var(--config-muted); font-size: 8px; }
.config-page .planner-default-choice { display: inline-flex; align-items: center; gap: 6px; color: #59635c; font-size: 8px; font-weight: 700; white-space: nowrap; }
.config-page .planner-default-choice input { width: 15px; height: 15px; margin: 0; accent-color: var(--config-accent); }
.config-page .planner-default-target { margin-left: auto; }
.config-page .planner-icon-button { width: 30px; height: 30px; display: grid; place-items: center; flex: 0 0 auto; border: 1px solid #d7ddd7; border-radius: 8px; background: white; color: #68716b; font-size: 16px; cursor: pointer; }
.config-page .planner-icon-button:hover { border-color: #bcc6bc; background: #f7f9f7; }
.config-page .planner-icon-button.danger:hover { border-color: #efc2bb; background: #fff2f0; color: #ad3e31; }
.config-page .planner-target-card > .planner-target-grid { padding: 14px; }
.config-page .planner-bucket-section { padding: 0 14px 14px; }
.config-page .planner-bucket-heading { margin-bottom: 9px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.config-page .planner-bucket-heading > div { display: grid; gap: 2px; }
.config-page .planner-bucket-heading strong { font-size: 10px; }
.config-page .planner-bucket-heading small { color: var(--config-muted); font-size: 8px; }
.config-page .planner-bucket-heading .button { min-height: 32px; padding: 0 11px; font-size: 8px; }
.config-page .planner-bucket-list { display: grid; gap: 7px; }
.config-page .planner-bucket-row { padding: 9px; display: grid; grid-template-columns: auto minmax(150px,.65fr) minmax(240px,1fr) auto; align-items: end; gap: 9px; border: 1px solid #e2e6e1; border-radius: 10px; background: #fafbf9; }
.config-page .planner-bucket-row .planner-default-choice { align-self: center; }
.config-page .planner-bucket-row .field { gap: 5px; }
.config-page .planner-bucket-row .field input { height: 38px; }
.config-page .planner-target-result { margin: 0 14px 13px; padding: 10px 12px; border: 1px solid #cfe3bc; border-radius: 9px; background: #f3faec; color: #477e10; font-size: 9px; font-weight: 700; }
.config-page .planner-target-result.error { border-color: #efc9c2; background: #fff3f1; color: #a13e31; }
.config-page .planner-target-footer { min-height: 52px; padding: 10px 14px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-top: 1px solid #e4e8e3; background: #fbfcfb; }
.config-page .planner-target-footer span { color: var(--config-muted); font-size: 8px; }
.config-page .planner-target-footer > div { display: flex; align-items: center; gap: 8px; }
.config-page .planner-target-footer .button { min-height: 34px; padding: 0 12px; font-size: 8px; }
.config-page .planner-section-label { margin: 19px 0 11px; display: flex; align-items: baseline; gap: 9px; }
.config-page .planner-section-label strong { color: var(--config-text); font-size: 11px; }
.config-page .planner-section-label small { color: var(--config-muted); font-size: 8px; }
.config-page .planner-test-result {
  min-height: 40px;
  margin-top: 14px;
  padding: 10px 13px;
  display: flex;
  align-items: center;
  border: 1px solid #cfe3bc;
  border-radius: 10px;
  background: #f3faec;
  color: #477e10;
  font-size: 9px;
  font-weight: 700;
}
.config-page .planner-test-result.error { border-color: #efc9c2; background: #fff3f1; color: #a13e31; }
.config-page .planner-integration-actions > div { display: flex; align-items: center; gap: 14px; }
.config-page .planner-integration-actions .button { min-height: 36px; padding: 0 13px; font-size: 9px; }
.config-page .integration-head h3 { color: var(--config-text); font-size: 16px; letter-spacing: -.01em; }
.config-page .integration-head p { margin-top: 3px; color: var(--config-muted); font-size: 9px; }
.config-page .connection-pill {
  padding: 6px 9px;
  border: 1px solid var(--config-border);
  border-radius: 999px;
  background: #f1f3f0;
  color: #737c76;
  font-size: 7px;
  letter-spacing: .08em;
}
.config-page .connection-pill.connected { border-color: #dcebcf; background: var(--config-accent-soft); color: #477e10; }
.config-page .field { display: grid; gap: 7px; }
.config-page .field > span { color: #4e5751; font-size: 9px; font-weight: 780; }
.config-page .field input,
.config-page .field select,
.config-page .role-editor-toolbar select,
.config-page .role-editor-toolbar input,
.config-page .role-assignment-add select,
.config-page .role-assignment-add input,
.config-page .employee-access-search input,
.config-page .settings-select-row select {
  height: 44px;
  padding: 0 13px;
  border: 1px solid var(--config-border-strong);
  border-radius: 10px;
  background: #fbfcfa;
  color: var(--config-text);
  font-size: 10px;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.config-page .field input:hover,
.config-page .field select:hover,
.config-page .role-editor-toolbar select:hover,
.config-page .role-editor-toolbar input:hover,
.config-page .role-assignment-add select:hover,
.config-page .role-assignment-add input:hover,
.config-page .employee-access-search input:hover,
.config-page .settings-select-row select:hover { border-color: #bbc3b9; background: white; }
.config-page .field input:focus,
.config-page .field select:focus,
.config-page .role-editor-toolbar select:focus,
.config-page .role-editor-toolbar input:focus,
.config-page .role-assignment-add select:focus,
.config-page .role-assignment-add input:focus,
.config-page .employee-access-search input:focus,
.config-page .settings-select-row select:focus { border-color: #8fba67; background: white; box-shadow: 0 0 0 3px rgba(97,166,14,.1); outline: 0; }
.config-page .integration-card .form-grid { gap: 12px; }
.config-page .integration-actions { margin-top: auto; padding-top: 18px; }
.config-page .integration-actions small { color: var(--config-muted); font-size: 8px; }
.config-page .text-button { font-size: 9px; }
.config-page .settings-section-head,
.config-page .settings-rule-table,
.config-page .settings-select-row,
.config-page .settings-info,
.config-page .role-editor-toolbar,
.config-page .permission-modules,
.config-page .role-employee-access,
.config-page .role-assignment-add,
.config-page .role-assignment-list { margin-left: 0; margin-right: 0; }
.config-page .settings-section-head { margin-top: 4px; margin-bottom: 14px; }
.config-page .settings-section-head:not(:first-child) { margin-top: 30px; }
.config-page .settings-section-head h3 { color: var(--config-text); font-size: 15px; letter-spacing: -.01em; }
.config-page .settings-section-head p { margin-top: 4px; color: var(--config-muted); font-size: 9px; }
.config-page .settings-rule-table,
.config-page .role-employee-access,
.config-page .role-assignment-list {
  border-color: var(--config-border);
  border-radius: 14px;
  box-shadow: 0 5px 20px rgba(39,47,40,.035);
}
.config-page .settings-rule-row { min-height: 56px; border-color: var(--config-border); }
.config-page .settings-rule-row.header { min-height: 40px; background: var(--config-panel-muted); }
.config-page .settings-rule-row strong { font-size: 11px; }
.config-page .settings-rule-row small { font-size: 8px; }
.config-page .settings-select-row {
  min-height: 66px;
  padding: 11px 15px;
  border-color: var(--config-border);
  border-radius: 13px;
  background: var(--config-panel-muted);
}
.config-page .settings-info { padding: 14px 16px; border: 1px solid #deead3; border-radius: 12px; background: #f4f9ee; color: #56624f; font-size: 9px; }
.config-page .role-editor-toolbar,
.config-page .role-assignment-add {
  padding: 16px;
  border-color: var(--config-border);
  border-radius: 14px;
  background: var(--config-panel-muted);
}
.config-page .role-editor-toolbar label > span,
.config-page .role-assignment-add label > span,
.config-page .employee-access-search > span { color: var(--config-muted); font-size: 8px; }
.config-page .permission-modules { gap: 14px; }
.config-page .permission-module { border-color: var(--config-border); border-radius: 14px; box-shadow: 0 5px 20px rgba(39,47,40,.035); }
.config-page .permission-module > header { min-height: 62px; padding: 12px 14px; background: var(--config-panel-muted); }
.config-page .permission-module > header strong { font-size: 12px; }
.config-page .permission-item { min-height: 60px; padding: 10px 14px; }
.config-page .permission-item strong { font-size: 10px; }
.config-page .permission-item.enabled { background: #f7fbf3; }
.config-page .role-employee-access-toolbar { padding: 14px; border-color: var(--config-border); background: var(--config-panel-muted); }
.config-page .employee-access-mode { min-height: 60px; border-color: var(--config-border); border-radius: 10px; background: white; }
.config-page .employee-access-mode:has(input:checked) { border-color: #a9ca88; background: var(--config-accent-soft); box-shadow: inset 3px 0 0 var(--config-accent); }
.config-page .role-employee-list { max-height: 460px; padding: 12px; gap: 9px; }
.config-page .role-employee-item { min-height: 60px; border-color: var(--config-border); border-radius: 10px; background: #fbfcfa; }
.config-page .role-assignment-row { min-height: 56px; padding: 10px 14px; }
.config-page-foot {
  position: sticky;
  bottom: 0;
  z-index: 10;
  min-height: 70px;
  padding: 13px 20px;
  border-color: var(--config-border);
  background: rgba(255,255,255,.94);
  box-shadow: 0 -10px 30px rgba(44,51,45,.035);
  backdrop-filter: blur(14px);
}
.config-page-foot .helper-text { color: var(--config-muted); font-size: 8px; }
.config-page-foot .button-dark {
  min-height: 43px;
  padding: 0 18px;
  border-radius: 10px;
  background: var(--config-text);
  font-size: 11px;
  box-shadow: 0 7px 18px rgba(31,36,33,.15);
}
.config-page .rental-address-book { display: grid; gap: 14px; }
.config-page .rental-address-add { padding: 16px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 12px; border: 1px solid var(--config-border); border-radius: 14px; background: var(--config-panel-muted); }
.config-page .rental-address-add label { display: grid; gap: 7px; }
.config-page .rental-address-add label > span,
.config-page .rental-address-row label > span { color: var(--config-muted); font-size: 8px; font-weight: 780; }
.config-page .rental-address-add input,
.config-page .rental-address-row input { width: 100%; height: 44px; padding: 0 13px; border: 1px solid var(--config-border-strong); border-radius: 10px; background: white; color: var(--config-text); font-size: 10px; }
.config-page .rental-address-add input:focus,
.config-page .rental-address-row input:focus { border-color: #8fba67; box-shadow: 0 0 0 3px rgba(97,166,14,.1); outline: 0; }
.config-page .rental-address-note { min-height: 48px; padding: 11px 13px; display: flex; align-items: center; gap: 9px; border: 1px solid #deead3; border-radius: 11px; background: #f4f9ee; color: #56624f; font-size: 9px; }
.config-page .rental-address-note > span { color: var(--config-accent); font-size: 15px; }
.config-page .rental-address-note p { margin: 0; }
.config-page .rental-address-list { display: grid; gap: 8px; }
.config-page .rental-address-row { min-height: 68px; padding: 10px 12px; display: grid; grid-template-columns: 34px minmax(0, 1fr) 34px; align-items: center; gap: 10px; border: 1px solid var(--config-border); border-radius: 12px; background: white; box-shadow: 0 4px 16px rgba(39,47,40,.035); }
.config-page .rental-address-row label { min-width: 0; display: grid; gap: 4px; }
.config-page .rental-address-pin { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 9px; background: var(--config-accent-soft); color: var(--config-accent); font-size: 16px; }
.config-page .rental-address-row .icon-button { width: 32px; height: 32px; border-color: #ead7d2; color: #a44537; }
.config-page .rental-address-empty { min-height: 190px; display: grid; place-content: center; text-align: center; border: 1px dashed var(--config-border-strong); border-radius: 14px; background: #fbfcfa; }
.config-page .rental-address-empty strong { font-size: 12px; }
.config-page .rental-address-empty p { margin: 5px 0 0; color: var(--config-muted); font-size: 9px; }

@media (max-width: 1180px) {
  .config-page-workspace { grid-template-columns: 220px minmax(0, 1fr); }
  .config-page-content > [data-config-panel="integrations"]:not(.hidden) { grid-template-columns: 1fr; }
  .config-page-content > [data-config-panel="integrations"] > .privacy-note { grid-column: auto; }
  .config-page .integration-card { min-height: 0; }
  .config-page .microsoft-credentials-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .config-page .microsoft-secret-field { grid-column: 1 / -1; }
  .config-page .role-editor-toolbar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .config-page .role-editor-toolbar .button { width: 100%; }
  .config-page .role-employee-access-toolbar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .config-page .employee-access-actions { grid-auto-flow: column; justify-content: start; }
}

@media (max-width: 820px) {
  .config-page-header { min-height: 82px; grid-template-columns: auto 1fr auto; gap: 14px; padding: 12px 16px; }
  .config-page-header .brand > span:last-child { display: none; }
  .config-page-title { padding-left: 16px; }
  .config-page-title .config-title-line, .config-page-title > p { display: none; }
  .config-page-title h1 { margin: 0; font-size: 24px; }
  .config-page .config-back-button { min-height: 38px; padding: 0 12px; font-size: 11px; }
  .config-page-main { padding: 12px; }
  .config-page-panel { min-height: calc(100dvh - 106px); border-radius: 15px; }
  .config-page-panel-head { min-height: 72px; padding: 14px 16px; }
  .config-page-panel-head p { display: block; }
  .config-page-workspace { grid-template-columns: 1fr; }
  .config-page-tabs {
    padding: 10px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 7px;
    border-right: 0;
    border-bottom: 1px solid var(--config-border);
  }
  .config-nav-intro, .config-nav-note { display: none; }
  .config-page-tabs button { min-height: 50px; padding: 7px; grid-template-columns: 28px minmax(0, 1fr); gap: 7px; }
  .config-tab-icon { width: 28px; height: 28px; border-radius: 8px; font-size: 14px; }
  .config-tab-copy strong { font-size: 9px; }
  .config-tab-copy small, .config-tab-arrow { display: none; }
  .config-page-content > [data-config-panel] { padding: 20px; }
  .config-page .permission-modules { grid-template-columns: 1fr; }
  .config-page .role-employee-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .config-page .planner-bucket-row { grid-template-columns: auto minmax(0, 1fr) auto; }
  .config-page .planner-bucket-id-field { grid-column: 2 / 3; }
  .config-page .planner-bucket-row .planner-icon-button { grid-column: 3; grid-row: 1 / 3; align-self: center; }
}

@media (max-width: 580px) {
  .config-page-header { grid-template-columns: auto 1fr; }
  .config-page-title { border-left: 0; padding-left: 0; }
  .config-page-title h1 { font-size: 21px; }
  .config-page-actions { grid-column: 2; grid-row: 1; }
  .config-page .config-back-button { font-size: 0; width: 40px; padding: 0; }
  .config-page .planner-target-toolbar,
  .config-page .planner-bucket-heading,
  .config-page .planner-target-footer { align-items: stretch; flex-direction: column; }
  .config-page .planner-target-toolbar .button,
  .config-page .planner-bucket-heading .button,
  .config-page .planner-target-footer .button { width: 100%; }
  .config-page .planner-target-footer > div { width: 100%; flex-direction: column; }
  .config-page .planner-target-head { align-items: flex-start; flex-wrap: wrap; }
  .config-page .planner-default-target { margin-left: 40px; }
  .config-page .planner-bucket-row { grid-template-columns: 1fr auto; }
  .config-page .planner-bucket-row .planner-default-choice,
  .config-page .planner-bucket-row .field { grid-column: 1; }
  .config-page .planner-bucket-id-field { grid-column: 1; }
  .config-page .planner-bucket-row .planner-icon-button { grid-column: 2; grid-row: 1 / 4; }
  .config-page .config-back-button span { font-size: 16px; }
  .config-page-panel-head { min-height: 64px; }
  .config-page-panel-head h2 { font-size: 15px; }
  .config-page-panel-head p, .config-panel-kicker { display: none; }
  .config-page-tabs { display: flex; overflow-x: auto; }
  .config-page-tabs button { min-width: 145px; }
  .config-page-content > [data-config-panel] { padding: 15px; }
  .config-page .integration-card { padding: 16px; border-radius: 13px; }
  .config-page .integration-head { align-items: flex-start; }
  .config-page .integration-head .connection-pill { margin-left: 0; }
  .config-page .integration-card .form-grid { grid-template-columns: 1fr; }
  .config-page .microsoft-secret-field { grid-column: auto; }
  .config-page .planner-section-label,
  .config-page .planner-integration-actions { align-items: flex-start; flex-direction: column; }
  .config-page .planner-integration-actions > div { width: 100%; justify-content: space-between; }
  .config-page .rental-address-add { grid-template-columns: 1fr; }
  .config-page .rental-address-add .button { width: 100%; }
  .config-page .settings-rule-table { overflow-x: auto; }
  .config-page .settings-rule-row { min-width: 650px; }
  .config-page .settings-select-row { align-items: stretch; flex-direction: column; }
  .config-page .settings-select-row select { min-width: 0; width: 100%; }
  .config-page .role-editor-toolbar,
  .config-page .role-assignment-add,
  .config-page .role-employee-access-toolbar { grid-template-columns: 1fr; }
  .config-page .role-employee-list { grid-template-columns: 1fr; }
  .config-page-foot { padding: 10px 12px; }
  .config-page-foot .helper-text { display: none; }
  .config-page-foot .button { width: 100%; }
}

.config-page .role-entry-access {
  margin: 0 0 26px;
  overflow: hidden;
  border: 1px solid var(--config-border);
  border-radius: 14px;
  background: white;
  box-shadow: 0 5px 20px rgba(39,47,40,.035);
}
.config-page .role-entry-access-note {
  min-height: 52px;
  padding: 11px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--config-border);
  background: #f7faf4;
  color: var(--config-muted);
}
.config-page .role-entry-access-note > span {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 8px;
  background: var(--config-accent-soft);
  color: var(--config-accent);
  font-size: 14px;
}
.config-page .role-entry-access-note p { margin: 0; font-size: 9px; line-height: 1.45; }
.config-page .role-entry-rule-table { min-width: 1050px; }
.config-page .role-entry-rule-row {
  min-height: 58px;
  display: grid;
  grid-template-columns: minmax(250px, 1fr) 115px 130px 145px 150px 160px;
  align-items: stretch;
  border-bottom: 1px solid var(--config-border);
}
.config-page .role-entry-rule-row:last-child { border-bottom: 0; }
.config-page .role-entry-rule-row.header {
  min-height: 41px;
  background: var(--config-panel-muted);
  color: var(--config-muted);
  font-size: 8px;
  font-weight: 850;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.config-page .role-entry-rule-row > * {
  min-width: 0;
  padding: 10px 14px;
  display: flex;
  align-items: center;
}
.config-page .role-entry-rule-row > * + * { justify-content: center; border-left: 1px solid var(--config-border); }
.config-page .role-entry-rule-row > span:first-child { display: block; align-self: center; }
.config-page .role-entry-rule-row strong,
.config-page .role-entry-rule-row small { display: block; }
.config-page .role-entry-rule-row strong { color: var(--config-text); font-size: 11px; }
.config-page .role-entry-rule-row small { margin-top: 3px; color: var(--config-muted); font-size: 8px; }
.config-page .role-entry-rule-row .settings-check { font-size: 9px; }
.config-page .role-entry-rule-row .settings-check.unavailable { color: #9a9f9b; cursor: default; }

.config-page .teams-report-head { margin-top: 0; }
.config-page .teams-report-settings { margin: 0 24px 28px; }
.config-page .teams-report-master { padding: 14px; display: grid; grid-template-columns: minmax(300px, 1fr) 150px auto; align-items: end; gap: 12px; border: 1px solid var(--config-border); border-radius: 14px; background: #fff; box-shadow: 0 10px 30px rgba(39,47,40,.05); }
.config-page .teams-report-master .permission-item { min-height: 54px; margin: 0; border: 0; background: var(--config-panel-muted); }
.config-page .teams-report-info { margin: 12px 0 18px; padding: 12px 14px; display: flex; gap: 10px; border: 1px solid #d7e3f5; border-radius: 12px; background: #f4f8ff; color: #3e5879; font-size: 9px; line-height: 1.55; }
.config-page .teams-report-info p { margin: 0; }
.config-page .teams-destination-list { display: grid; gap: 14px; }
.config-page .teams-destination-card { overflow: hidden; border: 1px solid var(--config-border); border-radius: 14px; background: #fff; box-shadow: 0 10px 30px rgba(39,47,40,.05); }
.config-page .teams-destination-card > header { min-height: 58px; padding: 11px 14px; display: grid; grid-template-columns: 32px minmax(0,1fr) auto; align-items: center; gap: 10px; border-bottom: 1px solid var(--config-border); background: var(--config-panel-muted); }
.config-page .teams-destination-number { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 9px; background: #e8f4dc; color: var(--config-accent); font-size: 11px; font-weight: 900; }
.config-page .teams-destination-card header strong, .config-page .teams-destination-card header small { display: block; }
.config-page .teams-destination-card header strong { font-size: 12px; }
.config-page .teams-destination-card header small { margin-top: 3px; color: var(--config-muted); font-size: 8px; }
.config-page .teams-enabled { display: flex; align-items: center; gap: 6px; font-size: 9px; font-weight: 800; }
.config-page .teams-enabled input { accent-color: var(--config-accent); }
.config-page .teams-destination-grid { padding: 14px; display: grid; grid-template-columns: minmax(220px,.65fr) minmax(220px,.65fr) minmax(320px,1fr); gap: 12px; }
.config-page .teams-webhook-field { grid-column: 3; }
.config-page .teams-employee-field { grid-column: 1 / -1; }
.config-page .teams-employee-field select { min-height: 150px; padding: 6px; }
.config-page .teams-employee-field option { padding: 6px 8px; border-radius: 5px; }
.config-page .teams-destination-card > footer { min-height: 54px; padding: 9px 14px; display: flex; align-items: center; justify-content: flex-end; gap: 8px; border-top: 1px solid var(--config-border); background: #fcfcfa; }
.config-page .teams-test-result { margin-right: auto; color: #43840b; font-size: 9px; font-weight: 750; }
.config-page .teams-test-result.error { color: #b7352b; }
.config-page .teams-report-empty { padding: 42px 20px; text-align: center; border: 1px dashed var(--config-border); border-radius: 14px; background: #fff; }
.config-page .teams-report-empty strong { font-size: 13px; }
.config-page .teams-report-empty p { margin: 6px 0 0; color: var(--config-muted); font-size: 9px; }

@media (max-width: 1050px) {
  .config-page .teams-report-master { grid-template-columns: 1fr 150px; }
  .config-page .teams-report-master > button { grid-column: 1 / -1; justify-self: start; }
  .config-page .teams-destination-grid { grid-template-columns: 1fr 1fr; }
  .config-page .teams-webhook-field, .config-page .teams-employee-field { grid-column: 1 / -1; }
}
@media (max-width: 680px) {
  .config-page .teams-report-settings { margin-left: 12px; margin-right: 12px; }
  .config-page .teams-report-master, .config-page .teams-destination-grid { grid-template-columns: 1fr; }
  .config-page .teams-report-master > button, .config-page .teams-webhook-field, .config-page .teams-employee-field { grid-column: 1; }
  .config-page .teams-destination-card > footer { align-items: stretch; flex-wrap: wrap; }
  .config-page .teams-test-result { width: 100%; }
}
.config-page .role-entry-rule-row .settings-check.unavailable input { opacity: .45; }

.config-page .absence-access-head { margin-top: 28px; }
.config-page .role-absence-access {
  margin: 0 0 26px;
  overflow: hidden;
  border: 1px solid var(--config-border);
  border-radius: 14px;
  background: white;
  box-shadow: 0 5px 20px rgba(39,47,40,.035);
}
.config-page .role-absence-access-note {
  min-height: 52px;
  padding: 11px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--config-border);
  background: #f7faf4;
  color: var(--config-muted);
}
.config-page .role-absence-access-note > span {
  width: 27px;
  height: 27px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--config-accent-soft);
  color: var(--config-accent);
  font-size: 12px;
}
.config-page .role-absence-access-note p { margin: 0; font-size: 9px; line-height: 1.45; }
.config-page .role-absence-rule-grid { padding: 12px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.config-page .role-absence-rule {
  min-width: 0;
  min-height: 70px;
  padding: 11px 12px;
  display: grid;
  grid-template-columns: minmax(150px, 1fr) auto;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--config-border);
  border-radius: 11px;
  background: #fcfcfa;
}
.config-page .role-absence-rule > span strong,
.config-page .role-absence-rule > span small { display: block; }
.config-page .role-absence-rule > span strong { color: var(--config-text); font-size: 10px; }
.config-page .role-absence-rule > span small { margin-top: 3px; color: var(--config-muted); font-size: 8px; }
.config-page .absence-access-options { padding: 3px; display: flex; gap: 3px; border: 1px solid var(--config-border); border-radius: 9px; background: #f1f2ee; }
.config-page .absence-access-options label { min-height: 31px; padding: 6px 9px; display: flex; align-items: center; border-radius: 6px; color: var(--config-muted); font-size: 8px; font-weight: 750; white-space: nowrap; cursor: pointer; }
.config-page .absence-access-options label.selected { background: white; color: var(--config-text); box-shadow: 0 1px 4px rgba(32,37,33,.11); }
.config-page .absence-access-options input { position: absolute; opacity: 0; pointer-events: none; }
.config-page .role-absence-empty { margin: 0; padding: 24px; color: var(--config-muted); font-size: 9px; text-align: center; }

@media (max-width: 900px) {
  .config-page .role-entry-access { overflow-x: auto; }
  .config-page .role-absence-rule-grid { grid-template-columns: 1fr; }
  .config-page .role-absence-rule { grid-template-columns: 1fr; }
  .config-page .absence-access-options { width: max-content; max-width: 100%; }
}

/* Gemeinsamer Oberflächen-Feinschliff */
:root {
  --radius-control: 10px;
  --radius-card: 14px;
  --radius-panel: 18px;
  --shadow-card: 0 8px 28px rgba(36, 37, 40, .055);
  --shadow-panel: 0 18px 54px rgba(36, 37, 40, .095);
  --line-calm: rgba(210, 206, 194, .62);
}

.button,
.icon-button.bordered,
.auto-sync-button,
.today-presence-button { min-height: 40px; border-radius: var(--radius-control); }
.workspace,
.logs-page-panel,
.statistics-panel,
.config-page-panel { border-color: var(--line-calm); border-radius: var(--radius-panel); box-shadow: var(--shadow-card); }
.modal { border-radius: var(--radius-panel); box-shadow: var(--shadow-panel); }
.modal-head,
.modal-foot,
.planner-toolbar,
.logs-page-panel-head,
.statistics-panel-head,
.config-page-panel-head { border-color: var(--line-calm); }
.statistics-table th,
.statistics-table td,
.settings-rule-row,
.role-entry-rule-row { border-color: rgba(220, 217, 207, .52) !important; }
.statistics-table thead th { background: #f2f1ec; }
.logs-empty,
.statistics-empty,
.notice-manager-empty,
.rental-address-empty,
.role-assignment-empty,
.role-employee-empty,
.empty-state-inline,
.config-access-denied { border: 0; border-radius: var(--radius-card); background: #faf9f5; color: var(--muted); box-shadow: inset 0 0 0 1px rgba(220,217,207,.42); }

.global-search-button kbd,
.global-search-field kbd {
  min-width: 38px;
  padding: 3px 6px;
  border: 1px solid var(--line-calm);
  border-radius: 6px;
  background: #f5f3ed;
  color: var(--muted);
  font: 750 9px/1.2 inherit;
  text-align: center;
  box-shadow: inset 0 -1px 0 rgba(36,37,40,.08);
}
.focus-mode-button { min-width: 34px; height: 30px; padding: 0 8px; border: 0; border-left: 1px solid var(--line-calm); background: transparent; color: var(--muted); font-size: 17px; }
.focus-mode-button:hover,
.focus-mode-button.active { background: rgba(97,166,14,.12); color: var(--brand-green); }

.global-search-dialog { width: min(680px, calc(100vw - 28px)); }
.global-search-body { padding: 15px; }
.global-search-field { height: 52px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; padding: 0 13px; border: 1px solid #cfcabe; border-radius: 12px; background: white; box-shadow: 0 5px 16px rgba(36,37,40,.045); }
.global-search-field > span { color: var(--brand-green); font-size: 22px; }
.global-search-field input { width: 100%; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 14px; font-weight: 700; }
.global-search-results { min-height: 250px; max-height: min(480px, 56vh); margin-top: 11px; display: grid; align-content: start; gap: 4px; overflow-y: auto; }
.global-search-results > button { width: 100%; min-height: 58px; padding: 8px 10px; display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; align-items: center; gap: 10px; border: 0; border-radius: 10px; background: transparent; text-align: left; }
.global-search-results > button:hover,
.global-search-results > button:focus-visible { background: #f2f5ed; }
.global-search-results > button > span:nth-child(2) { min-width: 0; }
.global-search-results strong,
.global-search-results small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.global-search-results strong { font-size: 12px; }
.global-search-results small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.global-search-results i { color: var(--brand-green); font-style: normal; font-size: 17px; }
.global-search-kind { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 9px; background: rgba(97,166,14,.12); color: #4d850d; font-size: 9px; font-weight: 900; }
.global-search-empty { min-height: 230px; display: grid; place-items: center; align-content: center; gap: 6px; color: var(--muted); text-align: center; }
.global-search-empty > span { font-size: 30px; color: #a7a397; }
.global-search-empty strong { color: var(--ink); }
.global-search-empty small { max-width: 330px; line-height: 1.5; }
.global-search-foot { padding-top: 10px; padding-bottom: 12px; color: var(--muted); }

.planner-loading { position: absolute; inset: 69px 0 0; z-index: 24; padding: 24px; display: grid; align-content: start; gap: 12px; overflow: hidden; background: rgba(255,254,250,.91); backdrop-filter: blur(2px); }
.planner-loading.hidden { display: none; }
.planner-loading-head,
.planner-loading-row { height: 56px; border-radius: 10px; background: linear-gradient(90deg, #eeece5 20%, #faf9f5 42%, #eeece5 64%); background-size: 300% 100%; animation: planwerk-skeleton 1.25s ease infinite; }
.planner-loading-head { height: 42px; }
.planner-loading-row.short { width: 72%; }
.planner-loading strong { margin-top: 5px; color: var(--muted); font-size: 10px; text-align: center; }
@keyframes planwerk-skeleton { from { background-position: 100% 0; } to { background-position: 0 0; } }

.unsaved-indicator { width: max-content; margin-top: 7px; padding: 4px 8px; display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; background: #fff2db; color: #8b5715; font-size: 8px; font-weight: 850; letter-spacing: .02em; }
.unsaved-indicator i { width: 6px; height: 6px; border-radius: 50%; background: #e89a29; }

.toast { min-width: 280px; max-width: min(440px, calc(100vw - 24px)); padding: 11px 12px; display: flex; align-items: center; gap: 10px; border-radius: 12px; box-shadow: 0 14px 38px rgba(36,37,40,.2); }
.toast-copy { min-width: 0; flex: 1; }
.toast-copy strong,
.toast-copy small { display: block; }
.toast-copy small { margin-top: 3px; line-height: 1.35; }
.toast-action { min-height: 32px; padding: 0 10px; border: 1px solid rgba(255,255,255,.38); border-radius: 8px; background: rgba(255,255,255,.12); color: inherit; font-size: 10px; font-weight: 850; }
.toast-close { width: 28px; height: 28px; display: grid; place-items: center; border: 0; border-radius: 7px; background: transparent; color: inherit; font-size: 17px; opacity: .72; }
.toast-action:hover,
.toast-close:hover { background: rgba(255,255,255,.2); }
.timeline-row.search-highlight { animation: search-row-highlight 2.1s ease both; }
@keyframes search-row-highlight { 0%, 65% { box-shadow: inset 5px 0 0 var(--brand-green), inset 0 0 0 999px rgba(97,166,14,.08); } 100% { box-shadow: none; } }

body.planwerk-focus-mode { overflow: hidden; }
body.planwerk-focus-mode .topbar,
body.planwerk-focus-mode .hero-row,
body.planwerk-focus-mode .sidebar { display: none; }
body.planwerk-focus-mode main { min-height: 100dvh; height: 100dvh; padding: 10px; }
body.planwerk-focus-mode .workspace { height: calc(100dvh - 20px); min-height: 0; grid-template-columns: minmax(0, 1fr); border-radius: 13px; }
body.planwerk-focus-mode .planner { height: 100%; }
body.planwerk-focus-mode .timeline-scroll { height: calc(100dvh - 98px); min-height: 0; overflow-y: auto; }
body.planwerk-focus-mode .planner-toolbar { position: sticky; top: 0; z-index: 28; background: rgba(255,254,250,.96); }

@media (max-width: 1280px) {
  .global-search-button kbd { display: none; }
}
@media (max-width: 760px) {
  .global-search-button { width: 40px; padding: 0; }
  .global-search-foot { display: none; }
}
