/* =========================================================
   Centro 2S — Design system
   Cores e tipografia herdadas da identidade atual (ver plano
   secção 7): verde/laranja/cinzentos + Roboto/Poppins.
   ========================================================= */

:root {
  --color-green: #007706;
  --color-green-dark: #005c04;
  --color-orange: #F2811C;
  --color-orange-dark: #d66f11;
  --color-grey: #8A8A8A;
  --color-text: #4a4a4a;
  --color-text-light: #828282;
  --color-dark: #1f2226;
  --color-dark-2: #2b2f34;
  --color-white: #ffffff;
  --color-bg: #ffffff;
  --color-bg-alt: #f6f7f8;
  --color-border: #e4e4e4;

  --font-body: 'Roboto', Arial, sans-serif;
  --font-heading: 'Poppins', Arial, sans-serif;

  --container-w: 1180px;
  --radius: 8px;
  --shadow-card: 0 4px 18px rgba(0, 0, 0, 0.08);
  --shadow-card-hover: 0 10px 28px rgba(0, 0, 0, 0.14);

  --header-h: 84px;
}

/* ---------- Reset básico ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; }
button { font-family: inherit; }

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--color-dark);
  margin: 0 0 0.5em;
  line-height: 1.25;
  font-weight: 600;
}
h1 { font-size: clamp(2rem, 4vw, 3rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }

.container {
  width: 100%;
  max-width: var(--container-w);
  margin: 0 auto;
  padding: 0 24px;
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--color-green);
  color: #fff;
  padding: 10px 16px;
  z-index: 1000;
}
.skip-link:focus {
  left: 8px;
  top: 8px;
}

/* ---------- Botões ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 12px 24px;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}
.btn:hover, .btn:focus-visible { transform: translateY(-1px); }
.btn-primary {
  background: var(--color-green);
  color: #fff;
}
.btn-primary:hover { background: var(--color-green-dark); }
.btn-outline {
  background: transparent;
  border-color: currentColor;
  color: var(--color-dark);
}
.btn-outline:hover { background: rgba(0,0,0,0.04); }
.btn-on-dark.btn-outline {
  color: #fff;
  border-color: rgba(255,255,255,0.7);
}
.btn-on-dark.btn-outline:hover { background: rgba(255,255,255,0.12); }
.btn-orange {
  background: var(--color-orange);
  color: #fff;
}
.btn-orange:hover { background: var(--color-orange-dark); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 500;
  background: #fff;
  border-bottom: 1px solid var(--color-border);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  gap: 24px;
}
.logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  flex-shrink: 0;
  display: block;
}
.logo .logo-centro { color: var(--color-grey); }
.logo .logo-2s { color: var(--color-orange); }
.logo-img { height: 34px; width: auto; display: block; }
.logo-img-footer { height: 30px; }

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
  justify-content: center;
}
.main-nav a {
  display: block;
  padding: 10px 16px;
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--color-dark);
  border-radius: var(--radius);
  transition: color 0.15s ease, background-color 0.15s ease;
}
.main-nav a:hover,
.main-nav a[aria-current="page"] {
  color: var(--color-green);
  background: rgba(0,119,6,0.08);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.lang-switch {
  display: flex;
  gap: 2px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.85rem;
}
.lang-switch a {
  padding: 6px 8px;
  border-radius: 4px;
  color: var(--color-text-light);
}
.lang-switch a[aria-current="true"] {
  color: var(--color-dark);
  background: var(--color-bg-alt);
}
.btn-remote {
  background: var(--color-green);
  color: #fff;
  font-size: 0.85rem;
  padding: 10px 16px;
}
.btn-remote:hover { background: var(--color-green-dark); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
}
.nav-toggle .bar {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-dark);
  margin: 5px 0;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 720px;
  display: flex;
  align-items: center;
  color: #fff;
  background: linear-gradient(120deg, var(--color-dark) 0%, var(--color-dark-2) 100%);
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-size: cover;
  background-position: center;
  opacity: 1;
  transition: opacity 0.4s ease;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(10,14,13,0.4) 0%, rgba(10,14,13,0.58) 100%);
}
.hero-content {
  position: relative;
  z-index: 2;
  max-width: 720px;
  padding: 96px 0;
}
.hero-nav-arrows,
.hero-dots { z-index: 3; }
.hero-eyebrow {
  display: inline-block;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--color-orange);
  margin-bottom: 16px;
}
.hero h1 { color: #fff; text-shadow: 0 2px 16px rgba(0,0,0,0.45); }
.hero p.lead {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.92);
  max-width: 560px;
  text-shadow: 0 1px 10px rgba(0,0,0,0.4);
}
.hero-eyebrow { text-shadow: 0 1px 10px rgba(0,0,0,0.4); }
.hero-actions {
  display: flex;
  gap: 16px;
  margin-top: 32px;
  flex-wrap: wrap;
}
.hero-nav-arrows {
  position: absolute;
  bottom: 28px;
  right: 24px;
  display: flex;
  gap: 8px;
  z-index: 2;
}
.hero-nav-arrows button {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.08);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.15s ease;
}
.hero-nav-arrows button:hover { background: rgba(255,255,255,0.2); }

.hero-dots {
  position: absolute;
  bottom: 30px;
  left: 24px;
  display: flex;
  gap: 8px;
  z-index: 2;
}
.hero-dots button {
  width: 8px; height: 8px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  cursor: pointer;
}
.hero-dots button.active { background: #fff; }

/* ---------- Page hero (páginas internas, mais curto) ---------- */
.page-hero {
  background: linear-gradient(120deg, var(--color-dark) 0%, var(--color-dark-2) 100%);
  color: #fff;
  padding: 64px 0;
}
.page-hero h1 { color: #fff; margin-bottom: 12px; }
.page-hero p { color: rgba(255,255,255,0.8); max-width: 640px; margin: 0; }
.breadcrumb {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  margin-bottom: 16px;
}
.breadcrumb a { color: rgba(255,255,255,0.85); }
.breadcrumb a:hover { text-decoration: underline; }

/* ---------- Secções genéricas ---------- */
.section { padding: 88px 0; }
.section-alt { background: var(--color-bg-alt); }
.section-header {
  max-width: 680px;
  margin: 0 auto 48px;
  text-align: center;
}
.section-header .eyebrow {
  display: block;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--color-green);
  margin-bottom: 10px;
}
.section-header p { color: var(--color-text-light); }

