/* Main Container */
.distribuidores-widget-container {
    max-width: 800px;
    margin: 0 auto;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

/* Custom Select Dropdown - Elementor controls will override these, but good defaults */
.custom-select-wrapper {
    position: relative;
    user-select: none;
    margin-bottom: 15px;
}

/* Temporarily disabled municipality filter
.municipio-select-wrapper {
    margin-top: 10px;
    border-top: 1px dashed #eee;
    padding-top: 15px;
}
*/

.custom-select {
    position: relative;
    display: flex;
    flex-direction: column;
}

.custom-select__trigger {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 15px;
    font-size: 16px;
    font-weight: 400;
    color: #333;
    height: 50px;
    line-height: 50px;
    background: #fff;
    cursor: pointer;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.custom-select__trigger:hover {
    border-color: #aaa;
}

.custom-options {
    position: absolute;
    display: block;
    top: 100%;
    left: 0;
    right: 0;
    border: 1px solid #ddd;
    border-top: 0;
    background: #fff;
    transition: all 0.3s;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 100;
    max-height: 250px;
    overflow-y: auto;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
}

.custom-select.open .custom-options {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
    margin-top: 5px;
    /* Spacing */
}

.custom-option {
    position: relative;
    display: block;
    padding: 10px 15px;
    font-size: 15px;
    font-weight: 300;
    color: #555;
    cursor: pointer;
    transition: all 0.2s;
}

.custom-option:hover,
.custom-option.selected {
    color: #000;
    background-color: #f5f5f5;
}

/* Arrow Icon */
.arrow-wrapper {
    display: inline-flex;
    /* Changed from flex to inline-flex to respect surrounding flow better */
    align-items: center;
    justify-content: center;
    aspect-ratio: 1 / 1;
    /* Force square aspect ratio */
    /* width/height removed to let padding/content dictate size, or Elementor controls */
    min-width: 20px;
    /* Kept min size */
    margin-left: 10px;
}

/* Pure CSS Arrow - Robust Solution */
/* Pure CSS Arrow - Robust Solution */
.simple-arrow {
    border: solid #888;
    border-width: 0 0.1em 0.1em 0;
    /* Proportional thickness */
    display: block;
    /* Behave as block inside flex item */
    width: 0.5em;
    /* Explicit square size */
    height: 0.5em;
    /* Explicit square size */
    transform: rotate(45deg);
    -webkit-transform: rotate(45deg);
    transition: all 0.2s;
    margin-top: -0.15em;
    /* Optical centering adjustment */
}

/* Ensure Elementor Color Control still works if possible, or fallback to border-color */
.custom-select__trigger .simple-arrow {
    border-color: inherit;
    /* This might need specific targeting from PHP if controls change 'color' on wrapper */
}




/* Results Styles - Elegant List */
.distribuidores-list {
    display: flex;
    flex-direction: column;
}

.distribuidor-item {
    background: #fff;
    padding: 25px 0;
    border-bottom: 1px solid #eaeaea;
    /* Light divider */
    transition: background-color 0.2s;
}

.distribuidor-item:last-child {
    border-bottom: none;
}

.distribuidor-title {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.3rem;
    font-weight: 600;
    color: #222;
    letter-spacing: -0.5px;
}

.distribuidor-details p {
    margin: 8px 0;
    font-size: 15px;
    color: #555;
    display: flex;
    align-items: center;
}

.distribuidor-details a {
    text-decoration: none;
    color: inherit;
    display: flex;
    /* Flexbox for alignment */
    align-items: center;
    /* Center vertically */
    transition: color 0.2s;
    line-height: 1.4;
}

.distribuidor-details a:hover {
    color: #000;
    text-decoration: none;
    /* Removed underline from whole block, maybe add border-bottom to text span if needed */
}

.distribuidor-icon {
    width: 20px;
    height: 20px;
    /* Fixed height */
    text-align: center;
    margin-right: 12px;
    color: #c97c36;
    /* Using the orange/brown color from your screenshot as default, or inherited */
    flex-shrink: 0;
    /* Prevent shrinking/clipping */
    display: flex;
    align-items: center;
    justify-content: center;
}

.distribuidor-icon svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
}

/* No results message */
.no-distribuidores {
    text-align: center;
    color: #777;
    padding: 40px 0;
    font-style: italic;
    background: #fafafa;
    border-radius: 4px;
}

/* Loading state */
.loading {
    text-align: center;
    padding: 30px;
}

/* Status Badges */
.status-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    border: 1px solid;
    line-height: 1;
    white-space: nowrap;
    align-self: flex-start;
}

.status-badge.open {
    color: #28a745;
    border-color: #28a745;
    background-color: rgba(40, 167, 69, 0.1);
}

.status-badge.closed {
    color: #dc3545;
    border-color: #dc3545;
    background-color: rgba(220, 53, 69, 0.1);
}

/* Skeleton Loading */
@keyframes skeleton-loading {
    0% {
        background-color: #f0f0f0;
    }

    50% {
        background-color: #e0e0e0;
    }

    100% {
        background-color: #f0f0f0;
    }
}

.distribuidor-skeleton {
    padding: 25px 0;
    border-bottom: 1px solid #eaeaea;
}

.skeleton-title {
    width: 60%;
    height: 24px;
    margin-bottom: 15px;
    border-radius: 4px;
    animation: skeleton-loading 1.5s infinite ease-in-out;
}

.skeleton-text {
    width: 80%;
    height: 16px;
    margin-bottom: 10px;
    border-radius: 4px;
    animation: skeleton-loading 1.5s infinite ease-in-out;
}

.skeleton-text:last-child {
    width: 40%;
}