/* ==========================================================================
   🎯 FitPoprawny - Moduł Zarządzania (Panel Trenera) CSS
   Design System: #141627 Navy, #e57c34 Accent, nowoczesne karty i panele
   ========================================================================== */

.fitpoprawny_mgt_wrapper {
    width: 100%;
    box-sizing: border-box;
    font-family: inherit;
    color: #141627;
}

/* 🔹 Górny pasek podzakładek Zarządzania */
.fitpoprawny_mgt_top_nav {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 24px;
    border-bottom: 1px solid #e7e7ea;
    padding-bottom: 12px;
}

.fitpoprawny_mgt_subtab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 10px;
    border: 1px solid #e7e7ea;
    background: #ffffff;
    color: #555a68;
    font-size: 0.94rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.fitpoprawny_mgt_subtab:hover {
    border-color: #e57c34;
    color: #e57c34;
    background: #fff8f4;
}

.fitpoprawny_mgt_subtab.is-active {
    background: #141627;
    color: #ffffff;
    border-color: #141627;
    box-shadow: 0 4px 14px rgba(20, 22, 39, 0.15);
}

.fitpoprawny_mgt_subtab .mgt-badge {
    background: rgba(229, 124, 52, 0.15);
    color: #e57c34;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.78rem;
    font-weight: 800;
}

.fitpoprawny_mgt_subtab.is-active .mgt-badge {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
}

/* 🔹 Nagłówek selektora klientów */
.fitpoprawny_mgt_selector_header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
    margin-bottom: 22px;
    flex-wrap: wrap;
}

.fitpoprawny_mgt_selector_title_wrap h3 {
    font-size: 1.45rem;
    font-weight: 800;
    margin: 0 0 4px;
    color: #141627;
    letter-spacing: -0.01em;
}

.fitpoprawny_mgt_selector_title_wrap p {
    font-size: 0.9rem;
    color: #666b78;
    margin: 0;
}

.fitpoprawny_mgt_search_box {
    position: relative;
    display: flex;
    align-items: center;
    min-width: 300px;
}

.fitpoprawny_mgt_search_box .search-ico {
    position: absolute;
    left: 14px;
    font-size: 0.95rem;
    opacity: 0.55;
    pointer-events: none;
}

.fitpoprawny_mgt_search_box input {
    width: 100%;
    padding: 10px 36px 10px 40px !important;
    border-radius: 10px !important;
    border: 1px solid #e7e7ea !important;
    background: #ffffff !important;
    font-size: 0.92rem !important;
    height: 42px !important;
    min-height: 42px !important;
    box-sizing: border-box !important;
    outline: none !important;
    margin: 0 !important;
}

.fitpoprawny_mgt_search_box input:focus {
    border-color: #e57c34 !important;
    box-shadow: 0 0 0 3px rgba(229, 124, 52, 0.25) !important;
}

#fitpoprawny_mgt_search_clear {
    position: absolute;
    right: 10px;
    background: none;
    border: none;
    color: #666b78;
    font-size: 1.2rem;
    cursor: pointer;
}

/* 🔹 Stan ładowania */
.fitpoprawny_mgt_loading,
.fitpoprawny_mgt_client_loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    gap: 12px;
    color: #666b78;
    font-size: 0.95rem;
}

.fitpoprawny_mgt_spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #f0f0f3;
    border-top-color: #e57c34;
    border-radius: 50%;
    animation: mgt-spin 0.75s infinite linear;
}

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

