/* =========================================================
   Matheus Vermelho — Deputado Estadual 22888
   Identidade: Anybody / Montserrat
   Primária #030a44 · Secundária #0074ff
   Apoio: #016836 #000000 #ffffff #ffec00
   ========================================================= */

:root {
  --primary: #030a44;
  --secondary: #0074ff;
  --green: #016836;
  --black: #000000;
  --white: #ffffff;
  --yellow: #ffec00;

  --navy-950: #01051f;
  --navy-900: var(--primary);
  --navy-800: #06125a;
  --navy-700: #0a1c72;
  --navy-600: #0f2a8a;
  --blue-accent: var(--secondary);
  --blue: var(--secondary);
  --green-dark: #014d28;
  --yellow-soft: #fff36a;
  --off-white: #f3f6fc;
  --mist: #e7eef9;
  --text: var(--black);
  --text-muted: #4a5570;
  --shadow: 0 18px 50px rgba(3, 10, 68, 0.2);
  --radius: 18px;
  --header-h: 82px;
  --font: "Montserrat", sans-serif;
  --font-display: "Anybody", "Montserrat", sans-serif;
  --container: 1160px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--off-white);
  line-height: 1.6;
  overflow-x: hidden;
}

body.is-loading {
  overflow: hidden;
}

/* ---------- Preloader ---------- */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  background: var(--primary);
  transition: opacity 0.7s var(--ease), visibility 0.7s var(--ease);
}

.preloader.is-done {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(125deg, rgba(3, 10, 68, 0.55) 0%, transparent 45%),
    repeating-linear-gradient(
      -28deg,
      transparent 0 90px,
      rgba(0, 116, 255, 0.08) 90px 160px,
      transparent 160px 250px,
      rgba(255, 236, 0, 0.04) 250px 310px
    );
  pointer-events: none;
}

.preloader-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.6rem;
  width: min(88vw, 560px);
  padding: 1rem;
  animation: preloaderRise 0.7s var(--ease) both;
}

@keyframes preloaderRise {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.preloader-logo-wrap {
  position: relative;
  width: 100%;
  display: grid;
  place-items: center;
}

.preloader-logo {
  width: min(100%, 280px);
  height: auto;
  filter: drop-shadow(0 18px 40px rgba(0, 0, 0, 0.35));
}

.preloader-bar {
  width: min(100%, 180px);
  height: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
}

.preloader-bar span {
  display: block;
  width: 40%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--secondary), var(--yellow), var(--green));
  animation: preloaderBar 1.35s ease-in-out infinite;
}

@keyframes preloaderBar {
  0% {
    transform: translateX(-120%);
  }
  100% {
    transform: translateX(320%);
  }
}

.preloader-label {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

@media (max-width: 640px) {
  .preloader-logo {
    width: min(100%, 200px);
  }
}

/* ---------- Video preloader (home only) ---------- */
.preloader--video {
  display: block;
  background: #000;
  overflow: hidden;
}

.preloader-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  pointer-events: none;
  border: 0;
}

.preloader-video-veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(3, 10, 68, 0.18) 0%, rgba(3, 10, 68, 0.35) 100%);
  pointer-events: none;
}

.preloader-video-label {
  position: absolute;
  left: 50%;
  bottom: clamp(1.4rem, 4vw, 2.4rem);
  transform: translateX(-50%);
  margin: 0;
  z-index: 2;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.45);
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .preloader--video .preloader-video {
    display: none;
  }

  .preloader--video {
    background: var(--primary);
  }
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

button,
input,
textarea {
  font: inherit;
}

.container {
  width: min(100% - 2.5rem, var(--container));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--secondary);
  color: var(--white);
  padding: 0.75rem 1rem;
  z-index: 1000;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  transition:
    background 0.35s var(--ease),
    box-shadow 0.35s var(--ease),
    backdrop-filter 0.35s var(--ease),
    -webkit-backdrop-filter 0.35s var(--ease);
}

.site-header.is-scrolled {
  background: rgba(3, 10, 68, 0.94);
  backdrop-filter: blur(18px) saturate(1.15);
  -webkit-backdrop-filter: blur(18px) saturate(1.15);
  box-shadow: 0 8px 24px rgba(3, 10, 68, 0.28);
}

.header-inner {
  width: min(100% - 2rem, var(--container));
  margin-inline: auto;
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: min-height 0.35s var(--ease), padding 0.35s var(--ease);
}

.site-header.is-scrolled .header-inner {
  min-height: 58px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  z-index: 2;
  flex-shrink: 0;
  transition: gap 0.35s var(--ease);
}

.site-header.is-scrolled .brand {
  gap: 0.55rem;
}

.brand-logo {
  width: clamp(48px, 7vw, 64px);
  height: auto;
  transition: width 0.35s var(--ease), opacity 0.35s var(--ease);
}

.site-header.is-scrolled .brand-logo {
  width: clamp(40px, 6vw, 52px);
  opacity: 0.96;
}

.brand-text {
  display: none;
  flex-direction: column;
  line-height: 1.05;
  color: var(--white);
}

.brand-text strong {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 120%;
  font-size: 0.92rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.brand-text small {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.62);
  margin-top: 0.2rem;
}

@media (min-width: 1100px) {
  .brand-text {
    display: flex;
  }
}

.brand-number {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 125%;
  font-size: clamp(1.85rem, 3.8vw, 2.35rem);
  letter-spacing: -0.03em;
  color: var(--white);
  line-height: 0.92;
  transition: font-size 0.35s var(--ease), opacity 0.35s var(--ease);
}

.site-header.is-scrolled .brand-number {
  font-size: clamp(1.45rem, 3vw, 1.85rem);
  opacity: 0.95;
}

.brand-number span {
  color: var(--secondary);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 1;
  min-width: 0;
  transition: gap 0.35s var(--ease);
}

.site-header.is-scrolled .site-nav {
  gap: 0.65rem;
}

.site-nav ul {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.15rem;
}

