/* Artigo (conteúdo de marca). Formato editorial: coluna de leitura estreita, intertítulos, boxes.
   Tokens e botões em css/base.css */

/* ===== CONFIG DO CABEÇALHO: troque aqui as cores e a logo ===== */
:root {
  --header-bar-bg: #5D6F9D;    /* faixa de cima (logo + "Notícias") */
  --header-bar-fg: #FFFFFF;    /* texto da faixa de cima */
  --header-strip-bg: #4A5A82;  /* faixa de baixo ("O Assunto") */
  --header-strip-fg: #FFFFFF;  /* texto da faixa de baixo */
  --header-logo: url("../img/logo-r7.svg"); /* arquivo da logo (SVG ou PNG), caminho relativo a este CSS */
  --header-logo-w: 80px;       /* largura da logo */
  --header-logo-h: 72px;       /* altura da logo */
}

/* ---------- Cabeçalho do blog ---------- */
.masthead { text-transform: uppercase; text-align: center; }
.masthead__bar {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  min-height: 52px; padding: 8px var(--gutter);
  background: var(--header-bar-bg); color: var(--header-bar-fg);
}
.masthead__logo {
  justify-self: start;
  display: flex;
  align-items: center;
  height: var(--header-logo-h);
}
.masthead__logo img {
  width: var(--header-logo-w);
  height: auto;
  max-height: 100%;
  object-fit: contain;
  display: block;
}
.masthead__title { font-size: 15px; font-weight: 600; letter-spacing: .01em; }
.masthead__actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 14px;
}
.masthead__icon {
  background: none;
  border: 0;
  padding: 4px;
  color: var(--header-bar-fg);
  cursor: pointer;
  display: grid;
  place-items: center;
  border-radius: 6px;
  -webkit-tap-highlight-color: transparent;
}
.masthead__icon:hover,
.masthead__icon:focus-visible {
  background: rgba(255, 255, 255, 0.12);
}
.masthead__icon svg { display: block; }
.masthead__strip {
  padding: 8px var(--gutter);
  background: var(--header-strip-bg); color: var(--header-strip-fg);
  font-size: 15px; font-weight: 800; letter-spacing: .02em;
}

@media (max-width: 480px) {
  :root {
    --header-logo-w: 60px;
    --header-logo-h: 54px;
  }
  .masthead__bar { min-height: 48px; padding: 6px var(--gutter); }
}

/* ---------- Layout: texto + cartão lateral (no computador) ---------- */
.layout {
  max-width: 1100px; margin: 0 auto; padding: 0 var(--gutter);
  display: grid; grid-template-columns: minmax(0, 1fr); gap: 56px;
}
.side { display: none; }

@media (min-width: 1040px) {
  .layout { grid-template-columns: minmax(0, 700px) 300px; justify-content: space-between; }
  .side { display: block; padding-top: 48px; }
  .side__card { position: sticky; top: 92px; }
}

.post { min-width: 0; padding-bottom: 24px; }

