a.navbar-brand {
  white-space: normal;
  text-align: center;
  word-break: break-all;
}

a {
  color: #0366d6;
}

.btn-primary {
  color: #fff;
  background-color: #1b6ec2;
  border-color: #1861ac;
}

.nav-pills .nav-link.active, .nav-pills .show > .nav-link {
  color: #fff;
  background-color: #1b6ec2;
  border-color: #1861ac;
}

/* Sticky footer styles
-------------------------------------------------- */
html {
  font-size: 14px;
  /* Modál nyitásakor ne tűnjön el a görgetősáv helye → ne ugráljon a szöveg/törés (Bootstrap body overflow) */
  scrollbar-gutter: stable;
  position: relative;
  min-height: 100%;
}
@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.border-top {
  border-top: 1px solid #e5e5e5;
}
.border-bottom {
  border-bottom: 1px solid #e5e5e5;
}

.box-shadow {
  box-shadow: 0 .25rem .75rem rgba(0, 0, 0, .05);
}

button.accept-policy {
  font-size: 1rem;
  line-height: inherit;
}

body:not(.login-page):not(.register-page) {
    background: radial-gradient(ellipse at center, #ffffff 50%, #e1e3f7 100%);
    background-repeat: no-repeat;
    background-attachment: fixed;
    background-size: 100% 100%;
}

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

.d-flex.flex-column.min-vh-100 {
    min-height: 100vh;
}

main.flex-fill {
    flex: 1 0 auto;
}

.footer {
    line-height: 60px;
    flex-shrink: 0;
}

/*.footer {
  position: absolute;
  bottom: 0;
  width: 100%;
  white-space: nowrap;
  line-height: 60px;
}*/

.card-metric {
    background-color: #ffffff;
    border-radius: 0.5rem;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    border-left: 4px solid;
}

.border-metric-primary {
    border-color: #2C3E50;
}

.border-metric-warning {
    border-color: #E67E22;
}

.border-metric-success {
    border-color: #27AE60;
}

.metric-number {
    font-size: 2.5rem;
    font-weight: 600;
    color: #2C3E50;
}

.metric-label {
    font-size: 0.9rem;
    text-transform: uppercase;
    color: #7F8C8D;
}

.bg-light {
    background-color: #f8f9fa !important;
}

.card {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease-in-out;
}

.card:hover {
    /*transform: translateY(-3px);*/
    transform: none;
}

.form-floating .toggle-password {
    height: 2.4rem;
    line-height: 1;
    z-index: 2;
    padding: 0;
}

.form-floating .form-control {
    padding-right: 2.75rem;
}

.text-danger.small {
    font-size: 0.85rem;
}

html.login-page,
body.login-page {
    height: 100%;
    margin: 0;
    overflow: hidden;
    background-color: #f8f9fa;
}

/* Normál oldalakon az űrlapmezők minden sarka lekerekített (a Layout bejelentkezési input[type="text"] szabálya csak a login/register oldalon legyen érvényes) */
body:not(.login-page):not(.register-page) input.form-control,
body:not(.login-page):not(.register-page) textarea.form-control,
body:not(.login-page):not(.register-page) select.form-control,
body:not(.login-page):not(.register-page) .form-select {
    border-radius: 0.375rem !important;
}

.list-group-item {
    border: none;
    padding: 1rem 1.25rem;
    transition: background-color 0.2s ease;
}

.list-group-item:hover {
    background-color: #f2f4f6;
}

.badge {
    font-size: 0.875rem;
    padding: 0.4em 0.6em;
    border-radius: 0.5rem;
}
/*
.card-header {
    font-weight: 600;
    font-size: 1.1rem;
    border-bottom: 1px solid #dee2e6;
    background-color: #ffffff;
}*/

button#clearClientSearch,
button#clearPositionSearch {
    padding: 0 0.5rem;
    line-height: 1;
}

