/**
 * Header unificado – OrquestraShop
 * Estilo refinado: desktop com barra centralizada, nav limpo, mobile consistente
 */

/* ========== Base / Desktop (≥ 992px) ========== */
.dtr-responsive-header,
.dtr-responsive-header .container,
#dtr-menu-button,
.slicknav_menu {
  display: none;
}

#dtr-main-content {
  padding-top: 76px;
}

#dtr-main-content .hero-section-top-padding {
  padding-top: 24px;
}

#dtr-header-global {
  display: block;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 0;
  min-height: 72px;
  background: #ffffff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  z-index: 9999;
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

#dtr-header-global.scrolled {
  border-bottom-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

#dtr-header-global .container {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding-left: clamp(16px, 3vw, 28px);
  padding-right: clamp(16px, 3vw, 28px);
  box-sizing: border-box;
}

/* Grid: logo colada à esquerda da coluna, menu no centro real da barra, CTAs à direita */
#dtr-header-global .header-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  column-gap: clamp(12px, 2vw, 28px);
  width: 100%;
  min-width: 0;
  min-height: 72px;
}

.dtr-header-left {
  min-width: 0;
  max-width: 100%;
  justify-self: start;
  text-align: left;
  width: max-content;
}

.dtr-header-left a {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  width: max-content;
  transition: opacity 0.2s ease;
}

.dtr-header-left a:hover {
  opacity: 0.85;
}

.dtr-header-left img {
  max-width: 100%;
  height: auto;
  max-height: 64px;
  width: auto;
  display: block;
}

#dtr-header-global.scrolled .dtr-header-left img {
  max-height: 56px;
}

/* Navegação central (coluna do meio do grid) */
#dtr-header-global .main-navigation {
  justify-self: center;
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: visible;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  display: flex;
  justify-content: center;
  margin: 0;
  width: max-content;
}

#dtr-header-global .main-navigation::-webkit-scrollbar {
  display: none;
}

.main-navigation .navbar-nav {
  display: flex;
  flex-wrap: nowrap;
  flex-direction: row;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
  align-items: center;
  justify-content: center;
  min-width: 0;
  width: auto;
}

.main-navigation .nav-item {
  flex-shrink: 0;
}

.main-navigation .nav-link {
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: #475569;
  border-radius: 8px;
  transition: color 0.2s ease, background 0.2s ease;
  display: block;
  text-decoration: none;
  white-space: nowrap;
}

.main-navigation .nav-link:hover {
  color: #00b494;
  background: rgba(0, 180, 148, 0.08);
  text-decoration: none;
}

.main-navigation .nav-link.active {
  color: #00b494;
  font-weight: 600;
  background: rgba(0, 180, 148, 0.1);
}

/* CTAs do header */
#dtr-header-global .header-buttons {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

/* Sobrepõe style.css (logo 360px fixo): escala responsiva e ancora à esquerda */
#dtr-header-global .logo-default,
#dtr-header-global .logo-alt {
  width: auto;
  max-width: 100%;
}

#dtr-header-global .logo-default img,
#dtr-header-global .logo-alt img {
  width: auto;
  max-width: min(360px, 100%);
  height: auto;
  display: block;
}

@media (max-width: 1199.98px) {
  #dtr-header-global .logo-default img,
  #dtr-header-global .logo-alt img {
    max-width: min(300px, 48vw);
  }
}

@media (min-width: 992px) and (max-width: 1060px) {
  #dtr-header-global .logo-default img,
  #dtr-header-global .logo-alt img {
    max-width: min(240px, 42vw);
  }
}

#dtr-header-global .header-buttons .dtr-btn,
.dtr-responsive-header .header-ctas-inline .dtr-btn,
.dtr-responsive-header .dtr-responsive-header-ctas .dtr-btn {
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 8px;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  white-space: nowrap;
  text-decoration: none;
  display: inline-block;
}

#dtr-header-global .header-buttons .btn-grey,
.dtr-responsive-header .header-ctas-inline .btn-grey,
.dtr-responsive-header .dtr-responsive-header-ctas .btn-grey {
  background: #f1f5f9 !important;
  border: 1px solid #e2e8f0 !important;
  color: #334155 !important;
  box-shadow: none !important;
}

#dtr-header-global .header-buttons .btn-grey:hover,
.dtr-responsive-header .header-ctas-inline .btn-grey:hover,
.dtr-responsive-header .dtr-responsive-header-ctas .btn-grey:hover {
  background: #e2e8f0 !important;
  border-color: #cbd5e1 !important;
  color: #334155 !important;
  transform: translateY(-1px);
}

