/* Estilos para Página de Notícias */

/* Seção Hero com Título */
.news-hero {
    background: linear-gradient(135deg, #1e3a8a 0%, #0ea5e9 100%);
    padding: 3rem 1rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.news-title-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Título Principal */
.news-title {
    font-size: 4rem;
    font-weight: 900;
    color: white;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    letter-spacing: 3px;
    margin: 0;
    z-index: 2;
    position: relative;
    animation: slideInDown 0.8s ease-out;
}

/* Título Espelhado (Efeito Mirror) */
.news-title-mirror {
    position: absolute;
    font-size: 4rem;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.15);
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    letter-spacing: 3px;
    margin: 0;
    transform: scaleX(-1) scaleY(-1);
    z-index: 1;
    animation: slideInUp 0.8s ease-out;
}

/* Animações */
@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Seção de Notícias */
.news-section {
    padding: 2rem 0;
}

/* Feed de Notícias */
.news-feed {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Card de Notícia */
.news-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    animation: fadeInUp 0.6s ease-out;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* Imagem da Notícia */
.news-card-image {
    width: 100%;
    height: 300px;
    object-fit: cover;
    background: linear-gradient(135deg, #1e3a8a 0%, #0ea5e9 100%);
}

/* Conteúdo da Notícia */
.news-card-content {
    padding: 2rem;
}

.news-card-date {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.news-card-date::before {
    content: "📅";
}

.news-card-author {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.news-card-author::before {
    content: "✍️";
}

.news-card-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1e3a8a;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.news-card-excerpt {
    font-size: 1rem;
    color: #4b5563;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

/* Ações da Notícia */
.news-card-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.btn-read-more {
    background: linear-gradient(135deg, #1e3a8a 0%, #0ea5e9 100%);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.btn-read-more:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.3);
}

.btn-edit {
    background: #10b981;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    display: none;
}

.btn-edit:hover {
    background: #059669;
    transform: scale(1.05);
}

.btn-delete {
    background: #ef4444;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    display: none;
}

.btn-delete:hover {
    background: #dc2626;
    transform: scale(1.05);
}

/* Modo Admin */
body.admin-mode .btn-edit,
body.admin-mode .btn-delete {
    display: inline-block;
}

/* Mensagem sem Notícias */
.no-news-message {
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.no-news-message p {
    font-size: 1.2rem;
    color: #6b7280;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    position: relative;
    animation: slideUp 0.3s ease-out;
}

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

.close-modal {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 2rem;
    cursor: pointer;
    color: #6b7280;
    transition: color 0.3s ease;
}

.close-modal:hover {
    color: #1f2937;
}

.modal-content h2 {
    color: #1e3a8a;
    margin-bottom: 1.5rem;
}

/* Formulário */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #0ea5e9;
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

/* Botões */
.btn-save,
.btn-cancel {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-right: 0.5rem;
}

.btn-save {
    background: #10b981;
    color: white;
}

.btn-save:hover {
    background: #059669;
    transform: scale(1.05);
}

.btn-cancel {
    background: #e5e7eb;
    color: #1f2937;
}

.btn-cancel:hover {
    background: #d1d5db;
}

/* Modal Login */
.modal-login {
    max-width: 400px;
}

/* Admin Bar */
.admin-bar {
    background: #1e3a8a;
    color: white;
    padding: 1rem;
    text-align: center;
    display: none;
    gap: 1rem;
    justify-content: center;
    align-items: center;
}

.admin-bar.active {
    display: flex;
}

.btn-add-news {
    background: #10b981;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-add-news:hover {
    background: #059669;
    transform: scale(1.05);
}

.btn-logout {
    background: #ef4444;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-logout:hover {
    background: #dc2626;
    transform: scale(1.05);
}

/* Responsividade - Tablet */
@media (max-width: 768px) {
    .news-title,
    .news-title-mirror {
        font-size: 2.5rem;
    }

    .news-card-title {
        font-size: 1.5rem;
    }

    .news-card-image {
        height: 250px;
    }

    .news-card-content {
        padding: 1.5rem;
    }
}

/* Responsividade - Mobile */
@media (max-width: 600px) {
    .news-hero {
        padding: 2rem 1rem;
    }

    .news-title-container {
        height: 80px;
    }

    .news-title,
    .news-title-mirror {
        font-size: 1.8rem;
        letter-spacing: 2px;
    }

    .news-card-image {
        height: 200px;
    }

    .news-card-content {
        padding: 1rem;
    }

    .news-card-title {
        font-size: 1.3rem;
    }

    .news-card-excerpt {
        font-size: 0.95rem;
    }

    .news-card-actions {
        flex-direction: column;
        width: 100%;
    }

    .btn-read-more,
    .btn-edit,
    .btn-delete {
        width: 100%;
        text-align: center;
    }

    .modal-content {
        width: 95%;
        padding: 1.5rem;
    }

    .admin-bar {
        flex-direction: column;
        gap: 0.5rem;
    }

    .btn-add-news,
    .btn-logout {
        width: 100%;
    }
}

/* Animação Fade In Up */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
