/* ==========================================================================
   Ajudo.com.br — folha de estilos da página inicial
   Direção: editorial quente (papel, serifa, verde-floresta + terracota)
   ========================================================================== */

:root {
  --paper: #f8f3e8;
  --paper-deep: #f1e9d8;
  --card: #fffdf7;
  --ink: #232a20;
  --ink-soft: #55604f;
  --green: #2e5743;
  --green-deep: #22422f;
  --terracotta: #c4572f;
  --terracotta-soft: #f3ddd2;
  --mustard: #e3a92f;
  --mustard-soft: #f6e8c6;
  --line: rgba(35, 42, 32, 0.16);
  --line-strong: rgba(35, 42, 32, 0.5);

  --font-display: "Fraunces", "Georgia", serif;
  --font-body: "Instrument Sans", "Helvetica Neue", sans-serif;

  --shadow-sm: 0 1px 2px rgba(35, 42, 32, 0.07), 0 2px 8px rgba(35, 42, 32, 0.06);
  --shadow-md: 0 2px 4px rgba(35, 42, 32, 0.08), 0 10px 28px rgba(35, 42, 32, 0.12);
  --shadow-pop: 4px 4px 0 rgba(35, 42, 32, 0.9);

  --radius: 14px;
  --radius-lg: 22px;
  --container: 1160px;
  --header-h: 72px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Grão de papel sobre a página inteira */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2000;
  opacity: 0.5;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3CfeComponentTransfer%3E%3CfeFuncA type='linear' slope='0.05'/%3E%3C/feComponentTransfer%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

img, svg { display: block; }
a { color: inherit; }

/* O atributo hidden SEMPRE vence (displays declarados, ex.: flex, não o anulam) */
[hidden] { display: none !important; }

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

/* Tipografia ------------------------------------------------------------- */

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

h1 { font-size: clamp(1.9rem, 4.4vw, 3.15rem); }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); }

h1 em, h2 em {
  font-style: italic;
  font-weight: 500;
  color: var(--terracotta);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--green);
}
.eyebrow svg { width: 14px; height: 14px; color: var(--mustard); }
.eyebrow-light { color: var(--mustard); }

/* Botões ------------------------------------------------------------------ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 12px 22px;
  border-radius: 999px;
  border: 1.5px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn svg { width: 14px; height: 10px; }

.btn-primary {
  background: var(--green);
  color: var(--paper);
  border-color: var(--green-deep);
  box-shadow: 0 2px 0 var(--green-deep), var(--shadow-sm);
}
.btn-primary:hover { background: var(--green-deep); transform: translateY(-2px); box-shadow: 0 4px 0 var(--green-deep), var(--shadow-md); }
.btn-primary:active { transform: translateY(0); box-shadow: 0 1px 0 var(--green-deep); }

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-ghost:hover { background: var(--card); border-color: var(--ink); transform: translateY(-2px); box-shadow: var(--shadow-sm); }

.btn-light {
  background: var(--paper);
  color: var(--green-deep);
  border-color: var(--paper);
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.25), var(--shadow-sm);
}
.btn-light:hover { transform: translateY(-2px); box-shadow: 0 4px 0 rgba(0, 0, 0, 0.25), var(--shadow-md); }

.btn-lg { padding: 15px 28px; font-size: 1.02rem; }
.btn-block { width: 100%; }

/* Barra superior ----------------------------------------------------------- */

.topbar {
  background: var(--green-deep);
  color: var(--paper);
  text-align: center;
  font-size: 0.82rem;
  padding: 8px 16px;
  letter-spacing: 0.02em;
}
.topbar strong { color: var(--mustard); }
.topbar-extra { white-space: nowrap; }
.topbar-dot {
  display: inline-block;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--mustard);
  margin-right: 4px;
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(227, 169, 47, 0.55); }
  50% { box-shadow: 0 0 0 5px rgba(227, 169, 47, 0); }
}

