/* =========================================
   UNIO COMBAT — style.css (Mobile Fixed)
   ========================================= */

/* ----- Variáveis Globais ----- */
:root {
  --black: #000000;
  --white: #ffffff;
  --blue: #00bdff;
  --gray-dark: #0a0a0a;
  --muted: rgba(255,255,255,0.7);
  --glass: rgba(255,255,255,0.04);
  --radius: 12px;
  --transition: 0.3s ease;
  --font-family: "Montserrat", sans-serif;
  font-family: var(--font-family);
  color: var(--white);
  background: var(--black);
}

/* ----- Reset / Base ----- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  overflow-x: hidden;
  min-height: 100%;
}

body {
  background: linear-gradient(270deg, #000000, #00111a, #002233, #000000);
  background-size: 800% 800%;
  animation: gradientFlow 18s ease infinite;
  color: var(--white);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

@keyframes gradientFlow {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition);
}

img {
  max-width: 100%;
  display: block;
}

.muted { color: var(--muted); }

.site-footer .muted {
  color: rgba(255,255,255,0.6);
  font-size: 14px;
}

/* ----- Containers ----- */
.container {
  width: min(1200px, 92%);
  margin: 0 auto;
}

/* =========================================
   HEADER
   ========================================= */
.site-header {
  background: linear-gradient(90deg, rgba(0,0,0,0.85), rgba(0,189,255,0.05));
  backdrop-filter: blur(12px);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  height: 72px; /* Altura fixa para consistência */
}
.brand { display: flex; align-items: center; gap: 10px; }
.logo { height: 40px; }
.brand-text {
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--blue);
}
.main-nav { display: flex; align-items: center; gap: 24px; }
.main-nav a {
  font-weight: 600;
  color: var(--muted);
  transition: color var(--transition);
}
.main-nav a:hover,
.main-nav a.active { color: var(--white); }
.cta-menu {
  background: var(--blue);
  color: var(--black);
  padding: 8px 14px;
  border-radius: 8px;
  font-weight: 700;
}
.header-actions { display: flex; align-items: center; gap: 10px; }

.btn {
  cursor: pointer;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 8px;
  border: none;
  transition: all var(--transition);
  display: inline-block;
  text-align: center;
}
.btn.transparent {
  background: transparent;
  border: 1px solid var(--blue);
  color: var(--blue);
}
.btn.transparent:hover {
  background: var(--blue);
  color: var(--black);
}
.btn.primary {
  background: var(--blue);
  color: var(--black);
}
.btn.primary:hover { background: #09d2ff; }
.btn.outline {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.3);
    color: var(--white);
}
.btn.outline:hover {
    border-color: var(--white);
}

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  background: none;
  border: none;
  margin-left: auto;
  z-index: 200;
  width: 30px;
  height: 30px;
}
.menu-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--white);
  border-radius: 4px;
  transition: all 0.3s ease;
}
/* Animação do X */
.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 6px);
}
.menu-toggle.active span:nth-child(2) { opacity: 0; }
.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* =========================================
   HERO
   ========================================= */
.hero {
  position: relative;
  padding-top: 120px; /* Mais espaço para o header */
  padding-bottom: 60px;
  min-height: 80vh;
  overflow: hidden;
  background: radial-gradient(800px 400px at 10% 20%, rgba(0,189,255,0.08), transparent 25%);
}
.hero-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,189,255,0.02), rgba(0,0,0,0.6));
  pointer-events: none;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 480px;
  gap: 40px;
  align-items: center;
}
.eyebrow {
  font-weight: 700;
  color: var(--blue);
  margin-bottom: 12px;
  display: inline-block;
}
h1 { font-size: 46px; margin-bottom: 16px; line-height: 1.1; }
.lead { color: var(--muted); font-weight: 300; font-size: 1.125rem; }

.hero-ctas { display: flex; gap: 12px; margin-top: 24px; flex-wrap: wrap; }
.pilares {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}
.pill {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,0.06);
  font-weight: 600;
  font-size: 13px;
}
.hero-right .hero-img {
  max-width: 300px;
  width: 100%;
  margin: 0 auto;
  height: auto;
  object-fit: contain;
}
.card-foot {
    margin-top: 20px;
    text-align: center;
}
.card-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

/* =========================================
   CARDS & UTILITIES
   ========================================= */
