/* ===================================================================
   Pragma Empreendimentos — Landing page
   Direção visual: monocromática, editorial, arquitetônica.
   Preto profundo / grafite / cinzas / off-white. Sem dourado,
   sem gradientes coloridos, sem glassmorphism.
   =================================================================== */

:root {
  /* Paleta institucional */
  --black: #0b0b0b;
  --graphite: #181818;
  --gray: #737373;
  --gray-light: #d6d6d3;
  --offwhite: #f3f2ef;
  --white: #ffffff;

  /* Neutros derivados — necessários para contraste AA em texto pequeno */
  --text: #2b2b2b;    /* corpo sobre fundo claro */
  --muted: #5a5a5a;   /* meta e labels sobre fundo claro */
  --label: #a7a7a7;   /* labels sobre fundo escuro */

  /* Fios de 1px */
  --rule-dark: rgba(11, 11, 11, 0.12);
  --rule-darker: rgba(11, 11, 11, 0.28);
  --rule-light: rgba(255, 255, 255, 0.08);
  --rule-lighter: rgba(255, 255, 255, 0.28);

  /* Didone, para acompanhar o wordmark da marca */
  --font-display: "Bodoni Moda", "Noto Serif Display", Georgia, "Times New Roman", serif;
  --font-sans: "Manrope", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  --maxw: 1320px;
  --gutter: clamp(20px, 5vw, 48px);
  --section-y: clamp(64px, 10vw, 160px);
  --radius: 2px;
  --header-h: 84px;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.75;
  color: var(--text);
  background: var(--offwhite);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body.nav-open { overflow: hidden; }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }

::selection { background: var(--black); color: var(--offwhite); }
:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* Barra de progresso de leitura — 2px, monocromática */
.scroll-progress {
  position: fixed; top: 0; left: 0; z-index: 90;
  height: 2px; width: 0;
  background: var(--offwhite);
  transition: width 0.1s linear;
}

/* ---------- Tipografia ---------- */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--black);
  letter-spacing: -0.015em;
}
h1 { font-size: clamp(2.2rem, 5.4vw, 4.6rem); line-height: 1.08; }
h2 { font-size: clamp(1.85rem, 3.5vw, 3rem); line-height: 1.14; }
h3 { font-size: clamp(1.1rem, 1.6vw, 1.35rem); line-height: 1.3; font-weight: 500; }

.display-line { display: block; }

.eyebrow {
  display: flex; align-items: center; gap: 14px;
  font-family: var(--font-sans);
  font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 26px;
}
.eyebrow::before {
  content: ""; flex: 0 0 auto;
  width: 28px; height: 1px; background: var(--rule-darker);
}

.lead {
  font-size: clamp(1rem, 1.35vw, 1.15rem);
  font-weight: 300;
  line-height: 1.7;
  max-width: 58ch;
}

.label {
  font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
}

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.85em;
  font-family: var(--font-sans);
  font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
  padding: 17px 28px;
  border: 1px solid transparent; border-radius: var(--radius);
  background: transparent; cursor: pointer; white-space: nowrap;
  transition: background 0.4s var(--ease), color 0.4s var(--ease), border-color 0.4s var(--ease);
}
.btn__arrow { display: inline-block; transition: transform 0.4s var(--ease); }
.btn:hover .btn__arrow { transform: translateX(5px); }
.btn-block { width: 100%; }

/* sobre fundo escuro */
.btn-solid { background: var(--offwhite); color: var(--black); border-color: var(--offwhite); }
.btn-solid:hover { background: transparent; color: var(--offwhite); }
.btn-outline { color: var(--offwhite); border-color: var(--rule-lighter); }
.btn-outline:hover { border-color: var(--offwhite); }

/* sobre fundo claro */
.btn-dark { background: var(--black); color: var(--offwhite); border-color: var(--black); }
.btn-dark:hover { background: transparent; color: var(--black); }
.btn-line { color: var(--black); border-color: var(--rule-darker); }
.btn-line:hover { border-color: var(--black); }

/* ---------- Header ---------- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 70;
  border-bottom: 1px solid transparent;
  transition: background 0.5s var(--ease), border-color 0.5s var(--ease);
}
.site-header.scrolled {
  background: var(--black);
  border-bottom-color: var(--rule-light);
}
.nav {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  height: var(--header-h);
}

/* Marca — arquivo oficial (assets/logo-pragma-claro.png).
   Sobre fundo claro, trocar o src por assets/logo-pragma-escuro.png. */
.brand { display: inline-flex; align-items: center; flex: 0 0 auto; }
.brand-logo { display: block; width: auto; height: 46px; }

