/* ============================================================
   1. Variáveis visuais
   As cores e medidas partilhadas ficam centralizadas para facilitar
   futuras alterações à identidade da SoftwareMC.
   ============================================================ */
:root {
  --ink: #07111f;
  --ink-soft: #111f30;
  --paper: #f7f4ed;
  --white: #ffffff;
  --blue: #2d5bff;
  --blue-deep: #163bbf;
  --coral: #ff6b4a;
  --lime: #c7ff5e;
  --muted: #697386;
  --line: rgba(7, 17, 31, 0.14);
  --radius: 22px;
  --shadow: 0 28px 80px rgba(4, 11, 22, 0.18);
  --shell: min(1180px, calc(100vw - 48px));
}

/* Reset mínimo para que o layout se comporte de forma previsível em browsers diferentes. */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Rolagem suave entre as âncoras da página, respeitando a altura do cabeçalho fixo. */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Aptos", "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

/* Regras base de tipografia, links, formulários e foco acessível. */
a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
a,
input,
textarea,
select {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 4px;
}

.shell {
  width: var(--shell);
  margin-inline: auto;
}

/* Link invisível até receber foco: ajuda utilizadores que navegam apenas com teclado. */
.skip-link {
  position: fixed;
  left: 18px;
  top: -60px;
  z-index: 1000;
  padding: 12px 18px;
  background: var(--lime);
  color: var(--ink);
  font-weight: 800;
  border-radius: 0 0 10px 10px;
  transition: top 0.2s ease;
}

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

/* ============================================================
   2. Navegação e cabeçalho
   ============================================================ */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  color: var(--white);
  transition: background 0.25s ease, box-shadow 0.25s ease, color 0.25s ease;
}

.site-header.is-scrolled {
  color: var(--ink);
  background: rgba(247, 244, 237, 0.9);
  box-shadow: 0 1px 0 rgba(7, 17, 31, 0.1);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}

.nav-shell {
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 21px;
  font-weight: 700;
  letter-spacing: -0.05em;
}

.brand strong {
  color: var(--coral);
  font-weight: 850;
}

.brand-mark {
  width: 33px;
  height: 33px;
  display: grid;
  place-items: center;
  color: var(--ink);
  background: var(--lime);
  border-radius: 9px 9px 9px 2px;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: -0.05em;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 32px;
  font-size: 14px;
  font-weight: 650;
}

.main-nav > a:not(.nav-cta) {
  position: relative;
  opacity: 0.78;
}

.main-nav > a:not(.nav-cta)::after {
  content: "";
  position: absolute;
  inset: auto 0 -7px;
  height: 2px;
  background: var(--coral);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}

.main-nav > a:not(.nav-cta):hover::after {
  transform: scaleX(1);
}

.nav-cta {
  padding: 11px 17px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.site-header.is-scrolled .nav-cta {
  border-color: var(--line);
}

.nav-cta:hover {
  color: var(--ink);
  background: var(--lime);
  border-color: var(--lime);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: currentColor;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 23px;
  height: 2px;
  margin: 6px auto;
  background: currentColor;
  transition: transform 0.2s ease;
}

/* ============================================================
   3. Hero
   A grelha e os círculos criam profundidade sem depender de imagens externas.
   ============================================================ */
.hero {
  min-height: 820px;
  position: relative;
  display: grid;
  align-items: center;
  overflow: hidden;
  color: var(--white);
  background:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px),
    var(--ink);
  background-size: 70px 70px;
  padding: 146px 0 86px;
}

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 140px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.13));
  pointer-events: none;
}

.hero-orbit {
  position: absolute;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 50%;
  pointer-events: none;
}

.hero-orbit-one {
  width: 680px;
  height: 680px;
  right: -260px;
  top: -220px;
}

.hero-orbit-two {
  width: 340px;
  height: 340px;
  left: -180px;
  bottom: -60px;
}

.hero-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 0.87fr) minmax(550px, 1.13fr);
  align-items: center;
  gap: 62px;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 25px;
  color: rgba(255,255,255,0.68);
  font-size: 12px;
  font-weight: 750;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.eyebrow span {
  width: 8px;
  height: 8px;
  background: var(--lime);
  border-radius: 50%;
  box-shadow: 0 0 0 5px rgba(199,255,94,0.12);
}

.hero h1,
.section-intro h2,
.solutions-heading h2,
.contact-copy h2 {
  margin: 0;
  font-size: clamp(3.3rem, 5.2vw, 5.3rem);
  line-height: 0.95;
  letter-spacing: -0.067em;
  text-wrap: balance;
}

