:root{
  --principal:#09255d;
  --principal-profunda:#04132f;
  --secundaria:#1bdcfc;
  --secundaria-escura:#135da3;
  --fundo:#f7fbfd;
  --texto:#071b3f;
  --muted:#4c6169;
  --card:#ffffff;
  --border:#e7eaf0;
}

/* Tema escuro global (ativado via html[data-theme="dark"]) */
html[data-theme="dark"]{
  --fundo:#04132f;
  --texto:#dff6fb;
  --muted:rgba(226,232,240,0.70);
  --card:rgba(15,23,42,0.85);
  --border:rgba(148,163,184,0.18);
}

html,body{height:100%;}
body{
  font-family:'Inter',system-ui,-apple-system,'Segoe UI',Roboto,Arial,sans-serif;
  background:var(--fundo);
  color:var(--texto);
}

/* Ajustes gerais no escuro */
html[data-theme="dark"] .text-muted{color: var(--muted)!important;}
html[data-theme="dark"] .dropdown-menu{
  background: rgba(15,23,42,0.98);
  border-color: rgba(148,163,184,0.18);
}
html[data-theme="dark"] .dropdown-item{color: rgba(226,232,240,0.85);} 
html[data-theme="dark"] .dropdown-item:hover{background: rgba(148,163,184,0.12);} 

/* Navbar */
.navbar{
  background:var(--principal)!important;
  padding:14px 0;
  border-bottom:1px solid rgba(255,255,255,0.10);
  /* evita o dropdown ficar "preso"/escondido por empilhamento ou overflow */
  overflow: visible;
}

/* garante que o menu "Conta" apareça por cima do conteúdo */
.navbar .dropdown-menu{
  z-index: 2000;
}

.brand-logo{
  height: 44px;
  width: auto;
  display: block;
}
@media (max-width: 480px){
  .brand-logo{ height: 36px; }
}

.navbar .nav-link{
  color:rgba(255,255,255,0.82)!important;
  font-weight:600;
}
.navbar .nav-link:hover{color:var(--secundaria)!important;}
.navbar .btn-cta{
  background:var(--secundaria);
  color:var(--principal-profunda)!important;
  border-radius:12px;
  font-weight:800;
  padding:10px 14px;
  margin-left:14px;
}
.navbar .btn-cta:hover{filter:brightness(0.95); transform:translateY(-1px);}

/* ── Navbar buttons padronizados ──────────────────────────────── */
.nb-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  height:36px;
  padding:0 14px;
  border-radius:8px;
  font-size:.875rem;
  font-weight:600;
  cursor:pointer;
  border:none;
  white-space:nowrap;
  text-decoration:none!important;
  transition:filter .15s, transform .1s;
  line-height:1;
}
.nb-btn:hover{filter:brightness(.9);transform:translateY(-1px);}
.nb-btn-ghost{
  background:transparent;
  border:1px solid rgba(255,255,255,.35);
  color:#fff!important;
}
.nb-btn-ghost:hover{background:rgba(255,255,255,.12);}
.nb-btn-primary{
  background:var(--secundaria);
  color:var(--principal-profunda)!important;
}
.nb-btn-cta{
  background:#fff;
  color:var(--principal)!important;
  font-weight:700;
}

/* Hero */
.hero{
  background:var(--principal);
  color:#fff;
  padding:86px 0 70px;
  text-align:center;
  border-bottom-left-radius:46px;
  border-bottom-right-radius:46px;
  margin-bottom:50px;
}
.hero h1{font-weight:900; font-size:clamp(2.1rem,4vw,3.3rem); margin-bottom:14px;}
.hero p{color:rgba(255,255,255,0.75); max-width:720px; margin:0 auto 24px;}

