/* =========================================================
   ESTILOS DE NOTÍCIAS (LISTA, DETALHE E FORMULÁRIO DO ADMIN)
   ========================================================= */

.noticias-lista-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 22px;
}

.noticias-lista-header h1 {
  margin: 0;
  color: var(--phi-text);
  font-size: 26px;
}

.noticias-vazio {
  color: var(--phi-text-muted);
}

.noticias-lista {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.noticia-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.noticia-item-conteudo {
  flex: 1;
  min-width: 240px;
}

.noticia-data {
  font-size: 12px;
  color: var(--phi-accent);
  font-weight: 600;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.noticia-item h2 {
  margin: 6px 0 8px;
  font-size: 19px;
}

.noticia-item h2 a {
  color: var(--phi-text);
  text-decoration: none;
}

.noticia-item h2 a:hover {
  color: var(--phi-accent);
}

.noticia-item p {
  color: var(--phi-text-muted);
  line-height: 1.55;
  margin: 0 0 10px;
}

.link-ver-todas {
  color: var(--phi-accent);
  font-weight: 600;
  text-decoration: none;
  font-size: 14px;
}

.link-ver-todas:hover {
  text-decoration: underline;
}

.noticia-item-acoes {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

.noticia-item-acoes form {
  margin: 0;
}

.btn-excluir {
  color: var(--phi-danger);
  border-color: var(--phi-danger);
}

.btn-excluir:hover {
  background: rgba(192, 57, 43, 0.10);
}

.noticias-paginacao {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 30px;
}

.noticias-paginacao-info {
  color: var(--phi-text-muted);
  font-size: 14px;
}

/* --- Detalhe da notícia --- */

.noticia-detalhe {
  max-width: 820px;
  margin: 0 auto;
}

.noticia-voltar {
  display: inline-block;
  margin-bottom: 18px;
}

.noticia-detalhe h1 {
  margin: 8px 0 20px;
  font-size: 26px;
  color: var(--phi-text);
}

.noticia-corpo {
  color: var(--phi-text);
  line-height: 1.75;
  font-size: 16px;
  white-space: pre-line;
}

.noticia-detalhe .noticia-item-acoes {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid var(--phi-border);
}

/* --- Formulário do admin --- */

.noticia-form-card {
  max-width: 760px;
  margin: 0 auto;
}

.noticia-form-card h1 {
  margin: 0 0 20px;
  font-size: 22px;
  color: var(--phi-text);
}

.noticia-form {
  display: flex;
  flex-direction: column;
}

.noticia-form label {
  font-weight: 600;
  color: var(--phi-text);
  margin: 14px 0 6px;
  font-size: 14px;
}

.noticia-form input[type="text"],
.noticia-form textarea {
  font-family: var(--phi-font);
  padding: 12px 16px;
  border-radius: 8px;
  border: 1px solid var(--phi-border);
  background-color: var(--phi-input-bg);
  color: var(--phi-text);
  font-size: 15px;
  resize: vertical;
}

.noticia-form input[type="text"]:focus,
.noticia-form textarea:focus {
  outline: none;
  border-color: var(--phi-accent);
  background-color: var(--phi-input-bg-focus);
}

.noticia-form-dica {
  margin: 8px 0 0;
  font-size: 12px;
  color: var(--phi-text-muted);
}

.noticia-form-acoes {
  display: flex;
  gap: 14px;
  margin-top: 24px;
}

@media (max-width: 600px) {
  .noticia-item {
    flex-direction: column;
  }

  .noticia-item-acoes {
    width: 100%;
  }

  .noticia-item-acoes .btn,
  .noticia-item-acoes form {
    flex: 1;
  }

  .noticia-item-acoes button {
    width: 100%;
  }
}
