/* 
 * Igreja Quadrangular Portugal - Estilos Principais
 * Versão: 2.0 - Responsivo Otimizado
 */

:root {
  --color-primary: #d9b311;
  --color-primary-dark: #c19e00;
  --color-secondary: #29252a;
  --color-text: #222029;
  --color-text-light: #555;
  --color-background: #f9f7f2;
  --color-background-alt: #f8f8f8;
  --color-border: #eee2c6;
  --color-white: #fff;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 3px 12px rgba(0, 0, 0, 0.1);
  --font-family: 'Montserrat', 'Segoe UI', Arial, sans-serif;
  --border-radius: 10px;
  --transition-speed: 0.3s;
  --container-width: 1300px;
  
  /* Espaçamentos responsivos */
  --spacing-xs: clamp(0.25rem, 1vw, 0.5rem);
  --spacing-sm: clamp(0.5rem, 2vw, 1rem);
  --spacing-md: clamp(1rem, 3vw, 2rem);
  --spacing-lg: clamp(2rem, 5vw, 4rem);
  --spacing-xl: clamp(3rem, 7vw, 6rem);
  
  /* Tipografia fluida */
  --font-size-sm: clamp(0.875rem, 1.5vw, 1rem);
  --font-size-base: clamp(1rem, 2vw, 1.125rem);
  --font-size-lg: clamp(1.125rem, 2.5vw, 1.25rem);
  --font-size-xl: clamp(1.5rem, 4vw, 2rem);
  --font-size-2xl: clamp(2rem, 5vw, 3rem);
}

/* Reset e estilos base */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px; /* Altura do header fixo */
}

/* Desabilitar smooth scroll para usuários com preferência de movimento reduzido */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  font-family: var(--font-family);
  background: var(--color-background);
  color: var(--color-text);
  line-height: 1.6;
  font-size: var(--font-size-base);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  width: 100%;
  position: relative;
  min-height: 100vh;
}

/* Prevenir scroll horizontal */
html, body {
  max-width: 100%;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
}

/* Container principal */
.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 1rem;
  width: 100%;
}

@media (min-width: 480px) {
  .container {
    padding: 1.5rem;
  }
}

@media (min-width: 768px) {
  .container {
    padding: 2rem 1.5rem;
  }
}

@media (min-width: 1024px) {
  .container {
    padding: 3rem 2rem;
  }
}

/* ---- HEADER & MENU ---- */
.header-main {
  background: var(--color-background-alt);
  border-bottom: 2px solid var(--color-border);
  padding: 0;
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 100;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  will-change: transform;
}

