/* ==========================================================================
   Moldapta — Site Institucional (Claro, Simples e Direto)
   ========================================================================== */

:root {
  --bg: #ffffff;
  --bg-alt: #f8fafc;
  --surface: #ffffff;
  --text: #0f172a;
  --text-muted: #475569;
  --border: #e2e8f0;
  --radius: 14px;
  --shadow: 0 10px 30px -12px rgba(15, 23, 42, 0.08);
}

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

html {
  scroll-behavior: smooth;
  accent-color: var(--adapt-c1);
}

::selection {
  background: color-mix(in srgb, var(--adapt-c2) 22%, transparent);
  color: var(--text);
}

:focus-visible {
  outline: 2px solid var(--adapt-c1);
  outline-offset: 2px;
}

body {
  margin: 0;
  font-family: "DM Sans", system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  caret-color: var(--adapt-c1);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: "Bricolage Grotesque", system-ui, sans-serif;
  line-height: 1.2;
  margin: 0 0 0.75rem;
  letter-spacing: -0.02em;
}

p {
  margin: 0 0 1rem;
  color: var(--text-muted);
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--text);
  color: #ffffff;
  padding: 0.75rem 1.25rem;
  font-weight: 600;
  border-radius: 0 0 10px 0;
}

.skip-link:focus {
  left: 0;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  height: 72px;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.brand-logo {
  height: 40px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  font-size: 0.95rem;
  font-weight: 500;
}

.nav-links a:not(.btn):hover {
  color: var(--adapt-c1);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.5rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-sm {
  padding: 0.55rem 1.1rem;
  font-size: 0.875rem;
}

.btn-primary {
  background: color-mix(in srgb, var(--adapt-c1, #2563EB) 78%, #090D16);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.14);
}

.btn-primary:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
}

.btn-outline {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}

.btn-outline:hover {
  border-color: var(--adapt-c2);
  color: var(--adapt-c1);
}

.btn-full {
  width: 100%;
}

.section-first {
  padding-top: 3.25rem;
}

.section-head-hero {
  max-width: 720px;
  margin-bottom: 2rem;
}

.section-head-hero h1 {
  font-size: clamp(2rem, 4vw, 2.9rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 0.75rem;
}

.section-head-hero .highlight {
  color: var(--adapt-c1);
}

.section-head-hero p {
  font-size: 1.08rem;
}

/* Sections */
section[id] {
  scroll-margin-top: 88px;
}

.section {
  padding: 4.25rem 0;
}

.section-alt {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-head {
  max-width: 600px;
  margin-bottom: 2.5rem;
}

.section-head h2 {
  font-size: clamp(1.75rem, 3.2vw, 2.35rem);
  font-weight: 800;
}

.section-head p {
  font-size: 1.02rem;
  margin: 0;
}

/* Niche Showcase (Interactive Commercial Examples) */
.niche-showcase {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  margin-bottom: 1.5rem;
}

.niche-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 1rem 1.25rem;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}

.niche-tab {
  min-height: 44px;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.niche-tab:hover {
  border-color: var(--adapt-c2);
  color: var(--text);
}

.niche-tab.is-active {
  background: color-mix(in srgb, var(--adapt-c1, #2563EB) 82%, #090D16);
  border-color: transparent;
  color: #ffffff;
}

.niche-panel {
  display: grid;
  grid-template-columns: 1.45fr 0.85fr;
  gap: 2rem;
  padding: 2rem;
  align-items: center;
}

.niche-panel[hidden] {
  display: none;
}

.niche-panel-main h2 {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.niche-pain {
  font-size: 1rem;
  margin-bottom: 1.25rem;
}

.niche-deliverables {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem 1.25rem;
}

.niche-deliverables li {
  position: relative;
  padding-left: 1.5rem;
  font-size: 0.96rem;
  color: var(--text);
  font-weight: 500;
}

.niche-deliverables li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--adapt-c2);
}

.niche-panel-side {
  background: color-mix(in srgb, var(--adapt-c2) 7%, var(--bg-alt));
  border: 1px solid color-mix(in srgb, var(--adapt-c2) 26%, var(--border));
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  align-items: flex-start;
}

.niche-side-title {
  font-family: "Bricolage Grotesque", system-ui, sans-serif;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--adapt-c1);
  line-height: 1.25;
}

.niche-side-note {
  margin: 0;
  font-size: 0.92rem;
  color: var(--text-muted);
}

.niche-cta {
  width: 100%;
}

/* Pillars Strip */
.pillars-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.pillar-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.pillar-item strong {
  font-family: "Bricolage Grotesque", system-ui, sans-serif;
  font-size: 1.05rem;
  color: var(--adapt-c1);
}

.pillar-item span {
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* Compare */
.compare-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.compare-box {
  border-radius: var(--radius);
  padding: 1.85rem;
  border: 1px solid var(--border);
}

.compare-old {
  background: var(--bg-alt);
}

.compare-new {
  background: var(--surface);
  border-color: color-mix(in srgb, var(--adapt-c2) 45%, var(--border));
  box-shadow: var(--shadow);
}

.compare-box h3 {
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

.compare-new h3 {
  color: var(--adapt-c1);
}

.compare-box ul {
  margin: 0;
  padding-left: 1.2rem;
  display: grid;
  gap: 0.7rem;
  color: var(--text-muted);
  font-size: 0.96rem;
}

/* Steps */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.step-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.6rem;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--adapt-c2) 15%, transparent);
  color: var(--adapt-c1);
  font-weight: 800;
  font-size: 0.95rem;
  margin-bottom: 0.9rem;
}

.step-item h3 {
  font-size: 1.1rem;
}

.step-item p {
  font-size: 0.94rem;
  margin: 0;
}

/* Contact */
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 3rem;
  align-items: start;
}

.contact-info h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
}

.contact-highlights {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
  display: grid;
  gap: 0.65rem;
}

.contact-highlights li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 500;
  font-size: 0.95rem;
}

.contact-highlights li::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--adapt-c3);
  flex-shrink: 0;
}

