/* =========================================================
   GLUB — ATIVIDADE 2
   Estilos específicos. O HUD continua usando tarefa1.css
   para manter o mesmo padrão em todas as etapas.
   ========================================================= */
#tarefa2-tela{position:absolute;inset:0;width:100%;height:100%;overflow:hidden;display:none;z-index:180;background:#071522}
#tarefa2-tela .tarefa1-hud{z-index:32;pointer-events:none}
#tarefa2-tela .tarefa1-hud-controles,
#tarefa2-tela .tarefa1-hud-botao{pointer-events:auto}
#tarefa2-tela .at2-logo-fixo{z-index:34!important}
#tarefa2-tela .tarefa1-pista-acerola{z-index:40!important}

/* O sprite do avatar possui transparência inferior; o deslocamento visual aproxima
   os pés da madeira sem alterar a superfície física da colisão. */
#tarefa2-tela .tarefa2-avatar img{position:relative;top:10px}

/* Siri lançador: gira o conjunto para as garras ficarem voltadas para cima. */
#tarefa2-tela .tarefa2-siri-lancador{
  transform:rotate(-90deg);
  transform-origin:50% 50%;
  pointer-events:none;
}

/* Máscara visual e interativa uniforme das três figuras. */
#tarefa2-tela .tarefa2-trio{pointer-events:auto}
#tarefa2-tela .tarefa2-figura{
  box-sizing:border-box;
  overflow:hidden;
  touch-action:manipulation;
}
#tarefa2-tela .tarefa2-figura-img{
  display:block;width:100%;height:100%;object-fit:contain;pointer-events:none;
}

/* Vegetação de primeiro plano: sempre acima do jogador, sem bloquear controles. */
#tarefa2-tela .tarefa2-vegetacao-frente{z-index:8!important;pointer-events:none}

#tarefa2-tela .tarefa2-salvo-ok{
  filter:drop-shadow(0 0 9px #fff) drop-shadow(0 0 12px #38d66b)!important;
  transform:scale(1.08);
}

/* =========================================================
   VIDA MARINHA — ATIVIDADE 2
   GIFs em camada de cenário, sem colisão.
   ========================================================= */
#tarefa2-tela .at2-animal-marinho{
  position:absolute;
  height:auto;
  pointer-events:none;
  will-change:transform;
  filter:drop-shadow(0 2px 2px #0018);
}

#tarefa2-tela .at2-marinho-direita{
  left:-190px;
  animation-name:at2MarinhoDireita;
  animation-timing-function:linear;
  animation-iteration-count:infinite;
}

#tarefa2-tela .at2-marinho-esquerda{
  left:1320px;
  animation-name:at2MarinhoEsquerda;
  animation-timing-function:linear;
  animation-iteration-count:infinite;
}

@keyframes at2MarinhoDireita{
  0%{transform:translateX(0) translateY(0)}
  25%{transform:translateX(375px) translateY(-6px)}
  50%{transform:translateX(750px) translateY(4px)}
  75%{transform:translateX(1125px) translateY(-4px)}
  100%{transform:translateX(1510px) translateY(0)}
}

@keyframes at2MarinhoEsquerda{
  0%{transform:translateX(0) translateY(0)}
  25%{transform:translateX(-375px) translateY(5px)}
  50%{transform:translateX(-750px) translateY(-5px)}
  75%{transform:translateX(-1125px) translateY(4px)}
  100%{transform:translateX(-1510px) translateY(0)}
}

/* Cavalos-marinhos permanecem numa área, flutuando suavemente. */
#tarefa2-tela .at2-marinho-vertical{
  animation-name:at2CavaloMarinho;
  animation-timing-function:ease-in-out;
  animation-iteration-count:infinite;
  animation-direction:alternate;
}
@keyframes at2CavaloMarinho{
  0%{transform:translate(0,12px) rotate(-2deg)}
  50%{transform:translate(12px,-12px) rotate(2deg)}
  100%{transform:translate(-8px,8px) rotate(-1deg)}
}
/* =========================================
   NAVIO PIRATA — FLUTUAÇÃO SUAVE
   ========================================= */

#tarefa2-tela .at2-navio-flutuante {
    animation: at2NavioFlutuando 5s ease-in-out infinite;
    transform-origin: 50% 78%;
    will-change: transform;
}

@keyframes at2NavioFlutuando {
    0%, 100% {
        transform: translateY(0px) rotate(-1.5deg);
    }

    50% {
        transform: translateY(-5px) rotate(1.5deg);
    }
}