.header-main.scrolled {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.logo-nav {
  max-width: var(--container-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(12px, 3vw, 24px);
  gap: clamp(12px, 3vw, 24px);
  position: relative;
  min-height: clamp(60px, 10vw, 80px);
}

.logo {
  display: flex;
  align-items: center;
  gap: clamp(8px, 2vw, 14px);
  flex: 1;
  min-width: 0;
}

.logo img {
  height: clamp(48px, 8vw, 72px);
  width: clamp(48px, 8vw, 72px);
  object-fit: contain;
  border-radius: var(--border-radius);
  background: var(--color-white);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.logo img:hover {
  transform: scale(1.05);
}

.logo-title {
  color: var(--color-secondary);
  font-size: clamp(0.875rem, 2.5vw, 1.25rem);
  letter-spacing: clamp(0.5px, 0.15vw, 1.3px);
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 480px) {
  .logo-title {
    white-space: normal;
    word-break: break-word;
  }
}

nav {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  position: relative;
}

.menu-list {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 28px;
  margin: 0;
  padding: 0;
  font-size: 1.08rem;
  font-weight: 600;
  transition: all var(--transition-speed);
}

.menu-list li { 
  white-space: nowrap; 
}

.menu-list a {
  text-decoration: none;
  color: var(--color-secondary);
  padding: 8px 0 2px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-bottom 0.15s;
}

.menu-list a:hover,
.menu-list a.active {
  color: var(--color-primary);
  border-bottom: 2px solid var(--color-primary);
}

.menu-list a.menu-painel {
  color: var(--color-primary) !important;
  font-weight: 700;
}

/* Botão do menu mobile */
.menu-mobile {
  display: none;
  background: none;
  border: none;
  font-size: 2.2rem;
  color: var(--color-secondary);
  cursor: pointer;
  margin-left: 15px;
  transition: color 0.2s;
}

.menu-mobile:hover {
  color: var(--color-primary);
}

/* Seção Wave */
.wave-section {
      position: relative;
      width: 100%;
      height: 600px;
      display: flex;
      align-items: center;
      justify-content: center;
      overflow: hidden;
      color: rgb(255, 255, 255);

}

 section video {
  position: absolute;
  object-fit: cover;
  width: 100%;
  height: 100%;
  filter: brightness(0.7);
}


.video-overlay1 {
  position: absolute;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.3);
}

.text-container {
  display: flex;
  position: absolute;
  text-align: center;
  z-index: 2;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 32px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.wave-title {
  font-size: var(--font-size-2xl);
  max-width: min(800px, 90vw);
  padding: 32px 64px 0 64px;
  word-wrap: break-word;
}

.wave-subtitle {
  max-width: min(800px, 90vw);
  font-size: clamp(1rem, 2.5vw, 1.1rem);
  padding: 0 64px 32px 64px;
}

.wave-bottom {
  position: absolute;
  width: 100%;
  height: clamp(40px, 8vw, 60px);
  margin-bottom: -5px;
  align-self: flex-end;
}

.wave-bottom svg {
  width: 100%;
  height: 100%;
  display: block;
}

/* Seção de Comunidades */
.section-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  text-align: center;
  margin-bottom: clamp(0.5rem, 2vw, 1rem);
  color: var(--color-secondary);
  padding: 0 var(--spacing-sm);
}

.section-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.1rem);
  text-align: center;
  margin-bottom: clamp(1.5rem, 4vw, 2rem);
  color: var(--color-text-light);
  padding: 0 var(--spacing-sm);
}

/* Filtro de Igrejas */
.church-filter-container {
  max-width: 800px;
  margin: 0 auto 3rem;
  padding: 0 1rem;
}

.church-filter-wrapper {
  position: relative;
}

.church-filter-input-group {
  position: relative;
  display: flex;
  align-items: center;
  background: var(--color-white);
  border-radius: 50px;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.church-filter-input-group:focus-within {
  border-color: var(--color-primary);
  box-shadow: 0 5px 20px rgba(217, 179, 17, 0.2);
}

.church-filter-icon {
  position: absolute;
  left: 20px;
  color: var(--color-text-light);
  font-size: 1.1rem;
  z-index: 2;
}

.church-filter-input {
  flex: 1;
  padding: 1rem 3rem 1rem 3.5rem;
  border: none;
  background: transparent;
  font-size: 1rem;
  font-family: var(--font-family);
  color: var(--color-text);
  outline: none;
  border-radius: 50px;
  transition: all 0.3s ease;
}

.church-filter-input::placeholder {
  color: var(--color-text-light);
  opacity: 0.7;
}

.church-filter-input:focus {
  background: transparent;
}

.church-filter-clear {
  position: absolute;
  right: 15px;
  background: var(--color-primary);
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--color-secondary);
  font-size: 0.9rem;
  transition: all 0.2s ease;
  z-index: 2;
}

.church-filter-clear:hover {
  background: var(--color-primary-dark);
  transform: scale(1.1);
}

.church-filter-results {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--color-white);
  border-radius: 15px;
  box-shadow: var(--shadow-md);
  margin-top: 0.5rem;
  padding: 0.75rem 1rem;
  font-size: 0.9rem;
  color: var(--color-text-light);
  display: none;
  z-index: 10;
}

.church-filter-results.show {
  display: block;
}

