/**
 * Aurelia AI LivePlan - Stylesheet
 * Design inspired by Mieszkanie module
 */

:root {
    --primary-color: #cbbb9fca;
    --dark-color: #373a3f;
    --light-color: #f8f8f8;
    --border-color: #696E75;
    --text-dark: var(--color-palette-2);
    --text-light: #666;
    --transition: all 0.2s ease;

    /* Paleta kolorów mieszkań - wstrzykiwane z panelu administracyjnego */
    /* Dostępne zmienne: --color-palette-1, --color-palette-2, ... --color-palette-6 */
    /* Fallback na domyślne kolory jeśli nie zostały zdefiniowane w adminie */

    /* Status colors - fallback values */
    --color-status-free: #28a745;
    --color-status-reserved: #ffc107;
    --color-status-sold: #dc3545;

    --var-color-palette-1: #5D3334;
    --var-color-palette-2: #7a444d;
    --var-color-palette-3: #9b5e60;
    --var-color-palette-4: #bb7a7c;
    --var-color-palette-5: #d4999b;
    --var-color-palette-6: #e8b8b9;
}

/* ==================== TOOLTIP ANIMATIONS ==================== */
@keyframes tooltipFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.liveplan-apartment-tooltip {
    animation: tooltipFadeIn 0.15s ease-out !important;
    transform-origin: center bottom;
}

.aurelia-liveplan-response {
    flex: 1;
    min-height: 400px;
}

.aurelia-liveplan-response svg {
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
}

.aurelia-liveplan-response img {
    width: 100%;
    height: auto;
    display: block;
    filter: brightness(0.2);
}


.liveplan-detail-image {
    width: 100%;
    height: auto;
    overflow: hidden;
}

.liveplan-detail-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.liveplan-detail-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.liveplan-detail-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 20px;
}

.liveplan-detail-meta {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.liveplan-detail-meta-item {
    display: flex;
    flex-direction: column;
}

.liveplan-detail-meta-label {
    font-size: 11px;
    color: var(--border-color);
    text-transform: uppercase;
    font-weight: 700;
    margin-bottom: 6px;
    letter-spacing: 0.5px;
}

.liveplan-detail-meta-value {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
}

.liveplan-detail-price {
    font-size: 20px;
    color: var(--primary-color);
    font-weight: 700;
}

.liveplan-detail-status {
    display: inline-block;
    padding: 0px 10px;
    background: var(--primary-color);
    color: rgb(38, 37, 37);
    border-radius: 0;
    font-size: 9px;
    font-weight: 700;
    text-transform: uppercase;
    width: fit-content;
    letter-spacing: 0.5px;
    line-height: 18px;
    margin-left: 20px;
}


.liveplan-detail-main-info .numer-domu {
    font-size: 57px;
    font-weight: 900;
    color: var(--color-palette-1);
    margin-bottom: 5px;
    vertical-align: top;
    display: flex;
    align-items: flex-start;
    flex-direction: row;
    line-height: 47px;
}

.liveplan-detail-main-info .podpis {
    font-size: 12px;
    color: #585858;
    display: block;
    margin-bottom: 15px;
    text-transform: uppercase;
}

/* ==================== SEARCH SECTION ==================== */
.liveplan-search-filters-section {
    background: #ffffff1c;
    padding: 30px;
    border-radius: 0;
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
}



@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

.liveplan-search-section {
    background: transparent;
    padding: 0;
    margin-bottom: 30px;
    border-radius: 0;
    display: flex;
    gap: 12px;
    display: none;
}

.liveplan-search-input {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    font-size: 15px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
}

.liveplan-search-input::placeholder {
    color: #999;
    font-weight: 400;
}

.liveplan-search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: white;
    box-shadow: 0 0 0 4px rgba(203, 187, 159, 0.15);
    transform: translateY(-1px);
}