.site-nav a {
  color: rgba(255, 255, 255, 0.86);
  font-size: 0.88rem;
  font-weight: 500;
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  white-space: nowrap;
  line-height: 1.2;
  transition: color 0.25s, background 0.25s, padding 0.35s var(--ease), font-size 0.35s var(--ease);
}

.site-header.is-scrolled .site-nav a {
  font-size: 0.8rem;
  padding: 0.32rem 0.55rem;
}

.site-nav a:hover,
.site-nav a.is-active {
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.site-header.is-scrolled .site-nav a:hover,
.site-header.is-scrolled .site-nav a.is-active {
  background: rgba(255, 255, 255, 0.12);
}

.site-nav a.is-active {
  color: var(--secondary);
}

.site-header.is-scrolled .header-cta {
  min-height: 36px;
  padding: 0.45rem 0.95rem;
  font-size: 0.8rem;
}

.site-header.is-scrolled .header-stripe {
  height: 3px;
  opacity: 0.85;
}

.site-header.is-scrolled .nav-toggle {
  width: 40px;
  height: 40px;
}

.nav-toggle {
  display: none;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
  position: relative;
  z-index: 2;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: var(--white);
  transition: 0.3s var(--ease);
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.header-stripe {
  height: 4px;
  background: linear-gradient(90deg, var(--primary) 0 28%, var(--secondary) 28% 62%, var(--yellow) 62% 82%, var(--green) 82% 100%);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 52px;
  padding: 0.85rem 1.55rem;
  border-radius: 999px;
  border: 2px solid transparent;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s, background 0.25s, color 0.25s;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-sm {
  min-height: 44px;
  padding: 0.65rem 1.2rem;
  font-size: 0.88rem;
}

.btn-yellow {
  background: var(--secondary);
  color: var(--white);
  box-shadow: 0 12px 28px rgba(0, 116, 255, 0.32);
}

.btn-yellow:hover {
  box-shadow: 0 16px 34px rgba(0, 116, 255, 0.45);
  background: #1a84ff;
}

.btn-outline {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.45);
  color: var(--white);
}

.btn-outline:hover {
  background: rgba(0, 116, 255, 0.16);
  border-color: var(--secondary);
}

.btn-navy {
  background: var(--primary);
  color: var(--white);
}

.btn-navy:hover {
  background: #06145e;
}

.btn-green {
  background: var(--green);
  color: var(--white);
}

.btn-accent {
  background: var(--yellow);
  color: var(--primary);
  box-shadow: 0 12px 28px rgba(255, 236, 0, 0.28);
}

.btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: min(100vh, 920px);
  display: grid;
  align-items: stretch;
  padding: calc(var(--header-h) + 50px) 0 0;
  color: var(--white);
  background:
    linear-gradient(115deg, rgba(3, 10, 68, 0.96) 0%, rgba(3, 10, 68, 0.88) 40%, rgba(0, 116, 255, 0.45) 100%),
    url("../images/hero-slogan.jpg") center/cover no-repeat;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, transparent 58%, rgba(0, 116, 255, 0.18) 100%),
    repeating-linear-gradient(
      -28deg,
      transparent 0 70px,
      rgba(255, 236, 0, 0.03) 70px 72px,
      transparent 72px 140px,
      rgba(1, 104, 54, 0.04) 140px 142px
    );
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  right: -8%;
  top: -10%;
  width: min(48vw, 560px);
  height: 140%;
  background: linear-gradient(180deg, var(--secondary), var(--primary) 55%, var(--green));
  clip-path: polygon(45% 0, 100% 0, 100% 100%, 0 100%);
  opacity: 0.88;
  transform: skewX(-8deg);
  animation: stripeIn 1.1s var(--ease) both;
  z-index: 1;
}

@keyframes stripeIn {
  from {
    opacity: 0;
    transform: skewX(-8deg) translateX(40px);
  }
  to {
    opacity: 0.9;
    transform: skewX(-8deg) translateX(0);
  }
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(100% - 2.5rem, var(--container));
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.95fr);
  gap: 1rem 1.5rem;
  align-items: start;
  min-height: calc(min(100vh, 920px) - var(--header-h) - 50px);
}

.hero-content {
  position: relative;
  z-index: 3;
  max-width: 640px;
  padding-top: 0;
  padding-bottom: 4.5rem;
  align-self: start;
  animation: rise 0.9s var(--ease) both;
}

.hero-portrait {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  align-self: end;
  pointer-events: none;
  animation: rise 1.05s var(--ease) 0.12s both;
}

.hero-portrait img {
  display: block;
  width: min(100%, 560px);
  height: auto;
  max-height: min(78vh, 680px);
  object-fit: cover;
  object-position: center top;
  border-radius: 24px 24px 0 0;
  filter: drop-shadow(0 18px 40px rgba(0, 0, 0, 0.35));
  -webkit-mask-image: linear-gradient(180deg, #000 72%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 72%, transparent 100%);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--secondary);
  margin-bottom: 1.1rem;
}

.eyebrow::before {
  content: "";
  width: 28px;
  height: 3px;
  background: linear-gradient(90deg, var(--secondary), var(--yellow));
}

.hero h1,
.page-hero h1,
.section-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 115%;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 1rem;
}

.hero h1 {
  font-size: clamp(2.0rem, 6vw, 4rem);
  max-width: 11ch;
}

.hero h1 em {
  font-style: normal;
  color: var(--secondary);
}

.hero-lead,
.section-lead {
  font-size: clamp(1rem, 2vw, 1.15rem);
  font-weight: 400;
  color: rgba(255, 255, 255, 0.86);
  max-width: 42ch;
  margin: 0 0 1.8rem;
}

.hero-number {
  display: inline-flex;
  align-items: baseline;
  gap: 0.15rem;
  margin: 0 0 1.4rem;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(3.4rem, 10vw, 6.5rem);
  line-height: 0.9;
  letter-spacing: -0.05em;
}

.hero-number .n22 {
  color: var(--secondary);
}

.hero-number .n00 {
  color: var(--white);
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 0.95rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
}

/* ---------- Stats ---------- */
.stats {
  position: relative;
  z-index: 3;
  margin-top: -2.5rem;
}

