/* Databozz — estilos do site
   Paleta da marca: névoa #F2F1EE, grafite #1C1B1F, bordô #7A1F3D.
   Tipografia: Archivo (variável), usando o eixo de largura nos títulos. */

@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-var.woff2") format("woff2");
  font-weight: 300 700;
  font-stretch: 100% 125%;
  font-style: normal;
  font-display: swap;
}

:root {
  --nevoa: #F2F1EE;
  --nevoa-2: #E9E7E2;
  --papel: #FBFAF8;
  --grafite: #1C1B1F;
  --aco: #5E5D63;
  --aco-claro: #A9A7AD;
  --bordo: #7A1F3D;
  --bordo-escuro: #5F1830;
  --rosa: #D88AA2;
  --linha: #D6D3CD;
  --linha-forte: #B9B6AF;
  --linha-escura: #3A383F;

  --f: "Archivo", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  /* escala tipográfica clássica (14 · 17 · 21 · 24 · 36 · 48 · 60 · 72) */
  --t-sm: 0.875rem;
  --t-body: 1.0625rem;
  --t-lead: 1.3125rem;
  --t-h3: 1.5rem;
  --t-h2: clamp(2rem, 1.4rem + 2.2vw, 3rem);
  --t-h1: clamp(2.6rem, 1.5rem + 4.6vw, 4.5rem);

  --wrap: 1240px;
  --gutter: clamp(20px, 5vw, 56px);
  --section: clamp(80px, 10vw, 144px);
  --r: 6px;
  --header-h: 72px;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--nevoa);
  color: var(--grafite);
  font-family: var(--f);
  font-size: var(--t-body);
  font-weight: 400;
  line-height: 1.6;
  font-kerning: normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

[hidden] { display: none !important; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }

h1, h2, h3 {
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.012em;
  text-wrap: balance;
}
h2 { font-size: var(--t-h2); font-stretch: 112%; }
h3 { font-size: var(--t-h3); font-stretch: 106%; font-weight: 600; line-height: 1.2; letter-spacing: -0.005em; }
p { text-wrap: pretty; }

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

:focus-visible {
  outline: 2px solid var(--bordo);
  outline-offset: 3px;
  border-radius: 2px;
}
.section--dark :focus-visible,
.site-footer :focus-visible { outline-color: var(--rosa); }

.skip {
  position: absolute;
  left: 12px;
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--grafite);
  color: var(--nevoa);
  border-radius: var(--r);
  text-decoration: none;
}
.skip:focus { top: 12px; }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 22px;
  border: 1px solid transparent;
  border-radius: var(--r);
  font-weight: 600;
  font-stretch: 104%;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.btn--primary { background: var(--bordo); color: var(--nevoa); }
.btn--primary:hover { background: var(--bordo-escuro); }
.btn--primary:disabled { opacity: .6; cursor: progress; }
.btn--ghost { border-color: var(--linha-forte); color: var(--grafite); }
.btn--ghost:hover { border-color: var(--grafite); }
.btn--sm { min-height: 40px; padding: 8px 16px; font-size: .9375rem; }

