/* ============================================================================
 * FOLHA DE ESTILOS PRINCIPAL
 * Projeto: Desafio de Palavras
 * ============================================================================ */


/*--------------------------------------------------------------------------*/
/* ESTILOS GERAIS E DE BASE
/*--------------------------------------------------------------------------*/
html {
    overflow-y: scroll;
}

body {
    font-family: 'Montserrat', 'Trebuchet MS', sans-serif;
    color: #ffffff;
    line-height: 1.6;
    margin: 0;
    
    background-image: 
        linear-gradient(rgba(15, 15, 25, 0.50), rgba(15, 15, 25, 0.50)),
        url('/imagens/fundo.webp'); 
    background-size: cover;
    background-position: center 20%;
    background-attachment: fixed;
    
    display: flex;
    flex-direction: column; 
    align-items: center;
    padding: 20px;
    min-height: 100vh;
}

/*--------------------------------------------------------------------------*/
/* LAYOUT PRINCIPAL E CABEÇALHO
/*--------------------------------------------------------------------------*/
header {
    max-width: 800px;
    width: 100%;
    padding: 0 40px;
    box-sizing: border-box;
    background-color: rgba(255, 255, 255, 0.15); 
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

main {
    background-color: rgba(10, 10, 25, 0.75);
    max-width: 800px;
    width: 100%;
    padding: 30px 40px 100px;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.15);
    margin-top: 100px;
    margin-bottom: 100px;
}

/*--------------------------------------------------------------------------*/
/* ESTILOS DE TEXTO E LOGO
/*--------------------------------------------------------------------------*/

header h1 {
    display: inline-block;
    font-family: 'Trebuchet MS', 'Montserrat', sans-serif;
    font-size: 5em;
    font-weight: bold;
    color: #ffffff;
    text-shadow: 3px 3px 10px rgba(0,0,0,0.8);
    margin: 20px 0 0 0;
    padding: 0;
    line-height: 1;
    text-align: left;
}

header h1 .titulo-vermelho {
    color: #c90303;
    font-family: inherit;
}

.slogan-container {
    display: flex;
    align-items: center;
    margin-top: 15px;
    margin-bottom: 20px;
}

.slogan-container i {
    font-size: 1.1em;
    color: #1b1b1a;
    margin-right: 5px;
    vertical-align: middle;
}

.slogan-container .slogan {
    font-family: 'Trebuchet MS', 'Montserrat', sans-serif;
    font-size: 0.70em;
    font-weight: normal;
    color: rgba(255, 255, 255, 0.7);
    text-shadow: 1px 1px 5px rgba(0,0,0,0.5);
    font-style: italic;
    quotes: """ """ "'" "'";
}

.slogan-container .slogan::before {
    content: open-quote;
    font-family: Arial, sans-serif;
    font-size: 1.2em;
    font-weight: bold;
    color: #fff;
    vertical-align: sub;
    margin-right: 5px;
}

.slogan-container .slogan::after {
    content: close-quote;
    font-family: Arial, sans-serif;
    font-size: 1.2em;
    font-weight: bold;
    color: #fff;
    vertical-align: sub;
    margin-left: 5px;
}

#selecao-jogo h2 {
    font-weight: normal;
    font-size: 1.2em;
    text-align: left;
    padding-left: 10px;
    margin-bottom: 20px;
    color: #ccc;
}

/*--------------------------------------------------------------------------*/
/* ÁREA DE JOGO E CONTROLOS
/*--------------------------------------------------------------------------*/
.escondido {
    display: none !important;
}

#botoes-jogos {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
    margin-top: 20px;
}

#botoes-jogos button {
    padding: 15px;
    font-size: 13px;
    font-weight: normal;
    color: #ffffff;
    background-color: transparent;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 6px;
    cursor: pointer;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    white-space: normal;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 60px;
    text-transform: none;
}

#botoes-jogos button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.8);
}

#display-texto {
    background-color: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 15px;
    margin-top: 15px;
    border-radius: 6px;
    min-height: 150px;
    font-family: "Courier New", Courier, monospace;
    white-space: pre-wrap;
    word-wrap: break-word;
    color: #f1f1f1;
}