.card {
  background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.02));
  padding: 24px;
  border-radius: 14px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.6);
  transition: transform 0.28s ease, box-shadow 0.28s ease;
  border: 1px solid rgba(255,255,255,0.05);
}
.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 40px 100px rgba(0,0,0,0.8);
}
.section { padding: 88px 0; }

/* ==== Secção “O que é” melhorada ==== */

.split.improved {
  display: flex;
  align-items: center;
  gap: 60px;
}
.split-left { flex: 1; }
.split-right { flex: 1; }

.split.improved .split-left h2 {
  font-size: 2.5rem;
  margin-bottom: 16px;
  line-height: 1.2;
}

.split.improved .split-left p {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--muted);
  margin-bottom: 30px;
}

.benefits {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 32px;
}

.benefit {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255,255,255,0.04);
  border-radius: 10px;
  padding: 12px 18px;
  transition: background 0.3s ease, transform 0.3s ease;
  width: fit-content;
}

.benefit:hover {
  background: rgba(255,255,255,0.08);
  transform: translateY(-3px);
}

.benefit img {
  height: 24px;
  width: 24px;
  filter: brightness(0) invert(1);
}

.split-right.visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.mockup-frame {
  position: relative;
  width: 280px;
  height: auto;
}

.mockup-frame .mockup {
  width: 100%;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.6);
}

.mockup-glow {
  position: absolute;
  inset: 0;
  border-radius: 20px;
  background: radial-gradient(circle at 50% 90%, var(--blue) 0%, transparent 60%);
  opacity: 0.3;
  pointer-events: none;
}

/* =========================================
   CAMPAIGNS (Grelha)
   ========================================= */
.campaigns-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    margin-top: 40px;
}
.campaign h3 { margin-bottom: 10px; font-size: 1.25rem; }
.campaign p { color: var(--muted); margin-bottom: 20px; font-size: 0.95rem;}
.campaign-actions { margin-top: auto; }

/* =========================================
   PARTNERS
   ========================================= */