/* ---------- Cabeçalho ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(242, 241, 238, .9);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--linha); }
.header-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  min-height: var(--header-h);
}
.brand { flex: none; margin-right: auto; }
.brand img { width: 148px; height: auto; }

.nav ul {
  display: flex;
  gap: 32px;
  list-style: none;
}
.nav a {
  font-size: .9375rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--aco);
  transition: color .15s ease;
}
.nav a:hover { color: var(--grafite); }

.nav-toggle {
  display: none;
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid var(--linha-forte);
  border-radius: var(--r);
  background: transparent;
  font-size: .9375rem;
  font-weight: 600;
  cursor: pointer;
}

@media (max-width: 880px) {
  .header-inner { gap: 12px; }
  .nav-toggle { display: inline-flex; align-items: center; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--nevoa);
    border-bottom: 1px solid var(--linha);
    padding: 8px var(--gutter) 24px;
  }
  .nav.is-open { display: block; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav a {
    display: block;
    padding: 14px 0;
    font-size: 1.125rem;
    color: var(--grafite);
    border-bottom: 1px solid var(--linha);
  }
}
@media (max-width: 440px) {
  .header-cta { display: none; }
  .brand img { width: 128px; }
}

/* ---------- Topo (hero) ---------- */
.hero { padding-top: clamp(48px, 8vw, 112px); padding-bottom: clamp(56px, 7vw, 96px); }
.hero-title {
  font-size: var(--t-h1);
  font-stretch: 116%;
  font-weight: 500;
  line-height: 1.02;
  letter-spacing: -0.022em;
  text-wrap: balance;
}
.hero-row {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 48px;
  align-items: end;
  margin-top: clamp(28px, 4vw, 48px);
}
.hero-lead {
  font-size: var(--t-lead);
  line-height: 1.5;
  color: var(--aco);
  max-width: 34em;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
}
@media (max-width: 880px) {
  .hero-row { grid-template-columns: 1fr; gap: 28px; }
  .hero-actions { justify-content: flex-start; }
}

