/*
 * PONTE IA - Interações e Cursores Aprimorados
 * Melhorias de UX e feedback visual
 */

/* ========================================
   CURSOR PERSONALIZADO
   ======================================== */

/* ========================================
   CURSOR PERSONALIZADO ULTRA MODERNO
   ======================================== */

/* Cursor padrão */
* {
    cursor: default;
}

/* Cursor de pointer com efeito gradient (compatível com todos os navegadores) */
a, 
button, 
.btn,
[role="button"],
input[type="submit"],
input[type="button"],
.social-link,
.play-button,
.nav-link,
.card-3d {
    cursor: pointer !important;
    /* Adiciona um efeito de "mão" mais visível */
    position: relative;
}

/* Hover effect nos links com transição suave */
a:hover,
button:hover,
.btn:hover {
    cursor: pointer !important;
    transition: all 0.2s ease;
}

/* Visited links - feedback visual que o link foi acessado */
a:visited {
    opacity: 0.9;
}

/* ========================================
   MELHORIAS NOS BOTÕES
   ======================================== */

/* Efeito de ripple/onda nos botões */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

/* Ripple effect - círculo branco ao clicar */
.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease-out, height 0.6s ease-out, opacity 0.6s ease-out;
    opacity: 0;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
    opacity: 1;
}

/* Feedback INSTANTÂNEO ao clicar - super visível */
.btn:active {
    transform: translateY(0) scale(0.95);
    transition: transform 0.05s ease-out;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3) !important;
}

/* Flash de luz ao clicar */
.btn:active::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.4);
    animation: flash 0.3s ease-out;
    pointer-events: none;
}

@keyframes flash {
    0% { opacity: 1; }
    100% { opacity: 0; }
}

/* ========================================
   BOTÕES PRIMÁRIOS - Verde
   ======================================== */

.btn-primary {
    box-shadow: 0 4px 15px rgba(153, 244, 67, 0.2);
    transition: all 0.3s ease;
    position: relative;
}

.btn-primary:hover {
    box-shadow: 0 8px 30px rgba(153, 244, 67, 0.5);
    transform: translateY(-3px) scale(1.03);
    filter: brightness(1.1);
}

.btn-primary:active {
    box-shadow: 0 1px 5px rgba(153, 244, 67, 0.4) !important;
    transform: translateY(0) scale(0.96) !important;
    filter: brightness(0.95);
    transition: all 0.05s ease-out !important;
}

/* Feedback adicional: borda ao clicar */
.btn-primary:active::after {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    border: 2px solid rgba(153, 244, 67, 0.6);
    border-radius: inherit;
    animation: pulse-border 0.4s ease-out;
}

@keyframes pulse-border {
    0% { 
        transform: scale(1);
        opacity: 1;
    }
    100% { 
        transform: scale(1.1);
        opacity: 0;
    }
}

/* ========================================
   BOTÕES SECUNDÁRIOS - Rosa
   ======================================== */

.btn-secondary {
    box-shadow: 0 4px 15px rgba(236, 68, 155, 0.2);
    transition: all 0.3s ease;
    position: relative;
}

.btn-secondary:hover {
    box-shadow: 0 8px 30px rgba(236, 68, 155, 0.5);
    transform: translateY(-3px) scale(1.03);
    filter: brightness(1.1);
}

.btn-secondary:active {
    box-shadow: 0 1px 5px rgba(236, 68, 155, 0.4) !important;
    transform: translateY(0) scale(0.96) !important;
    filter: brightness(0.95);
    transition: all 0.05s ease-out !important;
}

/* Feedback adicional: borda ao clicar */
.btn-secondary:active::after {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    border: 2px solid rgba(236, 68, 155, 0.6);
    border-radius: inherit;
    animation: pulse-border-pink 0.4s ease-out;
}

@keyframes pulse-border-pink {
    0% { 
        transform: scale(1);
        opacity: 1;
    }
    100% { 
        transform: scale(1.1);
        opacity: 0;
    }
}

/* ========================================
   BOTÕES OUTLINE
   ======================================== */