/* 🔹 Siatka kafelków klientów */
.fitpoprawny_mgt_clients_grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.fitpoprawny_mgt_client_card {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 14px;
    padding: 18px;
    box-shadow: 0 4px 16px rgba(20, 22, 39, 0.04);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.22s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.fitpoprawny_mgt_client_card:hover {
    transform: translateY(-2px);
    border-color: #e57c34;
    box-shadow: 0 8px 24px rgba(229, 124, 52, 0.12);
}

.fitpoprawny_mgt_client_card_top {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 14px;
}

.fitpoprawny_mgt_card_avatar {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(135deg, #e57c34 0%, #ba5716 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    font-weight: 800;
    flex-shrink: 0;
    box-shadow: 0 3px 10px rgba(229, 124, 52, 0.28);
}

.fitpoprawny_mgt_card_details {
    flex: 1;
    min-width: 0;
}

.fitpoprawny_mgt_card_name {
    font-size: 1.05rem;
    font-weight: 800;
    color: #141627;
    margin: 0 0 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fitpoprawny_mgt_card_email {
    font-size: 0.82rem;
    color: #666b78;
    margin: 0 0 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fitpoprawny_mgt_card_meta {
    font-size: 0.78rem;
    color: #8c919e;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* Pigułki ze stanem modułów na karcie */
.fitpoprawny_mgt_card_badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 10px 0;
    border-top: 1px solid #f2f3f7;
    border-bottom: 1px solid #f2f3f7;
    margin-bottom: 12px;
}

.fitpoprawny_mgt_pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    background: #f4f5f8;
    color: #666b78;
}

.fitpoprawny_mgt_pill.is-active {
    background: #fff3ea;
    color: #ba5716;
    border: 1px solid rgba(229, 124, 52, 0.2);
}

.fitpoprawny_mgt_card_btn {
    width: 100%;
    padding: 9px 14px;
    border-radius: 8px;
    border: 1px solid #e7e7ea;
    background: #fafafc;
    color: #141627;
    font-size: 0.86rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.fitpoprawny_mgt_client_card:hover .fitpoprawny_mgt_card_btn {
    background: #e57c34;
    color: #ffffff;
    border-color: #e57c34;
    box-shadow: 0 4px 12px rgba(229, 124, 52, 0.25);
}

/* 🔹 Widok B: Belka nagłówkowa wybranego klienta */
.fitpoprawny_mgt_client_header_card {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 14px;
    padding: 20px 24px;
    margin-bottom: 20px;
    box-shadow: 0 4px 20px rgba(20, 22, 39, 0.05);
}

.fitpoprawny_mgt_client_header_top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f2f3f7;
    flex-wrap: wrap;
    gap: 12px;
}

.fitpoprawny_mgt_btn_back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #f4f5f8;
    color: #141627;
    border: 1px solid #e7e7ea;
    padding: 7px 14px;
    border-radius: 8px;
    font-size: 0.86rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.fitpoprawny_mgt_btn_back:hover {
    background: #e7e7ea;
    transform: translateX(-2px);
}

.fitpoprawny_mgt_client_switcher {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.86rem;
    color: #666b78;
}

.fitpoprawny_mgt_client_switcher select {
    padding: 6px 12px !important;
    height: 36px !important;
    min-height: 36px !important;
    border-radius: 8px !important;
    border: 1px solid #e7e7ea !important;
    font-size: 0.86rem !important;
    background: #ffffff !important;
    color: #141627 !important;
    margin: 0 !important;
    outline: none !important;
}

/* Pasek profilowy klienta */
.fitpoprawny_mgt_client_profile_strip {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.fitpoprawny_mgt_strip_left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.fitpoprawny_mgt_strip_avatar {
    width: 58px;
    height: 58px;
    border-radius: 14px;
    background: linear-gradient(135deg, #e57c34 0%, #d86f2a 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 800;
    flex-shrink: 0;
    box-shadow: 0 4px 14px rgba(229, 124, 52, 0.32);
}

.fitpoprawny_mgt_strip_name_wrap h2 {
    font-size: 1.35rem;
    font-weight: 800;
    margin: 0 0 4px;
    color: #141627;
}

.fitpoprawny_mgt_strip_contacts {
    display: flex;
    gap: 14px;
    font-size: 0.84rem;
    color: #666b78;
    flex-wrap: wrap;
}

.fitpoprawny_mgt_strip_metrics {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.fitpoprawny_mgt_metric_pill {
    background: #f8f9fb;
    border: 1px solid #e7e7ea;
    border-radius: 10px;
    padding: 8px 14px;
    text-align: center;
    min-width: 80px;
}

.fitpoprawny_mgt_metric_pill small {
    display: block;
    font-size: 0.72rem;
    color: #8c919e;
    text-transform: uppercase;
    font-weight: 700;
    margin-bottom: 2px;
}

.fitpoprawny_mgt_metric_pill strong {
    font-size: 1.05rem;
    font-weight: 800;
    color: #141627;
}

/* 🔹 Pasek 5 zakładek klienta */
.fitpoprawny_mgt_client_tabs {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    background: #ffffff;
    padding: 8px;
    border-radius: 12px;
    border: 1px solid #e7e7ea;
    box-shadow: 0 2px 10px rgba(20, 22, 39, 0.03);
    overflow-x: auto;
}

.fitpoprawny_mgt_client_tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 9px;
    border: 1px solid transparent;
    background: transparent;
    color: #555a68;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.fitpoprawny_mgt_client_tab:hover {
    background: #f6f7fa;
    color: #141627;
}

.fitpoprawny_mgt_client_tab.is-active {
    background: #141627;
    color: #ffffff;
    box-shadow: 0 3px 12px rgba(20, 22, 39, 0.15);
}

.fitpoprawny_mgt_client_tab .tab-badge {
    background: #f0f0f3;
    color: #666b78;
    padding: 2px 7px;
    border-radius: 10px;
    font-size: 0.74rem;
    font-weight: 700;
}

.fitpoprawny_mgt_client_tab.is-active .tab-badge {
    background: rgba(255, 255, 255, 0.25);
    color: #ffffff;
}

/* 🔹 Panele zawartości zakładek klienta */
.fitpoprawny_mgt_tab_panel {
    display: none;
    animation: mgt-fade-in 0.2s ease;
}

.fitpoprawny_mgt_tab_panel.is-active {
    display: block;
}

@keyframes mgt-fade-in {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   1. DIETA - STYL
   ========================================================================== */
.fitpoprawny_mgt_diet_grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 900px) {
    .fitpoprawny_mgt_diet_grid { grid-template-columns: 1fr; }
}

.fitpoprawny_mgt_box {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 14px;
    padding: 22px;
    box-shadow: 0 4px 18px rgba(20, 22, 39, 0.04);
}

.fitpoprawny_mgt_box_title {
    font-size: 1.15rem;
    font-weight: 800;
    margin: 0 0 16px;
    color: #141627;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Kafelki energii i makro */
.fitpoprawny_mgt_energy_cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 20px;
}

.fitpoprawny_mgt_energy_card {
    background: #fafafc;
    border: 1px solid #e7e7ea;
    border-radius: 10px;
    padding: 14px;
    text-align: center;
}

.fitpoprawny_mgt_energy_card small {
    display: block;
    font-size: 0.78rem;
    color: #8c919e;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.fitpoprawny_mgt_energy_card strong {
    font-size: 1.35rem;
    font-weight: 800;
    color: #141627;
}

.fitpoprawny_mgt_macro_cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}

@media (max-width: 600px) {
    .fitpoprawny_mgt_macro_cards { grid-template-columns: 1fr 1fr; }
}

.fitpoprawny_mgt_macro_card {
    border-radius: 10px;
    padding: 12px 10px;
    text-align: center;
    border: 1px solid transparent;
}

.macro-kcal { background: #fff5ef; border-color: rgba(229, 124, 52, 0.25); color: #ba5716; }
.macro-p    { background: #eff6ff; border-color: rgba(37, 99, 235, 0.25); color: #1d4ed8; }
.macro-f    { background: #fefce8; border-color: rgba(202, 138, 4, 0.25); color: #a16207; }
.macro-c    { background: #f0fdf4; border-color: rgba(22, 163, 74, 0.25); color: #15803d; }

.fitpoprawny_mgt_macro_card small {
    display: block;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 2px;
}

.fitpoprawny_mgt_macro_card strong {
    font-size: 1.25rem;
    font-weight: 800;
}

/* ==========================================================================
   2. SUPLEMENTACJA - STYL
   ========================================================================== */
.fitpoprawny_mgt_sup_header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}

.fitpoprawny_mgt_btn_primary {
    background: linear-gradient(135deg, #e57c34 0%, #d86f2a 100%);
    color: #ffffff;
    border: none;
    padding: 9px 18px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.88rem;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(229, 124, 52, 0.25);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.fitpoprawny_mgt_btn_primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(229, 124, 52, 0.35);
}

.fitpoprawny_mgt_sup_grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.fitpoprawny_mgt_sup_card {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 3px 12px rgba(20, 22, 39, 0.04);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.fitpoprawny_mgt_sup_card_title {
    font-size: 1.05rem;
    font-weight: 800;
    color: #141627;
    margin: 0 0 6px;
}

.fitpoprawny_mgt_sup_card_dose {
    font-size: 0.88rem;
    font-weight: 700;
    color: #e57c34;
    margin-bottom: 6px;
}

.fitpoprawny_mgt_sup_card_time {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 6px;
    background: #f4f5f8;
    color: #555a68;
    font-size: 0.76rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.fitpoprawny_mgt_sup_card_desc {
    font-size: 0.82rem;
    color: #666b78;
    margin-bottom: 12px;
    line-height: 1.4;
}

.fitpoprawny_mgt_sup_card_footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #f2f3f7;
    padding-top: 10px;
}

/* ==========================================================================
   3. TRENINGI - STYL
   ========================================================================== */
.fitpoprawny_mgt_trainings_grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 18px;
}

.fitpoprawny_mgt_plan_card {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 14px;
    padding: 20px;
    box-shadow: 0 4px 16px rgba(20, 22, 39, 0.04);
}

.fitpoprawny_mgt_plan_title {
    font-size: 1.15rem;
    font-weight: 800;
    margin: 0 0 6px;
    color: #141627;
}

.fitpoprawny_mgt_plan_goal {
    font-size: 0.85rem;
    color: #666b78;
    margin-bottom: 12px;
}

.fitpoprawny_mgt_progress_wrap {
    margin-bottom: 14px;
}

.fitpoprawny_mgt_progress_bar {
    width: 100%;
    height: 8px;
    background: #f0f0f3;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 4px;
}

.fitpoprawny_mgt_progress_fill {
    height: 100%;
    background: linear-gradient(90deg, #e57c34, #27ae60);
    border-radius: 4px;
}

/* ==========================================================================
   4. FITATU - STYL
   ========================================================================== */
.fitpoprawny_mgt_fitatu_grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
}

.fitpoprawny_mgt_fitatu_card {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 3px 12px rgba(20, 22, 39, 0.04);
}

.fitpoprawny_mgt_fitatu_card_date {
    font-weight: 800;
    font-size: 0.88rem;
    color: #141627;
    margin-bottom: 8px;
}

.fitpoprawny_mgt_fitatu_imgs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
    margin-bottom: 8px;
}

.fitpoprawny_mgt_fitatu_thumb {
    width: 100%;
    height: 110px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    border: 1px solid #e7e7ea;
    transition: transform 0.2s ease;
}

.fitpoprawny_mgt_fitatu_thumb:hover {
    transform: scale(1.03);
}

/* ==========================================================================
   5. POMIARY - STYL
   ========================================================================== */
.fitpoprawny_mgt_measures_summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    margin-bottom: 22px;
}

.fitpoprawny_mgt_measure_stat {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    box-shadow: 0 3px 12px rgba(20, 22, 39, 0.04);
}

.fitpoprawny_mgt_measure_stat small {
    display: block;
    font-size: 0.74rem;
    text-transform: uppercase;
    font-weight: 700;
    color: #8c919e;
    margin-bottom: 4px;
}

.fitpoprawny_mgt_measure_stat strong {
    font-size: 1.4rem;
    font-weight: 800;
    color: #141627;
}

/* 🔹 Karta obwodów w module pomiarów */
.fitpoprawny_mgt_circs_card {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 12px;
    padding: 18px 20px;
    margin-bottom: 22px;
    box-shadow: 0 3px 12px rgba(20, 22, 39, 0.04);
}

.fitpoprawny_mgt_circs_card_head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid #f2f3f7;
    flex-wrap: wrap;
    gap: 8px;
}

.fitpoprawny_mgt_circs_grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 10px;
}

.fitpoprawny_mgt_circ_pill {
    background: #f8f9fb;
    border: 1px solid #e7e7ea;
    border-radius: 9px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.84rem;
    transition: all 0.15s ease;
}

.fitpoprawny_mgt_circ_pill:hover {
    border-color: #e57c34;
    background: #fff8f3;
}

.fitpoprawny_mgt_circ_num {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #e7e7ea;
    color: #555a68;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-weight: 700;
    flex-shrink: 0;
}

.fitpoprawny_mgt_circ_name {
    color: #444755;
    font-weight: 600;
    flex: 1;
}

.fitpoprawny_mgt_circ_val {
    color: #141627;
    font-weight: 800;
}

.fitpoprawny_mgt_table_wrap {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 12px;
    overflow-x: auto;
    box-shadow: 0 3px 12px rgba(20, 22, 39, 0.04);
}

.fitpoprawny_mgt_table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.86rem;
}

.fitpoprawny_mgt_table th,
.fitpoprawny_mgt_table td {
    padding: 11px 14px;
    text-align: left;
    border-bottom: 1px solid #f2f3f7;
}

.fitpoprawny_mgt_table th {
    background: #fbfbfd;
    font-weight: 700;
    color: #555a68;
}

/* Lightbox dla Fitatu */
.fitpoprawny_mgt_lightbox {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fitpoprawny_mgt_lightbox_backdrop {
    position: absolute;
    inset: 0;
    background: rgba(20, 22, 39, 0.8);
    backdrop-filter: blur(5px);
}

.fitpoprawny_mgt_lightbox_content {
    position: relative;
    z-index: 2;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.fitpoprawny_mgt_lightbox_img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.fitpoprawny_mgt_lightbox_close {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 2rem;
    cursor: pointer;
}

/* Szybkie propozycje suplementów w modalu */
.fitpoprawny_mgt_quick_sups_wrap {
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f0f0f3;
}

.fitpoprawny_mgt_quick_sups_wrap .quick-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 700;
    color: #8c919e;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.fitpoprawny_mgt_quick_sups {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.quick-sup-chip {
    background: #f4f5f8;
    border: 1px solid #e7e7ea;
    border-radius: 6px;
    padding: 4px 9px;
    font-size: 0.78rem;
    font-weight: 600;
    color: #141627;
    cursor: pointer;
    transition: all 0.15s ease;
}

.quick-sup-chip:hover {
    background: #fff5ef;
    border-color: #e57c34;
    color: #e57c34;
}

/* ==========================================================================
   NAWYKI - STYL PANELU I MODALI
   ========================================================================== */
.fitpoprawny_mgt_habits_list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.fitpoprawny_mgt_pkg_card {
    background: #ffffff;
    border: 1px solid #e7e7ea;
    border-radius: 14px;
    padding: 22px;
    box-shadow: 0 4px 18px rgba(20, 22, 39, 0.04);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.fitpoprawny_mgt_pkg_card:hover {
    box-shadow: 0 6px 22px rgba(20, 22, 39, 0.07);
}

.fitpoprawny_mgt_btn_quick_weeks {
    background: #f4f5f8;
    border: 1px solid #e7e7ea;
    border-radius: 6px;
    padding: 5px 12px;
    font-size: 0.82rem;
    font-weight: 700;
    color: #141627;
    cursor: pointer;
    transition: all 0.15s ease;
}

.fitpoprawny_mgt_btn_quick_weeks:hover,
.fitpoprawny_mgt_btn_quick_weeks:focus {
    background: #fff5ef;
    border-color: #e57c34;
    color: #e57c34;
}

.fitpoprawny_mgt_habit_input_row {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fafafc;
    border: 1px solid #f0f0f3;
    padding: 6px 10px;
    border-radius: 8px;
}

.fitpoprawny_mgt_habit_input_row .habit-row-num {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: #e57c34;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 800;
    flex-shrink: 0;
}

.fitpoprawny_mgt_habit_input_row input[type="text"] {
    flex: 1;
    height: 38px;
    border-radius: 8px;
    border: 1px solid #e7e7ea;
    padding: 0 12px;
    font-size: 0.88rem;
    background: #ffffff;
}

.fitpoprawny_mgt_btn_remove_habit_row {
    background: #fee2e2;
    color: #dc2626;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 800;
    font-size: 1.1rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease;
}

.fitpoprawny_mgt_btn_remove_habit_row:hover {
    background: #fca5a5;
}

/* Chipy ocen 1-10 */
.fitpoprawny_mgt_rating_chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid #e7e7ea;
    background: #ffffff;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.9rem;
    color: #141627;
    transition: all 0.15s ease;
    user-select: none;
}

.fitpoprawny_mgt_rating_chip:hover {
    border-color: #e57c34;
    color: #e57c34;
    background: #fff5ef;
}

.fitpoprawny_mgt_rating_chip.active,
.fitpoprawny_mgt_rating_chip:has(input:checked) {
    background: #e57c34;
    border-color: #e57c34;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(229, 124, 52, 0.35);
}

/* Wymuszenie wyświetlania modali z klasą .show */
#fitpoprawny_mgt_ai_modal.show,
#fitpoprawny_mgt_sup_modal.show {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    z-index: 9999999 !important;
}

#fitpoprawny_mgt_ai_modal.show .fitpoprawny_modal_content,
#fitpoprawny_mgt_sup_modal.show .fitpoprawny_modal_content {
    display: flex !important;
    flex-direction: column !important;
    z-index: 10000000 !important;
    position: relative !important;
}

/* 🔹 Akcje w nagłówku profilu klienta */
.fitpoprawny_mgt_client_header_actions {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.fitpoprawny_mgt_btn_ai_report {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #ffffff;
    color: #141627 !important;
    border: 1px solid #e7e7ea;
    padding: 10px 16px;
    border-radius: 10px;
    font-size: 0.86rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(20, 22, 39, 0.03);
    align-self: stretch;
}

.fitpoprawny_mgt_btn_ai_report:hover {
    background: #fff5ef;
    border-color: #e57c34;
    color: #e57c34 !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(229, 124, 52, 0.16);
}

.fitpoprawny_mgt_btn_ai_report .ai-icon {
    font-size: 1.15rem;
    line-height: 1;
}

.fitpoprawny_mgt_btn_ai_report .ai-label {
    font-weight: 700;
    letter-spacing: -0.2px;
}

/* 🔹 Pasek narzędzi raportu AI */
.fitpoprawny_mgt_ai_toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    flex-wrap: wrap;
    background: #f8f9fb;
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid #e7e7ea;
}

.fitpoprawny_mgt_ai_tool_btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 0.84rem;
    font-weight: 700;
    cursor: pointer;
    border: 1px solid #d5d8e2;
    background: #ffffff;
    color: #141627;
    transition: all 0.15s ease;
}

.fitpoprawny_mgt_ai_tool_btn:hover {
    border-color: #141627;
    background: #f4f5f8;
}

.fitpoprawny_mgt_ai_tool_btn.is-primary {
    background: #e57c34;
    color: #ffffff;
    border-color: #e57c34;
}

.fitpoprawny_mgt_ai_tool_btn.is-primary:hover {
    background: #c9621c;
    border-color: #c9621c;
}

.fitpoprawny_mgt_copy_status {
    font-size: 0.86rem;
    font-weight: 700;
    color: #16a34a;
    margin-left: auto;
}

/* 🔹 Podgląd raportu Markdown */
.fitpoprawny_mgt_ai_preview_box {
    background: #141627;
    border-radius: 10px;
    border: 1px solid #23273e;
    overflow: hidden;
}

#fitpoprawny_mgt_ai_preview_text {
    width: 100%;
    min-height: 380px;
    max-height: 520px;
    padding: 16px;
    box-sizing: border-box;
    border: none;
    outline: none;
    background: transparent;
    color: #e4e7f1;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.82rem;
    line-height: 1.55;
    resize: vertical;
    white-space: pre;
    overflow-x: auto;
}



