/*
Theme Name: 79m Editorial
Theme URI: https://79m.buzz/
Author: 79m.buzz
Description: Tema editorial independente em português do Brasil para o conteúdo da marca 79m.
Version: 1.0.0
Text Domain: 79m-editorial
*/

:root {
  --page: #F7F4EE;
  --surface: #FFFFFF;
  --surface-muted: #F0EBE2;
  --brand: #A83E32;
  --brand-dark: #8E332A;
  --amber: #D89A32;
  --ink: #242321;
  --muted: #68645E;
  --line: #DDD5C8;
  --info: #EEF4F1;
  --safe: #2F7764;
  --warning-bg: #FFF4D9;
  --warning: #9B6416;
  --danger: #B43B3B;
  --focus: #2F7764;
  --max: 1160px;
  --reading: 780px;
  --radius: 12px;
  --shadow: 0 12px 32px rgba(58, 45, 30, .09);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  overflow-x: hidden;
  background: var(--page);
  color: var(--ink);
  font-family: "Noto Sans", "Segoe UI", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.76;
  text-rendering: optimizeLegibility;
}
a { color: var(--brand-dark); text-decoration-thickness: .08em; text-underline-offset: .18em; }
a:hover { color: var(--brand); text-decoration-thickness: .14em; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
img { display: block; max-width: 100%; height: auto; }
.container { width: min(calc(100% - 40px), var(--max)); margin-inline: auto; }
.reading { width: min(100%, var(--reading)); margin-inline: auto; }
.skip-link { position: fixed; left: 16px; top: -100px; z-index: 1000; padding: 10px 16px; background: var(--ink); color: #fff; }
.skip-link:focus { top: 12px; }

.site-header { position: sticky; top: 0; z-index: 100; min-height: 68px; background: rgba(255,255,255,.97); border-bottom: 1px solid var(--line); }
.header-inner { min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.site-brand { color: var(--ink); font-size: 29px; font-weight: 900; letter-spacing: -.055em; text-decoration: none; }
.site-brand::after { content: "."; color: var(--brand); }
.site-nav ul { display: flex; align-items: center; gap: 6px; margin: 0; padding: 0; list-style: none; }
.site-nav a { display: inline-flex; min-height: 44px; align-items: center; padding: 8px 12px; color: var(--ink); font-size: 15px; font-weight: 720; text-decoration: none; border-radius: 8px; }
.site-nav a:hover, .site-nav .current-menu-item > a { background: var(--surface-muted); color: var(--brand-dark); }
.site-nav .menu-cta > a { margin-left: 5px; padding-inline: 18px; background: var(--brand); color: #fff; }
.site-nav .menu-cta > a:hover { background: var(--brand-dark); color: #fff; }
.nav-toggle { display: none; min-width: 48px; min-height: 48px; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); }
.nav-toggle-lines, .nav-toggle-lines::before, .nav-toggle-lines::after { width: 22px; height: 2px; display: block; margin: auto; background: currentColor; content: ""; transition: transform .18s ease; }
.nav-toggle-lines::before { transform: translateY(-7px); }
.nav-toggle-lines::after { transform: translateY(5px); }
.nav-toggle[aria-expanded="true"] .nav-toggle-lines { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-lines::before { transform: translateY(0) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-lines::after { transform: translateY(-2px) rotate(-45deg); }

main { min-height: 60vh; }
.page-head { padding: 64px 0 34px; }
.page-kicker { color: var(--brand); font-size: .78rem; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
h1, h2, h3 { margin: 0 0 .55em; color: var(--ink); line-height: 1.14; letter-spacing: -.032em; }
h1 { max-width: 930px; font-size: clamp(2.2rem, 6vw, 3.6rem); }
h2 { position: relative; margin-top: 2.05em; padding-top: .25em; font-size: clamp(1.85rem, 4vw, 2.3rem); }
h2::before { position: absolute; top: -.17em; left: 0; width: 48px; height: 4px; background: var(--brand); border-radius: 4px; content: ""; }
h3 { margin-top: 1.65em; font-size: clamp(1.35rem, 3vw, 1.6rem); }
.page-subtitle { max-width: 800px; margin: 0; color: var(--muted); font-size: clamp(1.05rem, 2vw, 1.24rem); }
.review-date { display: block; margin-top: 14px; color: var(--muted); font-size: .86rem; }
.article-panel { margin-bottom: 70px; padding: clamp(24px, 5vw, 58px); background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); }
.article-content > :first-child { margin-top: 0; }
.article-content p { margin: 0 0 1.2em; }
.article-content ul, .article-content ol { padding-left: 1.4em; }
.article-content li + li { margin-top: .55em; }
.article-content section { scroll-margin-top: 90px; }
.lede { color: #36332f; font-size: 1.12rem; line-height: 1.72; }

.home-hero { padding: 54px 0 66px; background: var(--surface-muted); border-bottom: 1px solid var(--line); }
.home-hero-grid { display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(380px, .98fr); gap: 48px; align-items: center; }
.home-hero h1 { font-size: clamp(2.35rem, 5vw, 3.65rem); }
.home-hero .page-subtitle { margin: 17px 0 24px; }
.hero-intro { margin-bottom: 26px; font-size: 1.06rem; }
.hero-media .site-figure { margin: 0; }
.home-body { padding-top: 68px; }

.button, .wp-block-button__link { display: inline-flex; min-height: 48px; align-items: center; justify-content: center; padding: 11px 20px; border: 2px solid var(--brand); border-radius: 10px; background: var(--brand); color: #fff; font-weight: 780; line-height: 1.2; text-decoration: none; }
.button:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.button.secondary { background: #fff; color: var(--brand-dark); }
.button.secondary:hover { background: var(--surface-muted); }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0; }

.site-figure { margin: 32px 0; overflow: hidden; background: var(--surface-muted); border: 1px solid var(--line); border-radius: var(--radius); }
.site-figure img { width: 100%; aspect-ratio: var(--ratio, 14/9); object-fit: cover; }
.site-figure figcaption { padding: 11px 15px; color: var(--muted); font-size: .84rem; }
.figure-hero { box-shadow: var(--shadow); }
.figure-hero img { --ratio: 16/9; }

.table-wrap { width: 100%; margin: 28px 0; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; min-width: 680px; border-collapse: collapse; background: #fff; font-size: .94rem; }
th, td { padding: 14px 15px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
th { background: var(--surface-muted); color: var(--ink); font-size: .84rem; line-height: 1.4; }
tr:last-child td { border-bottom: 0; }

.steps { margin: 30px 0; padding: 0; list-style: none; counter-reset: step; }
.steps li { position: relative; min-height: 64px; margin: 0; padding: 2px 0 28px 68px; border-left: 2px solid var(--line); counter-increment: step; }
.steps li:last-child { padding-bottom: 0; border-left-color: transparent; }
.steps li::before { position: absolute; top: -2px; left: -24px; width: 46px; height: 46px; display: grid; place-items: center; background: var(--brand); color: #fff; border: 5px solid #fff; border-radius: 50%; font-weight: 850; content: counter(step); }
.steps strong { display: block; margin-bottom: 3px; color: var(--ink); }
.notice { margin: 26px 0; padding: 18px 20px; background: var(--info); border-left: 5px solid var(--safe); border-radius: 8px; }
.notice.warning { background: var(--warning-bg); border-left-color: var(--warning); }
.notice.danger { background: #fff0ee; border-left-color: var(--danger); }
.notice > :last-child { margin-bottom: 0; }

.faq-list { display: grid; gap: 10px; margin: 28px 0; }
.faq-list details { background: #fff; border: 1px solid var(--line); border-radius: 10px; }
.faq-list details[open] { border-left: 5px solid var(--brand); }
.faq-list summary { min-height: 52px; padding: 13px 48px 13px 17px; display: flex; align-items: center; position: relative; cursor: pointer; color: var(--ink); font-weight: 780; list-style: none; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { position: absolute; right: 18px; content: "+"; color: var(--brand); font-size: 1.4rem; }
.faq-list details[open] summary::after { content: "−"; }
.faq-answer { padding: 0 18px 17px; }
.faq-answer > :last-child { margin-bottom: 0; }

.related-links { margin-top: 42px; padding: 22px; background: var(--surface-muted); border-radius: var(--radius); }
.related-links strong { display: block; margin-bottom: 8px; }
.legal-note { font-size: .94rem; color: var(--muted); }

.site-footer { padding: 52px 0 28px; background: var(--ink); color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.4fr .8fr 1fr; gap: 48px; }
.footer-brand { margin: 0 0 12px; font-size: 1.7rem; font-weight: 900; letter-spacing: -.04em; }
.site-footer h2 { margin: 0 0 14px; padding: 0; color: #fff; font-size: 1rem; letter-spacing: 0; }
.site-footer h2::before { display: none; }
.site-footer p { margin: 0 0 12px; color: #ded9d2; font-size: .92rem; }
.footer-links { margin: 0; padding: 0; list-style: none; }
.footer-links li + li { margin-top: 7px; }
.footer-links a { color: #fff; }
.footer-bottom { margin-top: 35px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.18); color: #c9c3bb; font-size: .8rem; }

.not-found { padding: 90px 0; text-align: center; }

@media (max-width: 920px) {
  .nav-toggle { display: inline-grid; place-items: center; }
  .site-nav { position: absolute; top: 100%; left: 0; width: 100%; max-height: 0; overflow: hidden; visibility: hidden; background: #fff; border-bottom: 1px solid var(--line); transition: max-height .2s ease, visibility .2s; }
  .site-nav.is-open { max-height: 520px; visibility: visible; box-shadow: var(--shadow); }
  .site-nav ul { width: min(calc(100% - 32px), var(--max)); margin: 12px auto 18px; display: flex; align-items: stretch; flex-direction: column; }
  .site-nav a { width: 100%; min-height: 48px; padding-inline: 14px; }
  .site-nav .menu-cta > a { margin: 4px 0 0; justify-content: center; }
  .home-hero-grid { grid-template-columns: 1fr; gap: 30px; }
  .hero-media { max-width: 720px; }
  .footer-grid { grid-template-columns: 1.2fr .8fr; }
  .footer-grid > :last-child { grid-column: 1 / -1; }
}

@media (max-width: 600px) {
  body { font-size: 16px; }
  .container { width: min(calc(100% - 32px), var(--max)); }
  .site-header, .header-inner { min-height: 58px; }
  .site-brand { font-size: 26px; }
  .nav-toggle { min-width: 46px; min-height: 46px; }
  .home-hero { padding: 38px 0 46px; }
  .home-hero h1 { font-size: clamp(2.05rem, 10vw, 2.6rem); }
  .hero-media .site-figure img { aspect-ratio: 4/5; object-position: 50% 50%; }
  .home-body { padding-top: 44px; }
  .page-head { padding: 42px 0 26px; }
  .article-panel { margin-bottom: 44px; padding: 23px 18px; border-radius: 12px; }
  h1 { font-size: clamp(2rem, 10vw, 2.55rem); overflow-wrap: anywhere; }
  h2 { margin-top: 1.8em; font-size: clamp(1.7rem, 8vw, 2rem); }
  h3 { font-size: 1.35rem; }
  .cta-row { flex-direction: column; }
  .button { width: 100%; }
  .site-figure img { aspect-ratio: 4/3; object-fit: cover; }
  .steps li { padding-left: 58px; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .footer-grid > :last-child { grid-column: auto; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