/* Cabeçalho ----------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 243, 232, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1.5px solid var(--line);
  transition: box-shadow 0.25s ease;
}
.site-header.scrolled { box-shadow: var(--shadow-md); }

.header-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: var(--header-h);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.logo-mark { width: 34px; height: 34px; }
.logo-text {
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.logo-dot { color: var(--terracotta); }

.main-nav { flex: 1; }
.main-nav > ul {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 9px 14px;
  border-radius: 999px;
  transition: background 0.15s ease;
}
.nav-link:hover { background: var(--paper-deep); }
.nav-link .chev { width: 11px; height: 7px; transition: transform 0.2s ease; }
.nav-item.open .chev { transform: rotate(180deg); }

/* Menu suspenso */
.nav-item.has-dropdown { position: relative; }
.dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: -12px;
  display: grid;
  grid-template-columns: repeat(3, minmax(170px, 1fr));
  gap: 4px 28px;
  background: var(--card);
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-pop), var(--shadow-md);
  padding: 22px 24px 14px;
  min-width: 580px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
}
.nav-item.open .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.13em;
  color: var(--terracotta);
  margin-bottom: 8px;
}
/* Título de coluna clicável (link p/ a página de cluster) sem perder o estilo de rótulo. */
.dropdown-col a.dropdown-title {
  font-size: 0.72rem;
  padding: 0;
  margin-left: 0;
  text-decoration: none;
  color: var(--terracotta);
  transition: color 0.15s ease;
}
.dropdown-col a.dropdown-title:hover { color: var(--green-deep); }
.dropdown-col { display: flex; flex-direction: column; }
.dropdown-col a {
  font-size: 0.92rem;
  text-decoration: none;
  padding: 7px 8px;
  margin-left: -8px;
  border-radius: 8px;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.dropdown-col a:hover { background: var(--paper-deep); color: var(--green-deep); }
.tag-hot {
  flex-shrink: 0;
  font-size: 0.52rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--mustard-soft);
  color: #8a6312;
  border: 1px solid var(--mustard);
  padding: 1px 6px;
  border-radius: 999px;
}
.dropdown-all {
  grid-column: 1 / -1;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding-top: 14px;
  border-top: 1.5px dashed var(--line);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--green);
  text-decoration: none;
}
.dropdown-all svg { width: 14px; height: 10px; transition: transform 0.15s ease; }
.dropdown-all:hover svg { transform: translateX(4px); }

/* Ações do cabeçalho */
.header-actions { display: flex; align-items: center; gap: 12px; }

.search-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink-soft);
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: 999px;
  padding: 9px 14px;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.search-btn:hover { border-color: var(--ink); box-shadow: var(--shadow-sm); }
.search-btn svg { width: 16px; height: 16px; }
.search-kbd {
  font-family: var(--font-body);
  font-size: 0.72rem;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 5px;
  padding: 0 6px;
  color: var(--ink-soft);
  background: var(--paper);
}

/* Área de conta (entrar / perfil / sair) */
.account { position: relative; }
.account-btn,
.account-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink);
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: 999px;
  padding: 9px 16px 9px 12px;
  cursor: pointer;
  text-decoration: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.account-btn:hover,
.account-link:hover { border-color: var(--ink); box-shadow: var(--shadow-sm); }
.account-btn svg,
.account-link svg { width: 18px; height: 18px; color: var(--green); }
.account-btn.is-logged svg { color: var(--terracotta); }
.account-btn-label { max-width: 12ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.account-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 220px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--card);
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-pop), var(--shadow-md);
  padding: 10px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
  z-index: 60;
}
.account.open .account-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.account-greet {
  font-size: 0.85rem;
  color: var(--ink-soft);
  padding: 6px 10px 8px;
  margin-bottom: 4px;
  border-bottom: 1.5px dashed var(--line);
}
.account-greet strong { color: var(--ink); }
.account-menu a {
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--ink);
  padding: 9px 10px;
  border-radius: 9px;
  transition: background 0.12s ease, color 0.12s ease;
}
.account-menu a:hover { background: var(--paper-deep); color: var(--green-deep); }
.account-menu .account-cta { color: var(--green-deep); }
.account-menu .account-exit { color: var(--terracotta); }

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: var(--card);
  border: 1.5px solid var(--ink);
  border-radius: 12px;
  cursor: pointer;
  padding: 0 11px;
}
.hamburger span {
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.2s ease;
}
.hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Menu móvel */
.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 6px;
  padding: 16px 20px 24px;
  border-top: 1.5px solid var(--line);
  background: var(--paper);
}
.mobile-nav.open { display: flex; }

.mobile-nav-search {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink-soft);
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: 13px 14px;
  cursor: pointer;
  text-align: left;
}
.mobile-nav-search svg { width: 16px; height: 16px; flex-shrink: 0; }

