/* --- PRODEX DESIGN SYSTEM: PREMIUM DARK MODE --- */

:root {
  --bg-dark: #0f0f0f;
  --bg-darker: #121212;
  --bg-card: #181818;
  --text-light: #c2c1c1;
  --text-white: #dcdcdc;
  --heading-color: #dcdcdc;
  --accent-color: #ed1f24;
  --accent-hover: #c9191e;
}

body {
  font-family: "Nunito", sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-light);
  -webkit-font-smoothing: antialiased;
  font-size: 1.05rem;
}

/* --- Utilitários e Tipografia --- */

/* 1. Define a cor do logótipo para todos os títulos por defeito */
h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--heading-color);
}

/* 2. Força a cor do logótipo mesmo onde o Bootstrap tenta impor o branco puro,
      garantindo que o H5 vermelho (O Multiplicador) não é afetado */
h1.text-white,
h2.text-white,
h3.text-white,
h4.text-white,
h5.text-white,
h6.text-white {
  color: var(--heading-color) !important;
}

.text-accent {
  color: var(--accent-color) !important;
}

.text-custom-white {
  color: #dcdcdc !important;
}


.section-darker {
  background-color: var(--bg-darker);
}

.max-w-custom {
  max-width: 800px;
}

/* Força a cor dos textos para melhor leitura/contraste conforme pedido */
p,
.text-muted,
.text-light {
  color: #c2c1c1 !important;
}

/* Classes antes "órfãs", agora definidas */
.accent-line {
  width: 60px;
  height: 3px;
  background-color: var(--accent-color);
  border-radius: 2px;
}

.letter-spacing {
  letter-spacing: 1.5px;
}

/* Navbar (Menu Topo) */
.navbar {
  background-color: rgba(15, 15, 15, 0.98);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  padding: 15px 0;
  transition: all 0.3s ease;
}


/* --- ESTILOS DO LOGOTIPO --- */
.logo-prodex {
  height: 75px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  transition: height 0.3s ease;
}

@media (max-width: 768px) {
  .logo-prodex {
    height: 50px;
  }
}

/* Botões Customizados */
.btn-primary-custom {
  background-color: var(--accent-color);
  color: #fff;
  font-weight: 600;
  padding: 12px 28px;
  border-radius: 5px;
  border: none;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
}

.btn-primary-custom:hover {
  background-color: var(--accent-hover);
  color: #fff;
  transform: translateY(-2px);
}

/* Hero Section */
.hero-section {
  background:
    linear-gradient(rgba(18, 18, 18, 0.8), rgba(18, 18, 18, 0.9)),
    url("images/fundo-topo.webp") center/cover no-repeat;

  /* Espaçamento superior e inferior mais compactos */
  padding-top: 210px;
  padding-bottom: 70px;
}

@media (max-width: 768px) {
  .hero-section {
    background-image:
      linear-gradient(rgba(18, 18, 18, 0.8), rgba(18, 18, 18, 0.9)),
      url("images/fundo-topo-mobile.webp");
  }
}

.hero-section h1,
.hero-section p {
  text-shadow: 0px 4px 15px rgba(0, 0, 0, 0.9);
}

/* Cards de Serviços */
.service-card {
  background-color: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition:
    transform 0.3s ease,
    border-color 0.3s ease;
}

.service-card:hover {
  transform: translateY(-10px);
  border-color: var(--accent-color);
}

.z-index-1 {
  position: relative;
  z-index: 1;
}

/* Formulário de Contacto */
#contacto,
footer {
  background-color: #121212 !important;
}

.contact-form .form-control {
  border-radius: 5px;
  padding: 15px;
  transition: all 0.3s ease;
  background-color: #121212 !important;
  color: #c2c1c1 !important;
  border-color: #3d4349;
}

.contact-form .form-control:focus {
  border-color: var(--accent-color);
  box-shadow: 0 0 0 0.25rem rgba(237, 31, 36, 0.25);
  background-color: var(--bg-dark);
  color: var(--text-white);
}

.contact-form .form-control::placeholder {
  color: #999999 !important;
  opacity: 1 !important;
}

/* --- AFINAÇÕES FLUIDAS E AJUSTES DE TAMANHO GLOBAIS --- */


/* NOVO: H1 e H5 do Hero encolhem juntos em mobile, 
   mas nunca ultrapassam o tamanho ideal de 1.25rem em desktop */
.hero-section h1,
.hero-section h5 {
  /* Varia entre 1rem (aprox. 16px em mobile) e 1.25rem (aprox. 20px em desktop) */
  font-size: clamp(1rem, 3vw, 1.25rem) !important;
}

.hero-section h1 {
  line-height: 1.5;
  font-weight: 700;
  letter-spacing: normal;
}

h2.display-5,
section h2 {
  font-size: clamp(1.3rem, 3vw, 1.8rem) !important;
}

/* Banner de Cookies */
.cookie-banner {
  position: fixed;
  bottom: -200px;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgba(20, 20, 20, 0.95);
  color: white;
  padding: 15px 30px;
  border-radius: 50px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  gap: 20px;
  z-index: 9999;
  transition: bottom 0.4s ease-in-out;
  border: 1px solid #333;
  width: 90%;
  max-width: 800px;
}

.cookie-banner.show {
  bottom: 20px;
}

@media (max-width: 768px) {
  .cookie-banner {
    flex-direction: column;
    text-align: center;
    border-radius: 15px;
    padding: 20px;
  }
}

.cookie-banner span {
  font-size: 0.9rem;
  color: #cccccc;
}

section h2 {
  color: var(--heading-color) !important;
}

/* --- Utilitários de Resolução de Problemas (Substituição de Inline Styles) --- */
.max-w-650 {
  max-width: 650px;
}

.max-w-700 {
  max-width: 700px;
}

.text-lg {
  font-size: 1.15rem;
}

.border-accent {
  border-color: var(--accent-color) !important;
}

.modal-header {
  background-color: rgba(18, 18, 18, 0.98);
  padding-top: max(1rem, env(safe-area-inset-top)) !important;
}

.virtual-tour-iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}