/* gráfico de tendência (papel de registrador) */
.trend-figure {
  margin-top: clamp(48px, 6vw, 80px);
  padding: clamp(16px, 2.4vw, 28px) clamp(12px, 2vw, 28px) 0;
  background: var(--papel);
  border: 1px solid var(--linha);
  border-radius: 4px;
}
.trend { width: 100%; height: auto; font-family: var(--f); overflow: visible; }
.trend--medium, .trend--narrow { display: none; }
@media (max-width: 1100px) {
  .trend--wide { display: none; }
  .trend--medium { display: block; }
}
@media (max-width: 680px) {
  .trend--medium { display: none; }
  .trend--narrow { display: block; }
}
.g-minor { stroke: #ECEAE5; stroke-width: 1; }
.g-major { stroke: #DCD9D3; stroke-width: 1; }
.c-thr { stroke: var(--grafite); stroke-width: 1.25; stroke-dasharray: 6 6; opacity: .5; }
.c-thr-label { fill: var(--aco); font-size: .9em; }
.c-band { fill: var(--bordo); opacity: .13; }
.c-today { stroke: var(--grafite); stroke-width: 1; opacity: .45; }
.c-measured { fill: none; stroke: var(--grafite); stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; }
.c-forecast { fill: none; stroke: var(--bordo); stroke-width: 2.5; stroke-linecap: round; }
.c-hit { fill: var(--bordo); stroke: var(--papel); stroke-width: 3; }
.c-ann-line { stroke: var(--bordo); stroke-width: 1; }
.c-ann-strong { fill: var(--bordo); font-weight: 600; }
.c-ann-text { fill: var(--grafite); }
.c-tick, .c-unit { fill: var(--aco); font-size: .88em; font-variant-numeric: tabular-nums; }

.trend-caption {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 24px;
  padding: 18px 0 20px;
  margin-top: 8px;
  border-top: 1px solid var(--linha);
  font-size: var(--t-sm);
  color: var(--aco);
}
.key { display: inline-flex; align-items: center; gap: 10px; color: var(--grafite); font-weight: 500; }
.key::before {
  content: "";
  width: 24px;
  height: 12px;
  background: linear-gradient(var(--grafite), var(--grafite)) center / 100% 2px no-repeat;
}
.key--forecast::before {
  background: linear-gradient(var(--bordo), var(--bordo)) center / 100% 3px no-repeat, rgba(122, 31, 61, .16);
}
.trend-note { flex: 1 1 280px; text-align: right; }
@media (max-width: 720px) { .trend-note { text-align: left; } }

@media (prefers-reduced-motion: no-preference) {
  .c-measured { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 2.4s cubic-bezier(.55, .05, .3, 1) .35s forwards; }
  .c-today, .c-band { animation: appear .8s ease 2.5s backwards; }
  .c-forecast { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 1.1s ease-out 2.8s forwards; }
  .c-hit, .c-ann { animation: appear .6s ease 3.8s backwards; }
}
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes appear { from { opacity: 0; } }

/* ---------- Frase de posicionamento ---------- */
.statement { padding-block: clamp(64px, 8vw, 112px) 0; border-top: 1px solid var(--linha); }
.statement-grid {
  display: grid;
  grid-template-columns: minmax(0, 8fr) minmax(0, 4fr);
  gap: 48px;
  align-items: end;
}
.statement-text {
  font-size: clamp(1.75rem, 1.2rem + 1.9vw, 2.75rem);
  font-stretch: 108%;
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: -0.015em;
  max-width: 24ch;
}
.statement-body { color: var(--aco); max-width: 34em; }
@media (max-width: 880px) { .statement-grid { grid-template-columns: 1fr; gap: 24px; } }

/* ---------- Seções ---------- */
.section { padding-block: var(--section); }
.section--tint { background: var(--nevoa-2); }
.section--dark { background: var(--grafite); color: var(--nevoa); }

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: 24px 64px;
  align-items: end;
  margin-bottom: clamp(40px, 6vw, 72px);
}
.section-head h2 { max-width: 16ch; }
.section-head p { color: var(--aco); max-width: 34em; justify-self: end; }
.section--dark .section-head p { color: var(--aco-claro); }
@media (max-width: 880px) {
  .section-head { grid-template-columns: 1fr; }
  .section-head p { justify-self: start; }
}

/* marcador em paralelogramo, herdado da diagonal do "Z" do símbolo */
.ticks li::before,
.next li::before {
  content: "";
  display: block;
  width: 7px;
  height: 11px;
  background: var(--bordo);
  transform: skewX(-38deg);
}

/* ---------- O que fazemos ---------- */
.services { border-bottom: 1px solid var(--linha); }
.service {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 24px 64px;
  padding-block: clamp(32px, 4vw, 48px);
  border-top: 1px solid var(--linha);
}
.service-name {
  font-size: clamp(1.625rem, 1.2rem + 1.2vw, 2.25rem);
  font-stretch: 114%;
  font-weight: 500;
  line-height: 1.1;
  max-width: 13ch;
}
.service-body > p { max-width: 38em; }
.service-claim { font-size: var(--t-lead); font-weight: 500; line-height: 1.35; margin-bottom: 12px; }
.service-body > p:not(.service-claim) { color: var(--aco); }
.ticks {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 32px;
  margin-top: 24px;
  font-size: .9688rem;
  line-height: 1.45;
}
.ticks li { display: grid; grid-template-columns: 14px 1fr; gap: 10px; align-items: baseline; }
.ticks li::before { position: relative; top: 1px; }
@media (max-width: 880px) { .service { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .ticks { grid-template-columns: 1fr; } }

/* ---------- Aplicações ---------- */
.uses-list { display: none; }
.use + .use { margin-top: 40px; padding-top: 40px; border-top: 1px solid var(--linha-forte); }
.use-title { font-size: var(--t-h3); margin-bottom: 8px; }
.use-lead {
  font-size: clamp(1.375rem, 1.1rem + 1vw, 1.875rem);
  font-stretch: 106%;
  line-height: 1.25;
  letter-spacing: -0.01em;
  max-width: 26ch;
}
.use-facts { display: grid; gap: 20px; margin-top: 28px; }
.use-facts div { display: grid; grid-template-columns: 130px 1fr; gap: 16px; padding-top: 20px; border-top: 1px solid var(--linha-forte); }
.use-facts dt { font-weight: 600; font-size: .9375rem; }
.use-facts dd { color: var(--aco); max-width: 38em; }
@media (max-width: 560px) { .use-facts div { grid-template-columns: 1fr; gap: 4px; } }

/* no celular: detalhes de cada aplicação abrem sob demanda */
.use-more {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 8px 0;
  border: 0;
  background: none;
  font-size: .9688rem;
  font-weight: 600;
  color: var(--bordo);
  cursor: pointer;
}
.use-more::after {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 1.6px solid currentColor;
  border-bottom: 1.6px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform .2s ease;
}
.use-more[aria-expanded="true"]::after { transform: translateY(2px) rotate(-135deg); }
.use-more + .use-facts { margin-top: 12px; }
.use + .use { margin-top: 32px; padding-top: 32px; }

.uses.is-tabs {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
  gap: 64px;
  align-items: start;
}
.uses.is-tabs .uses-list { display: flex; flex-direction: column; border-left: 1px solid var(--linha-forte); }
.uses-list [role="tab"] {
  position: relative;
  padding: 14px 0 14px 24px;
  border: 0;
  background: none;
  text-align: left;
  font-size: 1.125rem;
  font-stretch: 104%;
  font-weight: 500;
  color: var(--aco);
  cursor: pointer;
  transition: color .15s ease;
}
.uses-list [role="tab"]:hover { color: var(--grafite); }
.uses-list [role="tab"][aria-selected="true"] { color: var(--grafite); }
.uses-list [role="tab"][aria-selected="true"]::before {
  content: "";
  position: absolute;
  left: -2px;
  top: 10px;
  bottom: 10px;
  width: 3px;
  background: var(--bordo);
}
.uses.is-tabs .use + .use { margin-top: 0; padding-top: 0; border-top: 0; }
.uses.is-tabs .use-title {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}
.uses.is-tabs .use-lead { font-size: clamp(1.75rem, 1.2rem + 1.4vw, 2.375rem); line-height: 1.15; }
.uses.is-tabs .use:focus-visible { outline-offset: 12px; }
@media (prefers-reduced-motion: no-preference) {
  .uses.is-tabs .use:not([hidden]) { animation: appear .35s ease; }
}

/* ---------- Como trabalhamos ---------- */
.steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.step {
  position: relative;
  padding: 0 32px 0 0;
  border-top: 1px solid var(--linha-escura);
}
.step-n {
  display: block;
  margin: 32px 0 20px;
  font-size: 3.75rem;
  font-stretch: 125%;
  font-weight: 300;
  line-height: 1;
  color: var(--rosa);
  font-variant-numeric: tabular-nums;
}
.step h3 { color: var(--nevoa); }
.step-time { margin: 6px 0 14px; font-size: var(--t-sm); font-weight: 600; color: var(--rosa); }
.step p:last-child { color: var(--aco-claro); font-size: 1rem; }
@media (max-width: 980px) {
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 48px; }
}
@media (max-width: 600px) {
  .steps { grid-template-columns: 1fr; row-gap: 0; border-left: 1px solid var(--linha-escura); }
  .step { border-top: 0; padding: 0 0 40px 28px; }
  .step:last-child { padding-bottom: 0; }
  .step-n { margin: 0 0 12px; font-size: 2.75rem; }
}

/* ---------- Princípios e setores ---------- */
.principles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 48px 64px;
}
.principle h3 { margin-bottom: 10px; }
.principle p { color: var(--aco); max-width: 34em; }
@media (max-width: 720px) { .principles { grid-template-columns: 1fr; gap: 32px; } }

