/* ── Onboarding Modal ─────────────────────────────────────────────
   Prefixo: onb-  (evita conflitos com style.css)
   ---------------------------------------------------------------- */

/* Overlay / Backdrop */
.onb-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}
.onb-overlay.onb-visible {
  opacity: 1;
  pointer-events: all;
}

/* Modal box */
.onb-modal {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 12px 48px rgba(0, 0, 0, 0.22);
  width: 100%;
  max-width: 440px;
  position: relative;
  overflow: hidden;
  transform: translateY(16px) scale(0.97);
  transition: transform 0.28s cubic-bezier(0.34, 1.26, 0.64, 1), opacity 0.22s ease;
  opacity: 0;
}
.onb-overlay.onb-visible .onb-modal {
  transform: translateY(0) scale(1);
  opacity: 1;
}

/* ── Close button ── */
.onb-close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  background: #f5f0eb;
  border: none;
  border-radius: 50%;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  color: #9a8a7a;
  cursor: pointer;
  z-index: 10;
  line-height: 1;
  transition: background 0.15s, color 0.15s;
}
.onb-close:hover {
  background: #e5e0d8;
  color: #1a1a1a;
}

/* ── Branding ── */
.onb-branding {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 1.75rem 0.9rem;
  gap: 0.55rem;
}
.onb-branding-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #b0a090;
}
.onb-branding-logo {
  width: 140px;
  height: auto;
  display: block;
}
.onb-branding-sep {
  height: 1px;
  background: #f0ebe5;
  margin: 0 1.75rem;
}

/* ── Steps container ── */
.onb-steps {
  position: relative;
}

/* ── Individual step ── */
.onb-step {
  display: none;
  flex-direction: column;
  align-items: center;
  padding: 1.25rem 1.75rem 0.5rem;
}
.onb-step.onb-active {
  display: flex;
  animation: onb-slide-in 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}
.onb-step.onb-active.onb-anim-back {
  animation: onb-slide-in-back 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes onb-slide-in {
  from { opacity: 0; transform: translateX(28px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes onb-slide-in-back {
  from { opacity: 0; transform: translateX(-28px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* ── Illustration area ── */
.onb-illus {
  width: 100%;
  height: 148px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.75rem;
  margin-bottom: 1rem;
  overflow: hidden;
}
.onb-illus-1 { background: #eff6ff; }
.onb-illus-2 { background: #e8f5ee; }
.onb-illus-3 { background: #fffbeb; }

.onb-illus svg {
  max-width: 100%;
  max-height: 100%;
}

/* ── Step text ── */
.onb-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: #1a1a1a;
  text-align: center;
  margin-bottom: 0.3rem;
  line-height: 1.25;
}
.onb-subtitle {
  font-size: 0.97rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 0;
  line-height: 1.4;
}
.onb-subtitle-1 { color: #0487dd; }
.onb-subtitle-2 { color: #059669; }
.onb-subtitle-3 { color: #b45309; }

.onb-desc {
  font-size: 0.865rem;
  font-weight: 600;
  color: #5a5050;
  text-align: center;
  line-height: 1.65;
  margin-bottom: 0;
}

/* ── Navigation area ── */
.onb-nav {
  padding: 1.1rem 1.75rem 1.55rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
}

/* Dots */
.onb-dots {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.onb-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #e5e0d8;
  cursor: pointer;
  border: none;
  padding: 0;
  transition: background 0.2s, transform 0.2s, width 0.2s;
  flex-shrink: 0;
}
.onb-dot:hover:not(.onb-dot-active) {
  background: #b0a090;
}
.onb-dot.onb-dot-active {
  background: #0487dd;
  width: 20px;
  border-radius: 4px;
}

/* Buttons row */
.onb-btns {
  display: flex;
  gap: 0.6rem;
  width: 100%;
  align-items: center;
}
.onb-btn-back {
  padding: 0.72rem 1rem;
  background: #fff;
  color: #5a5050;
  border: 1.5px solid #ddd5cc;
  border-radius: 10px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s;
  font-family: inherit;
}
.onb-btn-back:hover { background: #f5f0eb; }

.onb-btn-next {
  flex: 1;
  padding: 0.72rem 1.5rem;
  background: #0487dd;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s;
  font-family: inherit;
}
.onb-btn-next:hover { background: #0370b8; }

/* Skip link */
.onb-skip {
  font-size: 0.75rem;
  color: #b0a090;
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  padding: 0;
  font-family: inherit;
  transition: color 0.15s;
}
.onb-skip:hover { color: #8a7d70; }

/* ── Help button (na interface principal) ── */
.onb-help-btn {
  align-self: center;
  margin-left: 0.4rem;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: none;
  border: 1.5px solid #ddd5cc;
  color: #9a8a7a;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-family: inherit;
  line-height: 1;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.onb-help-btn:hover {
  background: #f5f0eb;
  border-color: #b0a090;
  color: #5a5050;
}

/* ── Checkbox "Não mostrar novamente" ── */
.onb-no-show-label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  color: #b0a090;
  cursor: pointer;
  user-select: none;
  line-height: 1;
}
.onb-no-show-label:hover {
  color: #8a7d70;
}
.onb-no-show-chk {
  width: 13px;
  height: 13px;
  cursor: pointer;
  accent-color: #0487dd;
  flex-shrink: 0;
  margin: 0;
}

/* ── Responsividade ── */
@media (max-width: 480px) {
  .onb-modal {
    border-radius: 14px;
  }
  .onb-step {
    padding: 1.6rem 1.25rem 0.4rem;
  }
  .onb-nav {
    padding: 0.9rem 1.25rem 1.25rem;
  }
  .onb-illus {
    height: 120px;
  }
  .onb-title {
    font-size: 1rem;
  }
  .onb-desc {
    font-size: 0.83rem;
  }
}

@media (max-height: 600px) {
  .onb-illus { height: 100px; }
  .onb-step  { padding-top: 1.25rem; }
}

/* ── Print: ocultar modal ao imprimir ── */
@media print {
  .onb-overlay { display: none !important; }
}