.liveplan-search-btn {
    padding: 14px 40px;
    background: linear-gradient(135deg, #cbbb9f 0%, #d4c4a8 100%);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(203, 187, 159, 0.3);
}

.liveplan-search-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(203, 187, 159, 0.4);
}

.liveplan-search-btn:active {
    transform: translateY(0);
}

/* ==================== FILTERS SECTION ==================== */
.liveplan-filters-section {
    background: transparent;
    padding: 0;
    border-radius: 0;
    margin-bottom: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 24px;
    align-items: center;
}

@media (max-width: 768px) {
    .liveplan-filters-section {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

.liveplan-filter-group {
    display: flex;
    flex-direction: column;
    gap: 0px;
}

.liveplan-filter-group label {
    font-weight: 700;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
    letter-spacing: 1.2px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.liveplan-filter-group label::before {
    content: '';
    width: 3px;
    height: 14px;
    background: var(--primary-color);
    border-radius: 2px;
}

.liveplan-filter-group select,
.liveplan-filter-group input {
    padding: 14px 16px;
    border: 2px solid rgba(255, 255, 255, 0.6);
    border-radius: 12px;
    font-size: 15px;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    color: #2c3e50;
    font-weight: 500;
    cursor: pointer;
}

.liveplan-filter-group select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%232c3e50' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
}

.liveplan-filter-group select:hover,
.liveplan-filter-group input:hover {
    border-color: rgba(203, 187, 159, 0.4);

}

.liveplan-filter-group select:focus,
.liveplan-filter-group input:focus {
    outline: none;
    border-color: #fff;
    background-color: #fff6 !important;
    box-shadow: 0 0 0 4px rgba(203, 187, 159, 0.15);
    transform: translateY(-1px);
}

.liveplan-filter-group input[type="number"] {
    padding: 14px 16px;
}

/* ==================== AREA SLIDER ==================== */
.liveplan-area-slider {
    margin: 10px 0 35px 0;
    padding: 15px 0;
}

/* Stylizacja noUiSlider */
.noUi-target {
    background: rgba(255, 255, 255, 0.2) !important;
    border: none !important;
    border-radius: 10px;
    height: 8px;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1) !important;
    pointer-events: auto !important;
}

.noUi-connect {
    background: linear-gradient(90deg, #5D3334 0%, #7a444d 100%) !important;
    box-shadow: 0 2px 8px rgba(93, 51, 52, 0.4) !important;
    pointer-events: none !important;
}

.noUi-handle {
    width: 24px !important;
    height: 24px !important;
    border-radius: 50% !important;
    background: white !important;
    border: 3px solid #5D3334 !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2), 0 0 0 0 rgba(93, 51, 52, 0.4) !important;
    cursor: grab !important;
    cursor: hand !important;
    top: -9px !important;
    left: -12px !important;
    right: auto !important;
    transition: all 0.3s ease;
    pointer-events: auto !important;
}

.noUi-handle.noUi-lower {
    left: -12px !important;
    right: auto !important;
}

.noUi-handle.noUi-upper {
    right: -12px !important;
    left: auto !important;
}

.noUi-handle::before,
.noUi-handle::after {
    display: none;
}

.noUi-handle:hover {
    transform: scale(1.15);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25), 0 0 0 8px rgba(93, 51, 52, 0.15) !important;
}

.noUi-handle:active {
    cursor: grabbing;
    transform: scale(1.05);
}

.noUi-handle.noUi-active {
    box-shadow: 0 4px 20px rgba(93, 51, 52, 0.5), 0 0 0 8px rgba(93, 51, 52, 0.2) !important;
}

.noUi-handle:focus {
    outline: none;
}

/* Tooltips dla suwaka */
.noUi-tooltip {
    background: #ffffffbf;
    color: var(--color-palette-2);
    border: 0px solid rgba(203, 187, 159, 0.5) !important;
    border-radius: 3px;
    padding: 8px 14px !important;
    font-size: 13px !important;
    font-weight: 700;
    bottom: 140% !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0);
    letter-spacing: 0.5px;
}

