/* Hallmark · shape: custom (brand) · genre: editorial · theme: brand
 * paper: #F4F2EE cal · accent: #E3721B laranja obra · display: Archivo 900 · body: Archivo 400/600 · hero: split, gable-framed photograph under the logo's roof line · nav: edge-aligned lockup, three links and one action · footer: grafite slab, lockup over legal links and consumer info · signature: the hero photo cut into a house, crowned by the logo's orange roof line
 * axes: light/grotesk-heavy/warm · posture: brand-led, restrained · contrast: pass · fold: pass · v2.0.0 */
/* Hallmark · pre-emit critique: P4 H4 E4 S4 R4 V4 · weakest: S, services list fits any builder; anchored it with the sample plan and quote, the things TDR will hand every client */
/* Hallmark · dismissed F4 · the selected tab of the plan switcher is a state, not a second call to action */
/* Hallmark · dismissed 58 · the contact screen holds the form labels, counted with the fields they name */
/* Hallmark · dismissed 25 · footer lines are one-sentence captions, 32 and 40ch keep them beside the lockup */
@import url("./tokens.css");
@import url("./base.css");

@font-face { font-family: "Archivo"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/archivo-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Archivo"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/archivo-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Archivo"; font-style: normal; font-weight: 900; font-display: swap; src: url("../fonts/archivo-latin-900-normal.woff2") format("woff2"); }

body { font-size: 1.0625rem; }

/* ---------- Skip link ---------- */
.skip { position: absolute; left: var(--space-md); top: calc(-1 * var(--space-3xl)); z-index: var(--z-toast); padding: var(--space-xs) var(--space-md); background: var(--color-ink); color: var(--color-paper); }
.skip:focus-visible { top: var(--space-md); }

/* ---------- Logo ---------- */
.lockup { display: inline-flex; align-items: center; gap: var(--space-sm); color: var(--color-ink); text-decoration: none; min-height: 48px; }
.lockup:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 4px; }
.mark { width: 56px; height: auto; flex: none; }
.mark .roof { fill: none; stroke: var(--color-accent); stroke-width: 13; stroke-linecap: square; stroke-linejoin: miter; }
.mark text { font-family: var(--font-display); font-weight: 900; font-size: 52px; letter-spacing: 1px; fill: currentColor; }
.lockup__words { display: flex; flex-direction: column; gap: var(--space-3xs); line-height: 1; }
.lockup__name { font-family: var(--font-display); font-weight: 900; font-size: 1.375rem; }
.lockup__tag { font-weight: 600; font-size: var(--text-xs); color: var(--color-muted); }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-xs); min-height: 52px; padding: 0 var(--space-lg); border: 2px solid var(--color-accent); border-radius: var(--radius-input); background: var(--color-accent); color: var(--color-accent-ink); font: 600 var(--text-md)/1 var(--font-body); white-space: nowrap; text-decoration: none; cursor: pointer; transition: background-color var(--dur-short) var(--ease-out), border-color var(--dur-short) var(--ease-out), transform var(--dur-micro) var(--ease-out); }
.btn:hover { background: var(--color-accent-2); border-color: var(--color-accent-2); }
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 3px; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; transform: none; }
.btn[aria-busy="true"] { cursor: progress; }
.btn--quiet { background: transparent; color: var(--color-ink); border-color: var(--color-ink); }
.btn--quiet:hover { background: var(--color-ink); border-color: var(--color-ink); color: var(--color-paper); }
@media (prefers-reduced-motion: reduce) { .btn { transition: background-color var(--dur-short) linear; } }

.link { white-space: nowrap; font-weight: 600; text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--color-accent); text-underline-offset: 0.22em; transition: text-decoration-color var(--dur-short) var(--ease-out); }
.link:hover { text-decoration-color: currentColor; }
.link:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; }