#botao-voltar {
    padding: 12px 25px;
    border: none;
    border-radius: 6px;
    color: white;
    background-color: #6c757d;
}

#botao-voltar:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.4);
}

/* Linha com "Voltar à Seleção" + "Exportar Texto" lado a lado */
#botoes-area-jogo {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: stretch;
}

#botao-exportar-texto {
    padding: 12px 25px;
    border: none;
    border-radius: 6px;
    color: white;
    background-color: #1f7a5c;
    cursor: pointer;
    transition: all 0.2s ease;
}

#botao-exportar-texto i {
    margin-right: 6px;
}

#botao-exportar-texto:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.4);
}

/* Telemóveis estreitos: os dois botões dividem a largura */
@media (max-width: 480px) {
    #botoes-area-jogo button {
        flex: 1 1 0;
        padding: 12px 10px;
    }
}

#area-feedback {
    margin-top: 20px;
    padding: 20px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

#mensagem-feedback {
    text-align: center;
    font-weight: bold;
    min-height: 24px;
    font-size: 1.1em;
    margin: 0;
}

/* ============================================================================
 * BARRA DE INPUT FIXA NO FUNDO (OTIMIZADA)
 * ============================================================================ */

#barra-input-fixa {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, rgba(15, 15, 25, 0.97) 0%, rgba(10, 10, 20, 0.98) 100%);
    border-top: 2px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.5);
    z-index: 1000;
    padding: 15px 20px;
    backdrop-filter: blur(10px);
}

.barra-conteudo {
    max-width: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
}

.barra-input-grupo {
    display: flex;
    align-items: center;
    gap: 8px;
}

.barra-input-grupo label {
    font-size: 14px;
    color: #ccc;
    white-space: nowrap;
    font-weight: 500;
}

#barra-input-posicao {
    flex-shrink: 0;
}

.barra-palavra-grupo {
    flex-shrink: 0;
    width: 350px;
}

#barra-posicao {
    width: 55px;
    padding: 12px 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    background-color: rgba(50, 50, 60, 0.8);
    color: #fff;
    font-size: 16px;
    text-align: center;
    transition: all 0.3s ease;
}

#barra-palavra {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    background-color: rgba(50, 50, 60, 0.8);
    color: #fff;
    font-size: 16px;
    transition: all 0.3s ease;
}

#barra-posicao:focus,
#barra-palavra:focus {
    outline: none;
    border-color: #ff0000;
    background-color: rgba(60, 60, 70, 0.9);
    box-shadow: 0 0 0 3px rgba(255, 0, 0, 0.1);
}

#barra-botao-enviar {
    padding: 12px 20px;
    border: none;
    border-radius: 6px;
    color: white;
    background: linear-gradient(135deg, #ff0000 0%, #cc0000 100%);
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    text-transform: uppercase;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(255, 0, 0, 0.3);
    flex-shrink: 0;
}

#barra-botao-enviar:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 0, 0, 0.5);
    background: linear-gradient(135deg, #ff2222 0%, #dd0000 100%);
}

#barra-botao-enviar:active {
    transform: translateY(0);
}

#barra-botao-enviar i {
    font-size: 14px;
}

/* Botão de Toggle de Som */
.botao-som {
    padding: 12px 15px;
    border: none;
    border-radius: 6px;
    color: white;
    background: rgba(255, 255, 255, 0.15);
    cursor: pointer;
    font-size: 18px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    min-width: 50px;
}

.botao-som:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

.botao-som:active {
    transform: translateY(0);
}

.botao-som.desativado {
    background: rgba(150, 150, 150, 0.3);
    color: rgba(255, 255, 255, 0.5);
}

.botao-som.desativado:hover {
    background: rgba(150, 150, 150, 0.4);
}

/* ============================================================================
 * TOAST NOTIFICATION (FEEDBACK VISUAL)
 * ============================================================================ */

#toast-notification {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    background: linear-gradient(135deg, #2d2d44 0%, #1a1a2e 100%);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 15px;
    padding: 25px 35px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    z-index: 10000;
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    max-width: 90%;
    min-width: 300px;
}