.stats-heading {
  margin: 0 0 0.85rem;
  text-align: center;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: white;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.stats-grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.stats-grid-5 {
  grid-template-columns: repeat(5, 1fr);
}

.stats-heading-sub {
  margin-top: 1.35rem;
  color: var(--text-muted);
}

.stat-card {
  background: var(--primary);
  color: var(--white);
  padding: 1.7rem 1.4rem;
  text-align: center;
}

.stat-card-total {
  background: linear-gradient(160deg, var(--secondary), var(--primary));
}

.stat-card strong {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 900;
  color: var(--secondary);
  letter-spacing: -0.03em;
  line-height: 1;
  margin-bottom: 0.55rem;
}

.stat-card .stat-number {
  color: inherit;
}

.stat-card .stat-number .n22,
.stat-card .stat-number .n888 {
  font-size: inherit;
  font-weight: inherit;
  font-family: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  text-transform: none;
}

.stat-card .stat-number .n22 {
  color: var(--green);
}

.stat-card .stat-number .n888 {
  color: var(--secondary);
}

.stat-card > span {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
  line-height: 1.35;
  display: block;
  max-width: 18ch;
  margin-inline: auto;
}

/* ---------- Sections ---------- */
.section {
  padding: clamp(4rem, 8vw, 6.5rem) 0;
}

.section-head {
  max-width: 680px;
  margin-bottom: 2.8rem;
}

.section-head.center {
  text-align: center;
  margin-inline: auto;
}

.section-kicker {
  display: inline-block;
  color: var(--secondary);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.section-title {
  font-size: clamp(1.9rem, 4vw, 3rem);
  color: var(--primary);
}

.section-lead {
  color: var(--text-muted);
}

.section-dark {
  background:
    linear-gradient(160deg, var(--navy-950), var(--primary) 50%, #061a6e),
    radial-gradient(circle at 85% 20%, rgba(0, 116, 255, 0.22), transparent 38%);
  color: var(--white);
}

.section-dark .section-title,
.section-dark .section-lead {
  color: var(--white);
}

.section-dark .section-lead {
  color: rgba(255, 255, 255, 0.78);
}

.section-mist {
  background: linear-gradient(180deg, var(--mist), var(--off-white));
}

/* ---------- Split / About preview ---------- */
.split {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

.split-visual {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  min-height: 420px;
  background:
    linear-gradient(145deg, rgba(3, 10, 68, 0.25), rgba(0, 116, 255, 0.4)),
    url("../images/hero-slogan.jpg") center/cover no-repeat;
  box-shadow: var(--shadow);
}

.split-visual.bio-photo {
  min-height: 280px;
  background: rgba(3, 10, 68, 0.12);
}

.split-visual.bio-photo img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 280px;
  max-height: 420px;
  object-fit: cover;
  object-position: center top;
}

.split-visual::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 8px;
  background: linear-gradient(90deg, var(--primary), var(--secondary), var(--yellow));
}

.split-badge {
  position: absolute;
  left: 1.4rem;
  bottom: 1.8rem;
  background: rgba(3, 10, 68, 0.9);
  color: var(--white);
  backdrop-filter: blur(8px);
  border-radius: 16px;
  padding: 1rem 1.2rem;
  max-width: 240px;
}

.split-badge strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--secondary);
  line-height: 1;
  margin-bottom: 0.35rem;
}

.split-copy p {
  color: var(--text-muted);
  margin: 0 0 1rem;
}

.split-copy p:last-of-type {
  margin-bottom: 1.6rem;
}

/* ---------- Cards / Proposals ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.35rem;
}

.card {
  background: var(--white);
  border-radius: 22px;
  padding: 1.7rem 1.5rem;
  border: 1px solid rgba(8, 30, 108, 0.08);
  box-shadow: 0 10px 30px rgba(3, 10, 68, 0.06);
  transition: transform 0.3s var(--ease), box-shadow 0.3s;
  position: relative;
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: linear-gradient(180deg, var(--secondary), var(--yellow), var(--green));
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}

.card-icon {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, rgba(0, 116, 255, 0.12), rgba(1, 104, 54, 0.1));
  color: var(--primary);
  margin-bottom: 1.1rem;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  overflow: hidden;
}

.card-icon--image {
  width: 56px;
  height: 56px;
  padding: 0;
  background: transparent;
  border-radius: 14px;
}

.card-icon--image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-icon svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.card h3 {
  margin: 0 0 0.65rem;
  font-size: 1.15rem;
  color: var(--navy-900);
}

.card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.card-dark {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--white);
}

.card-dark h3 {
  color: var(--white);
}

.card-dark p {
  color: rgba(255, 255, 255, 0.72);
}

.card-dark .card-icon {
  background: rgba(255, 236, 0, 0.12);
  color: var(--yellow);
}

/* ---------- Timeline ---------- */
.timeline {
  display: grid;
  gap: 0;
  position: relative;
  padding-left: 1.6rem;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.4rem;
  bottom: 0.4rem;
  width: 3px;
  background: linear-gradient(180deg, var(--green), var(--yellow), var(--navy-600));
  border-radius: 999px;
}

.timeline-item {
  position: relative;
  padding: 0 0 1.8rem 1.4rem;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -1.85rem;
  top: 0.45rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--secondary);
  border: 3px solid var(--primary);
  box-shadow: 0 0 0 4px rgba(0, 116, 255, 0.2);
}

.timeline-item h3 {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  color: var(--primary);
}

.timeline-item p {
  margin: 0;
  color: var(--text-muted);
}

.timeline-item .year {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--secondary);
  margin-bottom: 0.35rem;
}

/* ---------- Materials ---------- */
.materials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.35rem;
}

.material-card {
  background: var(--white);
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid rgba(8, 30, 108, 0.08);
  box-shadow: 0 10px 30px rgba(3, 10, 68, 0.06);
  display: flex;
  flex-direction: column;
  transition: transform 0.3s var(--ease);
}

.material-card:hover {
  transform: translateY(-6px);
}