/* ---------- Cartões de destaque (Home) ---------- */
/* Sobrepostos à base do hero, replicando o mockup aprovado (secção 7 do plano). */
.cards-overlap-wrap {
  margin-top: -64px;
  position: relative;
  z-index: 5;
}
.cards-overlap {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-card-hover);
  overflow: hidden;
}
.cards-overlap .card {
  border: none;
  border-right: 1px solid var(--color-border);
  border-radius: 0;
  box-shadow: none;
}
.cards-overlap .card:last-child { border-right: none; }
.cards-overlap .card:hover {
  transform: none;
  box-shadow: none;
  background: var(--color-bg-alt);
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 32px 28px;
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.card:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-3px);
}
.card-icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  background: rgba(0,119,6,0.1);
  color: var(--color-green);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}
.card-icon svg { width: 26px; height: 26px; }
.card-icon-mono {
  width: 48px; height: 48px;
  border-radius: 10px;
  background: rgba(0,119,6,0.1);
  color: var(--color-green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 18px;
}
.card h3 { margin-bottom: 8px; }
.card p { color: var(--color-text-light); margin-bottom: 0; font-size: 0.95rem; }
.card p + p { margin-top: 10px; }
.card p.card-highlight {
  color: var(--color-green);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.92rem;
}

/* ---------- Interoperabilidade (nova secção) ---------- */
.interop-section .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.interop-visual {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-card-hover);
  line-height: 0;
}
.interop-visual img { width: 100%; height: auto; }
.interop-list { margin-top: 20px; padding-left: 0; list-style: none; }
.interop-list li {
  display: flex;
  gap: 10px;
  padding: 8px 0;
  font-size: 0.9rem;
}
.interop-list li::before {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--color-orange);
  margin-top: 6px;
  flex-shrink: 0;
}

/* ---------- Áreas de atuação / prova social ---------- */
.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  text-align: center;
}
.stat-item strong {
  display: block;
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--color-green);
}
.stat-item span { color: var(--color-text-light); font-size: 0.9rem; }

/* ---------- Mapa + estatística de clientes ---------- */
.social-proof-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 48px;
  align-items: center;
}
.map-stat {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  line-height: 0;
}
.map-stat img { width: 100%; display: block; }
.map-stat-overlay {
  position: absolute;
  top: 50%;
  left: 6%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.9);
  padding: 20px 28px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}
.map-stat-overlay strong {
  display: block;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 2.6rem;
  line-height: 1;
  color: var(--color-green);
}
.map-stat-overlay span {
  display: block;
  margin-top: 4px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  color: var(--color-dark);
}
.stats-col {
  display: flex;
  flex-direction: column;
  gap: 32px;
}
.stats-col .stat-item { text-align: left; }

/* ---------- CTA final ---------- */
.cta-band {
  background: var(--color-green);
  color: #fff;
  padding: 64px 0;
  text-align: center;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,0.85); max-width: 560px; margin: 0 auto 28px; }

/* ---------- Listas de soluções/serviços ---------- */
.offer-list { display: flex; flex-direction: column; gap: 32px; }
.offer-item {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 24px;
  padding: 28px;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
}
.offer-icon {
  width: 56px; height: 56px;
  border-radius: 12px;
  background: rgba(242,129,28,0.12);
  color: var(--color-orange);
  display: flex;
  align-items: center;
  justify-content: center;
}
.offer-icon svg { width: 28px; height: 28px; }
.offer-item h3 { margin-bottom: 6px; }
.offer-item ul { margin-top: 12px; padding-left: 20px; color: var(--color-text-light); font-size: 0.92rem; }
.offer-item li { margin-bottom: 4px; }

