/* Direction contract lives as an HTML comment in index.html's <body> — see that file. */

:root {
  --graphite: #14181A;
  --graphite-soft: #1D2325;
  --graphite-line: #2B3234;
  --teal: #0E6E63;
  --teal-soft: #0B5A51;
  --teal-bright: #17A392;
  --paper: #F2F4F1;
  --paper-2: #E7EAE6;
  --white: #FFFFFF;
  --ink: #1B1F1D;
  --ink-secondary: #5B6462;
  --on-graphite: #E9ECEA;
  --on-graphite-dim: rgba(233, 236, 234, 0.62);
  --on-teal: #F2F4F1;
  --border: #C9D0CB;
  --notch: 26px;
  --notch-sm: 16px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --max-width: 1180px;
  /* Type scale — five steps, ≥1.25 ratio apart */
  --fs-label: 0.72rem;   /* 11.52px */
  --fs-body: 0.94rem;    /* 15.04px */
  --fs-sub: 1.45rem;     /* 23.2px */
  --fs-h2: clamp(1.5rem, 2.4vw, 1.75rem);  /* 24–28px */
  --fs-h1: clamp(2.2rem, 4vw, 3rem);       /* 35.2–48px */
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Public Sans', -apple-system, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  font-size: var(--fs-body);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1.75rem; }
section { padding: 5.5rem 0; }

h1, h2, h3 {
  font-family: 'Public Sans', sans-serif;
  color: var(--ink);
  font-weight: 700;
  letter-spacing: -0.01em;
}

.mono {
  font-family: 'JetBrains Mono', 'Courier New', monospace;
  letter-spacing: 0.02em;
}

/* ---------- Signature shape: cut top-right corner ---------- */
.protocol-card {
  clip-path: polygon(0 0, calc(100% - var(--notch)) 0, 100% var(--notch), 100% 100%, 0 100%);
}
.protocol-card-sm {
  clip-path: polygon(0 0, calc(100% - var(--notch-sm)) 0, 100% var(--notch-sm), 100% 100%, 0 100%);
}

/* ---------- Header ---------- */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: var(--graphite);
  border-bottom: 1px solid var(--graphite-line);
}

.header .nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.75rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.protocol-id {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.protocol-id .tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--teal-bright);
  border: 1px solid var(--teal-soft);
  padding: 0.35rem 0.6rem;
}

.protocol-id .name {
  font-weight: 700;
  font-size: var(--fs-body);
  color: var(--on-graphite);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2.1rem;
  list-style: none;
}

.nav-links a {
  color: var(--on-graphite-dim);
  font-size: var(--fs-body);
  font-weight: 500;
  transition: color 0.15s var(--ease);
}
.nav-links a:hover { color: var(--on-graphite); }

.nav-links .nav-restrito {
  font-family: 'JetBrains Mono', monospace;
  font-size: var(--fs-label);
  color: var(--teal-bright);
  border-left: 1px solid var(--graphite-line);
  padding-left: 1.5rem;
}
.nav-links .nav-restrito:hover { color: var(--on-graphite); }

.nav-links .contact-btn {
  color: var(--on-teal);
  background: var(--teal);
  padding: 0.55rem 1.2rem;
}
.nav-links .contact-btn:hover { background: var(--teal-soft); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}
.nav-toggle span { width: 24px; height: 1.5px; background: var(--on-graphite); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: 'Public Sans', sans-serif;
  font-size: var(--fs-body);
  font-weight: 700;
  padding: 0.8rem 1.6rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 0.15s var(--ease), border-color 0.15s var(--ease), color 0.15s var(--ease);
}

.btn-accent { background: var(--teal); color: var(--on-teal); }
.btn-accent:hover { background: var(--teal-soft); }

.btn-outline { border-color: rgba(233, 236, 234, 0.4); color: var(--on-graphite); }
.btn-outline:hover { border-color: var(--on-graphite); }

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

/* ---------- Hero ---------- */
.hero {
  background: var(--graphite);
  padding: 8.5rem 0 5rem;
}

.hero-card {
  background: var(--graphite-soft);
  border: 1px solid var(--graphite-line);
  padding: 2.75rem 3rem;
  max-width: 760px;
}

.protocol-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: var(--fs-body);
  color: var(--teal-bright);
  letter-spacing: 0.03em;
  margin-bottom: 1.4rem;
}
.protocol-label::before {
  content: '';
  width: 7px; height: 7px;
  background: var(--teal-bright);
}

.hero h1 {
  color: var(--on-graphite);
  font-size: var(--fs-h1);
  line-height: 1.2;
  margin-bottom: 1.4rem;
  max-width: 22ch;
}

.hero p {
  color: var(--on-graphite-dim);
  font-size: var(--fs-body);
  max-width: 52ch;
  margin-bottom: 2rem;
}

.hero .hero-actions { display: flex; gap: 0.9rem; flex-wrap: wrap; margin-bottom: 1.75rem; }

.seal {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  border: 1px solid var(--teal-soft);
  padding: 0.55rem 1rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: var(--fs-body);
  color: var(--teal-bright);
  letter-spacing: 0.05em;
}
.seal svg { flex-shrink: 0; }

/* ---------- Section heads ---------- */
.section-head { max-width: 640px; margin-bottom: 2.75rem; }
.section-head .protocol-label { color: var(--teal-soft); }
.section-head .protocol-label::before { background: var(--teal-soft); }
.section-head h2 { font-size: var(--fs-h2); margin-bottom: 0.75rem; }
.section-head p { color: var(--ink-secondary); font-size: var(--fs-body); }