/* Filtro Premium de Igrejas */
.church-filter-premium {
  max-width: min(1000px, 100%);
  margin: 0 auto 2rem;
  padding: 1rem;
  background: linear-gradient(135deg, var(--color-white) 0%, #f8f9fa 100%);
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

@media (min-width: 768px) {
  .church-filter-premium {
    padding: 1.5rem;
    margin-bottom: 3rem;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
  }
}

@media (min-width: 1024px) {
  .church-filter-premium {
    padding: 2rem;
  }
}

.filter-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: clamp(1rem, 3vw, 2rem);
  padding-bottom: clamp(0.75rem, 2vw, 1rem);
  border-bottom: 2px solid var(--color-border);
  flex-wrap: wrap;
  gap: 1rem;
}

.filter-title {
  font-size: clamp(1.125rem, 3vw, 1.5rem);
  color: var(--color-secondary);
  display: flex;
  align-items: center;
  gap: clamp(0.5rem, 1.5vw, 0.75rem);
  margin: 0;
}

.filter-title i {
  color: var(--color-primary);
  font-size: clamp(1.125rem, 2.5vw, 1.3rem);
}

.filter-stats {
  font-size: clamp(0.8rem, 2vw, 0.9rem);
  color: var(--color-text-light);
  background: var(--color-background);
  padding: clamp(0.375rem, 1vw, 0.5rem) clamp(0.75rem, 2vw, 1rem);
  border-radius: 20px;
  font-weight: 500;
  white-space: nowrap;
}

.filter-controls {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1rem, 2vw, 1.5rem);
  align-items: start;
}

@media (min-width: 768px) {
  .filter-controls {
    grid-template-columns: 1fr auto;
  }
}

.search-group {
  position: relative;
}

.search-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 1rem;
  color: var(--color-text-light);
  font-size: 1rem;
  z-index: 2;
  transition: color 0.3s ease;
}

@media (min-width: 768px) {
  .search-icon {
    left: 1.25rem;
    font-size: 1.1rem;
  }
}

.search-input {
  width: 100%;
  padding: 0.75rem 3rem 0.75rem 3rem;
  border: 2px solid var(--color-border);
  border-radius: 50px;
  font-size: 0.9rem;
  font-family: var(--font-family);
  color: var(--color-text);
  background: var(--color-white);
  transition: all 0.3s ease;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

@media (min-width: 768px) {
  .search-input {
    padding: 1rem 3rem 1rem 3.5rem;
    font-size: 1rem;
  }
}

.search-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(217, 179, 17, 0.1);
  transform: translateY(-1px);
}

.search-input:focus + .search-icon {
  color: var(--color-primary);
}

.search-input::placeholder {
  color: var(--color-text-light);
  opacity: 0.7;
}

.clear-btn {
  position: absolute;
  right: 0.75rem;
  background: var(--color-primary);
  border: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--color-secondary);
  font-size: 0.85rem;
  transition: all 0.2s ease;
  z-index: 2;
}

@media (min-width: 768px) {
  .clear-btn {
    right: 1rem;
    width: 32px;
    height: 32px;
    font-size: 0.9rem;
  }
}

.clear-btn:hover {
  background: var(--color-primary-dark);
  transform: scale(1.1);
}

.filter-options {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.75rem;
  justify-content: flex-start;
}

@media (min-width: 768px) {
  .filter-options {
    gap: 0.75rem;
    margin-top: 1rem;
  }
}

.filter-btn {
  background: var(--color-white);
  border: 2px solid var(--color-border);
  padding: 0.5rem 0.875rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--color-text);
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.375rem;
  white-space: nowrap;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  min-height: 36px;
}

@media (min-width: 768px) {
  .filter-btn {
    padding: 0.625rem 1rem;
    font-size: 0.9rem;
    border-radius: 25px;
    gap: 0.5rem;
    min-height: 40px;
  }
}

.filter-btn:hover {
  border-color: var(--color-primary);
  background: rgba(217, 179, 17, 0.05);
  transform: translateY(-1px);
}

.filter-btn:active {
  transform: translateY(0);
}

.filter-btn.active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-secondary);
  font-weight: 600;
}

.filter-btn i {
  font-size: clamp(0.7rem, 1.5vw, 0.8rem);
}

.sort-group {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.sort-select {
  padding: 0.625rem 0.75rem;
  border: 2px solid var(--color-border);
  border-radius: 8px;
  background: var(--color-white);
  color: var(--color-text);
  font-size: 0.85rem;
  font-family: var(--font-family);
  cursor: pointer;
  transition: all 0.3s ease;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 0.5rem center;
  background-size: 1em;
  padding-right: 2rem;
}

@media (min-width: 768px) {
  .sort-select {
    width: auto;
    min-width: 200px;
    font-size: 0.9rem;
    padding: 0.75rem 2.5rem 0.75rem 1rem;
    border-radius: 10px;
  }
}

.sort-select:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(217, 179, 17, 0.1);
}

