/* ===========================================================
   Escuta Cultural — Design system
   Pesquisa • Trabalho • Saúde mental
   =========================================================== */

:root {
  /* Paleta extraída do logo */
  --cream: #f4ebe0;
  --cream-soft: #faf4ec;
  --cream-alt: #efe1d1;
  --terracotta: #b8492a;
  --terracotta-dark: #96391f;
  --ochre: #e0a23a;
  --ochre-dark: #c6862a;
  --olive: #9b9a6d;
  --olive-dark: #7d7c54;
  --ink: #2a2420;
  --ink-soft: #5c5247;
  --ink-faint: #8a8074;
  --white: #ffffff;
  --border: #e3d5c3;

  --font-head: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 30px -14px rgba(42, 36, 32, 0.25);
  --container: 1180px;

  --focus: 3px solid #1a5fb4;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream-soft);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.1rem, 4vw, 3.2rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 2.8vw, 2.3rem); font-weight: 800; }
h3 { font-size: 1.25rem; font-weight: 700; }
h4 { font-size: 1.05rem; font-weight: 700; }

p { margin: 0 0 1em; color: var(--ink-soft); }

a {
  color: var(--terracotta-dark);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}

a:hover { color: var(--terracotta); }

img { max-width: 100%; display: block; }

ul, ol { padding-left: 1.3em; color: var(--ink-soft); }
li { margin-bottom: 0.4em; }

/* Focus visibility — never remove outline, only restyle */
:focus-visible {
  outline: var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -3.5rem;
  background: var(--ink);
  color: var(--white);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  z-index: 200;
  transition: top 0.15s ease;
  font-weight: 600;
}

.skip-link:focus {
  top: 1rem;
}

/* ---------- Layout helpers ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 4.5rem 0;
}

.section--alt {
  background: var(--cream-alt);
}

.section--dark {
  background: var(--ink);
  color: var(--cream);
}

.section--dark h2, .section--dark h3, .section--dark p { color: var(--cream); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--terracotta-dark);
  margin-bottom: 0.9rem;
}

.lede {
  font-size: 1.15rem;
  max-width: 62ch;
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  overflow: hidden;
  white-space: nowrap;
}

/* ---------- Header / nav ---------- */
.site-header {
  background: var(--cream-soft);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.6rem 1.5rem;
  max-width: var(--container);
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  flex-shrink: 0;
}

.brand img {
  height: 46px;
  width: auto;
}

.brand:hover { color: inherit; }

.primary-nav {
  display: flex;
  align-items: center;
  gap: 1.9rem;
  min-width: 0;
}

.primary-nav ul {
  list-style: none;
  display: flex;
  gap: 1.3rem;
  margin: 0;
  padding: 0;
  flex-wrap: nowrap;
}

.primary-nav a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
  padding: 0.35rem 0.1rem;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}

.primary-nav a:hover {
  color: var(--terracotta-dark);
}

.primary-nav a[aria-current="page"] {
  color: var(--terracotta-dark);
  border-bottom-color: var(--terracotta);
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--white);
  cursor: pointer;
}

.nav-toggle svg { width: 22px; height: 22px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.98rem;
  padding: 0.85rem 1.5rem;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  line-height: 1;
  transition: transform 0.12s ease, background-color 0.12s ease, color 0.12s ease, box-shadow 0.12s ease;
  white-space: nowrap;
}

.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--terracotta);
  color: var(--white);
  border-color: var(--terracotta);
}
.btn-primary:hover { background: var(--terracotta-dark); border-color: var(--terracotta-dark); color: var(--white); }

.btn-secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink);
}
.btn-secondary:hover { background: var(--ink); color: var(--white); }

.btn-ghost {
  background: var(--white);
  color: var(--terracotta-dark);
  border-color: var(--border);
}
.btn-ghost:hover { border-color: var(--terracotta); }

.btn-lg { padding: 1rem 1.9rem; font-size: 1.05rem; }
.btn-sm { padding: 0.55rem 1.1rem; font-size: 0.88rem; }
.btn-block { width: 100%; justify-content: center; }

.btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

.header-cta { flex-shrink: 0; }

/* ---------- Hero ---------- */
.hero {
  padding: 3.2rem 0 0;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 2.5rem;
  align-items: center;
}

.hero-logo {
  height: 125px;
  width: auto;
  display: block;
  margin-left: 0;
  margin-right: auto;
  margin-bottom: 1.6rem;
}

.hero-copy .lede { margin-bottom: 1.7rem; }

.hero-cta-row {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  flex-wrap: wrap;
  margin-top: 1.6rem;
}

.time-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink-soft);
}

.time-chip svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--terracotta); }