.noUi-tooltip::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid #ffffffbf;
}

/* Pips (podziałki) */
.noUi-pips {
    padding: 10px 0;
}

.noUi-pip {
    padding: 0 !important;
    height: auto !important;
}

.noUi-value {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 600;
}

.noUi-pips-horizontal {
    display: none !important;
}

/* Input fields dla wybranego zakresu */
.liveplan-area-inputs {
    display: none;
    align-items: center;
    gap: 12px;
    margin-top: 15px;
}

.liveplan-area-separator {
    color: rgba(255, 255, 255, 0.6);
    font-weight: 700;
    font-size: 18px;
    user-select: none;
}

.liveplan-area-min,
.liveplan-area-max {
    flex: 1;
    padding: 12px !important;
    border: 2px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 10px;
    font-size: 15px;
    background: rgba(255, 255, 255, 0.95) !important;
    color: #2c3e50;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
}

.liveplan-area-min:focus,
.liveplan-area-max:focus {
    outline: none;
    border-color: var(--primary-color) !important;
    background: white !important;
    box-shadow: 0 0 0 4px rgba(203, 187, 159, 0.15);
}

/* ==================== RESET BUTTON ==================== */
.liveplan-filter-reset {
    padding: 14px 32px;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 1px;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.liveplan-filter-reset::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.liveplan-filter-reset:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.liveplan-filter-reset:hover::before {
    width: 300px;
    height: 300px;
}

.liveplan-filter-reset:active {
    transform: translateY(0);
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 1024px) {
    .liveplan-search-filters-section {
        padding: 30px;
    }
}

@media (max-width: 768px) {
    .liveplan-search-filters-section {
        padding: 25px 20px;
    }

    .liveplan-filters-section {
        gap: 20px;
    }

    .liveplan-filter-reset {
        width: 100%;
    }
}

/* ==================== RESULTS SECTION ==================== */
.liveplan-results-section {
    margin-top: 20px;
}

.liveplan-loading {
    text-align: center;
    padding: 40px;
    color: #666;
    font-size: 16px;
}

.liveplan-loading::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-right: 10px;
    border: 2px solid #f0f0f0;
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* ==================== PROPERTY CARDS ==================== */
.liveplan-results {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.liveplan-property-card {
    background: #ffffff8c;
    background-repeat: no-repeat;
    background-size: 50%;
    background-position: 90% 30px;
    border: 0px solid #e8e8e8;
    border-radius: 0;
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.0);
    cursor: pointer;
}

.liveplan-property-card:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    transform: translateY(-3px);
}

.liveplan-property-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #f0f0f0;
    position: relative;
}

.liveplan-property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.liveplan-property-card:hover .liveplan-property-image img {
    transform: scale(1.08);
}

.liveplan-property-info {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.liveplan-room-number {
    margin: 0 0 15px 0;
    font-size: 20px;
    font-weight: 700;
    color: var(--text-dark);
}

.liveplan-property-meta {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
    font-size: 13px;
}

.meta-item {
    color: var(--text-light);
    line-height: 1.4;
}

.meta-item strong {
    color: var(--text-dark);
    font-weight: 700;
}

.liveplan-description {
    font-size: 13px;
    color: var(--text-light);
    margin: 12px 0;
    flex: 1;
    line-height: 1.6;
}

.liveplan-property-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid #eee;
    margin-top: auto;
}

.liveplan-price {
    font-weight: 700;
    font-size: 18px;
    color: var(--primary-color);
}

.liveplan-status {
    font-size: 9px;
    font-weight: 700;
    padding: 0px 10px;
    border-radius: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: var(--primary-color);
    color: white;
}

/* Status colors */
.status-available .liveplan-status.status-available,
.liveplan-detail-status.status-available {
    background: var(--color-status-free);
    color: var(--color-palette-2);
    border: 1px solid var(--color-palette-2)33327;
}

