/* D'Ville Chalés — Analândia-SP | Condomínio Nova Analândia */

:root {
  --bg: #0d1117;
  --text: #ffffff;
  --accent: #b8941f;
  --accent-light: #d4a83a;
  --accent-soft: rgba(184, 148, 31, 0.2);
  --border: rgba(255, 255, 255, 0.08);
  --card-bg: rgba(255, 255, 255, 0.03);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: 'Montserrat', 'Segoe UI', system-ui, sans-serif;
  line-height: 1.5;
  overflow-x: hidden;
}

h1, h2, h3, .modal-title, .card-title, .hero-text strong, .header-title {
  font-family: 'Playfair Display', Georgia, serif;
  letter-spacing: 0.03em;
}

/* Header — flex, título centralizado, logo em destaque */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 2rem;
  min-height: 72px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  position: relative;
}

.header-left {
  flex: 0 0 auto;
  z-index: 1;
}

.logo-wrap {
  margin: 0;
  line-height: 0;
  min-height: 48px;
}

.logo-img {
  display: block;
  max-height: 64px;
  height: 64px;
  width: 64px;
  min-width: 64px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  border: 2px solid var(--accent);
}

.header-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--accent);
  font-family: 'Playfair Display', Georgia, serif;
  pointer-events: none;
  white-space: nowrap;
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex: 0 0 auto;
  z-index: 1;
}

.nav-link {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  position: relative;
  padding: 0.25rem 0;
  transition: color 0.3s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width 0.3s ease, left 0.3s ease;
}

.nav-link:hover {
  color: var(--accent-light);
}

.nav-link:hover::after {
  width: 100%;
  left: 0;
}

/* Header mobile — evita sobreposição dos botões ao título */
@media (max-width: 768px) {
  .header {
    flex-direction: column;
    align-items: center;
    padding: 0.75rem 1rem;
    min-height: auto;
  }

  .header-title {
    position: static;
    transform: none;
    margin: 0.5rem 0 0;
    font-size: 1.2rem;
    order: 2;
  }

  .header-left {
    order: 1;
  }

  .nav {
    order: 3;
    margin-top: 0.75rem;
    gap: 1rem;
  }

  .nav-link {
    font-size: 0.9rem;
  }
}

/* Botões */
.btn {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 4px;
  font-size: 0.9rem;
  cursor: pointer;
  background: transparent;
  color: var(--text);
}

.btn-primary {
  background: var(--accent);
  color: var(--bg);
}

.btn-primary:hover {
  background: var(--accent-light);
}

.btn-outline {
  border: 1px solid var(--accent);
  color: var(--accent);
}

.btn-outline:hover {
  background: var(--accent-soft);
}

.btn-ghost {
  color: var(--text);
}

/* Main */
.main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

.hero {
  text-align: center;
  padding: 1.5rem 1rem 2.5rem;
  border-bottom: 1px solid var(--border);
}

.hero-text {
  margin: 0;
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.9);
}

.hero-text strong {
  color: var(--accent);
}

.hero-location {
  color: var(--accent-light);
  font-weight: 600;
}

/* Carrossel de topo — container com respiro (92% / max 1400px), centralizado, bordas suaves e sombra */
.carousel-section {
  width: 92%;
  max-width: 1400px;
  margin: 20px auto;
  padding: 0;
  position: relative;
  box-sizing: border-box;
}

.carousel-wrap {
  position: relative;
  width: 100%;
  border-radius: 15px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--card-bg);
  box-sizing: border-box;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.carousel-track {
  display: flex;
  transition: transform 0.45s ease;
  width: 100%;
}

.carousel-slide {
  position: relative;
  flex: 0 0 100%;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--border);
}

.carousel-slide-zoom-wrap {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.carousel-slide-zoom-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.carousel-slide[data-focus="top"] .carousel-slide-zoom-wrap img {
  object-position: center top;
}

.carousel-slide[data-focus="bottom"] .carousel-slide-zoom-wrap img {
  object-position: center bottom;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.carousel-slide[data-focus="top"] img {
  object-position: center top;
}

.carousel-slide[data-focus="bottom"] img {
  object-position: center bottom;
}

.carousel-slide-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  pointer-events: none;
}

.carousel-slide-first .carousel-slide-overlay {
  pointer-events: none;
}

.carousel-slide-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  z-index: 1;
  pointer-events: none;
}

