/*
Theme Name: ConvenCon
Theme URI: https://convencon.com.br
Author: ConvenCon
Description: Tema oficial da Convenção de Contabilidade do Distrito Federal (CRCDF).
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: convencon
Tags: custom-colors, custom-menu, custom-logo, featured-images, translation-ready
*/

/* =========================================================
   1. Design tokens
   ========================================================= */
:root {
  --c-navy: #0a1f33;
  --c-navy-soft: #12304d;
  --c-navy-deep: #061523;
  --c-gold: #c9a227;
  --c-gold-light: #e6cb6a;
  --c-cream: #faf7f0;
  --c-white: #ffffff;
  --c-ink: #16202b;
  --c-muted: #5b6b7c;
  --c-line: #e6e1d5;

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 18px 45px -22px rgba(10, 31, 51, .35);
  --shadow-sm: 0 8px 24px -16px rgba(10, 31, 51, .4);

  --wrap: 1160px;
  --gap: clamp(1rem, 2.5vw, 2rem);
}

/* =========================================================
   2. Reset enxuto
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: clamp(1rem, .95rem + .2vw, 1.075rem);
  line-height: 1.7;
  color: var(--c-ink);
  background: var(--c-cream);
  -webkit-font-smoothing: antialiased;
}
img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: var(--c-navy-soft); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--c-gold); }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.15;
  letter-spacing: -.015em;
  margin: 0 0 .6em;
  color: var(--c-navy);
}
h1 { font-size: clamp(2.1rem, 1.4rem + 3.2vw, 4rem); }
h2 { font-size: clamp(1.7rem, 1.3rem + 1.8vw, 2.6rem); }
h3 { font-size: clamp(1.15rem, 1rem + .6vw, 1.4rem); }
p { margin: 0 0 1.1em; }
ul, ol { padding-left: 1.25rem; }
hr { border: 0; border-top: 1px solid var(--c-line); margin: 2.5rem 0; }
figure { margin: 0; }
figcaption { font-size: .85rem; color: var(--c-muted); margin-top: .5rem; }

.screen-reader-text {
  position: absolute !important; width: 1px; height: 1px; padding: 0;
  overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; border: 0;
}

/* =========================================================
   3. Layout
   ========================================================= */
