/* Página inicial do Traçado — direção "folha técnica": papel de desenho, traço grafite, a cor de cada
   camada do CAD só onde ela representa uma camada, e o azul do Traçado nas ações. */
:root {
  --papel: #f6f8f7; --papel-2: #edf1ef; --grade: #dce4e0; --grade-forte: #c9d4ce;
  --grafite: #1f2529; --grafite-2: #4a545b; --grafite-3: #646e75;
  --azul: #1d4ed8; --azul-2: #173ead; --foco: #1d4ed8;
  --medida: min(1200px, 100% - 48px);
  color-scheme: light;
}
@view-transition { navigation: auto; }
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 17px/1.6 Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--grafite); background: var(--papel); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--azul); text-decoration: none; }
a, button { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
h1, h2, h3 { line-height: 1.1; margin: 0; text-wrap: balance; letter-spacing: -.022em; }
p { margin: 0 0 12px; text-wrap: pretty; }
.muted { color: var(--grafite-3); }
.nota { font-size: 14px; color: var(--grafite-3); }
.centro { text-align: center; }
:focus-visible { outline: 3px solid var(--foco); outline-offset: 3px; border-radius: 4px; }
.pular { position: absolute; left: 12px; top: -60px; z-index: 99; background: var(--grafite); color: #fff; padding: 10px 16px; border-radius: 8px; }
.pular:focus { top: 12px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px; border-radius: 8px; font: 600 16px/1 Inter, system-ui, sans-serif; border: 1.5px solid transparent; white-space: nowrap; transition: background-color .15s, border-color .15s, color .15s; }
.btn.grande { min-height: 52px; padding: 0 26px; font-size: 17px; }
.btn.primario { background: var(--azul); color: #fff; }
.btn.primario:hover { background: var(--azul-2); }
.btn.linha { border-color: var(--grafite); color: var(--grafite); background: transparent; }
.btn.linha:hover { background: var(--grafite); color: var(--papel); }
.btn.claro { background: var(--papel); color: var(--grafite); }
.btn.claro:hover { background: #fff; }

/* Topo */
.topo { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 24px; padding: 12px max(24px, (100% - 1200px) / 2); background: color-mix(in srgb, var(--papel) 90%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--grade-forte); }
.marca { display: inline-flex; align-items: center; gap: 10px; color: var(--grafite); font-size: 19px; }
.logo { view-transition-name: marca; width: 30px; height: 30px; border-radius: 7px; background: var(--azul); position: relative; flex: none; }
.logo::before, .logo::after { content: ''; position: absolute; background: #fff; border-radius: 2px; }
.logo::before { left: 7px; right: 7px; top: 8px; height: 3.5px; }   /* régua T: a cabeça */
.logo::after { left: 13.25px; width: 3.5px; top: 8px; bottom: 6px; } /* e a lâmina */
.topo nav { display: flex; gap: 4px; }
.topo nav a { color: var(--grafite-2); padding: 8px 12px; border-radius: 6px; font-size: 15px; }
.topo nav a:hover { color: var(--grafite); background: var(--papel-2); }
.topo-acoes { margin-left: auto; display: flex; gap: 10px; }
.topo .btn { min-height: 40px; padding: 0 16px; font-size: 15px; }

/* Abertura: o texto e a folha com a planta desenhada pelo motor */
.abertura { width: var(--medida); margin: 0 auto; padding: 56px 0 64px; display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 56px; align-items: center; }
.abertura h1 { font-size: clamp(40px, 5vw, 64px); font-weight: 800; letter-spacing: -.035em; margin-bottom: 20px; }
.abertura .sub { font-size: 19px; color: var(--grafite-2); max-width: 34em; }
.cta { display: flex; gap: 12px; flex-wrap: wrap; margin: 28px 0 14px; }
.abertura .nota { max-width: 36em; }

.folha { margin: 0; background: #fff; border: 1.5px solid var(--grafite); border-radius: 4px; box-shadow: 8px 8px 0 var(--grade); display: grid; grid-template-rows: auto auto; }
.folha-desenho { position: relative; aspect-ratio: 16 / 10; padding: 18px; border-bottom: 1.5px solid var(--grafite); overflow: hidden;
  background-color: #fff; background-image: linear-gradient(var(--papel-2) 1px, transparent 1px), linear-gradient(90deg, var(--papel-2) 1px, transparent 1px), linear-gradient(var(--grade) 1px, transparent 1px), linear-gradient(90deg, var(--grade) 1px, transparent 1px);
  background-size: 10px 10px, 10px 10px, 50px 50px, 50px 50px; }
.desenhando { position: absolute; inset: 0; display: grid; place-items: center; margin: 0; color: var(--grafite-3); font-size: 15px; }
.folha.viva .desenhando { display: none; }
.folha .reserva { display: none; }
.folha.falhou .reserva { display: block; width: 100%; height: 100%; object-fit: cover; }
.folha.falhou .desenhando, .folha.falhou .folha-base { display: none; }
.folha-base { display: grid; grid-template-columns: auto 1fr; }
.legenda { display: flex; flex-direction: column; gap: 2px; padding: 10px; border-right: 1.5px solid var(--grafite); min-width: 150px; }
.legenda:empty { display: none; }
.camada { display: flex; align-items: center; gap: 10px; padding: 6px 10px; border: 0; border-radius: 4px; background: none; font: 500 14px/1.2 Inter, system-ui, sans-serif; color: var(--grafite-3); cursor: pointer; text-align: left; transition: color .15s, background-color .15s; }
.camada .traco { width: 22px; height: 0; border-top: 3px solid var(--cor); opacity: .35; transition: opacity .15s; }
.camada[aria-pressed="true"] { color: var(--grafite); }
.camada[aria-pressed="true"] .traco { opacity: 1; }
.camada:hover:not(:disabled) { background: var(--papel-2); }
.camada:disabled { cursor: default; color: var(--grafite); }
.camada:disabled .traco { opacity: 1; }
.carimbo { margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.carimbo > div { padding: 8px 12px; border-left: 1px solid var(--grade-forte); border-bottom: 1px solid var(--grade-forte); min-width: 0; }
.carimbo > div:nth-child(3n + 2) { border-left: 0; }
.carimbo dt { font-size: 12px; color: var(--grafite-3); }
.carimbo dd { margin: 2px 0 0; font-weight: 700; font-size: 17px; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.carimbo .c-proj { grid-column: 1 / -1; border-left: 0; }
.carimbo .c-proj dd { font-size: 15px; font-weight: 600; }
.carimbo .c-valor { grid-column: span 2; background: var(--papel); }
.carimbo .c-valor dd { font-size: 24px; color: var(--azul); letter-spacing: -.02em; }
.folha figcaption { grid-column: 1 / -1; padding: 10px 14px; font-size: 13px; color: var(--grafite-3); border-top: 1.5px solid var(--grafite); }

/* O desenho (mesmas classes do editor do app, com as cores da folha) */
.folha svg.ed { width: 100%; height: 100%; display: block; }
.folha svg.ed * { vector-effect: non-scaling-stroke; }
.folha svg.ed text { vector-effect: none; stroke: none; font-family: Inter, system-ui, sans-serif; }
.folha svg.ed .layer { transition: opacity .6s ease; }
.folha svg.ed .layer.apagada { opacity: 0; }
.folha:not(.pronta) svg.ed .layer:not(.apagada) { animation: entrar .8s ease both; }
@keyframes entrar { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.folha svg.ed .layer { transform-box: fill-box; }
.folha .room-fill { stroke: none; fill-opacity: .55; }
.folha .room-name { fill: var(--grafite); font-weight: 600; }
.folha .room-area { fill: var(--grafite-3); }
.folha .wall { fill: #4a545b; stroke: var(--grafite); stroke-width: 1; }
.folha .viga { fill: none; stroke: var(--grafite-2); stroke-width: 1; stroke-dasharray: 6 3; }
.folha .pilar { fill: #9aa5ab; stroke: var(--grafite); stroke-width: 1.2; }
.folha .opening { fill: #fff; stroke: none; }
.folha .swing { fill: none; stroke: var(--grafite-3); stroke-width: 1; stroke-dasharray: 4 3; }
.folha .leaf { fill: none; stroke: var(--grafite); stroke-width: 1.4; }
.folha .lbl { fill: var(--grafite); }
.folha .pil-lbl { fill: var(--grafite-3); }
.folha .el-lbl { fill: #b91c1c; font-weight: 500; }
.folha .el-sym { fill: #fff; stroke: #dc2626; stroke-width: 1.6; }
.folha .el-sym.filled, .folha .el-fill { fill: #dc2626; }
.folha .mec-sym { fill: #ecfeff; stroke: #0e7490; stroke-width: 1.6; }
.folha .mec-txt { fill: #0e7490; font-weight: 700; }
.folha .guard { fill: none; stroke: #ca8a04; stroke-width: 1.4; stroke-dasharray: 3 2; }
.folha .movel { fill: #f5f3ff; stroke-width: 1.4; }
.folha .thin { stroke-width: 1; fill: none; }
.folha .thick { stroke-width: 3; }
.folha .dashed { stroke-dasharray: 4 3; }
.folha .pipe { stroke-linecap: round; vector-effect: none; }
.folha .cob-fill { fill: rgba(194, 65, 12, .04); stroke-width: 1.2; stroke-dasharray: 8 4; }
.folha .terca { stroke-width: .8; opacity: .55; fill: none; }
.folha .cota-ext { stroke: var(--grafite-2); stroke-width: .8; }
.folha .cota-line { stroke: var(--grafite-2); stroke-width: 1; color: var(--grafite-2); }
.folha .cota-txt, .folha .nota { fill: var(--grafite); font-weight: 600; }
.folha .hatch-line { stroke: var(--grafite-2); stroke-width: .7; }
.folha .hit { fill: transparent; stroke: transparent; }

/* Antes e depois */
.antes-depois { border-block: 1.5px solid var(--grafite); background: #fff; padding: 56px max(24px, (100% - 1000px) / 2); }
.antes-depois h2 { font-size: clamp(28px, 3.2vw, 38px); margin-bottom: 28px; }
.colunas { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.colunas h3 { font-size: 18px; padding-bottom: 10px; border-bottom: 1.5px solid var(--grafite); margin-bottom: 14px; }
.colunas ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.colunas li { color: var(--grafite-2); padding-left: 28px; position: relative; }
.riscado li::before { content: ''; position: absolute; left: 2px; top: .75em; width: 16px; border-top: 2px solid #dc2626; transform: rotate(-12deg); }
.feito li::before { content: ''; position: absolute; left: 3px; top: .35em; width: 7px; height: 12px; border: solid var(--azul); border-width: 0 2.5px 2.5px 0; transform: rotate(40deg); }

/* Seções */
.secao { width: var(--medida); margin: 0 auto; padding: 80px 0 16px; }
.secao-cab { max-width: 44em; margin-bottom: 32px; }
.secao-cab h2 { font-size: clamp(30px, 3.6vw, 44px); margin-bottom: 12px; }
.secao-cab p { color: var(--grafite-2); font-size: 18px; }

/* Legenda de camadas (como no gerenciador de camadas do CAD) */
.tabela-rolar { overflow-x: auto; border: 1.5px solid var(--grafite); border-radius: 4px; background: #fff; }
.camadas { width: 100%; border-collapse: collapse; font-size: 15px; }
.camadas th, .camadas td { text-align: left; vertical-align: top; padding: 14px 16px; border-bottom: 1px solid var(--grade-forte); }
.camadas thead th { font-size: 13px; font-weight: 600; color: var(--grafite-3); background: var(--papel); border-bottom: 1.5px solid var(--grafite); }
.camadas tbody tr:last-child > * { border-bottom: 0; }
.camadas tbody th { font-weight: 700; font-size: 16px; min-width: 230px; white-space: normal; }
.camadas td:nth-child(2) { color: var(--grafite-2); min-width: 150px; font-size: 14px; }
.camadas td:last-child { color: var(--grafite-2); max-width: 40em; }
.tipo-linha { display: block; width: 48px; height: 8px; margin-bottom: 8px; stroke: var(--cor); stroke-width: 2.5; }
.em-volta { font-size: 22px; margin: 48px 0 18px; }
.em-volta-lista { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; margin: 0; }
.em-volta-lista > div { padding: 16px 0; border-top: 1px solid var(--grade-forte); }
.em-volta-lista dt { font-weight: 700; margin-bottom: 4px; }
.em-volta-lista dd { margin: 0; color: var(--grafite-2); font-size: 16px; }

/* Telas */
.mostruario { width: var(--medida); margin: 0 auto; padding: 72px 0 24px; display: grid; gap: 80px; }
.mostra { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 56px; align-items: center; }
.mostra.invertido .mostra-txt { order: 2; }
.mostra figure { margin: 0; border: 1.5px solid var(--grafite); border-radius: 4px; background: #fff; box-shadow: 8px 8px 0 var(--grade); overflow: hidden; }
.mostra figcaption { padding: 8px 12px; font-size: 13px; color: var(--grafite-3); border-top: 1.5px solid var(--grafite); }
.mostra h3 { font-size: clamp(24px, 2.6vw, 32px); margin-bottom: 14px; }
.mostra p { color: var(--grafite-2); }
.lista { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 10px; }
.lista li { padding-left: 26px; position: relative; color: var(--grafite-2); }
.lista li::before { content: ''; position: absolute; left: 3px; top: .35em; width: 7px; height: 12px; border: solid var(--azul); border-width: 0 2.5px 2.5px 0; transform: rotate(40deg); }

/* Proposta */
.proposta-bloco { margin-top: 72px; background: var(--grafite); color: #dfe5e2; padding: 80px max(24px, (100% - 1200px) / 2); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 56px; align-items: center; }
.proposta-bloco h2 { font-size: clamp(30px, 3.6vw, 44px); color: #fff; margin-bottom: 16px; }
.proposta-bloco p { color: #c3ccc8; max-width: 34em; margin-bottom: 24px; }
.proposta-imgs { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.proposta-imgs img { border-radius: 4px; border: 1.5px solid #3a444a; }

/* Como funciona: é uma sequência, então numerada */
.passos { list-style: none; counter-reset: passo; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 1.5px solid var(--grafite); }
.passos li { counter-increment: passo; padding: 20px 24px 8px 0; position: relative; }
.passos li::before { content: counter(passo); position: absolute; top: -15px; left: 0; width: 28px; height: 28px; border-radius: 50%; background: var(--papel); border: 1.5px solid var(--grafite); display: grid; place-items: center; font-weight: 700; font-size: 14px; }
.passos b { display: block; font-size: 18px; margin: 10px 0 6px; }
.passos p { color: var(--grafite-2); font-size: 16px; margin: 0; }

/* Planos */
.planos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1.5px solid var(--grafite); border-radius: 4px; background: #fff; }
.plano { padding: 28px; display: flex; flex-direction: column; gap: 4px; border-left: 1px solid var(--grade-forte); }
.plano:first-child { border-left: 0; }
.plano.destaque { background: var(--papel); box-shadow: inset 0 4px 0 var(--azul); }
.plano h3 { font-size: 19px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.selo { font-size: 12px; font-weight: 600; color: var(--azul); border: 1.5px solid var(--azul); border-radius: 999px; padding: 2px 10px; }
.plano .preco { font-size: 46px; font-weight: 800; letter-spacing: -.035em; line-height: 1.1; margin: 8px 0; font-variant-numeric: tabular-nums; }
.plano .preco span { font-size: 28px; }
.plano .preco small { font-size: 15px; font-weight: 500; color: var(--grafite-3); margin: 0 4px; letter-spacing: 0; }
.plano .muted { font-size: 15px; }
.plano ul { list-style: none; padding: 0; margin: 12px 0 24px; display: grid; gap: 8px; flex: 1; color: var(--grafite-2); font-size: 15px; }
.plano li { padding-left: 22px; position: relative; }
.plano li::before { content: ''; position: absolute; left: 2px; top: .4em; width: 6px; height: 11px; border: solid var(--azul); border-width: 0 2.5px 2.5px 0; transform: rotate(40deg); }
.plano .btn { width: 100%; }
.planos-secao .nota { margin-top: 16px; }

/* Dúvidas */
.faq { max-width: 50em; border-top: 1.5px solid var(--grafite); }
.faq details { border-bottom: 1px solid var(--grade-forte); }
.faq summary { cursor: pointer; font-weight: 600; font-size: 18px; padding: 18px 0; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ''; flex: none; width: 12px; height: 12px; border: solid var(--grafite); border-width: 0 2px 2px 0; transform: rotate(45deg) translate(-3px, -3px); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(-135deg) translate(-3px, -3px); }
.faq p { color: var(--grafite-2); margin: 0 0 18px; max-width: 44em; }

/* Chamada final e rodapé (o carimbo da prancha) */
.cta-final { width: var(--medida); margin: 88px auto 72px; padding: 48px; border: 1.5px solid var(--grafite); border-radius: 4px; background: #fff; box-shadow: 8px 8px 0 var(--grade); }
.cta-final h2 { font-size: clamp(28px, 3.4vw, 40px); margin-bottom: 12px; }
.cta-final p { color: var(--grafite-2); max-width: 38em; }
.rodape { width: var(--medida); margin: 0 auto 32px; display: grid; grid-template-columns: 1.2fr 1fr; border: 1.5px solid var(--grafite); border-radius: 4px; background: #fff; font-size: 14px; }
.rodape > * { padding: 16px 20px; margin: 0; }
.rp-marca { border-right: 1px solid var(--grade-forte); }
.rp-marca p { color: var(--grafite-3); margin: 8px 0 0; }
.rp-links { display: flex; flex-wrap: wrap; gap: 6px 20px; align-content: center; }
.rp-links a { color: var(--grafite-2); }
.rp-links a:hover { color: var(--azul); }
.rp-aviso { grid-column: 1 / -1; border-top: 1px solid var(--grade-forte); color: var(--grafite-3); }

@media (max-width: 1000px) {
  .abertura { grid-template-columns: 1fr; padding: 32px 0 48px; gap: 36px; }
  .mostra, .proposta-bloco { grid-template-columns: 1fr; gap: 28px; }
  .mostra.invertido .mostra-txt { order: 0; }
  .passos { grid-template-columns: 1fr 1fr; row-gap: 28px; }
  .planos { grid-template-columns: 1fr; }
  .plano { border-left: 0; border-top: 1px solid var(--grade-forte); }
  .plano:first-child { border-top: 0; }
  .topo nav { display: none; }
}
@media (max-width: 640px) {
  :root { --medida: calc(100% - 32px); }
  body { font-size: 16px; }
  .topo { padding: 10px 16px; gap: 10px; }
  .topo .btn.linha { display: none; }
  .colunas, .em-volta-lista { grid-template-columns: 1fr; gap: 28px; }
  .antes-depois { padding: 40px 16px; }
  .folha-base { grid-template-columns: 1fr; }
  .legenda { flex-direction: row; flex-wrap: wrap; border-right: 0; border-bottom: 1.5px solid var(--grafite); }
  .carimbo { grid-template-columns: 1fr 1fr; }
  .carimbo > div:nth-child(3n + 2) { border-left: 1px solid var(--grade-forte); }
  .carimbo > div:nth-child(2n) { border-left: 0; }
  .carimbo .c-valor { grid-column: 1 / -1; }
  .passos { grid-template-columns: 1fr; }
  .cta-final { padding: 28px 20px; }
  .rodape { grid-template-columns: 1fr; }
  .rp-marca { border-right: 0; border-bottom: 1px solid var(--grade-forte); }
  .secao { padding-top: 56px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  @view-transition { navigation: none; }
}