/* Navegação */
.nav-links { display: flex; align-items: center; gap: clamp(20px, 2.4vw, 40px); }
.nav-links a {
  position: relative;
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: rgba(243, 242, 239, 0.72);
  padding: 6px 0;
  transition: color 0.3s var(--ease);
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 100%; height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: left;
  transition: transform 0.45s var(--ease);
}
.nav-links a:hover, .nav-links a:focus-visible { color: var(--offwhite); }
.nav-links a:hover::after { transform: scaleX(1); }

.nav-toggle {
  display: none; flex-direction: column; gap: 6px;
  background: none; border: 0; cursor: pointer; padding: 8px; margin-right: -8px;
}
.nav-toggle span {
  display: block; width: 26px; height: 1px; background: var(--offwhite);
  transition: transform 0.35s var(--ease), opacity 0.25s linear;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: 92vh;
  display: flex; align-items: flex-end;
  padding: calc(var(--header-h) + clamp(60px, 12vw, 140px)) 0 clamp(56px, 8vw, 104px);
  background: var(--black);
  color: var(--offwhite);
}
.hero-photo {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%; object-fit: cover;
  filter: saturate(0.72) contrast(1.03);
}
.hero-overlay {
  position: absolute; inset: 0; z-index: -1;
  /* Camada única: escurece o lado do texto e libera a arquitetura à direita.
     Os stops foram calibrados medindo o contraste WCAG sobre os pixels reais
     da foto atrás de cada linha de texto (mínimo obtido: 5.09 no lead). */
  background: linear-gradient(
    100deg,
    rgba(11, 11, 11, 0.88) 0%,
    rgba(11, 11, 11, 0.78) 40%,
    rgba(11, 11, 11, 0.45) 72%,
    rgba(11, 11, 11, 0.22) 100%
  );
}
.hero-inner { position: relative; }
.hero-content { max-width: 900px; }
.hero-content .lead { max-width: 52ch; }
.hero .eyebrow { color: var(--gray-light); }
.hero .eyebrow::before { background: var(--rule-lighter); }
.hero h1 { color: var(--white); margin-bottom: clamp(22px, 3vw, 34px); }
.hero .lead { color: var(--gray-light); }
.hero-cta {
  display: flex; flex-wrap: wrap; gap: 14px;
  margin-top: clamp(34px, 4.5vw, 52px);
}

/* ---------- Seções ---------- */
.section { padding: var(--section-y) 0; }
.section--white { background: var(--white); }
.section--dark { background: var(--black); color: var(--gray-light); }
.section--dark h2, .section--dark h3 { color: var(--white); }
.section--dark .eyebrow { color: var(--label); }
.section--dark .eyebrow::before { background: var(--rule-lighter); }

.section-head { max-width: 62ch; margin-bottom: clamp(48px, 6vw, 84px); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .eyebrow { justify-content: center; }
.section-head .lead { margin-top: 22px; color: var(--muted); }
.section--dark .section-head .lead { color: var(--gray-light); }

/* ---------- Sobre ---------- */
.split {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 7vw, 110px); align-items: center;
}
.split__text p { margin-bottom: 20px; }
.split__text p:last-of-type { margin-bottom: 0; }
.split__text strong { font-weight: 600; color: var(--black); }

.rule-list { list-style: none; margin-top: clamp(32px, 4vw, 46px); border-top: 1px solid var(--rule-dark); }
.rule-list li {
  padding: 16px 0; border-bottom: 1px solid var(--rule-dark);
  font-size: 0.95rem;
  display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: baseline;
}
.rule-list li::before {
  content: ""; width: 18px; height: 1px; background: var(--rule-darker);
  transform: translateY(-4px);
}

.split__visual { position: relative; }
.split__frame { position: relative; overflow: hidden; aspect-ratio: 4 / 5; background: var(--graphite); }
.split__frame img { width: 100%; height: 100%; object-fit: cover; filter: saturate(0.7) contrast(1.03); }
.split__caption {
  margin-top: 18px; display: flex; align-items: center; gap: 12px;
  font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted);
}
.split__caption::before { content: ""; width: 24px; height: 1px; background: var(--rule-darker); }