.carousel-slide-content .carousel-cta {
  pointer-events: auto;
}

.carousel-slide-welcome {
  margin: 0 0 1.25rem;
  font-size: clamp(1rem, 3vw, 1.35rem);
  font-weight: 600;
  color: #fff;
  text-align: center;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  max-width: 420px;
}

.carousel-cta {
  padding: 0.65rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.2s;
}

.carousel-cta:hover {
  background: var(--accent-light);
}

.carousel-slide-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.95rem;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: var(--card-bg);
  color: var(--accent);
  font-size: 1.5rem;
  cursor: pointer;
  z-index: 2;
  line-height: 1;
  opacity: 0.9;
}

.carousel-btn:hover {
  opacity: 1;
}

.carousel-prev { left: 0.5rem; }
.carousel-next { right: 0.5rem; }

.carousel-btn-config {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 36px;
  height: 36px;
  padding: 0;
  border: none;
  border-radius: 6px;
  background: var(--card-bg);
  color: var(--accent);
  cursor: pointer;
  z-index: 2;
  font-size: 1.1rem;
  opacity: 0.9;
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--border);
  cursor: pointer;
  padding: 0;
}

.carousel-dot.active {
  background: var(--accent);
}

.modal-subtitle {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.75);
}

/* Modal carrossel: URL, Selecionar e Remover alinhados na mesma linha, dentro da área escura */
.carousel-edit-row {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
  min-width: 0;
  max-width: 100%;
}

.carousel-edit-row:last-of-type { border-bottom: none; }

.carousel-row-top {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  flex: 1 1 auto;
}

.carousel-row-top label {
  flex: 0 0 52px;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.9);
}

.carousel-row-top .carousel-input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0.5rem 0.75rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.9rem;
}

.carousel-row-top .carousel-input:focus {
  outline: none;
  border-color: var(--accent);
}

.carousel-row-top .carousel-focus {
  flex: 0 0 auto;
  min-width: 120px;
  padding: 0.5rem 0.5rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.85rem;
  cursor: pointer;
}

.carousel-row-top .carousel-focus-custom {
  display: none;
}

.carousel-row-top .carousel-foco-btn {
  flex: 0 0 auto;
  white-space: nowrap;
  font-size: 0.85rem;
}

.carousel-row-btns {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.carousel-row-btns .carousel-select-btn {
  white-space: nowrap;
}

.carousel-row-btns .carousel-remove {
  color: #e57373;
  font-weight: 500;
}

.carousel-row-btns .carousel-remove:hover {
  color: #ff8a80;
}

.carousel-empty { margin: 0 0 0.75rem; color: rgba(255,255,255,0.6); font-size: 0.9rem; }
#carousel-form-container #carousel-add { margin-top: 0.5rem; }

/* Carrossel de chalés — 2 cards em desktop, 1 em mobile */
.chales-section {
  position: relative;
  width: 92%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem 0;
  box-sizing: border-box;
}

.chales-wrap {
  overflow: hidden;
}

.chales {
  display: flex;
  flex-wrap: nowrap;
  gap: 2.5rem;
  transition: transform 0.4s ease;
  box-sizing: border-box;
}

.chales .card {
  flex: 0 0 calc((100% - 2.5rem) / 2);
  min-width: 0;
  box-sizing: border-box;
}

/* Modo carrossel: 3+ cards — slides A-B, B-C, C-A, rotação circular */
.chales.chales-carousel-mode {
  gap: 0;
}
.chales.chales-carousel-mode .chales-slide {
  flex: 0 0 100%;
  width: 100%;
  display: flex;
  flex-wrap: nowrap;
  gap: 2.5rem;
  box-sizing: border-box;
  padding: 0 0.5rem;
}
.chales.chales-carousel-mode .chales-slide .card {
  flex: 0 0 calc((100% - 2.5rem) / 2);
  min-width: 0;
}

@media (max-width: 768px) {
  .chales-container {
    padding: 0 10px;
    overflow-x: hidden;
  }

  /* Modo stack: cards empilhados verticalmente */
  .chales-section.chales-stack-mode .chales {
    flex-direction: column;
    flex-wrap: wrap;
    overflow: visible;
    gap: 1.5rem;
  }

  .chales-section.chales-stack-mode .chales .card {
    flex: 0 0 auto;
    max-width: 100%;
    width: 100%;
  }

  .chales-section.chales-stack-mode .chales-carousel-btn {
    display: none !important;
  }

  .chales-section.chales-stack-mode .chales-wrap {
    overflow: visible;
  }

  /* Carrossel mode (desktop redimensionado): ajustes */
  .chales .card,
  .chales.chales-carousel-mode .chales-slide .card {
    flex: 0 0 100% !important;
    max-width: 100% !important;
    margin: 10px 0 !important;
  }
}

.chales-carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border: 1px solid var(--accent);
  background: rgba(13, 17, 23, 0.9);
  color: var(--accent);
  font-size: 1.5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  border-radius: 50%;
  transition: background 0.5s ease, color 0.5s ease, border-color 0.5s ease, box-shadow 0.5s ease;
}