.hero h1 em,
.section-intro h2 em,
.contact-copy h2 em {
  color: var(--coral);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
}

.hero-lead {
  max-width: 570px;
  margin: 28px 0 0;
  color: rgba(255,255,255,0.68);
  font-size: 18px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-top: 36px;
}

.button {
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 0 22px;
  border: 0;
  border-radius: 4px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button span {
  font-size: 20px;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  color: var(--ink);
  background: var(--lime);
  box-shadow: 8px 8px 0 var(--blue);
}

.button-primary:hover {
  box-shadow: 4px 4px 0 var(--blue);
}

.text-link {
  display: inline-flex;
  gap: 12px;
  align-items: center;
  padding: 12px 0;
  color: rgba(255,255,255,0.78);
  font-weight: 700;
  border-bottom: 1px solid rgba(255,255,255,0.25);
}

.trust-list {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 20px;
  margin: 44px 0 0;
  padding: 25px 0 0;
  border-top: 1px solid rgba(255,255,255,0.1);
  list-style: none;
  color: rgba(255,255,255,0.57);
  font-size: 12px;
  font-weight: 650;
}

.trust-list span {
  color: var(--lime);
  margin-right: 5px;
}

/* Inclinação subtil do mockup para o fazer parecer um produto apresentado em perspetiva. */
.hero-product {
  position: relative;
  transform: perspective(1600px) rotateY(-3deg) rotateX(1deg);
}

/* Janela de aplicação ilustrativa usada na primeira dobra da página. */
.product-window {
  overflow: hidden;
  background: #eff2f7;
  border: 1px solid rgba(255,255,255,0.23);
  border-radius: 16px;
  box-shadow: 0 46px 110px rgba(0,0,0,0.38), -22px 20px 0 rgba(45,91,255,0.14);
}

.window-topbar {
  height: 43px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 15px;
  color: #8792a4;
  background: #fff;
  border-bottom: 1px solid #dde2ea;
  font-size: 9px;
}

.window-dots {
  display: flex;
  gap: 5px;
}

.window-dots span {
  width: 6px;
  height: 6px;
  background: #d6dce5;
  border-radius: 50%;
}

.window-title {
  flex: 1;
  text-align: center;
}

.online-dot {
  padding: 3px 7px;
  color: #167a57;
  background: #def7ea;
  border-radius: 10px;
}

.app-frame {
  height: 420px;
  display: grid;
  grid-template-columns: 52px 1fr;
  color: var(--ink);
}

.app-sidebar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 23px;
  padding-top: 16px;
  background: var(--ink-soft);
}

.mini-brand {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  margin-bottom: 14px;
  color: var(--ink);
  background: var(--lime);
  border-radius: 7px;
  font-size: 9px;
  font-weight: 900;
}

.side-pill {
  width: 16px;
  height: 6px;
  background: #536077;
  border-radius: 10px;
}

.side-pill.active {
  width: 24px;
  background: var(--coral);
}

.app-main {
  padding: 23px 24px;
}

.app-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.app-heading small {
  color: #8b95a5;
  font-size: 9px;
}

.app-heading h2 {
  margin: 4px 0 0;
  font-size: 17px;
  letter-spacing: -0.035em;
}

.app-avatar {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  color: white;
  background: var(--blue);
  border-radius: 50%;
  font-size: 9px;
  font-weight: 800;
}

.app-kpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 22px;
}

.app-kpi {
  min-height: 105px;
  display: flex;
  flex-direction: column;
  padding: 14px;
  background: #fff;
  border: 1px solid #e0e5ed;
  border-radius: 10px;
}

.app-kpi.coral {
  color: white;
  background: var(--coral);
  border-color: var(--coral);
}

.app-kpi.lime {
  background: var(--lime);
  border-color: var(--lime);
}

.app-kpi span,
.app-kpi small {
  color: #7c8798;
  font-size: 8px;
}

.app-kpi.coral span,
.app-kpi.coral small {
  color: rgba(255,255,255,0.7);
}

.app-kpi strong {
  margin: 6px 0 auto;
  font-size: 20px;
  letter-spacing: -0.04em;
}

.app-kpi .positive {
  color: #23835f;
}

.app-bottom {
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  gap: 10px;
  margin-top: 10px;
}

.chart-card,
.agenda-card {
  height: 177px;
  padding: 15px;
  background: white;
  border: 1px solid #e0e5ed;
  border-radius: 10px;
}