.mobile-group summary {
  font-weight: 700;
  font-size: 1rem;
  padding: 13px 4px;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.mobile-group summary::-webkit-details-marker { display: none; }
.mobile-group summary::after {
  content: "+";
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--terracotta);
}
.mobile-group[open] summary::after { content: "–"; }
.mobile-group a {
  display: block;
  padding: 11px 16px;
  font-size: 0.95rem;
  text-decoration: none;
  color: var(--ink-soft);
  border-left: 2px solid var(--line);
  margin-left: 6px;
}
.mobile-group a:active { color: var(--green); }

.mobile-link {
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  padding: 13px 4px;
  border-top: 1.5px dashed var(--line);
}
.mobile-nav .btn { margin-top: 14px; }

/* Herói ---------------------------------------------------------------------- */

.hero {
  position: relative;
  padding: clamp(48px, 7vw, 88px) 0 28px;
  overflow: hidden;
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 48px;
  align-items: center;
}

.hero-copy h1 { margin: 14px 0 18px; }
.hero-sub {
  font-size: 1.12rem;
  color: var(--ink-soft);
  max-width: 50ch;
  margin-bottom: 28px;
}
.hero-sub a {
  color: var(--green-deep);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--line-strong);
  text-underline-offset: 2px;
  transition: color 0.12s ease, text-decoration-color 0.12s ease;
}
.hero-sub a:hover { color: var(--terracotta); text-decoration-color: var(--terracotta); }

.hero-search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--card);
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  padding: 7px 7px 7px 20px;
  box-shadow: var(--shadow-pop);
  max-width: 540px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.hero-search:focus-within {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 rgba(35, 42, 32, 0.9);
}
.hero-search-icon { width: 18px; height: 18px; color: var(--ink-soft); flex-shrink: 0; }
.hero-search input {
  flex: 1;
  min-width: 0;
  border: none;
  background: none;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  outline: none;
}
.hero-search input::placeholder { color: var(--ink-soft); opacity: 0.75; }

.hero-chips {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}
.chips-label { font-size: 0.85rem; color: var(--ink-soft); font-weight: 600; margin-right: 2px; }
.chip {
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--green-deep);
  background: #e4ecdf;
  border: 1.5px solid var(--green);
  border-radius: 999px;
  padding: 6px 14px;
  transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.chip:hover {
  background: var(--green);
  color: var(--paper);
  transform: translateY(-2px);
}

/* Composição decorativa do herói */
.hero-art {
  position: relative;
  min-height: 380px;
}

.art-card {
  position: absolute;
  background: var(--card);
  border: 1.5px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow-pop);
}

.art-receipt {
  width: min(270px, 70%);
  top: 8%;
  left: 6%;
  padding: 20px 20px 0;
  transform: rotate(-4deg);
  animation: float 7s ease-in-out infinite;
}
.art-receipt-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
}
.art-pill { width: 34px; height: 10px; border-radius: 999px; background: var(--terracotta); }

.art-lines { display: flex; flex-direction: column; gap: 9px; }
.art-lines span { height: 7px; border-radius: 999px; background: var(--paper-deep); }
.art-lines.light span { background: rgba(248, 243, 232, 0.28); }

.art-receipt-value {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--green);
  margin: 16px 0 8px;
}
.art-signature { color: var(--ink); padding-bottom: 4px; }
.art-signature svg { width: 110px; height: 26px; }
.art-sig-line { display: block; height: 1.5px; background: var(--line-strong); width: 130px; margin-top: -4px; }
.art-zigzag { margin: 14px -20px 0; color: var(--line-strong); }
.art-zigzag svg { width: 100%; height: 9px; }

.art-calc {
  width: min(190px, 48%);
  right: 4%;
  bottom: 10%;
  padding: 14px;
  transform: rotate(3deg);
  background: var(--green);
  border-color: var(--green-deep);
  animation: float 8s ease-in-out 0.8s infinite;
}
.art-calc-display {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--paper);
  background: var(--green-deep);
  border-radius: 9px;
  padding: 9px 12px;
  text-align: right;
  margin-bottom: 11px;
}
.art-calc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
}
.art-calc-grid span {
  display: grid;
  place-items: center;
  aspect-ratio: 1.5;
  background: rgba(248, 243, 232, 0.14);
  border-radius: 8px;
  color: var(--paper);
  font-size: 0.85rem;
  font-weight: 600;
}