.Client-filter-group .btn,
.position-filter-group .btn {
    height: 38px;
    font-size: 0.95rem;
}

.clear-filter-btn {
    padding: 0 0.6rem;
    font-size: 1.2rem;
    line-height: 1;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.clear-filter-btn {
    padding: 0 0.5rem;
    font-size: 1.2rem;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/*Calendar*/
/* Alap naptár doboz */
#calendar {
    background-color: #f8f9fa;
    padding: 16px;
    border-radius: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    font-family: "Segoe UI", "Helvetica Neue", sans-serif;
}

/* Címsor */
/*.fc-toolbar-title {
    font-size: 1.6rem;
    font-weight: 600;
    color: #212529;
}*/

/* Gombok */
/*.fc .fc-button {
    background-color: #0d6efd;
    border: none;
    padding: 0.4rem 0.75rem;
    font-size: 0.9rem;
    font-weight: 450;
    border-radius: 0.3rem;
}

.fc .fc-button:hover,
.fc .fc-button:focus {
    background-color: #0b5ed7;
    outline: none;
    box-shadow: none;
}*/

/* Esemény megjelenés */
/*.fc-event {
    border: none;
    border-radius: 0.5rem;
    padding: 6px 8px;
    font-size: 0.9rem;
    font-weight: 400;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: transform 0.05s;
    background-color: inherit;
    color: inherit;
}

.fc-event:hover {
    transform: scale(1.03);
}

.fc-event .fc-event-title {
    font-weight: 500 !important;
    font-size: 0.9rem;
    color: #fff; 
}*/

/* Napcellák */
/*.fc-daygrid-day-frame {
    padding: 3px;
}

.fc-day-today {
    background-color: #e9f5ff !important;
}
.fc-daygrid-event-dot {
    display: none !important;
}*/

.event-item {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #dee2e6;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.event-time {
    font-weight: 600;
    color: #0d6efd;
    min-width: 60px;
}

.event-title {
    font-weight: 500;
    color: #212529;
    word-break: break-word;
}

/*Calendar*/
.custom-dropdown-wrapper {
    position: relative;
}

.custom-dropdown-button {
    height: 100%;
    padding: 0.375rem 0.75rem;
    font-size: 1rem;
    line-height: 1.5;
    border: 1px solid #ced4da;
    border-radius: 0.375rem;
    background-color: #fff;
    width: 100%;
    text-align: left;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #212529;
}

    .custom-dropdown-button::after {
        content: "";
        border-top: 0.45em solid;
        border-right: 0.4em solid transparent;
        border-left: 0.4em solid transparent;
        margin-left: auto;
    }

.custom-dropdown-menu {
    width: 100%;
    max-height: 250px;
    overflow-y: auto;
    border: 1px solid #ced4da;
    border-radius: 0.375rem;
    margin-top: 0.25rem;
    padding: 0.5rem;
    background-color: #fff;
    box-shadow: 0 .25rem .75rem rgba(0,0,0,.05);
    z-index: 1000;
}
table td.actions {
    padding-right: 1.4rem;
    white-space: nowrap;
}
table td.actions .btn-sm {
    font-size: 1rem;
    border-radius: 0.35rem;
}

.table-container {
    background: #fff;
    border-radius: 1rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
    padding: 2rem;
    margin-bottom: 2rem;
}

.table thead th {
    background-color: #f1f5f9;
    color: #1f2937;
    font-weight: 600;
    border-bottom: 2px solid #e2e8f0;
}

.table tbody td {
    vertical-align: middle;
    border-top: 1px solid #e5e7eb;
}

.table tr:hover {
    background-color: #f8fafc;
}

.table th, .table td {
    padding: 0.75rem 1rem;
}
.navbar-pro {
    background: linear-gradient(to right, #ffffff, #f2f5fb);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    border-bottom: 1px solid #dee2e6;
    padding: 0.75rem 1.5rem;
    z-index: 1050;
    backdrop-filter: blur(6px);
}

    .navbar-pro .navbar-brand {
        font-weight: 700;
        font-size: 1.3rem;
        color: #0d6efd !important;
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }

    .navbar-pro .nav-link {
        font-weight: 500;
        font-size: 1rem;
        color: #333;
        display: flex;
        align-items: center;
        gap: 0.4rem;
        padding: 0.5rem 1rem;
        transition: all 0.2s ease;
    }

        .navbar-pro .nav-link:hover,
        .navbar-pro .nav-link.active {
            color: #1b6ec2 !important;
            background-color: #f8f9fa;
            border-radius: 0.375rem;
        }

    .navbar-pro .nav-separator {
        display: none;
    }

    .navbar-pro .nav-group-menu .dropdown-item.active {
        background-color: rgba(13, 110, 253, 0.1);
        color: #1b6ec2;
    }
    .navbar-pro .btn-outline-danger.btn-sm {
        font-size: 0.875rem;
        padding: 0.375rem 0.75rem;
        border-radius: 0.375rem;
    }
.mt-navbar {
    margin-top: 70px; /* vagy pontosan amennyi a navbar magassága */
}

.btn-premium-add {
    background: linear-gradient(135deg, #0d6efd, #3b82f6);
    color: white;
    border: none;
    padding: 0.6rem 1.2rem;
    font-weight: 600;
    border-radius: 0.75rem;
    box-shadow: 0 6px 16px rgba(13, 110, 253, 0.2);
    transition: all 0.2s ease-in-out;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

    .btn-premium-add:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 20px rgba(13, 110, 253, 0.2);
        text-decoration: none;
        color: white;
    }

.btn-premium-save {
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    color: white;
    border: none;
    padding: 0.45rem 1rem;
    font-weight: 600;
    border-radius: 0.5rem;
    font-size: 0.95rem;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
    transition: background-color 0.2s ease-in-out, transform 0.2s ease-in-out, color 0.2s ease-in-out;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 0.4rem;
}

    .btn-premium-save:hover {
        transform: translateY(-1px);
        box-shadow: 0 2px 6px rgba(15, 23, 42, 0.1);
        text-decoration: none;
        color: white;
    }

    .btn.btn-premium-save:focus,
    .btn.btn-premium-save:focus-visible,
    .btn.btn-premium-save:active {
        outline: none !important;
        box-shadow: none !important;
        color: white;
    }

.btn-premium-danger {
    background: linear-gradient(135deg, #dc4f35, #e74c3c);
    color: white;
    border: none;
    padding: 0.4rem 0.9rem;
    font-weight: 600;
    border-radius: 0.5rem;
    font-size: 0.95rem;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
    transition: all 0.2s ease-in-out;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    text-decoration: none;
}

    .btn-premium-danger:hover {
        transform: translateY(-1px);
        box-shadow: 0 6px 16px rgba(220, 53, 69, 0.4);
        text-decoration: none;
        color: white;
    }

/* Feladat szerkesztő – státusz kártyák */
.task-status-cards .row {
    align-items: stretch;
}

.task-status-cards .col {
    display: flex;
}

.task-status-card {
    width: 100%;
    height: 100%;
    min-height: 4.6rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    text-align: left;
    padding: 0.65rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 0.7rem;
    background: #fff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

    .task-status-card:hover:not(.is-active) {
        box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
    }

.task-status-card__icon {
    flex-shrink: 0;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.task-status-card__text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.1rem;
    min-width: 0;
    flex: 1;
}

.task-status-card__title {
    font-weight: 600;
    font-size: 0.84rem;
    line-height: 1.2;
}

.task-status-card__hint {
    font-size: 0.75rem;
    line-height: 1.25;
    color: #64748b;
    font-weight: 400;
}

/* Kész – zöld */
.task-status-card--done { background: #ecfdf3; }
.task-status-card--done .task-status-card__icon { background: #22c55e; color: #fff; }
.task-status-card--done .task-status-card__title { color: #15803d; }
.task-status-card--done.is-active {
    border-color: #16a34a;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.28);
}

/* Folyamatban – sárga */
.task-status-card--progress { background: #fefce8; }
.task-status-card--progress .task-status-card__icon {
    background: #fef3c7;
    color: #ca8a04;
}
.task-status-card--progress .task-status-card__title { color: #a16207; }
.task-status-card--progress.is-active {
    border-color: #ca8a04;
    box-shadow: 0 0 0 2px rgba(234, 179, 8, 0.35);
}

/* Várakozik – narancs */
.task-status-card--waiting { background: #fff7ed; }
.task-status-card--waiting .task-status-card__icon { background: #f97316; color: #fff; }
.task-status-card--waiting .task-status-card__title { color: #c2410c; }
.task-status-card--waiting.is-active {
    border-color: #ea580c;
    box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.3);
}

/* Nyitott – kék */
.task-status-card--open { background: #eff6ff; }
.task-status-card--open .task-status-card__icon {
    background: #dbeafe;
    color: #2563eb;
}
.task-status-card--open .task-status-card__title { color: #1d4ed8; }
.task-status-card--open.is-active {
    border-color: #2563eb;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3);
}

@media (max-width: 575.98px) {
    .task-status-card {
        min-height: auto;
        padding: 0.75rem 0.85rem;
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }
}

.btn-premium-secondary-success {
    background: #f1f3f5;
    color: #198754;
    border: none;
    padding: 0.4rem 0.9rem;
    font-weight: 600;
    border-radius: 0.5rem;
    font-size: 0.95rem;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease-in-out;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    text-decoration: none;
}

    .btn-premium-secondary-success:hover:not(:disabled) {
        background: #e9ecef;
        transform: translateY(-1px);
        color: #146c43;
        text-decoration: none;
    }

    .btn-premium-secondary-success:disabled {
        opacity: 0.65;
        cursor: not-allowed;
    }

.btn-premium-secondary {
    background: #ebeced;
    color: #495057;
    border: none;
    padding: 0.4rem 0.9rem;
    font-weight: 600;
    border-radius: 0.5rem;
    font-size: 0.95rem;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease-in-out;
    justify-content: center;
    text-align: center;
    align-items: center;
    gap: 0.4rem;
    text-decoration: none;
}

    .btn-premium-secondary:hover {
        background: #e9ecef;
        transform: translateY(-1px);
        color: #343a40;
        text-decoration: none;
    }

.page-title {
    color: #2563eb;
    font-weight: 700;
    font-size: 2rem;
}

#modalDimmer.show {
    display: block !important;
    background-color: rgba(0, 0, 0, 0.4); /* ugyanaz a vizuális hatás, de fix */
    z-index: 1040;
}
.swal-btn {
    margin: 0 .25rem !important;
    border-radius: .7rem !important;
    font-weight: 600 !important;
}

@media (max-width: 991.98px) {
    body {
        background: #fefefe !important;
    }

    .metric-number {
        font-size: 1.8rem;
    }

    .metric-label {
        font-size: 0.75rem;
    }

    .card-header,
    .list-group-item {
        padding: 0.75rem 1rem;
    }

    table.mobile-responsive thead {
        display: none;
    }

    table.mobile-responsive tbody tr {
        display: block;
        margin-bottom: 1rem;
        border: 1px solid #dee2e6;
        border-radius: 0.5rem;
        padding: 0.5rem;
    }

    table.mobile-responsive tbody td {
        display: block;
        width: 100%;
        text-align: left;
        border: none;
        padding: 0.25rem 0;
    }

    td.text-end {
        text-align: left !important;
    }

    .contact-card .card-body > .d-flex {
        gap: 0.5rem;
    }

    .contact-card .form-check-input.contact-checkbox { 
        transform: scale(1.3);
        margin-top: 1px;
    }

    .contact-card .form-check-label {
        margin-left: 5px;
    }

    .contact-card .toggle-btn {
        font-size: 1.2rem;
        margin-left: 1rem;
    }

    .contact-card .toggle-content {
        font-size: 0.95rem;
    }

    #select-all-mobile.form-check-input {
        transform: scale(1.3);
        margin-top: 1px;
    }

    #calendar {
        height: 600px;
    }

    input[type="datetime-local"] {
        width: 100%;
        min-width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }


    .container.mt-3 {
        margin-top: 1rem !important;
    }

    .business-header {
        flex-direction: column;
        align-items: start !important;
        gap: 0.75rem;
    }

    .business-header h1 {
        font-size: 1.5rem;
    }

    .business-header .btn {
        width: 100%;
    }

    #calendarTitle {
        min-width: 120px;
        flex: 1;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .btn-premium-add {
        width: 100%;
        justify-content: center;
        margin-top: 1rem;
        font-size: 1.1rem;
        padding: 0.8rem 1rem;
    }

        .btn-premium-add i {
            font-size: 1.3rem;
        }

}
/* Desktop: Mégse bal, Mentés jobb – bombabiztos */
.footer-actions {
    display: flex;
    align-items: center;
    width: 100%;
}

    .footer-actions .btn-premium-save {
        margin-left: auto; /* EZ tolja jobbra */
    }

/* ha véletlen flex:1 lenne valahol desktopon, ezt lenullázzuk */
@media (min-width: 769px) {
    .footer-actions > .btn {
        flex: 0 0 auto;
    }
}

/* Mobil: marad 50-50 */
@media (max-width: 768px) {
    .footer-actions {
        gap: .75rem;
    }

        .footer-actions > .btn {
            flex: 1 1 0;
        }

        .footer-actions .btn-premium-save {
            margin-left: 0; /* mobilon ne tolja el */
        }
}

.footer-actions .btn-premium-save {
    margin-left: auto !important;
}
/* Navbar: hosszú név ne tolja ki a kijelentkezést */
.navbar-pro .nav-userbar {
    flex-wrap: nowrap;
}

.navbar-pro .nav-user {
    min-width: 0; /* EZ kell az ellipsishez flex-ben */
    max-width: 360px; /* állítható */
}

.navbar-pro .nav-user-name,
.navbar-pro .nav-user-role {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.navbar-pro .nav-logout-btn {
    flex-shrink: 0; /* gomb maradjon látható */
    white-space: nowrap;
}
/* desktopon (amikor még nem hamburger) a userbar max. legyen kisebb */
@media (min-width: 1200px) {
    .navbar-pro .nav-user {
        max-width: 240px;
    }
}

.validation-summary-valid {
    display: none;
}

/* iOS Safari input zoom fix: a mezők betűmérete legyen >= 16px */
@media (max-width: 991.98px) {
    input,
    select,
    textarea,
    .form-control,
    .form-select,
    .custom-dropdown-button {
        font-size: 16px !important;
    }
}

/* Beállítások / Számlázási beállítások modál: közepes szélesség, viewport magasság, görgethető tartalom, Mentés mindig látható */
#genericModal.modal-settings-view .modal-dialog {
    max-width: min(820px, 92vw);
    max-height: calc(100vh - 2rem);
    margin: 1rem auto;
}
#genericModal.modal-settings-view .modal-content {
    max-height: calc(100vh - 2rem);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#genericModal.modal-settings-view .modal-body {
    flex: 1 1 auto;
    overflow-y: auto;
    min-height: 0;
}
#genericModal.modal-settings-view .modal-footer {
    flex-shrink: 0;
}

/* Mobilon: maradjon esztétikus "kártya" és közben a footer mindig elérhető */
@media (max-width: 991.98px) {
    #genericModal.modal-settings-view .modal-dialog {
        max-width: min(820px, 96vw);
        margin: .5rem auto;
        max-height: calc(100dvh - 1rem);
        height: calc(100dvh - 1rem);
    }

    #genericModal.modal-settings-view .modal-content {
        max-height: calc(100dvh - 1rem);
        height: calc(100dvh - 1rem);
        border-radius: .75rem;
    }

    #genericModal.modal-settings-view .modal-body {
        padding-bottom: calc(1rem + env(safe-area-inset-bottom));
    }

    #genericModal.modal-settings-view .modal-footer {
        padding-bottom: calc(.75rem + env(safe-area-inset-bottom));
    }
}

/* Projekt létrehozás: ténylegesen széles modal, kisebb görgetési kényszer */
#genericModal.modal-project-create-view .modal-dialog {
    max-width: min(1320px, 96vw);
}

/* Intake létrehozás: széles modal + sticky footer */
#genericModal.modal-intake-create-view .modal-dialog {
    max-width: min(1320px, 96vw);
}

/*
 * BS4 CSS: .modal z-index 1050, .modal-backdrop 1040 — a második backdrop a hátsó modál ABLAKA alatt marad,
 * ezért „nem szürkül” a genericModal, ha a nestedModal is nyitva (pl. Intakes/Create → új ügyfél).
 * Ilyenkor JS ráteszi a .cegem-modal-behind-nested osztályt; ez vizuálisan ugyanazt adja, mint egy extra réteg.
 */
#genericModal.modal.show.cegem-modal-behind-nested .modal-dialog {
    position: relative;
}

#genericModal.modal.show.cegem-modal-behind-nested .modal-dialog::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 6;
    background: rgba(15, 23, 42, 0.32);
    border-radius: 0.5rem;
    pointer-events: none;
}

/* Modál tartalom csere animáció (ismétlődő mentés hatókör, törlés vissza, stb.) */
.modal-content.cegem-modal-swap-out,
form.cegem-task-popup-dialog.cegem-modal-swap-out {
    opacity: 0;
    transform: translateX(12px);
    transition: opacity 0.18s ease, transform 0.18s ease;
    pointer-events: none;
}

@keyframes cegemModalSwapIn {
    from {
        opacity: 0;
        transform: translateX(-12px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.modal-content.cegem-modal-swap-in,
form.cegem-task-popup-dialog.cegem-modal-swap-in {
    animation: cegemModalSwapIn 0.22s ease forwards;
}

.cegem-ghost-task-form-host {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.modal-content.cegem-modal-swap-loading,
form.cegem-task-popup-dialog.cegem-modal-swap-loading {
    position: relative;
    pointer-events: none;
    min-height: 7rem;
}

.modal-content.cegem-modal-swap-loading::after,
form.cegem-task-popup-dialog.cegem-modal-swap-loading::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 20;
    border-radius: inherit;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(2px);
}

.modal-content.cegem-modal-swap-loading::before,
form.cegem-task-popup-dialog.cegem-modal-swap-loading::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 21;
    width: 2rem;
    height: 2rem;
    margin: -1rem 0 0 -1rem;
    border: 3px solid #dbeafe;
    border-top-color: #2563eb;
    border-radius: 50%;
    animation: cegemModalSwapSpin 0.7s linear infinite;
}

@keyframes cegemModalSwapSpin {
    to {
        transform: rotate(360deg);
    }
}

/* E-mail linkről megnyitott feladat szerkesztő – modal-szerű popup teljes oldalon */
.cegem-task-popup-page {
    margin: 0;
    min-height: 100vh;
    background: rgba(15, 23, 42, 0.42);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 1.25rem 1rem 2rem;
}

.cegem-task-popup-shell {
    width: 100%;
    max-width: 640px;
}

.cegem-task-popup-dialog {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 1rem;
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.35);
    border: 1px solid rgba(13, 110, 253, 0.12);
    overflow: hidden;
}

.cegem-task-popup-dialog .modal-header {
    padding: 1.25rem 1.25rem 0.5rem;
}

.cegem-task-popup-dialog .modal-body {
    max-height: min(72vh, calc(100vh - 12rem));
    overflow-y: auto;
}

.cegem-task-popup-badge {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #2563eb;
    background: rgba(37, 99, 235, 0.1);
    border-radius: 999px;
    padding: 0.25rem 0.65rem;
}

@media (max-width: 575.98px) {
    .cegem-task-popup-page {
        padding: 0.75rem 0.5rem 1.5rem;
    }

    .cegem-task-popup-dialog .modal-body {
        max-height: none;
    }
}

/* Mobil / tablet hamburger (navbar-expand-xl alatt) */
@media (max-width: 1199.98px) {
    body:has(#navbarContent.show) nav.navbar.navbar-pro.fixed-top,
    body:has(#navbarContent.collapsing) nav.navbar.navbar-pro.fixed-top {
        z-index: 1080;
    }

    .navbar-pro .navbar-collapse {
        padding-top: 0.25rem;
    }

    .navbar-pro .navbar-nav {
        width: 100%;
        margin-bottom: 0 !important;
        align-items: stretch;
    }

    .navbar-pro .navbar-nav .nav-item {
        width: 100%;
    }

    .navbar-pro .navbar-nav .nav-link {
        display: flex !important;
        align-items: center;
        justify-content: flex-start;
        gap: 0.5rem;
        width: 100%;
        text-align: left;
        float: none;
        padding: 0.75rem 1rem;
    }

    .navbar-pro .navbar-nav .nav-link:hover {
        background-color: #f8f9fa;
    }

    .navbar-pro .nav-mobile-group-toggle {
        border: 0;
        background: transparent;
        justify-content: space-between !important;
    }

    .navbar-pro .nav-mobile-group-toggle .nav-mobile-group-chevron {
        transition: transform 0.2s ease;
        font-size: 0.85rem;
        opacity: 0.65;
    }

    .navbar-pro .nav-mobile-group-toggle[aria-expanded="true"] .nav-mobile-group-chevron {
        transform: rotate(180deg);
    }

    .navbar-pro .nav-mobile-group-panel {
        border-left: 2px solid rgba(13, 110, 253, 0.15);
        margin-left: 1rem;
    }

    .navbar-pro .nav-mobile-group-items {
        padding-left: 0;
        margin-bottom: 0.25rem;
    }

    .navbar-pro .nav-mobile-sub-link {
        padding-left: 1.5rem !important;
        font-size: 0.95rem;
        font-weight: 500;
    }
}

/* Egyedi fájlválasztó (magyar feliratok, natív input elrejtve) */
.cegem-file-picker {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
    position: relative;
}

.cegem-file-picker-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
    opacity: 0;
}

.cegem-file-picker-btn {
    cursor: pointer;
    margin-bottom: 0;
}

.cegem-file-picker-name {
    flex: 1 1 12rem;
    min-width: 0;
    word-break: break-word;
}

/* Általános súgó ikon (hover tooltip), pl. projekt bevételi terv */
.app-help-btn {
    border: none;
    background: transparent;
    color: #94a3b8;
    padding: 0.15rem;
    line-height: 1;
    font-size: 1.05rem;
    cursor: help;
    vertical-align: middle;
}

.app-help-btn:hover,
.app-help-btn:focus {
    color: #0d6efd;
    outline: none;
}

.app-help-btn .bi {
    display: block;
}

.tooltip.app-help-tooltip {
    z-index: 1080;
}

.tooltip.app-help-tooltip .tooltip-inner {
    max-width: min(22rem, calc(100vw - 2rem));
    text-align: left;
    font-size: 0.8125rem;
    line-height: 1.45;
    padding: 0.65rem 0.85rem;
}