.hero-visual {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 5 / 4;
  background: linear-gradient(135deg, var(--ink) 0%, #3a2f27 100%);
  box-shadow: var(--shadow);
}

.hero-visual .arches {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-visual svg { width: 72%; height: 72%; }

.hero-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-visual figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 1rem 1.3rem;
  font-size: 0.78rem;
  color: var(--cream);
  background: linear-gradient(0deg, rgba(0,0,0,0.6), transparent);
}

/* ---------- Feature cards (quick nav) ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin-top: 3.2rem;
}

.feature-card {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding: 2rem 1.6rem;
  border-right: 1px solid var(--border);
  text-decoration: none;
  color: var(--ink);
}

.feature-card:last-child { border-right: none; }

.feature-card:hover { background: var(--cream-alt); }

.feature-icon {
  width: 42px; height: 42px;
  border-radius: 10px;
  background: var(--terracotta);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-icon svg { width: 22px; height: 22px; }

.feature-card h3 { margin-bottom: 0.15rem; font-size: 1.08rem; }
.feature-card p { font-size: 0.92rem; margin: 0; }

/* ---------- Split section (image/text) ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
}

.split-visual {
  min-height: 360px;
  position: relative;
  background: linear-gradient(160deg, var(--terracotta) 0%, var(--terracotta-dark) 55%, var(--ink) 100%);
  display: flex;
  align-items: flex-end;
  padding: 2rem;
}

.split-visual .tag {
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.1rem;
  padding: 0.9rem 1.3rem;
  border-radius: var(--radius-sm);
  transform: rotate(-2deg);
  box-shadow: var(--shadow);
}

.split-copy {
  padding: 3.5rem 3rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* ---------- Generic content grid / cards ---------- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.8rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.6rem; }

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.8rem;
}

.card--accent {
  border-left: 5px solid var(--terracotta);
}

.stat {
  font-family: var(--font-head);
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--terracotta-dark);
}

.pill {
  display: inline-block;
  background: var(--cream-alt);
  border: 1px solid var(--border);
  color: var(--ink-soft);
  border-radius: 999px;
  padding: 0.3rem 0.8rem;
  font-size: 0.82rem;
  font-weight: 600;
  margin: 0 0.4rem 0.4rem 0;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  display: grid;
  gap: 1.1rem;
}

.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 3.2rem;
  margin: 0;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0; top: -0.1rem;
  width: 2.3rem; height: 2.3rem;
  border-radius: 50%;
  background: var(--ochre);
  color: var(--ink);
  font-family: var(--font-head);
  font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

th, td {
  text-align: left;
  padding: 0.9rem 1.1rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
  font-size: 0.95rem;
}

th { background: var(--cream-alt); font-family: var(--font-head); }

tr:last-child td { border-bottom: none; }

blockquote {
  margin: 0;
  padding: 1.6rem 1.9rem;
  background: var(--cream-alt);
  border-left: 5px solid var(--ochre);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 1.15rem;
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--ink);
}

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--terracotta);
  color: var(--white);
  text-align: center;
  padding: 4rem 1.5rem;
}

.cta-band h2, .cta-band p { color: var(--white); }
.cta-band .lede { margin: 0 auto 1.8rem; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink);
  color: var(--cream);
  padding: 3.5rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(244,235,224,0.15);
}

.footer-logo-chip {
  display: inline-block;
  background: var(--cream);
  padding: 0.6rem 0.9rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1.1rem;
  line-height: 0;
}
.footer-logo-chip img { height: 34px; }
.footer-brand p { color: #cfc3b4; max-width: 32ch; }

.site-footer h4 { color: var(--cream); margin-bottom: 1rem; font-size: 0.95rem; letter-spacing: 0.03em; text-transform: uppercase; }

.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 0.6rem; }
.site-footer a { color: #d9cfc2; text-decoration: none; font-size: 0.95rem; }
.site-footer a:hover { color: var(--ochre); text-decoration: underline; }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding-top: 1.6rem;
  font-size: 0.85rem;
  color: #a79c8c;
}

/* ===========================================================
   Formulário — Participar
   =========================================================== */

.form-shell {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.form-progress-wrap {
  padding: 1.5rem 2rem 1.2rem;
  border-bottom: 1px solid var(--border);
  background: var(--cream-soft);
}

.form-progress-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--ink-soft);
  margin-bottom: 0.6rem;
}

.progress-track {
  height: 10px;
  background: var(--border);
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--terracotta);
  border-radius: 999px;
  width: 0%;
  transition: width 0.25s ease;
}

.form-step {
  padding: 2.5rem 2.2rem;
}

.form-step[hidden] { display: none; }

.step-kicker {
  color: var(--terracotta-dark);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.4rem;
}

.step-desc {
  margin-bottom: 1.8rem;
  max-width: 68ch;
}

fieldset.q {
  border: none;
  border-top: 1px solid var(--border);
  padding: 1.4rem 0;
  margin: 0;
}

fieldset.q:first-of-type { border-top: none; padding-top: 0; }