.chales-carousel-btn:hover {
  background: var(--accent-soft);
  color: var(--accent-light);
  border-color: var(--accent-light);
  box-shadow: 0 0 12px var(--accent-soft);
}

.chales-prev { left: -1rem; }
.chales-next { right: -1rem; }

@media (max-width: 768px) {
  .chales-prev { left: 0.25rem; }
  .chales-next { right: 0.25rem; }
  .chales-carousel-btn { width: 36px; height: 36px; font-size: 1.2rem; }
}

.card {
  position: relative;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 15px;
  overflow: hidden;
  display: flex;
  flex-direction: row;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(184, 148, 31, 0.03);
  transition: box-shadow 0.4s ease;
}

.card:hover {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3), 0 0 24px rgba(184, 148, 31, 0.08);
}

@media (max-width: 768px) {
  .card {
    flex-direction: column;
  }
}

.card-btn-config {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 36px;
  height: 36px;
  padding: 0;
  border: none;
  border-radius: 6px;
  background: var(--card-bg);
  color: var(--accent);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  opacity: 0.9;
}

.card-btn-config svg {
  width: 20px;
  height: 20px;
}

.card-btn-excluir {
  position: absolute;
  top: 0.5rem;
  right: 2.5rem;
  width: 36px;
  height: 36px;
  padding: 0;
  border: none;
  border-radius: 6px;
  background: var(--card-bg);
  color: #c62828;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  opacity: 0.9;
}

.card-btn-excluir:hover {
  background: rgba(198, 40, 40, 0.2);
  color: #b71c1c;
}

.card-btn-excluir svg {
  width: 20px;
  height: 20px;
}

.card-img-wrap {
  width: min(320px, 38%);
  aspect-ratio: 9 / 16;
  background: var(--border);
  overflow: hidden;
  flex-shrink: 0;
  border-radius: 15px 0 0 15px;
  border-right: 2px solid var(--accent);
  box-shadow: 0 0 12px var(--accent-soft), inset 0 0 20px rgba(184, 148, 31, 0.08);
}

@media (max-width: 768px) {
  .card-img-wrap {
    width: 100%;
    aspect-ratio: 9 / 16;
    border-radius: 15px 15px 0 0;
    border-right: none;
    border-bottom: 2px solid var(--accent);
    box-shadow: 0 0 12px var(--accent-soft), inset 0 0 20px rgba(184, 148, 31, 0.08);
  }
}

.card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.card-img-wrap[data-focus="top"] .card-img {
  object-position: center top;
}

.card-img-wrap[data-focus="bottom"] .card-img {
  object-position: center bottom;
}

.card-img-zoom-wrap {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.card-img-zoom-wrap .card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.card-img-wrap[data-focus="top"] .card-img-zoom-wrap .card-img {
  object-position: center top;
}

.card-img-wrap[data-focus="bottom"] .card-img-zoom-wrap .card-img {
  object-position: center bottom;
}

.card-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  border-radius: 0 15px 15px 0;
}

@media (max-width: 768px) {
  .card-body {
    border-radius: 0;
  }
}

.card-title {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--accent);
}

.card-destaque {
  margin: 0 0 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent);
}

.card-camas {
  margin: 0 0 0.5rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.9);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.card-camas-icon {
  font-size: 1rem;
}

.card-camas-text {
  font-weight: 500;
}

.card-desc {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.85);
  flex: 1;
  line-height: 1.5;
}

.card-location {
  color: var(--accent-light);
  font-weight: 600;
}

