/**
 * Project Sidewalk API Documentation - Raw Labels Component Styles
 *
 * This stylesheet contains styles specific to the Raw Labels component and works in conjunction with the main
 * api-docs.css file.
 */

/* ==========================================================================
   COMPONENT CONTAINERS
   ========================================================================== */

/* Uses the .map-container class from api-docs.css */
#raw-labels-preview {
    width: 100%;
    height: 500px;
    margin: var(--space-lg) 0;
    border: 1px solid var(--color-border-light);
    border-radius: var(--border-radius);
    overflow: hidden;
    position: relative;
}

#raw-labels-map {
    width: 100%;
    height: 100%;
}

/* ==========================================================================
   POPUP AND TOOLTIPS
   ========================================================================== */

/* Label popup - extends .map-popup class from api-docs.css */
.label-popup {
    max-width: 250px;
    padding: 2px;
}

.label-popup h4 {
    margin: 0 0 6px 0;
    font-size: var(--font-size-sm);
    border-bottom: 1px solid var(--color-border-light);
    padding-bottom: 4px;
}

.label-popup p {
    margin: 4px 0;
    font-size: var(--font-size-xs);
    line-height: 1.4;
}

/* ==========================================================================
   MAP CONTROLS AND LEGEND
   ========================================================================== */

/* Legend styling */
.info.legend {
    background-color: white;
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    max-width: 200px;
    max-height: 300px;
    overflow-y: auto;
}

.info.legend h4 {
    margin: 0 0 5px;
    font-size: var(--font-size-sm);
    font-weight: 600;
}

/* Region title */
.region-title {
    font-size: var(--font-size-sm);
    background-color: white;
    padding: 5px 10px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

/* Label count - could use .counter-badge from api-docs.css */
.label-count {
    font-size: var(--font-size-xs);
    background-color: white;
    padding: 5px 10px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    position: absolute;
    bottom: var(--space-sm);
    right: var(--space-sm);
    z-index: var(--z-index-dropdown);
}

/* ==========================================================================
   STATUS MESSAGES
   ========================================================================== */

/* Uses .message and .message-error classes from api-docs.css */
/* Uses .loading-message class from api-docs.css */

/* No labels message */
.no-labels-message {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: var(--space-sm) var(--space-lg);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    z-index: var(--z-index-dropdown);
}

/* ==========================================================================
   RESPONSIVE ADJUSTMENTS
   ========================================================================== */

@media (max-width: var(--breakpoint-sm)) {
    #raw-labels-preview {
        height: 400px;
    }

    .info.legend {
        max-width: 150px;
        font-size: var(--font-size-xs);
    }

    .label-popup {
        max-width: 200px;
    }
}
