/* ═══════════════════════════════════════
   EasyOCR Landing — Custom Styles
   ═══════════════════════════════════════ */

/* Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #0a0a0a; }
::-webkit-scrollbar-thumb { background: #009656; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #00c06b; }

/* Gradient text */
.gradient-text {
    background: linear-gradient(135deg, #00e682 0%, #2bfda1 50%, #00c06b 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Glass effect */
.glass {
    background: rgba(17, 17, 17, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Navbar */
#navbar {
    background: transparent;
    border-bottom: 1px solid transparent;
}
.navbar-scrolled {
    background: rgba(5, 5, 5, 0.85) !important;
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom-color: rgba(255, 255, 255, 0.04) !important;
    box-shadow: 0 1px 24px rgba(0, 0, 0, 0.4);
}

/* Active nav link pill */
.nav-active {
    background: rgba(0, 230, 130, 0.1);
    color: #fff !important;
}
.nav-active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 12px;
    height: 2px;
    background: #00e682;
    border-radius: 1px;
}

/* Grid pattern */
.grid-pattern {
    background-image:
        linear-gradient(rgba(0, 150, 86, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 150, 86, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
}

/* Noise texture */
.noise::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.02'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 0;
}

/* Animated border */
.animated-border {
    position: relative;
}
.animated-border::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, #00e682, transparent, #009656);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

/* Progress bar animation */
.progress-animate {
    animation: progressFill 3s ease-in-out infinite;
}
@keyframes progressFill {
    0% { width: 0%; }
    20% { width: 10%; }
    40% { width: 25%; }
    60% { width: 55%; }
    80% { width: 85%; }
    100% { width: 100%; }
}

/* Intersection observer reveal */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* FAQ details animation */
details summary {
    list-style: none;
}
details summary::-webkit-details-marker {
    display: none;
}
details[open] summary {
    color: #00e682;
}

/* ═══ IMAP Section Animations ═══ */

/* Slide-in for email/processing items */
@keyframes imapSlideIn {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Pulse glow for the IMAP simulation panel */
@keyframes imapPulseGlow {
    0%, 100% { box-shadow: 0 0 30px rgba(0, 230, 130, 0.05); }
    50% { box-shadow: 0 0 50px rgba(0, 230, 130, 0.12); }
}
.animated-border {
    animation: imapPulseGlow 4s ease-in-out infinite;
}
.imap-panel-glow {
    box-shadow: 0 0 60px rgba(0, 230, 130, 0.06);
}

/* Cursor parpadeante para typewriter JSON */
@keyframes imapCursorBlink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}
.imap-cursor-blink {
    animation: imapCursorBlink 0.8s step-end infinite;
}

/* Campana de webhook */
@keyframes imapBellRing {
    0%, 100% { transform: rotate(0); }
    20% { transform: rotate(12deg); }
    40% { transform: rotate(-10deg); }
    60% { transform: rotate(6deg); }
    80% { transform: rotate(-4deg); }
}
.imap-bell-ring {
    animation: imapBellRing 0.6s ease-in-out;
}

/* Puntos de actividad */
@keyframes imapDotPulse {
    0%, 100% { opacity: 0.4; transform: scale(0.8); }
    50% { opacity: 1; transform: scale(1.2); }
}
.imap-dot-pulse {
    animation: imapDotPulse 1.5s ease-in-out infinite;
}

/* Engranaje giratorio */
.imap-gear-spin {
    animation: spin 3s linear infinite;
}
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Tarjeta de procesamiento pulsante */
@keyframes imapProcPulse {
    0%, 100% { border-color: rgba(0, 230, 130, 0.15); }
    50% { border-color: rgba(0, 230, 130, 0.35); }
}
.imap-proc-pulse {
    animation: imapProcPulse 2s ease-in-out infinite;
}

/* Smooth selection */
::selection {
    background: rgba(0, 230, 130, 0.3);
    color: #fff;
}
