/* ============================================
   $BARK - Custom CSS Styles
   Tailwind CSS Extension
   ============================================ */

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: #d6eeff;
    font-family: 'Nunito', sans-serif;
    overflow-x: hidden;
}

/* Selection */
::selection {
    background-color: #1A5276;
    color: #fff;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #e0f4ff;
}

::-webkit-scrollbar-thumb {
    background: #1A5276;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #009dff;
}

/* ============================================
   Animations
   ============================================ */

/* Fade In Up Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.8s ease-out forwards;
}

/* Float Animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

.animate-float {
    animation: float 4s ease-in-out infinite;
}

/* Slow Bounce Animation */
@keyframes bounceSlow {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.animate-bounce-slow {
    animation: bounceSlow 2s ease-in-out infinite;
}

/* Marquee Animation */
@keyframes marquee {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.animate-marquee {
    animation: marquee 20s linear infinite;
}

.marquee-container {
    overflow: hidden;
    white-space: nowrap;
}

.marquee-content {
    display: inline-flex;
    min-width: 200%;
}

/* Pulse Glow Animation */
@keyframes pulseGlow {
    0%, 100% {
        box-shadow: 0 0 5px rgba(255, 193, 7, 0.5);
    }
    50% {
        box-shadow: 0 0 20px rgba(255, 193, 7, 0.8), 0 0 30px rgba(255, 193, 7, 0.4);
    }
}

.animate-pulse-glow {
    animation: pulseGlow 2s ease-in-out infinite;
}

/* Spin Slow Animation */
@keyframes spinSlow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.animate-spin-slow {
    animation: spinSlow 10s linear infinite;
}

/* Shimmer Effect */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.animate-shimmer {
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

/* ============================================
   Component Styles
   ============================================ */

/* Navbar */
.navbar-scrolled {
    box-shadow: 0 4px 20px rgba(26, 82, 118, 0.15);
}

/* Feature Cards */
.feature-card {
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    transition: left 0.5s ease;
}

.feature-card:hover::before {
    left: 100%;
}

/* Stat Cards */
.stat-card {
    position: relative;
}

.stat-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #ffc107, #009dff);
    transition: width 0.3s ease;
    border-radius: 3px;
}

.stat-card:hover::after {
    width: 60%;
}

/* Buttons */
.btn-primary {
    position: relative;
    overflow: hidden;
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-primary:hover::after {
    width: 300%;
    height: 300%;
}

.btn-outline {
    position: relative;
    z-index: 1;
}

.btn-outline::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: #1A5276;
    z-index: -1;
    transition: width 0.3s ease;
    border-radius: inherit;
}

.btn-outline:hover::before {
    width: 100%;
}

/* Timeline Styles */
.timeline-dot {
    position: relative;
}

.timeline-dot::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(255, 193, 7, 0.2);
    border-radius: 50%;
    animation: pulseGlow 2s ease-in-out infinite;
}

/* ============================================
   Gradient Backgrounds
   ============================================ */

.gradient-primary {
    background: linear-gradient(135deg, #1A5276 0%, #009dff 100%);
}

.gradient-accent {
    background: linear-gradient(135deg, #ffc107 0%, #ffdb4d 100%);
}

.gradient-light {
    background: linear-gradient(180deg, #e0f4ff 0%, #d6eeff 100%);
}

/* Mesh Gradient Background */
.mesh-gradient {
    background-color: #d6eeff;
    background-image: 
        radial-gradient(at 40% 20%, rgba(0, 157, 255, 0.15) 0px, transparent 50%),
        radial-gradient(at 80% 0%, rgba(255, 193, 7, 0.1) 0px, transparent 50%),
        radial-gradient(at 0% 50%, rgba(26, 82, 118, 0.1) 0px, transparent 50%),
        radial-gradient(at 80% 50%, rgba(0, 157, 255, 0.1) 0px, transparent 50%),
        radial-gradient(at 0% 100%, rgba(255, 193, 7, 0.1) 0px, transparent 50%);
}

/* ============================================
   Glass Effect
   ============================================ */

.glass {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.glass-dark {
    background: rgba(26, 82, 118, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ============================================
   Text Effects
   ============================================ */

.text-gradient {
    background: linear-gradient(135deg, #1A5276 0%, #009dff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-shadow {
    text-shadow: 2px 2px 4px rgba(26, 82, 118, 0.2);
}

.text-glow {
    text-shadow: 0 0 10px rgba(0, 157, 255, 0.5), 0 0 20px rgba(0, 157, 255, 0.3);
}

/* ============================================
   Neon Border Effect
   ============================================ */

.neon-border {
    position: relative;
}

.neon-border::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #ffc107, #009dff, #1A5276, #ffc107);
    background-size: 400% 400%;
    border-radius: inherit;
    z-index: -1;
    animation: borderGlow 3s ease infinite;
}

@keyframes borderGlow {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

/* ============================================
   Responsive Utilities
   ============================================ */

/* Hide on mobile */
@media (max-width: 767px) {
    .desktop-only {
        display: none !important;
    }
}

/* Hide on desktop */
@media (min-width: 768px) {
    .mobile-only {
        display: none !important;
    }
}

/* ============================================
   Section Transitions
   ============================================ */

section {
    position: relative;
}

/* Wave Divider */
.wave-divider {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
}

.wave-divider svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 60px;
}

.wave-divider .shape-fill {
    fill: #FFFFFF;
}

/* ============================================
   Loading Animation
   ============================================ */

.loading-dots {
    display: inline-flex;
    gap: 4px;
}

.loading-dots span {
    width: 8px;
    height: 8px;
    background: #1A5276;
    border-radius: 50%;
    animation: loadingBounce 1.4s infinite ease-in-out both;
}

.loading-dots span:nth-child(1) {
    animation-delay: -0.32s;
}

.loading-dots span:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes loadingBounce {
    0%, 80%, 100% {
        transform: scale(0);
    }
    40% {
        transform: scale(1);
    }
}

/* ============================================
   Card Hover Effects
   ============================================ */

.card-hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(26, 82, 118, 0.15);
}

.card-hover-glow {
    transition: box-shadow 0.3s ease;
}

.card-hover-glow:hover {
    box-shadow: 0 0 30px rgba(0, 157, 255, 0.3);
}

/* ============================================
   Chart Container
   ============================================ */

.chart-container {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
}

.chart-container iframe {
    display: block;
    border: none;
}

/* ============================================
   Footer Styles
   ============================================ */

footer a {
    transition: all 0.3s ease;
}

footer a:hover {
    transform: translateY(-2px);
}

/* ============================================
   Mobile Menu Animation
   ============================================ */

#mobileMenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

#mobileMenu.active {
    max-height: 500px;
}

/* ============================================
   Accessibility
   ============================================ */

/* Focus states */
a:focus,
button:focus {
    outline: 2px solid #009dff;
    outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ============================================
   Print Styles
   ============================================ */

@media print {
    nav,
    .marquee-container,
    #chart,
    footer {
        display: none !important;
    }
    
    body {
        background: white !important;
    }
    
    section {
        page-break-inside: avoid;
    }
}