.btn-outline,
.btn-outline-pink {
    box-shadow: 0 4px 15px rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.btn-outline:hover,
.btn-outline-pink:hover {
    box-shadow: 0 8px 30px rgba(153, 244, 67, 0.3);
    transform: translateY(-3px) scale(1.02);
}

/* ========================================
   BOTÕES DE TEXTO
   ======================================== */

.btn-text {
    position: relative;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* Linha animada abaixo do texto */
.btn-text::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: currentColor;
    transition: width 0.3s ease;
}

.btn-text:hover::after {
    width: 100%;
}

/* Movimento suave para a direita */
.btn-text:hover {
    transform: translateX(5px);
    filter: brightness(1.2);
}

/* Feedback ao clicar */
.btn-text:active {
    transform: translateX(3px) scale(0.98);
    filter: brightness(0.9);
    transition: all 0.05s ease-out;
}

/* Ícone animado ao hover */
.btn-text:hover i {
    transform: translateX(3px);
    transition: transform 0.3s ease;
}

/* ========================================
   CARDS INTERATIVOS
   ======================================== */

.card-3d,
.solution-card,
.team-card {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.card-3d:hover {
    transform: translateY(-10px) scale(1.02);
}

/* ========================================
   PLAY BUTTON (Manifesto)
   ======================================== */

.play-button {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer !important;
}

.play-button:hover {
    transform: scale(1.2);
    box-shadow: 0 8px 30px rgba(153, 244, 67, 0.5);
}

.play-button:active {
    transform: scale(1.1);
}

/* ========================================
   LINKS SOCIAIS
   ======================================== */

.social-link {
    transition: all 0.3s ease;
    cursor: pointer !important;
}

.social-link:hover {
    transform: translateY(-3px) scale(1.1);
}

.social-link:active {
    transform: translateY(-1px) scale(1.05);
}

/* ========================================
   NAVEGAÇÃO
   ======================================== */

.nav-link {
    position: relative;
    transition: all 0.3s ease;
    cursor: pointer !important;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-primary);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link:hover {
    color: var(--color-primary);
    transform: translateY(-2px);
}

/* ========================================
   SCROLL TO TOP BUTTON
   ======================================== */

.scroll-to-top {
    transition: all 0.3s ease;
    cursor: pointer !important;
}

.scroll-to-top:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 8px 30px rgba(153, 244, 67, 0.4);
}

.scroll-to-top:active {
    transform: translateY(-2px) scale(1.05);
}

/* ========================================
   INPUTS E FORMS
   ======================================== */

input,
textarea,
select {
    cursor: text;
}

input[type="submit"],
input[type="button"] {
    cursor: pointer !important;
}

/* ========================================
   LOADING STATE - Indicador visual ao clicar em links externos
   ======================================== */

.btn.loading {
    pointer-events: none;
    opacity: 0.7;
    cursor: wait !important;
}

.btn.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spinner 0.6s linear infinite;
}

@keyframes spinner {
    to { transform: rotate(360deg); }
}

/* ========================================
   CLICK FEEDBACK - Indicador de "abrindo link"
   ======================================== */

/* Animação de "processando" ao clicar */
.btn[target="_blank"]:active::before,
a[target="_blank"]:active::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    border: 2px solid currentColor;
    border-top-color: transparent;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: quick-spin 0.3s ease-out;
    z-index: 10;
}

@keyframes quick-spin {
    0% { transform: translate(-50%, -50%) rotate(0deg) scale(0.5); opacity: 0; }
    50% { opacity: 1; }
    100% { transform: translate(-50%, -50%) rotate(180deg) scale(1); opacity: 0; }
}

/* ========================================
   DISABLED STATE
   ======================================== */

.btn:disabled,
.btn[disabled] {
    opacity: 0.5;
    cursor: not-allowed !important;
    pointer-events: none;
}

/* ========================================
   RESPONSIVIDADE
   ======================================== */

@media (max-width: 768px) {
    /* Reduzir efeitos em mobile para performance */
    .btn:hover {
        transform: translateY(-2px);
    }
    
    .card-3d:hover {
        transform: translateY(-5px) scale(1.01);
    }
}

/* ========================================
   ACESSIBILIDADE
   ======================================== */

/* Focus visível para navegação por teclado */
.btn:focus-visible,
a:focus-visible,
button:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 3px;
}

/* Redução de movimento para usuários que preferem */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .btn::before,
    .btn-text::after,
    .nav-link::after {
        transition: none;
    }
}