/* ---------- Abertura ---------- */
.post__head { padding: 32px 0 24px; }
.post__section { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; color: var(--primary-deep); font-weight: 700; font-size: 15px; margin-bottom: 14px; }
.tag-ad { padding: 3px 10px; border-radius: 999px; background: var(--foreground); color: #fff; font-size: 12.5px; font-weight: 800; }
.post__title {
  font-size: clamp(30px, 7.4vw, 50px); line-height: 1.08; font-weight: 800; letter-spacing: -0.032em;
  text-wrap: balance;
}
.post__dek { margin-top: 18px; font-size: clamp(18px, 4.6vw, 21px); line-height: 1.5; color: var(--muted-foreground); font-weight: 500; }


/* ---------- Ilustração do topo ---------- */
.shot { margin: 0 calc(var(--gutter) * -1) 0; }
.shot__frame { position: relative; overflow: hidden; background: var(--primary-soft); }
.shot__art { width: 100%; height: auto; }

/* ---------- Vídeo do topo (arquivo e capa em VIDEO, js/main.js) ---------- */
.video {
  --video-ratio: 16 / 9; /* proporção do vídeo. Vertical: 9 / 16 */
  aspect-ratio: var(--video-ratio); background: #1A1714;
}
.video__poster, .video video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
img.video__poster { display: block; }
.video::after { /* escurece a capa para o play aparecer */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(26, 23, 20, .05), rgba(26, 23, 20, .35));
}
.video__play {
  position: absolute; z-index: 1; left: 50%; top: 50%; translate: -50% -50%;
  width: 72px; height: 72px; border: 0; border-radius: 50%; cursor: pointer;
  display: grid; place-items: center;
  background: var(--primary); color: #fff; box-shadow: 0 10px 30px -8px rgba(0, 0, 0, .55);
  transition: transform .15s ease;
}
.video__play::before { /* anel pulsando */
  content: ""; position: absolute; inset: -8px; border-radius: 50%;
  border: 3px solid #fff; opacity: .7; animation: video-pulse 1.8s ease-out infinite;
}
.video__play:active { transform: scale(.94); }
.video__play svg { width: 32px; height: 32px; margin-left: 4px; fill: currentColor; }
@keyframes video-pulse { from { transform: scale(.9); opacity: .8; } to { transform: scale(1.25); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .video__play::before { animation: none; } }
.video__duration {
  position: absolute; z-index: 1; right: 12px; bottom: 12px;
  padding: 3px 8px; border-radius: 6px; background: rgba(0, 0, 0, .72); color: #fff;
  font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums;
}
.video__duration:empty { display: none; }
.video__soon {
  position: absolute; z-index: 1; left: 50%; bottom: 14px; translate: -50% 0;
  padding: 7px 14px; border-radius: 999px; background: #fff; color: var(--foreground);
  font-size: 14px; font-weight: 700; white-space: nowrap; box-shadow: var(--shadow);
}
.video__overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  background: rgba(0, 0, 0, 0.35);
  cursor: pointer;
}
.video__sound-btn {
  width: 80px;
  height: 80px;
  border: 0;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: 0 10px 30px -8px rgba(0, 0, 0, .6);
  animation: video-pulse 1.6s ease-out infinite;
  position: relative;
}
.video__sound-btn::before {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  border: 3px solid #fff;
  opacity: .7;
  animation: video-pulse 1.6s ease-out infinite;
}
.video__sound-text {
  margin: 0;
  padding: 8px 16px;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  border-radius: 999px;
  text-align: center;
  letter-spacing: -0.01em;
}
.video.is-playing .video__overlay { display: none; }
.shot figcaption { padding: 10px var(--gutter) 0; font-size: 13.5px; line-height: 1.5; color: var(--muted-foreground); }
.shot figcaption strong { color: var(--foreground); font-weight: 700; }

@media (min-width: 640px) {
  .shot { margin: 0; }
  .shot__frame { border-radius: var(--radius-card); }
  .shot figcaption { padding: 10px 0 0; }
}

/* ---------- Corpo do texto ---------- */
.post__body { max-width: 680px; padding-top: 28px; font-size: 18px; line-height: 1.75; }
.post__body > * + * { margin-top: 20px; }
.post__body p { text-wrap: pretty; }
.post__body .lead { font-size: 20px; line-height: 1.65; font-weight: 500; }
.post__body h2 {
  margin-top: 48px; font-size: clamp(25px, 6vw, 31px); line-height: 1.18; font-weight: 800; letter-spacing: -0.025em;
  text-wrap: balance;
}
.post__body h2 + * { margin-top: 14px; }
.post__body strong { font-weight: 700; }
.post__body .note { font-size: 15px; line-height: 1.6; color: var(--muted-foreground); }

/* Em resumo */
.summary {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-card);
  padding: 20px 20px 18px; font-size: 16px; line-height: 1.55;
}
.summary h2 { margin: 0 0 10px; font-size: 17px; letter-spacing: -0.01em; }
.summary li { position: relative; padding-left: 22px; }
.summary li + li { margin-top: 8px; }
.summary li::before {
  content: ""; position: absolute; left: 2px; top: .55em;
  width: 8px; height: 8px; border-radius: 3px; background: var(--primary);
}
.post__body .summary + .lead { margin-top: 32px; }