.status-reserved .liveplan-status.status-reserved,
.liveplan-detail-status.status-reserved {
    background: var(--color-status-reserved);
    color: var(--color-palette-2);
    border: 1px solid var(--color-status-reserved);
}

.status-sold .liveplan-status.status-sold,
.liveplan-detail-status.status-sold {
    background: var(--color-status-sold);
    color: var(--color-palette-2);
    border: 1px solid var(--color-status-sold);
}

.status-draft .liveplan-status.status-draft {
    background: #e0e0e0;
    color: #616161;
}

/* Hover effect dla całej karty */
.liveplan-property-card:hover {
    box-shadow: 0 8px 20px rgba(203, 187, 159, 0.15);
    transform: translateY(-4px);
}

/* ==================== NO RESULTS ==================== */
.liveplan-no-results {
    text-align: center;
    padding: 50px 20px;
    color: var(--text-light);
    font-size: 16px;
    background: white;
    border-radius: 0;
    border: 1px solid #e8e8e8;
    margin: 20px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

/* ==================== PAGINATION ==================== */
.liveplan-pagination {
    margin-top: 40px;
}

.liveplan-pagination-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.liveplan-pagination-btn {
    padding: 10px 20px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 0;
    cursor: pointer;
    font-weight: 700;
    transition: var(--transition);
    color: var(--text-dark);
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
}

.liveplan-pagination-btn:hover:not(:disabled) {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.liveplan-pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.liveplan-pagination-numbers {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.liveplan-pagination-number {
    padding: 10px 14px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 0;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    color: var(--text-dark);
    font-size: 13px;
}

.liveplan-pagination-number:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.liveplan-pagination-number.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    cursor: default;
}

.liveplan-pagination-dots {
    padding: 10px 6px;
    color: var(--text-light);
    font-weight: 700;
}

.liveplan-pagination-info {
    text-align: center;
    font-size: 14px;
    color: var(--text-light);
    margin: 15px 0 0 0;
}

.liveplan-pagination-info strong {
    color: var(--text-dark);
    font-weight: 700;
}

/* ==================== RESPONSIVE ==================== */
/* Graphical search styles removed - use [aurelia-table] instead */

.liveplan-property-info {
    padding: 12px;
}

.liveplan-room-number {
    font-size: 16px;
    margin-bottom: 10px;
}

.liveplan-property-meta {
    font-size: 12px;
    gap: 6px;
}

.liveplan-results {
    grid-template-columns: 1fr;
}
}



/* ==================== LIVEPLAN DETAIL CONTENT STYLES ==================== */
.liveplan-detail-content h4 {
    margin: 80px 0 20px 0 !important;
    line-height: 35px;
}

.liveplan-detail-content h4 {
    margin: 0 !important;
}

.liveplan-detail-content .margines {
    padding: 0 !important;
}

.liveplan-detail-content .szpalta {
    display: inline-block;
    padding: 0px;
    float: none;
}

.liveplan-detail-content .properity-image {
    display: flex;
    padding: 0px;
    justify-content: center;
    height: 100%;
    align-items: center;
}

.liveplan-detail-content .pdf a {
    display: flex;
    width: 48% !important;
    padding: 5px 10px;
    margin-right: 2px;
    height: 50px;
    vertical-align: middle;
    justify-content: center;
    align-items: center;
    background-color: var(--color-palette-2) !important;
}

.liveplan-detail-content .price-main span:last-child {
    font-size: 10px;
}

/* ==================== DEPRECATED GRAPHICAL SEARCH STYLES REMOVED ==================== */
/* These styles were for the old graphical search. Use [aurelia-table] instead. */
/* For template-based rendering, styles should be defined in separate template files. */


/* ==================== AURELIA TABLE STYLESHEET ==================== */

.aurelia-table-container {
    margin: 2rem 0;
}

/* TABS */
.aurelia-table-tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid #e9ecef;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.aurelia-table-tab-btn {
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    cursor: pointer;
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.9rem;
    color: #6c757d;
    transition: all 0.3s ease;
    position: relative;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
}