.material-preview {
  aspect-ratio: 16 / 10;
  background:
    linear-gradient(145deg, rgba(3, 10, 68, 0.82), rgba(0, 116, 255, 0.45)),
    url("../images/hero-slogan.jpg") center/cover no-repeat;
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.material-preview.alt {
  background:
    linear-gradient(145deg, rgba(3, 10, 68, 0.85), rgba(1, 104, 54, 0.4)),
    url("../images/logo-bandeira.png") center/cover no-repeat;
}

.material-preview--photo,
.material-preview--story {
  background: #0a1230;
  padding: 0;
}

.material-preview--photo {
  aspect-ratio: 1 / 1;
}

.material-preview--story {
  aspect-ratio: 9 / 16;
  max-height: 420px;
}

.material-preview--photo img,
.material-preview--story img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.materials-grid--stories {
  grid-template-columns: repeat(4, 1fr);
}

.material-preview .tag {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 2;
  background: var(--secondary);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
}

.material-body {
  padding: 1.35rem 1.35rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex: 1;
}

.material-body h3 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--navy-900);
}

.material-body p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
  flex: 1;
}

/* ---------- Avatar workshop ---------- */
.avatar-intro {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
}

.avatar-intro-copy .section-title {
  max-width: 14ch;
}

.avatar-intro-copy .section-lead {
  max-width: 42ch;
  margin-bottom: 1.4rem;
}

.avatar-preview {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.avatar-preview-frame {
  border-radius: 22px;
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow);
  border: 1px solid rgba(8, 30, 108, 0.08);
}

.avatar-preview-frame img {
  width: 100%;
  height: auto;
  display: block;
}

.avatar-preview-note {
  margin: 0;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.ai-link {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0.12rem 0.45rem;
  border-radius: 8px;
  background: rgba(1, 104, 54, 0.12);
  color: var(--green);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 2px;
  transition: background 0.2s, color 0.2s;
}

.ai-link:hover {
  background: var(--green);
  color: var(--white);
  text-decoration: none;
}

.avatar-guide {
  margin-top: 2.5rem;
}

.avatar-steps {
  margin: 0 0 1.6rem;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.9rem;
  counter-reset: avatar-step;
}

.avatar-steps li {
  position: relative;
  padding: 1rem 1rem 1rem 4rem;
  background: var(--white);
  border-radius: 16px;
  border: 1px solid rgba(8, 30, 108, 0.08);
  box-shadow: 0 8px 24px rgba(3, 10, 68, 0.05);
  counter-increment: avatar-step;
}

.avatar-steps li::before {
  content: counter(avatar-step, decimal-leading-zero);
  position: absolute;
  left: 1rem;
  top: 1rem;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, var(--navy-900), var(--green));
  color: var(--white);
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 800;
}

.avatar-steps strong {
  display: block;
  margin-bottom: 0.25rem;
  color: var(--navy-900);
  font-size: 1rem;
}

.avatar-steps span {
  display: block;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.55;
}

.avatar-prompt-box {
  background: var(--navy-900);
  color: var(--white);
  border-radius: 22px;
  padding: 1.25rem 1.25rem 1.1rem;
  box-shadow: var(--shadow);
}

.avatar-prompt-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 0.9rem;
}

.avatar-prompt-head h3 {
  margin: 0;
  font-size: 1rem;
  color: var(--yellow);
}

.avatar-prompt-text {
  margin: 0;
  max-height: 320px;
  overflow: auto;
  padding: 1rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.88);
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 0.78rem;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
}

.avatar-copy-feedback {
  min-height: 1.2em;
  margin: 0.7rem 0 0;
  font-size: 0.85rem;
  color: var(--yellow);
}

.avatar-intro-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 0.35rem 0 0;
}

.avatar-intro-copy .section-lead {
  margin-bottom: 1rem;
}

/* ---------- Avatar automático ---------- */
.avatar-auto-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.4rem, 3vw, 2.4rem);
  align-items: start;
}

.avatar-auto-panel {
  background: var(--white);
  border-radius: 24px;
  padding: clamp(1.3rem, 3vw, 1.8rem);
  border: 1px solid rgba(8, 30, 108, 0.08);
  box-shadow: 0 12px 34px rgba(3, 10, 68, 0.06);
}

.avatar-auto-form {
  display: grid;
  gap: 1rem;
  margin-top: 1.2rem;
}

.avatar-dropzone {
  display: grid;
  gap: 0.45rem;
  place-items: center;
  text-align: center;
  min-height: 180px;
  padding: 1.4rem;
  border-radius: 18px;
  border: 2px dashed rgba(1, 33, 105, 0.28);
  background: rgba(232, 238, 248, 0.7);
  cursor: pointer;
  transition: border-color 0.25s, background 0.25s, transform 0.25s;
}

.avatar-dropzone:hover,
.avatar-dropzone.is-dragover {
  border-color: var(--green);
  background: rgba(1, 104, 54, 0.08);
}

.avatar-dropzone.has-file {
  display: none;
}

.avatar-dropzone input {
  display: none;
}

.avatar-dropzone-title {
  font-weight: 700;
  color: var(--navy-900);
}

.avatar-dropzone-hint {
  font-size: 0.88rem;
  color: var(--text-muted);
  max-width: 28ch;
}

.avatar-user-preview {
  display: grid;
  gap: 0.85rem;
  justify-items: start;
}

.avatar-user-preview img {
  width: min(100%, 280px);
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 16px;
  border: 1px solid rgba(8, 30, 108, 0.1);
}