.filter-results-info {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(217, 179, 17, 0.1);
  border-radius: 10px;
  font-size: 0.9rem;
  color: var(--color-text);
  display: none;
  animation: slideDown 0.3s ease;
}

.filter-results-info.show {
  display: block;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Cards com animações premium */
.card {
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  transform-origin: center;
}

.card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.card.filter-hidden {
  opacity: 0;
  transform: scale(0.9);
  pointer-events: none;
  height: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

.card.filter-visible {
  opacity: 1;
  transform: scale(1);
  animation: premiumFadeIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes premiumFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Responsividade do filtro */
@media (max-width: 768px) {
  .church-filter-container {
    padding: 0 0.5rem;
    margin-bottom: 2rem;
  }
  
  .church-filter-input {
    padding: 0.875rem 3rem 0.875rem 3rem;
    font-size: 0.95rem;
  }
  
  .church-filter-icon {
    left: 15px;
  }
  
  .church-filter-clear {
    right: 12px;
    width: 28px;
    height: 28px;
  }
}

/* Destaque de busca */
.search-highlight {
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  color: var(--color-secondary);
  padding: 0.1rem 0.3rem;
  border-radius: 4px;
  font-weight: 600;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  animation: highlightPulse 0.5s ease;
}

@keyframes highlightPulse {
  0% {
    transform: scale(1.1);
    box-shadow: 0 0 0 4px rgba(217, 179, 17, 0.3);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  }
}

/* Cards de Igrejas */
.cards-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr));
  gap: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: clamp(2rem, 5vw, 3rem);
  width: 100%;
}

@media (max-width: 500px) {
  .cards-list {
    grid-template-columns: 1fr;
  }
}

