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

html { overflow-x: hidden; max-width: 100%; }

body {
  margin: 0;
  font-family: 'Poppins', sans-serif;
  overflow-x: hidden;
  max-width: 100vw;
  position: relative;
  background-color: var(--landing-bg);
  padding-top: var(--landing-header-h);
}

main, footer { overflow-x: clip; }

img, picture, video, iframe {
  max-width: 100%;
  height: auto;
}

.sidebar {
  position: fixed;
  top: 0;
  left: -300px;
  width: 300px;
  height: 100vh;
  background: #fff;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
  z-index: 1100;
  transition: left 0.3s ease;
  display: flex;
  flex-direction: column;
}

.sidebar.open { left: 0; }

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  border-bottom: 1px solid #eee;
}

.sidebar-header .logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #1f2937;
}

.sidebar-header .logo svg { height: 28px; width: 28px; }

.sidebar-header .logo .credpix-logo-img {
  height: 32px;
  width: auto;
  max-width: 130px;
}

.logo-text {
  font-weight: 700;
  font-size: 1rem;
  color: var(--cor-texto-destaque);
}

.close-btn {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: #555;
}

.sidebar nav { padding: 20px; flex-grow: 1; }

.sidebar nav h5 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--cor-texto-destaque);
  margin-top: 1.5rem;
  margin-bottom: 1rem;
}

.sidebar nav h5:first-child { margin-top: 0; }

.sidebar nav a {
  display: block;
  padding: 10px 15px;
  text-decoration: none;
  color: #333;
  border-radius: 8px;
  transition: background-color 0.2s;
}

.sidebar nav a:hover { background-color: #f4f7f9; }

.sidebar-footer {
  padding: 25px;
  border-top: 1px solid #eee;
  font-size: 0.9rem;
}

.sidebar-footer strong { display: block; font-weight: 600; }

.sidebar-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  z-index: 1050;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.sidebar-overlay.show {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

@media (max-width: 768px) {
  .sidebar {
    width: 85vw;
    max-width: 300px;
    left: -100%;
  }
}

@media (max-width: 991px) {
  body { padding-top: calc(var(--landing-header-h) - 10px); }
}

@media (max-width: 480px) {
  body { padding-top: calc(var(--landing-header-h) - 15px); }
}

.a-btn,
[data-simulador-btn],
[data-hero-cta] {
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(4, 90, 205, 0.15);
  cursor: pointer;
}
