/* King Systems - Custom Styles */

/* Logo Slider Animation */
.logo-slider {
    overflow: hidden;
    position: relative;
    width: 100%;
}

.logo-track {
    display: flex;
    gap: 0;
    animation: scroll 60s linear infinite;
    width: max-content;
}

.logo-set {
    display: flex;
    gap: 4rem;
    flex-shrink: 0;
}

.logo-track:hover {
    animation-play-state: paused;
}

.logo-item {
    flex-shrink: 0;
    min-width: 150px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    font-weight: 600;
    color: #6b7280;
    transition: all 0.3s ease;
}

.logo-item:hover {
    color: #1e3a8a;
    transform: scale(1.05);
}

.partner-logo-img {
    max-width: 160px;
    max-height: 70px;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: all 0.3s ease;
    display: block;
}

.logo-item:hover .partner-logo-img {
    transform: scale(1.1);
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-100% / 2));
    }
}

/* Client Logo Slider */
.client-slider {
    overflow: hidden;
    position: relative;
    width: 100%;
}

.client-track {
    display: flex;
    gap: 6rem;
    animation: scrollClients 120s linear infinite;
}

.client-track:hover {
    animation-play-state: paused;
}

.client-item {
    flex-shrink: 0;
    min-width: 180px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    font-weight: 600;
    color: #6b7280;
    transition: all 0.3s ease;
}

.client-item:hover {
    color: #1e3a8a;
    transform: scale(1.05);
}

/* Client Logo Grid with Images */
.client-logo-grid {
    overflow: hidden;
    position: relative;
    width: 100%;
}

.client-logo-track {
    display: flex;
    gap: 0;
    animation: scrollClients 120s linear infinite;
    align-items: center;
    width: max-content;
}

.client-logo-set {
    display: flex;
    gap: 4rem;
    flex-shrink: 0;
    align-items: center;
}

.client-logo-track:hover {
    animation-play-state: paused;
}

.client-logo-item {
    flex-shrink: 0;
    min-width: 200px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    transition: all 0.3s ease;
}

.client-logo-img {
    max-width: 180px;
    max-height: 80px;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: all 0.3s ease;
}

.client-logo-item:hover .client-logo-img {
    transform: scale(1.1);
}

@keyframes scrollClients {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-100% / 2));
    }
}

/* Reviews Slider Animation */
.reviews-track {
    display: flex;
    animation: scrollReviews 60s linear infinite;
    width: max-content;
}

.reviews-track:hover {
    animation-play-state: paused;
}

@keyframes scrollReviews {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-50%));
    }
}

.review-card {
    animation: fadeIn 0.6s ease-out;
}

/* Ensure reviews scroll on mobile */
@media (max-width: 768px) {
    .reviews-track {
        animation: scrollReviews 60s linear infinite !important;
    }
    
    .review-card {
        width: 20rem !important; /* 320px for better mobile fit */
        min-width: 20rem;
    }
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Card Hover Effects */
.card-hover {
    transition: all 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-8px);
}

/* Clickable Cards */
a.block {
    text-decoration: none;
    color: inherit;
}

.cursor-pointer {
    cursor: pointer;
}

/* Feature Icon Animation */
.feature-icon {
    transition: all 0.3s ease;
}

.card-hover:hover .feature-icon {
    transform: scale(1.1);
}

/* Navigation Sticky Effect */
.nav-sticky {
    transition: all 0.3s ease;
}

/* Button Styles */
.btn-primary {
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 12px rgba(0, 0, 0, 0.15);
}

/* Mobile Menu */
.mobile-menu {
    transition: all 0.3s ease;
}

/* Form Styles */
input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: #1e3a8a;
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

/* Responsive Typography */
@media (max-width: 768px) {
    .logo-track {
        gap: 2rem;
    }
    
    .client-track {
        gap: 3rem;
    }
    
    .logo-item,
    .client-item {
        min-width: 120px;
        height: 60px;
        font-size: 1rem;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #1e3a8a;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0c4a6e;
}

/* Hero Section Overlay - Reduced opacity for better image visibility */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.40) 0%, rgba(12, 74, 110, 0.35) 100%);
}

/* Service Plans Card Scaling */
@media (min-width: 768px) {
    .scale-105 {
        transform: scale(1.05);
    }
}

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #1e3a8a, #0c4a6e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Loading Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* Success/Error Messages */
.message-success {
    background-color: #10b981;
    color: white;
    padding: 1rem;
    border-radius: 0.5rem;
    margin-top: 1rem;
}

.message-error {
    background-color: #ef4444;
    color: white;
    padding: 1rem;
    border-radius: 0.5rem;
    margin-top: 1rem;
}

/* Print Styles */
@media print {
    nav,
    footer,
    .btn-primary {
        display: none;
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus Visible */
*:focus-visible {
    outline: 2px solid #d97706;
    outline-offset: 2px;
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .text-gray-600 {
        color: #000;
    }
}

/* Chat Button Animation */
@keyframes bounce-slow {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-8px);
    }
}

.animate-bounce-slow {
    animation: bounce-slow 2s ease-in-out infinite;
}

#chatButton:hover {
    animation: none; /* Stop bouncing on hover */
}

/* Mobile Chat Button Adjustments */
@media (max-width: 768px) {
    #chatButton {
        bottom: 1rem;
        right: 1rem;
        padding: 1rem 1.5rem;
        font-size: 0.875rem;
    }
    
    #chatButton span {
        display: inline; /* Always show text on mobile too */
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}