/* Estilos para o modal de notícias */
.noticia-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
    animation-name: fadeIn;
    animation-duration: 0.4s;
}

.noticia-modal-content {
    position: relative;
    background-color: var(--modal-noticia-color, #fff);
    margin: 10% auto;
    padding: 20px;
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    overflow-y: auto;
    border-radius: 10px;
    box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
    animation-name: slideIn;
    animation-duration: 0.4s;
}

.noticia-close {
    position: absolute;
    top: 10px;
    right: 15px;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1;
}

.noticia-close:hover,
.noticia-close:focus {
    color: #000;
    text-decoration: none;
}

.noticia-header {
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
    margin-bottom: 15px;
}

.noticia-title {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 24px;
    font-weight: bold;
    padding-right: 30px; /* Espaço para o botão fechar */
}

.noticia-image {
    width: 100%;
    max-height: 400px;
    object-fit: contain;
    margin-bottom: 15px;
    border-radius: 5px;
}

.noticia-content {
    line-height: 1.6;
    font-size: 16px;
    color: #333;
}

.noticia-content p {
    margin-bottom: 15px;
}

.noticia-footer {
    margin-top: 20px;
    padding-top: 10px;
    border-top: 1px solid #eee;
    text-align: right;
}

.noticia-source {
    font-size: 14px;
    color: #666;
}

.noticia-back-button {
    display: inline-block;
    padding: 8px 16px;
    background-color: var(--pwa-button-color, #007bff); /* Usa a mesma cor do botão do APP */
    color: var(--text-color, white); /* Usa a mesma cor do texto configurada */
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    margin-top: 10px;
}

.noticia-back-button:hover {
    background-color: #0056b3;
}

.noticia-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 0;
    height: 200px;
}

.noticia-loading img {
    animation: pulse 1.5s infinite ease-in-out;
}

.noticia-loading p {
    margin-top: 15px;
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

@keyframes pulse {
    0% { opacity: 0.6; transform: scale(0.95); }
    50% { opacity: 1; transform: scale(1.05); }
    100% { opacity: 0.6; transform: scale(0.95); }
}

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

@keyframes slideIn {
    from {top: -300px; opacity: 0}
    to {top: 0; opacity: 1}
}

/* Responsividade */
@media screen and (max-width: 600px) {
    .noticia-modal-content {
        margin: 5% auto;
        width: 95%;
        max-height: 90vh;
    }
    
    .noticia-title {
        font-size: 20px;
    }
    
    .noticia-content {
        font-size: 14px;
    }
}