.avatar-cutout-wrap {
  width: min(100%, 280px);
  aspect-ratio: 1;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(8, 30, 108, 0.1);
  background:
    linear-gradient(45deg, #d9dee8 25%, transparent 25%),
    linear-gradient(-45deg, #d9dee8 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #d9dee8 75%),
    linear-gradient(-45deg, transparent 75%, #d9dee8 75%);
  background-size: 20px 20px;
  background-position: 0 0, 0 10px, 10px -10px, -10px 0;
  background-color: #fff;
}

.avatar-cutout-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border: 0;
  border-radius: 0;
}

.avatar-cutout-wrap img.is-cutout {
  object-fit: contain;
}

.avatar-auto-status {
  margin: 0;
  min-height: 1.3em;
  font-size: 0.92rem;
  color: var(--text-muted);
}

.avatar-auto-status.is-error {
  color: #b42318;
}

.avatar-result-frame {
  position: relative;
  margin-top: 1.1rem;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(8, 30, 108, 0.08);
  background: #f4f7fb;
}

.avatar-result-frame img {
  width: 100%;
  height: auto;
  display: block;
}

.avatar-result-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 0.85rem;
  text-align: center;
  padding: 1.5rem;
  background: rgba(3, 10, 68, 0.72);
  color: var(--white);
}

.avatar-result-overlay p {
  margin: 0;
  font-size: 0.95rem;
}

.avatar-spinner {
  width: 42px;
  height: 42px;
  margin-inline: auto;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.25);
  border-top-color: var(--yellow);
  animation: avatarSpin 0.8s linear infinite;
}

@keyframes avatarSpin {
  to {
    transform: rotate(360deg);
  }
}

/* ---------- Blog ---------- */
.blog-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(260px, 0.85fr);
  gap: clamp(1.4rem, 3vw, 2.4rem);
  align-items: start;
}

.blog-feed {
  display: grid;
  gap: 1.1rem;
}

.post-entry,
.widget-box,
.post-detail,
.blog-empty {
  background: var(--white);
  border: 1px solid rgba(8, 30, 108, 0.08);
  border-radius: 22px;
  box-shadow: 0 12px 30px rgba(3, 10, 68, 0.06);
}

.post-entry,
.blog-empty,
.post-detail {
  padding: 1.4rem 1.45rem;
}

.post-entry.has-thumb {
  display: grid;
  grid-template-columns: minmax(160px, 240px) minmax(0, 1fr);
  gap: 1.15rem;
  padding: 0.85rem;
  align-items: stretch;
}

.post-entry-thumb {
  display: block;
  overflow: hidden;
  border-radius: 16px;
  background: rgba(3, 10, 68, 0.06);
  min-height: 160px;
}

.post-entry-thumb img {
  width: 100%;
  height: 100%;
  min-height: 160px;
  max-height: 220px;
  object-fit: cover;
  display: block;
  transition: transform 0.35s var(--ease);
}

.post-entry:hover .post-entry-thumb img {
  transform: scale(1.04);
}

.post-entry-body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: 0.45rem 0.55rem 0.55rem 0;
  min-width: 0;
}

.post-entry.has-thumb .post-entry-body {
  padding-right: 0.7rem;
}

.post-meta {
  display: inline-block;
  margin-bottom: 0.55rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--green);
}

.post-entry h2,
.blog-empty h2 {
  margin: 0 0 0.7rem;
  color: var(--navy-900);
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.4vw, 1.7rem);
  letter-spacing: -0.02em;
}

.post-entry h2 a {
  color: inherit;
}

.post-entry h2 a:hover {
  color: var(--green);
}

.post-excerpt {
  margin: 0 0 1.1rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ---------- Blog destaques (home) ---------- */
.blog-highlights-heading {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 1.5rem 2rem;
  align-items: end;
  margin-bottom: 2rem;
}

.blog-highlights-heading .section-title {
  margin-bottom: 0;
}

.blog-highlights-heading-copy {
  display: grid;
  justify-items: end;
  gap: 1rem;
}

.blog-highlights-heading-copy p {
  margin: 0;
  max-width: 36rem;
  color: var(--text-muted);
  text-align: right;
  line-height: 1.55;
}

.blog-highlights-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.85fr);
  gap: 1.15rem;
  align-items: stretch;
}

.blog-highlight-featured,
.blog-highlight-card,
.blog-highlights-empty {
  background: var(--white);
  border: 1px solid rgba(8, 30, 108, 0.08);
  box-shadow: 0 12px 30px rgba(3, 10, 68, 0.06);
}

.blog-highlight-featured {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  min-height: 100%;
  padding: clamp(1.5rem, 3vw, 2.35rem);
  border-radius: 28px;
  background:
    radial-gradient(circle at top right, rgba(255, 236, 0, 0.14), transparent 34%),
    linear-gradient(180deg, #fff, #f6f8fc);
  transition: transform 0.24s var(--ease), border-color 0.24s var(--ease), box-shadow 0.24s var(--ease);
  overflow: hidden;
}

.blog-highlight-featured.has-thumb {
  padding: 0;
}

.blog-highlight-featured-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.blog-highlight-featured.has-thumb .blog-highlight-featured-body {
  padding: clamp(1.15rem, 2.5vw, 1.75rem);
}

.blog-highlight-thumb {
  display: block;
  overflow: hidden;
  background: rgba(3, 10, 68, 0.06);
}

.blog-highlight-featured .blog-highlight-thumb {
  border-radius: 28px 28px 0 0;
}

.blog-highlight-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s var(--ease);
}

.blog-highlight-featured .blog-highlight-thumb img {
  aspect-ratio: 16 / 10;
  max-height: 280px;
}

.blog-highlight-thumb-sm {
  flex-shrink: 0;
  width: 72px;
  border-radius: 12px;
}

.blog-highlight-thumb-sm img {
  width: 72px;
  height: 72px;
  max-height: none;
}

.blog-highlight-featured:hover .blog-highlight-thumb img,
.blog-highlight-card:hover .blog-highlight-thumb img {
  transform: scale(1.04);
}