/* ---------- Nav ---------- */
.nav { position: sticky; top: 0; z-index: var(--z-sticky-nav); background: color-mix(in oklab, var(--color-paper) 94%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--color-rule); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-lg); min-height: 76px; }
.nav__links { display: flex; align-items: center; gap: var(--space-lg); margin: 0; padding: 0; list-style: none; }
.nav__links a:not(.btn) { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; text-decoration: none; color: var(--color-ink); border-bottom: 2px solid transparent; transition: border-color var(--dur-short) var(--ease-out); }
.nav__links a:not(.btn):hover, .nav__links a[aria-current="page"] { border-bottom-color: var(--color-accent); }
.nav__links a:not(.btn):focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; }
.nav__links .btn { min-height: 46px; }
.nav__toggle { display: none; min-height: 46px; padding: 0 var(--space-md); border: 2px solid var(--color-ink); border-radius: var(--radius-input); background: transparent; color: var(--color-ink); font-weight: 600; cursor: pointer; transition: background-color var(--dur-short) var(--ease-out); }
.nav__toggle:hover { background: var(--color-paper-2); }
.nav__toggle:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; }
.nav__toggle:active { transform: translateY(1px); }

@media (max-width: 48rem) {
  .js .nav__toggle { display: inline-flex; align-items: center; }
  .js .nav__links { display: none; }
  .js .nav.is-open .nav__links { display: flex; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0; padding: var(--space-sm) var(--gutter) var(--space-lg); background: var(--color-paper); border-bottom: 1px solid var(--color-rule); }
  .js .nav.is-open .nav__links li { border-top: 1px solid var(--color-rule); }
  .js .nav.is-open .nav__links .btn { margin-top: var(--space-md); width: 100%; }
  .nav__links { gap: var(--space-md); flex-wrap: wrap; }
  .lockup__tag { display: none; }
}

/* ---------- Hero ---------- */
.hero { display: grid; align-items: center; min-height: min(calc(100svh - 77px), 900px); padding-block: var(--space-xl); }
.hero__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); align-items: center; }
.hero__text { grid-column: 1 / span 6; display: flex; flex-direction: column; gap: var(--space-lg); }
.hero h1 { font-size: clamp(2.5rem, 4.2vw + 0.5rem, 5rem); line-height: 0.98; max-width: 12ch; }
.hero .lead { color: var(--color-muted); max-width: 34ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--space-sm); margin-top: var(--space-xs); }
.hero__fig { grid-column: 7 / -1; margin: 0; }

.casa { position: relative; width: calc(100% - var(--space-2xl)); max-width: 520px; margin-left: var(--space-2xl); }
.casa__roof { position: absolute; inset: 0 0 auto 0; width: 100%; height: auto; overflow: visible; z-index: 2; }
.casa__roof path { fill: none; stroke: var(--color-accent); stroke-width: 7; stroke-linecap: square; stroke-linejoin: miter; stroke-dasharray: 200; stroke-dashoffset: 0; animation: roof-draw 900ms var(--ease-out) 150ms both; }
@keyframes roof-draw { from { stroke-dashoffset: 200; } to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) { .casa__roof path { animation: none; stroke-dashoffset: 0; } }
.casa__photo { width: 86%; margin: 9% auto 0; aspect-ratio: 5 / 6; clip-path: polygon(50% 0, 100% 30%, 100% 100%, 0 100%, 0 30%); }
.casa__photo > img { object-position: 50% 45%; }
.casa__note { position: absolute; inset: auto 0 0 0; z-index: 0; display: grid; place-items: center; padding: var(--space-lg); color: var(--color-muted); font-size: var(--text-sm); text-align: center; }

@media (max-width: 60rem) {
  .hero__text, .hero__fig { grid-column: 1 / -1; }
  .hero__fig { margin-top: var(--space-2xl); }
  .casa { width: 100%; max-width: 420px; margin-inline: auto; }
  .hero { min-height: 0; padding-block: var(--space-2xl) var(--space-3xl); }
}

/* ---------- Sections ---------- */
.section { padding-block: var(--section-gap-s); }
.section__head { display: flex; flex-direction: column; gap: var(--space-md); }
.section__head p { color: var(--color-muted); font-size: var(--text-lead); max-width: 46ch; }