/* ---------- Atuação (pilares editoriais) ---------- */
.pillars { border-top: 1px solid var(--rule-dark); }
.pillar {
  position: relative;
  display: grid; grid-template-columns: 3.5rem minmax(0, 1fr) minmax(0, 1.15fr);
  gap: clamp(16px, 4vw, 64px); align-items: baseline;
  padding: clamp(28px, 3.6vw, 46px) 0;
  border-bottom: 1px solid var(--rule-dark);
  transition: border-color 0.5s var(--ease);
}
.pillar::before {
  content: ""; position: absolute; left: 0; bottom: -1px;
  width: 0; height: 1px; background: var(--black);
  transition: width 0.7s var(--ease);
}
.pillar:hover { border-bottom-color: transparent; }
.pillar:hover::before { width: 100%; }
.pillar__num {
  font-family: var(--font-display); font-size: 0.95rem;
  color: var(--gray); letter-spacing: 0.04em;
}
.pillar__title {
  font-family: var(--font-sans); font-size: clamp(1rem, 1.4vw, 1.2rem);
  font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--black); line-height: 1.4;
  transition: transform 0.5s var(--ease);
}
.pillar:hover .pillar__title { transform: translateX(5px); }
.pillar__desc { color: var(--muted); font-size: 0.95rem; font-weight: 300; }

/* ---------- Empreendimentos ---------- */
.projects { display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(28px, 3.4vw, 56px); }
.project { display: block; }
.project__frame {
  position: relative; overflow: hidden;
  aspect-ratio: 4 / 3; background: var(--graphite);
}
.project__frame img {
  width: 100%; height: 100%; object-fit: cover;
  filter: saturate(0.68) contrast(1.04);
  transform: scale(1);
  transition: transform 0.75s var(--ease);
}
.project__frame::after {
  content: ""; position: absolute; inset: 0;
  background: rgba(11, 11, 11, 0.14);
  transition: background 0.75s var(--ease);
}
.project:hover .project__frame img { transform: scale(1.04); }
.project:hover .project__frame::after { background: rgba(11, 11, 11, 0.04); }

.project__meta {
  display: flex; justify-content: space-between; align-items: baseline; gap: 20px;
  margin-top: 22px; padding-top: 20px;
  border-top: 1px solid var(--rule-dark);
  transition: border-color 0.5s var(--ease);
}
.project:hover .project__meta { border-top-color: var(--rule-darker); }
.project__name { font-family: var(--font-display); font-size: clamp(1.25rem, 1.9vw, 1.65rem); color: var(--black); }
.project__type { margin-top: 6px; font-size: 0.9rem; font-weight: 300; color: var(--muted); }
.project__status {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 9px;
  font-size: 0.66rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted);
}
.project__status::before {
  content: ""; width: 5px; height: 5px;
  border: 1px solid var(--muted); background: transparent;
}
.project__status--live::before { background: var(--black); border-color: var(--black); }

/* ---------- Números ---------- */
.figures { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(36px, 5vw, 72px); }
.figure { border-top: 1px solid var(--rule-light); padding-top: clamp(20px, 2.6vw, 32px); }
.figure__value {
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(2.4rem, 4.6vw, 4rem); line-height: 1; color: var(--white);
  letter-spacing: -0.02em;
}
/* unidade ao lado do numeral, para os quatro números manterem o mesmo corpo */
.figure__unit {
  font-family: var(--font-display);
  font-size: clamp(1rem, 1.5vw, 1.35rem); line-height: 1;
  color: var(--white); margin-left: 0.28em;
}
.figure__label {
  display: block; margin-top: 16px;
  font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--label);
}

/* ---------- Contato ---------- */
.contact { align-items: start; }
.contact-list { list-style: none; margin-top: clamp(32px, 4vw, 44px); border-top: 1px solid var(--rule-dark); }
.contact-list li {
  padding: 18px 0; border-bottom: 1px solid var(--rule-dark);
  display: grid; grid-template-columns: 8.5rem minmax(0, 1fr); gap: 16px; align-items: baseline;
}
.contact-list dt, .contact-list .ci {
  font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted);
}
.contact-list a { transition: color 0.3s var(--ease); border-bottom: 1px solid var(--rule-dark); }
.contact-list a:hover { color: var(--black); border-bottom-color: var(--black); }