.art-sticker-free {
  position: absolute;
  top: 0;
  right: 12%;
  width: 96px;
  animation: spin-slow 24s linear infinite;
}
.sticker-text {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 19px;
  fill: var(--paper);
  font-style: italic;
}

.art-squiggle {
  position: absolute;
  bottom: 2%;
  left: 2%;
  width: 130px;
  height: 38px;
}

@keyframes float {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -10px; }
}
@keyframes spin-slow { to { transform: rotate(360deg); } }

/* Faixa de confiança */
.trust-strip {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: clamp(36px, 5vw, 60px);
  border-top: 1.5px dashed var(--line-strong);
  padding-top: 22px;
}
.trust-strip li {
  font-size: 0.92rem;
  color: var(--ink-soft);
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.trust-strip strong {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--ink);
}

/* Divisor ondulado ------------------------------------------------------- */

.wave-divider svg { width: 100%; height: 48px; }

/* Seções ------------------------------------------------------------------- */

.section { padding: clamp(56px, 8vw, 96px) 0; }

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: clamp(28px, 4vw, 44px);
}
.section-head h2 { margin-top: 10px; }
.section-head-center {
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* Ferramentas ---------------------------------------------------------------- */

.section-tools { background: var(--paper-deep); padding-top: clamp(36px, 5vw, 64px); }

.tools-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.tool-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 26px 24px 22px;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.tool-card:hover {
  transform: translate(-3px, -3px);
  border-color: var(--ink);
  box-shadow: var(--shadow-pop), var(--shadow-md);
}
.tool-card h3 { font-size: 1.22rem; }
.tool-card p { font-size: 0.93rem; color: var(--ink-soft); flex: 1; }

.tool-badge {
  position: absolute;
  top: -12px;
  right: 18px;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 4px 12px;
  border-radius: 999px;
  border: 1.5px solid var(--ink);
}
.badge-hot { background: var(--mustard); color: var(--ink); box-shadow: 2px 2px 0 rgba(35, 42, 32, 0.9); }

.tool-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  border: 1.5px solid currentColor;
  margin-bottom: 4px;
}
.tool-icon svg { width: 26px; height: 26px; }
.icon-green { color: var(--green); background: #e4ecdf; }
.icon-terracotta { color: var(--terracotta); background: var(--terracotta-soft); }
.icon-mustard { color: #9a6f14; background: var(--mustard-soft); }

.tool-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 6px;
  padding-top: 14px;
  border-top: 1.5px dashed var(--line);
}
.pill-free, .pill-premium {
  font-size: 0.72rem;
  font-weight: 700;
  border-radius: 999px;
  padding: 3px 11px;
  letter-spacing: 0.03em;
}
.pill-free { background: #e4ecdf; color: var(--green-deep); border: 1px solid var(--green); }
.pill-premium { background: var(--paper); color: var(--ink-soft); border: 1px dashed var(--line-strong); }

/* Categorias (índice do site) ---------------------------------------------- */

.section-note {
  font-size: 0.92rem;
  color: var(--ink-soft);
  max-width: 32ch;
  text-align: right;
}

.cat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.cat-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 22px 18px;
  overflow: hidden;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.cat-card:hover { transform: translateY(-3px); border-color: var(--green); box-shadow: var(--shadow-md); }
.cat-head { position: relative; padding-right: 56px; }
.cat-card h3 { font-size: 1.12rem; }
.cat-card h3 a { text-decoration: none; color: inherit; }
.cat-card h3 a:hover { color: var(--green-deep); }
.cat-count { font-size: 0.82rem; color: var(--ink-soft); margin-top: 2px; }
.cat-num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 2.4rem;
  font-weight: 500;
  color: var(--terracotta);
  opacity: 0.35;
  position: absolute;
  right: 0;
  top: -6px;
  transition: opacity 0.18s ease;
}
.cat-card:hover .cat-num { opacity: 0.8; }

.cat-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  border-top: 1.5px dashed var(--line);
  padding-top: 6px;
}
.cat-links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ink-soft);
  text-decoration: none;
  padding: 7px 2px;
  border-radius: 8px;
  transition: color 0.12s ease, padding-left 0.12s ease;
}
.cat-links a::after {
  content: "→";
  opacity: 0;
  transition: opacity 0.12s ease;
  color: var(--terracotta);
}
.cat-links a:hover { color: var(--green-deep); padding-left: 6px; }
.cat-links a:hover::after { opacity: 1; }