.card-unidades {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: var(--accent);
  font-style: italic;
}

.card-preco {
  margin: 0 0 1rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
}

.card-preco-periodo {
  font-weight: 400;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
}

.card-btn-fotos,
.card-btn-reservar {
  border-radius: 10px;
  transition: all 0.5s ease;
}

.card-btn-fotos {
  margin-bottom: 0.5rem;
  position: relative;
  overflow: hidden;
}

.card-btn-fotos::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--accent-soft);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.5s ease;
  z-index: -1;
}

.card-btn-fotos:hover::before {
  transform: scaleX(1);
}

.card-btn-reservar {
  width: 100%;
  margin-top: auto;
  flex-shrink: 0;
  position: relative;
  color: var(--bg);
  background: var(--accent);
  transition: color 0.5s ease, background-color 0.5s ease, box-shadow 0.5s ease;
}

.card-btn-reservar:hover {
  color: #000;
  background: var(--accent-light);
  box-shadow: 0 0 14px rgba(184, 148, 31, 0.4);
}


/* Modais */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
  z-index: 1000;
}

.modal-overlay.modal-open {
  opacity: 1;
  visibility: visible;
}

/* Ajustar enquadramento abre por cima do Editar Carrossel */
#modal-foco.modal-open {
  z-index: 1100;
}

.modal {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem 2rem;
  max-width: 420px;
  width: 100%;
}

.modal-login {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}

.modal-login .modal-title {
  color: var(--accent);
}

.modal-login-subtitle {
  margin: 0 0 1.25rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.75);
}

.form-login label {
  display: block;
  margin-top: 0.75rem;
  margin-bottom: 0.25rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
}

.form-login input {
  width: 100%;
  padding: 0.5rem 0.75rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.95rem;
}

.form-login input:focus {
  outline: none;
  border-color: var(--accent);
}

.form-login-erro {
  margin: 0.75rem 0 0;
  font-size: 0.85rem;
  color: #e74c3c;
  min-height: 1.25rem;
}

.form-login-erro:empty {
  display: none;
}

.form-login-sucesso {
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
  color: #27ae60;
  min-height: 1.25rem;
}

.form-login-sucesso:empty {
  display: none;
}

.form-social label {
  display: block;
  margin-top: 0.75rem;
  margin-bottom: 0.25rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
}

.form-social input {
  width: 100%;
  padding: 0.5rem 0.75rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.95rem;
}

.form-social input:focus {
  outline: none;
  border-color: var(--accent);
}

.form-social-hint {
  margin: 0.2rem 0 0;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.6);
}

.form-social-erro {
  margin: 0.75rem 0 0;
  font-size: 0.85rem;
  color: #e74c3c;
  min-height: 1.25rem;
}

.form-social-erro:empty {
  display: none;
}

.modal-title {
  margin: 0 0 1rem;
  font-size: 1.2rem;
  color: var(--accent);
}

.modal-text {
  margin: 0 0 1.25rem;
  font-size: 1rem;
}

.modal-reserva-chale {
  margin: 0 0 1rem;
  font-weight: 600;
  color: var(--accent);
}

.modal-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  margin-top: 1.25rem;
}

/* Formulário reserva */
.form-reserva label {
  display: block;
  margin-top: 0.75rem;
  margin-bottom: 0.25rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
}

.form-reserva input {
  width: 100%;
  padding: 0.5rem 0.75rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.95rem;
}

.form-reserva input:focus {
  outline: none;
  border-color: var(--accent);
}

.form-reserva-status {
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
  color: var(--accent-light);
  min-height: 1.25rem;
}

.form-reserva-status:empty {
  display: none;
}

.form-reserva-status.reserva-status-loading {
  color: var(--accent-light);
}

.modal-reserva .modal-actions {
  margin-top: 1rem;
}

.btn-enviar-whatsapp {
  background: #25D366 !important;
  color: #fff !important;
  font-weight: 600;
  box-shadow: 0 0 12px rgba(37, 211, 102, 0.4);
}

.btn-enviar-whatsapp:hover {
  background: #20bd5a !important;
  box-shadow: 0 0 16px rgba(37, 211, 102, 0.5);
}

.form-reserva-total {
  margin-top: 0.75rem;
  margin-bottom: 0;
  font-weight: 600;
  color: var(--accent-light);
}