.blog-highlight-label {
  margin: 0 0 0.65rem;
  color: #b89600;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.blog-highlight-featured h3,
.blog-highlight-card h3 {
  margin: 0;
  color: var(--navy-900);
  font-family: var(--font-display);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.blog-highlight-featured h3 a,
.blog-highlight-card h3 a {
  color: inherit;
}

.blog-highlight-featured h3 a:hover,
.blog-highlight-card h3 a:hover {
  color: var(--green);
}

.blog-highlight-featured h3 {
  margin-bottom: 0.85rem;
  font-size: clamp(1.45rem, 2.8vw, 2.2rem);
}

.blog-highlight-excerpt,
.blog-highlight-card p {
  color: var(--text-muted);
  line-height: 1.55;
}

.blog-highlight-excerpt {
  margin: 0 0 1.35rem;
  flex: 1;
  font-size: 1.02rem;
  line-height: 1.65;
}

.blog-highlight-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: auto;
}

.blog-highlight-stack {
  display: grid;
  gap: 0.7rem;
  align-content: stretch;
  height: 100%;
}

.blog-highlight-card {
  display: grid;
  gap: 0.35rem;
  align-content: start;
  padding: 0.85rem 0.95rem 0.8rem;
  border-radius: 16px;
  transition: transform 0.24s var(--ease), border-color 0.24s var(--ease), box-shadow 0.24s var(--ease);
}

.blog-highlight-card.has-thumb {
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.7rem;
  align-items: center;
  padding: 0.65rem;
}

.blog-highlight-card-body {
  display: grid;
  gap: 0.28rem;
  min-width: 0;
}

.blog-highlight-card.has-thumb .blog-highlight-card-body {
  padding-right: 0.2rem;
}

.blog-highlight-card .post-meta {
  margin-bottom: 0;
  font-size: 0.7rem;
}

.blog-highlight-card:hover,
.blog-highlight-featured:hover {
  transform: translateY(-3px);
  border-color: rgba(1, 104, 54, 0.28);
  box-shadow: 0 16px 36px rgba(3, 10, 68, 0.1);
}

.blog-highlight-card h3 {
  font-size: 0.98rem;
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-highlight-card p {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-highlight-link {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem;
  margin-top: 0.1rem;
  color: var(--navy-900);
  font-weight: 700;
  font-size: 0.82rem;
}

.blog-highlight-link span:last-child {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 999px;
  background: rgba(3, 10, 68, 0.08);
  color: var(--navy-900);
  font-size: 0.95rem;
  line-height: 1;
}

.blog-highlight-link:hover {
  color: var(--green);
}

.blog-highlight-link:hover span:last-child {
  background: var(--yellow);
  color: var(--navy-900);
}

.blog-highlights-empty {
  padding: 1.6rem 1.5rem;
  border-radius: 22px;
}

.blog-highlights-empty h3 {
  margin: 0 0 0.55rem;
  color: var(--navy-900);
  font-family: var(--font-display);
}

.blog-highlights-empty p {
  margin: 0 0 1rem;
  color: var(--text-muted);
}

.blog-highlights-empty code {
  font-size: 0.9em;
  color: var(--navy-600);
}

@media (max-width: 992px) {
  .blog-highlights-heading {
    grid-template-columns: 1fr;
  }

  .blog-highlights-heading-copy {
    justify-items: start;
  }

  .blog-highlights-heading-copy p {
    text-align: left;
  }

  .blog-highlights-grid {
    grid-template-columns: 1fr;
  }

  .blog-highlight-stack {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .blog-highlight-stack {
    grid-template-columns: 1fr;
  }

  .blog-highlight-actions {
    flex-direction: column;
  }

  .blog-highlight-actions .btn {
    width: 100%;
  }
}

.blog-empty p {
  color: var(--text-muted);
}

.blog-empty code {
  font-size: 0.9em;
  color: var(--navy-600);
}

.blog-sidebar {
  display: grid;
  gap: 1rem;
  position: sticky;
  top: calc(var(--header-h) + 1rem);
}

.widget-box {
  padding: 1.15rem 1.2rem;
}

.widget-title {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.9rem;
  color: var(--navy-900);
  font-weight: 800;
  font-size: 0.95rem;
}

.search-wrapper {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.45rem;
}

.search-wrapper input {
  width: 100%;
  min-height: 44px;
  border: 1px solid rgba(8, 30, 108, 0.16);
  border-radius: 12px;
  padding: 0.65rem 0.85rem;
  font: inherit;
  color: var(--text);
  background: #f7f9fc;
}

.search-wrapper button {
  width: 44px;
  border: 0;
  border-radius: 12px;
  background: var(--navy-900);
  color: var(--yellow);
  cursor: pointer;
}

.calendar-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.calendar-nav {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(1, 33, 105, 0.08);
  color: var(--navy-900);
  font-size: 1.2rem;
  font-weight: 700;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.35rem;
  text-align: center;
}

.cal-grid small {
  color: var(--text-muted);
  font-size: 0.72rem;
}

.cal-day {
  display: grid;
  place-items: center;
  min-height: 34px;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--navy-900);
  background: rgba(232, 238, 248, 0.7);
}

.cal-day.is-empty {
  background: transparent;
}

.cal-day.is-active,
.cal-day:hover {
  background: var(--navy-900);
  color: var(--yellow);
}

.calendar-clear {
  display: inline-block;
  margin-top: 0.8rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--green);
}

.portal-links {
  display: grid;
  gap: 0.45rem;
}

.portal-link {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.7rem 0.8rem;
  border-radius: 12px;
  background: rgba(232, 238, 248, 0.7);
  color: var(--navy-900);
  font-size: 0.9rem;
  font-weight: 600;
}

.portal-link.is-active,
.portal-link:hover {
  background: var(--navy-900);
  color: var(--white);
}

.portal-link .utility-link {
  color: var(--green);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.portal-link.is-active .utility-link,
.portal-link:hover .utility-link {
  color: var(--yellow);
}

.post-detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 1.2rem;
}

.post-detail.has-featured {
  padding: 0;
  overflow: hidden;
}

.post-detail-featured {
  margin: 0;
  background: rgba(3, 10, 68, 0.06);
}

.post-detail-featured img {
  display: block;
  width: 100%;
  height: auto;
  max-height: min(52vh, 480px);
  object-fit: cover;
}

.post-detail-inner {
  padding: 1.4rem 1.45rem 1.55rem;
}

.post-detail.has-featured .post-detail-inner {
  padding-top: 1.25rem;
}

.post-category-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.post-category-chip {
  display: inline-flex;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  background: rgba(1, 104, 54, 0.12);
  color: var(--green);
  font-size: 0.75rem;
  font-weight: 700;
}

.post-detail-content {
  color: var(--text);
  line-height: 1.7;
  font-size: 1.02rem;
}

.post-detail-content img {
  border-radius: 14px;
  margin: 1rem 0;
}

.post-detail-content h2,
.post-detail-content h3 {
  color: var(--navy-900);
  font-family: var(--font-display);
}

.post-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.6rem;
}

/* ---------- CTA band ---------- */
.cta-band {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  padding: clamp(2.2rem, 5vw, 3.4rem);
  background:
    linear-gradient(120deg, var(--primary), #061a6e 55%, var(--secondary));
  color: var(--white);
  display: grid;
  grid-template-columns: 1.4fr auto;
  gap: 1.5rem;
  align-items: center;
  box-shadow: var(--shadow);
}

.cta-band::after {
  content: "";
  position: absolute;
  right: -40px;
  top: -30%;
  width: 220px;
  height: 160%;
  background: linear-gradient(180deg, var(--secondary), var(--yellow) 70%, var(--green));
  opacity: 0.9;
  transform: skewX(-18deg);
}

.cta-band > * {
  position: relative;
  z-index: 1;
}

.cta-band h2 {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  letter-spacing: -0.02em;
}

.cta-band p {
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
  max-width: 46ch;
}

/* ---------- Propostas portrait ---------- */
.propostas-portrait {
  padding-top: 0;
  padding-bottom: clamp(2.5rem, 5vw, 4rem);
}

.propostas-portrait-frame {
  margin: 0;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: linear-gradient(135deg, var(--mist), var(--white));
}

.propostas-portrait-frame img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  object-position: center top;
}

/* ---------- Page hero ---------- */
.page-hero {
  padding: calc(var(--header-h) + 3.5rem) 0 3.5rem;
  background:
    linear-gradient(125deg, rgba(3, 10, 68, 0.96), rgba(3, 10, 68, 0.88) 48%, rgba(0, 116, 255, 0.55)),
    url("../images/hero-slogan.jpg") center/cover no-repeat;
  color: var(--white);
  position: relative;
  overflow: hidden;
}

.page-hero::after {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: min(28vw, 320px);
  background: linear-gradient(180deg, var(--secondary), var(--primary) 55%, var(--yellow));
  clip-path: polygon(35% 0, 100% 0, 100% 100%, 0 100%);
  opacity: 0.95;
}

.page-hero .container {
  position: relative;
  z-index: 1;
}

.page-hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  max-width: 14ch;
}