.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
.section { padding: clamp(3.5rem, 2rem + 6vw, 6.5rem) 0; }
.section--tight { padding: clamp(2.5rem, 1.5rem + 3vw, 4rem) 0; }
.section--navy { background: var(--c-navy); color: #dbe4ee; }
.section--navy h2, .section--navy h3 { color: var(--c-white); }
.section--cream { background: var(--c-cream); }
.section--white { background: var(--c-white); }
.section-head { max-width: 720px; margin-bottom: clamp(2rem, 1rem + 2vw, 3rem); }
.section-head--center { margin-inline: auto; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: .78rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  color: var(--c-gold); margin-bottom: .9rem;
}
.eyebrow::before { content: ""; width: 28px; height: 2px; background: currentColor; }
.lead { font-size: clamp(1.05rem, 1rem + .35vw, 1.25rem); color: var(--c-muted); }
.section--navy .lead { color: #b9c7d6; }

.grid { display: grid; gap: var(--gap); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }

/* =========================================================
   4. Botões
   ========================================================= */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font-family: var(--font-body); font-weight: 600; font-size: .95rem;
  padding: .9rem 1.6rem; border-radius: 999px; border: 2px solid transparent;
  text-decoration: none; cursor: pointer; transition: transform .15s ease, background .2s ease, color .2s ease, border-color .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn--gold { background: var(--c-gold); color: var(--c-navy-deep); }
.btn--gold:hover { background: var(--c-gold-light); color: var(--c-navy-deep); }
.btn--ghost { border-color: rgba(255,255,255,.45); color: var(--c-white); }
.btn--ghost:hover { border-color: var(--c-white); background: rgba(255,255,255,.08); color: var(--c-white); }
.btn--navy { background: var(--c-navy); color: var(--c-white); }
.btn--navy:hover { background: var(--c-navy-soft); color: var(--c-white); }
.btn--ghost-dark { border-color: var(--c-navy); color: var(--c-navy); }
.btn--ghost-dark:hover { background: var(--c-navy); color: var(--c-white); }
.btn--sm { padding: .6rem 1.1rem; font-size: .85rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: .8rem; }

/* =========================================================
   5. Cabeçalho
   ========================================================= */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 31, 51, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255,255,255,.08);
  transition: box-shadow .2s ease;
}
.site-header.is-scrolled { box-shadow: 0 10px 30px -18px rgba(0,0,0,.6); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-height: 76px; }
.brand { display: flex; align-items: center; gap: .75rem; text-decoration: none; color: var(--c-white); }
.brand img { max-height: 46px; width: auto; }
.brand__mark {
  display: grid; place-items: center; width: 42px; height: 42px; flex: none;
  border-radius: 10px; background: var(--c-gold); color: var(--c-navy-deep);
  font-family: var(--font-display); font-weight: 700; font-size: 1.15rem;
}
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name { font-family: var(--font-display); font-weight: 700; font-size: 1.12rem; letter-spacing: .01em; }
.brand__tag { font-size: .68rem; letter-spacing: .18em; text-transform: uppercase; color: #9fb2c6; }

.nav { display: flex; align-items: center; gap: 1.6rem; }
.nav ul { display: flex; align-items: center; gap: 1.5rem; list-style: none; margin: 0; padding: 0; }
.nav a { color: #d6e0ea; text-decoration: none; font-size: .92rem; font-weight: 500; position: relative; padding: .35rem 0; }
.nav a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: 0; height: 2px;
  background: var(--c-gold); transition: right .25s ease;
}
.nav a:hover, .nav .current-menu-item > a { color: var(--c-white); }
.nav a:hover::after, .nav .current-menu-item > a::after { right: 0; }
.nav .menu-item-has-children { position: relative; }
.nav .sub-menu {
  position: absolute; top: calc(100% + .6rem); left: -.75rem; min-width: 210px;
  background: var(--c-white); border-radius: var(--radius-sm); box-shadow: var(--shadow);
  padding: .5rem; display: none; flex-direction: column; gap: .1rem;
}
.nav .menu-item-has-children:hover .sub-menu { display: flex; }
.nav .sub-menu a { color: var(--c-ink); padding: .55rem .75rem; border-radius: 6px; }
.nav .sub-menu a::after { display: none; }
.nav .sub-menu a:hover { background: var(--c-cream); color: var(--c-navy); }

.nav-toggle {
  display: none; background: none; border: 0; padding: .5rem; cursor: pointer;
  color: var(--c-white); width: 44px; height: 44px;
}
.nav-toggle span { display: block; height: 2px; background: currentColor; margin: 5px 0; transition: .25s ease; }
.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* =========================================================
   6. Hero
   ========================================================= */
.hero {
  position: relative; overflow: hidden; color: var(--c-white);
  background:
    radial-gradient(1100px 520px at 82% -12%, rgba(201,162,39,.28), transparent 62%),
    radial-gradient(900px 480px at -10% 110%, rgba(46,92,140,.5), transparent 60%),
    linear-gradient(160deg, var(--c-navy-deep), var(--c-navy) 55%, #0e2a44);
}
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image:
    linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(70% 70% at 50% 30%, #000 35%, transparent 100%);
}
.hero__inner { position: relative; z-index: 1; padding: clamp(4rem, 2rem + 8vw, 8rem) 0 clamp(3.5rem, 2rem + 5vw, 6rem); }
.hero__edition {
  display: inline-flex; align-items: center; gap: .6rem; margin-bottom: 1.4rem;
  padding: .45rem .9rem; border: 1px solid rgba(201,162,39,.4); border-radius: 999px;
  background: rgba(201,162,39,.1); color: var(--c-gold-light);
  font-size: .78rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
}
.hero h1 { color: var(--c-white); max-width: 18ch; margin-bottom: 1.1rem; }
.hero h1 em { font-style: normal; color: var(--c-gold-light); }
.hero__lead { max-width: 58ch; font-size: clamp(1.02rem, .95rem + .4vw, 1.22rem); color: #c3d1df; }
.hero__meta { display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; margin: 1.8rem 0 2rem; }
.hero__meta span { display: inline-flex; align-items: center; gap: .5rem; font-size: .93rem; color: #dae4ef; }
.hero__meta svg { width: 18px; height: 18px; color: var(--c-gold); flex: none; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .8rem; }

/* faixa de números */
.stats { position: relative; z-index: 2; margin-top: -2.4rem; }
.stats__inner {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  background: var(--c-white); border-radius: var(--radius); box-shadow: var(--shadow);
  overflow: hidden; border: 1px solid var(--c-line);
}
.stat { padding: 1.5rem 1.2rem; text-align: center; border-right: 1px solid var(--c-line); }
.stat:last-child { border-right: 0; }
.stat__num { font-family: var(--font-display); font-size: clamp(1.6rem, 1.3rem + 1vw, 2.2rem); color: var(--c-navy); line-height: 1; }
.stat__label { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: var(--c-muted); margin-top: .45rem; }

/* =========================================================
   7. Cards
   ========================================================= */
.card {
  background: var(--c-white); border: 1px solid var(--c-line); border-radius: var(--radius);
  padding: clamp(1.4rem, 1rem + 1vw, 2rem); box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #d8d2c3; }
.card h3 { margin-bottom: .5rem; }
.card p:last-child { margin-bottom: 0; }
.card__icon {
  display: grid; place-items: center; width: 46px; height: 46px; border-radius: 12px;
  background: rgba(201,162,39,.14); color: var(--c-navy); margin-bottom: 1rem;
}
.card__icon svg { width: 24px; height: 24px; }
.card__num {
  font-family: var(--font-display); font-size: .82rem; font-weight: 700;
  letter-spacing: .14em; color: var(--c-gold); margin-bottom: .6rem;
}
.card--navy { background: var(--c-navy-soft); border-color: rgba(255,255,255,.1); color: #cfdae6; }
.card--navy h3 { color: var(--c-white); }
.card--navy .card__icon { background: rgba(201,162,39,.18); color: var(--c-gold-light); }

/* palestrantes */
.speaker { text-align: left; }
.speaker__photo {
  aspect-ratio: 4 / 5; border-radius: var(--radius); overflow: hidden; margin-bottom: 1rem;
  background: linear-gradient(150deg, #dcd6c7, #c9c2b0);
  display: grid; place-items: center; color: #8b8677;
}
.speaker__photo img { width: 100%; height: 100%; object-fit: cover; }
.speaker__name { font-family: var(--font-display); font-size: 1.12rem; color: var(--c-navy); margin: 0 0 .2rem; }
.speaker__role { font-size: .85rem; color: var(--c-muted); margin: 0; }
.section--navy .speaker__name { color: var(--c-white); }
.section--navy .speaker__role { color: #9fb2c6; }

/* programação */
.day-card { background: var(--c-white); border: 1px solid var(--c-line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.day-card__head { background: var(--c-navy); color: var(--c-white); padding: 1.1rem 1.4rem; display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.day-card__head strong { font-family: var(--font-display); font-size: 1.15rem; }
.day-card__head span { font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--c-gold-light); }
.timeline { list-style: none; margin: 0; padding: .5rem 1.4rem 1.2rem; }
.timeline li { display: grid; grid-template-columns: 74px 1fr; gap: 1rem; padding: .85rem 0; border-bottom: 1px dashed var(--c-line); }
.timeline li:last-child { border-bottom: 0; }
.timeline time { font-weight: 600; font-size: .86rem; color: var(--c-gold); padding-top: .1rem; }
.timeline p { margin: 0; font-size: .95rem; }
.timeline small { display: block; color: var(--c-muted); font-size: .82rem; margin-top: .15rem; }

/* CTA de inscrição */
.cta-band {
  position: relative; overflow: hidden; border-radius: var(--radius);
  background: linear-gradient(120deg, var(--c-navy), #17395a 60%, #1d4468);
  color: var(--c-white); padding: clamp(2rem, 1.2rem + 3vw, 3.5rem);
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 2rem; align-items: center;
}
.cta-band::after {
  content: ""; position: absolute; right: -80px; top: -80px; width: 280px; height: 280px;
  border-radius: 50%; background: radial-gradient(circle, rgba(201,162,39,.35), transparent 70%);
}
.cta-band h2 { color: var(--c-white); margin-bottom: .4rem; }
.cta-band p { color: #c8d5e2; margin: 0; }
.cta-band__actions { display: flex; flex-wrap: wrap; gap: .8rem; justify-content: flex-end; position: relative; z-index: 1; }

/* patrocinadores */
.logos { display: flex; flex-wrap: wrap; gap: 1rem; align-items: stretch; }
.logo-slot {
  flex: 1 1 160px; min-height: 84px; display: grid; place-items: center; text-align: center;
  border: 1px dashed #cfc8b8; border-radius: var(--radius-sm); color: #9a9485;
  font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; background: rgba(255,255,255,.5);
}

/* =========================================================
   8. Conteúdo / posts
   ========================================================= */
.entry { max-width: 760px; margin-inline: auto; }
.entry__meta { font-size: .85rem; color: var(--c-muted); margin-bottom: 1.4rem; }
.entry__content > * + * { margin-top: 1.1em; }
.entry__content blockquote {
  margin: 2rem 0; padding: 1rem 1.5rem; border-left: 4px solid var(--c-gold);
  background: var(--c-white); border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-family: var(--font-display); font-size: 1.15rem; color: var(--c-navy);
}
.entry__content img { border-radius: var(--radius-sm); }
.page-hero { background: var(--c-navy); color: #cfdae6; padding: clamp(3rem, 2rem + 4vw, 5rem) 0; }
.page-hero h1 { color: var(--c-white); margin-bottom: .3rem; }
.page-hero p { margin: 0; color: #a9bccd; }
.breadcrumb { font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--c-gold-light); margin-bottom: .8rem; }
.post-list { display: grid; gap: 1.2rem; }
.post-item { display: grid; grid-template-columns: 120px 1fr; gap: 1.2rem; align-items: start; }
.post-item__thumb { aspect-ratio: 1; border-radius: var(--radius-sm); background: linear-gradient(150deg,#dcd6c7,#c9c2b0); overflow: hidden; }
.post-item__thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-item h3 { margin: 0 0 .3rem; }
.post-item p { margin: 0; color: var(--c-muted); font-size: .94rem; }
.post-item time { font-size: .8rem; color: var(--c-gold); font-weight: 600; }

/* =========================================================
   9. Formulário
   ========================================================= */
.form { display: grid; gap: 1rem; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field { display: grid; gap: .35rem; }
.field label { font-size: .85rem; font-weight: 600; color: var(--c-navy); }
.field input, .field select, .field textarea {
  font: inherit; font-size: .95rem; color: var(--c-ink);
  padding: .8rem .95rem; border: 1px solid #d7d1c3; border-radius: var(--radius-sm);
  background: var(--c-white); width: 100%;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--c-gold); box-shadow: 0 0 0 3px rgba(201,162,39,.18);
}
.form__hint { font-size: .8rem; color: var(--c-muted); }
.form__hp { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }
.notice { padding: .95rem 1.1rem; border-radius: var(--radius-sm); font-size: .92rem; margin-bottom: 1.2rem; }
.notice--ok { background: #e7f6ec; color: #1c6b3a; border: 1px solid #bfe4cb; }
.notice--erro { background: #fdecec; color: #8f2222; border: 1px solid #f3c6c6; }

/* contato */
.contact-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(1.5rem, 1rem + 3vw, 3.5rem); align-items: start; }
.contact-info { display: grid; gap: 1.1rem; }
.contact-info__item { display: grid; grid-template-columns: 42px 1fr; gap: .9rem; align-items: start; }
.contact-info__icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 10px; background: rgba(201,162,39,.14); color: var(--c-navy); }
.contact-info__icon svg { width: 20px; height: 20px; }
.contact-info__item strong { display: block; font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--c-muted); margin-bottom: .15rem; }
.contact-info__item a, .contact-info__item p { margin: 0; font-size: .96rem; }

/* =========================================================
   10. Rodapé
   ========================================================= */
.site-footer { background: var(--c-navy-deep); color: #93a6b9; padding: clamp(3rem, 2rem + 3vw, 4.5rem) 0 0; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 2.5rem; padding-bottom: 2.5rem; }
.footer-brand p { font-size: .92rem; max-width: 36ch; margin-top: 1rem; }
.footer-col h4 { color: var(--c-white); font-family: var(--font-body); font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 1rem; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .55rem; }
.footer-col a { color: #aebdca; text-decoration: none; font-size: .92rem; }
.footer-col a:hover { color: var(--c-gold-light); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.09); padding: 1.2rem 0;
  display: flex; flex-wrap: wrap; gap: .6rem 1.5rem; justify-content: space-between;
  font-size: .8rem; color: #7d8fa1;
}

/* =========================================================
   11. Utilidades e animação
   ========================================================= */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn:hover, .card:hover { transform: none; }
}
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mt-2 { margin-top: 2rem; }

/* =========================================================
   12. Responsivo
   ========================================================= */
@media (max-width: 900px) {
  .cta-band { grid-template-columns: 1fr; }
  .cta-band__actions { justify-content: flex-start; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .nav {
    position: fixed; inset: 76px 0 auto 0; background: var(--c-navy);
    flex-direction: column; align-items: stretch; padding: 1rem 1.25rem 1.75rem;
    gap: .25rem; border-bottom: 1px solid rgba(255,255,255,.1);
    transform: translateY(-120%); transition: transform .3s ease; max-height: calc(100vh - 76px); overflow-y: auto;
  }
  .nav.is-open { transform: none; }
  .nav ul { flex-direction: column; align-items: stretch; gap: .1rem; }
  .nav a { display: block; padding: .8rem 0; font-size: 1rem; border-bottom: 1px solid rgba(255,255,255,.07); }
  .nav a::after { display: none; }
  .nav .sub-menu { position: static; display: flex; background: transparent; box-shadow: none; padding: .25rem 0 .5rem 1rem; }
  .nav .sub-menu a { color: #b9c7d6; border-bottom: 0; padding: .45rem 0; }
  .header-inner { min-height: 68px; }
  .hero__actions .btn { width: 100%; }
  .form__row { grid-template-columns: 1fr; }
  .stats__inner { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(2n) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--c-line); }
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
  .post-item { grid-template-columns: 84px 1fr; }
}
@media (max-width: 420px) {
  .stats__inner { grid-template-columns: 1fr; }
  .stat { border-right: 0; border-bottom: 1px solid var(--c-line); }
}