.modal-reserva {
  max-width: 420px;
}

/* Admin */
.modal-admin {
  max-width: 480px;
}

/* Modal Ajustar enquadramento */
.modal-foco {
  max-width: 560px;
  width: 94vw;
  box-sizing: border-box;
  padding: 1.25rem;
}

.foco-zoom-ctrls {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.foco-zoom-value {
  min-width: 3rem;
  text-align: center;
  font-size: 0.9rem;
  color: var(--accent);
}

.foco-viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #1a1a1a;
  border-radius: 8px;
  margin-bottom: 1rem;
  cursor: grab;
  touch-action: none;
}

.foco-viewport:active {
  cursor: grabbing;
}

.foco-image-wrap {
  position: absolute;
  top: 0;
  left: 0;
  will-change: transform;
  cursor: grab;
  opacity: 1;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  contain: layout style paint;
}

.foco-image-wrap:active {
  cursor: grabbing;
}

.foco-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
  user-drag: none;
}

.foco-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
}

.modal-carousel {
  max-width: 960px;
  width: 94vw;
  box-sizing: border-box;
  padding: 1.25rem;
}

.modal-carousel #carousel-form-container {
  max-width: 100%;
  overflow: hidden;
  padding: 0.5rem 0;
  box-sizing: border-box;
}

#carousel-form-container {
  max-width: 100%;
  overflow: hidden;
  padding-left: 0;
  padding-right: 0;
  box-sizing: border-box;
}

.modal-admin .modal-title {
  margin-bottom: 1rem;
}

.admin-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.admin-row label {
  flex: 0 0 120px;
  font-size: 0.9rem;
}

.admin-row input {
  flex: 1;
  padding: 0.5rem 0.75rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.95rem;
}

.admin-row input:focus {
  outline: none;
  border-color: var(--accent);
}

#admin-form-container {
  margin-bottom: 0.5rem;
}

.form-editar-chale label {
  display: block;
  margin-top: 0.75rem;
  margin-bottom: 0.25rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
}

.form-editar-chale input,
.form-editar-chale textarea {
  width: 100%;
  padding: 0.5rem 0.75rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.95rem;
}

.form-editar-chale textarea {
  resize: vertical;
  min-height: 80px;
}

.form-editar-chale input:focus,
.form-editar-chale textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.modal-admin .form-editar-chale {
  margin-bottom: 0.5rem;
}

.admin-imagem-ctrls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-top: 0.5rem;
}

.admin-imagem-ctrls select {
  padding: 0.35rem 0.5rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  font-size: 0.9rem;
}

/* Hero: link admin galeria */
.hero-admin-link {
  margin: 0.75rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.btn-sm {
  font-size: 0.85rem;
  padding: 0.4rem 0.75rem;
}

/* Modal Galeria — grade 13 fotos, cantos 15px, hover 0.5s com legenda */
.modal-galeria {
  max-width: 900px;
  width: 94vw;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 15px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.modal-galeria-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
}

.modal-close-btn {
  font-size: 1.5rem;
  line-height: 1;
  padding: 0.25rem 0.5rem;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  overflow-y: auto;
  max-height: calc(90vh - 60px);
}

.gallery-item {
  position: relative;
  border-radius: 15px;
  overflow: hidden;
  aspect-ratio: 1;
  background: #1a1a1e;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gallery-item:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.gallery-item-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 0.5rem 0.6rem;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  font-size: 0.8rem;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.gallery-item:hover .gallery-item-caption {
  opacity: 1;
}

/* Lightbox — ampliar foto */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  z-index: 10000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.lightbox-overlay.lightbox-open {
  opacity: 1;
  visibility: visible;
}

.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 44px;
  height: 44px;
  border: none;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  border-radius: 8px;
  z-index: 1;
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border: none;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 2.5rem;
  line-height: 1;
  cursor: pointer;
  border-radius: 50%;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background 0.2s ease;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 0.35);
}

.lightbox-prev {
  left: 1.5rem;
}

.lightbox-next {
  right: 1.5rem;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 75vh;
  object-fit: contain;
  border-radius: 8px;
}

.lightbox-caption {
  margin: 1rem 0 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: 1rem;
  text-align: center;
}

/* Footer */
.footer {
  margin-top: 4rem;
  padding: 2.5rem 2rem 0;
  background: #0a0a0a;
  border-top: 1px solid var(--border);
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2.5rem;
}

