.calendar-workspace { color:var(--label); }
.calendar-page-heading,.calendar-template-heading { display:flex; align-items:center; justify-content:space-between; gap:18px; margin-bottom:17px; }
.calendar-page-heading h1 { margin:0; font-size:28px; }
.calendar-template-heading h2 { margin:0; font-size:20px; }
.calendar-tabs { display:flex; gap:24px; margin-bottom:18px; border-bottom:1px solid var(--line); overflow:auto; }
.calendar-tabs button { padding:12px 0; border:0; border-bottom:2px solid transparent; background:none; color:var(--secondary-label); font:inherit; font-size:13px; font-weight:600; white-space:nowrap; cursor:pointer; }
.calendar-tabs button[aria-selected=true] { border-bottom-color:var(--blue); color:var(--blue); }
.calendar-loading,.calendar-empty { padding:44px 18px; color:var(--secondary-label); font-size:13px; text-align:center; }
.calendar-alerts { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; margin-bottom:18px; }
.calendar-alerts[hidden],.calendar-legend[hidden] { display:none; }
.calendar-alert { min-width:0; display:flex; align-items:center; gap:10px; padding:12px; border:1px solid var(--line); border-radius:9px; background:white; color:var(--label); font:inherit; text-align:left; cursor:pointer; transition:transform 150ms var(--ease),box-shadow 150ms var(--ease),border-color 150ms var(--ease); }
.calendar-alert:not(:disabled):hover { transform:translateY(-1px); box-shadow:var(--shadow-small); }
.calendar-alert:disabled { cursor:default; opacity:.62; }
.calendar-alert[aria-pressed=true] { outline:2px solid currentColor; outline-offset:2px; }
.calendar-alert strong { flex:0 0 auto; min-width:27px; font-size:22px; line-height:1; }
.calendar-alert span { display:grid; min-width:0; gap:3px; }
.calendar-alert b { font-size:11px; line-height:1.3; }
.calendar-alert small { overflow:hidden; color:var(--secondary-label); font-size:9px; line-height:1.35; text-overflow:ellipsis; white-space:nowrap; }
.calendar-alert-today { border-color:#b7d6f6; color:#075bb5; background:#f6fbff; }
.calendar-alert-overdue { border-color:#f0c0c6; color:#b42335; background:#fff8f8; }
.calendar-alert-documents { border-color:#ebd18c; color:#876000; background:#fffdf6; }
.calendar-alert-unassigned { border-color:#d5d4dc; color:#5c5c66; background:#fbfbfc; }
.calendar-alert-overload { border-color:#dec8f3; color:#703b9b; background:#fcf9ff; }
.calendar-toolbar { display:flex; align-items:center; justify-content:space-between; gap:16px; margin-bottom:14px; }
.calendar-month-navigation,.calendar-filters { display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.calendar-month-navigation h2 { min-width:190px; margin:0 0 0 5px; font-size:18px; text-transform:capitalize; }
.calendar-icon-button { display:grid; place-items:center; width:36px; height:36px; padding:0; border:1px solid var(--line); border-radius:7px; background:white; color:var(--label); font:inherit; font-size:22px; line-height:1; cursor:pointer; }
.calendar-icon-button:hover { background:var(--fill-hover); }
.calendar-filters select,.calendar-template-filters select,.calendar-template-filters input { min-height:36px; max-width:190px; padding:7px 9px; border:1px solid var(--line); border-radius:7px; background:white; color:var(--label); font:inherit; font-size:11px; }
.calendar-filter-panel,.calendar-template-filter-panel { position:relative; }
.calendar-filter-panel > summary,.calendar-template-filter-panel > summary { min-height:36px; display:flex; align-items:center; justify-content:center; gap:7px; padding:7px 12px; border:1px solid var(--line); border-radius:7px; background:#fff; color:var(--label); font-size:11px; font-weight:650; list-style:none; cursor:pointer; }
.calendar-filter-panel > summary::-webkit-details-marker,.calendar-template-filter-panel > summary::-webkit-details-marker { display:none; }
.calendar-filter-panel > summary::before,.calendar-template-filter-panel > summary::before { content:'≡'; color:var(--secondary-label); font-size:14px; line-height:1; }
.calendar-filter-panel[open] > summary,.calendar-template-filter-panel[open] > summary { border-color:#91bce9; background:#f4f9ff; color:#075bb5; }
.calendar-filter-panel .calendar-filters { position:absolute; z-index:12; top:calc(100% + 7px); right:0; width:min(600px,calc(100vw - 48px)); display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:9px; padding:12px; border:1px solid var(--line); border-radius:10px; background:#fff; box-shadow:0 14px 34px #16233a24; }
.calendar-filter-panel .calendar-filters select { width:100%; max-width:none; }
.calendar-filter-panel .text-button { justify-self:end; grid-column:1/-1; }
.calendar-active-alert { display:flex; align-items:center; justify-content:space-between; gap:12px; margin:0 0 12px; padding:9px 11px; border:1px solid #bfd8f7; border-radius:7px; background:#f2f8ff; color:#075bb5; font-size:11px; }
.calendar-active-alert button { padding:0; border:0; background:none; color:inherit; font:inherit; font-size:11px; font-weight:650; cursor:pointer; text-decoration:underline; }
.calendar-legend { display:flex; flex-wrap:wrap; gap:9px 14px; margin:0 0 13px; }
.calendar-legend-item { display:inline-flex; align-items:center; gap:5px; color:var(--secondary-label); font-size:10px; }
.calendar-legend-item i { width:7px; height:7px; border-radius:50%; background:#777; }
.calendar-legend-item.category-tax i,.calendar-event.category-tax { --category:#bb4a00; --category-soft:#fff0e5; }
.calendar-legend-item.category-payroll i,.calendar-event.category-payroll { --category:#7b4b00; --category-soft:#fff3d4; }
.calendar-legend-item.category-accounting i,.calendar-event.category-accounting { --category:#006c63; --category-soft:#e4f7f3; }
.calendar-legend-item.category-guide i,.calendar-event.category-guide { --category:#1769aa; --category-soft:#e9f3ff; }
.calendar-legend-item.category-declaration i,.calendar-event.category-declaration { --category:#713d9c; --category-soft:#f3eaff; }
.calendar-legend-item.category-recurring i,.calendar-event.category-recurring { --category:#58606e; --category-soft:#eff1f4; }
.calendar-legend-item.category-other i,.calendar-event.category-other { --category:#55555b; --category-soft:#f2f2f4; }
.calendar-legend-item.category-tax i,.calendar-legend-item.category-payroll i,.calendar-legend-item.category-accounting i,.calendar-legend-item.category-guide i,.calendar-legend-item.category-declaration i,.calendar-legend-item.category-recurring i,.calendar-legend-item.category-other i { background:var(--category); }
.calendar-legend-item.holiday i { background:#c14d68; }
.calendar-layout { display:grid; grid-template-columns:minmax(0,1fr) 290px; gap:14px; align-items:start; }
.calendar-grid-wrap,.calendar-agenda { border:1px solid #dedfe4; border-radius:12px; background:white; box-shadow:0 4px 16px #17233d0a; }
.calendar-grid { display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); overflow:hidden; border-radius:12px; }
.calendar-weekday { padding:10px 8px; border-bottom:1px solid var(--line); background:#fafafa; color:var(--secondary-label); font-size:10px; font-weight:650; text-align:center; }
.calendar-day { position:relative; min-width:0; min-height:118px; display:flex; flex-direction:column; align-items:stretch; gap:4px; padding:8px; border:0; border-right:1px solid #ededf0; border-bottom:1px solid #ededf0; background:white; color:var(--label); text-align:left; cursor:pointer; overflow:hidden; transition:background 120ms ease,box-shadow 120ms ease; }
.calendar-day:nth-child(7n) { border-right:0; }
.calendar-day:hover { background:#fbfdff; }
.calendar-day.outside { background:#fafafa; color:#a5a5aa; }
.calendar-day.weekend:not(.outside) { background:#fcfcfd; }
.calendar-day.today .calendar-day-head > span { display:grid; place-items:center; width:23px; height:23px; border-radius:50%; background:var(--blue); color:white; }
.calendar-day.selected { z-index:1; background:#f5f9ff; box-shadow:inset 0 0 0 2px var(--blue); }
.calendar-day.marked { background:linear-gradient(135deg,#fff7f9 0 7px,white 7px); }
.calendar-day-head { display:flex; align-items:center; justify-content:space-between; min-height:23px; color:inherit; font-size:11px; font-weight:600; }
.calendar-day-mark { display:grid; place-items:center; width:16px; height:16px; border-radius:4px; background:#f7e5e9; color:#a13752; font-style:normal; font-size:8px; }
.calendar-event { width:100%; min-width:0; overflow:hidden; padding:4px 5px; border:0; border-radius:4px; background:var(--category-soft); color:var(--category); font:inherit; font-size:9px; font-weight:600; line-height:1.35; text-align:left; text-overflow:ellipsis; white-space:nowrap; cursor:pointer; }
.calendar-event:hover { filter:brightness(.97); }
.calendar-event.planned { border:1px dashed color-mix(in srgb,var(--category) 35%,white); background:transparent; }
.calendar-more-events { overflow:hidden; color:var(--blue); font-size:9px; font-weight:600; text-overflow:ellipsis; white-space:nowrap; }
.calendar-agenda { position:sticky; top:78px; overflow:hidden; }
.calendar-agenda-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; padding:16px; border-bottom:1px solid var(--line); }
.calendar-agenda-heading span { display:block; margin-bottom:4px; color:var(--secondary-label); font-size:9px; font-weight:650; text-transform:uppercase; }
.calendar-agenda-heading h2 { margin:0; font-size:15px; text-transform:capitalize; }
.calendar-agenda-heading .calendar-icon-button { width:31px; height:31px; font-size:18px; }
.calendar-agenda-list { display:grid; gap:8px; min-height:220px; max-height:530px; padding:12px; overflow:auto; }
.calendar-agenda-empty { margin:auto 0; color:var(--secondary-label); font-size:12px; line-height:1.55; text-align:center; }
.calendar-agenda-item,.calendar-agenda-special { width:100%; display:grid; gap:5px; padding:11px; border:1px solid var(--line); border-left:3px solid var(--category,#999); border-radius:7px; background:white; color:var(--label); text-align:left; }
.calendar-agenda-item { cursor:pointer; font:inherit; }
.calendar-agenda-item:hover { background:#fafcff; border-color:#c5d7ea; }
.calendar-agenda-item-top { display:flex; align-items:center; justify-content:space-between; gap:8px; }
.calendar-agenda-item b,.calendar-agenda-item > span { overflow:hidden; font-size:11px; line-height:1.35; text-overflow:ellipsis; white-space:nowrap; }
.calendar-agenda-item em { flex:0 0 auto; padding:3px 5px; border-radius:4px; background:var(--category-soft); color:var(--category); font-size:8px; font-style:normal; font-weight:650; }
.calendar-agenda-item small { overflow:hidden; color:var(--secondary-label); font-size:9px; line-height:1.4; text-overflow:ellipsis; white-space:nowrap; }
.calendar-agenda-special { grid-template-columns:minmax(0,1fr) auto; border-left-color:#c14d68; background:#fffafb; }
.calendar-agenda-special.non_working { border-left-color:#8b6e2c; background:#fffdf6; }
.calendar-agenda-special div { display:grid; gap:4px; }
.calendar-agenda-special strong { font-size:11px; }
.calendar-agenda-special span,.calendar-agenda-special p { margin:0; color:var(--secondary-label); font-size:9px; line-height:1.4; }
.calendar-remove-day { align-self:start; width:24px; height:24px; padding:0; border:0; border-radius:5px; background:transparent; color:#9b5264; font-size:16px; cursor:pointer; }
.calendar-remove-day:hover { background:#fae6ea; }
.calendar-agenda > .full { margin:0 12px 12px; width:calc(100% - 24px); min-height:36px; font-size:11px; }
.calendar-template-filter-panel { margin-bottom:15px; }
.calendar-template-filter-panel > summary { width:max-content; margin-left:auto; }
.calendar-template-filters { display:flex; gap:10px; flex-wrap:wrap; margin-top:8px; padding:12px; border:1px solid var(--line); border-radius:10px; background:#fff; }
.calendar-template-filters input { flex:1 1 230px; max-width:none; }
.calendar-template-list { display:grid; grid-template-columns:repeat(auto-fill,minmax(270px,1fr)); gap:12px; margin-top:18px; }
.calendar-template-card { min-width:0; display:flex; flex-direction:column; justify-content:space-between; gap:18px; padding:16px; border:1px solid var(--line); border-top:3px solid var(--category,#777); border-radius:9px; background:white; }
.calendar-template-copy { min-width:0; }
.calendar-template-badges { display:flex; gap:6px; flex-wrap:wrap; margin-bottom:10px; }
.calendar-category-pill,.calendar-regime-pill { display:inline-block; padding:4px 6px; border-radius:4px; font-size:9px; font-weight:650; }
.calendar-category-pill { color:var(--category); background:var(--category-soft); }
.calendar-regime-pill { color:#56565e; background:#f0f0f2; }
.calendar-template-card h3 { margin:0 0 6px; font-size:14px; }
.calendar-template-card p { margin:0 0 10px; color:#4b4b51; font-size:12px; line-height:1.5; }
.calendar-template-card small { display:block; color:var(--secondary-label); font-size:10px; line-height:1.45; }
.calendar-template-actions { display:flex; align-items:center; justify-content:space-between; gap:10px; }
.calendar-template-actions .primary-button { min-height:34px; padding:7px 10px; font-size:11px; }
.calendar-capacity { display:flex; align-items:center; gap:14px; margin-top:22px; padding:12px 14px; border:1px solid #d7e1ee; border-radius:9px; background:#f7fbff; }
.calendar-capacity > div { margin-right:auto; }
.calendar-capacity strong { display:block; font-size:12px; }
.calendar-capacity .help-tip { width:19px; height:19px; font-size:10px; }
.calendar-capacity label { display:flex; align-items:center; gap:7px; color:#4b4b51; font-size:11px; }
.calendar-capacity input { width:58px; min-height:35px; padding:7px; border:1px solid var(--line); border-radius:6px; font:inherit; text-align:center; }
.calendar-dialog { width:min(640px,calc(100% - 28px)); max-height:90dvh; padding:0; overflow:hidden; border:1px solid var(--line); border-radius:14px; background:white; color:var(--label); box-shadow:var(--shadow-large); }
.calendar-dialog::backdrop { background:#17171d60; backdrop-filter:blur(3px); }
.calendar-dialog form { display:flex; flex-direction:column; max-height:calc(90dvh - 2px); }
.calendar-dialog header { display:flex; align-items:flex-start; justify-content:space-between; gap:15px; padding:19px 22px; border-bottom:1px solid var(--line); }
.calendar-dialog header span { display:block; margin-bottom:4px; color:var(--blue); font-size:9px; font-weight:700; letter-spacing:.04em; }
.calendar-dialog h2 { margin:0; font-size:19px; }
.calendar-dialog header button { display:grid; place-items:center; width:31px; height:31px; padding:0; border:1px solid var(--line); border-radius:7px; background:white; color:var(--secondary-label); font-size:18px; cursor:pointer; }
.calendar-dialog-body { display:grid; gap:16px; padding:22px; overflow:auto; }
.calendar-dialog-body label { display:grid; gap:7px; font-size:11px; font-weight:600; }
.calendar-dialog-body input,.calendar-dialog-body select,.calendar-dialog-body textarea { width:100%; min-width:0; min-height:40px; padding:9px 10px; border:1px solid var(--line); border-radius:7px; background:white; color:var(--label); font:inherit; font-size:12px; }
.calendar-dialog-body textarea { min-height:78px; resize:vertical; }
.calendar-dialog-fields { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; }
.calendar-dialog footer { display:flex; align-items:center; justify-content:flex-end; gap:10px; padding:15px 22px; border-top:1px solid var(--line); }
.calendar-dialog footer > div { margin-right:auto; }
.calendar-delete-template { color:#b42335; }
@media (max-width:1120px) { .calendar-layout { grid-template-columns:1fr; } .calendar-agenda { position:static; } .calendar-agenda-list { max-height:none; min-height:120px; } }
@media (max-width:820px) { .calendar-alerts { grid-template-columns:repeat(2,minmax(0,1fr)); } .calendar-toolbar { align-items:stretch; flex-direction:column; } .calendar-filter-panel { align-self:flex-end; } .calendar-filter-panel .calendar-filters { position:static; width:100%; margin-top:7px; } .calendar-day { min-height:96px; padding:6px; } .calendar-event { padding:3px 4px; font-size:8px; } .calendar-legend { display:none; } }
@media (max-width:620px) { .calendar-page-heading,.calendar-template-heading { align-items:stretch; flex-direction:column; } .calendar-page-heading > .primary-button,.calendar-template-heading > .primary-button { width:100%; } .calendar-month-navigation h2 { order:-1; flex-basis:100%; margin:0; } .calendar-grid { min-width:610px; } .calendar-grid-wrap { overflow:auto; } .calendar-alerts { grid-template-columns:1fr; } .calendar-alert small { white-space:normal; } .calendar-dialog-fields { grid-template-columns:1fr; } .calendar-capacity { align-items:stretch; flex-direction:column; } .calendar-capacity label { justify-content:space-between; } .calendar-dialog footer { flex-wrap:wrap; } .calendar-dialog footer > div { flex-basis:100%; margin:0; } }