.page-hero p {
  max-width: 48ch;
  color: rgba(255, 255, 255, 0.84);
  margin: 0;
  font-size: 1.05rem;
}

/* ---------- About longform ---------- */
.prose {
  display: grid;
  gap: 1.1rem;
}

.prose p {
  margin: 0;
  color: var(--text-muted);
  font-size: 1.02rem;
}

.highlight-box {
  background: var(--primary);
  color: var(--white);
  border-radius: 24px;
  padding: 1.8rem;
  position: relative;
  overflow: hidden;
}

.highlight-box::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 6px;
  background: linear-gradient(180deg, var(--secondary), var(--yellow), var(--green));
}

.highlight-box h3 {
  margin: 0 0 0.6rem;
  font-family: var(--font-display);
  color: var(--secondary);
}

.highlight-box p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
}

.bio-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}

.profile-list {
  margin: 0;
  padding: 1.25rem 1.35rem;
  list-style: none;
  background: var(--white);
  border-radius: 18px;
  border: 1px solid rgba(8, 16, 40, 0.08);
  box-shadow: 0 10px 30px rgba(8, 16, 40, 0.06);
}

.profile-list li {
  position: relative;
  padding: 0.65rem 0 0.65rem 1.15rem;
  color: var(--text-muted);
  font-size: 0.95rem;
  border-bottom: 1px solid rgba(8, 16, 40, 0.06);
}

.profile-list li:last-child {
  border-bottom: 0;
}

.profile-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.05rem;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--secondary), var(--green));
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--primary);
  color: rgba(255, 255, 255, 0.82);
  margin-top: 0;
}

.footer-stripe {
  height: 5px;
  background: linear-gradient(90deg, var(--primary) 0 25%, var(--secondary) 25% 55%, var(--yellow) 55% 78%, var(--green) 78% 100%);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2rem;
  padding: 3.5rem 0 2.5rem;
}

.footer-logo {
  width: min(100%, 160px);
  height: auto;
  margin-bottom: 1rem;
}

.footer-brand p {
  max-width: 36ch;
  margin: 0;
  color: rgba(255, 255, 255, 0.68);
}

.footer-nav h3,
.footer-contact h3 {
  margin: 0 0 1rem;
  color: var(--secondary);
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer-nav a,
.footer-contact li {
  display: block;
  padding: 0.28rem 0;
  color: rgba(255, 255, 255, 0.72);
  transition: color 0.2s;
}

.footer-nav a:hover {
  color: var(--white);
}

.socials {
  display: flex;
  gap: 0.55rem;
  margin-top: 1.1rem;
}

.social {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.06);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 800;
  transition: background 0.2s, color 0.2s;
}

.social:hover {
  background: var(--secondary);
  color: var(--white);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1.2rem 0 1.6rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}

.footer-bottom .container,
.footer-bottom .reveal {
  opacity: 1 !important;
  transform: none !important;
  filter: none !important;
}

.footer-bottom .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem 1.25rem;
}

.footer-bottom-copy {
  display: grid;
  gap: 0.25rem;
}

.footer-bottom p {
  margin: 0;
}

.footer-credit {
  margin-left: auto;
  color: rgba(170, 188, 220, 0.72);
  font-size: 0.88rem;
  white-space: nowrap;
}

.footer-credit a {
  color: #ff7a1a;
  font-weight: 700;
  text-decoration: none;
}

.footer-credit a:hover {
  color: #ff9444;
  text-decoration: underline;
}