/* Services */
.services__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-2xl); }
.services__aside { grid-column: 1 / span 4; display: flex; flex-direction: column; gap: var(--space-xl); align-self: start; position: sticky; top: calc(76px + var(--space-xl)); }
.services__photo { margin: 0; aspect-ratio: 4 / 3; border-radius: var(--radius-card); }
.services__list { grid-column: 6 / -1; margin: 0; padding: 0; list-style: none; counter-reset: srv; border-top: 2px solid var(--color-ink); }
.services__list li { counter-increment: srv; display: grid; grid-template-columns: 3.5rem minmax(0, 1fr); gap: var(--space-xs) var(--space-md); padding-block: var(--space-lg); border-bottom: 1px solid var(--color-rule); }
.services__list li::before { content: counter(srv, decimal-leading-zero); grid-row: span 2; font-family: var(--font-display); font-weight: 900; font-size: var(--text-xl); line-height: 1.1; color: var(--color-accent); font-variant-numeric: tabular-nums; }
.services__list h3 { font-size: var(--text-2xl); max-width: none; }
.services__list p { color: var(--color-muted); }
@media (max-width: 60rem) {
  .services__aside, .services__list { grid-column: 1 / -1; }
  .services__aside { position: static; }
}

/* Plan (dark band) */
.plan { background: var(--color-night); color: var(--color-night-ink); --color-focus: var(--color-accent); }
.plan .section__head p { color: var(--color-night-muted); }
.plan__top { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: var(--space-xl); margin-bottom: var(--space-2xl); }
.tabs { display: inline-flex; border: 2px solid var(--color-night-rule); border-radius: var(--radius-input); padding: var(--space-2xs); gap: var(--space-2xs); }
.tabs button { min-height: 44px; padding: 0 var(--space-lg); border: 0; border-radius: var(--radius-input); background: transparent; color: var(--color-night-ink); font-weight: 600; cursor: pointer; transition: background-color var(--dur-short) var(--ease-out), color var(--dur-short) var(--ease-out); }
.tabs button:hover { background: var(--color-night-2); }
.tabs button[aria-selected="true"] { background: var(--color-night-ink); color: var(--color-ink); }
.tabs button:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }
html:not(.js) .tabs { display: none; }
.panel + .panel { margin-top: var(--space-2xl); }
.js .panel + .panel { margin-top: 0; }
.panel__title { font-size: var(--text-title); margin-bottom: var(--space-lg); }

