/* Fallback CSS para manter aparência básica caso o Tailwind CDN não carregue */
:root { --bg:#f9fafb; --fg:#1f2937; --white:#fff; --black:#000; }
html,body { margin:0; padding:0; background:var(--bg); color:var(--fg); font-family: Montserrat, Roboto, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Arial, sans-serif; }
a { text-decoration:none; }

/* Utilitários básicos */
.bg-black { background-color: var(--black) !important; }
.text-white { color: var(--white) !important; }
.bg-gray-50 { background-color: #f9fafb !important; }
.text-gray-800 { color: #1f2937 !important; }
.font-sans { font-family: Montserrat, Roboto, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Arial, sans-serif !important; }
header { background-color: var(--black); color: var(--white); }
.max-w-7xl { max-width: 1280px; margin-left:auto; margin-right:auto; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.py-3 { padding-top:.75rem; padding-bottom:.75rem; }
.py-10 { padding-top:2.5rem; padding-bottom:2.5rem; }
.py-20 { padding-top:5rem; padding-bottom:5rem; }
.rounded { border-radius: .5rem; }
.shadow { box-shadow: 0 1px 2px rgba(0,0,0,.1); }
.bg-white { background-color:#fff; }
.bg-gray-800 { background-color:#1f2937; color:#fff; }
.text-blue-600 { color:#2563eb; }
.grid { display:grid; }
.gap-6 { gap:1.5rem; }
.md\:grid-cols-2 { grid-template-columns: 1fr; }
@media (min-width:768px){ .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.bg-cover { background-size: cover; }
.bg-center { background-position: center; }
.flex { display:flex; }
.flex-col { flex-direction:column; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.items-center { align-items: center; }
.gap-3 { gap:.75rem; }
.text-xl { font-size:1.25rem; line-height:1.75rem; }
.font-semibold { font-weight:600; }
.font-bold { font-weight:700; }
.text-sm { font-size:.875rem; }
.mb-4 { margin-bottom:1rem; }
.mb-8 { margin-bottom:2rem; }

/* Classes com barra precisam de escape */
.bg-black\/60 { background-color: rgba(0,0,0,.6); }

/* Carrossel e placeholders */
.overflow-x-auto { overflow-x: auto; }
.scroll-smooth { scroll-behavior: smooth; }
.snap-x { scroll-snap-type: x mandatory; }
.snap-mandatory { scroll-snap-type: x mandatory; }
.snap-start { scroll-snap-align: start; }
.w-64 { width: 16rem; }
.sm\:w-72 { width: 18rem; }
.md\:w-80 { width: 20rem; }
.h-40 { height: 10rem; }
.animate-pulse { animation: pulse 2s cubic-bezier(0.4,0,0.6,1) infinite; }
@keyframes pulse { 0%, 100% { opacity: 1 } 50% { opacity: .5 } }

/* Botões básicos */
button, .rounded { border-radius: .5rem; }
button, .px-5 { padding-left:1.25rem; padding-right:1.25rem; }
button, .py-3 { padding-top:.75rem; padding-bottom:.75rem; }

/* Skeleton shimmer (fallback quando Tailwind não está disponível) */
.skeleton { position: relative; background: linear-gradient(90deg, #eee 25%, #f5f5f5 37%, #eee 63%); background-size: 400% 100%; animation: shimmer 1.4s ease-in-out infinite; }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }

/* Ratio helpers (mantêm espaço ideal antes da imagem carregar) */
.ratio-3x2 { position: relative; width: 100%; padding-top: 66.6667%; overflow: hidden; }
.ratio-16x9 { position: relative; width: 100%; padding-top: 56.25%; overflow: hidden; }
.ratio-4x3 { position: relative; width: 100%; padding-top: 75%; overflow: hidden; }
.ratio-1x1 { position: relative; width: 100%; padding-top: 100%; overflow: hidden; }
.ratio-content { position: absolute; inset: 0; width: 100%; height: 100%; }
@media (min-width:640px){ .sm\:ratio-3x2{ padding-top:66.6667%; } .sm\:ratio-16x9{ padding-top:56.25%; } .sm\:ratio-4x3{ padding-top:75%; } .sm\:ratio-1x1{ padding-top:100%; } }
@media (min-width:768px){ .md\:ratio-3x2{ padding-top:66.6667%; } .md\:ratio-16x9{ padding-top:56.25%; } .md\:ratio-4x3{ padding-top:75%; } .md\:ratio-1x1{ padding-top:100%; } }
@media (min-width:1024px){ .lg\:ratio-3x2{ padding-top:66.6667%; } .lg\:ratio-16x9{ padding-top:56.25%; } .lg\:ratio-4x3{ padding-top:75%; } .lg\:ratio-1x1{ padding-top:100%; } }

/* Contorno padrão para imagens redondas/placas */
.rounded-t { border-top-left-radius: .5rem; border-top-right-radius: .5rem; }
.rounded-lg { border-radius: .5rem; }

/* Utilitários adicionais */
.overflow-hidden { overflow: hidden; }
.object-cover { object-fit: cover; }
.w-full { width: 100%; }
/* Toasts */
.toast-root { position: fixed; top: 1rem; right: 1rem; z-index: 9999; display: flex; flex-direction: column; gap: .5rem; width: min(360px, 90vw); }
.toast { display:flex; align-items:flex-start; gap:.75rem; padding: .75rem 1rem; border-radius: .5rem; box-shadow: 0 6px 16px rgba(0,0,0,.15); background: #111827; color: #fff; opacity: 0; transform: translateY(-8px); transition: opacity .2s ease, transform .2s ease; }
.toast.show { opacity: 1; transform: translateY(0); }
.toast .title { font-weight: 600; }
.toast.success { background: #065f46; }
.toast.error { background: #7f1d1d; }
.toast.info { background: #1f2937; }
.toast .close { margin-left: auto; background: transparent; border: 0; color: #fff; cursor: pointer; }

/* Login page styles migrated from inline */
.login-card { background-color: #f8f8f8; border-radius: 10px; box-sizing: border-box; padding: 20px; max-width: 400px; box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.1); }
.card-header { text-align: center; margin-bottom: 20px; }
.card-header h1 { font-size: 2em; color: #333; text-shadow: 1px 1px #ddd; }
.form-group { margin-bottom: 10px; }
.form-group label { display: block; font-size: 1.2em; color: #555; margin-bottom: 10px; }
input[type="text"], input[type="email"], input[type="password"] { box-sizing: border-box; padding: 10px; border-radius: 5px; border: none; background-color: #f0f0f0; font-size: 1.2em; color: #555; box-shadow: inset 0px 2px 5px rgba(0, 0, 0, 0.1); transition: box-shadow 0.3s ease; width: 100%; }
input[type="text"]:focus, input[type="email"]:focus, input[type="password"]:focus { box-shadow: inset 0px 2px 5px rgba(0, 0, 0, 0.3); outline: none; }
input[type="submit"], .login-button { background-color: #007bff; border: none; border-radius: 5px; color: #fff; cursor: pointer; font-size: 1.2em; padding: 10px; transition: background-color 0.3s ease; width: 100%; }
.login-button { transition: 0.25s; }
.login-button:hover { background-color: #0069d9e7; box-shadow: 0px 0px 30px 0px rgba(0,105,217,1); }

.site-desktop-nav { display: none; }
@media (min-width:768px){ .site-desktop-nav { display: flex; gap: 1.5rem; } }
@media (min-width:1024px){ .site-desktop-nav { gap: 2rem; } }

/* Fallback para navegadores sem suporte a flex-gap */
@supports not (gap: 1rem) {
  @media (min-width:768px){
    .site-desktop-nav > a { margin-right: 1.5rem; }
    .site-desktop-nav > a:last-child { margin-right: 0; }
  }
  @media (min-width:1024px){
    .site-desktop-nav > a { margin-right: 2rem; }
  }
}

.auto-gallery-button-prev-arrow,
.auto-gallery-button-next-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 10; display: flex; align-items: center; justify-content: center; width: 2.5rem; height: 2.5rem; background: rgba(0,0,0,.5); color: #fff; border-radius: .25rem; }
.auto-gallery-button-prev-arrow { left: .5rem; }
.auto-gallery-button-next-arrow { right: .5rem; }
.gallery-main-image { max-height: 520px; width: 100%; height: auto; object-fit: cover; }
