@import './variables.css';

/* Base & Reset */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-family: var(--font-sans);
    color: var(--color-brand-ink);
    background-color: var(--color-warm-paper);
    -webkit-tap-highlight-color: transparent;
}

body {
    margin: 0;
    background-color: var(--color-warm-paper);
    color: var(--color-brand-ink);
    font-family: var(--font-sans);
    font-feature-settings: "cv02", "cv03", "cv04", "cv11";
    overflow-x: hidden;
}

[x-cloak] {
    display: none !important;
}

/* Régimen Numérico CFO: Claridad tabular obligatoria para importes, saldos y porcentajes */
.tabular-nums,
.cfo-metric,
.cfo-currency {
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
}

/* Tokens Pre-Compilados de la Paleta Daylight Clean Fintech & Warm Paper */
.bg-warm-paper,
.bg-\[\#faf8f3\] {
    background-color: var(--color-warm-paper) !important;
}

.text-\[\#0f172a\] {
    color: var(--color-brand-ink) !important;
}

.bg-\[\#0f172a\] {
    background-color: var(--color-brand-ink) !important;
}

.border-warm-paper,
.border-\[\#efeae0\] {
    border-color: var(--color-warm-paper-border) !important;
}

/* Escala Matemática Estricta de Z-Index Pre-Compilada */
.z-\[100\] {
    z-index: 100 !important;
}

.z-\[110\] {
    z-index: 110 !important;
}

.z-\[120\] {
    z-index: 120 !important;
}

.z-\[130\] {
    z-index: 130 !important;
}

.driver-popover,
.driver-overlay {
    z-index: 9999 !important;
}

/* ==========================================================================
   ANIMACIONES FINTECH PREMIUM & EFECTOS DE MOVIMIENTO
   ========================================================================== */

/* 1. Levitation / Float suave */
@keyframes floatSlow {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-7px);
    }
}

@keyframes floatReverse {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(7px);
    }
}

.animate-float-slow {
    animation: floatSlow 5s ease-in-out infinite;
}

.animate-float-reverse {
    animation: floatReverse 6s ease-in-out infinite;
}

/* 2. Botón Shimmer / Sheen Sweep (Efecto de luz diagonal continuo) */
.btn-sheen {
    position: relative;
    overflow: hidden;
}

.btn-sheen::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -80%;
    width: 45%;
    height: 200%;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.4) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(25deg);
    animation: buttonSheen 5.5s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    pointer-events: none;
}

@keyframes buttonSheen {
    0%, 65% {
        left: -80%;
        opacity: 0;
    }
    68% {
        opacity: 1;
    }
    82% {
        left: 150%;
        opacity: 0;
    }
    100% {
        left: 150%;
        opacity: 0;
    }
}

/* 3. Pulse Beacon (Indicador de estado en vivo para ARCA y Servicios) */
.pulse-beacon {
    position: relative;
    display: inline-block;
}

.pulse-beacon::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 9999px;
    background-color: currentColor;
    opacity: 0.6;
    animation: beaconPing 2s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes beaconPing {
    75%, 100% {
        transform: scale(2.4);
        opacity: 0;
    }
}

/* 4. Tarjetas Daylight Clean Fintech Premium */
.daylight-card {
    background-color: var(--color-pure-white);
    border: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 0 10px 30px -10px rgba(15, 23, 42, 0.05), 0 4px 12px -2px rgba(15, 23, 42, 0.02);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s ease;
}

.daylight-card:hover {
    box-shadow: 0 22px 45px -12px rgba(14, 165, 233, 0.12), 0 8px 24px -4px rgba(15, 23, 42, 0.04);
    border-color: rgba(14, 165, 233, 0.35);
}

/* 5. Hover Lift (Micro-elevación con sombra dinámica en tarjetas y métricas) */
.hover-lift {
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.28s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.28s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px -12px rgba(15, 23, 42, 0.08), 0 8px 20px -4px rgba(14, 165, 233, 0.12);
    border-color: rgba(14, 165, 233, 0.4);
}

/* 6. Halo Solar Ambient Drift */
@keyframes haloBreathe {
    0%, 100% {
        opacity: 0.9;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.03) translateY(-3px);
    }
}

.solar-halo {
    background: radial-gradient(circle at 75% 20%, rgba(245, 158, 11, 0.16) 0%, rgba(14, 165, 233, 0.11) 40%, rgba(250, 248, 243, 0) 72%);
    animation: haloBreathe 9s ease-in-out infinite;
}

/* 7. Botón Primario Cielo Argentino (#0ea5e9) */
.cielo-glow-btn {
    background-color: var(--color-cielo-argentino);
    color: var(--color-pure-white);
    box-shadow: 0 10px 28px -6px rgba(14, 165, 233, 0.48);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
}

.cielo-glow-btn:hover {
    background-color: var(--color-cielo-argentino-dark);
    transform: translateY(-2px);
    box-shadow: 0 16px 36px -6px rgba(14, 165, 233, 0.62);
}

/* 8. Badge Glows */
.badge-glow-amber {
    box-shadow: 0 0 18px -2px rgba(245, 158, 11, 0.28);
}

.badge-glow-emerald {
    box-shadow: 0 0 18px -2px rgba(16, 185, 129, 0.28);
}

.badge-glow-cielo {
    box-shadow: 0 0 18px -2px rgba(14, 165, 233, 0.28);
}

/* 9. Micro-interacción en íconos al hacer hover */
.icon-tilt {
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.group:hover .icon-tilt,
.icon-tilt:hover {
    transform: scale(1.15) rotate(6deg);
}

/* 10. Adaptación App Nativa Mobile */
@media (max-width: 767px) {
    .pb-safe-mobile {
        padding-bottom: 5.5rem;
    }
}