/* Buttons */
.btn-pill{
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding:12px 18px;
  border-radius:14px;
  font-weight:700;
  text-decoration:none;
  border:1px solid rgba(255,255,255,0.14);
  color:#fff;
  background:rgba(255,255,255,0.06);
}
.btn-pill:hover{background:rgba(255,255,255,0.10); color:#fff;}
.btn-pill.btn-primary{
  background:var(--secundaria);
  border-color:transparent;
}
.btn-pill.btn-primary:hover{filter:brightness(0.95);}

/* Cards */
.card-soft{
  background:var(--card);
  border:1px solid var(--border);
  border-radius:26px;
  overflow:hidden;
  box-shadow:0 10px 30px rgba(2,6,23,0.05);
  transition:0.25s;
}
.card-soft:hover{transform:translateY(-6px); box-shadow:0 18px 46px rgba(2,6,23,0.10);}
.card-soft .media{
  position:relative;
  padding:14px;
}
.card-soft .media img{
  width:100%;
  height:210px;
  object-fit:cover;
  border-radius:18px;
}
.badge-status{
  position:absolute;
  top:22px;
  right:22px;
  padding:7px 12px;
  border-radius:999px;
  font-size:0.72rem;
  font-weight:900;
  letter-spacing:0.4px;
}
.badge-status.ok{background:var(--secundaria); color:var(--principal-profunda);}
.badge-status.off{background:#dc3545; color:#fff;}

/* Badges de indisponibilidade em templates que não usam .badge-status */
.badge-neutral{
  position:absolute;
  top:22px;
  right:22px;
  padding:7px 12px;
  border-radius:999px;
  font-size:0.72rem;
  font-weight:900;
  letter-spacing:0.4px;
  background:#dc3545;
  color:#fff;
}
.price{
  color:var(--secundaria);
  font-weight:900;
  font-size:1.25rem;
}

/* Panels */
.panel-dark{
  background:var(--principal);
  border-radius:46px;
  color:#fff;
  padding:56px 0;
  margin-top:56px;
}
.panel-dark .box{
  background:rgba(255,255,255,0.04);
  border:1px solid rgba(255,255,255,0.10);
  border-radius:22px;
  padding:22px;
  height:100%;
}

/* Footer */
.main-footer{
  background:var(--principal);
  padding:72px 0 26px;
  color:#fff;
  margin-top:90px;
}
.main-footer .footer-text{color:rgba(255,255,255,0.65); line-height:1.8;}
.main-footer .footer-title{font-weight:800; margin-bottom:18px;}
.main-footer a{color:rgba(255,255,255,0.70); text-decoration:none;}
.main-footer a:hover{color:var(--secundaria);}
.social-links a{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:40px;
  height:40px;
  border-radius:12px;
  background:rgba(255,255,255,0.06);
  color:#fff;
  margin-right:8px;
}
.social-links a:hover{background:var(--secundaria); color:#fff; transform:translateY(-2px);}
.footer-divider{border-color:rgba(255,255,255,0.12); margin:34px 0 18px;}
.footer-bottom{color:rgba(255,255,255,0.45); font-size:0.85rem; text-align:center;}

/* Simple fade-up */
.animate-card{opacity:0; transform:translateY(10px);}
.animate-ready .animate-card{animation:fadeUp 0.7s ease forwards;}
@keyframes fadeUp{to{opacity:1; transform:translateY(0);}}

/* Forms */
.form-control:focus{box-shadow:0 0 0 0.25rem rgba(27,220,252,0.18); border-color:rgba(19,93,163,0.55);}

/* Auth (Login/Cadastro) */
.auth-wrap{
  min-height: calc(100vh - 160px);
  display:flex;
  align-items:center;
  padding: 56px 0;
  background:
    radial-gradient(600px 200px at 15% 10%, rgba(27,220,252,0.14), transparent 60%),
    radial-gradient(520px 240px at 90% 35%, rgba(19,93,163,0.12), transparent 60%),
    var(--fundo);
}
.auth-card{
  max-width: 520px;
  margin: 0 auto;
  background: var(--card);
  border:1px solid var(--border);
  border-radius: 26px;
  padding: 28px;
  box-shadow: 0 18px 55px rgba(2,6,23,0.10);
}
.auth-brand{
  display:flex;
  gap: 14px;
  align-items:flex-start;
}
.auth-mark{
  width:44px;
  height:44px;
  border-radius: 14px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#fff;
  background: linear-gradient(135deg, var(--secundaria-escura), var(--secundaria));
  box-shadow: 0 10px 22px rgba(19,93,163,0.24);
}
.auth-title{
  font-weight: 900;
  font-size: 1.4rem;
  line-height: 1.1;
}
.auth-subtitle{
  color: var(--muted);
  margin-top: 6px;
  font-size: 0.95rem;
}
.auth-btn{
  border-radius: 16px;
  font-weight: 800;
  background: var(--secundaria);
  border-color: transparent;
  padding-top: 12px;
  padding-bottom: 12px;
}
.auth-btn:hover{filter: brightness(0.96);}
.auth-foot{
  margin-top: 14px;
  text-align:center;
  display:flex;
  gap: 8px;
  justify-content:center;
  align-items:center;
}
.auth-link{
  font-weight: 800;
  color: var(--texto);
  text-decoration: none;
}
.auth-link:hover{color: var(--secundaria);}

.auth-divider{
  position:relative;
  text-align:center;
  margin: 14px 0 10px;
}
.auth-divider::before{
  content:"";
  position:absolute;
  left:0;
  right:0;
  top:50%;
  height:1px;
  background: var(--border);
}
.auth-divider span{
  position:relative;
  display:inline-block;
  padding: 0 10px;
  background: var(--card);
  color: var(--muted);
  font-weight:800;
  font-size: 0.85rem;
}
.auth-google{
  border-color: var(--border) !important;
}
html[data-theme="dark"] .auth-google{
  color: rgba(226,232,240,0.92) !important;
  border-color: rgba(148,163,184,0.22) !important;
}

.auth-tools{
  display:flex;
  justify-content:flex-end;
  margin-bottom: 12px;
}
.auth-theme{
  display:inline-flex;
  align-items:center;
  gap:10px;
  border:1px solid var(--border);
  background:transparent;
  color: var(--muted);
  font-weight:800;
  border-radius: 14px;
  padding: 8px 12px;
}
.auth-theme:hover{color: var(--texto);}

.password-wrap{
  position:relative;
}
.password-wrap input{
  padding-right: 52px !important;
}
/* Quando inválido, o Bootstrap coloca ícone na direita — recua o olhinho */
.password-wrap input.is-invalid{
  padding-right: 80px !important;
}
.password-toggle{
  position:absolute;
  right: 36px;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 6px;
  border-radius: 12px;
  line-height: 1;
}
/* Sem erro: olhinho fica na borda direita normal */
.password-wrap:not(:has(input.is-invalid)) .password-toggle{
  right: 10px;
}
.password-toggle:hover{color: var(--texto); background: rgba(2,6,23,0.04);} 

.pw-meter{
  margin-top: 10px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(2,6,23,0.02);
}
.pw-title{font-weight: 800; font-size: 0.92rem; color: var(--texto); margin-bottom: 8px;}
.pw-list{list-style:none; padding-left: 0; margin:0; display:grid; gap:6px;}
.pw-list li{display:flex; align-items:center; gap:10px; color: var(--muted); font-size: 0.92rem;}
.pw-list li i{font-size: 0.55rem;}
.pw-list li.ok{color: var(--secundaria); font-weight:800;}

/* Tema escuro: melhorias nas telas de auth (usa o tema global) */
html[data-theme="dark"] .auth-wrap{
  background:
    radial-gradient(600px 220px at 15% 10%, rgba(27,220,252,0.18), transparent 60%),
    radial-gradient(520px 260px at 90% 35%, rgba(148,163,184,0.10), transparent 60%),
    var(--fundo);
}
html[data-theme="dark"] .auth-card{
  box-shadow: 0 18px 55px rgba(0,0,0,0.50);
}
html[data-theme="dark"] .auth-theme{border-color: rgba(148,163,184,0.22); color: rgba(226,232,240,0.75);} 
html[data-theme="dark"] .form-control{
  background: rgba(2,6,23,0.45);
  border-color: rgba(148,163,184,0.22);
  color: #e5e7eb;
}
html[data-theme="dark"] .form-control::placeholder{color: rgba(226,232,240,0.55);} 
html[data-theme="dark"] .pw-meter{background: rgba(2,6,23,0.35); border-color: rgba(148,163,184,0.22);} 

/* Calendário simples */
.cal-box{
  border:1px solid var(--border);
  border-radius:18px;
  padding:14px;
  background:var(--card);
}
.cal-title{
  font-weight:800;
  margin-bottom:10px;
}
.cal-grid{
  display:grid;
  grid-template-columns: repeat(7, 1fr);
  gap:6px;
  margin-bottom:6px;
}
.cal-head > div{
  font-size:12px;
  color:var(--muted);
  text-align:center;
  padding:4px 0;
}
.cal-day{
  aspect-ratio: 1 / 1;
  display:flex;
  align-items:center;
  justify-content:center;
  border:1px solid var(--border);
  border-radius:12px;
  font-size:12px;
  background:var(--card);
}
.cal-out{
  opacity:.35;
}
.cal-ocupado-bg{
  background: rgba(220, 38, 38, .12);
  border-color: rgba(220, 38, 38, .25);
}
.cal-bloqueado-bg{
  background: rgba(107, 114, 128, .12);
  border-color: rgba(107, 114, 128, .25);
}
.cal-dot{
  display:inline-block;
  width:10px;
  height:10px;
  border-radius:999px;
  margin-right:6px;
  vertical-align:middle;
}
.cal-ocupado{ background: rgba(220, 38, 38, .8); }
.cal-bloqueado{ background: rgba(107, 114, 128, .8); }