.card {
  background: var(--color-white);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s, box-shadow 0.3s;
  width: 100%;
  max-width: 100%;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

@media (hover: none) {
  .card:hover {
    transform: none;
  }
  
  .card:active {
    transform: scale(0.98);
  }
}

.card-top-img {
  width: 100%;
  height: clamp(160px, 25vw, 200px);
  object-fit: cover;
  display: block;
}

.card-content {
  padding: clamp(1rem, 3vw, 1.5rem);
}

.card h3 {
  margin-bottom: clamp(0.5rem, 1.5vw, 0.75rem);
  color: var(--color-secondary);
  font-size: clamp(1.125rem, 2.5vw, 1.25rem);
  line-height: 1.3;
  word-wrap: break-word;
}

.leaders {
  color: var(--color-text-light);
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.info, .address {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
}

.info a {
  color: #095fc1;
  text-decoration: none;
}

.info a:hover {
  text-decoration: underline;
}

.contact-btn {
  background: var(--color-primary);
  color: var(--color-secondary);
  border: none;
  padding: 0.6rem 1.2rem;
  border-radius: 4px;
  font-weight: 600;
  cursor: pointer;
  margin-top: 1rem;
  transition: background-color 0.2s;
}

.contact-btn:hover {
  background: var(--color-primary-dark);
}

.no-results {
  grid-column: 1 / -1;
  text-align: center;
  padding: 2rem;
  color: var(--color-text-light);
}

/* Footer */
.site-footer {
  background: var(--color-secondary);
  color: var(--color-white);
  padding: clamp(2rem, 5vw, 3rem) clamp(1rem, 3vw, 2rem) clamp(1rem, 2vw, 1.5rem);
}

.footer-content {
  max-width: var(--container-width);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: clamp(1.5rem, 3vw, 2rem);
  align-items: center;
}

@media (max-width: 768px) {
  .footer-content {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
  }
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: clamp(0.75rem, 2vw, 1rem);
  flex-wrap: wrap;
}

.footer-logo img {
  width: clamp(36px, 6vw, 40px);
  height: clamp(36px, 6vw, 40px);
  border-radius: var(--border-radius);
  flex-shrink: 0;
}

.footer-logo span {
  font-size: clamp(0.9rem, 2vw, 1rem);
  line-height: 1.3;
}

.footer-links {
  display: flex;
  gap: clamp(1rem, 2.5vw, 1.5rem);
  flex-wrap: wrap;
}

@media (max-width: 480px) {
  .footer-links {
    flex-direction: column;
    gap: 0.75rem;
  }
}

.footer-links a {
  color: #ddd;
  transition: color 0.2s;
  font-size: clamp(0.875rem, 1.8vw, 1rem);
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.footer-links a:hover {
  color: var(--color-primary);
}

.footer-social {
  display: flex;
  gap: clamp(0.75rem, 2vw, 1rem);
  flex-wrap: wrap;
}

.footer-copyright {
  max-width: var(--container-width);
  margin: clamp(1.5rem, 4vw, 2rem) auto 0;
  padding-top: clamp(0.75rem, 2vw, 1rem);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  font-size: clamp(0.8rem, 1.8vw, 0.9rem);
  color: #aaa;
  padding-left: clamp(1rem, 3vw, 2rem);
  padding-right: clamp(1rem, 3vw, 2rem);
}

/* Ícones de redes sociais */
.church-social { 
  margin-top: 12px; 
  display: flex; 
  gap: 14px; 
  align-items: center;
}

.church-social .social-icon { 
  color: #666; 
  text-decoration: none; 
  transition: all 0.2s; 
  line-height: 1; 
  display: inline-flex;
  font-size: 1.3rem;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #f5f5f5;
}

.church-social .social-icon:hover { 
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.church-social .social-icon .fa-globe:hover,
.church-social .social-icon:hover .fa-globe { 
  color: #095fc1;
}

.church-social .social-icon[aria-label="Instagram"]:hover,
.church-social .social-icon:hover .fa-instagram { 
  color: #e4405f; 
}

.church-social .social-icon[aria-label="Facebook"]:hover,
.church-social .social-icon:hover .fa-facebook { 
  color: #1877f2;
}

.church-social .social-icon:hover .fa-envelope { 
  color: #ea4335;
}

.church-social .social-icon:hover .fa-phone { 
  color: #25d366;
}

/* Seção Doutrina */
.doutrina-section {
  background: linear-gradient(135deg, #f9f7f2 0%, #fff 100%);
  padding: clamp(2rem, 6vw, 4rem) clamp(1rem, 3vw, 2rem);
}

.doutrina-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr));
  gap: clamp(1.5rem, 3vw, 2rem);
  margin-top: clamp(1.5rem, 4vw, 2rem);
}

@media (max-width: 600px) {
  .doutrina-grid {
    grid-template-columns: 1fr;
  }
}

.doutrina-card {
  background: var(--color-white);
  padding: clamp(1.5rem, 3vw, 2rem) clamp(1rem, 2.5vw, 1.5rem);
  border-radius: var(--border-radius);
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s, box-shadow 0.3s;
}

.doutrina-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

@media (hover: none) {
  .doutrina-card:hover {
    transform: none;
  }
  
  .doutrina-card:active {
    transform: scale(0.98);
  }
}

.doutrina-icon {
  font-size: clamp(2rem, 4vw, 2.5rem);
  color: var(--color-primary);
  margin-bottom: clamp(0.75rem, 2vw, 1rem);
}

.doutrina-card h3 {
  color: var(--color-secondary);
  margin-bottom: clamp(0.5rem, 1.5vw, 0.75rem);
  font-size: clamp(1rem, 2.5vw, 1.15rem);
  line-height: 1.3;
}

.doutrina-card p {
  color: var(--color-text-light);
  line-height: 1.6;
  font-size: clamp(0.875rem, 2vw, 1rem);
}

/* Seção Eventos */
.eventos-section {
  padding: clamp(2rem, 6vw, 4rem) clamp(1rem, 3vw, 2rem);
  background: var(--color-white);
}

.eventos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr));
  gap: clamp(1.5rem, 3vw, 2rem);
  margin-top: clamp(1.5rem, 4vw, 2rem);
}

@media (max-width: 500px) {
  .eventos-grid {
    grid-template-columns: 1fr;
  }
}