/* ---------- Record table (Quem Somos / Contato facts) ---------- */
.record-table {
  background: var(--white);
  border: 1px solid var(--border);
}

.record-row {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 1.5rem;
  padding: 1.1rem 1.5rem;
  border-bottom: 1px solid var(--paper-2);
}
.record-row:last-child { border-bottom: none; }

.record-row dt {
  font-family: 'JetBrains Mono', monospace;
  font-size: var(--fs-label);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-secondary);
}

.record-row dd { color: var(--ink); font-weight: 600; font-size: var(--fs-body); }

/* ---------- Sobre ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3.5rem;
  align-items: start;
}

.about-text p { color: var(--ink-secondary); margin-bottom: 1.1rem; max-width: 60ch; font-size: var(--fs-body); }

/* ---------- Serviços — protocol index table ---------- */
.benefit-index {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 10px;
}

.benefit-row {
  display: grid;
  grid-template-columns: 96px 1fr;
  border-bottom: 1px solid var(--paper-2);
}
.benefit-row:last-child { border-bottom: none; }

.benefit-code {
  background: var(--graphite);
  color: var(--teal-bright);
  font-family: 'JetBrains Mono', monospace;
  font-size: var(--fs-label);
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1rem 0.75rem;
}

.benefit-body { padding: 1.6rem 2rem; }

.benefit-body h3 {
  font-size: var(--fs-sub);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.benefit-body p { color: var(--ink-secondary); font-size: var(--fs-body); max-width: 62ch; }

/* ---------- CTA strip ---------- */
.cta-strip {
  background: var(--teal);
  padding: 3.25rem 0;
}

.cta-strip .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.cta-strip h3 { color: var(--on-teal); font-size: var(--fs-sub); font-weight: 700; }
.cta-strip p { color: rgba(242, 244, 241, 0.78); font-size: var(--fs-body); margin-top: 0.25rem; }
.cta-strip .btn-ghost { background: var(--graphite); color: var(--on-graphite); border-color: var(--graphite); }
.cta-strip .btn-ghost:hover { background: var(--graphite-soft); }

/* ---------- Contato ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3.5rem; }

.map-frame {
  border: 1px solid var(--border);
  width: 100%;
  height: 220px;
  margin-top: 1.5rem;
  filter: grayscale(0.5) contrast(1.05);
}

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

.field { margin-bottom: 1.15rem; }

.field label {
  display: block;
  font-family: 'JetBrains Mono', monospace;
  font-size: var(--fs-label);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-secondary);
  margin-bottom: 0.4rem;
}

.field input, .field textarea {
  width: 100%;
  border: 1px solid var(--border);
  padding: 0.7rem 0.85rem;
  font-size: var(--fs-body);
  font-family: inherit;
  color: var(--ink);
  background: var(--paper);
  transition: border-color 0.15s var(--ease);
}

.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(14, 110, 99, 0.14);
}

.form-card .btn { width: 100%; justify-content: center; border: none; }

/* ---------- Footer ---------- */
.footer {
  background: var(--graphite);
  color: var(--on-graphite-dim);
  padding: 3.25rem 0 1.75rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-bottom: 2.25rem;
  padding-bottom: 2.25rem;
  border-bottom: 1px solid var(--graphite-line);
}

.footer-grid h3 {
  font-family: 'JetBrains Mono', monospace;
  color: var(--on-graphite);
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.1rem;
}

.footer-grid ul { list-style: none; display: flex; flex-direction: column; gap: 0.65rem; font-size: var(--fs-body); }
.footer-grid a:hover { color: var(--teal-bright); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: var(--fs-label);
}

.footer-bottom .link-restrito { color: rgba(233, 236, 234, 0.4); font-family: 'JetBrains Mono', monospace; }
.footer-bottom .link-restrito:hover { color: var(--teal-bright); }

.footer-credit {
  margin-top: 1.1rem;
  font-size: 0.72rem;
  color: rgba(233, 236, 234, 0.35);
  font-family: 'JetBrains Mono', monospace;
}
.footer-credit a { color: rgba(233, 236, 234, 0.5); }
.footer-credit a:hover { color: var(--teal-bright); }

/* ---------- WhatsApp — a protocol-tab, not a floating bubble ---------- */
.whatsapp-float {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--teal);
  color: var(--on-teal);
  border: 1px solid var(--teal-soft);
  padding: 0.7rem 1.15rem;
  font-size: var(--fs-body);
  font-weight: 700;
  z-index: 90;
  transition: background-color 0.15s var(--ease);
}
.whatsapp-float:hover { background: var(--teal-soft); }
.whatsapp-float svg { flex-shrink: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .record-row { grid-template-columns: 1fr; gap: 0.35rem; }
  .benefit-row { grid-template-columns: 1fr; }
  .benefit-code { justify-content: flex-start; padding: 0.6rem 1.5rem; }
  .nav-links, .nav-links .contact-btn { display: none; }
  .nav-toggle { display: flex; }
  .header.open .nav-links {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--graphite);
    flex-direction: column;
    align-items: flex-start;
    padding: 1.5rem 1.75rem;
    gap: 1.1rem;
    border-top: 1px solid var(--graphite-line);
  }
  .nav-links .nav-restrito { border-left: none; padding-left: 0; }
  .hero { padding: 7rem 0 3.5rem; }
  .hero-card { padding: 2rem; }
}

@media (max-width: 520px) {
  section { padding: 3.75rem 0; }
  .cta-strip .container { flex-direction: column; align-items: flex-start; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .whatsapp-float span { display: none; }
}
