/**
 * EAS ImageMap Enhancer - Status Styling
 * Colors for different unit statuses
 */

/* Свободен (Available) - Green */
.imp-object.unit-status-svoboden polygon,
.imp-object.unit-status-svoboden {
    /* fill: rgba(76, 175, 80, 0.5) !important; */
}

.imp-object.unit-status-svoboden:hover polygon,
.imp-object.unit-status-svoboden.imp-object-highlighted polygon {
    fill: rgba(76, 175, 80, 0.7) !important;
}

/* Резервиран (Reserved) - Orange */
.imp-object.unit-status-rezerviran polygon,
.imp-object.unit-status-rezerviran {
    fill: rgba(255, 152, 0, 0.5) !important;
}

.imp-object.unit-status-rezerviran:hover polygon,
.imp-object.unit-status-rezerviran.imp-object-highlighted polygon {
    fill: rgba(255, 152, 0, 0.7) !important;
}

/* Продаден (Sold) - Red */
.imp-object.unit-status-prodaden polygon,
.imp-object.unit-status-prodaden {
    fill: rgba(244, 67, 54, 0.5) !important;
}

.imp-object.unit-status-prodaden:hover polygon,
.imp-object.unit-status-prodaden.imp-object-highlighted polygon {
    fill: rgba(244, 67, 54, 0.7) !important;
}

/* Депозит (Deposit) - Yellow */
.imp-object.unit-status-depozit polygon,
.imp-object.unit-status-depozit {
    fill: rgba(255, 235, 59, 0.5) !important;
}

.imp-object.unit-status-depozit:hover polygon,
.imp-object.unit-status-depozit.imp-object-highlighted polygon {
    fill: rgba(255, 235, 59, 0.7) !important;
}

/* Fallback for units without status - Light gray */
.imp-object:not([data-unit-status]) polygon {
    /* Keep default Image Map Pro styling */
}

/* Optional: Add stroke/border for better visibility */
.imp-object[data-unit-status] polygon {
    stroke-width: 1px;
    stroke-opacity: 0.8;
}

.imp-object.unit-status-svoboden polygon {
    stroke: rgba(56, 142, 60, 1);
}

.imp-object.unit-status-rezerviran polygon {
    stroke: rgba(230, 126, 0, 1);
}

.imp-object.unit-status-prodaden polygon {
    stroke: rgba(211, 47, 47, 1);
}

.imp-object.unit-status-depozit polygon {
    stroke: rgba(245, 200, 0, 1);
}

/* ===========================================
   Status Text Labels Container
   =========================================== */

#eas-labels-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 0;
    overflow: visible;
    pointer-events: none;
    z-index: 99;
}

/* Base styles for all status labels */
.eas-status-label {
    position: absolute;
    transform: translate(-50%, -50%);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 6px;
    border-radius: 3px;
    white-space: nowrap;
    pointer-events: none;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Резервиран label - Orange */
.eas-status-label.eas-status-rezerviran {
    background-color: rgba(255, 152, 0, 0.95);
    color: #fff;
}

/* Продаден label - Red */
.eas-status-label.eas-status-prodaden {
    background-color: rgba(244, 67, 54, 0.95);
    color: #fff;
}

/* Депозит label - Yellow */
.eas-status-label.eas-status-depozit {
    background-color: rgba(255, 235, 59, 0.95);
    color: #333;
}

/* Свободен label - Green (shows unit name) */
.eas-status-label.eas-status-svoboden {
    background-color: rgba(76, 175, 80, 0.95);
    color: #fff;
}
