/*
Theme Name: Airton José 1526
Theme URI: https://airtonjose.com.br
Author: Felipe Batista Simas
Description: Tema de campanha para o candidato a Deputado Federal Airton José (MDB Paraná). Banner principal e colinha de votação, com todos os textos, números, imagens e cores editáveis pelo painel do WordPress. As imagens acompanham o tema, sem precisar de importação.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: airton-jose
Tags: one-page, custom-colors, custom-logo, responsive-layout
*/

:root {
  --verde:        #39B640;
  --verde-escuro: #2DA439;
  --azul:         #2F72AB;
  --azul-escuro:  #3168B2;
  --cinza-caixa:  #BFBFBF;
  --preto:        #1A1A1A;
  --texto:        #2B2B2B;
  --texto-suave:  #6B6B6B;
  --fundo:        #FFFFFF;
  --fundo-alt:    #F4F6F8;
  --borda:        #E3E7EB;

  --max: 900px;
  --raio: 10px;
  --transicao: .25s ease;
}

/* ---------- Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--fundo);
  color: var(--texto);
  font-family: "Montserrat", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }

h1, h2, p { margin: 0; }

.container {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: 20px;
}

/* ============================================================
   BANNER PRINCIPAL
   ============================================================ */
.banner {
  width: 100%;
  background: var(--fundo);
  overflow: hidden;
}

.banner__img {
  width: 100%;
  height: auto;
}

/* ============================================================
   COLINHA
   ============================================================ */
.colinha {
  padding-block: 48px 56px;
  background: var(--fundo);
}

.colinha__titulo {
  font-size: clamp(1.55rem, 5vw, 2.25rem);
  font-weight: 900;
  letter-spacing: -.01em;
  color: var(--azul-escuro);
  text-align: center;
  text-transform: uppercase;
}

.colinha__titulo::after {
  content: "";
  display: block;
  width: 72px;
  height: 5px;
  margin: 14px auto 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--verde) 0 50%, var(--azul-escuro) 50% 100%);
}

.colinha__sub {
  margin-top: 14px;
  text-align: center;
  color: var(--texto-suave);
  font-size: .98rem;
  font-weight: 500;
}

/* ---------- Lista de cargos ---------- */
.cargos {
  margin-top: 36px;
  display: flex;
  flex-direction: column;
  gap: 26px;
}

.cargo {
  padding: 22px 22px 24px;
  border: 1px solid var(--borda);
  border-radius: var(--raio);
  background: var(--fundo-alt);
}

.cargo--destaque {
  border-color: var(--verde);
  background: #FFFFFF;
  box-shadow: 0 10px 28px rgba(47, 114, 171, .13);
}

.cargo__nome {
  font-size: clamp(1.05rem, 3.6vw, 1.3rem);
  font-weight: 800;
  line-height: 1.28;
  color: var(--preto);
}

.cargo__candidato {
  display: block;
  font-weight: 800;
  color: var(--preto);
}

.cargo--destaque .cargo__candidato { color: var(--azul-escuro); }

.asterisco { font-size: .75em; }

/* ---------- Dígitos ---------- */
.digitos {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.digito {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: clamp(52px, 14vw, 68px);
  aspect-ratio: 1 / 1;
  border-radius: 4px;
  background: var(--cinza-caixa);
  color: var(--preto);
  font-size: clamp(1.7rem, 6.5vw, 2.35rem);
  font-weight: 900;
  line-height: 1;
  user-select: none;
}

.digito--preenchido {
  background: var(--cinza-caixa);
  animation: pulso .4s ease both;
}

.cargo--destaque .digito--preenchido {
  /* mesmo cinza da colinha impressa; o destaque fica no cartão */
  background: var(--cinza-caixa);
  color: var(--preto);
}

@keyframes pulso {
  from { transform: scale(.82); opacity: 0; }
  to   { transform: scale(1);   opacity: 1; }
}

/* ---------- Botão copiar ---------- */
.btn-copiar {
  margin-top: 18px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border: 0;
  border-radius: 999px;
  background: var(--azul-escuro);
  color: #FFFFFF;
  font-family: inherit;
  font-size: .95rem;
  font-weight: 700;
  cursor: pointer;
  transition: background var(--transicao), transform var(--transicao);
}

.btn-copiar:hover  { background: var(--azul); }
.btn-copiar:active { transform: scale(.97); }

.btn-copiar:focus-visible {
  outline: 3px solid var(--verde);
  outline-offset: 2px;
}

/* ---------- Coligação ---------- */
.coligacao {
  margin-top: 32px;
  color: var(--texto-suave);
  font-size: .76rem;
  font-weight: 600;
  line-height: 1.55;
  text-transform: uppercase;
  letter-spacing: .01em;
}

/* ============================================================
   RODAPÉ
   ============================================================ */
.rodape {
  padding-block: 34px;
  background: var(--azul-escuro);
  border-top: 6px solid var(--verde);
}

.rodape__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  text-align: center;
}

.rodape__logo {
  width: 190px;
  background: #FFFFFF;
  padding: 10px 14px;
  border-radius: var(--raio);
}

.rodape__legal {
  color: rgba(255, 255, 255, .88);
  font-size: .76rem;
  font-weight: 600;
  line-height: 1.6;
}

/* ============================================================
   TOAST
   ============================================================ */
.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  z-index: 50;
  padding: 12px 22px;
  border-radius: 999px;
  background: var(--preto);
  color: #FFFFFF;
  font-size: .9rem;
  font-weight: 700;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 14px);
  transition: opacity var(--transicao), transform var(--transicao);
}

.toast.visivel {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ============================================================
   ANIMAÇÃO DE ENTRADA
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .5s ease, transform .5s ease;
}

.reveal.visivel {
  opacity: 1;
  transform: none;
}

/* ============================================================
   RESPONSIVO
   ============================================================ */
@media (max-width: 600px) {
  .colinha      { padding-block: 34px 40px; }
  .cargos       { gap: 20px; }
  .cargo        { padding: 18px 16px 20px; }
  .digitos      { gap: 8px; }
  .btn-copiar   { width: 100%; justify-content: center; }
}

@media (max-width: 360px) {
  .digito { width: 46px; font-size: 1.5rem; }
}

/* ---------- Acessibilidade ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}


/* ============================================================
   AJUSTES ESPECIFICOS DO WORDPRESS
   ============================================================ */

/* barra de administracao */
body.admin-bar .toast { bottom: 58px; }

/* o WP injeta srcset no <img>; garante que ele nunca estoure */
.banner__img,
.rodape__logo { max-width: 100%; }

/* estado vazio mostrado apenas para quem pode editar */
.aviso-editor {
  max-width: var(--max);
  margin: 28px auto;
  padding: 18px 20px;
  border: 1px dashed var(--azul-escuro);
  border-radius: var(--raio);
  background: #FFF8E5;
  color: var(--texto);
  font-size: .92rem;
  font-weight: 600;
  text-align: center;
}

.aviso-editor a { color: var(--azul-escuro); }

/* banner sem imagem definida */
.banner--vazio {
  display: grid;
  place-items: center;
  min-height: 220px;
  background: var(--fundo-alt);
  color: var(--texto-suave);
  font-weight: 700;
}