#toast-notification.toast-visivel {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

#toast-notification.toast-escondido {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
    pointer-events: none;
}

.toast-conteudo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.toast-icone {
    font-size: 40px;
    flex-shrink: 0;
    animation: toastBounce 0.6s ease-out;
}

.toast-mensagem {
    color: #fff;
    font-size: 18px;
    font-weight: bold;
    line-height: 1.4;
    text-align: left;
}

@keyframes toastBounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

/* ============================================================================
 * TOAST SORTEIO (SEPARADO)
 * ============================================================================ */

.toast-sorteio {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: linear-gradient(135deg, #2d2d44 0%, #1a1a2e 100%);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 15px;
    padding: 16px 35px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    z-index: 9998;
    opacity: 0;
    pointer-events: none;
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    max-width: 80%;
    width: 500px;
    color: #fff;
    text-align: center;
    font-size: 16px;
    font-weight: bold;
    line-height: 1.4;
    white-space: pre-line;
}

.toast-sorteio.toast-visivel {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.toast-sorteio.toast-escondido {
    opacity: 0;
    transform: translateX(-50%) translateY(100px);
    pointer-events: none;
}

.sorteio-frase-azul {
    color: #4a9eff;
}

#aviso-password-container {
    background: #ff4444 !important;
    color: white !important;
    padding: 15px !important;
    border-radius: 10px !important;
    box-shadow: 0 4px 12px rgba(255, 68, 68, 0.3) !important;
}

#aviso-password-container p {
    color: white !important;
}

/* ============================================ */
/* ÍCONES SOCIAIS E MÚSICA                     */
/* ============================================ */

.icones-social {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 18px;
    margin: 25px auto;
    padding: 15px 0;
    flex-wrap: wrap;
}

/* Reduzir margem superior para a fila de música */
.icones-musica {
    margin-top: 10px;
}

.icone-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.25);
    font-size: 26px;
    color: white;
}

.icone-link:hover {
    transform: scale(1.2) translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.35);
}

.icone-link:active {
    transform: scale(1.1);
}

/* Cores específicas de cada plataforma */
.icone-link.spotify {
    background: #1DB954;
}

.icone-link.spotify:hover {
    box-shadow: 0 8px 25px rgba(29, 185, 84, 0.7);
}

.icone-link.youtube {
    background: #FF0000;
} 

.icone-link.youtube:hover {
    box-shadow: 0 8px 25px rgba(255, 0, 0, 0.7);
}

.icone-link.facebook {
    background: #1877F2;
}

.icone-link.facebook:hover {
    box-shadow: 0 8px 25px rgba(24, 119, 242, 0.7);
}

.icone-link.instagram {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
}

.icone-link.instagram:hover {
    box-shadow: 0 8px 25px rgba(225, 48, 108, 0.7);
}

.icone-link.telegram {
    background: #0088cc;
}

.icone-link.telegram:hover {
    box-shadow: 0 8px 25px rgba(0, 136, 204, 0.7);
}

.icone-link.whatsapp {
    background: #25D366;
}

.icone-link.whatsapp:hover {
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.7);
}

.icone-link.tiktok {
    background: linear-gradient(45deg, #ff0050, #00f2ea);
}

.icone-link.tiktok:hover {
    box-shadow: 0 8px 25px rgba(255, 0, 80, 0.7);
}

.icone-link.reddit {
    background: #FF4500;
}
.icone-link.reddit:hover {
    box-shadow: 0 8px 25px rgba(255, 69, 0, 0.7);
}

/* ============================================ */
/* LINKS LEGAIS - DENTRO DA SECÇÃO DE JOGOS   */
/* ============================================ */

.links-legais {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin: 30px auto 20px;
    padding: 12px 15px;
    background: rgba(128, 128, 128, 0.15);
    border-radius: 8px;
}

.links-legais a {
    color: white;
    text-decoration: none;
    font-size: 0.7rem;
    padding: 4px 6px;
    transition: color 0.3s ease;
}

.links-legais a:hover {
    color: #FFD700;
}

.separador-legal {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.65rem;
}

/* ============================================ */
/* FOOTER - APENAS FRASE                       */
/* ============================================ */

footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

footer p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.8rem;
    margin: 0 0 8px 0;
    font-style: italic;
    line-height: 1.4;
}

