/*------------------------------------------------------------------
  apnep.css — ajustes do site sobre o template TechnoAI
  Carregado DEPOIS de styles.css (ver views/layouts/main.ejs).

  Regra de ouro: o styles.css do template NÃO se altera. Tudo o que for
  específico do apnep.pt vive aqui — nunca em <style> dentro das secções
  nem em style="" no HTML da BD.
-------------------------------------------------------------------*/


/*==================================================================
  1. Secções de equipa em fundo CLARO
  ------------------------------------------------------------------
  O template tem `.team h2 { color:#fff !important }`, pensado para as
  secções com fundo escuro (.section-gradient). Nas secções claras
  (.sections-bg) o título ficava branco sobre branco.
==================================================================*/
.team.sections-bg .section-header h2 { color: var(--theme-color) !important; }
.team.sections-bg .section-header p  { color: var(--color-primary); }


/*==================================================================
  2. Sidebar do blog / notícias
  ------------------------------------------------------------------
  `.footer-widget-heading h3` é branco (feito para o rodapé escuro).
  A .blog-sidbar tem fundo claro, logo os títulos desapareciam.
==================================================================*/
.blog-sidbar .footer-widget-heading h3 { color: var(--theme-color) !important; }
.blog-sidbar .list      { list-style: none; padding-left: 0; }
.blog-sidbar .list li   { margin-bottom: 10px; }
.blog-sidbar .list li a { color: var(--color-primary); }
.blog-sidbar .cat-count { opacity: .6; font-size: .9em; }
.blog-sidbar .active > a { font-weight: 700; text-decoration: underline; }


/*==================================================================
  3. Conteúdo HTML vindo da base de dados
  ------------------------------------------------------------------
  O texto das notícias (e de outras secções) é escrito no backoffice e
  usa <section>, <p>, <ul>, <strong>... O template tem regras GLOBAIS
  `section { padding:100px 0 }` e `section { background: var(--light-color) }`
  que fariam cada bloco ganhar 100px de espaço e fundo próprio.
==================================================================*/
.news-body section {
  padding: 0;
  background: none;
  overflow: visible;
  margin-bottom: 28px;
}
.news-body h2 { font-size: 28px; margin: 28px 0 12px; }
.news-body h3 { font-size: 22px; margin: 22px 0 10px; }
.news-body p  { margin-bottom: 16px; line-height: 1.8; }
.news-body ul,
.news-body ol { margin: 0 0 18px 20px; }
.news-body li { margin-bottom: 8px; }
.news-body img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 12px 0;
}
.news-body table { max-width: 100%; }
.news-body blockquote {
  border-left: 4px solid var(--theme-color);
  padding-left: 16px;
  font-style: italic;
  margin: 20px 0;
}


/*==================================================================
  4. Links de imprensa nas notícias
  ------------------------------------------------------------------
  Escritos no backoffice como {{Nome [[url]]}} e convertidos pelo
  plug_news em <a class="news-link"> dentro de <div class="news-links">.
==================================================================*/
.news-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 24px 0;
}
.news-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid var(--theme-color);
  border-radius: 30px;
  font-size: 14px;
  font-weight: 500;
  color: var(--theme-color);
  background: transparent;
  text-decoration: none;
  transition: all .3s ease;
}
.news-link:hover {
  background: var(--theme-color);
  color: #fff;
}
.news-link i { font-size: 13px; }


/*==================================================================
  5. Sidebar: categorias e outras notícias
  ------------------------------------------------------------------
  Texto mais pequeno que o corpo, com o ícone do template
  (bi-arrow-right-circle-fill) alinhado ao topo da linha.
==================================================================*/
.blog-sidbar h3 {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 15px;
  color: var(--theme-color);
}
.blog-sidbar hr { opacity: .15; margin: 25px 0; }

.blog-sidbar .sidbar-cats,
.blog-sidbar .sidbar-posts {
  list-style: none;
  padding-left: 0;
  margin-bottom: 0;
}
.blog-sidbar .sidbar-cats li,
.blog-sidbar .sidbar-posts li { margin-bottom: 10px; }

.blog-sidbar .sidbar-cats li a,
.blog-sidbar .sidbar-posts li a {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  color: var(--color-primary);
  line-height: 1.5;
  text-decoration: none;
  transition: color .3s ease;
}
.blog-sidbar .sidbar-cats li a i,
.blog-sidbar .sidbar-posts li a i {
  color: var(--theme-color);
  flex-shrink: 0;
  margin-top: 4px;
}
.blog-sidbar .sidbar-cats li a:hover,
.blog-sidbar .sidbar-posts li a:hover { color: var(--theme-color); }