/* Boxes */
.box { border-radius: var(--radius-card); padding: 22px 20px; font-size: 16.5px; line-height: 1.65; }
.box h3 { font-size: 18px; line-height: 1.3; font-weight: 800; margin-bottom: 8px; letter-spacing: -0.01em; }
.box p + p { margin-top: 12px; }
.box--define { background: var(--primary-soft); }
.box--math { background: var(--card); box-shadow: var(--shadow); border: 1px solid var(--border); }
.math {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 10px;
  padding: 14px 16px; border-radius: var(--radius); background: var(--muted);
  font-size: 17px; font-weight: 600; color: var(--muted-foreground);
}
.math span { color: var(--foreground); font-weight: 700; }
.math strong { color: var(--primary-deep); font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.box--alert { background: var(--destructive-soft); }
.box--alert h3 { color: #A51C1C; }
.box--alert li { position: relative; padding-left: 26px; }
.box--alert li + li { margin-top: 8px; }
.box--alert li::before {
  content: ""; position: absolute; left: 3px; top: .5em; width: 12px; height: 12px;
  background:
    linear-gradient(45deg, transparent 43%, var(--destructive) 43% 57%, transparent 57%),
    linear-gradient(-45deg, transparent 43%, var(--destructive) 43% 57%, transparent 57%);
}

/* Citação de destaque (frase do próprio texto) */
.pull { margin: 36px 0 !important; padding: 4px 0 4px 20px; border-left: 4px solid var(--primary); }
.pull p { font-size: clamp(22px, 5.6vw, 27px); line-height: 1.35; font-weight: 700; letter-spacing: -0.02em; text-wrap: balance; }

/* Faixas de valor */
.rates { display: grid; gap: 12px; }
@media (min-width: 560px) { .rates { grid-template-columns: 1fr 1fr; } }
.rate { 
  background: var(--card); 
  border: 1px solid var(--border); 
  border-radius: var(--radius-card); 
  padding: 22px 20px; 
  text-align: center;
}
.rate__value { 
  font-size: clamp(28px, 7vw, 34px); 
  line-height: 1.1; 
  font-weight: 800; 
  letter-spacing: -0.035em; 
  color: var(--primary); 
}
.rate__label { 
  margin-top: 8px; 
  font-size: 15px; 
  line-height: 1.45; 
  color: var(--muted-foreground); 
}

/* Passo a passo (é uma sequência de verdade, então leva número) */
.steps { counter-reset: step; }
.steps li { position: relative; padding: 0 0 22px 56px; counter-increment: step; }
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 38px; height: 38px; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--primary); color: #fff; font-weight: 800; font-size: 17px; line-height: 1;
}
.steps li:not(:last-child)::after {
  content: ""; position: absolute; left: 18px; top: 44px; bottom: 6px; width: 2px; background: var(--border);
}
.steps h3 { font-size: 19px; line-height: 1.3; font-weight: 800; padding-top: 6px; letter-spacing: -0.01em; }
.steps p { margin-top: 4px; font-size: 17px; line-height: 1.65; }

/* Requisitos */
.checks li { position: relative; padding-left: 34px; }
.checks li + li { margin-top: 12px; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: .32em;
  width: 22px; height: 22px; border-radius: 7px; background: var(--success-soft);
}
.checks li::after {
  content: ""; position: absolute; left: 7px; top: calc(.32em + 5px);
  width: 6px; height: 10px; border: solid var(--success); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg);
}