.whatsapp-direct {
  margin-top: 1.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
}

.whatsapp-direct-label {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text);
}

.btn-whatsapp {
  background: #15803d;
  color: #ffffff;
  gap: 0.55rem;
  box-shadow: 0 4px 12px rgba(21, 128, 61, 0.18);
}

.btn-whatsapp:hover {
  background: #166534;
  transform: translateY(-1px);
}

.whatsapp-direct-note {
  margin: 0;
  font-size: 0.86rem;
  color: var(--text-muted);
  min-height: 1.2em;
}

.contact-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.85rem;
}

.form-group {
  margin-bottom: 1.1rem;
}

.form-row-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.9rem;
}

.form-group label,
.field-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 0.45rem;
  color: var(--text);
}

.label-opt {
  font-weight: 400;
  color: var(--text-muted);
}

.topic-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.75rem;
}

.topic-chip {
  min-height: 36px;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.83rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}

.topic-chip:hover {
  border-color: var(--adapt-c2);
  color: var(--text);
}

.topic-chip.is-active {
  background: color-mix(in srgb, var(--adapt-c2) 14%, var(--surface));
  border-color: var(--adapt-c1);
  color: var(--adapt-c1);
  font-weight: 600;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.72rem 0.9rem;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-group input[aria-invalid="true"],
.form-group textarea[aria-invalid="true"] {
  border-color: #b91c1c;
}

.field-error {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.82rem;
  color: #b91c1c;
  font-weight: 500;
  min-height: 1.1em;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--adapt-c2);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--adapt-c2) 18%, transparent);
}

.form-feedback {
  margin: 0.9rem 0 0;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text);
  min-height: 1.3em;
}

.form-feedback-link {
  display: inline-block;
  margin-top: 0.5rem;
  font-weight: 700;
  color: var(--adapt-c1);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem 0;
  background: var(--bg-alt);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.92rem;
  color: var(--text-muted);
}

.footer-brand strong {
  color: var(--text);
}

.footer-copy {
  margin: 0;
  font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 900px) {
  .hero-grid,
  .niche-panel,
  .niche-deliverables,
  .compare-grid,
  .steps-grid,
  .contact-wrap {
    grid-template-columns: 1fr;
  }

  .pillars-strip,
  .form-row-2 {
    grid-template-columns: repeat(2, 1fr);
  }

  .niche-panel {
    padding: 1.5rem;
  }

  .hero {
    padding: 3.5rem 0 3rem;
  }
}

@media (max-width: 680px) {
  .header-inner {
    flex-wrap: wrap;
    height: auto;
    padding: 0.75rem 0;
    gap: 0.75rem;
  }

  .nav-links {
    width: 100%;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.55rem 0.9rem;
    font-size: 0.85rem;
  }

  .nav-links .btn-sm {
    min-height: 44px;
    padding: 0.6rem 1rem;
  }

  .form-row-2 {
    grid-template-columns: 1fr;
  }

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

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