/* Premium -------------------------------------------------------------------- */

.section-premium { padding-top: 0; }

.premium-box {
  position: relative;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 40px;
  align-items: center;
  background: var(--green-deep);
  color: var(--paper);
  border-radius: 28px;
  border: 1.5px solid var(--ink);
  box-shadow: 6px 6px 0 rgba(35, 42, 32, 0.9);
  padding: clamp(36px, 5vw, 64px);
  overflow: hidden;
}
/* Textura de linhas diagonais no fundo do bloco premium */
.premium-box::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28'%3E%3Cpath d='M-4 8L8 -4M-4 22L22 -4M6 32L32 6M20 36L36 20' stroke='%23f8f3e8' stroke-opacity='0.05' stroke-width='2'/%3E%3C/svg%3E");
  pointer-events: none;
}
.premium-box > * { position: relative; }

.premium-box h2 { color: var(--paper); margin: 12px 0 14px; }
.premium-box h2 em { color: var(--mustard); }
.premium-sub { color: rgba(248, 243, 232, 0.78); max-width: 46ch; margin-bottom: 22px; }

.premium-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 13px;
  margin-bottom: 30px;
}
.premium-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.98rem;
}
.premium-list svg { width: 20px; height: 20px; flex-shrink: 0; margin-top: 2px; }

.premium-ctas { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.premium-note { font-size: 0.85rem; color: rgba(248, 243, 232, 0.7); }

.premium-art { display: grid; place-items: center; }
.premium-doc {
  position: relative;
  width: min(300px, 100%);
  background: rgba(248, 243, 232, 0.08);
  border: 1.5px solid rgba(248, 243, 232, 0.35);
  border-radius: var(--radius);
  padding: 18px 20px 30px;
  transform: rotate(2.5deg);
}
.premium-doc-bar { display: flex; gap: 6px; margin-bottom: 18px; }
.premium-doc-bar span {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: rgba(248, 243, 232, 0.4);
}
.premium-stamp {
  position: absolute;
  right: -22px;
  bottom: -22px;
  width: 104px;
  background: var(--paper);
  border-radius: 50%;
  padding: 7px;
  box-shadow: var(--shadow-md);
  transform: rotate(-12deg);
}
.stamp-text {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.08em;
  fill: var(--terracotta);
}

/* Como funciona ------------------------------------------------------------ */

.section-how { background: var(--paper-deep); }

.steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  counter-reset: passo;
}
.step {
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px 26px;
  box-shadow: var(--shadow-sm);
}
.step-num {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--terracotta);
  color: var(--paper);
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.3rem;
  font-weight: 600;
  border: 1.5px solid var(--ink);
  box-shadow: 2px 2px 0 rgba(35, 42, 32, 0.9);
  margin-bottom: 16px;
}
.step h3 { font-size: 1.15rem; margin-bottom: 6px; }
.step p { font-size: 0.93rem; color: var(--ink-soft); }

/* Dúvidas ------------------------------------------------------------------ */

.faq-container { max-width: 760px; }

.faq-list { display: flex; flex-direction: column; gap: 12px; }

.faq-item {
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.15s ease;
}
.faq-item[open] { border-color: var(--ink); box-shadow: var(--shadow-sm); }

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 600;
  padding: 18px 22px;
}
.faq-item summary::-webkit-details-marker { display: none; }

.faq-icon {
  position: relative;
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  background: var(--mustard-soft);
}
.faq-icon::before, .faq-icon::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  background: var(--ink);
  transition: transform 0.2s ease;
}
.faq-icon::before { width: 11px; height: 1.7px; }
.faq-icon::after { width: 1.7px; height: 11px; }
.faq-item[open] .faq-icon::after { transform: rotate(90deg); }

.faq-item p {
  padding: 0 22px 20px;
  color: var(--ink-soft);
  font-size: 0.96rem;
  max-width: 62ch;
}
.faq-item p a {
  color: var(--green-deep);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--green);
  text-underline-offset: 2px;
}
.faq-item p a:hover { color: var(--terracotta); text-decoration-color: var(--terracotta); }

/* CTA final --------------------------------------------------------------- */

.section-cta { padding-top: 0; }