/* categorias: texto mais pequeno */
.blog-sidbar .sidbar-cats li a  { font-size: 14px; }
/* outras notícias: ligeiramente maior que as categorias */
.blog-sidbar .sidbar-posts li a { font-size: 15px; }

.blog-sidbar .sidbar-cats li.active > a { font-weight: 700; }

/* miniaturas 3x3 */
.blog-sidbar .row img {
  aspect-ratio: 1 / 1;
  object-fit: cover;
  transition: transform .3s ease, opacity .3s ease;
}
.blog-sidbar .row img:hover { transform: scale(1.05); opacity: .85; }


/*==================================================================
  6. Formulário de contacto
==================================================================*/
/* honeypot anti-spam — fora do ecrã, nunca visível */
.hp-field {
  position: absolute !important;
  left: -9999px;
  height: 0;
  overflow: hidden;
}
.contact-information-box-3 .contact-info a { color: inherit; text-decoration: none; }
.contact-information-box-3 .contact-info a:hover { color: var(--theme-color); }
.contact-form .messages .alert { margin-top: 20px; }
.contact-form .form-note {
  margin-top: 14px;
  font-size: 13px;
  color: #6b7280;
  display: flex;
  align-items: flex-start;
  gap: 7px;
  line-height: 1.5;
}
.contact-form .form-note i { color: var(--theme-color); margin-top: 2px; }
.contact-form-box .alert { display: flex; align-items: flex-start; gap: 10px; }


/*==================================================================
  7. Notas de custo de chamada + contactos no rodapé/página
==================================================================*/
.footer-note {
  display: block;
  font-size: 11px;
  opacity: .65;
  margin-top: 2px;
  font-weight: 400;
  line-height: 1.3;
}
.footer-section .footer-widget-heading h3 { margin-top: 0; }
.footer-section .list li a i { margin-right: 6px; }

.contact-socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  margin-right: 8px;
  border-radius: 50%;
  border: 1px solid var(--theme-color);
  color: var(--theme-color);
  transition: all .3s ease;
}
.contact-socials a:hover { background: var(--theme-color); color: #fff; }


/*==================================================================
  8. Área de sócios e login
==================================================================*/
.socio-card {
  background: #fff;
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 16px;
  padding: 32px;
  box-shadow: 0 6px 24px rgba(0,0,0,.06);
}
.socio-card .socio-icon { font-size: 40px; color: var(--theme-color); display: block; margin-bottom: 14px; }
.socio-card hr { opacity: .1; margin: 24px 0; }

.socio-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px; border-radius: 30px;
  font-size: 14px; font-weight: 600;
}
.socio-badge.ok       { background: rgba(2,155,155,.12); color: var(--theme-color); }
.socio-badge.pendente { background: rgba(217,101,35,.12); color: #d96523; }

/* código de 6 dígitos */
.otp-group { display: flex; gap: 10px; justify-content: center; }
.otp-group .otp {
  width: 52px; height: 60px;
  text-align: center;
  font-size: 24px; font-weight: 600;
  padding: 0;
}
@media (max-width: 480px) {
  .otp-group { gap: 6px; }
  .otp-group .otp { width: 42px; height: 52px; font-size: 20px; }
}

/* numeração dos passos */
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; margin-right: 8px;
  border-radius: 50%;
  background: var(--theme-color); color: #fff;
  font-size: 15px; font-weight: 700;
}
.call-to-action .cta-tag {
  text-transform: uppercase; letter-spacing: 2px;
  font-size: 13px; opacity: .8; margin-bottom: 6px;
}
.socio-stats .stat-label {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .5px;
  opacity: .6;
  margin-bottom: 2px;
}
.socio-stats .stat-value {
  display: block;
  font-size: 22px;
  font-weight: 700;
  color: var(--theme-color);
  line-height: 1.2;
}
.socio-stats .stat-value.sm { font-size: 15px; font-weight: 500; color: var(--color-primary); }