.aurelia-table-tab-btn:hover {
    color: var(--color-palette-1);
}

.aurelia-table-tab-btn.active {
    color: var(--color-palette-1);
    border-bottom-color: var(--color-palette-1);
    background: rgba(255, 255, 255, 0.99);
}

/* TAB CONTENT */
.aurelia-table-tabs-content {
    margin-top: 2rem;
}

.aurelia-table-tab-pane {
    display: none;
}

.aurelia-table-tab-pane.active {
    display: block;
}

/* SEARCH */
.aurelia-table-search {
    display: flex;
    gap: 10px;
    margin-bottom: 1.5rem;
}

.aurelia-table-search-input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 0.9rem;
}

.aurelia-table-search-input:focus {
    outline: none;
    border-color: var(--color-palette-1);
    box-shadow: 0 0 0 0.2rem rgba(5, 51, 112, 0.25);
}

.aurelia-table-search-btn {
    padding: 0.75rem 1.5rem;
    background: var(--color-palette-1);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.3s ease;
}

.aurelia-table-search-btn:hover {
    background: #042859;
}

/* TABLE */
.aurelia-table-wrapper {
    overflow-x: auto;
    margin-bottom: 1rem;
}

.aurelia-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0);
}

.aurelia-table thead {
    background: #f8f9fa65;
}

.aurelia-table th {
    padding: 1rem;
    text-align: center;
    font-weight: 600;
    color: var(--color-palette-2);
    text-transform: uppercase;
    font-size: 0.85rem;
    border-bottom: 0px solid #e9ecef;
    cursor: pointer;
    user-select: none;
    letter-spacing: 0.5px;
    border-top: 0;
}

.aurelia-table th,
.aurelia-table td {
    border-width: 0px;
}

.aurelia-table th.sortable:hover {
    background: #ffffff75;
}

.aurelia-table th.no-sort {
    cursor: default;
}

.aurelia-table th.no-sort:hover {
    background: #f8f9fa;
}

.aurelia-table th .sort-icon {
    margin-left: 5px;
    opacity: 0.3;
    transition: opacity 0.3s ease;
}

.aurelia-table th.sortable:hover .sort-icon {
    opacity: 0.6;
}

.aurelia-table th.sort-asc .sort-icon::before {
    content: '↑';
    opacity: 1;
}

.aurelia-table th.sort-desc .sort-icon::before {
    content: '↓';
    opacity: 1;
}

.aurelia-table td {
    padding: 1rem;
    border-top: 1px solid #0000002e;
}

.aurelia-table tbody tr:hover {
    background: #f8f9fa33;
}

.aurelia-table tbody tr.active {
    background: #cbbb9f86;
    font-weight: 500;
}

.aurelia-table tbody tr.active:hover {
    background: #cbbb9f6c;
}

.aurelia-table strong {
    color: var(--color-palette-1);
    font-weight: 600;
}


/* STATUS BADGE */
.aurelia-table-status {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 3px;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: uppercase;
    line-height: 0.8rem;
}

.status-available {
    background: var(--color-status-free);
    color: var(--color-palette-2);
    border: 1px solid var(--color-status-free);

}

.status-reserved {
    background: var(--color-status-reserved);
    color: var(--color-palette-2);
    border: 1px solid var(--color-status-reserved);
}

.status-sold {
    background: var(--color-status-sold);
    color: var(--color-palette-2);
    border: 1px solid var(--color-status-sold);
}

.status-unknown {
    background: #e2e3e5;
    color: #383d41;
    border: 1px solid #d3d3d3;
}

/* BUTTON */
.aurelia-table-btn-show {
    padding: 0.5rem 1rem;
    background: var(--color-palette-1);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.85rem;
    transition: background 0.3s ease;
    text-transform: uppercase;
    white-space: nowrap;
}

