/* ====================================================================
   Trânsito e Segurança - Padrão Dark Glow Moderno (Mobile First)
   ==================================================================== */

:root {
    --primary: #0284c7;
    --primary-dark: #0369a1;
    --accent: #38bdf8;
    --bg-color: #0f172a;
    --card-bg: rgba(30, 41, 59, 0.75);
    --card-hover: rgba(30, 41, 59, 0.95);
    --border-color: rgba(56, 189, 248, 0.2);
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --glow: rgba(56, 189, 248, 0.15);
    --radius: 16px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
    background-color: var(--bg-color) !important;
    color: var(--text-main) !important;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    padding: 0;
}

/* Efeitos de Luz de Fundo (Glow Background) */
.bg-glow-1 {
    position: fixed;
    top: -100px;
    left: -100px;
    width: 350px;
    height: 350px;
    background: rgba(2, 132, 199, 0.22);
    filter: blur(120px);
    border-radius: 50%;
    z-index: 0;
    pointer-events: none;
}

.bg-glow-2 {
    position: fixed;
    top: 30%;
    right: -100px;
    width: 400px;
    height: 400px;
    background: rgba(56, 189, 248, 0.15);
    filter: blur(150px);
    border-radius: 50%;
    z-index: 0;
    pointer-events: none;
}

header, main, footer {
    position: relative;
    z-index: 10;
}

/* --- BANNER DA PÁGINA (HERO) --- */
.header-transito {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(2, 132, 199, 0.25) 100%) !important;
    border-bottom: 1px solid var(--border-color);
    padding: 36px 16px;
    margin-bottom: 24px;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    text-align: center;
    position: relative;
}

.btn-voltar-premium {
    position: absolute;
    top: 20px;
    left: 20px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    padding: 6px 12px;
    border-radius: 9999px;
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-voltar-premium:hover {
    color: var(--accent);
    border-color: var(--accent);
    background: rgba(30, 41, 59, 0.9);
    transform: translateX(-4px);
    box-shadow: 0 6px 20px var(--glow);
}

.header-transito h1 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 15px 0 8px 0;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, #ffffff 0%, #38bdf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.3;
}

.header-transito p {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0 auto;
    max-width: 750px;
}

/* --- CONTAINER PRINCIPAL --- */
.main-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 16px 40px 16px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* --- SEÇÕES / CARDS --- */
.card-secao {
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.card-secao:hover {
    border-color: rgba(56, 189, 248, 0.5);
    background: var(--card-hover);
    box-shadow: 0 15px 35px rgba(2, 132, 199, 0.2);
}

.card-secao h2 {
    font-size: 1.25rem;
    color: var(--text-main);
    margin-top: 0;
    margin-bottom: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-secao h2 i {
    color: var(--accent);
    font-size: 1.1rem;
    background: rgba(2, 132, 199, 0.15);
    padding: 10px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
}

.card-secao p {
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 12px;
    font-size: 0.88rem;
}

.card-secao strong {
    color: var(--text-main);
}

/* --- ALERTA DE PROIBIÇÃO CUSTOMIZADO --- */
.alerta-proibido {
    background: rgba(220, 38, 38, 0.1);
    border: 1px solid rgba(220, 38, 38, 0.3);
    border-radius: 12px;
    padding: 18px;
    margin-top: 14px;
    margin-bottom: 14px;
}

.alerta-proibido h3 {
    font-size: 1.05rem;
    color: #fca5a5;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
}

.alerta-proibido h3 i {
    color: #ef4444;
}

.alerta-proibido p {
    color: #f1f5f9;
    margin: 0;
    font-size: 0.88rem;
}

/* --- GRID DE TELEFONES DE EMERGÊNCIA (MOBILE FIRST: 1 COLUNA) --- */
.grid-emergencia {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-top: 16px;
}

.item-emergencia {
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.3s ease;
}

.item-emergencia:hover {
    transform: translateY(-3px);
    background: rgba(30, 41, 59, 0.95);
    box-shadow: 0 10px 25px var(--glow);
    border-color: rgba(56, 189, 248, 0.5);
}

.item-emergencia h3 {
    font-size: 1.05rem;
    color: var(--text-main);
    margin: 0 0 8px 0;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.item-emergencia h3 i {
    color: var(--accent);
    font-size: 1rem;
}

.item-emergencia span {
    font-size: 0.86rem;
    color: var(--text-muted);
    line-height: 1.4;
    margin-bottom: 12px;
}

/* --- BOTÕES DE LIGAR NOS CARDS DE EMERGÊNCIA --- */
.btn-ligar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #ffffff;
    text-decoration: none;
    padding: 10px 18px;
    border-radius: 9999px;
    font-weight: 600;
    font-size: 0.85rem;
    box-shadow: 0 8px 20px rgba(2, 132, 199, 0.3);
    transition: all 0.3s ease;
}

.btn-ligar:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(2, 132, 199, 0.5);
}

/* --- RODAPÉ --- */
.footer-portal {
    width: 100%;
    background-color: #0b1329 !important;
    color: var(--text-muted) !important;
    border-top: 1px solid var(--border-color);
    margin-top: 40px;
    text-align: center;
    padding: 20px;
    font-size: 0.85rem;
}

/* ==========================================================================
   BREAKPOINTS: EXPANSÃO PARA TABLETS E DESKTOPS (min-width)
   ========================================================================== */

@media screen and (min-width: 768px) {
    .header-transito {
        padding: 40px 24px;
    }

    .header-transito h1 {
        font-size: 2.1rem;
    }

    .main-container {
        padding: 0 24px 60px 24px;
        gap: 30px;
    }

    .card-secao {
        padding: 32px;
    }

    .card-secao h2 {
        font-size: 1.4rem;
    }

    .card-secao p {
        font-size: 1rem;
    }

    .grid-emergencia {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }

    .item-emergencia {
        padding: 24px;
    }
}