  @keyframes cal-spin {
    to { transform: rotate(360deg); }
  }

  /* ====== Glassmorphism utilityk (login dizájnhoz igazítva) ====== */
  .glass-panel {
    position: relative;
    color: #0f172a;
    background-color: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(26px);
    -webkit-backdrop-filter: blur(26px);
    box-shadow:
      0 28px 60px rgba(2, 15, 34, 0.18),
      inset 0 1px 0 rgba(255, 255, 255, 0.35);
    overflow: hidden;
  }
  .glass-panel::before,
  .glass-panel::after {
    content: "";
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,255,255,0.35) 0%, rgba(255,255,255,0.15) 50%, transparent 100%);
    filter: blur(12px);
  }
  .glass-panel::before {
    top: -20px; right: -20px; width: 100px; height: 100px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 100%);
  }
  .glass-panel::after {
    width: 80px; height: 80px; left: 0; top: 0;
    box-shadow: 50px 260px 0 0 rgba(255,255,255,0.08), 240px 240px 0 0 rgba(255,255,255,0.1);
  }
  .glass-card--no-glow::before,
  .glass-card--no-glow::after { display: none !important; }
  .glass-corner-glow {
    display: none !important;
    position: absolute; top: -70px; left: -70px; width: 200px; height: 200px; border-radius: 50%; pointer-events:none; mix-blend-mode: screen;
    background:
      radial-gradient(circle, rgba(255,255,255,0.7) 0%, rgba(255,255,255,0.45) 20%, transparent 40%),
      radial-gradient(circle, rgba(255,255,255,0.28) 0%, rgba(255,255,255,0.14) 40%, rgba(255,255,255,0.06) 75%, transparent 100%);
    filter: blur(18px);
  }
  .glass-sticky {
    position: sticky; left: 0; z-index: 30;
    background: rgba(255,255,255,0.55);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-right: 1px solid rgba(0,0,0,0.06);
  }

  /* Fejléc: letisztult keret (#ebebeb), kék bal szegély / erős árnyék nélkül */
  .calendar-wrapper .calendar-header-outer.glass-panel {
    position: relative;
    box-shadow: none !important;
    border: 1px solid #ebebeb !important;
    background: rgba(248, 250, 252, 0.96) !important;
  }
  .calendar-header-inner {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(0, 0, 0, 0.06);
  }
/* Nap cella link: nincs aláhúzás, szín a cellától (original megjelenés) */
.table-compact .cal-cell-link {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: inherit;
}

.glass-cell {
  border: 1px solid rgba(209,213,219,0.9);
  border-radius: 6px;
  transition: transform .2s ease, filter .2s ease;
  height: 26px !important;
  width: 26px !important;
  font-size: 14px !important;
  font-weight: 700;
  font-style: normal;
  color: #000;
}