.chart-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 9px;
}

.chart-head span {
  color: #8d97a6;
  font-size: 8px;
}

.bars {
  height: 115px;
  display: flex;
  align-items: end;
  gap: 8px;
  padding-top: 18px;
  border-bottom: 1px solid #e6eaf0;
}

.bars i {
  width: 12%;
  height: var(--bar);
  background: var(--blue);
  border-radius: 4px 4px 0 0;
}

.bars i:nth-child(2n) {
  background: #9fb0ff;
}

.agenda-card > strong {
  font-size: 9px;
}

.agenda-card > div {
  display: grid;
  grid-template-columns: 37px 1fr;
  gap: 8px;
  margin-top: 13px;
  padding-top: 11px;
  border-top: 1px solid #e9edf2;
  font-size: 8px;
}

.agenda-card time {
  color: var(--blue);
  font-weight: 800;
}

.agenda-card span {
  display: flex;
  flex-direction: column;
  color: #8b95a5;
}

.agenda-card b {
  color: var(--ink);
  font-size: 9px;
}

/* Etiquetas flutuantes que destacam certificação e acompanhamento próximo. */
.certification-float,
.support-float {
  position: absolute;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 15px;
  color: var(--ink);
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 18px 45px rgba(0,0,0,0.22);
  transform: translateZ(20px);
}

.certification-float {
  right: -22px;
  bottom: 36px;
}

.support-float {
  left: -30px;
  top: 75px;
}

.cert-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  color: white;
  background: var(--blue);
  border-radius: 8px;
  font-size: 11px;
  font-weight: 900;
}

.certification-float > span:last-child,
.support-float > span:last-child {
  display: flex;
  flex-direction: column;
}

.certification-float strong,
.support-float strong {
  font-size: 10px;
}

.certification-float small,
.support-float small {
  color: #8993a2;
  font-size: 8px;
}

.pulse-dot {
  width: 9px;
  height: 9px;
  background: #2ad893;
  border-radius: 50%;
  box-shadow: 0 0 0 5px rgba(42,216,147,0.16);
}

/* ============================================================
   4. Manifesto e secções de conteúdo
   ============================================================ */
.manifesto-strip {
  position: relative;
  z-index: 3;
  overflow: hidden;
  color: var(--ink);
  background: var(--lime);
  transform: rotate(-1deg) scale(1.02);
}

.marquee-content {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  font-size: clamp(17px, 2vw, 25px);
  font-weight: 850;
  letter-spacing: -0.04em;
  white-space: nowrap;
}

.marquee-content i {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  background: var(--coral);
  border-radius: 50%;
}

/* Espaçamento vertical comum às secções claras e escuras. */
.section {
  padding: 125px 0;
}

.section-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
  align-items: end;
  gap: 80px;
}

.section-number {
  display: block;
  margin-bottom: 24px;
  color: var(--blue);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.12em;
}

.section-number.light {
  color: var(--lime);
}

.section-intro h2 {
  font-size: clamp(2.9rem, 5vw, 4.9rem);
}

.section-intro p,
.solutions-heading p {
  margin: 0 0 7px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.75;
}

/* Lista de serviços com separadores para leitura rápida em desktop e mobile. */
.service-list {
  margin-top: 78px;
  border-top: 1px solid var(--line);
}

.service-row {
  display: grid;
  grid-template-columns: 45px 92px 1fr;
  align-items: start;
  gap: 30px;
  padding: 46px 0;
  border-bottom: 1px solid var(--line);
}

.service-index {
  padding-top: 17px;
  color: #9a9ea6;
  font-family: Georgia, serif;
  font-size: 13px;
}

.service-symbol {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 28px;
  transition: transform 0.25s ease;
}

.service-row:hover .service-symbol {
  transform: rotate(8deg) scale(1.06);
}

.coral-symbol { background: var(--coral); }
.blue-symbol { color: white; background: var(--blue); }
.lime-symbol { background: var(--lime); }

.service-copy {
  display: grid;
  grid-template-columns: 0.7fr 1.3fr;
  column-gap: 55px;
  align-items: start;
}

.service-copy h3,
.clinic-copy h3,
.product-card h3 {
  margin: 5px 0 0;
  font-size: 30px;
  line-height: 1.08;
  letter-spacing: -0.045em;
}

.service-copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.tag-list {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 18px;
}