/*==================================================================
  9. Área Pessoal (/area-pessoal)
==================================================================*/
.account-sidebar { position: sticky; top: 110px; }
.account-user { text-align: center; padding-bottom: 6px; }
.account-user img {
  width: 96px; height: 96px;
  object-fit: cover; border-radius: 50%;
  border: 3px solid var(--theme-color);
  margin-bottom: 12px;
}
.account-user h4 { font-size: 18px; margin-bottom: 2px; }
.account-user p  { font-size: 14px; opacity: .7; margin-bottom: 14px; word-break: break-all; }

.account-nav { list-style: none; padding-left: 0; margin-bottom: 0; }
.account-nav li { margin-bottom: 4px; }
.account-nav li a {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 14px; border-radius: 10px;
  color: var(--color-primary); font-size: 15px;
  text-decoration: none; transition: all .25s ease;
}
.account-nav li a i { color: var(--theme-color); font-size: 17px; }
.account-nav li a:hover { background: rgba(2,155,155,.08); }
.account-nav li a.active {
  background: var(--theme-color); color: #fff; font-weight: 600;
}
.account-nav li a.active i { color: #fff; }

.account-panel {
  background: #fff;
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 16px;
  padding: 28px;
  box-shadow: 0 6px 24px rgba(0,0,0,.05);
}
.account-panel .panel-title {
  font-size: 22px; margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--theme-color);
}