.gantt { margin: 0; padding: 0; list-style: none; }
.gantt__weeks, .gantt li { display: grid; grid-template-columns: minmax(12rem, 22rem) repeat(4, minmax(0, 1fr)); align-items: center; column-gap: 0; }
.gantt__weeks { color: var(--color-night-muted); font-size: var(--text-sm); padding-bottom: var(--space-sm); border-bottom: 1px solid var(--color-night-rule); }
.gantt__weeks span { padding-left: var(--space-sm); border-left: 1px solid var(--color-night-rule); }
.gantt li { min-height: 64px; border-bottom: 1px solid var(--color-night-rule); background-image: linear-gradient(to right, transparent calc(100% - 1px), var(--color-night-rule) 0); }
.gantt__task { font-weight: 600; padding-right: var(--space-md); }
.gantt__bar { grid-row: 1; height: 22px; margin-inline: var(--space-2xs); background: var(--color-accent); border-radius: 1px; }
.gantt__bar .visually-hidden { color: var(--color-ink); }
.w1-1 { grid-column: 2 / 3; } .w1-2 { grid-column: 2 / 4; } .w2-2 { grid-column: 3 / 4; } .w2-3 { grid-column: 3 / 5; } .w3-4 { grid-column: 4 / 6; } .w4-4 { grid-column: 5 / 6; }
.gantt__task { grid-column: 1; grid-row: 1; }
@media (max-width: 44rem) {
  .gantt__weeks, .gantt li { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .gantt__weeks > :first-child { display: none; }
  .gantt li { padding-block: var(--space-sm); row-gap: var(--space-xs); }
  .gantt__task { grid-column: 1 / -1; grid-row: 1; padding: 0; }
  .gantt__bar { grid-row: 2; }
  .w1-1 { grid-column: 1 / 2; } .w1-2 { grid-column: 1 / 3; } .w2-2 { grid-column: 2 / 3; } .w2-3 { grid-column: 2 / 4; } .w3-4 { grid-column: 3 / 5; } .w4-4 { grid-column: 4 / 5; }
}

.quote { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.quote th, .quote td { padding: var(--space-md) var(--space-sm); text-align: left; border-bottom: 1px solid var(--color-night-rule); vertical-align: top; }
.quote thead th { color: var(--color-night-muted); font-weight: 400; font-size: var(--text-sm); border-bottom-color: var(--color-night-muted); }
.quote td:first-child { font-weight: 600; }
.quote th:nth-child(n+2), .quote td:nth-child(n+2) { text-align: right; width: 7rem; }
.quote-wrap { overflow-x: auto; }
.plan__foot { margin-top: var(--space-lg); color: var(--color-night-muted); font-size: var(--text-sm); max-width: 60ch; }

/* Contact */
.contact__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-2xl); }
.contact__info { grid-column: 1 / span 5; display: flex; flex-direction: column; gap: var(--space-xl); }
.contact__list { display: grid; gap: var(--space-md); margin: 0; }
.contact__list div { display: grid; gap: var(--space-2xs); padding-top: var(--space-md); border-top: 1px solid var(--color-rule); }
.contact__list dt { font-size: var(--text-sm); color: var(--color-muted); }
.contact__list dd { margin: 0; font-weight: 600; font-size: var(--text-lg); }
.contact__form { grid-column: 7 / -1; }
@media (max-width: 60rem) { .contact__info, .contact__form { grid-column: 1 / -1; } }

.fill { padding: 0 0.25em; border: 1px dashed color-mix(in oklch, var(--color-muted) 70%, transparent); border-radius: 3px; color: var(--color-muted); font-weight: 400; -webkit-box-decoration-break: clone; box-decoration-break: clone; }

/* Form */
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-lg) var(--space-md); padding: var(--space-xl); background: var(--color-surface); border: 1px solid var(--color-rule); border-radius: var(--radius-card); }
.field { display: grid; gap: var(--space-xs); align-content: start; }
.field--full { grid-column: 1 / -1; }
.field label, .check label { font-weight: 600; font-size: var(--text-sm); }
.field .opt { font-weight: 400; color: var(--color-muted); }
.field input, .field select, .field textarea { width: 100%; min-height: 50px; padding: var(--space-sm) var(--space-md); border: 1px solid var(--color-muted); border-radius: var(--radius-input); background: var(--color-surface); color: var(--color-ink); outline: 2px solid transparent; outline-offset: -3px; transition: border-color var(--dur-short) var(--ease-out); }
.field textarea { min-height: 150px; resize: vertical; line-height: 1.5; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--color-ink); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline-color: var(--color-focus); border-color: var(--color-ink); }
.field [aria-invalid="true"] { border-color: var(--color-error); }
.field input:disabled, .field select:disabled, .field textarea:disabled { opacity: 0.6; cursor: not-allowed; }
.field__err { min-height: 0; font-size: var(--text-sm); color: var(--color-error); }
.field__err:empty { display: none; }
.check { grid-column: 1 / -1; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: var(--space-sm); align-items: start; }
.check input { width: 22px; height: 22px; margin: var(--space-3xs) 0 0; accent-color: var(--color-ink); cursor: pointer; }
.check input:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; }
.check .field__err { grid-column: 2; }
.check label { font-weight: 400; font-size: var(--text-sm); color: var(--color-muted); }
.form__foot { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-md); }
.form__status { font-size: var(--text-sm); color: var(--color-muted); }
.form__status.is-ok { color: var(--color-success); font-weight: 600; }
.form__status.is-err { color: var(--color-error); font-weight: 600; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 40rem) { .form { grid-template-columns: minmax(0, 1fr); padding: var(--space-lg); } }