@media (max-width: 1200px) {
  .main-navigation .nav-link {
    padding: 8px 12px;
    font-size: 13px;
  }
  #dtr-header-global .header-buttons .dtr-btn,
  .dtr-responsive-header .header-ctas-inline .dtr-btn {
    padding: 9px 16px;
    font-size: 13px;
  }
}

/* ========== Mobile (< 992px) ========== */
@media (max-width: 991.98px) {
  #dtr-header-global {
    display: none !important;
  }

  #dtr-main-content {
    padding-top: 60px;
  }

  #dtr-main-content .hero-section-top-padding {
    padding-top: 20px;
  }

  .dtr-responsive-header {
    display: flex !important;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    align-items: center;
    padding: 12px 20px;
    min-height: 60px;
    background: #ffffff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    z-index: 9999;
    transition: box-shadow 0.2s ease;
  }

  .dtr-responsive-header .container {
    display: flex !important;
    flex: 1;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    max-width: 100%;
    padding: 0;
    min-width: 0;
  }

  /* Logo à esquerda; hamburger + CTAs agrupados à direita */
  .dtr-responsive-header .container > a:first-of-type {
    margin-right: auto;
  }

  .dtr-responsive-header .container > a {
    order: 1;
    flex-shrink: 0;
    min-width: 0;
  }
  .dtr-responsive-header .container > #dtr-menu-button {
    order: 2;
  }
  .dtr-responsive-header .container > .header-ctas-inline {
    order: 3;
  }

  .dtr-responsive-header .container > a img {
    max-height: 48px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
  }

  #dtr-menu-button {
    display: flex !important;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    padding: 0;
    margin: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.2s ease;
    position: static !important;
    top: auto !important;
    right: auto !important;
    left: auto !important;
  }

  #dtr-menu-button:hover {
    background: rgba(0, 0, 0, 0.05);
  }

  .dtr-responsive-header .header-ctas-inline {
    display: flex !important;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
  }

  .dtr-responsive-header .header-ctas-inline .dtr-btn {
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    white-space: nowrap;
  }

  .dtr-responsive-header .header-ctas-inline .btn-green {
    background: #00b494;
    border: 1px solid #00b494;
    color: #fff;
  }

  .dtr-responsive-header .header-ctas-inline .btn-grey {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    color: #334155;
  }

  /* Painel do menu mobile */
  .dtr-responsive-header-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    max-height: calc(100vh - 60px);
    overflow-y: auto;
    z-index: 9997;
  }

  .dtr-responsive-header.mobile-menu-open .dtr-responsive-header-menu {
    display: block;
  }

  .slicknav_menu {
    display: block !important;
    position: static !important;
    background: transparent !important;
    padding: 0 !important;
  }

  .slicknav_nav {
    position: static !important;
    padding: 16px 20px !important;
    border: none !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 2px !important;
  }

  .slicknav_nav a {
    padding: 12px 16px !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    color: #334155 !important;
    border-radius: 8px !important;
    border: none !important;
    display: block !important;
    transition: background 0.2s ease, color 0.2s ease;
  }

  .slicknav_nav a:hover {
    background: rgba(0, 180, 148, 0.1) !important;
    color: #00b494 !important;
  }

  .slicknav_nav li {
    border: none !important;
    margin: 0 !important;
  }

  .dtr-responsive-header-ctas {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 16px 20px 24px;
    border-top: 1px solid #f1f5f9;
    background: #fafbfc;
  }

  .dtr-responsive-header-ctas .dtr-btn {
    width: 100%;
    text-align: center;
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    display: block;
  }

  .dtr-responsive-header-ctas .btn-green {
    background: #00b494;
    border: 1px solid #00b494;
    color: #fff;
  }

  .dtr-responsive-header-ctas .btn-grey {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    color: #334155;
  }
}

@media (min-width: 992px) {
  #dtr-header-global {
    display: block !important;
  }
  .dtr-responsive-header,
  .dtr-responsive-header-menu .slicknav_menu {
    display: none !important;
  }
}

.dtr-responsive-header .header-ctas-inline {
  display: none;
}

/* Páginas internas: padding-top do conteúdo */
.welcome-page,
.terms-page {
  padding-top: 100px !important;
}

@media (max-width: 991.98px) {
  .welcome-page,
  .terms-page {
    padding-top: 84px !important;
  }
}

@media (max-width: 575.98px) {
  .welcome-page,
  .terms-page {
    padding-top: 76px !important;
  }
}
