/* ══════════════════════════════════════════
   MOBILE — breakpoints responsivos
══════════════════════════════════════════ */

/* Ocultos no desktop */
.hamburger   { display: none; }
#faixa-dots  { display: none; }
#nav-overlay { display: none; }

/* ── MENU MOBILE (nav-mobile) ── */
.nav-mobile {
  position: fixed; inset: 0; z-index: 49;
  background: rgba(8,5,16,0.97); backdrop-filter: blur(20px);
  display: flex; flex-direction: column;
  padding: 96px 40px 48px;
  opacity: 0; transform: translateX(100%);
  transition: transform 0.45s cubic-bezier(0.16,1,0.3,1), opacity 0.35s ease;
  pointer-events: none; overflow-y: auto;
}
.nav-mobile.open { opacity: 1; transform: translateX(0); pointer-events: all; }
.mob-links { flex: 1; display: flex; flex-direction: column; }
.mob-link {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 1.55rem; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase;
  color: rgba(255,255,255,0.82); text-decoration: none;
  padding: 20px 0; border-bottom: 1px solid rgba(255,255,255,0.06);
  opacity: 0; transform: translateX(-22px);
  transition: color 0.25s, opacity 0.4s ease, transform 0.4s ease;
}
.mob-link:last-child { border-bottom: none; }
.mob-link:hover { color: var(--menta); }
.mob-link-cta { color: var(--menta) !important; margin-top: 8px; }
.mob-arrow { font-size: 1.2rem; color: rgba(255,255,255,0.25); transition: color 0.25s, transform 0.25s; }
.mob-link:hover .mob-arrow { color: var(--menta); transform: translateX(4px); }
.nav-mobile.open .mob-link:nth-child(1) { opacity:1; transform:none; transition-delay:0.18s; }
.nav-mobile.open .mob-link:nth-child(2) { opacity:1; transform:none; transition-delay:0.26s; }
.nav-mobile.open .mob-link:nth-child(3) { opacity:1; transform:none; transition-delay:0.34s; }
.mob-bottom { opacity: 0; transform: translateY(10px); transition: opacity 0.4s ease 0.42s, transform 0.4s ease 0.42s; }
.nav-mobile.open .mob-bottom { opacity: 1; transform: translateY(0); }
.mob-divider { height: 1px; background: linear-gradient(90deg, rgba(255,255,255,0.12), transparent); margin-bottom: 28px; }
.mob-socials { display: flex; gap: 28px; align-items: center; }
.mob-social { color: rgba(255,255,255,0.45); display: flex; transition: color 0.25s, transform 0.25s; }
.mob-social:hover { color: var(--menta); transform: translateY(-2px); }

/* ── FOOTER ── */
.site-footer {
  position: fixed; bottom: 0; left: 0; right: 0;
  z-index: 10; background: var(--preto);
  display: flex; align-items: center; justify-content: space-between;
  padding: 11px 80px;
  border-top: 1px solid rgba(255,255,255,0.06);
  opacity: 0; pointer-events: none; /* revelado pelo GSAP junto com a animação */
}
.footer-copy { font-size: 0.7rem; font-weight: 600; letter-spacing: 1px; color: rgba(255,255,255,0.28); text-transform: uppercase; }
.footer-socials { display: flex; gap: 22px; align-items: center; }
.footer-social { color: rgba(255,255,255,0.3); display: flex; transition: color 0.25s, transform 0.25s; }
.footer-social:hover { color: var(--menta); transform: translateY(-2px); }

/* Em touch, :hover fica "grudado" após swipe — reseta o estado, mas não quando active */
@media (hover: none) {
  .beat-block:hover:not(.active) {
    background: rgba(15,12,26,0.8);
    border-color: rgba(74,28,147,0.4);
    box-shadow: none;
    transform: none;
  }
  .beat-block:hover:not(.active)::before { opacity: 0; }
}

/* ── Tablet ── */
@media (max-width: 1024px) {
  .faixa { padding: 60px 40px; }
  .beats-row { gap: 8px; }
  .beat-block { width: 68px; height: 68px; }
  .beat-letter { font-size: 1.6rem; }
}