.cta-box {
  position: relative;
  text-align: center;
  background: var(--terracotta-soft);
  border: 1.5px solid var(--ink);
  border-radius: 28px;
  box-shadow: 6px 6px 0 rgba(35, 42, 32, 0.9);
  padding: clamp(48px, 7vw, 80px) 24px;
  overflow: hidden;
}
.cta-box h2 { margin-bottom: 12px; }
.cta-box p { color: var(--ink-soft); margin-bottom: 28px; }
.cta-actions {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}
.cta-burst {
  position: absolute;
  width: 64px;
  height: 64px;
  top: 26px;
  left: 8%;
  animation: spin-slow 20s linear infinite;
}

/* Rodapé --------------------------------------------------------------------- */

.site-footer {
  background: var(--ink);
  color: rgba(248, 243, 232, 0.82);
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 36px;
  padding: clamp(48px, 6vw, 72px) 20px 36px;
}
.logo-footer .logo-text { color: var(--paper); }
.footer-brand p {
  font-size: 0.92rem;
  margin-top: 16px;
  max-width: 30ch;
  color: rgba(248, 243, 232, 0.6);
}
.footer-social { margin-top: 16px; }
.footer-social a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  color: rgba(248, 243, 232, 0.7);
  transition: color 0.15s ease;
}
.footer-social a:hover { color: var(--mustard); }
.footer-social svg { width: 18px; height: 18px; }

.footer-col { display: flex; flex-direction: column; gap: 4px; }
.footer-title {
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--paper);
  margin-bottom: 10px;
}
.footer-col a {
  font-size: 0.92rem;
  text-decoration: none;
  color: rgba(248, 243, 232, 0.7);
  padding: 5px 0;
  width: fit-content;
  border-bottom: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.footer-col a:hover { color: var(--mustard); border-color: var(--mustard); }
.footer-col a.footer-all { color: var(--mustard); font-weight: 600; margin-top: 4px; }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  border-top: 1px solid rgba(248, 243, 232, 0.15);
  padding-top: 22px;
  padding-bottom: 30px;
  font-size: 0.82rem;
  color: rgba(248, 243, 232, 0.55);
}
.footer-bottom p { display: flex; align-items: center; gap: 6px; }
.heart { width: 14px; height: 12px; }
.footer-credit {
  color: var(--mustard);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.15s ease;
}
.footer-credit:hover { border-color: var(--mustard); }

/* Busca (overlay) ------------------------------------------------------------- */

.search-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: clamp(16px, 10vh, 120px) 16px 16px;
}
.search-overlay[hidden] { display: none; }

.search-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(35, 42, 32, 0.55);
  backdrop-filter: blur(3px);
  animation: fade-in 0.2s ease;
}

.search-panel {
  position: relative;
  width: min(620px, 100%);
  background: var(--card);
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-pop), 0 24px 60px rgba(35, 42, 32, 0.35);
  overflow: hidden;
  animation: panel-in 0.22s cubic-bezier(0.2, 0.9, 0.3, 1.2);
}
@keyframes fade-in { from { opacity: 0; } }
@keyframes panel-in {
  from { opacity: 0; transform: translateY(14px) scale(0.98); }
}

.search-panel-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1.5px solid var(--line);
}
.search-panel-head svg { width: 18px; height: 18px; color: var(--ink-soft); flex-shrink: 0; }
.search-panel-head input {
  flex: 1;
  min-width: 0;
  border: none;
  background: none;
  outline: none;
  font-family: var(--font-body);
  font-size: 1.05rem;
  color: var(--ink);
}
.search-close {
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-soft);
  background: var(--paper);
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 7px;
  padding: 4px 9px;
  cursor: pointer;
}
.search-close:hover { color: var(--ink); border-color: var(--ink); }

.search-results {
  list-style: none;
  max-height: min(420px, 55vh);
  overflow-y: auto;
  padding: 8px;
}
.search-result a {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  padding: 12px 14px;
  border-radius: 12px;
}
.search-result a:hover, .search-result a:focus-visible, .search-result.active a { background: var(--paper-deep); }
.search-result .tool-icon {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  margin: 0;
  flex-shrink: 0;
}
.search-result .tool-icon svg { width: 20px; height: 20px; }
.search-result-name { font-weight: 600; font-size: 0.98rem; }
.search-result-name mark {
  background: var(--mustard-soft);
  color: inherit;
  border-radius: 3px;
  padding: 0 1px;
}
.search-result-cat { font-size: 0.78rem; color: var(--ink-soft); }