/* Níveis */
.levels { display: grid; gap: 10px; }
@media (min-width: 560px) { .levels { grid-template-columns: 1fr 1fr; } }
.levels li {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-card);
  padding: 16px 18px; font-size: 15px; line-height: 1.5;
}
.levels__n { color: var(--primary-deep); font-weight: 700; font-size: 13px; }
.levels h3 { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 4px; }
.levels li p:last-child { color: var(--muted-foreground); }
.levels .is-pro { border-color: #A8C4E0; background: var(--primary-soft); }

/* Como começar */
.start { counter-reset: s; }
.start li { counter-increment: s; position: relative; padding-left: 36px; }
.start li + li { margin-top: 10px; }
.start li::before {
  content: counter(s); position: absolute; left: 0; top: .2em;
  width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center;
  background: var(--primary-soft); color: var(--primary-deep); font-size: 13px; font-weight: 800; line-height: 1;
}

/* Chamada no meio do texto */
.cta-card {
  display: grid; gap: 16px;
  margin: 22px 0 0 !important;
  padding: 22px 20px; border-radius: var(--radius-card);
  background: var(--card); border: 1.5px solid #B8D0E8; box-shadow: var(--shadow);
  font-size: 16px; line-height: 1.55;
}
.cta-card p { color: var(--muted-foreground); }
.cta-card .cta-card__title { color: var(--foreground); font-size: 19px; font-weight: 800; letter-spacing: -0.015em; margin-bottom: 4px; }
@media (min-width: 560px) {
  .cta-card { grid-template-columns: 1fr auto; align-items: center; gap: 20px; padding: 22px 24px; }
}

/* ---------- Chamada final ---------- */
.final {
  margin-top: 48px; padding: 36px 22px; border-radius: var(--radius-card);
  background: var(--primary); color: #fff; text-align: center;
}
.final h2 { font-size: clamp(27px, 7vw, 36px); line-height: 1.12; font-weight: 800; letter-spacing: -0.03em; text-wrap: balance; }
.final p { margin: 12px auto 22px; max-width: 30em; font-size: 16.5px; line-height: 1.55; color: #E8F0F8; }
.btn--light { background: #fff; color: var(--primary-deep); box-shadow: 0 10px 24px -12px #001a4099; }
.btn--light:hover { background: var(--primary-soft); }

/* ---------- Comentários (exemplos) ---------- */
.comments { margin-top: 48px; max-width: 680px; }
.comments h2 { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 14px; }
.comments .draft-note { margin-bottom: 14px; }
.comment { display: flex; gap: 12px; padding: 16px 0; border-top: 1px solid var(--border); }
.comment__avatar {
  width: 38px; height: 38px; flex: none; border-radius: 50%;
  display: grid; place-items: center; background: var(--muted); color: var(--muted-foreground); font-weight: 800;
  overflow: hidden;
}
.comment__avatar img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.comment__meta { font-size: 14px; }
.comment__meta span { color: var(--muted-foreground); }
.comment__text { margin-top: 2px; font-size: 16px; line-height: 1.6; }
.comment__tag { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; background: var(--warning-soft); color: #7A4304; font-size: 12px; font-weight: 700; }

/* ---------- Cartão lateral (computador) ---------- */
.side__card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-card);
  box-shadow: var(--shadow); padding: 22px;
}
.side__mark { width: 40px; height: 40px; }
.side__title { margin: 14px 0 12px; font-size: 20px; line-height: 1.25; font-weight: 800; letter-spacing: -0.02em; }
.side__facts { margin-bottom: 18px; font-size: 15px; color: var(--muted-foreground); }
.side__facts li { padding: 8px 0; border-top: 1px solid var(--border); }
.side__facts strong { color: var(--foreground); font-weight: 800; }
.side__fine { margin-top: 12px; font-size: 12.5px; line-height: 1.45; color: var(--muted-foreground); }


/* ---------- Rodapé ---------- */
.footer { margin-top: 56px; padding: 28px 0 calc(32px + env(safe-area-inset-bottom)); border-top: 1px solid var(--border); background: var(--card); }
.footer__inner { max-width: 1100px; margin: 0 auto; padding: 0 var(--gutter); font-size: 14px; line-height: 1.6; color: var(--muted-foreground); }
.footer__inner strong { color: var(--foreground); }
.footer nav { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 14px 0; }
.footer nav a { color: var(--foreground); font-weight: 600; text-underline-offset: 3px; }
.footer__copy { font-size: 13px; }