.tag-list span {
  padding: 7px 11px;
  color: #536074;
  background: #ece9e1;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ============================================================
   5. Soluções e cartões de produto
   ============================================================ */
.solutions {
  color: white;
  background: var(--ink);
}

.section-kicker {
  display: flex;
  align-items: start;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}

.section-kicker p {
  margin: 0;
  color: rgba(255,255,255,0.46);
  font-size: 13px;
}

.solutions-heading {
  display: grid;
  grid-template-columns: 1fr 330px;
  align-items: end;
  gap: 70px;
  margin: 40px 0 72px;
}

.solutions-heading h2 {
  font-size: clamp(3.2rem, 6vw, 6.2rem);
}

.solutions-heading p {
  color: rgba(255,255,255,0.55);
}

/* Cartão de destaque da Gestão de Clínicas. */
.clinic-feature {
  min-height: 630px;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  overflow: hidden;
  color: var(--ink);
  background: var(--lime);
  border-radius: var(--radius);
}

.clinic-copy {
  z-index: 2;
  padding: 62px 50px;
}

.product-label {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #4b6022;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.12em;
}

.product-dot {
  width: 7px;
  height: 7px;
  background: var(--coral);
  border-radius: 50%;
}

.clinic-copy h3 {
  margin-top: 24px;
  font-size: clamp(2.6rem, 4vw, 4.2rem);
}

.clinic-copy > p {
  max-width: 490px;
  margin: 22px 0 0;
  color: #415020;
  font-size: 17px;
  line-height: 1.7;
}

.feature-checks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 13px;
  margin: 30px 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
  font-weight: 700;
}

.feature-checks span {
  display: inline-grid;
  width: 19px;
  height: 19px;
  place-items: center;
  margin-right: 6px;
  color: white;
  background: var(--blue);
  border-radius: 50%;
  font-size: 10px;
}

.cert-badge {
  display: flex;
  align-items: center;
  gap: 13px;
  max-width: 430px;
  margin-bottom: 28px;
  padding: 13px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(7,17,31,0.12);
  border-radius: 11px;
}

.cert-badge-mark {
  width: 42px;
  height: 42px;
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  color: white;
  background: var(--blue);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 900;
}

.cert-badge > span:last-child {
  display: flex;
  flex-direction: column;
}

.cert-badge strong {
  font-size: 12px;
}

.cert-badge small {
  color: #596732;
  font-size: 10px;
}

.button-dark {
  color: white;
  background: var(--ink);
  box-shadow: 7px 7px 0 var(--coral);
}

.button-dark:hover {
  box-shadow: 3px 3px 0 var(--coral);
}

/* Área gráfica do cartão de clínicas: os cartões internos são decorativos. */
.clinic-visual {
  position: relative;
  min-height: 630px;
  overflow: hidden;
  background: var(--blue);
}

.visual-grid {
  position: absolute;
  inset: 0;
  opacity: 0.24;
  background-image: linear-gradient(rgba(255,255,255,0.16) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.16) 1px, transparent 1px);
  background-size: 45px 45px;
  transform: perspective(500px) rotate(8deg) scale(1.15);
}

.patient-card,
.metric-card,
.mini-calendar {
  position: absolute;
  color: var(--ink);
  background: white;
  border: 1px solid rgba(7,17,31,0.1);
  border-radius: 14px;
  box-shadow: 0 30px 65px rgba(5,14,60,0.27);
}

.patient-card {
  width: 350px;
  left: 50%;
  top: 50%;
  padding: 24px;
  transform: translate(-52%, -55%) rotate(-3deg);
}