.sectors {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 16px 64px;
  margin-top: clamp(56px, 7vw, 96px);
  padding-top: 32px;
  border-top: 1px solid var(--linha);
}
.sectors-label { font-size: 1rem; font-weight: 600; font-stretch: 100%; color: var(--aco); }
.sectors-text {
  font-size: clamp(1.375rem, 1.1rem + 1vw, 1.875rem);
  font-stretch: 106%;
  line-height: 1.3;
  letter-spacing: -0.01em;
  max-width: 30ch;
}
@media (max-width: 880px) { .sectors { grid-template-columns: 1fr; } }

/* ---------- Contato ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 48px 80px;
  align-items: start;
}
.contact-intro h2 { margin-bottom: 20px; }
.contact-intro > p { color: var(--aco); }
.next {
  list-style: none;
  counter-reset: passo;
  display: grid;
  gap: 14px;
  margin: 32px 0;
  padding-top: 28px;
  border-top: 1px solid var(--linha-forte);
}
.next li { counter-increment: passo; display: grid; grid-template-columns: 14px 1fr; gap: 12px; align-items: baseline; }
.next li::before { position: relative; top: 1px; }
.contact-mail { font-size: .9688rem; color: var(--aco); }
.contact-mail a { color: var(--grafite); font-weight: 600; text-underline-offset: 3px; }
@media (max-width: 880px) { .contact-grid { grid-template-columns: 1fr; } }

.form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 20px;
  padding: clamp(24px, 3vw, 40px);
  background: var(--papel);
  border: 1px solid var(--linha);
  border-radius: 8px;
}
.field { display: grid; gap: 8px; align-content: start; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: .9375rem; font-weight: 600; }
.opt { font-weight: 400; color: var(--aco); }
.field input, .field select, .field textarea {
  width: 100%;
  min-height: 48px;
  padding: 11px 14px;
  background: #fff;
  border: 1px solid var(--linha-forte);
  border-radius: var(--r);
  font-size: 1rem;
  line-height: 1.4;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.field textarea { resize: vertical; min-height: 132px; }
.field select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%235E5D63' stroke-width='1.6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
}
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--aco); }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--bordo);
  box-shadow: 0 0 0 3px rgba(122, 31, 61, .16);
}
.field input:user-invalid, .field textarea:user-invalid { border-color: #A3243B; }

.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 4px; }
.form-legal { font-size: var(--t-sm); color: var(--aco); flex: 1 1 220px; }
.form-legal a { text-underline-offset: 3px; }
.form-status:empty { display: none; }
.form-status {
  padding: 14px 16px;
  border-radius: var(--r);
  font-size: .9688rem;
  border-left: 3px solid var(--aco);
  background: var(--nevoa);
}
.form-status.is-ok { border-left-color: #2F6B4F; }
.form-status.is-error { border-left-color: var(--bordo); }
.form-status a { font-weight: 600; text-underline-offset: 3px; }
@media (max-width: 560px) { .form { grid-template-columns: 1fr; } }

/* ---------- Rodapé ---------- */
.site-footer { background: var(--grafite); color: var(--aco-claro); font-size: .9688rem; }
.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 4fr) minmax(0, 3fr);
  gap: 40px 64px;
  padding-block: 72px 48px;
}
.footer-brand img { width: 132px; height: auto; margin-bottom: 16px; }
.footer-nav ul { list-style: none; display: grid; gap: 10px; }
.site-footer a { color: var(--nevoa); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; text-underline-offset: 3px; }
.footer-contact { display: grid; gap: 10px; align-content: start; }
.footer-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 32px;
  padding-block: 24px 32px;
  border-top: 1px solid var(--linha-escura);
  font-size: var(--t-sm);
}
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; padding-top: 56px; } }

