/**
 * Mapa Regiões do Brasil - CSS
 * Sistema de Regiões para HTML5 Maps Plugin
 */

.map-regions-container {
    max-width: 100%;
    margin: 0;
}

.region-buttons-wrapper {
    background: transparent;
    padding: 0;
    box-shadow: none;
    margin: 0;
}

.region-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Botão com quadrado colorido à esquerda */
.region-btn {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    padding: 12px 15px;
    border: none;
    border-radius: 8px;
    background: #ffffff;
    cursor: pointer;
    transition: box-shadow 0.2s ease;
    font-family: inherit;
    width: 280px;
    height: 55px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.region-btn:hover {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.region-btn-active,
.region-btn-selected {
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.18);
}

/* Quadrado colorido ao lado do nome */
.region-color-box {
    width: 28px;
    height: 28px;
    border-radius: 5px;
    flex-shrink: 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.region-name {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    text-align: left;
}

/* Modal */
.mrb-modal {
    display: none;
    position: fixed;
    z-index: 999999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    animation: fadeIn 0.3s ease;
}

.mrb-modal.show {
    display: block;
}

.mrb-modal-content {
    background-color: #ffffff;
    margin: 5% auto;
    padding: 50px 30px 30px 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    position: relative;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    animation: slideDown 0.3s ease;
    display: flex;
    flex-direction: column;
}

.mrb-modal-close {
    color: #999;
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
    z-index: 10;
}

.mrb-modal-close:hover,
.mrb-modal-close:focus {
    color: #333;
}

#mrb-modal-body {
    font-size: 16px;
    line-height: 1.8;
    color: #555;
    overflow-y: auto;
    max-height: calc(80vh - 80px);
    padding-right: 10px;
}

#mrb-modal-body::-webkit-scrollbar {
    width: 8px;
}

#mrb-modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

#mrb-modal-body::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

#mrb-modal-body::-webkit-scrollbar-thumb:hover {
    background: #555;
}

#mrb-modal-body p {
    margin-bottom: 15px;
}

#mrb-modal-body h1,
#mrb-modal-body h2,
#mrb-modal-body h3 {
    margin-top: 0;
    margin-bottom: 15px;
}

/* Animações */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Responsividade */
@media (max-width: 768px) {
    .region-buttons {
        gap: 10px;
    }

    .region-btn {
        width: 100%;
        max-width: 280px;
    }

    .region-color-box {
        width: 24px;
        height: 24px;
    }

    .region-name {
        font-size: 15px;
    }
    
    .mrb-modal-content {
        width: 95%;
        margin: 10% auto;
        padding: 50px 20px 20px 20px;
        max-height: 85vh;
    }
    
    #mrb-modal-body {
        max-height: calc(85vh - 70px);
    }
}