.patient-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.patient-top > span:nth-child(2) {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.patient-top b { font-size: 13px; }
.patient-top small { color: #8790a0; font-size: 9px; }
.patient-top i { color: #9fa7b3; font-style: normal; }

.patient-avatar {
  width: 43px;
  height: 43px;
  display: grid;
  place-items: center;
  color: white;
  background: var(--coral);
  border-radius: 50%;
  font-size: 11px;
  font-weight: 800;
}

.patient-data {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 24px;
}

.patient-data span {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 13px;
  background: #f1f3f7;
  border-radius: 8px;
}

.patient-data small { color: #8a94a4; font-size: 8px; }
.patient-data b { font-size: 10px; }
.patient-data .status-ok { color: #24805e; }

.patient-note {
  margin-top: 22px;
}

.patient-note span {
  display: block;
  width: 100%;
  height: 7px;
  margin-top: 8px;
  background: #e9edf2;
  border-radius: 5px;
}

.patient-note span:nth-child(2) { width: 82%; }
.patient-note span:nth-child(3) { width: 61%; }

.metric-card {
  width: 190px;
  right: 24px;
  top: 70px;
  padding: 20px;
  transform: rotate(5deg);
}

.metric-card small { color: #8d96a4; }
.metric-card strong { display: block; margin-top: 3px; font-size: 43px; letter-spacing: -0.06em; }
.metric-card sup { color: var(--coral); font-size: 17px; }
.metric-card > div { height: 50px; display: flex; align-items: end; gap: 6px; margin-top: 6px; }
.metric-card i { width: 12px; background: var(--blue); border-radius: 4px 4px 0 0; }
.metric-card i:nth-child(1) { height: 38%; }
.metric-card i:nth-child(2) { height: 50%; }
.metric-card i:nth-child(3) { height: 45%; }
.metric-card i:nth-child(4) { height: 65%; }
.metric-card i:nth-child(5) { height: 78%; }
.metric-card i:nth-child(6) { height: 92%; background: var(--coral); }

.mini-calendar {
  width: 260px;
  left: 20px;
  bottom: 54px;
  padding: 19px;
  transform: rotate(3deg);
}

.mini-calendar > strong { font-size: 13px; }
.mini-calendar > div { display: grid; grid-template-columns: repeat(5, 1fr); margin-top: 15px; color: #9aa3b1; font-size: 8px; text-align: center; }
.mini-calendar .dates { margin-top: 7px; color: var(--ink); }
.mini-calendar i { display: grid; height: 28px; place-items: center; font-style: normal; }
.mini-calendar .today { color: white; background: var(--coral); border-radius: 50%; }

/* Grelha das três soluções adicionais. */
.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 18px;
}

.product-card {
  min-width: 0;
  overflow: hidden;
  color: var(--ink);
  background: #f2eee6;
  border-radius: 17px;
}

.product-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px;
  border-bottom: 1px solid var(--line);
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 0.11em;
}

.product-arrow {
  width: 29px;
  height: 29px;
  display: grid;
  place-items: center;
  background: white;
  border-radius: 50%;
  font-size: 14px;
}

/* Ilustrações CSS dos produtos: mapa, rede de pessoas e calendário de planeamento. */
.route-art,
.people-art,
.schedule-art {
  position: relative;
  height: 260px;
  overflow: hidden;
}

.route-art {
  background: var(--coral);
}

.route-art::before,
.route-art::after {
  content: "";
  position: absolute;
  background: rgba(255,255,255,0.18);
}

.route-art::before { width: 1px; height: 100%; left: 50%; }
.route-art::after { width: 100%; height: 1px; top: 50%; }
.route-art b { position: absolute; right: 25px; bottom: 8px; color: rgba(255,255,255,0.14); font-size: 98px; line-height: 1; }

.map-ring {
  position: absolute;
  border: 1px solid rgba(255,255,255,0.37);
  border-radius: 50%;
}

.ring-one { width: 210px; height: 210px; left: -25px; top: 20px; }
.ring-two { width: 125px; height: 125px; left: 18px; top: 62px; }

.map-pin {
  position: absolute;
  z-index: 3;
  width: 20px;
  height: 20px;
  background: var(--lime);
  border: 5px solid white;
  border-radius: 50% 50% 50% 0;
  box-shadow: 0 8px 15px rgba(67,18,6,0.24);
  transform: rotate(-45deg);
}

.pin-one { left: 96px; top: 63px; }
.pin-two { left: 199px; top: 166px; }
.route-line { position: absolute; width: 137px; height: 100px; left: 90px; top: 82px; border-bottom: 3px dashed white; border-right: 3px dashed white; border-radius: 0 0 80px 0; transform: rotate(4deg); }

.product-association .people-art { background: var(--lime); }

.person {
  position: absolute;
  z-index: 2;
  display: grid;
  place-items: center;
  color: white;
  background: var(--blue);
  border: 6px solid rgba(255,255,255,0.7);
  border-radius: 50%;
  box-shadow: 0 12px 25px rgba(7,17,31,0.14);
  font-size: 11px;
  font-weight: 800;
}

.p1 { width: 78px; height: 78px; left: 50%; top: 50%; transform: translate(-50%,-50%); }
.p2 { width: 58px; height: 58px; left: 40px; top: 45px; background: var(--coral); }
.p3 { width: 62px; height: 62px; right: 45px; top: 36px; background: var(--ink); }
.p4 { width: 60px; height: 60px; right: 51px; bottom: 27px; color: var(--ink); background: white; }

.connect { position: absolute; width: 2px; height: 105px; left: 50%; top: 38px; background: rgba(7,17,31,0.2); transform-origin: bottom; }
.c1 { transform: rotate(-51deg); }
.c2 { transform: rotate(52deg); }
.c3 { top: 118px; transform: rotate(121deg); }

.product-schedule .schedule-art { background: var(--blue); }

.schedule-month {
  position: absolute;
  left: 28px;
  top: 25px;
  width: 113px;
  height: 138px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  background: var(--lime);
  border-radius: 10px;
  box-shadow: 0 18px 30px rgba(0,0,0,0.18);
  transform: rotate(-4deg);
}

.schedule-month small { font-size: 8px; font-weight: 850; letter-spacing: 0.15em; }
.schedule-month strong { font-size: 55px; line-height: 1; letter-spacing: -0.08em; }
.schedule-month span { margin-top: 6px; font-size: 7px; font-weight: 800; }

.schedule-lines {
  position: absolute;
  right: 25px;
  top: 50px;
  width: 185px;
  padding: 18px;
  background: white;
  border-radius: 10px;
  box-shadow: 0 18px 30px rgba(0,0,0,0.19);
  transform: rotate(3deg);
}

.schedule-lines i { display: block; height: 8px; margin: 12px 0; background: #e5e9f0; border-radius: 5px; }
.schedule-lines b { display: block; width: var(--width); height: 100%; background: var(--coral); border-radius: inherit; }
.schedule-lines i:nth-child(2) b,
.schedule-lines i:nth-child(4) b { background: var(--blue); }

.schedule-check {
  position: absolute;
  right: 35px;
  bottom: 28px;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  color: var(--ink);
  background: var(--coral);
  border: 5px solid white;
  border-radius: 50%;
  font-size: 20px;
  font-weight: 900;
}

.product-card-copy {
  min-height: 245px;
  padding: 28px 26px 30px;
}

.product-card h3 {
  font-size: 27px;
}

.product-card-copy > p {
  min-height: 78px;
  margin: 16px 0 0;
  color: #626d7b;
  font-size: 14px;
  line-height: 1.65;
}

.product-card .tag-list {
  display: flex;
  margin-top: 20px;
}

.dark-tags span {
  color: #4d5869;
  background: white;
}

/* ============================================================
   6. Processo e contacto
   ============================================================ */
.method {
  background: var(--paper);
}

.method-intro {
  align-items: end;
}

.method-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 90px;
}

.method-step {
  padding-right: 34px;
}

.method-step > span {
  color: var(--coral);
  font-family: Georgia, serif;
  font-size: 14px;
  font-style: italic;
}

.step-line {
  position: relative;
  height: 1px;
  margin: 18px 0 28px;
  background: var(--line);
}

.step-line::before {
  content: "";
  position: absolute;
  left: 0;
  top: -4px;
  width: 9px;
  height: 9px;
  background: var(--blue);
  border-radius: 50%;
}

.method-step h3 {
  margin: 0;
  font-size: 22px;
  letter-spacing: -0.04em;
}

.method-step p {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

/* Área de contacto com contraste elevado para funcionar como CTA final. */
.contact-section {
  position: relative;
  overflow: hidden;
  padding: 115px 0;
  color: white;
  background: var(--blue);
}

.contact-section::before {
  content: "";
  position: absolute;
  width: 520px;
  height: 520px;
  left: -230px;
  bottom: -260px;
  border: 100px solid rgba(199,255,94,0.11);
  border-radius: 50%;
}

.contact-grid {
  position: relative;
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 100px;
  align-items: start;
}

.contact-copy h2 {
  font-size: clamp(3rem, 5vw, 5rem);
}

.contact-copy h2 em {
  color: var(--lime);
}

.contact-copy > p {
  max-width: 490px;
  margin: 28px 0 0;
  color: rgba(255,255,255,0.68);
  font-size: 17px;
  line-height: 1.7;
}

.contact-note {
  display: flex;
  gap: 13px;
  margin-top: 45px;
  color: white;
}

.contact-note > span {
  color: var(--lime);
  font-size: 25px;
}

.contact-note p {
  display: flex;
  flex-direction: column;
  margin: 0;
  font-size: 13px;
}

.contact-note a {
  width: fit-content;
  margin-top: 4px;
  color: var(--lime);
  border-bottom: 1px solid rgba(199,255,94,0.5);
}

/* Formulário sem backend: o JavaScript prepara um email através de mailto. */
.contact-form {
  display: grid;
  gap: 22px;
  padding: 42px;
  color: var(--ink);
  background: var(--paper);
  border-radius: var(--radius);
  box-shadow: 18px 18px 0 var(--ink);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.contact-form label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 13px 0;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-bottom: 1px solid #b8b5af;
  border-radius: 0;
  outline: 0;
  font-size: 15px;
  text-transform: none;
  transition: border-color 0.2s ease;
}

.contact-form textarea {
  resize: vertical;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  border-color: var(--blue);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: #a29f99;
}

.button-coral {
  justify-self: start;
  color: var(--ink);
  background: var(--coral);
  box-shadow: 6px 6px 0 var(--ink);
}

.button-coral:hover {
  box-shadow: 3px 3px 0 var(--ink);
}

.form-status {
  margin: -4px 0 0;
  color: #77736d;
  font-size: 10px;
}

/* ============================================================
   7. Rodapé, animações e responsividade
   ============================================================ */
.site-footer {
  padding: 54px 0;
  color: rgba(255,255,255,0.72);
  background: var(--ink);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: end;
  gap: 70px;
}

.brand-footer {
  color: white;
}

.footer-grid > div:first-child p {
  margin: 13px 0 0;
  color: rgba(255,255,255,0.42);
  font-size: 12px;
}

.footer-links {
  display: flex;
  gap: 22px;
  font-size: 12px;
}

.footer-links a:hover {
  color: var(--lime);
}

.footer-meta {
  display: flex;
  flex-direction: column;
  color: rgba(255,255,255,0.35);
  font-size: 10px;
  text-align: right;
}

/* Estado inicial e estado visível dos elementos observados pelo IntersectionObserver. */
.reveal {
  opacity: 0;
  transform: translateY(25px);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(.2,.7,.2,1);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.18s; }
.delay-3 { transition-delay: 0.26s; }

/* Tablet largo: reduz a escala do mockup e aproxima as colunas. */
@media (max-width: 1100px) {
  .hero-grid {
    grid-template-columns: 0.9fr 1.1fr;
    gap: 35px;
  }

  .hero-product {
    transform: scale(0.9) perspective(1600px) rotateY(-3deg);
    transform-origin: left center;
  }

  .support-float { left: -10px; }
  .certification-float { right: -10px; }
  .clinic-copy { padding: 52px 38px; }
  .patient-card { width: 310px; }
  .metric-card { right: 10px; }
  .mini-calendar { left: 10px; }
  .contact-grid { gap: 60px; }
}

/* Tablet: passa as áreas principais para uma coluna e reorganiza os produtos. */
@media (max-width: 920px) {
  :root { --shell: min(100% - 40px, 760px); }

  .main-nav { gap: 20px; }
  .hero { padding-top: 130px; }
  .hero-grid { grid-template-columns: 1fr; gap: 70px; }
  .hero-copy { max-width: 680px; }
  .hero-product { width: 690px; max-width: 100%; margin: 0 auto; transform: none; }

  .section-intro,
  .solutions-heading,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 35px;
  }

  .section-intro p,
  .solutions-heading p { max-width: 580px; }

  .service-copy { grid-template-columns: 1fr; gap: 12px; }
  .tag-list { grid-column: 1; }

  .clinic-feature { grid-template-columns: 1fr; }
  .clinic-copy { padding: 55px; }
  .clinic-visual { min-height: 520px; }
  .product-grid { grid-template-columns: 1fr 1fr; }
  .product-card:last-child { grid-column: 1 / -1; }
  .product-card:last-child .people-art { height: 300px; }

  .method-grid { grid-template-columns: 1fr 1fr; gap: 55px 0; }
  .contact-copy { max-width: 700px; }
  .contact-form { max-width: 700px; }
  .footer-grid { grid-template-columns: 1fr auto; }
  .footer-meta { grid-column: 1 / -1; flex-direction: row; justify-content: space-between; text-align: left; }
}

/* Mobile: transforma a navegação num menu de ecrã inteiro e simplifica os mockups. */
@media (max-width: 720px) {
  :root { --shell: calc(100vw - 32px); }
  html { scroll-padding-top: 70px; }

  .nav-shell { min-height: 70px; }
  .menu-toggle { display: block; position: relative; z-index: 2; }
  .main-nav {
    position: fixed;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 25px;
    padding: 90px 32px 40px;
    color: white;
    background: var(--ink);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-15px);
    transition: opacity 0.22s ease, visibility 0.22s ease, transform 0.22s ease;
  }

  .main-nav.is-open { opacity: 1; visibility: visible; transform: translateY(0); }
  .main-nav > a { font-size: 28px; letter-spacing: -0.04em; }
  .main-nav .nav-cta { margin-top: 10px; font-size: 17px; }
  .menu-toggle[aria-expanded="true"] { color: white; }
  .menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
  .menu-toggle[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

  .hero { min-height: auto; padding: 120px 0 86px; }
  .hero h1 { font-size: clamp(3rem, 14vw, 4.5rem); }
  .hero-lead { font-size: 16px; }
  .hero-actions { align-items: flex-start; flex-direction: column; gap: 16px; }
  .trust-list { display: grid; gap: 11px; }
  .hero-product { width: 620px; max-width: 115%; margin-left: -5%; }
  .product-window { border-radius: 11px; }
  .app-frame { height: 355px; grid-template-columns: 42px 1fr; }
  .app-main { padding: 18px 14px; }
  .app-kpis { gap: 6px; }
  .app-kpi { min-height: 87px; padding: 10px; }
  .app-kpi strong { font-size: 16px; }
  .app-bottom { gap: 6px; }
  .chart-card, .agenda-card { height: 148px; padding: 11px; }
  .bars { height: 95px; gap: 5px; }
  .support-float { display: none; }
  .certification-float { right: -2px; bottom: 17px; }

  .marquee-content { min-height: 66px; width: max-content; padding: 0 20px; }
  .section { padding: 90px 0; }
  .section-intro h2 { font-size: clamp(2.7rem, 12vw, 4rem); }
  .section-intro { gap: 26px; }
  .service-list { margin-top: 55px; }
  .service-row { grid-template-columns: 35px 62px 1fr; gap: 16px; padding: 35px 0; }
  .service-symbol { width: 58px; height: 58px; font-size: 22px; }
  .service-copy { grid-column: 2 / -1; padding-left: 0; }
  .service-index { grid-row: 1 / span 2; }
  .service-copy h3 { font-size: 25px; }

  .solutions-heading { margin-bottom: 50px; }
  .solutions-heading h2 { font-size: clamp(3rem, 14vw, 5rem); }
  .clinic-copy { padding: 40px 25px; }
  .clinic-copy h3 { font-size: 2.7rem; }
  .feature-checks { grid-template-columns: 1fr; }
  .clinic-visual { min-height: 440px; }
  .patient-card { width: 285px; }
  .metric-card { width: 154px; top: 26px; padding: 15px; }
  .metric-card strong { font-size: 35px; }
  .mini-calendar { width: 210px; bottom: 30px; }
  .product-grid { grid-template-columns: 1fr; }
  .product-card:last-child { grid-column: auto; }
  .product-card:last-child .people-art { height: 260px; }
  .product-card-copy { min-height: 0; }
  .product-card-copy > p { min-height: 0; }

  .method-grid { grid-template-columns: 1fr; gap: 45px; margin-top: 65px; }
  .method-step { padding-right: 0; }
  .contact-section { padding: 90px 0; }
  .contact-copy h2 { font-size: clamp(3rem, 14vw, 4.5rem); }
  .contact-form { padding: 28px 20px; box-shadow: 8px 8px 0 var(--ink); }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 35px; }
  .footer-links { flex-wrap: wrap; }
  .footer-meta { grid-column: auto; flex-direction: column; gap: 5px; }
}

/* Ecrãs muito estreitos: reduz detalhes secundários para preservar legibilidade. */
@media (max-width: 430px) {
  .brand { font-size: 19px; }
  .hero-product { max-width: 126%; margin-left: -13%; }
  .app-heading h2 { font-size: 14px; }
  .app-kpi:nth-child(2) { display: none; }
  .app-kpis { grid-template-columns: 1fr 1fr; }
  .agenda-card { display: none; }
  .app-bottom { grid-template-columns: 1fr; }
  .certification-float { right: 14px; }
  .service-row { grid-template-columns: 30px 1fr; }
  .service-symbol { grid-column: 2; }
  .service-copy { grid-column: 2; }
  .clinic-visual { min-height: 395px; }
  .patient-card { width: 255px; padding: 18px; }
  .metric-card { right: -6px; }
  .mini-calendar { left: -15px; }
}

/* Utilizadores que pedem menos movimento não recebem transições prolongadas. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
}