/* ---------- Footer ---------- */
.footer { background: var(--color-night); color: var(--color-night-ink); padding-block: var(--space-2xl) var(--space-xl); --color-focus: var(--color-accent); }
.footer .lockup { color: var(--color-night-ink); }
.footer .lockup__tag { color: var(--color-night-muted); display: inline; }
.footer__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-xl); }
.footer__brand { grid-column: 1 / span 4; display: flex; flex-direction: column; gap: var(--space-md); }
.footer__brand p { color: var(--color-night-muted); font-size: var(--text-sm); max-width: 32ch; }
.footer__col { grid-column: span 4; display: flex; flex-direction: column; gap: var(--space-sm); font-size: var(--text-sm); }
.footer__col h2 { font-size: var(--text-md); letter-spacing: 0; font-family: var(--font-body); font-weight: 600; color: var(--color-night-muted); }
.footer__col ul { margin: 0; padding: 0; list-style: none; display: grid; gap: var(--space-2xs); }
.footer a { color: var(--color-night-ink); text-decoration-color: var(--color-night-muted); }
.footer a:hover { text-decoration-color: var(--color-accent); }
.footer__col a { display: inline-flex; align-items: center; min-height: 32px; }
.footer__col p { color: var(--color-night-muted); max-width: 40ch; }
.footer__base { grid-column: 1 / -1; display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-sm) var(--space-xl); padding-top: var(--space-lg); border-top: 1px solid var(--color-night-rule); font-size: var(--text-xs); color: var(--color-night-muted); }
.footer__base a { color: var(--color-night-muted); }
@media (max-width: 60rem) { .footer__brand, .footer__col { grid-column: 1 / -1; } }

/* ---------- Legal pages ---------- */
.doc { padding-block: var(--space-2xl) var(--section-gap-s); }
.doc__inner { max-width: 72ch; }
.doc h1 { font-size: var(--text-display-s); max-width: 16ch; }
.doc__meta { margin-top: var(--space-md); color: var(--color-muted); }
.doc__toc { margin: var(--space-xl) 0 0; padding: var(--space-lg); border: 1px solid var(--color-rule); background: var(--color-surface); border-radius: var(--radius-card); }
.doc__toc h2 { font-family: var(--font-body); font-size: var(--text-md); letter-spacing: 0; font-weight: 600; margin-bottom: var(--space-sm); }
.doc__toc ol { margin: 0; padding-left: 1.25rem; display: grid; gap: var(--space-2xs); }
.doc__body h2 { font-size: var(--text-2xl); margin: var(--space-2xl) 0 var(--space-md); max-width: none; scroll-margin-top: 100px; }
.doc__body h3 { font-size: var(--text-lg); margin: var(--space-lg) 0 var(--space-xs); }
.doc__body p, .doc__body li { max-width: 68ch; }
.doc__body p + p { margin-top: var(--space-sm); }
.doc__body ul, .doc__body ol { padding-left: 1.25rem; display: grid; gap: var(--space-xs); margin: var(--space-sm) 0; }
.doc__body a:not(.btn) { font-weight: 600; text-decoration-color: var(--color-accent); text-decoration-thickness: 2px; }
.doc__body table { width: 100%; border-collapse: collapse; margin: var(--space-md) 0; font-size: var(--text-sm); }
.doc__body th, .doc__body td { text-align: left; padding: var(--space-sm); border-bottom: 1px solid var(--color-rule); vertical-align: top; }
.doc__body thead th { font-weight: 600; border-bottom: 2px solid var(--color-ink); }
.table-wrap { overflow-x: auto; }

/* ---------- Thank-you / 404 ---------- */
.notice { min-height: 60vh; display: grid; align-content: center; gap: var(--space-lg); padding-block: var(--space-3xl); }
.notice h1 { font-size: var(--text-display-s); }
.notice p { color: var(--color-muted); font-size: var(--text-lead); }

strong, b, th { font-weight: 600; }
.doc__body { margin-top: var(--space-xl); }