/* ══════════════════════════════════════════
   MOBILE ≤ 768px
══════════════════════════════════════════ */
@media (max-width: 768px) {

  /* ── Hero: respira abaixo da nav fixa ── */
  .hero { padding-top: 64px; }
  .sub          { margin-bottom: 28px; }
  .eq-container { margin-bottom: 24px; }

  /* ── Nav fixa no topo ── */
  nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    padding: 14px 24px;
    background: rgba(8,5,16,0.88);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    z-index: 50;
  }

  /* Footer mobile: in-flow, sempre visível (sem animação GSAP) */
  .site-footer {
    position: relative;
    flex-direction: column;
    padding: 0 20px;
    height: 50px;
    justify-content: center;
    text-align: center;
    opacity: 1; pointer-events: all;
  }
  .footer-socials { display: none; }

  /* Links ocultos por padrão; hamburger os revela */
  .nav-links {
    display: none;
    position: fixed;
    top: 58px; left: 0; right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(8,5,16,0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(65,201,166,0.15);
    padding: 8px 24px 24px;
    z-index: 50;
  }
  .nav-links.open { display: flex; }
  .nav-links li   { display: block !important; }
  .nav-links li a {
    display: block;
    padding: 16px 0;
    font-size: 1rem;
    font-weight: 600;
    border-bottom: 1px solid rgba(255,255,255,0.07);
  }
  .nav-links li:last-child a { border-bottom: none; margin-top: 8px; }
  .nav-links .cta-nav {
    display: inline-block !important;
    padding: 10px 24px !important;
    border-radius: 999px;
    text-align: center;
  }

  /* ── Overlay escurecedor do menu ── */
  #nav-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(8,5,16,0.75);
    z-index: 49;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
  }
  #nav-overlay.active {
    opacity: 1;
    pointer-events: all;
  }

  /* ── Hamburger ── */
  .hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    z-index: 51;
  }
  .hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--branco);
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
  }
  .hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
  .hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  /* ── Hero headlines ── */
  .headline-top  { font-size: clamp(1.4rem, 5vw, 2rem); }
  .headline-main { font-size: clamp(2rem, 7vw, 3.2rem); }
  .sub           { font-size: 0.9rem; padding: 0 16px; }

  /* ── EQ ── */
  .eq-container { gap: 4px; }

  /* ── Toca-discos ── */
  .turntable-wrap { width: 260px; height: 260px; }
  .tonearm-wrap   {
    top: -14px; right: -40px;
    width: 122px; height: 150px;
    transform-origin: 20px 20px;
  }

  /* ── CTAs: mesma largura mínima ── */
  .cta-group { flex-direction: column; align-items: center; gap: 12px; }
  .btn-primary,
  .btn-ghost  { padding: 14px 32px; font-size: 0.9rem; min-width: 210px; }

  /* ── Scroll hint: ligeiramente à esquerda e embaixo ── */
  .scroll-hint {
    left: calc(50% - 8px);
    transform: translateX(-50%);
    bottom: 16px;
    margin-left: 0;
  }

  /* ── DAW timeline ── */
  #daw-timeline { display: none; }

  /* ══════════════════════════════════════════
     CARROSSEL HORIZONTAL (scroll-snap)
  ══════════════════════════════════════════ */

  #pin-container {
    height: calc(100svh - 50px);
    height: calc(100dvh - 50px);
    min-height: unset;
    position: relative;
    overflow: hidden;
  }

  #sticky-inner {
    position: relative;
    top: auto;
    width: 100%;
    height: 100%;
    overflow: hidden;
  }

  #sections-wrapper {
    display: flex;
    flex-direction: row;
    width: 100%;
    height: 100%;
    overflow-x: scroll;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    transform: none !important;
    scrollbar-width: none;
  }
  #sections-wrapper::-webkit-scrollbar { display: none; }

  /* Faixas: conteúdo começa no topo para não cortar o início */
  .faixa {
    width: 100vw;
    min-width: 100vw;
    height: 100%;
    min-height: unset;
    flex-shrink: 0;
    scroll-snap-align: start;
    overflow-y: auto;
    padding: 72px 24px 64px;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
  }

  /* Faixa 7 (CTA): mantém centralizado */
  .faixa-7 { justify-content: center; }

  /* ── Faixa 1: wave removida ── */
  .faixa-1 .visual-side { display: none; }

  /* ── Faixa 2 ── */
  .faixa-2 h2 { font-size: clamp(1.8rem, 6vw, 2.6rem); margin-bottom: 16px; }
  .sintomas-grid { flex-direction: column; gap: 14px; margin-top: 20px; }
  .sintoma { flex-direction: row; align-items: center; text-align: left; gap: 12px; }
  .sintoma-icon { width: 38px; height: 38px; font-size: 1.3rem; flex-shrink: 0; border-width: 1.5px; }
  .sintoma-title { font-size: 0.75rem; white-space: nowrap; flex-shrink: 0; }
  .sintoma-desc  { font-size: 0.74rem; line-height: 1.5; }

  /* ── Faixa 3 · O Conserto ── */
  .faixa-3 .inner { max-width: 100%; }
  .conserto-quote { font-size: clamp(1.1rem, 4.5vw, 1.5rem); padding-left: 18px; max-width: 100%; }
  .conserto-source { padding-left: 0; font-size: 0.72rem; margin-bottom: 22px; }
  /* stats: um por linha, centralizados */
  .faixa-3 .stats-row {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 20px;
    width: 100%;
  }
  .faixa-3 .stat { align-items: center; flex: unset; }
  .faixa-3 .stat-num { font-size: 2.6rem; }
  .faixa-3 .stat-label { max-width: 180px; text-align: center; }

  /* ── Stats (genérico mobile) ── */
  .stats-row { gap: 16px; margin-bottom: 20px; flex-wrap: nowrap; }
  .stat-num  { font-size: 1.9rem; letter-spacing: -1px; }
  .stat-label { font-size: 0.66rem; max-width: 90px; line-height: 1.4; }

  /* ── Faixa 4 · P.A.N.C.A.D.A. ──────────────
     Grid pirâmide: PAN / CA / DA
  ────────────────────────────────────────── */
  .faixa-4 { padding-top: 72px; }

  /* Pirâmide 3+2+2 centralizada */
  .beats-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    width: 100%;
    max-width: 232px;
    margin: 0 auto 12px;
  }

  .beat-block {
    width: calc((100% - 16px) / 3);
    height: auto !important;
    aspect-ratio: 1;
    flex-shrink: 0;
  }

  /* Beats C A D A — maiores para igualar a linha de 3 */
  .beat-block:nth-child(n+4) {
    width: calc((100% - 8px) / 2);
  }

  /* Esconde labels: a descrição aparece no painel ao clicar */
  .beat-word   { display: none; }
  .beat-letter { font-size: 2.1rem; }

  /* Reset grid-column herdado */
  .beat-block:nth-child(n) { grid-column: unset; }

  /* Subtítulo da faixa 4 — reduz margem inferior */
  .faixa-4 .faixa-sub { margin-bottom: 28px; font-size: 0.82rem; }

  /* Beat panel compacto para caber na tela */
  .beat-panel        { padding: 12px 16px; min-height: 56px; }
  .beat-panel-title  { font-size: 0.66rem; margin-bottom: 5px; }
  .beat-panel-text   { font-size: 0.78rem; line-height: 1.55; }

  /* ── Faixa 5 · Cases ── */
  .faixa-5 h2 {
    font-size: clamp(1.1rem, 4vw, 1.4rem);
    margin-bottom: 22px;
  }
  .cases-grid { flex-direction: column; gap: 8px; }
  .case-card  { padding: 12px 14px; }
  .case-segment { margin-bottom: 4px; }
  .case-name  { font-size: 1rem; margin-bottom: 8px; }
  .case-waveform { height: 26px; margin-bottom: 8px; }
  .btn-ouvir  { padding: 7px 16px; font-size: 0.7rem; }
  .btn-discoteca {
    margin-top: 14px;
    padding: 11px 20px;
    font-size: 0.74rem;
    width: 100%;
    justify-content: center;
  }

  /* ── Faixa 6 · Prova social ── */
  .faixa-6 {
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
  }
  .faixa-6 .inner { gap: 20px; }
  .depoimento { padding: 18px 20px; }
  .depoimento-text { font-size: 0.87rem; line-height: 1.65; }

  /* ── Strip de logos — horizontal no mobile (animação via logos.js) ── */
  .logos-side {
    width: 100%;
    height: 48px;
    border-right: none;
    border-bottom: 1px solid rgba(65,201,166,0.08);
    padding-right: 0;
    margin-bottom: 20px;
    flex-shrink: 0;
    overflow: hidden;
    position: relative;
  }
  /* Fade esquerda/direita */
  .logos-side::before {
    top: 0; bottom: 0; left: 0; right: auto;
    width: 48px; height: 100%;
    background: linear-gradient(to right, var(--preto), transparent);
  }
  .logos-side::after {
    top: 0; bottom: 0; right: 0; left: auto;
    width: 48px; height: 100%;
    background: linear-gradient(to left, var(--preto), transparent);
  }
  /* track horizontal: width:max-content garante que -50% = exatamente 1 set de logos */
  .logos-track {
    flex-direction: row;
    flex-wrap: nowrap;
    width: max-content;
    align-items: center;
    gap: 40px;
    height: 100%;
    will-change: transform;
  }
  .logo-item {
    width: auto;
    min-width: 80px;
    max-width: 120px;
    height: 32px;
    flex-shrink: 0;
  }
  .logo-item img {
    width: auto;
    height: 100%;
    max-width: 120px;
    object-fit: contain;
  }
  .logo-item span {
    font-size: 0.55rem;
    letter-spacing: 1.5px;
    white-space: nowrap;
  }

  /* ── Faixa 6 · CTA ── */
  .btn-cta-final { padding: 16px 40px; font-size: 0.95rem; }

  /* ── Número decorativo ── */
  .faixa-num { font-size: 4rem; }

  /* ── Dots de navegação ── */
  #faixa-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    position: absolute;
    bottom: 14px;
    left: 0; right: 0;
    z-index: 10;
    pointer-events: none;
  }
  .faixa-dot {
    width: 6px;
    height: 6px;
    border-radius: 3px;
    background: rgba(255,255,255,0.2);
    border: none;
    cursor: pointer;
    padding: 0;
    pointer-events: all;
    transition: background 0.3s ease, width 0.3s ease;
  }
  .faixa-dot.active {
    background: var(--menta);
    width: 18px;
  }
}