/* ---------- Placeholders visuais (fotos/ilustrações) ---------- */
.placeholder-visual {
  background: repeating-linear-gradient(45deg, #eceff1, #eceff1 10px, #e4e8eb 10px, #e4e8eb 20px);
  border: 1px dashed #b7bfc4;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6b7378;
  font-size: 0.85rem;
  text-align: center;
  padding: 24px;
  min-height: 220px;
}

/* ---------- Página Empresa ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: start;
}
.about-values {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 24px;
}
.value-item h4 { margin-bottom: 4px; font-size: 1rem; }
.value-item p { font-size: 0.9rem; color: var(--color-text-light); margin-bottom: 0; }

/* ---------- Formulário de contacto ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: start;
}
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 6px;
  color: var(--color-dark);
}
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--color-text);
  background: #fff;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: 2px solid var(--color-green);
  outline-offset: 1px;
  border-color: var(--color-green);
}
.form-error {
  color: #c62828;
  font-size: 0.82rem;
  margin-top: 4px;
  display: none;
}
.form-group.has-error .form-error { display: block; }
.form-group.has-error input,
.form-group.has-error textarea { border-color: #c62828; }
.form-status {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  display: none;
}
.form-status.show { display: block; }
.form-status.success { background: rgba(0,119,6,0.1); color: var(--color-green-dark); }
.form-status.error { background: rgba(198,40,40,0.1); color: #c62828; }
.honeypot-field { position: absolute; left: -9999px; top: -9999px; }

.contact-info-list { list-style: none; margin-bottom: 32px; }
.contact-info-list li {
  display: flex;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--color-border);
}
.contact-info-list li:last-child { border-bottom: none; }
.contact-info-list .ci-icon {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(0,119,6,0.1);
  color: var(--color-green);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.contact-info-list .ci-icon svg { width: 20px; height: 20px; }
.map-embed {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--color-border);
}
.map-embed iframe { width: 100%; height: 280px; border: 0; display: block; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-dark);
  color: rgba(255,255,255,0.75);
  padding: 56px 0 28px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
}
.footer-grid h4 {
  color: #fff;
  font-size: 0.95rem;
  margin-bottom: 16px;
}
.footer-logo { margin-bottom: 12px; }
.footer-grid p { font-size: 0.88rem; color: rgba(255,255,255,0.6); }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 10px; font-size: 0.9rem; }
.footer-links a:hover { color: var(--color-orange); }
.funding-bar {
  margin-top: 40px;
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,0.1);
  text-align: center;
}
.funding-bar img {
  max-width: 480px;
  width: 100%;
  background: #fff;
  padding: 14px 18px;
  border-radius: 6px;
  margin: 0 auto 16px;
}
.funding-links {
  display: flex;
  gap: 24px;
  justify-content: center;
  flex-wrap: wrap;
  font-size: 0.8rem;
}
.funding-links a { color: rgba(255,255,255,0.65); text-decoration: underline; }
.funding-links a:hover { color: #fff; }

.footer-bottom {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.1);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.5);
}

/* ---------- Placeholder marker (conteúdo a confirmar) ---------- */
.tbc {
  background: rgba(242,129,28,0.15);
  border: 1px dashed var(--color-orange);
  padding: 2px 6px;
  border-radius: 4px;
  font-style: italic;
}

/* =========================================================
   Responsivo
   ========================================================= */
@media (max-width: 980px) {
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
  .cards-overlap { grid-template-columns: 1fr; }
  .cards-overlap .card { border-right: none; border-bottom: 1px solid var(--color-border); }
  .cards-overlap .card:last-child { border-bottom: none; }
  .cards-overlap-wrap { margin-top: -40px; }
  .interop-section .container,
  .about-grid,
  .contact-grid,
  .social-proof-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  .main-nav {
    position: fixed;
    top: var(--header-h);
    left: 0; right: 0;
    background: #fff;
    flex-direction: column;
    align-items: stretch;
    padding: 12px 24px 24px;
    border-bottom: 1px solid var(--color-border);
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
  }
  .main-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  .main-nav a { padding: 14px 8px; border-bottom: 1px solid var(--color-border); }
  .nav-toggle { display: block; }
  .header-actions .btn-remote span.long { display: none; }
  .cards-grid { grid-template-columns: 1fr; }
  .stats-row { grid-template-columns: 1fr; gap: 32px; }
  .about-values { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .offer-item { grid-template-columns: 1fr; }
  .section { padding: 64px 0; }
  .hero { min-height: 560px; }
  .hero-content { padding: 72px 0; }
}

.nav-toggle[aria-expanded="true"] .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