.aurelia-table-btn-show:hover {
    background: #5d3330cb;
    color: white;
}

/* LOADING */
.aurelia-table-loading {
    padding: 2rem;
    text-align: center;
    color: #6c757d;
}

/* NO RESULTS */
.aurelia-table-no-results {
    padding: 2rem;
    text-align: center;
    color: #6c757d;
    font-style: italic;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .aurelia-liveplan-nav {
        flex-direction: row;
        display: flow;
        grid-template-columns: 1fr !important;
    }

    .aurelia-table-tabs {
        gap: 0;
        margin-bottom: 1rem;
    }

    .aurelia-table-tab-btn {
        padding: 0.75rem 1rem;
        font-size: 0.8rem;
    }

    .aurelia-table-search {
        flex-direction: column;
    }

    .aurelia-table th,
    .aurelia-table td {
        padding: 0.75rem 0.5rem;
        font-size: 0.85rem;
    }

    .aurelia-table-btn-show {
        padding: 0.4rem 0.8rem;
        font-size: 0.75rem;
    }

    .aurelia-table {
        font-size: 0.9rem;
    }

    /* Prosta wersja mobilna - ukryj niektóre kolumny */
    .aurelia-table thead {
        display: none;
    }

    .aurelia-table,
    .aurelia-table tbody,
    .aurelia-table tr,
    .aurelia-table td {
        display: block;
        width: 100%;
    }

    .aurelia-table tr {
        margin-bottom: 1rem;
        border: 1px solid #e9ecef00;
        padding: 1rem;
        background-color: #ffffff;
    }

    .aurelia-table th,
    .aurelia-table td {
        padding: 2px 8px;
    }

    .aurelia-table td {
        padding: 0.5rem 0;
        border: none;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .aurelia-table td::before {
        content: attr(data-label);
        font-weight: 600;
        color: #495057;
        text-transform: uppercase;
        font-size: 0.75rem;
        flex: 1;
    }

    .aurelia-table td:last-child {
        margin-top: 0.5rem;
        padding-top: 1rem;
        border-top: 1px solid #e9ecef;
    }
}

/* ==================== FILTER FORM STYLES ==================== */
.filter-form {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.filter-row {
    display: flex;
    align-items: stretch;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-group {
    flex: 1;
    min-width: 180px;
    display: flex;
    flex-direction: column;
}

.filter-group button.btn-search {
    height: 100%;
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    white-space: normal;
}

.filter-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #495057;
}

.filter-group select {
    width: 100%;
    padding: 0.75rem 12px;
    border: 1px solid var(--color-palette-2);
    border-radius: 4px;
    font-size: 0.9rem;
    margin: 0;
    color: var(--color-palette-2);
}

.filter-group select:focus {
    border-color: var(--color-palette-1);
    outline: none;
    box-shadow: 0 0 0 0.2rem rgba(5, 51, 112, 0.25);
}

.btn-search {
    background: var(--color-palette-1);
    color: white;
    border: none;
    padding: 0.85rem 2rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.3s ease;
    width: 100%;
}

.btn-search:hover {
    background: #042859;
}

.filter-form .btn-light:not(:disabled):not(.disabled).active,
.filter-form .btn-light:not(:disabled):not(.disabled):active,
.filter-form .show>.btn-light.dropdown-toggle {
    color: #5d3330 !important;
    background-color: #e8e8e800 !important;
}

.bootstrap-select>.dropdown-toggle {
    width: 180px !important;
}

.filter-group:not(:nth-last-child(-n+2)) {
    flex: 1;
    min-width: 180px;
}

/* ==================== FILTER FORM RESPONSIVE ==================== */

@media (max-width: 768px) {

    .liveplan-price-history {
        margin-left: 0px;
        display: inline-block;
        float: right;
        margin-top: 20px;
    }

    .filter-form {
        padding: 1.5rem;
    }

    .filter-row {
        flex-direction: column;
    }

    .filter-group {
        min-width: 100%;
        width: 100%;
    }

    .filter-group:not(:nth-last-child(-n+2)) {
        border: none !important;
    }

    .bootstrap-select>.dropdown-toggle {
        width: 100% !important;
        font-size: 16px;
        font-weight: 500;
        color: #000 !important;
        background: 0 0;
        padding: 10px 20px;
        border: 1px solid #e0e0e0;
        border-radius: 0;
        -webkit-box-shadow: none !important;
        box-shadow: none !important;
    }

    /* ==================== TABLE RANGE SLIDERS ==================== */

    /* HTML range sliders dla wyszukiwarki tabelarycznej */
    .range-slider {
        -webkit-appearance: none;
        appearance: none;
        width: 100%;
        height: 6px;
        background: transparent;
        cursor: pointer !important;
        cursor: hand !important;
        pointer-events: auto !important;
        position: relative;
        z-index: 5;
    }

    .range-slider::-webkit-slider-thumb {
        -webkit-appearance: none;
        appearance: none;
        width: 24px;
        height: 24px;
        border-radius: 50%;
        background: white !important;
        border: 3px solid #5D3334 !important;
        cursor: pointer !important;
        cursor: hand !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
        pointer-events: auto !important;
        transition: all 0.3s ease;
    }

    .range-slider::-webkit-slider-thumb:hover {
        transform: scale(1.15);
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25), 0 0 0 8px rgba(93, 51, 52, 0.15) !important;
    }

    .range-slider::-webkit-slider-thumb:active {
        cursor: grabbing;
        transform: scale(1.05);
    }

    .range-slider::-moz-range-thumb {
        width: 24px;
        height: 24px;
        border-radius: 50%;
        background: white !important;
        border: 3px solid #5D3334 !important;
        cursor: pointer !important;
        cursor: hand !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
        pointer-events: auto !important;
        transition: all 0.3s ease;
    }

    .range-slider::-moz-range-thumb:hover {
        transform: scale(1.15);
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25), 0 0 0 8px rgba(93, 51, 52, 0.15) !important;
    }

    .range-slider::-moz-range-thumb:active {
        cursor: grabbing;
        transform: scale(1.05);
    }

    .range-slider::-webkit-slider-runnable-track {
        background: transparent;
        height: 6px;
        border: none;
    }

    .range-slider::-moz-range-track {
        background: transparent;
        border: none;
    }

    .range-slider-min,
    .range-slider-max {
        position: absolute !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        height: 6px !important;
        pointer-events: none !important;
    }

    .range-slider-min {
        pointer-events: auto !important;
        z-index: 5 !important;
    }

    .range-slider-max {
        pointer-events: auto !important;
        z-index: 4 !important;
    }

    .range-track {
        pointer-events: none !important;
    }

    .range-fill {
        pointer-events: none !important;
    }

    .table-filter-slider-container {
        display: flex;
        flex-wrap: wrap;
        gap: 20px;
        margin-bottom: 20px;
    }

    .table-filter-slider-wrapper {
        flex: 1;
        min-width: 200px;
    }

    .table-filter-slider-label {
        display: block;
        margin-bottom: 10px;
        font-weight: 600;
        color: var(--color-palette-2);
        font-size: 14px;
    }

    .range-slider-container {
        position: relative;
        height: 40px;
        margin: 10px 0;
    }

    .btn-search {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
}

/* ==================== PROPERTY TOOLTIPS ==================== */
.liveplan-tooltips-wrapper {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 15px 0;
}

.liveplan-tooltips-wrapper .wiersz {
    margin: 0;
}

.price-tooltip-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 12px;
    background: rgba(203, 187, 159, 0.1);
    border-radius: 4px;
    transition: all 0.2s ease;
    position: relative;
}

