/* Custom styles for AIWebsite theme */

/* Base */
html {
    scroll-behavior: smooth;
}

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

/* GSAP ready state */
body.gsap-ready [data-gsap],
body.gsap-ready .gsap-hero-text {
    visibility: visible;
}

body:not(.gsap-loading) [data-gsap],
body:not(.gsap-loading) .gsap-hero-text {
    visibility: visible;
}

/* Gradient text animation */
@keyframes gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.animate-gradient {
    animation: gradient-shift 6s ease-in-out infinite;
}

/* Neural node pulse */
@keyframes node-pulse {
    0%, 100% { opacity: 0.4; r: 4; }
    50% { opacity: 0.8; r: 6; }
}

.neural-node {
    animation: node-pulse 3s ease-in-out infinite;
}

.neural-node:nth-child(2n) {
    animation-delay: 0.5s;
}

.neural-node:nth-child(3n) {
    animation-delay: 1s;
}

/* Neural line pulse */
@keyframes line-pulse {
    0%, 100% { opacity: 0.2; }
    50% { opacity: 0.5; }
}

.neural-line {
    animation: line-pulse 4s ease-in-out infinite;
}

.neural-line:nth-child(2n) {
    animation-delay: 1s;
}

/* Glow effect */
.glow-purple {
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.3), 0 0 60px rgba(139, 92, 246, 0.1);
}

.glow-blue {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.3), 0 0 60px rgba(59, 130, 246, 0.1);
}

/* Prose overrides for WordPress content */
.prose img {
    border-radius: 1rem;
    border: 1px solid rgba(55, 65, 81, 0.5);
}

.prose pre {
    border-radius: 1rem;
}

/* WordPress pagination */
.page-numbers {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.page-numbers a,
.page-numbers span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.75rem;
    border-radius: 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s;
}

.page-numbers a {
    color: #9ca3af;
    border: 1px solid rgba(55, 65, 81, 0.5);
    background: rgba(17, 24, 39, 0.4);
}

.page-numbers a:hover {
    color: #fff;
    border-color: rgba(88, 28, 135, 0.5);
    background: rgba(88, 28, 135, 0.1);
}

.page-numbers .current {
    color: #fff;
    background: linear-gradient(135deg, #581c87, #2563eb);
    border: none;
}

/* Terminal cursor blink */
@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

#terminal-cursor {
    animation: blink 1s step-end infinite;
}

/* Scrollbar for chat */
.overflow-y-auto::-webkit-scrollbar {
    width: 4px;
}

.overflow-y-auto::-webkit-scrollbar-track {
    background: transparent;
}

.overflow-y-auto::-webkit-scrollbar-thumb {
    background: rgba(88, 28, 135, 0.3);
    border-radius: 2px;
}

/* WP admin bar fix */
body.admin-bar header.fixed {
    top: 32px;
}

@media (max-width: 782px) {
    body.admin-bar header.fixed {
        top: 46px;
    }
}

/* Responsive fixes */
@media (max-width: 640px) {
    .font-heading.text-6xl {
        font-size: 2.25rem;
    }
}