.glass-cell:hover {
  transform: translateY(-1px) scale(1.06);
  filter: saturate(1.05);
}



  /* Mai nap: sárga keret csak bal és jobb oldalon (minden felhasználónál) */
  .is-today {
    border-top: 1px solid rgba(209, 213, 219, 0.9) !important;
    border-bottom: 1px solid rgba(209, 213, 219, 0.9) !important;
    border-left: 2px solid #f59e0b !important;
    border-right: 2px solid #f59e0b !important;
    box-shadow: 0 0 6px rgba(245,158,11,0.6) !important;
  }

  /* Bejelentkezett felhasználó saját sora – szürke keret vízszintesen kizárólag a napok cellája körül */
  .row-my-user td:not(.name-col) {
  }
  .row-my-user td:not(.name-col) .glass-cell {
    border-top: 2px solid #475569 !important;
    border-bottom: 2px solid #475569 !important;
    border-left: 1px solid rgba(209, 213, 219, 0.9) !important;
    border-right: 1px solid rgba(209, 213, 219, 0.9) !important;
    box-shadow: 0 0 6px rgba(71, 85, 105, 0.5) !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
  }
  /* Mai nap a saját sorban: sárga keret csak bal és jobb oldalon (felül/alul szürke marad) */
  .row-my-user td:not(.name-col) .glass-cell.is-today {
    border-top: 2px solid #475569 !important;
    border-bottom: 2px solid #475569 !important;
    border-left: 2px solid #f59e0b !important;
    border-right: 2px solid #f59e0b !important;
    box-shadow: 0 0 6px rgba(245, 158, 11, 0.6) !important;
  }
  .pending-approval {
    background-image: repeating-linear-gradient(45deg, rgba(226,232,240,0.9) 0, rgba(226,232,240,0.9) 8px, rgba(255,255,255,0.75) 8px, rgba(255,255,255,0.75) 16px);
  }
  /* Táblázat cellák és fejlécek padding */
  .table-compact th,
  .table-compact td {
    padding: 3px 4px !important;
  }
  /* Név oszlop */
  .table-compact .name-col {
    padding: 3px 6px !important;
    font-size: 14px;
    white-space: nowrap;
  }

  .calendar-wrapper .glass-panel {
    overflow: visible;
  box-shadow:
    0 8px 16px rgba(2, 15, 34, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

  .calendar-scroller { box-shadow: none !important; }
  .calendar-wrapper,
  .calendar-group-block { box-shadow: none !important; }
  .calendar-flex-inner,
  .calendar-flex-inner .glass-panel { box-shadow: none !important; }
  @media (max-width: 640px){
    .calendar-scroller { overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; }
  }
  /* Nyomtató ikon a táblázat fejlécében: csak asztali nézetben */
  @media (max-width: 1023px) {
    .desktop-only-print-icon { display: none !important; }
  }
  @media print {
    .no-print { display: none !important; }
    .glass-panel, .glass-sticky { backdrop-filter: none !important; box-shadow: none !important; }
    .glass-cell { box-shadow: none !important; }
    /* Nyomtatáskor minden csoport expandálva legyen látható */
    .calendar-group-block.group-collapsed .planzee-calendar-unified__body-sleeve {
      grid-template-rows: 1fr !important;
      overflow: visible !important;
    }
    .calendar-group-block.group-collapsed .planzee-calendar-unified__body-sleeve-inner {
      overflow: visible !important;
    }
    .planzee-group-toggle { display: none !important; }
  }

  /* Vízsz. görgetés + sticky név: napcellák alacsonyabb rétegen, hogy a név takarja őket (ne fordítva) */
  .calendar-scroller .table-compact thead th.pro-day-head,
  .calendar-scroller .table-compact tbody td.cal-cell-td {
    position: relative;
    z-index: 0;
  }
  .calendar-scroller .table-compact .cal-cell-link {
    z-index: 0;
  }
  .calendar-scroller .table-compact .glass-cell.pro-day-cell {
    position: relative;
    z-index: 0;
  }

  @media (max-width: 1024px){
    .calendar-scroller { overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; }
    .calendar-scroller .calendar-flex-inner {
      overflow: visible !important;
    }
    /* Fix Név oszlop: a napok görgethetők, a nevek maradnak, a fejléc napokkal együtt gördül */
    .calendar-scroller .glass-sticky.name-col {
      position: sticky !important;
      left: 0 !important;
      z-index: 50;
      min-width: 110px;
      box-shadow: 4px 0 8px -2px rgba(0,0,0,0.08);
      transition: background-color 0.2s ease, backdrop-filter 0.2s ease;
    }
    .calendar-scroller thead .glass-sticky.name-col {
      z-index: 51;
    }
    /* Napok mögött: átlátszatlan, de ugyanaz a szürkés árnyalat mint a glass */
    .calendar-scroller.name-col-scrolled .glass-sticky.name-col {
      background: #EAECF5 !important;
      backdrop-filter: none !important;
      -webkit-backdrop-filter: none !important;
    }
  }

  /* Csoportkártyák közötti távolság a blokkon: így nem esik egybe a törzs box-shadow-ja a réssel
     (a margin átlátszó; a „kékes sáv” az rgba kék árnyék volt a calendar-group-body alatti margóban). */
  .calendar-group-block {
    margin-bottom: 10px;
  }

  /* Összecsukott csoport után következő csoport: kisebb térköz (expand/collapse ugrás elkerülésére) */
  .calendar-group-block.group-collapsed + .calendar-group-block {
    margin-top: 0.25rem !important;
  }
  /* Fejléc margin (régi két-kártya elrendezés); egységes kártyánál a .planzee-calendar-unified felülírja */
  .calendar-group-block .glass-panel.glass-card--no-glow {
    margin-bottom: 0.25rem !important;
  }
  .planzee-pro-card .planzee-calendar-unified .calendar-header-outer.glass-panel.glass-card--no-glow {
    margin-bottom: 0 !important;
  }

  /* Csoport összecsukás: egy kártyában a törzs lenyílik (0fr → 1fr), fejléc mindig látszik */
  .planzee-calendar-unified__body-sleeve {
    display: grid;
    grid-template-rows: 1fr;
    transition: grid-template-rows 0.42s cubic-bezier(0.33, 1, 0.68, 1);
    /* Kinyitva: visible – különben a sticky név a scroller helyett itt „akad meg” */
    overflow: visible;
    /* Flex oszlop gyerek: min-height:auto a rejtett tábla intrinsic magasságát adná → üres „alsó rész” összecsukva */
    min-height: 0;
  }
  .calendar-group-block.group-collapsed .planzee-calendar-unified__body-sleeve {
    grid-template-rows: 0fr;
    overflow: hidden;
  }
  .calendar-group-block.group-expanded .planzee-calendar-unified__body-sleeve {
    grid-template-rows: 1fr;
  }
  .planzee-calendar-unified__body-sleeve-inner {
    min-height: 0;
    overflow: visible;
  }
  @media (prefers-reduced-motion: reduce) {
    .planzee-calendar-unified__body-sleeve {
      transition: none;
    }
    .planzee-calendar-unified__divider {
      transition: none !important;
    }
  }

  /* Naptár újratöltés után: expand állapot localStorage-ból – ne animáljon (szerver első csoport expanded → kliens collapsed) */
  #calendar-container.planzee-suppress-group-animate .planzee-calendar-unified__body-sleeve {
    transition: none !important;
  }
  #calendar-container.planzee-suppress-group-animate .planzee-calendar-unified__divider {
    transition: none !important;
  }
  #calendar-container.planzee-suppress-group-animate .planzee-pro-card.group-collapsed .planzee-calendar-unified,
  #calendar-container.planzee-suppress-group-animate .planzee-pro-card.group-expanded .planzee-calendar-unified {
    transition: none !important;
  }

  /* Plusz/mínusz gomb: expand üzemmódban − látszik, collapse üzemmódban + látszik */
  .calendar-group-block.group-expanded .planzee-group-toggle .icon-expand {
    display: none !important;
  }
  .calendar-group-block.group-expanded .planzee-group-toggle .icon-collapse {
    display: inline !important;
  }
  .calendar-group-block.group-collapsed .planzee-group-toggle .icon-expand {
    display: inline !important;
  }
  .calendar-group-block.group-collapsed .planzee-group-toggle .icon-collapse {
    display: none !important;
  }

  /* ===== Elrendezés – az original calendar_table.php megjelenése (Tailwindtől független) ===== */
  .calendar-wrapper {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
    margin-top: 1.5rem;
  }
  .calendar-scroller {
    overflow-y: hidden;
    max-width: 100%;
  }
  /* Asztali: vízszintesen ne görgető; mobilon a max-width: 1024px media query ad overflow-x: auto-t */
  @media (min-width: 1025px) {
    .calendar-scroller { overflow-x: hidden; }
  }
  .calendar-flex-inner {
    display: flex;
    flex-direction: column;
    width: max-content; /* táblázat szélességével nő, így a scroller vízszintesen görgethető */
    min-width: 0; /* flex gyerek tud zsugorodni a scroller szélességéhez */
    margin-left: auto;
    margin-right: auto;
    overflow: hidden;
    min-height: 80px;
  }
  /* Csoport törzs: /attendance panel – ugyanaz mint .calendar-header-outer */
  .calendar-group-body {
    border-radius: 1rem;
    overflow: visible;
    border: 1px solid #ebebeb;
    background: rgba(248, 250, 252, 0.96);
    box-shadow: none;
    caret-color: transparent; /* inner és outer közötti térben ne villogjon a kurzor */
  }
  .calendar-group-body > .glass-panel {
    border-radius: 1rem;
    margin: 0.25rem; /* ugyanannyi térköz, mint a header outer és inner között (p-1) */
    caret-color: transparent; /* inner és outer közötti térben ne villogjon a kurzor */
    background: rgba(255, 255, 255, 0.98) !important;
    border: 1px solid rgba(226, 232, 240, 0.95) !important;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
  .calendar-group-body > .glass-panel::before,
  .calendar-group-body > .glass-panel::after {
    display: none !important;
  }
  .calendar-group-block.group-collapsed .calendar-group-body > .glass-panel {
    margin: 0 !important;
  }
  .calendar-header-outer {
    border-radius: 1rem;
    padding: 0.25rem;
    margin-bottom: 0.5rem;
    border: 1px solid #ebebeb;
    background: rgba(248, 250, 252, 0.96);
    box-shadow: none;
  }
  .calendar-header-inner {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: space-between;
    align-items: center;
    /* Vezető badge (bal blokk vége) és dátum (jobb blokk): minimum távolság szűk nézetben is */
    gap: max(1px, 0.45rem);
    border-radius: 0.75rem;
    padding: 0.25rem 0.75rem;
    color: #0f172a;
  }
  .calendar-header-inner .cal-header-left {
    display: flex;
    flex-direction: row;
    align-items: center;
    flex: 1 1 auto;
    min-width: 0;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.025em;
    opacity: 0.9;
  }
  .calendar-header-inner .cal-header-right {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
  }
  .calendar-header-inner .cal-header-right .cal-month-year {
    font-size: 0.75rem;
    font-weight: 500;
    opacity: 0.8;
  }
  .planzee-group-toggle {
    width: 1.75rem;
    height: 1.75rem;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    border: 1px solid rgba(37, 99, 235, 0.5);
    background: linear-gradient(145deg, #1e40af 0%, #2563eb 42%, #3b82f6 100%);
    color: #ffffff;
    cursor: pointer;
    box-shadow:
      0 1px 2px rgba(15, 23, 42, 0.1),
      0 2px 10px rgba(37, 99, 235, 0.32);
    transition:
      transform 0.18s ease,
      box-shadow 0.2s ease,
      filter 0.2s ease,
      border-color 0.2s ease,
      background 0.2s ease;
    caret-color: transparent;
    user-select: none;
  }
  /* Összecsukva (+): tiszta kék | Kinyitva (−): meleg narancs */
  .calendar-group-block.group-expanded .planzee-group-toggle {
    border-color: rgba(234, 88, 12, 0.52);
    background: linear-gradient(145deg, #c2410c 0%, #ea580c 40%, #fb923c 100%);
    box-shadow:
      0 1px 2px rgba(15, 23, 42, 0.1),
      0 2px 10px rgba(234, 88, 12, 0.32);
  }
  @media (hover: hover) {
    .calendar-group-block.group-collapsed .planzee-group-toggle:hover {
      color: #ffffff;
      filter: brightness(1.06);
      box-shadow:
        0 2px 4px rgba(15, 23, 42, 0.12),
        0 4px 16px rgba(37, 99, 235, 0.4);
    }
    .calendar-group-block.group-expanded .planzee-group-toggle:hover {
      color: #ffffff;
      filter: brightness(1.06);
      box-shadow:
        0 2px 4px rgba(15, 23, 42, 0.12),
        0 4px 16px rgba(234, 88, 12, 0.42);
    }
  }
  .planzee-group-toggle:active {
    transform: scale(0.96);
  }
  .planzee-group-toggle:focus-visible {
    outline: 2px solid rgba(96, 165, 250, 0.95);
    outline-offset: 2px;
  }
  .calendar-group-block.group-expanded .planzee-group-toggle:focus-visible {
    outline-color: rgba(251, 146, 60, 0.98);
  }
  .planzee-group-toggle .icon-expand,
  .planzee-group-toggle .icon-collapse {
    font-size: 0.95rem;
    line-height: 1;
    font-weight: 800;
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.12);
  }
  .planzee-group-toggle .hidden {
    display: none !important;
  }
  .desktop-only-print-icon {
    /* Ugyanakkora keret, mint a .planzee-group-toggle (+-) */
    width: 1.75rem;
    height: 1.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 0;
    flex-shrink: 0;
  }
  .cal-print-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    padding: 0;
    border: none;
    border-radius: 0.5rem;
    background: linear-gradient(145deg, #0d9488 0%, #0f766e 42%, #047857 100%);
    color: #ffffff;
    cursor: pointer;
    text-decoration: none;
    box-shadow:
      0 1px 2px rgba(15, 23, 42, 0.1),
      0 2px 10px rgba(13, 148, 136, 0.28);
    transition:
      transform 0.18s ease,
      box-shadow 0.2s ease,
      filter 0.2s ease;
  }
  .cal-print-btn:hover {
    color: #ffffff;
    text-decoration: none;
    filter: brightness(1.06);
    box-shadow:
      0 2px 4px rgba(15, 23, 42, 0.12),
      0 4px 16px rgba(13, 148, 136, 0.38);
  }
  @media (hover: hover) {
    .cal-print-btn:hover {
      transform: translateY(-1px);
    }
  }
  .cal-print-btn:focus-visible {
    outline: 2px solid rgba(45, 212, 191, 0.95);
    outline-offset: 2px;
  }
  .planzee-month-modal-btn svg,
  .cal-print-btn svg {
    width: 0.95rem;
    height: 0.95rem;
    flex-shrink: 0;
  }
  @media (max-width: 1023px) {
    .desktop-only-print-icon { display: none !important; }
  }

  /* Nap fejléc: alap háttér világos (original), hétvége/ünnep piros – jobban kiemelve */
  .table-compact thead th:not(.name-col) {
    background-color: #fff;
  }
  .cal-th-red,
  .bg-red-50.text-red-600 {
    background-color: #fee2e2 !important;
    color: #b91c1c;
    font-weight: 600;
    border-left: 1px solid rgba(185, 28, 28, 0.2);
    border-right: 1px solid rgba(185, 28, 28, 0.2);
  }
  .cal-th-normal,
  .text-slate-800 {
    color: #1e293b;
  }
  .bg-red-50 { background-color: #fee2e2; }
  .text-red-600 { color: #b91c1c; }

  /* Dolgozók sorában: hétvége/ünnep – erősebb piros háttér, jól elkülönül */
  .table-compact td.cal-cell-red {
    background-color: #fee2e2;
  }

  /* Táblázat (original: border-collapse) */
  .table-compact {
    font-size: 0.875rem;
    text-align: center;
    border-collapse: collapse;
    min-width: max-content;
    width: 100%;
  }
  .table-compact thead tr,
  .table-compact tbody tr,
  .table-compact th,
  .table-compact td,
  .table-compact .border-0 {
    border: 0 !important;
  }
  .table-compact .rounded-tl-2xl { border-top-left-radius: 1rem; }
  .table-compact .rounded-bl-2xl { border-bottom-left-radius: 1rem; }
  .table-compact .rounded-br-2xl { border-bottom-right-radius: 1rem; }
  .table-compact thead th:last-child { border-top-right-radius: 1rem; }
  .glass-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    margin-right: auto;
    border-radius: 0.375rem;
  }
  .glass-sticky.name-col {
    background: rgba(255, 255, 255, 0.6);
  }

  /* Megjelenő kódok magyarázata */
  .cal-visible-codes {
    margin-top: 1rem;
    margin-bottom: 1.5rem;
    max-width: 48rem;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
  .cal-visible-codes h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.25rem;
  }
  .cal-visible-codes h3 svg {
    width: 1rem;
    height: 1rem;
    color: #6b7280;
    flex-shrink: 0;
  }
  .cal-visible-codes-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  .cal-visible-codes-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.5rem;
    background: #fff;
    border-radius: 0.5rem;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    border: 1px solid #e5e7eb;
  }
  .cal-visible-codes-item .short {
    width: 1.25rem;
    height: 1.25rem;
    border-radius: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.75rem;
    color: #222;
  }
  .cal-visible-codes-item .desc {
    font-size: 0.75rem;
    color: #374151;
  }

  /* Üres állapot */
  .cal-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    align-self: stretch;
    width: 100%;
    margin-top: 2.5rem;
    padding-left: 1rem;
    padding-right: 1rem;
    text-align: center !important;
  }
  .cal-empty-state .cal-empty-state-title {
    width: 100%;
    text-align: center !important;
    font-size: 1.25rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
  }

  /* Lapozó */
  .cal-pagination {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 1rem;
    margin-bottom: 1.5rem;
    margin-top: 0.5rem;
  }
  .cal-pagination-info {
    font-size: 0.875rem;
    color: #4b5563;
    text-align: center;
    margin-bottom: 0.5rem;
  }
  .cal-pagination-info .font-medium { font-weight: 500; }
  .cal-pagination-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }
  .cal-pagination-links a,
  .cal-pagination-links span {
    padding: 0.25rem 0.75rem;
    border-radius: 0.75rem;
    font-size: 0.875rem;
    text-decoration: none;
  }
  .cal-pagination-links a {
    border: 1px solid #d1d5db;
    background: #fff;
    color: inherit;
  }
  .cal-pagination-links a:hover {
    background: #f9fafb;
  }
  .cal-pagination-links .current {
    border: 1px solid #2563eb;
    background: #2563eb;
    color: #fff;
  }
  .cal-pagination-links .disabled {
    border: 1px solid #e5e7eb;
    background: #f3f4f6;
    color: #9ca3af;
    cursor: not-allowed;
  }

  .planzee-weekly-page .calendar-wrapper {
    width: min(var(--planzee-shell-width, 1160px), calc(100% - var(--planzee-shell-padding, 1.5rem)));
    margin-left: auto;
    margin-right: auto;
  }

  /* Kétoszlopos (bal sidebar + jobb naptár) elrendezésben a naptár legyen keskenyebb, középen */
  .planzee-main .calendar-wrapper,
  .planzee-main .cal-pagination,
  .planzee-main .cal-visible-codes {
    width: 800px;
    max-width: 800px;
    margin-left: 0;
    margin-right: 0;
    box-sizing: border-box;
  }

  /* Ne középre üljön a táblázat a bal oszlopon belül,
     így nem marad nagy üres sáv a jobb oldalon.
     Csak #calendar-container: a havi modál is .planzee-main alatt van, oda nem szabad inline-grid / max-content
     szabályt alkalmazni (összeakad a modál width:100% + fixed táblájával). */
  #calendar-container .calendar-flex-inner {
    /* A fejléc hosszú szövege ne növelje a blokk szélességét a táblánál: a rács szélességét a törzs (tábla) adja,
       a fejléc ugyanarra a sávra esik (width:0; min-width:100%). */
    display: inline-grid;
    grid-template-columns: auto;
    width: auto;
    margin-left: 0;
    margin-right: 0;
  }
  #calendar-container .calendar-flex-inner > .planzee-calendar-unified {
    grid-column: 1;
    width: max-content;
    min-width: 0;
    box-sizing: border-box;
  }

  .planzee-main .calendar-scroller {
    overflow-x: auto !important;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
  }
  /* Vízszintes görgetésnél a név oszlop maradjon; a flex-inner overflow:hidden levágná a sticky-t */
  .planzee-main .calendar-scroller .calendar-flex-inner {
    overflow: visible !important;
  }
  .planzee-main .calendar-scroller .glass-sticky.name-col {
    position: -webkit-sticky !important;
    position: sticky !important;
    left: 0 !important;
    z-index: 50;
    min-width: 7.5rem;
    max-width: 11rem;
    box-shadow: 4px 0 10px -4px rgba(15, 23, 42, 0.18);
    background: rgba(255, 255, 255, 0.98) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
  .planzee-main .calendar-scroller thead .glass-sticky.name-col {
    z-index: 52;
  }
  .planzee-main .calendar-scroller.name-col-scrolled .glass-sticky.name-col {
    background: #eaecf5 !important;
  }

  /* A scroller és a sticky között ne legyen rejtett overflow (téma / egyéb felülírás ellen) */
  .planzee-main .calendar-scroller .planzee-calendar-unified,
  .planzee-main .calendar-scroller .planzee-calendar-unified__body-sleeve-inner,
  .planzee-main .calendar-scroller .calendar-group-body,
  .planzee-main .calendar-scroller .planzee-calendar-inner-card {
    overflow: visible !important;
  }
  .planzee-main .calendar-group-block.group-expanded .calendar-scroller .planzee-calendar-unified__body-sleeve {
    overflow: visible !important;
  }
  /* Hover transform új réteget hozhat, a név oszlop „elcsúszik” vizuálisan */
  @media (hover: hover) and (pointer: fine) {
    .planzee-main .calendar-scroller .planzee-pro-card .glass-cell.pro-day-cell:hover {
      transform: none !important;
      filter: none !important;
    }
  }

  .planzee-weekly-page .table-compact th:not(.name-col),
  .planzee-weekly-page .table-compact td:not(.name-col) {
    min-width: 44px;
  }

  .planzee-weekly-page .calendar-header-inner .cal-header-right .cal-month-year {
    font-weight: 700;
    font-size: 0.8rem;
  }

  /* ===== Pro weekly redesign overrides ===== */
  /* Egy kártya: csoportfejléc + halvány elválasztó + naptár; összecsukáskor a törzs együtt lenyílik */
  .planzee-pro-card .planzee-calendar-unified {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    border: 1px solid #ebebeb;
    border-radius: 16px;
    /* Teljes visible: a visible+hidden tengely páros sok böngészőben auto scrollportot csinál → tönkreteszi a sticky-t */
    overflow: visible;
    background: #ffffff;
    box-sizing: border-box;
    min-width: 0;
  }
  .planzee-pro-card .planzee-calendar-unified .calendar-header-outer.glass-panel.pro-header-shell {
    border: 0 !important;
    box-shadow: none !important;
    /* overflow: visible a kártyán: a lekerekítés a fejlécre + alsó blokkra osztva */
    border-radius: 16px 16px 0 0 !important;
    margin-bottom: 0 !important;
    background: linear-gradient(180deg, #ffffff 0%, rgba(248, 250, 252, 0.92) 100%) !important;
  }
  .calendar-group-block.group-collapsed .planzee-calendar-unified .calendar-header-outer.glass-panel.pro-header-shell {
    border-radius: 16px !important;
  }
  .planzee-pro-card .planzee-calendar-unified .calendar-group-body {
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    background: transparent !important;
  }
  .planzee-pro-card .planzee-calendar-unified .calendar-group-body > .glass-panel {
    border-radius: 0 0 16px 16px !important;
    margin: 0 !important;
    padding: 10px 10px 12px !important;
    overflow-x: visible !important;
    overflow-y: visible !important;
  }
  .planzee-calendar-unified__divider {
    flex-shrink: 0;
    height: 1px;
    margin: 0 0.85rem;
    border: 0;
    background: linear-gradient(
      90deg,
      transparent 0%,
      rgba(148, 163, 184, 0.12) 12%,
      rgba(148, 163, 184, 0.28) 50%,
      rgba(148, 163, 184, 0.12) 88%,
      transparent 100%
    );
    opacity: 0;
    transition: opacity 0.32s ease 0.06s, height 0.38s cubic-bezier(0.33, 1, 0.68, 1), margin 0.38s ease;
    pointer-events: none;
  }
  .calendar-group-block.group-expanded .planzee-calendar-unified__divider {
    opacity: 1;
  }
  /* Becsukva: ugyanaz a halvány „szőrös” vonal, mint kinyitva — kis lélegzővel a fejléc alatt */
  .calendar-group-block.group-collapsed .planzee-calendar-unified__divider {
    opacity: 1;
    height: 1px;
    margin: 0.4rem 1rem;
    background: linear-gradient(
      90deg,
      transparent 0%,
      rgba(148, 163, 184, 0.1) 14%,
      rgba(148, 163, 184, 0.24) 50%,
      rgba(148, 163, 184, 0.1) 86%,
      transparent 100%
    );
    transition: opacity 0.22s ease, margin 0.32s ease;
  }

  /* Összecsukva: enyhe háttér + belső árnyék; a vékony elválasztó a divideren van */
  .planzee-pro-card.group-collapsed .planzee-calendar-unified {
    background: linear-gradient(180deg, #ffffff 0%, #fafbfc 55%, #f1f5f4 100%);
    box-shadow: inset 0 -12px 18px -10px rgba(148, 163, 184, 0.14);
    transition: background 0.35s ease, box-shadow 0.35s ease;
  }
  .planzee-pro-card.group-expanded .planzee-calendar-unified {
    background: #ffffff;
    box-shadow: none;
    transition: background 0.32s ease, box-shadow 0.32s ease;
  }
  @media (prefers-reduced-motion: reduce) {
    .planzee-pro-card.group-collapsed .planzee-calendar-unified,
    .planzee-pro-card.group-expanded .planzee-calendar-unified {
      transition: none;
    }
  }

  .planzee-pro-card .pro-header-shell {
    border: 1px solid #ebebeb !important;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.96)) !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06) !important;
  }
  .planzee-pro-card .pro-header-inner {
    border: 0 !important;
    background: transparent !important;
    min-height: 25px;
    min-width: 0;
  }
  .planzee-pro-card .calendar-header-inner .cal-header-left {
    overflow: hidden;
    min-width: 0;
  }
  .planzee-pro-card .pro-group-title {
    flex: 1 1 0%;
    display: block;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 700;
    color: #0f172a;
    letter-spacing: 0.01em;
  }
  .planzee-pro-card .pro-group-leader {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
    margin-left: .35rem;
    padding: .18rem .55rem;
    border-radius: 9999px;
    background: #eef2ff;
    color: #3730a3;
    font-size: .72rem;
    font-weight: 600;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .planzee-pro-card .calendar-group-body {
    border: 1px solid #ebebeb;
    border-radius: 16px;
    background: rgba(248, 250, 252, 0.96);
    box-shadow: none;
  }
  .planzee-pro-card .calendar-group-body > .glass-panel {
    background: #fff !important;
    border: 0 !important;
    box-shadow: none !important;
    margin: 0 !important;
    padding: 10px !important;
  }
  .planzee-pro-card .calendar-group-body > .glass-panel::before,
  .planzee-pro-card .calendar-group-body > .glass-panel::after {
    display: none !important;
  }
  .planzee-pro-card .planzee-calendar-inner-card {
    border: 1px solid #ebebeb;
    border-radius: 14px;
    background: #ffffff;
    width: 100%;
    box-sizing: border-box;
    padding: 8px;
  }
  .planzee-pro-card .planzee-calendar-unified .planzee-calendar-inner-card {
    border-radius: 0 0 12px 12px;
  }

  .planzee-pro-card .table-compact {
    border-collapse: separate;
    border-spacing: 0;
    min-width: 620px;
    width: max-content !important;
  }
  .planzee-pro-card .table-compact th,
  .planzee-pro-card .table-compact td {
    border-bottom: 1px solid #edf2f7 !important;
  }
  .planzee-pro-card .table-compact tbody tr:last-child td {
    border-bottom: 0 !important;
  }

  .planzee-pro-card .name-col {
    width: 210px;
    min-width: 210px;
    max-width: 210px;
    text-align: left;
    font-size: 0.9rem;
    font-weight: 600;
    color: #1e293b;
    background: #fff !important;
  }
  .planzee-pro-card .pro-user-name {
    display: inline-block;
    max-width: 190px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    vertical-align: middle;
  }

  .planzee-pro-card .pro-day-head {
    width: 64px;
    min-width: 64px;
    text-align: center;
    background: transparent !important;
    color: #334155;
    padding: 8px 5px !important;
    vertical-align: middle;
  }
  .planzee-pro-card .pro-day-head__dow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: .66rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: #475569;
    margin-right: 0.3rem;
    line-height: 1;
    font-weight: 700;
  }
  .planzee-pro-card .pro-day-head__num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2rem;
    height: 1.65rem;
    padding: 0 0.55rem;
    border-radius: 9999px;
    border: 1px solid #d6dfeb;
    background: linear-gradient(180deg, #ffffff, #f8fbff);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
    font-size: .8rem;
    font-weight: 800;
    color: #0f172a;
  }

  .planzee-pro-card .table-compact td.cal-cell-red {
    background: #ffe5e5;
  }
  .planzee-pro-card .pro-day-cell {
    min-width: 2rem !important;
    height: 1.65rem !important;
    padding: 0 0.55rem !important;
    border-radius: 9999px !important;
    border: 1px solid #d6dfeb;
    color: #0f172a;
    font-size: .8rem !important;
    font-weight: 800 !important;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08), inset 0 1px 0 rgba(255,255,255,0.6);
  }
  .planzee-pro-card .cal-cell-link:hover .pro-day-cell {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.14);
  }
  .planzee-pro-card .pro-day-cell.is-today {
    border-top: 1px solid #d6dfeb !important;
    border-bottom: 1px solid #d6dfeb !important;
    border-left: 2px solid #f59e0b !important;
    border-right: 2px solid #f59e0b !important;
    box-shadow: 0 0 6px rgba(245, 158, 11, 0.55) !important;
  }
  /* Planzee: keskeny nézetben a naptár ne legyen fix 800px – vízszintes görgetés a .calendar-scroller-en */
  @media (max-width: 1023px) {
    .planzee-main .calendar-wrapper,
    .planzee-main .cal-pagination,
    .planzee-main .cal-visible-codes {
      width: 100% !important;
      max-width: 100% !important;
      margin-left: auto;
      margin-right: auto;
    }
    .planzee-main .cal-visible-codes h3 {
      justify-content: center;
      text-align: center;
    }
    .planzee-main .cal-visible-codes-list {
      justify-content: center;
    }
    .planzee-main .cal-visible-codes-item {
      text-align: center;
    }
    .planzee-main .calendar-scroller {
      overflow-x: auto !important;
      overflow-y: hidden;
      -webkit-overflow-scrolling: touch;
    }
    .planzee-main .calendar-flex-inner {
      margin-left: auto !important;
      margin-right: auto !important;
    }
  }

  @media (max-width: 1024px) {
    .planzee-pro-card .pro-group-leader { display: none !important; }
    .planzee-pro-card .name-col { width: 150px; min-width: 150px; max-width: 150px; }
    .planzee-pro-card .pro-user-name { max-width: 135px; }
    .planzee-pro-card .pro-day-head { width: 56px; min-width: 56px; }
    .planzee-pro-card .pro-day-head__dow { margin-right: 0.2rem; font-size: .62rem; }
    .planzee-pro-card .pro-day-head__num { min-width: 1.8rem; height: 1.5rem; font-size: .74rem; padding: 0 0.45rem; }
    .planzee-pro-card .pro-day-cell { min-width: 1.8rem !important; height: 1.5rem !important; padding: 0 0.45rem !important; border-radius: 9999px !important; font-size: .74rem !important; }
  }

  /* Asztali Planzee: széles kártya + ellipsis fejléc + tábla kitölti a sort (mobilon: flex-inner max-content → vízsz. görgetés) */
  @media (min-width: 1024px) {
    .planzee-main #calendar-container .calendar-flex-inner {
      width: 100%;
      min-width: 0;
      box-sizing: border-box;
    }
    .planzee-main #calendar-container .calendar-flex-inner > .planzee-calendar-unified {
      width: 100%;
      max-width: 100%;
      min-width: 0;
    }
    .planzee-main #calendar-container .planzee-pro-card .table-compact {
      width: 100% !important;
      min-width: 0 !important;
      table-layout: fixed;
    }
    .planzee-main #calendar-container .planzee-pro-card .pro-day-head,
    .planzee-main #calendar-container .planzee-pro-card .table-compact td.cal-cell-td:not(.name-col) {
      width: auto !important;
      min-width: 0 !important;
    }
  }

  .planzee-weekly-page .cal-pagination,
  .planzee-weekly-page .cal-visible-codes {
    width: min(var(--planzee-shell-width, 1160px), calc(100% - var(--planzee-shell-padding, 1.5rem)));
    margin-left: auto;
    margin-right: auto;
    box-sizing: border-box;
  }

  /* Teljes hónap modal megnyitása (naptár fejléc) – minden nézetben */
  .planzee-month-modal-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    padding: 0;
    margin-right: 0.15rem;
    border: none;
    border-radius: 0.5rem;
    background: linear-gradient(145deg, #818cf8 0%, #6366f1 38%, #7c3aed 100%);
    color: #ffffff;
    cursor: pointer;
    flex-shrink: 0;
    box-shadow:
      0 1px 2px rgba(15, 23, 42, 0.1),
      0 2px 10px rgba(99, 102, 241, 0.32);
    transition:
      transform 0.18s ease,
      box-shadow 0.2s ease,
      filter 0.2s ease;
  }
  .planzee-month-modal-btn:hover {
    color: #ffffff;
    filter: brightness(1.05);
    box-shadow:
      0 2px 4px rgba(15, 23, 42, 0.12),
      0 4px 16px rgba(99, 102, 241, 0.42);
  }
  @media (hover: hover) {
    .planzee-month-modal-btn:hover {
      transform: translateY(-1px);
    }
  }
  .planzee-month-modal-btn:focus-visible {
    outline: 2px solid rgba(165, 180, 252, 0.95);
    outline-offset: 2px;
  }

  @media (prefers-reduced-motion: reduce) {
    .planzee-month-modal-btn:hover,
    .cal-print-btn:hover {
      transform: none;
    }
  }

  /* Teljes hónap modal (egy mérettel nagyobb alap: padding, dialog, típusok) */
  .planzee-month-modal {
    position: fixed;
    inset: 0;
    z-index: 10260;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    box-sizing: border-box;
  }
  body.has-navbar .planzee-month-modal {
    top: calc(var(--nav-height, 56px) + 10px);
    padding-top: 0.5rem;
  }
  .planzee-month-modal[hidden] {
    display: none !important;
  }
  .planzee-month-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(4px);
  }
  .planzee-month-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(1240px, calc(100vw - 2rem));
    max-width: 100%;
    min-width: 0;
    max-height: min(92vh, calc(100dvh - 2rem));
    display: flex;
    flex-direction: column;
    border-radius: 1.35rem;
    border: 1px solid #ebebeb;
    background: rgba(248, 250, 252, 0.98);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 12px 28px rgba(15, 23, 42, 0.08);
    overflow: hidden;
    box-sizing: border-box;
  }
  body.has-navbar .planzee-month-modal__dialog {
    max-height: calc(100dvh - var(--nav-height, 56px) - 28px);
  }
  .planzee-month-modal__header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    grid-template-areas: "title rail close";
    align-items: center;
    gap: 0.65rem 0.85rem;
    padding: 0.85rem 1rem 0.95rem;
    border-bottom: 1px solid rgba(148, 163, 184, 0.25);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.96));
  }
  .planzee-month-modal__title {
    grid-area: title;
    justify-self: start;
    margin: 0;
    font-size: 1.125rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: 0.02em;
    line-height: 1.2;
  }
  .planzee-month-modal__month-rail {
    grid-area: rail;
    justify-self: center;
    display: inline-flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.55rem;
    border-radius: 0.85rem;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(148, 163, 184, 0.4);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
    max-width: 100%;
    min-width: 0;
  }
  .planzee-month-modal__month-nav {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    padding: 0;
    border: 1px solid rgba(148, 163, 184, 0.45);
    border-radius: 0.55rem;
    background: rgba(255, 255, 255, 0.95);
    color: #475569;
    font-size: 0.85rem;
    line-height: 1;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
    flex-shrink: 0;
  }
  .planzee-month-modal__month-nav:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
    color: #0f172a;
  }
  .planzee-month-modal__month-label {
    font-size: 0.9375rem;
    font-weight: 700;
    color: #1e293b;
    letter-spacing: 0.02em;
    white-space: nowrap;
    padding: 0 0.25rem;
    min-width: 0;
    text-align: center;
  }
  .planzee-month-modal__close {
    grid-area: close;
    justify-self: end;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border: none;
    border-radius: 0.75rem;
    background: rgba(241, 245, 249, 0.95);
    color: #475569;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
  }
  .planzee-month-modal__close:hover {
    background: #e2e8f0;
    color: #0f172a;
  }
  @media (max-width: 520px) {
    .planzee-month-modal__header {
      grid-template-columns: 1fr auto;
      grid-template-areas:
        "title close"
        "rail rail";
      row-gap: 0.55rem;
      padding: 0.75rem 0.85rem 0.85rem;
    }
    .planzee-month-modal__title {
      font-size: 1.05rem;
    }
    .planzee-month-modal__month-rail {
      justify-self: stretch;
      justify-content: center;
    }
  }
  .planzee-month-modal__body {
    flex: 1;
    min-height: 0;
    min-width: 0;
    width: 100%;
    overflow: auto;
    padding: 0.95rem 1.05rem 1.2rem;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
  }
  .planzee-month-modal__body .calendar-wrapper {
    margin-top: 0 !important;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  .planzee-month-modal__body .calendar-header-outer {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  .planzee-month-modal__body .calendar-header-outer.glass-panel {
    overflow: visible !important;
  }
  /* Asztali modál: fix tábla, befér a párbeszédablakba – nincs vízszintes görgetés */
  .planzee-month-modal__body .calendar-scroller {
    overflow-x: hidden !important;
    overflow-y: visible;
    max-width: 100%;
    width: 100%;
    -webkit-overflow-scrolling: touch;
  }
  .planzee-month-modal__body .calendar-flex-inner {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0;
    margin-left: 0 !important;
    margin-right: 0 !important;
    overflow: visible !important;
  }
  .planzee-month-modal__body .calendar-flex-inner > .planzee-calendar-unified {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }
  .planzee-month-modal__body .calendar-group-block {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  .planzee-month-modal__body .planzee-pro-card {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  .planzee-month-modal__body .planzee-pro-card .calendar-group-body > .glass-panel {
    padding: 9px 11px !important;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: visible !important;
  }
  .planzee-month-modal__body .planzee-pro-card .table-compact {
    table-layout: fixed;
    width: 100% !important;
    min-width: 0 !important;
  }
  .planzee-month-modal__body .planzee-pro-card .table-compact th:not(.name-col),
  .planzee-month-modal__body .planzee-pro-card .table-compact td:not(.name-col) {
    min-width: 0 !important;
    max-width: none !important;
    width: auto;
  }
  .planzee-month-modal__body .calendar-scroller .glass-sticky.name-col {
    position: relative !important;
    left: auto !important;
    width: 14%;
    min-width: 0 !important;
    max-width: none;
    box-shadow: none !important;
    /* fontos: ne legyen z-index !important – mobil @media sticky + magas z-index felülírja */
    z-index: auto;
  }
  .planzee-month-modal__body .planzee-pro-card .name-col {
    width: 14%;
    min-width: 0 !important;
    max-width: none;
    padding: 0.3rem 0.45rem !important;
    font-size: 0.85rem !important;
    line-height: 1.2;
  }
  .planzee-month-modal__body .planzee-pro-card .pro-user-name {
    max-width: 100%;
    font-size: 0.81rem;
    font-weight: 600;
  }
  .planzee-month-modal__body .planzee-pro-card .pro-day-head {
    min-width: 0 !important;
    width: auto !important;
    max-width: none !important;
    padding: 0.2rem 0.08rem !important;
    vertical-align: middle;
    text-align: center;
    line-height: 1.08;
  }
  .planzee-month-modal__body .planzee-pro-card .pro-day-head__dow {
    display: block;
    margin-right: 0;
    font-size: 0.67rem;
    letter-spacing: 0.03em;
    line-height: 1;
  }
  .planzee-month-modal__body .planzee-pro-card .pro-day-head__num {
    min-width: 0;
    max-width: 100%;
    height: auto;
    min-height: 1.15rem;
    padding: 0.08rem 0.1rem;
    font-size: 0.73rem;
    border-width: 1px;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.06);
  }
  .planzee-month-modal__body .planzee-pro-card .cal-cell-td {
    min-width: 0;
  }
  .planzee-month-modal__body .planzee-pro-card .cal-cell-td:not(.name-col) .cal-cell-link {
    width: 100%;
    max-width: 100%;
    aspect-ratio: 1 / 1;
    box-sizing: border-box;
    align-items: stretch !important;
  }
  .planzee-month-modal__body .planzee-pro-card .pro-day-cell {
    min-width: 0 !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    max-width: 100%;
    box-sizing: border-box;
    padding: 0.1rem 0.06rem !important;
    font-size: 0.71rem !important;
    font-weight: 700 !important;
    border-radius: 0.32rem !important;
    border-width: 1px;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .planzee-month-modal__body .planzee-pro-card .cal-cell-link:hover .pro-day-cell {
    transform: none;
  }
  .planzee-month-modal__body .planzee-pro-card .pro-day-cell.is-today {
    border-left-width: 1px !important;
    border-right-width: 1px !important;
  }
  .planzee-month-modal__body .cal-visible-codes {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    margin-top: 0.65rem !important;
    padding: 0.45rem 0.35rem;
    font-size: 0.78rem;
  }
  .planzee-month-modal__body .cal-visible-codes h3 {
    font-size: 0.75rem !important;
  }
  .planzee-month-modal__body .pro-header-inner {
    min-height: 0 !important;
    padding: 0.35rem 0.6rem !important;
  }
  .planzee-month-modal__body .planzee-pro-card .pro-group-title {
    font-size: 0.95rem;
  }
  .planzee-month-modal__body .planzee-pro-card .pro-group-leader {
    font-size: 0.82rem;
    padding: 0.22rem 0.65rem;
  }
  .planzee-month-modal__body .planzee-group-toggle {
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 0.5rem;
  }
  .planzee-month-modal__body .planzee-group-toggle .icon-expand,
  .planzee-month-modal__body .planzee-group-toggle .icon-collapse {
    font-size: 0.95rem;
  }
  .planzee-month-modal__body .cal-print-btn svg {
    width: 0.95rem;
    height: 0.95rem;
  }
  .planzee-month-modal__body .cal-visible-codes-item .short {
    font-size: 0.75rem;
    padding: 0.12rem 0.35rem;
  }
  .planzee-month-modal__body .cal-visible-codes-item .desc {
    font-size: 0.73rem;
  }
  .planzee-month-modal__body .cal-month-year {
    font-size: 0.78rem !important;
  }

  /* Mobil: teljes szélességű dialógus; vízsz. görgetés + sticky név; naposzlop = desktop modál szélesség / napok száma (--planzee-modal-day-cols a táblán) */
  @media (max-width: 1023px) {
    .planzee-month-modal {
      align-items: center;
      justify-content: flex-start;
      padding-left: 0.65rem;
      padding-right: 0.65rem;
      padding-bottom: max(0.75rem, env(safe-area-inset-bottom, 0px));
    }
    body.has-navbar .planzee-month-modal {
      padding-top: 0.35rem;
    }
    .planzee-month-modal__dialog {
      width: 100%;
      max-width: 100%;
      min-width: 0;
    }
    .planzee-month-modal__header {
      flex-shrink: 0;
    }
    .planzee-month-modal__body {
      overflow-x: hidden;
      overflow-y: auto;
      overscroll-behavior-y: contain;
      -webkit-overflow-scrolling: touch;
      padding: 0.65rem 0.65rem 1rem;
    }
    .planzee-month-modal__body .cal-visible-codes {
      width: 100%;
      max-width: 100%;
      min-width: 0;
      box-sizing: border-box;
    }
    .planzee-month-modal__body .calendar-wrapper {
      width: 100% !important;
      max-width: 100% !important;
      min-width: 0 !important;
      box-sizing: border-box;
    }
    .planzee-month-modal__body .calendar-scroller {
      overflow-x: auto !important;
      overflow-y: visible;
      width: 100%;
      max-width: 100%;
      min-width: 0;
      -webkit-overflow-scrolling: touch;
      overscroll-behavior-x: contain;
      isolation: isolate;
    }
    .planzee-month-modal__body .calendar-flex-inner {
      width: max-content !important;
      min-width: 100% !important;
      max-width: none !important;
      margin-left: 0 !important;
      margin-right: 0 !important;
      overflow: visible !important;
      box-sizing: border-box;
    }
    .planzee-month-modal__body .calendar-group-block,
    .planzee-month-modal__body .planzee-pro-card {
      width: 100% !important;
      max-width: 100% !important;
      min-width: 0;
      box-sizing: border-box;
    }
    .planzee-month-modal__body .planzee-pro-card .calendar-group-body > .glass-panel {
      width: 100% !important;
      max-width: 100% !important;
      min-width: 0;
      box-sizing: border-box;
    }
    /* Virtuális táblaszélesség ≈ nagy modál (min(1240px, vw) − padding); 0.86 ≈ naposzlopok aránya a 14% név mellett */
    .planzee-month-modal__body .planzee-pro-card .table-compact {
      --planzee-modal-day-cols: 7;
      --planzee-modal-cell: calc((min(1160px, 72.5rem) * 0.86) / var(--planzee-modal-day-cols));
      table-layout: auto;
      width: max-content !important;
      min-width: 100% !important;
      border-collapse: separate !important;
      border-spacing: 0 !important;
    }
    .planzee-month-modal__body .planzee-pro-card .table-compact th:not(.name-col),
    .planzee-month-modal__body .planzee-pro-card .table-compact td:not(.name-col) {
      width: var(--planzee-modal-cell) !important;
      min-width: var(--planzee-modal-cell) !important;
      max-width: var(--planzee-modal-cell) !important;
      box-sizing: border-box;
      position: relative !important;
      z-index: 0 !important;
    }
    .planzee-month-modal__body .calendar-scroller .glass-sticky.name-col {
      position: sticky !important;
      left: 0 !important;
      z-index: 100 !important;
      min-width: 7.5rem !important;
      max-width: 11rem;
      width: auto !important;
      box-shadow: 4px 0 10px -4px rgba(15, 23, 42, 0.18);
      background: rgba(255, 255, 255, 0.98) !important;
      backdrop-filter: none !important;
      -webkit-backdrop-filter: none !important;
    }
    .planzee-month-modal__body .calendar-scroller thead .glass-sticky.name-col {
      z-index: 101 !important;
    }
    .planzee-month-modal__body .planzee-pro-card .name-col {
      min-width: 7rem !important;
      max-width: 10rem;
      width: auto !important;
    }
    .planzee-month-modal__body .planzee-pro-card .pro-day-head {
      padding: 0.25rem 0.12rem !important;
    }
    .planzee-month-modal__body .planzee-pro-card .cal-cell-td:not(.name-col) {
      padding: 0.2rem !important;
      vertical-align: middle;
    }
    .planzee-month-modal__body .planzee-pro-card .cal-cell-td:not(.name-col) .cal-cell-link {
      display: flex;
      align-items: stretch;
      justify-content: stretch;
      min-width: 0;
      min-height: 0;
    }
    .planzee-month-modal__body .planzee-pro-card .pro-day-cell {
      display: flex !important;
      align-items: center !important;
      justify-content: center !important;
      max-height: 100%;
      flex: 1 1 auto;
      padding: 0.1rem !important;
      font-size: 0.68rem !important;
      border-radius: 0.3rem !important;
    }
    .planzee-month-modal__body .planzee-pro-card .glass-cell.pro-day-cell {
      width: 100% !important;
      height: 100% !important;
      min-width: 0 !important;
      min-height: 0 !important;
      max-width: 100% !important;
      max-height: 100% !important;
      z-index: 0 !important;
    }
    /* Hover transform új réteget hozhat létre, ami ráül a név oszlopra */
    .planzee-month-modal__body .planzee-pro-card .glass-cell:hover {
      transform: none !important;
      filter: none !important;
    }
  }

  .planzee-month-modal__loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 2.85rem 1.15rem;
    font-size: 1rem;
    color: #64748b;
  }
  .planzee-month-modal__spinner {
    width: 1.4rem;
    height: 1.4rem;
    border-radius: 9999px;
    border: 2px solid #cbd5e1;
    border-top-color: transparent;
    animation: planzee-month-spin 0.75s linear infinite;
  }
  @keyframes planzee-month-spin {
    to { transform: rotate(360deg); }
  }

/* Lebegő tooltip (/planzee – ugyanaz a vizuális nyelv, mint a jelenléti admin / dashboard) */
.planzee-floating-tooltip {
  position: fixed;
  left: 0;
  top: 0;
  width: max-content;
  max-width: min(18rem, calc(100vw - 20px));
  box-sizing: border-box;
  background: rgba(51, 65, 85, 0.96);
  color: #f8fafc;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 0.65rem;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.22);
  padding: 0.5rem 0.65rem;
  font-size: 0.72rem;
  line-height: 1.35;
  font-weight: 500;
  text-align: left;
  white-space: pre-line;
  word-break: break-word;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(3px);
  transition: opacity 0.14s ease, transform 0.14s ease, visibility 0.14s ease;
  z-index: 12000;
}

.planzee-floating-tooltip.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

@media (hover: hover) and (pointer: fine) {
  .planzee-weekly-page [data-planzee-tooltip] {
    cursor: help;
  }
}
