/* ============================================
   infoContentor - Estilos Comuns
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
    min-height: 100vh;
}

/* ========== AVISO DE CONTINGÊNCIA ========== */
.contingency-banner {
    background-color: #fff3e0;
    color: #c67c00;
    text-align: center;
    padding: 10px;
    font-size: 0.85rem;
    font-weight: 600;
    border-bottom: 2px solid #ffd966;
    position: relative;
    z-index: 1;
}

.contingency-banner u {
    color: #b45f06;
}

/* ========== VERSÃO DESKTOP - COM IMAGEM DE FUNDO ========== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

/* Imagem de fundo */
.hero-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.hero-background img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 30%;
}

/* Fallback para navegadores antigos */
@supports not (object-fit: cover) {
    .hero-background {
        background-size: cover;
        background-position: center 30%;
        background-repeat: no-repeat;
    }
    .hero-background img {
        display: none;
    }
}

/* Fallback específico para cada página */
body.pesquisa .hero-background {
    background-image: url('../images/contentores.jpg');
}

body.naoencontrado .hero-background {
    background-image: url('../images/contentores_naoencontrado.png');
    background-position: center;
}

/* ========== CARD PRINCIPAL ========== */
.card {
    max-width: 550px;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    padding: 30px 25px 35px;
    transition: all 0.3s ease;
    backdrop-filter: blur(2px);
}

/* Título */
.title {
    color: #005b9c;
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.subtitle {
    color: #4a6a8a;
    text-align: center;
    margin-bottom: 30px;
    font-size: 1rem;
}

/* ========== FORMULÁRIO DE PESQUISA ========== */
.search-form {
    display: flex;
    border: 2px solid #e0e4e8;
    border-radius: 50px;
    overflow: hidden;
    background: white;
    transition: border-color 0.2s;
}

.search-form:focus-within {
    border-color: #005b9c;
}

.search-input {
    flex: 1;
    padding: 14px 20px;
    border: none;
    font-size: 1rem;
    outline: none;
    font-family: inherit;
}

.search-button {
    background: #005b9c;
    border: none;
    padding: 0 25px;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-button:hover {
    background: #004a7c;
}

.search-button:disabled {
    background: #6c8eae;
    cursor: wait;
}

.search-button svg {
    width: 22px;
    height: 22px;
    fill: white;
}

/* ========== SUPORTE ========== */
.support {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #eef2f5;
    color: #6c86a0;
    font-size: 0.85rem;
}

.support svg {
    flex-shrink: 0;
}

/* ========== RODAPÉ ========== */
.footer {
    text-align: center;
    font-size: 0.7rem;
    color: #8ba0b5;
    margin-top: 25px;
}

/* ========== MENSAGEM DE ERRO ========== */
.message {
    text-align: center;
    margin-bottom: 25px;
    color: #4a627a;
    line-height: 1.5;
}

.message a {
    color: #005b9c;
    text-decoration: underline;
}

/* ========== MEDIA QUERIES PARA TELEMÓVEL ========== */
@media (max-width: 768px) {
    /* Remove o fundo em telemóvel */
    .hero-background {
        display: none;
    }
    
    /* Altera o fundo do body para cor sólida */
    body {
        background-color: #f0f4f8;
    }
    
    /* Adiciona espaçamento no topo */
    .hero {
        min-height: auto;
        padding: 15px 0 0 0;
        align-items: flex-start;
    }
    
    /* Card sem transparência e com espaçamento */
    .card {
        background: white;
        backdrop-filter: none;
        margin-top: 0;
        border-radius: 16px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        padding: 20px 18px 25px;
    }
    
    .title {
        font-size: 2rem;
    }
    
    .search-input {
        padding: 12px 15px;
        font-size: 0.95rem;
    }
    
    .search-button {
        padding: 0 18px;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 10px 0 0 0;
    }
    
    .card {
        padding: 18px 15px 22px;
        border-radius: 16px;
    }
    
    .title {
        font-size: 1.8rem;
    }
    
    .subtitle {
        margin-bottom: 20px;
        font-size: 0.9rem;
    }
    
    .search-input {
        padding: 10px 12px;
        font-size: 0.9rem;
    }
    
    .support {
        margin-top: 20px;
        padding-top: 15px;
    }
}
.contingency-banner {
        background: linear-gradient(135deg, #ff6b6b 0%, #ff4757 100%);
        color: white;
        padding: 12px 20px;
        position: sticky;
        top: 0;
        z-index: 1000;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
        animation: slideDown 0.5s ease-out;
    }
    
    .contingency-content {
        max-width: 1200px;
        margin: 0 auto;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 12px;
        flex-wrap: wrap;
    }
    
    .contingency-icon {
        font-size: 20px;
        animation: pulse 1.5s infinite;
    }
    
    .contingency-text {
        font-size: 14px;
        letter-spacing: 0.5px;
    }
    
    .contingency-text strong {
        font-weight: 700;
        text-transform: uppercase;
    }
    
    .contingency-close {
        background: rgba(255,255,255,0.2);
        border: none;
        color: white;
        cursor: pointer;
        font-size: 16px;
        width: 24px;
        height: 24px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
    }
    
    .contingency-close:hover {
        background: rgba(255,255,255,0.3);
        transform: scale(1.1);
    }
    
    @keyframes slideDown {
        from {
            transform: translateY(-100%);
            opacity: 0;
        }
        to {
            transform: translateY(0);
            opacity: 1;
        }
    }
    
    @keyframes pulse {
        0%, 100% {
            transform: scale(1);
        }
        50% {
            transform: scale(1.1);
        }
    }
    
    @media (max-width: 768px) {
        .contingency-text {
            font-size: 12px;
        }
        .contingency-icon {
            font-size: 16px;
        }
    }