footer .versao {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.7rem;
    margin: 0;
    font-style: normal;
}

/* ============================================================================
 * REGRAS PARA ECRÃS PEQUENOS (DESIGN RESPONSIVO)
 * ============================================================================ */

/* Tablets */
@media (max-width: 768px) {
    header {
        padding: 20px 15px;
    }
    
    header h1 {
        font-size: 3.5em; 
        text-align: center;
        display: block;
    }
    
    header h1 .slogan {
        text-align: center;
    }

    #selecao-jogo h2 {
        text-align: center;
        padding-left: 0;
    }

    #botoes-jogos {
        grid-template-columns: repeat(2, 1fr);
    }
    
    main {
        padding: 20px 15px; 
    }
    
    #barra-input-fixa {
        padding: 12px 15px;
    }
    
    .barra-conteudo {
        gap: 10px;
    }
    
    .barra-palavra-grupo {
        width: 280px;
    }
    
    #barra-posicao {
        width: 50px;
        padding: 10px 8px;
        font-size: 15px;
    }
    
    #barra-palavra {
        padding: 10px 12px;
        font-size: 15px;
    }
    
    #barra-botao-enviar {
        padding: 10px 16px;
        font-size: 14px;
    }
    
    .barra-input-grupo label {
        font-size: 13px;
    }
    
    .toast-sorteio {
        max-width: 85%;
        width: auto;
        padding: 14px 30px;
        font-size: 15px;
        bottom: 90px;
    }
    
    .icones-social {
        gap: 16px;
    }
    
    .icone-link {
        width: 52px;
        height: 52px;
        font-size: 24px;
    }
}

/* Telemóveis */
@media (max-width: 600px) {
    .icones-social {
        gap: 8px;
        padding: 12px 5px;
        margin: 20px auto;
        flex-wrap: nowrap;
        overflow-x: auto;
    }
    
    .icone-link {
        width: 42px;
        height: 42px;
        font-size: 20px;
        flex-shrink: 0;
    }
    
    .links-legais {
        padding: 12px 15px;
        gap: 8px;
    }
    
    .links-legais a {
        font-size: 0.65rem;
        padding: 4px 6px;
    }
    
    .separador-legal {
        font-size: 0.6rem;
    }
    
    footer p {
        font-size: 0.75rem;
        padding: 0 10px;
    }
    
    footer .versao {
        font-size: 0.65rem;
    }
}

@media (max-width: 480px) {
    #barra-input-fixa {
        padding: 10px 8px;
    }
    
    .barra-conteudo {
        gap: 8px;
        flex-wrap: nowrap;
    }
    
    #barra-input-posicao {
        flex-shrink: 0;
    }
    
    .barra-palavra-grupo {
        flex: 1;
        min-width: 0;
    }
    
    #barra-posicao {
        width: 45px;
        padding: 10px 6px;
        font-size: 16px;
    }
    
    #barra-palavra {
        width: 100%;
        padding: 10px 12px;
        font-size: 16px;
    }
    
    #barra-botao-enviar {
        padding: 10px 12px;
        font-size: 14px;
        flex-shrink: 0;
        width: auto;
    }
    
    .botao-som {
        padding: 10px 12px;
        font-size: 16px;
        min-width: 45px;
    }
    
    .barra-input-grupo label {
        font-size: 12px;
    }
    
    #toast-notification {
        min-width: 0;
        max-width: 85%;
        padding: 20px 25px;
    }
    
    .toast-conteudo {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }
    
    .toast-icone {
        font-size: 45px;
    }
    
    .toast-mensagem {
        font-size: 15px;
        text-align: center;
        line-height: 1.5;
    }
    
    .toast-sorteio {
        max-width: 90%;
        width: auto;
        padding: 12px 20px;
        font-size: 14px;
        bottom: 80px;
    }
}