/* ---------- Páginas simples (privacidade, 404, obrigado) ---------- */
.page { padding-block: clamp(56px, 8vw, 112px) var(--section); }
.page h1 { font-size: clamp(2.25rem, 1.6rem + 2.6vw, 3.5rem); font-stretch: 114%; line-height: 1.05; margin-bottom: 20px; max-width: 18ch; }
.page .page-lead { font-size: var(--t-lead); color: var(--aco); max-width: 34em; }
.prose { max-width: 42em; margin-top: 48px; }
.prose h2 { font-size: 1.5rem; font-stretch: 108%; margin: 48px 0 12px; }
.prose p, .prose ul { color: var(--aco); }
.prose p + p, .prose p + ul, .prose ul + p { margin-top: 14px; }
.prose ul { padding-left: 1.2em; display: grid; gap: 6px; }
.prose strong { color: var(--grafite); font-weight: 600; }
.page-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }

/* =====================================================================
   Página /fabrica: mesmo visual, conteúdo próprio.
   O que representa uma tela do sistema (o painel da fila, os exemplos) fica em
   fundo "papel", com borda fina; o resto da página é a nossa conversa.
   ===================================================================== */

h4 { margin: 0; }
@media (max-width: 900px) { .hero-title br { display: none; } }

/* ---------- Painel da fila (topo) ---------- */
.queue { width: 100%; height: auto; font-family: var(--f); overflow: visible; }
.queue--medium, .queue--narrow { display: none; }
@media (max-width: 1100px) {
  .queue--wide { display: none; }
  .queue--medium { display: block; }
}
@media (max-width: 680px) {
  .queue--medium { display: none; }
  .queue--narrow { display: block; }
}
.q-question { fill: var(--grafite); font-weight: 600; font-stretch: 106%; }
.q-day { fill: var(--aco); font-size: .85em; }
.q-machine { fill: var(--aco); font-weight: 500; }
.q-machine--focus { fill: var(--grafite); font-weight: 600; }
.q-order { fill: var(--grafite); }
.q-new { fill: var(--bordo); }
.q-hatch-bg { fill: #E3E1DC; }
.q-hatch-line { stroke: #9C9AA0; stroke-width: 2; }
.q-label { fill: var(--nevoa); font-size: .82em; font-weight: 600; font-variant-numeric: tabular-nums; }
.q-due { fill: #8E8C92; }
.q-due--late { fill: var(--bordo); }
.q-late-outline { fill: none; stroke: var(--bordo); stroke-width: 3; }
.q-delay-line { stroke: var(--bordo); stroke-width: 2; }
.q-delay-text { fill: var(--bordo); font-weight: 600; font-size: .82em; }
.q-now { stroke: var(--grafite); stroke-width: 1; stroke-dasharray: 4 4; opacity: .55; }
.q-now-text { fill: var(--aco); font-size: .8em; }
.q-answer-strong { fill: var(--bordo); font-weight: 600; }
.q-answer-text { fill: var(--grafite); font-weight: 400; }

/* o pedido urgente entra e empurra a fila do Torno 2 (um único movimento, no carregamento) */
@media (prefers-reduced-motion: no-preference) {
  .q-new-group {
    transform-box: fill-box;
    transform-origin: left center;
    animation: q-grow .9s cubic-bezier(.5, 0, .2, 1) 1s backwards;
  }
  .q-shift--wide { animation: q-shift-wide .9s cubic-bezier(.5, 0, .2, 1) 1s backwards; }
  .q-shift--medium { animation: q-shift-medium .9s cubic-bezier(.5, 0, .2, 1) 1s backwards; }
  .q-shift--narrow { animation: q-shift-narrow .9s cubic-bezier(.5, 0, .2, 1) 1s backwards; }
  .q-delay, .q-answer, .q-due--late { animation: appear .6s ease 2.1s backwards; }
}
/* deslocamento = 1 dia na escala de cada versão (ver tools/make_queue.py) */
@keyframes q-shift-wide { from { transform: translateX(-200px); } }
@keyframes q-shift-medium { from { transform: translateX(-147.2px); } }
@keyframes q-shift-narrow { from { transform: translateX(-107.5px); } }
@keyframes q-grow { from { transform: scaleX(0); } }

.key--order::before { background: var(--grafite); border-radius: 2px; }
.key--setup::before { background: repeating-linear-gradient(45deg, #9C9AA0 0 2px, #E3E1DC 2px 5px); border-radius: 2px; }
.key--new::before { background: var(--bordo); border-radius: 2px; }
.key--due::before { width: 12px; height: 10px; background: #8E8C92; clip-path: polygon(0 0, 100% 0, 50% 100%); }

/* ---------- A informação espalhada ---------- */
/* frase seguida de uma seção escura: precisa do próprio espaço embaixo */
.statement--spaced { padding-bottom: clamp(64px, 8vw, 112px); }
.situations {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px 32px;
  margin-top: clamp(40px, 5vw, 64px);
}
.situations li {
  padding-top: 20px;
  border-top: 1px solid var(--linha-forte);
  font-size: 1.0625rem;
  line-height: 1.5;
}
@media (max-width: 980px) { .situations { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) {
  .situations { grid-template-columns: 1fr; gap: 0; }
  .situations li { padding-block: 16px; }
}

/* ---------- Um sistema só: os quatro usos ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--linha-escura);
}
.feature { display: flex; flex-direction: column; padding: 40px 48px 48px 0; }
.feature:nth-child(even) { padding: 40px 0 48px 48px; border-left: 1px solid var(--linha-escura); }
.feature:nth-child(n + 3) { border-top: 1px solid var(--linha-escura); }
.feature-name {
  font-size: clamp(1.75rem, 1.3rem + 1.3vw, 2.5rem);
  font-stretch: 116%;
  font-weight: 500;
  line-height: 1.08;
  color: var(--nevoa);
}
.feature-claim { margin: 12px 0 0; font-size: var(--t-lead); font-weight: 500; line-height: 1.35; color: var(--rosa); }
.section--dark .ticks { grid-template-columns: 1fr; color: var(--nevoa); }
.section--dark .ticks li::before { background: var(--rosa); }
.feature-note { margin-top: 18px; font-size: var(--t-sm); color: var(--aco-claro); max-width: 36em; }
/* o exemplo fica sempre embaixo; os exemplos lado a lado têm a mesma altura */
.feature > .example { margin-top: auto; }
.feature > :nth-last-child(2) { margin-bottom: 28px; }
@supports (grid-template-rows: subgrid) {
  /* cada bloco ocupa 6 linhas da grade: nome, frase, lista, nota, exemplo e link.
     As linhas que um bloco não usa ficam vazias; assim os exemplos lado a lado se alinham. */
  .feature { display: grid; grid-row: span 6; grid-template-rows: subgrid; align-items: start; }
  .feature > :nth-last-child(2) { margin-bottom: 0; }
  .feature > .example { grid-row: 5; align-self: stretch; margin-top: 28px; }
  .feature > .feature-link { grid-row: 6; }
}

.example {
  padding: 16px 20px 18px;
  background: var(--papel);
  border-radius: 4px;
  color: var(--grafite);
}
.example-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  font-size: var(--t-sm);
  color: var(--aco);
}
.example-tag { flex: none; font-size: .8125rem; font-weight: 600; color: var(--bordo); }
.example-main {
  margin-top: 8px;
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.4;
  font-variant-numeric: tabular-nums;
}
.example-sub { margin-top: 6px; font-size: .9375rem; line-height: 1.5; color: var(--aco); font-variant-numeric: tabular-nums; }
.features-note { margin-top: 20px; font-size: var(--t-sm); color: var(--aco-claro); }
.feature-text { margin-top: 14px; font-size: 1.0625rem; line-height: 1.55; color: var(--aco-claro); max-width: 36em; }
.feature-link {
  justify-self: start;
  align-self: start;
  margin-top: 20px;
  font-weight: 600;
  color: var(--rosa);
  text-decoration: underline;
  text-underline-offset: .2em;
  text-decoration-thickness: 1px;
}
.feature-link:hover { color: var(--nevoa); }
/* sem subgrid: o link fica logo abaixo do exemplo */
.feature > .example + .feature-link { margin-top: 20px; }

@media (max-width: 880px) {
  .features { grid-template-columns: 1fr; }
  .feature, .feature:nth-child(even) { padding: 32px 0 40px; border-left: 0; }
  .feature + .feature { border-top: 1px solid var(--linha-escura); }
}

/* ---------- O caminho ---------- */
.path {
  margin-top: clamp(56px, 7vw, 88px);
  padding: 36px 40px 40px;
  background: #26252A;
  border-top: 3px solid var(--rosa);
  border-radius: 0 0 6px 6px;
}
.path-head {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: 16px 64px;
  align-items: end;
}
.path-title { font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem); font-stretch: 112%; font-weight: 500; color: var(--nevoa); }
.path-note { font-size: .9688rem; color: var(--aco-claro); max-width: 34em; justify-self: end; }
.path-steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px 40px;
  margin-top: 32px;
}
.path-steps li { padding-top: 20px; border-top: 1px solid var(--linha-escura); }
.path-n {
  display: block;
  font-size: 2.25rem;
  font-stretch: 125%;
  font-weight: 300;
  line-height: 1;
  color: var(--rosa);
  font-variant-numeric: tabular-nums;
}
.path-steps h4 { margin: 14px 0 6px; font-size: 1.25rem; font-stretch: 106%; font-weight: 600; color: var(--nevoa); }
.path-steps p { font-size: 1rem; color: var(--aco-claro); }
@media (max-width: 880px) {
  .path { padding: 28px 22px 30px; }
  .path-head { grid-template-columns: 1fr; }
  .path-note { justify-self: start; }
  .path-steps { grid-template-columns: 1fr; }
}

/* ---------- Passos em fundo claro ---------- */
.steps--light { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.steps--light .step { border-top-color: var(--linha-forte); }
.steps--light .step-n { color: var(--bordo); }
.steps--light .step h3 { color: var(--grafite); }
.steps--light .step p:last-child { color: var(--aco); }
.steps--light .step h3 + p { margin-top: 8px; }
@media (max-width: 760px) {
  .steps--light { grid-template-columns: 1fr; row-gap: 0; border-left: 1px solid var(--linha-forte); }
  .steps--light .step { border-top: 0; padding: 0 0 36px 28px; }
  .steps--light .step:last-child { padding-bottom: 0; }
  .steps--light .step-n { margin: 0 0 10px; font-size: 2.75rem; }
}

/* ---------- Perguntas frequentes ---------- */
.faq-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 32px 64px;
  align-items: start;
}
.faq-grid h2 { max-width: 12ch; }
.faq details { border-top: 1px solid var(--linha); }
.faq details:last-child { border-bottom: 1px solid var(--linha); }
.faq summary {
  position: relative;
  padding: 20px 44px 20px 0;
  list-style: none;
  cursor: pointer;
  font-size: 1.125rem;
  font-weight: 600;
  font-stretch: 104%;
  line-height: 1.35;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  position: absolute;
  right: 6px;
  top: 50%;
  width: 14px;
  height: 14px;
  background:
    linear-gradient(var(--bordo), var(--bordo)) center / 100% 2px no-repeat,
    linear-gradient(var(--bordo), var(--bordo)) center / 2px 100% no-repeat;
  transform: translateY(-50%);
  transition: transform .2s ease;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq summary:hover { color: var(--bordo); }
.faq details p { padding: 0 44px 22px 0; max-width: 40em; color: var(--aco); }
@media (max-width: 880px) { .faq-grid { grid-template-columns: 1fr; } }

/* ---------- Princípios em três colunas (página inicial) ---------- */
.principles--three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px 48px;
  margin-top: clamp(56px, 7vw, 88px);
  padding-top: clamp(32px, 4vw, 48px);
  border-top: 1px solid var(--linha);
}
.principles--three h3 { font-size: 1.25rem; }
@media (max-width: 880px) { .principles--three { grid-template-columns: 1fr; } }

/* ---------- Contato ---------- */
.contact-intro > p + .contact-mail { margin-top: 20px; }
.field input::placeholder { color: #8E8C92; }