/* ── Wider mobile (≥ 400px) — telas como Samsung A52s ──
   Esses phones têm viewport CSS ~393–430px e DPR alto.
   Escala turntable/tonearm proporcionalmente (~79% do desktop).
────────────────────────────────────────────────────────── */
@media (min-width: 400px) and (max-width: 767px) {
  .turntable-wrap { width: 300px; height: 300px; }
  .tonearm-wrap   {
    top: -16px; right: -44px;
    width: 142px; height: 175px;
    transform-origin: 22px 22px;
  }
  .faixa { padding: 72px 28px 64px; }
  .btn-primary,
  .btn-ghost  { min-width: 240px; }
  .beats-row  { max-width: 268px; }
}

/* ── Small mobile ≤ 380px — telefones muito pequenos ── */
@media (max-width: 380px) {
  nav { padding: 12px 20px; }
  .nav-links { top: 54px; }
  .hero { padding-top: 56px; }
  .hero-content { padding: 0 16px; }
  .turntable-wrap { width: 220px; height: 220px; }
  .tonearm-wrap   {
    top: -12px; right: -34px;
    width: 104px; height: 128px;
    transform-origin: 17px 17px;
  }
  .faixa { padding: 64px 20px 64px; }
  .faixa-3 h2 { font-size: clamp(2.4rem, 8vw, 3.6rem); }
  .beats-row                 { gap: 6px; max-width: 200px; }
  .beat-block                { width: calc((100% - 12px) / 3); }
  .beat-block:nth-child(n+4) { width: calc((100% - 6px) / 2); }
  .beat-letter               { font-size: 1.85rem; }
}