.price-tooltip-trigger:hover {
    background: rgba(203, 187, 159, 0.2);
    transform: translateY(-2px);
}

.price-tooltip-trigger .opis {
    font-size: 12px;
    color: var(--text-dark);
    white-space: nowrap;
    line-height: 1.3;
}

.price-tooltip-trigger svg {
    width: 20px;
    height: 20px;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.price-tooltip-trigger:hover svg {
    opacity: 1;
}

/* Tooltip styles for price tooltip trigger */
.liveplan-price-tooltip {
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
    z-index: 10000;
    font-size: 12px;
}

.liveplan-price-tooltip table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.liveplan-price-tooltip thead {
    background: var(--color-palette-2);
    color: white;
}

.liveplan-price-tooltip th {
    padding: 8px 6px;
    text-align: left;
    font-weight: 600;
    border: 1px solid #ddd;
}

.liveplan-price-tooltip td {
    padding: 8px 6px;
    border: 1px solid #eee;
}

.liveplan-price-tooltip tbody tr:nth-child(odd) {
    background: #f9f9f9;
}

.liveplan-price-tooltip tbody tr:hover {
    background: #f0f0f0;
}

.liveplan-price-tooltip .nr-column,
.liveplan-price-tooltip .floor-column {
    font-weight: 600;
    color: var(--color-palette-2);
}

.liveplan-price-tooltip .area-column,
.liveplan-price-tooltip .price-column,
.liveplan-price-tooltip .value-column {
    text-align: right;
    font-weight: 500;
}

.liveplan-popup-tooltip {
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 12px;
    max-width: 600px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
    z-index: 10001;
}

.liveplan-popup-tooltip table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.liveplan-popup-tooltip thead {
    background: var(--color-palette-2);
    color: white;
}

.liveplan-popup-tooltip th {
    padding: 8px 6px;
    text-align: left;
    font-weight: 600;
    border: 1px solid #ddd;
}

.liveplan-popup-tooltip td {
    padding: 8px 6px;
    border: 1px solid #eee;
}

.liveplan-popup-tooltip tbody tr:nth-child(odd) {
    background: #f9f9f9;
}

.liveplan-popup-tooltip tbody tr:hover {
    background: #f0f0f0;
}

.liveplan-popup-tooltip .nr-column,
.liveplan-popup-tooltip .floor-column {
    font-weight: 600;
    color: var(--color-palette-2);
}

.liveplan-popup-tooltip .area-column,
.liveplan-popup-tooltip .price-column,
.liveplan-popup-tooltip .value-column {
    text-align: right;
    font-weight: 500;
}

/* ==================== LOKATORSKI TOOLTIPS (TENANT CELLS, PARKING, PRICE HISTORY) ==================== */
.lokatorski-tooltip-popup {
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 12px;
    max-width: 600px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
    z-index: 10001;
}

.lokatorski-tooltip-popup table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.lokatorski-tooltip-popup thead {
    background: var(--color-palette-2);
    color: white;
}

.lokatorski-tooltip-popup th {
    padding: 8px 6px;
    text-align: left;
    font-weight: 600;
    border: 1px solid #ddd;
}

.lokatorski-tooltip-popup td {
    padding: 8px 6px;
    border: 1px solid #eee;
}

.lokatorski-tooltip-popup tbody tr:nth-child(odd) {
    background: #f9f9f9;
}

.lokatorski-tooltip-popup tbody tr:hover {
    background: #f0f0f0;
}

.lokatorski-tooltip-popup .nr-column,
.lokatorski-tooltip-popup .floor-column {
    font-weight: 600;
    color: var(--color-palette-2);
}

.lokatorski-tooltip-popup .area-column,
.lokatorski-tooltip-popup .price-column,
.lokatorski-tooltip-popup .value-column {
    text-align: right;
    font-weight: 500;
}

.lokatorski-tooltip-popup .date-column {
    text-align: left;
    color: #999;
    font-size: 11px;
}

.spotkanie:hover {
    background: #635554;
    color: #fff
}