.evento-card {
  background: var(--color-white);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s, box-shadow 0.3s;
  border: 1px solid var(--color-border);
  width: 100%;
  max-width: 100%;
}

.evento-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

@media (hover: none) {
  .evento-card:hover {
    transform: none;
  }
  
  .evento-card:active {
    transform: scale(0.98);
  }
}

.evento-img {
  width: 100%;
  height: clamp(180px, 30vw, 220px);
  object-fit: cover;
  display: block;
}

.evento-content {
  padding: clamp(1rem, 3vw, 1.5rem);
}

.evento-content h3 {
  color: var(--color-secondary);
  margin-bottom: clamp(0.75rem, 2vw, 1rem);
  font-size: clamp(1.125rem, 2.8vw, 1.3rem);
  line-height: 1.3;
  word-wrap: break-word;
}

.evento-meta {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.evento-date,
.evento-time {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-primary);
  font-weight: 600;
  font-size: 0.95rem;
}

.evento-location {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-text-light);
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.evento-location i {
  color: var(--color-primary);
}

.evento-description {
  color: var(--color-text);
  line-height: 1.6;
  font-size: 0.95rem;
}

.eventos-info {
  max-width: 700px;
  margin: 2rem auto;
  text-align: center;
  padding: 2rem;
  background: var(--color-background);
  border-radius: var(--border-radius);
  border-left: 4px solid var(--color-primary);
}

.eventos-info p {
  margin-bottom: 1rem;
  color: var(--color-text);
  line-height: 1.7;
}

.eventos-info p:last-child {
  margin-bottom: 0;
}

/* Mapa nos eventos */
.evento-map {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--color-border);
}

/* Seção Contacto */
.contacto-section {
  background: linear-gradient(135deg, #2b2730 0%, #3a3540 100%);
  color: var(--color-white);
  padding: clamp(2rem, 6vw, 4rem) clamp(1rem, 3vw, 2rem);
}

.contacto-section .section-title,
.contacto-section .section-subtitle {
  color: var(--color-white);
}

.contacto-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: clamp(1.5rem, 3vw, 2rem);
  margin-top: clamp(1.5rem, 4vw, 2rem);
}

@media (max-width: 600px) {
  .contacto-info {
    grid-template-columns: 1fr;
  }
}

.contacto-item {
  display: flex;
  gap: clamp(1rem, 2.5vw, 1.5rem);
  align-items: flex-start;
  padding: clamp(1rem, 3vw, 1.5rem);
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--border-radius);
  transition: background 0.3s;
}

.contacto-item:hover {
  background: rgba(255, 255, 255, 0.1);
}

@media (hover: none) {
  .contacto-item:hover {
    background: rgba(255, 255, 255, 0.05);
  }
  
  .contacto-item:active {
    background: rgba(255, 255, 255, 0.1);
  }
}

.contacto-item i {
  font-size: clamp(1.75rem, 3.5vw, 2rem);
  color: var(--color-primary);
  min-width: clamp(32px, 5vw, 40px);
  flex-shrink: 0;
}

.contacto-item h4 {
  margin-bottom: clamp(0.375rem, 1vw, 0.5rem);
  color: var(--color-white);
  font-size: clamp(1rem, 2.2vw, 1.1rem);
}

.contacto-item p {
  color: #ddd;
  line-height: 1.6;
  font-size: clamp(0.875rem, 1.8vw, 0.95rem);
  word-wrap: break-word;
  overflow-wrap: break-word;
  max-width: 100%;
}

/* Melhorias nos cards */
.leaders, .address {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}

.leaders i, .address i {
  color: var(--color-primary);
  min-width: 18px;
}

/* Mapa do Google Maps */
.church-map {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--color-border);
}