/* estados que o apnep-account.js emite */
.acc-loading { display: inline-flex; align-items: center; gap: 8px; opacity: .7; }
.acc-loading i { animation: acc-spin 1s linear infinite; }
@keyframes acc-spin { to { transform: rotate(360deg); } }
.acc-empty, .empty { opacity: .55; font-style: italic; }
.acc-error   { color: #c0392b; }
.acc-msg-ok  { color: var(--theme-color); font-weight: 600; }

.acc-badge {
  display: inline-block; padding: 4px 12px; border-radius: 20px;
  font-size: 12px; font-weight: 600;
}
.badge-green  { background: rgba(2,155,155,.14);  color: var(--theme-color); }
.badge-orange { background: rgba(217,101,35,.14); color: #d96523; }
.badge-red    { background: rgba(192,57,43,.12);  color: #c0392b; }
.badge-grey   { background: rgba(0,0,0,.07);      color: #666; }

/* modal de pagamento */
.acc-modal {
  position: fixed; inset: 0; z-index: 1080;
  background: rgba(0,0,0,.55);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.acc-modal-box {
  background: #fff; border-radius: 16px;
  max-width: 560px; width: 100%;
  max-height: 85vh; overflow-y: auto;
  padding: 30px; position: relative;
}
.acc-modal-close {
  position: absolute; top: 12px; right: 16px;
  background: none; border: 0; font-size: 28px; line-height: 1;
  cursor: pointer; opacity: .5;
}
.acc-modal-close:hover { opacity: 1; }

@media (max-width: 991px) {
  .account-sidebar { position: static; }
}
.comprov-box {
  margin-top: 28px; padding-top: 24px;
  border-top: 1px dashed rgba(0,0,0,.15);
}
.comprov-box h4 { font-size: 18px; margin-bottom: 8px; }
.comprov-box h4 i { color: var(--theme-color); margin-right: 6px; }
.comprov-box p { font-size: 14px; opacity: .75; margin-bottom: 16px; }
.comprov-lista { margin-top: 16px; }
.comprov-lista .alert { margin-bottom: 0; }
#uploadModal .acc-modal-box { max-width: 620px; }


/*==================================================================
  10. Área Pessoal — conteúdo dos separadores
==================================================================*/
/* botão do template em versão pequena, para ações dentro de listas */
.cta-btn.cta-sm {
  padding: 7px 16px;
  font-size: 13px;
  display: inline-flex; align-items: center; gap: 6px;
}
.acc-card-actions .cta-btn,
.acc-quota-accao .cta-btn { margin: 0 6px 6px 0; }

/* foto de perfil */
.acc-photo-row {
  display: flex; align-items: center; gap: 20px;
  padding-bottom: 22px; margin-bottom: 22px;
  border-bottom: 1px solid rgba(0,0,0,.08);
  flex-wrap: wrap;
}
.acc-photo-row img {
  width: 92px; height: 92px; object-fit: cover;
  border-radius: 50%; border: 3px solid var(--theme-color);
}
.acc-photo-row h5 { font-size: 16px; margin-bottom: 2px; }
.acc-photo-row p  { font-size: 13px; opacity: .65; margin-bottom: 10px; }

/* formulários */
.acc-form { margin-bottom: 8px; }
.acc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.acc-grid.one { grid-template-columns: 1fr; }
@media (max-width: 767px) { .acc-grid { grid-template-columns: 1fr; } }
.acc-input label {
  display: block; font-size: 12px; font-weight: 600;
  text-transform: uppercase; letter-spacing: .5px;
  opacity: .6; margin-bottom: 5px;
}
.acc-input input[readonly] { opacity: .65; cursor: not-allowed; }
.acc-msg:empty { display: none; }
.acc-msg { margin: 12px 0; }
.acc-sep { height: 1px; background: rgba(0,0,0,.08); margin: 30px 0 24px; }
.acc-subtitle { font-size: 17px; margin: 26px 0 14px; }
.acc-subtitle i { color: var(--theme-color); margin-right: 6px; }
.acc-hint { font-size: 13px; opacity: .7; margin-bottom: 12px; }
.acc-bio-editor { min-height: 220px; }

/* linhas rótulo/valor */
.acc-field { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid rgba(0,0,0,.05); }
.acc-field-label { font-size: 13px; opacity: .6; }
.acc-field-value { font-weight: 500; text-align: right; }

/* cabeçalho do sócio */
.acc-socio-head {
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 16px; flex-wrap: wrap; margin-bottom: 22px;
}
.acc-socio-num { font-size: 13px; opacity: .6; }
.acc-socio-head h5 { font-size: 20px; margin: 2px 0 0; }
.acc-socio-head p  { font-size: 14px; opacity: .7; margin: 0; }

/* estatísticas */
.acc-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 22px; }
@media (max-width: 767px) { .acc-stats { grid-template-columns: repeat(2, 1fr); } }
.acc-stat { background: rgba(2,155,155,.06); border-radius: 12px; padding: 14px; text-align: center; }
.acc-stat.alerta { background: rgba(217,101,35,.08); }
.acc-stat-label { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .5px; opacity: .6; margin-bottom: 4px; }
.acc-stat-value { display: block; font-size: 22px; font-weight: 700; color: var(--theme-color); }
.acc-stat.alerta .acc-stat-value { color: #d96523; }

.acc-alerta {
  background: rgba(217,101,35,.1); border-left: 4px solid #d96523;
  border-radius: 8px; padding: 14px 16px; margin-bottom: 22px; font-size: 14px;
}
.acc-alerta i { color: #d96523; margin-right: 6px; }

/* quotas */
.acc-quotas { display: flex; flex-direction: column; gap: 10px; }
.acc-quota {
  display: grid;
  grid-template-columns: 60px 1fr 90px 110px auto;
  align-items: center; gap: 12px;
  padding: 14px 16px;
  border: 1px solid rgba(0,0,0,.08); border-radius: 12px;
}
.acc-quota-ano   { font-size: 18px; font-weight: 700; color: var(--theme-color); }
.acc-quota-desc  { font-size: 14px; }
.acc-quota-valor { font-weight: 600; text-align: right; }
.acc-quota-accao { text-align: right; }
@media (max-width: 767px) {
  .acc-quota { grid-template-columns: 60px 1fr; }
  .acc-quota-valor, .acc-quota-accao { grid-column: 2; text-align: left; }
}

/* cartões das restantes abas */
.acc-cards { display: flex; flex-direction: column; gap: 14px; }
.acc-card {
  border: 1px solid rgba(0,0,0,.08); border-radius: 12px;
  padding: 18px 20px; transition: box-shadow .25s ease;
}
.acc-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,.07); }
.acc-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; }
.acc-card-head h5 { font-size: 16px; margin: 0; }
.acc-card-meta { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 10px; font-size: 13px; opacity: .75; }
.acc-card-meta i { color: var(--theme-color); margin-right: 4px; }
.acc-card-meta .destaque { font-weight: 700; opacity: 1; color: var(--theme-color); }
.acc-card-actions { margin-top: 14px; }

.acc-file { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; color: var(--theme-color); }
.acc-file.sm { font-size: 12px; margin-left: 8px; }
.acc-muted { opacity: .4; }

/* estado vazio */
.acc-empty-state { text-align: center; padding: 46px 20px; }
.acc-empty-state i { font-size: 44px; opacity: .18; display: block; margin-bottom: 14px; }
.acc-empty-state p { opacity: .55; margin: 0; }