fieldset.q legend {
  font-weight: 700;
  color: var(--ink);
  padding: 0;
  margin-bottom: 0.9rem;
  font-size: 1.01rem;
  float: left;
  width: 100%;
}

.q-optional {
  font-weight: 500;
  font-size: 0.82rem;
  color: var(--ink-faint);
  text-transform: none;
  letter-spacing: 0;
  margin-left: 0.4rem;
}

.q-hint {
  font-size: 0.86rem;
  color: var(--ink-faint);
  margin: -0.5rem 0 0.9rem;
  clear: both;
}

.options {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  clear: both;
}

.option {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  padding: 0.55rem 0.8rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  background: var(--white);
}

.option:hover { border-color: var(--ochre); background: var(--cream-soft); }

.option input[type="radio"],
.option input[type="checkbox"] {
  margin-top: 0.2rem;
  width: 18px; height: 18px;
  accent-color: var(--terracotta);
  flex-shrink: 0;
}

.option span { font-size: 0.97rem; color: var(--ink); }

.options.scale {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.options.scale .option {
  flex: 1 1 140px;
  justify-content: center;
  text-align: center;
  flex-direction: column;
  align-items: center;
  padding: 0.7rem 0.5rem;
}

textarea, input[type="text"] {
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.97rem;
  padding: 0.8rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--ink);
  clear: both;
  resize: vertical;
}

textarea:focus, input[type="text"]:focus {
  border-color: var(--terracotta);
}

.char-note {
  font-size: 0.8rem;
  color: var(--ink-faint);
  margin-top: 0.4rem;
}

.form-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1.6rem 2.2rem;
  background: var(--cream-soft);
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
}

.form-nav-right { display: flex; gap: 0.8rem; }

.consent-gate {
  padding: 3rem 2.2rem;
}

.consent-box {
  background: var(--cream-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.6rem 1.8rem;
  margin: 1.6rem 0;
}

.consent-box ul { margin: 0.6rem 0 0; }

.status-banner {
  padding: 1rem 1.3rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  margin-bottom: 1.5rem;
  display: none;
}

.status-banner.show { display: block; }

.status-banner.error {
  background: #fbeae5;
  color: #96391f;
  border: 1px solid #e3b7a6;
}

.success-panel {
  text-align: center;
  padding: 4.5rem 2rem;
}

.success-icon {
  width: 70px; height: 70px;
  border-radius: 50%;
  background: var(--olive);
  color: var(--white);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1.5rem;
}

.success-icon svg { width: 34px; height: 34px; }

/* ---------- Content page helpers ---------- */
.page-hero {
  padding: 3.2rem 0 3rem;
  border-bottom: 1px solid var(--border);
}

.page-hero .lede { margin-top: 0.5rem; }

.breadcrumb {
  font-size: 0.85rem;
  color: var(--ink-faint);
  margin-bottom: 1rem;
}

.breadcrumb a { color: var(--ink-faint); }

.prose h2 { margin-top: 2.4rem; }
.prose h3 { margin-top: 1.8rem; }

.notice {
  background: var(--cream-alt);
  border: 1px solid var(--border);
  border-left: 5px solid var(--olive);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.3rem 1.6rem;
  margin: 1.5rem 0;
}

.coming-soon {
  text-align: center;
  padding: 5rem 2rem;
  background: var(--cream-alt);
  border-radius: var(--radius);
  border: 1px dashed var(--border);
}

.coming-soon .feature-icon { margin: 0 auto 1.3rem; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { order: -1; aspect-ratio: 16/9; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .feature-card:nth-child(2) { border-right: none; }
  .feature-card { border-bottom: 1px solid var(--border); }
  .split { grid-template-columns: 1fr; }
  .split-copy { padding: 2.8rem 1.8rem; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 820px) {
  .primary-nav { display: none; }
  .nav-toggle { display: flex; }
  .site-header.nav-open .primary-nav {
    display: block;
    position: fixed;
    inset: 0;
    background: var(--cream-soft);
    padding: 5.5rem 1.5rem 2rem;
    overflow-y: auto;
  }
  .site-header.nav-open .primary-nav ul {
    flex-direction: column;
    gap: 0.2rem;
  }
  .site-header.nav-open .primary-nav a {
    display: block;
    padding: 0.9rem 0.3rem;
    font-size: 1.15rem;
    border-bottom: 1px solid var(--border);
  }
  .header-cta .btn span.full { display: none; }
}

@media (max-width: 640px) {
  .hero-logo { height: 93px; margin-bottom: 1.2rem; }
  .section { padding: 3rem 0; }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-card { border-right: none; }
  .options.scale { flex-direction: column; }
  .options.scale .option { flex-direction: row; justify-content: flex-start; }
  .form-step { padding: 1.8rem 1.3rem; }
  .form-nav { padding: 1.2rem 1.3rem; }
  .footer-grid { grid-template-columns: 1fr; }
}