/* Telemóveis muito pequenos (iPhone SE, etc) */
@media (max-width: 380px) {
    .icones-social {
        gap: 6px;
        padding: 12px 3px;
    }
    
    .icone-link {
        width: 38px;
        height: 38px;
        font-size: 18px;
    }
    
    .links-legais a {
        font-size: 0.6rem;
    }
    
    footer p {
        font-size: 0.7rem;
    }
    
    footer .versao {
        font-size: 0.6rem;
    }
}

/* ============================================================================
   MODAL PASSWORD - ESTILOS BÁSICOS
   ============================================================================ */

/* NOTA: O modal-password é criado dinamicamente com inline styles no JavaScript.
   Os estilos abaixo (.modal-overlay e .modal-password-box) NÃO são usados
   porque essas classes não existem no código JavaScript.
   Comentados para evitar conflitos. */

/*
#modal-password .modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;  
  height: 100vh; 
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  margin: 0;
  z-index: 10000;
  animation: fadeIn 0.2s ease;
}

#modal-password .modal-password-box {
  background: white;
  padding: 35px;
  border-radius: 15px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  max-width: 400px;
  width: 90%;
  animation: slideUp 0.3s ease;
}
*/

/* 📱 MOBILE: Estilos para o input password */
@media (max-width: 768px) {
  #modal-password #input-password {
    font-size: 16px; /* Evita zoom no iOS */
  }
}

#modal-password h3 {
  margin: 0 0 20px 0;
  color: #1f2937;
  font-size: 22px;
  text-align: center;
  font-weight: 600;
}

#modal-password p {
  color: #6b7280;
  margin: 10px 0;
  text-align: center;
  font-size: 14px;
}

#modal-password strong {
  color: #667eea;
  font-size: 16px;
  font-weight: 600;
}

#modal-password #input-password {
  width: 100%;
  padding: 14px 16px;
  margin: 20px 0;
  border: 2px solid #e5e7eb;
  border-radius: 10px;
  font-size: 15px;
  box-sizing: border-box;
  background: white;
  outline: none;
  transition: all 0.2s;
  font-family: inherit;
}

#modal-password #input-password:focus {
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

#modal-password .modal-buttons {
  display: flex;
  gap: 12px;
  margin-top: 25px;
}

#modal-password .btn-primary {
  flex: 1;
  padding: 14px;
  background: #667eea;
  color: white;
  border: none;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}

#modal-password .btn-primary:hover {
  background: #5568d3;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

#modal-password .btn-primary:active {
  transform: translateY(0);
}

#modal-password .btn-secondary {
  flex: 1;
  padding: 14px;
  background: white;
  color: #6b7280;
  border: 2px solid #e5e7eb;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}

#modal-password .btn-secondary:hover {
  background: #f9fafb;
  border-color: #d1d5db;
  transform: translateY(-1px);
}

#modal-password .btn-secondary:active {
  transform: translateY(0);
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================================
   TOAST DE ERRO
   ============================================================================ */

#toast-erro {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  z-index: 11000;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

#toast-erro.show {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}

#toast-erro .toast-content {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  color: white;
  padding: 16px 24px;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(239, 68, 68, 0.4);
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 280px;
  max-width: 90vw;
}

#toast-erro .toast-icon {
  font-size: 24px;
  flex-shrink: 0;
}

#toast-erro .toast-message {
  font-size: 15px;
  font-weight: 600;
  flex: 1;
}

/* Mobile */
@media (max-width: 768px) {
  #toast-erro {
    top: 50%;
    left: 50%;
    right: auto;
    transform: translate(-50%, -50%) scale(0.8);
    width: 90%;
  }
  
  #toast-erro.show {
    transform: translate(-50%, -50%) scale(1);
  }
  
  #toast-erro .toast-content {
    min-width: auto;
    width: 100%;
  }
}

/* ========================================= */
/* 📬 INBOX - CAIXA DE CORREIO              */
/* ========================================= */