.btn-show-map {
  width: 100%;
  padding: 12px;
  background: linear-gradient(135deg, var(--color-primary) 0%, #FFD300 100%);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-show-map:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(174,144,49,0.3);
}

.btn-show-map.active {
  background: linear-gradient(135deg, #be2222 0%, #f73a3a 100%);
}

.map-container {
  margin-top: 12px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.map-container iframe {
  display: block;
  border-radius: 8px;
}

/* ========================================
   RESPONSIVIDADE: MOBILE FIRST
   ======================================== */

/* Tablet e Desktop pequeno (768px+) */
@media (min-width: 768px) {
  nav {
    display: flex !important;
  }
}

/* Mobile: Menu hamburguer */
@media (max-width: 767px) {
  .menu-mobile {
    display: block;
  }
  
  nav {
    display: none;
    position: absolute; /* fora do fluxo */
    top: 100%; /* logo abaixo do header */
    right: 0;
    background: #fff;
    width: 220px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border-radius: 0 0 8px 8px;
    z-index: 999;
  }

  nav.open {
    display: block; /* quando ativo */
  }
  
  .menu-list {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 10px;
    right: 0;
    width: min(280px, 85vw);
    background: var(--color-background-alt);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    border-radius: 0 0 12px 12px;
    z-index: 100;
    gap: 0;
    padding: 1rem;
    font-size: 1rem;
    align-items: flex-start;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .menu-list.open { 
    display: flex;
    animation: slideDown 0.3s ease-out;
  }
  
  @keyframes slideDown {
    from {
      opacity: 0;
      transform: translateY(-10px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  .menu-list li { 
    width: 100%;
    margin-bottom: 0.5rem;
  }
  
  .menu-list li:last-child {
    margin-bottom: 0;
  }
  
  .menu-list a {
    display: block;
    padding: 0.75rem;
    border-radius: 8px;
    transition: background 0.2s ease;
  }
  
  .menu-list a:hover,
  .menu-list a:active {
    background: rgba(217, 179, 17, 0.1);
  }
}

/* Mobile muito pequeno */
@media (max-width: 360px) {
  .menu-list {
    width: calc(100vw - 20px);
    right: 10px;
    padding: 0.75rem;
    font-size: 0.95rem;
  }
}

/* Melhorias para telas pequenas */
@media (max-width: 500px) {
  .church-filter-premium {
    padding: 0.875rem;
    margin: 0 0.5rem 1.5rem;
  }
  
  .filter-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
  }
  
  .filter-title {
    font-size: 1.05rem;
  }
  
  .filter-stats {
    width: 100%;
    text-align: left;
    font-size: 0.8rem;
  }
  
  .filter-controls {
    gap: 0.75rem;
  }
  
  .search-input {
    font-size: 0.875rem;
    padding: 0.625rem 2.5rem 0.625rem 2.75rem;
  }
  
  .filter-btn {
    font-size: 0.8rem;
    padding: 0.4rem 0.75rem;
    min-height: 32px;
  }
  
  .filter-btn i {
    font-size: 0.7rem;
  }
  
  .sort-select {
    font-size: 0.8rem;
    padding: 0.5rem 1.75rem 0.5rem 0.625rem;
  }
  
  .btn-show-map {
    font-size: 0.875rem;
    padding: 0.75rem 1rem;
  }
}

/* Otimizações para telas muito pequenas */
@media (max-width: 360px) {
  :root {
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
  }
  
  .filter-btn {
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
  }
  
  .church-social .social-icon {
    width: 32px;
    height: 32px;
    font-size: 1.125rem;
  }
}

/* Otimizações para paisagem em mobile */
@media (max-height: 500px) and (orientation: landscape) {
  /*.wave-section {
    padding: 2rem 1rem 0;
  }
  
  .wave-title {
    font-size: 1.5rem;
  }
  
  .wave-subtitle {
    font-size: 1rem;
  }
  
  .menu-list {
    max-height: 70vh;
    overflow-y: auto;
  }*/
  
  .wave-section {
      position: relative;
      width: 100%;
      height: 600px;
      display: flex;
      align-items: center;
      justify-content: center;
      overflow: hidden;
      color: rgb(255, 255, 255);

}

 section video {
  position: absolute;
  object-fit: cover;
  width: 100%;
  height: 100%;
  filter: brightness(0.7);
}


.video-overlay1 {
  position: absolute;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.3);
}

.text-container {
  display: flex;
  position: absolute;
  text-align: center;
  z-index: 2;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 32px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.wave-title {
  font-size: var(--font-size-2xl);
  max-width: min(800px, 90vw);
  padding: 32px 64px 0 64px;
  word-wrap: break-word;
}

.wave-subtitle {
  max-width: min(800px, 90vw);
  font-size: clamp(1rem, 2.5vw, 1.1rem);
  padding: 0 64px 32px 64px;
}

.wave-bottom {
  position: absolute;
  width: 100%;
  height: clamp(40px, 8vw, 60px);
  margin-bottom: -5px;
  align-self: flex-end;
}

.wave-bottom svg {
  width: 100%;
  height: 100%;
  display: block;
}
  
}

/* Acessibilidade */
.menu-list::-webkit-scrollbar {
  display: none;
}

/* Foco visível para acessibilidade */
a:focus, button:focus {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* Suporte para notch do iPhone (iOS) */
@supports (padding-top: env(safe-area-inset-top)) {
  body {
    padding-top: env(safe-area-inset-top);
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
    padding-bottom: env(safe-area-inset-bottom);
  }
  
  .header-main {
    padding-left: max(env(safe-area-inset-left), 0px);
    padding-right: max(env(safe-area-inset-right), 0px);
  }
}

/* Melhorias de performance para mobile */
@media (max-width: 767px) {
  * {
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
  }
  
  img {
    -webkit-user-drag: none;
    user-drag: none;
  }
  
  /* Prevenir zoom em inputs (Safari iOS) */
  input, select, textarea {
    font-size: 16px !important;
  }
  
  /* Melhorar rendering em Safari iOS */
  body {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
  }
}

/* Ajustes específicos para Safari iOS */
@supports (-webkit-overflow-scrolling: touch) {
  .menu-list {
    -webkit-overflow-scrolling: touch;
  }
  
  .search-input,
  .sort-select {
    -webkit-appearance: none;
    border-radius: 50px;
  }
  
  input[type="text"],
  input[type="search"] {
    -webkit-appearance: none;
  }
}

/* Fix para Samsung Internet */
@media screen and (-webkit-min-device-pixel-ratio:0) {
  select::-ms-expand {
    display: none;
  }
}

/* Suporte para modo escuro do sistema (opcional) */
@media (prefers-color-scheme: dark) {
  /* Descomente se quiser suporte para modo escuro
  :root {
    --color-background: #1a1a1a;
    --color-text: #e5e5e5;
    --color-background-alt: #2a2a2a;
  }
  */
}

/* Melhorias para impressão */
@media print {
  .header-main,
  .menu-mobile,
  .wave-bottom,
  .church-filter-premium,
  .btn-show-map,
  .footer-links,
  button {
    display: none !important;
  }
  
  body {
    font-size: 12pt;
    line-height: 1.4;
  }
  
  .card,
  .doutrina-card,
  .evento-card {
    break-inside: avoid;
    page-break-inside: avoid;
  }
}

/* Cards com animações premium */
.card {
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  transform-origin: center;
  position: relative;
}

.card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.card.filter-hidden {
  opacity: 0;
  transform: scale(0.9);
  pointer-events: none;
  height: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

.card.filter-visible {
  opacity: 1;
  transform: scale(1);
  animation: premiumFadeIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Destaque para cards filtrados */
.card.filtered-match {
  border: 2px solid var(--color-primary);
  box-shadow: 0 0 0 4px rgba(217, 179, 17, 0.2);
}

.card.filtered-match::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-primary-dark));
  border-radius: 20px 20px 0 0;
}

@keyframes premiumFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Mensagem de nenhum resultado */
.no-churches-found {
  grid-column: 1 / -1;
  text-align: center;
  padding: 4rem 2rem;
  background: linear-gradient(135deg, var(--color-white) 0%, #f8f9fa 100%);
  border-radius: 20px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
  margin: 2rem 0;
}

.no-churches-found i {
  font-size: 4rem;
  color: var(--color-primary);
  margin-bottom: 1.5rem;
  display: block;
  opacity: 0.7;
}

.no-churches-found h3 {
  color: var(--color-secondary);
  margin-bottom: 0.5rem;
  font-size: 1.5rem;
}

.no-churches-found p {
  color: var(--color-text-light);
  margin: 0;
  font-size: 1.1rem;
}