.partners-container {
  overflow: hidden;
  width: 100%;
  margin-top: 20px;
}
.partners-track {
  display: flex;
  gap: 24px;
  width: max-content;
  animation: scrollPartners 38s linear infinite;
}
@keyframes scrollPartners {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.partner { flex: 0 0 auto; }
.partner img {
  height: 42px;
  filter: grayscale(1);
  transition: filter var(--transition);
}
.partner img:hover {
  filter: grayscale(0) drop-shadow(0 0 6px var(--blue));
}

/* ===== FORMULÁRIO PARCEIROS ===== */
.partner-form {
  margin-top: 24px;
  display: flex;
  justify-content: center;
  padding: 0;
  width: 100%;
}
.partner-form iframe {
  width: 100%;
  max-width: 1000px;
  height: 1800px; /* Default height */
  border: none;
  border-radius: 10px;
  box-shadow: 0 18px 60px rgba(0,0,0,0.6);
  background: rgba(255,255,255,0.02);
}

/* =========================================
   PLANOS / PRICING PAGE
   ========================================= */
.planos-page .pricing {
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 60px;
}
.planos-page .pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  width: 100%;
}
.planos-page .plan.card {
  text-align: center;
  padding: 36px 24px;
  border: 1px solid rgba(255,255,255,0.06);
  transition: all 0.3s ease;
}
.planos-page .plan.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
}
.planos-page .plan h3 {
  font-size: 22px;
  margin-bottom: 8px;
  color: var(--blue);
}
.planos-page .price {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 16px;
}
.planos-page .plan ul {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
}
.planos-page .plan ul li {
  margin: 8px 0;
  color: var(--muted);
}
.planos-page .compare.card {
  width: 100%;
  padding: 32px;
  border: 1px solid rgba(255,255,255,0.05);
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.015));
  border-radius: 14px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.5);
  overflow-x: auto;
}
.planos-page .compare h4 {
  font-size: 20px;
  margin-bottom: 18px;
  color: var(--blue);
  text-align: center;
}
.planos-page .compare table {
  width: 100%;
  border-collapse: collapse;
  text-align: center;
  font-size: 15px;
  min-width: 600px; /* Garante scroll se necessário */
}
.planos-page .compare thead {
  background: rgba(255,255,255,0.05);
  font-weight: 700;
}
.planos-page .compare th, .planos-page .compare td {
  padding: 12px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.planos-page .compare tbody tr:hover {
  background: rgba(255,255,255,0.03);
}
.planos-page .compare td:first-child {
  text-align: left;
  font-weight: 600;
  color: var(--muted);
}

/* =========================================
   FOOTER
   ========================================= */
.site-footer {
  border-top: 1px solid rgba(255,255,255,0.05);
  padding: 36px 0;
  background: linear-gradient(90deg, var(--black), rgba(0,189,255,0.04));
  margin-top: auto;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}
.footer-left {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
/* MANTÉM LOGO PEQUENO - CRÍTICO */
.logo-small {
  height: 34px;
  width: auto;
  opacity: 0.95;
}
.footer-right {
  display: flex;
  align-items: center;
  gap: 18px;
}
.social-icon img {
  height: 22px;
  width: 22px;
  opacity: 0.8;
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.social-icon img:hover {
  opacity: 1;
  transform: translateY(-2px);
}

/* =========================================
   MOBILE / RESPONSIVE (A PARTE CRÍTICA)
   ========================================= */
@media (max-width: 992px) {
  
  /* 1. Header & Menu */
  .menu-toggle { display: flex; }
  .header-actions { display: none; } /* Botões desktop escondidos */
  
  .main-nav {
    position: fixed;
    top: 72px; /* Logo abaixo do header */
    left: 0;
    right: 0;
    bottom: 0; /* Ocupa até ao fundo */
    height: calc(100vh - 72px);
    background: #000000; /* Fundo sólido, não transparente */
    flex-direction: column;
    align-items: center;
    justify-content: flex-start; /* Itens começam no topo */
    gap: 30px;
    padding: 40px 20px;
    display: none;
    z-index: 150;
    overflow-y: auto; /* Permite scroll se menu for longo */
  }
  
  .main-nav.open { 
    display: flex; 
    animation: fadeIn 0.3s ease;
  }
  
  .main-nav a {
    font-size: 1.5rem; /* Letra maior para toque */
    width: 100%;
    text-align: center;
    padding: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
  }
  
  .main-nav .cta-menu {
      background: transparent;
      color: var(--blue);
      border: 1px solid var(--blue);
  }

  @keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
  }

  /* 2. Hero Section Mobile */
  .hero { padding-top: 100px; padding-bottom: 40px; }
  
  .hero-inner {
    grid-template-columns: 1fr; /* Coluna única */
    text-align: center;
    gap: 30px;
  }
  
  .hero-left {
    order: 1; /* Texto primeiro */
  }
  
  .hero-right {
    order: 2; /* Imagem depois */
    margin: 0 auto;
    width: 100%;
    max-width: 350px;
  }

  .hero-ctas { justify-content: center; width: 100%; }
  .pilares { justify-content: center; }
  
  h1 { font-size: 2.5rem; } /* Título ajustado para ecrã pequeno */

  /* 3. Sections & Splits */
  .section { padding: 60px 0; }
  
  .split.improved {
    flex-direction: column; /* Empilha verticalmente */
    gap: 40px;
  }
  
  .split-left, .split-right { width: 100%; }
  
  .benefits { justify-content: center; }

  /* 4. Planos */
  .planos-page .pricing-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  /* 5. Footer Mobile */
  .footer-inner {
    flex-direction: column;
    justify-content: center;
    text-align: center;
    gap: 20px;
  }
  .footer-left { align-items: center; }
  .logo-small { height: 34px; /* Garante tamanho no mobile */ }
  .footer-right { gap: 22px; margin-top: 10px; }
  .social-icon img { height: 26px; width: 26px; } /* Ícones ligeiramente maiores para toque */

  /* Estilização para os Widgets GoFundMe */
.campaign-card-wrapper {
    background: #ffffff; /* Fundo branco conforme a imagem */
    border-radius: 14px;
    overflow: hidden;
    padding: 10px;
    transition: transform var(--transition);
    display: flex;
    justify-content: center;
}

.campaign-card-wrapper:hover {
    transform: translateY(-8px);
}

/* Garante que o widget ocupe a largura total do container */
.gfm-embed {
    width: 100% !important;
    margin: 0 !important;
}

/* Ajuste na grid para comportar os widgets largos */
@media (min-width: 992px) {
    .campaigns-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}