/* Botão Inbox */
.inbox-button {
  position: fixed;
  top: 20px;
  right: 20px;
  background: linear-gradient(135deg, #FF8C00 0%, #FF6B00 100%);
  color: white;
  border: none;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  font-size: 26px;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(255, 140, 0, 0.4);
  transition: all 0.3s ease;
  z-index: 999;
  animation: pulse 2s infinite;
}

.inbox-button:hover {
  transform: scale(1.15);
  box-shadow: 0 6px 25px rgba(255, 140, 0, 0.6);
}

@keyframes pulse {
  0%, 100% {
    box-shadow: 0 4px 20px rgba(255, 140, 0, 0.4);
  }
  50% {
    box-shadow: 0 4px 30px rgba(255, 140, 0, 0.7);
  }
}

.inbox-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background: #ff4444;
  color: white;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  font-size: 12px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid white;
}

/* Modal Inbox */
.inbox-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 20px;
}

.inbox-modal.active {
  display: flex;
}

.inbox-content {
  background: white;
  border-radius: 20px;
  width: 100%;
  max-width: 600px;
  max-height: 80vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.inbox-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.inbox-header h2 {
  margin: 0;
  font-size: 24px;
}

.inbox-close {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: white;
  font-size: 24px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.3s;
}

.inbox-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

.inbox-messages {
  overflow-y: auto;
  padding: 20px;
  flex: 1;
}

.inbox-message {
  background: #f8f9fa;
  border-radius: 12px;
  padding: 15px;
  margin-bottom: 15px;
  border-left: 4px solid #667eea;
  transition: transform 0.2s;
}

.inbox-message:hover {
  transform: translateX(5px);
}

.inbox-message.unread {
  background: #e3f2fd;
  border-left-color: #2196F3;
  font-weight: 500;
}

.inbox-message-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  align-items: center;
}

.inbox-message-from {
  font-weight: bold;
  color: #667eea;
}

.inbox-message-date {
  color: #999;
  font-size: 12px;
}

.inbox-message-subject {
  font-weight: bold;
  margin-bottom: 8px;
  color: #333;
}

.inbox-message-body {
  color: #666;
  line-height: 1.5;
}

.inbox-message-actions {
  margin-top: 10px;
  display: flex;
  gap: 10px;
}

.inbox-delete-btn {
  background: #ff4444;
  color: white;
  border: none;
  padding: 5px 15px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 12px;
  transition: background 0.3s;
}

.inbox-delete-btn:hover {
  background: #cc0000;
}

.inbox-empty {
  text-align: center;
  padding: 40px;
  color: #999;
}

.inbox-empty-icon {
  font-size: 64px;
  margin-bottom: 20px;
}

/* Responsivo */
@media (max-width: 768px) {
  .inbox-button {
    width: 50px;
    height: 50px;
    font-size: 20px;
    top: 15px;
    right: 15px;
  }
  
  .inbox-modal {
    padding: 5px;
    align-items: center;
    justify-content: center;
  }
  
  .inbox-content {
    max-width: 90%;
    width: 90%;
    max-height: 80vh;
    border-radius: 12px;
    margin: 0 auto;
  }
  
  .inbox-header {
    padding: 12px 15px;
  }
  
  .inbox-header h2 {
    font-size: 16px;
  }
  
  .inbox-close {
    width: 32px;
    height: 32px;
    font-size: 18px;
  }
  
  .inbox-messages {
    padding: 12px;
  }
  
  .inbox-message {
    padding: 10px;
    margin-bottom: 10px;
  }
  
  .inbox-message-from {
    font-size: 13px;
  }
  
  .inbox-message-date {
    font-size: 10px;
  }
  
  .inbox-message-subject {
    font-size: 13px;
    margin-bottom: 6px;
  }
  
  .inbox-message-body {
    font-size: 12px;
    line-height: 1.4;
  }
  
  .inbox-delete-btn {
    padding: 5px 10px;
    font-size: 10px;
  }
  
  .inbox-empty {
    padding: 25px 10px;
  }
  
  .inbox-empty-icon {
    font-size: 40px;
    margin-bottom: 15px;
  }
  
  .inbox-empty p {
    font-size: 13px;
  }
  
  .inbox-badge {
    width: 18px;
    height: 18px;
    font-size: 10px;
    top: -3px;
    right: -3px;
  }
}