.contact-form { display: grid; gap: 22px; }
.field { display: grid; gap: 8px; }
.field label {
  font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted);
}
.field input, .field select, .field textarea {
  font-family: var(--font-sans); font-size: 0.95rem; font-weight: 400;
  color: var(--black); background: var(--white);
  padding: 14px 16px;
  border: 1px solid var(--rule-dark); border-radius: var(--radius);
  transition: border-color 0.3s var(--ease);
}
.field input::placeholder, .field textarea::placeholder { color: var(--gray); }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--black);
}
.field textarea { resize: vertical; min-height: 120px; }
.field select { appearance: none; background-image: none; }
.form-note { font-size: 0.85rem; min-height: 1.4em; color: var(--muted); }
.form-note.ok { color: var(--black); }
.form-note.err { color: #8f2b23; }

/* ---------- Footer ---------- */
.site-footer { background: var(--black); color: var(--gray-light); }
.footer-top {
  display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(36px, 5vw, 72px);
  padding: clamp(56px, 7vw, 96px) 0 clamp(40px, 5vw, 64px);
}
.footer-brand .brand-logo { height: 48px; }
.footer-tagline {
  margin-top: 24px; font-family: var(--font-display);
  font-size: 1.15rem; color: var(--offwhite);
}
.footer-col h2 {
  font-family: var(--font-sans); font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--label);
  margin-bottom: 22px;
}
.footer-col ul { list-style: none; display: grid; gap: 12px; }
.footer-col a, .footer-col span { font-size: 0.92rem; font-weight: 300; color: var(--gray-light); }
.footer-col a { transition: color 0.3s var(--ease); }
.footer-col a:hover { color: var(--white); }

.footer-base {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px 32px;
  padding: 26px 0 34px;
  border-top: 1px solid var(--rule-light);
  font-size: 0.76rem; font-weight: 300; color: var(--gray);
}
/* créditos das fotos licenciadas — linha própria, discreta */
.footer-credits { flex-basis: 100%; font-size: 0.7rem; line-height: 1.6; }
.footer-credits a { border-bottom: 1px solid rgba(255, 255, 255, 0.2); transition: color 0.3s var(--ease); }
.footer-credits a:hover { color: var(--gray-light); border-bottom-color: var(--gray-light); }

/* ---------- Reveal ---------- */
.reveal {
  opacity: 0; transform: translateY(22px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
  transition-delay: var(--reveal-delay, 0s);
}
.reveal.in { opacity: 1; transform: none; }

/* ---------- Responsivo ---------- */
@media (max-width: 1080px) {
  .figures { grid-template-columns: repeat(2, 1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  :root { --header-h: 72px; }

  .brand-logo { height: 34px; }
  .footer-brand .brand-logo { height: 40px; }

  .nav-toggle { display: flex; }
  .nav-links {
    position: fixed; inset: 0; z-index: 60; /* abaixo do header (70), acima das seções */
    flex-direction: column; align-items: flex-start; justify-content: center;
    gap: 4px;
    padding: var(--header-h) var(--gutter) 40px;
    background: var(--black);
    opacity: 0; visibility: hidden;
    /* visibility comuta na hora ao abrir e só depois do fade ao fechar */
    transition: opacity 0.45s var(--ease), visibility 0s linear 0.45s;
  }
  .nav-links.open {
    opacity: 1; visibility: visible;
    transition: opacity 0.45s var(--ease), visibility 0s linear 0s;
  }
  .nav-links a {
    width: 100%; padding: 20px 0;
    font-family: var(--font-display); font-size: 1.6rem;
    font-weight: 400; letter-spacing: 0.02em; text-transform: none;
    color: var(--offwhite);
    border-bottom: 1px solid var(--rule-light);
  }
  .nav-links a::after { display: none; }
  .site-header.nav-is-open { background: var(--black); }

  .hero { min-height: 88vh; align-items: center; }
  /* No mobile o texto é centralizado e a foto é o corte retrato, então o
     scrim vira vertical. Mínimo medido: 4.91 no eyebrow. */
  .hero-overlay {
    background: linear-gradient(
      180deg,
      rgba(11, 11, 11, 0.62) 0%,
      rgba(11, 11, 11, 0.7) 45%,
      rgba(11, 11, 11, 0.82) 100%
    );
  }
  .split { grid-template-columns: 1fr; gap: clamp(32px, 6vw, 56px); }
  .split__visual { order: -1; }
  .contact .split__visual, .contact__form-wrap { order: 0; }
  .split__frame { aspect-ratio: 3 / 2; }

  .pillar { grid-template-columns: 2.5rem minmax(0, 1fr); row-gap: 12px; }
  .pillar__desc { grid-column: 2; }

  .projects { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .figures { grid-template-columns: 1fr; gap: 32px; }
  .footer-top { grid-template-columns: 1fr; }
  .footer-brand { grid-column: auto; }
  .contact-list li { grid-template-columns: 1fr; gap: 6px; }
  .hero-cta .btn { width: 100%; }
  .project__meta { flex-direction: column; align-items: flex-start; gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .project__frame img, .pillar__title, .pillar::before, .btn__arrow { transition: none; }
  .project:hover .project__frame img { transform: none; }
  .pillar:hover .pillar__title { transform: none; }
}