.search-empty {
  padding: 28px 22px;
  text-align: center;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.search-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.75rem;
  color: var(--ink-soft);
  border-top: 1.5px solid var(--line);
  padding: 10px 16px;
  background: var(--paper);
}
.search-hint kbd {
  font-family: var(--font-body);
  font-size: 0.7rem;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 5px;
  padding: 0 5px;
  background: var(--card);
}
.link-try {
  font-family: var(--font-body);
  font-size: inherit;
  font-weight: 700;
  color: var(--terracotta);
  background: none;
  border: none;
  border-bottom: 1.5px dashed var(--terracotta);
  cursor: pointer;
  padding: 0;
}

/* Toast (aviso de página em construção) ---------------------------------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%) translateY(10px);
  background: var(--ink);
  color: var(--paper);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 13px 22px;
  border-radius: 999px;
  border: 1.5px solid rgba(248, 243, 232, 0.25);
  box-shadow: var(--shadow-md);
  max-width: min(90vw, 420px);
  text-align: center;
  z-index: 500;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
}
.toast.show {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%);
}

/* Animações de entrada --------------------------------------------------------
   Conteúdo é VISÍVEL por padrão (sem JS = página íntegra, robôs leem tudo).
   A animação só roda quando o JS adiciona .in ao entrar no viewport. */

@keyframes fade-up {
  from { opacity: 0; transform: translateY(18px); }
}
.reveal.in { animation: fade-up 0.55s ease both; }

/* Entrada do herói: CSS puro no carregamento, independente de JS */
@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
}
.hero-copy > * { animation: rise 0.6s ease backwards; }
.hero-copy > :nth-child(1) { animation-delay: 0.05s; }
.hero-copy > :nth-child(2) { animation-delay: 0.13s; }
.hero-copy > :nth-child(3) { animation-delay: 0.21s; }
.hero-copy > :nth-child(4) { animation-delay: 0.29s; }
.hero-copy > :nth-child(5) { animation-delay: 0.37s; }
.hero-art { animation: rise 0.7s ease backwards 0.3s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal.in, .hero-copy > *, .hero-art { animation: none; }
  .art-receipt, .art-calc, .art-sticker-free, .cta-burst, .topbar-dot { animation: none; }
}

/* Foco visível */
:focus-visible {
  outline: 2.5px solid var(--terracotta);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Responsivo ------------------------------------------------------------------ */

@media (max-width: 1024px) {
  .tools-grid { grid-template-columns: repeat(2, 1fr); }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-inner { gap: 28px; }
}

/* CTA Premium compacto — só aparece no mobile (no header bar) */
.btn-premium-mobile { display: none; }

@media (max-width: 860px) {
  .main-nav { display: none; }
  .hamburger { display: flex; }
  .btn-header { display: none; }
  .account { display: none; }
  .btn-premium-mobile { display: inline-flex; padding: 9px 16px; font-size: 0.9rem; }
  .search-btn-label, .search-kbd { display: none; }
  .search-btn { padding: 11px; border-radius: 12px; }

  .hero-inner { grid-template-columns: 1fr; }
  .hero-art { min-height: 300px; margin-top: 8px; }
  .art-receipt { left: 0; }
  .art-calc { right: 0; }

  .trust-strip { grid-template-columns: repeat(2, 1fr); gap: 18px 12px; }

  .premium-box { grid-template-columns: 1fr; }
  .premium-art { padding: 8px 24px 18px 0; justify-content: start; }

  .steps { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  .tools-grid { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: 1fr; }

  /* Topbar em uma linha só */
  .topbar-extra { display: none; }

  /* H1 mais compacto para caber em 2 linhas no celular */
  h1 { font-size: clamp(1.7rem, 7.2vw, 2.1rem); }

  .hero { padding-top: 36px; }
  .hero-search { flex-wrap: wrap; padding: 10px; border-radius: var(--radius-lg); }
  .hero-search input { width: 100%; padding: 6px 4px 10px; }
  .hero-search .btn { width: 100%; }
  .hero-search-icon { display: none; }

  .section-head .btn { width: 100%; }
  .section-note { text-align: left; }
  .search-hint { display: none; }
  .cta-actions .btn { width: 100%; }
  .premium-ctas .btn { width: 100%; }
  .cta-burst { width: 44px; height: 44px; top: 16px; left: 16px; }

  .footer-inner { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { justify-content: center; text-align: center; }
}