/* ---------- WhatsApp ---------- */
.whatsapp-float {
  position: fixed;
  right: 1.2rem;
  bottom: 1.2rem;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  color: var(--white);
  display: grid;
  place-items: center;
  box-shadow: 0 12px 30px rgba(37, 211, 102, 0.45);
  z-index: 90;
  transition: transform 0.25s var(--ease);
}

.whatsapp-float:hover {
  transform: scale(1.06);
}

/* ---------- Back to top ---------- */
.back-to-top {
  position: fixed;
  left: 1.2rem;
  bottom: 1.4rem;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: rgba(3, 10, 68, 0.92);
  color: var(--secondary);
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: 0 10px 28px rgba(3, 10, 68, 0.35);
  z-index: 90;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(12px);
  transition:
    opacity 0.3s var(--ease),
    visibility 0.3s var(--ease),
    transform 0.3s var(--ease),
    background 0.25s,
    color 0.25s;
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--secondary);
  color: var(--white);
}

.back-to-top:focus-visible {
  outline: 2px solid var(--secondary);
  outline-offset: 3px;
}

/* ---------- Reveal / Lazy scroll ---------- */
.reveal {
  opacity: 0;
  transform: translate3d(0, 36px, 0) scale(0.98);
  filter: blur(6px);
  transition:
    opacity 0.85s var(--ease),
    transform 0.85s var(--ease),
    filter 0.85s var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform, filter;
}

.reveal.reveal-left {
  transform: translate3d(-40px, 18px, 0) scale(0.98);
}

.reveal.reveal-right {
  transform: translate3d(40px, 18px, 0) scale(0.98);
}

.reveal.reveal-scale {
  transform: translate3d(0, 16px, 0) scale(0.92);
}

.reveal.reveal-fade {
  transform: none;
  filter: blur(8px);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
  filter: blur(0);
}

.reveal.is-visible,
.reveal.is-visible * {
  will-change: auto;
}

img.lazy-img {
  opacity: 0;
  transform: scale(1.03);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

img.lazy-img.is-loaded {
  opacity: 1;
  transform: none;
}

/* ---------- Utilities ---------- */
.mt-1 { margin-top: 0.75rem; }
.mt-2 { margin-top: 1.5rem; }
.mt-3 { margin-top: 2.25rem; }
.mb-0 { margin-bottom: 0; }
.text-center { text-align: center; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .stats-grid,
  .cards,
  .materials-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .materials-grid--stories {
    grid-template-columns: repeat(3, 1fr);
  }

  .stats-grid-3 {
    grid-template-columns: 1fr;
  }

  .stats-grid-5 {
    grid-template-columns: repeat(2, 1fr);
  }

  .stats-grid-5 .stat-card-total {
    grid-column: 1 / -1;
  }

  .split,
  .bio-grid,
  .footer-grid,
  .cta-band,
  .avatar-intro {
    grid-template-columns: 1fr;
  }

  .avatar-steps {
    grid-template-columns: 1fr;
  }

  .avatar-intro-copy .section-title {
    max-width: none;
  }

  .avatar-auto-grid {
    grid-template-columns: 1fr;
  }

  .blog-layout {
    grid-template-columns: 1fr;
  }

  .blog-sidebar {
    position: static;
  }

  .post-entry.has-thumb {
    grid-template-columns: 1fr;
    gap: 0.85rem;
  }

  .post-entry-thumb img {
    max-height: 220px;
    min-height: 180px;
  }

  .post-entry.has-thumb .post-entry-body {
    padding: 0 0.55rem 0.7rem;
  }

  .hero::after,
  .page-hero::after {
    width: min(42vw, 220px);
    opacity: 0.7;
  }

  .cta-band::after {
    display: none;
  }
}

@media (max-width: 1100px) and (min-width: 981px) {
  .brand-logo {
    width: clamp(110px, 14vw, 140px);
  }

  .brand-number {
    font-size: clamp(1.85rem, 3.2vw, 2.25rem);
  }

  .site-nav a {
    font-size: 0.8rem;
    padding: 0.4rem 0.55rem;
  }

  .header-cta {
    padding: 0.55rem 0.9rem;
    font-size: 0.82rem;
  }
}

@media (max-width: 980px) {
  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: fixed;
    inset: 0;
    background: rgba(2, 6, 31, 0.97);
    flex-direction: column;
    justify-content: center;
    gap: 1.5rem;
    padding: 2rem;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s, visibility 0.3s;
  }

  .site-nav.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .site-nav ul {
    flex-direction: column;
    width: 100%;
    gap: 0.35rem;
  }

  .site-nav a {
    display: block;
    text-align: center;
    font-size: 1.15rem;
    padding: 0.9rem 1rem;
    white-space: normal;
  }

  .header-cta {
    width: min(100%, 280px);
  }
}

@media (max-width: 640px) {
  :root {
    --header-h: 72px;
  }

  .container,
  .hero-inner,
  .header-inner {
    width: min(100% - 1.5rem, var(--container));
  }

  .stats-grid,
  .cards,
  .materials-grid {
    grid-template-columns: 1fr;
  }

  .materials-grid--stories {
    grid-template-columns: repeat(2, 1fr);
  }

  .hero {
    min-height: auto;
    padding-bottom: 0;
    align-items: center;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .hero-content {
    max-width: none;
    padding-bottom: 2rem;
  }

  .hero-portrait {
    justify-content: center;
    max-width: 320px;
    margin-inline: auto;
  }

  .hero-portrait img {
    width: min(100%, 300px);
    max-height: 380px;
  }

  .hero h1 {
    max-width: none;
  }

  .brand-number {
    font-size: 1.35rem;
  }

  .footer-bottom .container {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-credit {
    margin-left: 0;
  }

  .split-visual {
    min-height: 320px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    scroll-behavior: auto !important;
  }

  .reveal,
  .reveal.reveal-left,
  .reveal.reveal-right,
  .reveal.reveal-scale,
  .reveal.reveal-fade,
  img.lazy-img {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    transition: none !important;
  }

  .preloader-logo,
  .preloader-bar span,
  .preloader-content {
    animation: none !important;
  }

  .preloader-logo {
    filter: drop-shadow(0 18px 40px rgba(0, 0, 0, 0.35));
  }
}
