/* ============================================
   EMERGENCIAS - DISEÑO LIMPIO SIN BORDES
   ============================================ */
.emergencias-section {
    padding: 3rem 0;
    background-color: #ffffff;
    border: none !important;
    border-top: none !important;
    border-bottom: none !important;
}

.emergencias-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.emergencias-header .section-title {
    margin-bottom: 0;
}

/* Grilla limpia sin marco ni bordes */
.emergencias-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.5rem;
    position: relative;
    border: none !important;
    border-radius: 0 !important;
    background: transparent !important;
    overflow: visible !important;
    box-shadow: none !important;
}

/* Item individual plano integrado al fondo sin bordes ni sombras */
.em-item,
.em-card {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    background: transparent !important;
    border-radius: 12px !important;
    padding: 0.75rem 0.5rem !important;
    gap: 0.75rem !important;
    text-decoration: none !important;
    color: inherit !important;
    border: none !important;
    border-right: none !important;
    border-bottom: none !important;
    box-shadow: none !important;
    position: relative !important;
    transition: transform 0.2s ease, background-color 0.2s ease !important;
    box-sizing: border-box !important;
    min-width: 0 !important;
}

.em-item:hover,
.em-card:hover {
    transform: translateY(-2px) !important;
    background: rgba(0, 51, 153, 0.03) !important;
}

/* Icon Wrapper */
.em-icon-wrapper,
.em-icon {
    width: 46px !important;
    height: 46px !important;
    min-width: 46px !important;
    min-height: 46px !important;
    max-width: 46px !important;
    max-height: 46px !important;
    border-radius: 12px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
    transition: transform 0.25s ease, background-color 0.25s ease !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}

.em-item:hover .em-icon-wrapper,
.em-card:hover .em-icon {
    transform: scale(1.06);
}

.em-icon-wrapper svg,
.em-icon svg,
.emergencias-section .em-icon-wrapper svg,
.emergencias-section .em-icon svg {
    width: 24px !important;
    height: 24px !important;
    min-width: 24px !important;
    min-height: 24px !important;
    max-width: 24px !important;
    max-height: 24px !important;
    display: block !important;
    flex-shrink: 0 !important;
}

/* Details */
.em-details,
.em-content {
    display: flex !important;
    flex-direction: column !important;
    flex-grow: 1 !important;
    min-width: 0 !important;
    overflow: hidden !important;
}

.em-title,
.em-content h3 {
    font-size: 0.82rem !important;
    font-weight: 600 !important;
    color: var(--texto-secundario, #64748b) !important;
    margin: 0 0 0.15rem 0 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.em-phone-num,
.em-number {
    font-size: 1.3rem !important;
    font-weight: 800 !important;
    color: var(--azul-institucional, #003399) !important;
    line-height: 1.1 !important;
    letter-spacing: -0.02em !important;
    display: block !important;
    white-space: nowrap !important;
}

/* Action Button */
.em-call-action {
    display: inline-flex !important;
    align-items: center !important;
    gap: 0.35rem !important;
    padding: 0.4rem 0.65rem !important;
    border-radius: 20px !important;
    font-size: 0.78rem !important;
    font-weight: 700 !important;
    background-color: rgba(0, 51, 153, 0.08) !important;
    color: var(--azul-institucional, #003399) !important;
    transition: all 0.2s ease !important;
    flex-shrink: 0 !important;
}

.em-item:hover .em-call-action {
    background-color: var(--azul-institucional, #003399) !important;
    color: #ffffff !important;
}

.em-phone-icon,
.em-call-action svg {
    width: 15px !important;
    height: 15px !important;
    min-width: 15px !important;
    min-height: 15px !important;
    max-width: 15px !important;
    max-height: 15px !important;
    display: inline-block !important;
    flex-shrink: 0 !important;
}

/* Responsividad Laptops & Media Screens (max-width: 1024px) */
@media (max-width: 1024px) {
    .emergencias-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 1.25rem !important;
    }
}

@media (max-width: 640px) {
    .emergencias-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
}

/* Colores por tipo de emergencia (SVG y Contenedor) */

/* Seguridad Ciudadana (956584049) */
.em-item--seguridad .em-icon-wrapper {
    background-color: rgba(243, 156, 18, 0.15) !important;
    color: #f39c12 !important;
}
.em-item--seguridad:hover .em-icon-wrapper {
    background-color: rgba(243, 156, 18, 0.25) !important;
}

/* Bomberos (132) */
.em-item--bomberos .em-icon-wrapper {
    background-color: rgba(231, 76, 60, 0.15) !important;
    color: #e74c3c !important;
}
.em-item--bomberos:hover .em-icon-wrapper {
    background-color: rgba(231, 76, 60, 0.25) !important;
}

/* Ambulancia SAMU (131) */
.em-item--ambulancia .em-icon-wrapper {
    background-color: rgba(2, 119, 189, 0.15) !important;
    color: #0277bd !important;
}
.em-item--ambulancia:hover .em-icon-wrapper {
    background-color: rgba(2, 119, 189, 0.25) !important;
}

/* Carabineros (133) */
.em-item--policia .em-icon-wrapper {
    background-color: rgba(46, 125, 50, 0.15) !important;
    color: #2e7d32 !important;
}
.em-item--policia:hover .em-icon-wrapper {
    background-color: rgba(46, 125, 50, 0.25) !important;
}