.footer-col {
  min-width: 0;
}

.footer-brand .logo-img-footer {
  width: 48px;
  height: 48px;
  min-width: 48px;
  max-height: 48px;
  margin-bottom: 0.75rem;
}

.footer-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--accent);
  margin: 0 0 1rem;
  letter-spacing: 0.04em;
}

.footer-text {
  margin: 0;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.6;
}

.footer-link {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  font-size: 0.95rem;
  line-height: 1.7;
  transition: color 0.3s ease;
}

.footer-link:hover {
  color: var(--accent-light);
}

.footer-map-wrap {
  grid-column: span 1;
}

.footer-map-container {
  display: block;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 16 / 10;
}

.footer-map-iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
  filter: grayscale(1) invert(1) brightness(0.9) contrast(0.95);
}

.footer-map-container:hover .footer-map-iframe {
  filter: grayscale(1) invert(1) brightness(1) contrast(1);
}

.footer-social-links {
  display: flex;
  gap: 0.75rem;
}

.footer-social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--accent);
  text-decoration: none;
  transition: color 0.5s ease, background 0.5s ease, border-color 0.5s ease;
}

.footer-social-link svg {
  width: 22px;
  height: 22px;
}

.footer-social-link:hover {
  color: var(--accent-light);
  background: var(--accent-soft);
  border-color: var(--accent);
}

.footer-credits {
  margin-top: 2.5rem;
  padding: 1.5rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-copyright {
  margin: 0;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  text-align: center;
}

.footer-admin-link {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-admin-link:hover {
  color: var(--accent);
}

@media (max-width: 900px) {
  .footer-inner {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-map-wrap {
    grid-column: span 1;
  }
}

/* Admin: Editar Logo */
.modal-logo {
  text-align: center;
}

.modal-logo .modal-title,
.modal-logo .modal-subtitle {
  text-align: center;
}

.modal-logo .logo-edit-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.logo-file-input-hidden {
  position: absolute;
  width: 0.1px;
  height: 0.1px;
  opacity: 0;
  overflow: hidden;
  z-index: -1;
}

.logo-file-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1.25rem;
  background: var(--card-bg);
  border: 1px solid var(--accent);
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.5s ease, color 0.5s ease, border-color 0.5s ease, box-shadow 0.5s ease;
}

.logo-file-label:hover {
  background: var(--accent-soft);
  color: var(--accent-light);
  border-color: var(--accent-light);
  box-shadow: 0 0 12px var(--accent-soft);
}

.logo-preview-wrap {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--accent);
  background: var(--card-bg);
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-preview-wrap.has-preview .logo-preview-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.logo-preview-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.logo-file-name {
  margin: 0;
  font-size: 0.85rem;
  color: var(--accent-light);
  min-height: 1.25rem;
  max-width: 240px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.logo-file-name:empty {
  display: none;
}

.modal-actions-center {
  justify-content: center;
}

.modal-logo .modal-actions .btn {
  transition: background 0.5s ease, color 0.5s ease, border-color 0.5s ease;
}

/* Admin: Editar Galeria */
.modal-galeria-admin {
  max-width: 640px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-galeria-admin .modal-title {
  flex-shrink: 0;
}

.modal-galeria-admin .modal-subtitle {
  flex-shrink: 0;
}

#galeria-form-container {
  overflow-y: auto;
  flex: 1;
  min-height: 0;
  margin-bottom: 1rem;
  padding-right: 0.5rem;
}

.modal-galeria-admin .modal-actions {
  flex-shrink: 0;
  margin-top: 0;
}

.galeria-edit-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
}

.galeria-edit-row label {
  flex: 0 0 60px;
  font-size: 0.9rem;
}

.galeria-edit-row .galeria-input-src {
  flex: 1 1 180px;
  min-width: 0;
  padding: 0.5rem 0.75rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.9rem;
}

.galeria-edit-row .galeria-input-caption {
  flex: 1 1 140px;
  min-width: 0;
  padding: 0.5rem 0.75rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.9rem;
}

.galeria-edit-row .galeria-remove {
  color: #e57373;
  font-weight: 500;
}

#galeria-form-container #galeria-add {
  margin-top: 0.5rem;
}

/* Sem tooltips: não utilizamos atributo title nos elementos. */
