/* Custom CSS for Quick IT Help Website */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* Animations for elements */
.animate-fadeInUp {
    animation: fadeInUp 0.8s ease-out;
}

.animate-fadeIn {
    animation: fadeIn 0.6s ease-out;
}

.animate-slideInLeft {
    animation: slideInLeft 0.8s ease-out;
}

/* Hero section enhancements */
.hero-section {
    position: relative;
    overflow: hidden;
    background-size: 200% 200%;
    animation: gradientShift 15s ease infinite;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1) 0%, rgba(99, 102, 241, 0.1) 100%);
    z-index: -1;
}

.hero-section h1 {
    animation: slideInLeft 1s ease-out;
}

.hero-section p {
    animation: slideInLeft 1s ease-out 0.2s both;
}

.hero-section .grid {
    animation: slideInLeft 1s ease-out 0.4s both;
}

.hero-section .flex.gap-4 {
    animation: slideInLeft 1s ease-out 0.6s both;
}

.hero-section .flex.gap-8 {
    animation: slideInLeft 1s ease-out 0.8s both;
}

.hero-section img {
    animation: slideInRight 1s ease-out;
}

.hero-section .absolute {
    animation: float 3s ease-in-out infinite;
}

.hero-section .inline-flex {
    animation: slideInLeft 1s ease-out 0.1s both;
}

.hero-section .transform.rotate-3:hover {
    transform: rotate(0deg) scale(1.05);
}

.hero-section .transform.-rotate-3:hover {
    transform: rotate(0deg) scale(1.05);
}

.hero-section .bg-red-500 {
    animation: pulse 2s infinite;
}

.hero-section .bg-white.rounded-xl {
    animation: slideInRight 1s ease-out 0.5s both;
}

.stats-counter {
    animation: countUp 1s ease-out 1s both;
}

/* Service cards enhancements */
.service-card {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.1), transparent);
    transition: left 0.5s ease;
}

.service-card:hover::before {
    left: 100%;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.service-card .text-blue-600 {
    transition: transform 0.3s ease;
}

.service-card:hover .text-blue-600 {
    transform: scale(1.1);
}

/* Team member cards */
.team-member {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    text-align: center;
}

.team-member:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}

.team-member-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin: 0 auto 16px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 24px;
}

.team-member.c-level .team-member-avatar {
    background: linear-gradient(135deg, #f59e0b, #ef4444);
}

/* FAQ enhancements */
.faq-item {
    transition: all 0.3s ease;
}

.faq-question:hover {
    background-color: #f3f4f6;
}

.faq-answer {
    max-height: 500px;
    overflow: visible;
    padding-top: 16px;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-answer.show {
    max-height: 500px;
    padding-top: 16px;
}

.faq-answer.hidden {
    max-height: 0;
    overflow: hidden;
    padding-top: 0;
}

.faq-question i {
    transition: transform 0.3s ease;
}

.faq-question.active i {
    transform: rotate(180deg);
}

/* Contact form enhancements */
#contact-form input,
#contact-form select,
#contact-form textarea {
    transition: all 0.3s ease;
}

#contact-form input:focus,
#contact-form select:focus,
#contact-form textarea:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    border-color: #3b82f6;
}

#contact-form button {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

#contact-form button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

#contact-form button:hover::before {
    width: 300px;
    height: 300px;
}

/* Navigation enhancements */
.nav-link {
    position: relative;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: #3b82f6;
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* Mobile menu enhancements */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

#mobile-menu.show {
    max-height: 500px;
}

/* Stats counter animation */
.stats-counter {
    font-variant-numeric: tabular-nums;
}

/* Loading spinner */
.spinner {
    border: 3px solid #f3f4f6;
    border-top: 3px solid #3b82f6;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes countUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Success message */
.success-message {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    padding: 16px;
    border-radius: 8px;
    margin-top: 16px;
    display: none;
    animation: fadeInUp 0.5s ease;
}

.success-message.show {
    display: block;
}

/* Error message */
.error-message {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    padding: 16px;
    border-radius: 8px;
    margin-top: 16px;
    display: none;
    animation: fadeInUp 0.5s ease;
}

.error-message.show {
    display: block;
}

/* Responsive enhancements */
@media (max-width: 768px) {
    .service-card {
        margin-bottom: 20px;
    }
    
    .team-member {
        margin-bottom: 20px;
    }
    
    #home h2 {
        font-size: 2.5rem;
        line-height: 1.2;
    }
    
    #home .text-xl {
        font-size: 1.125rem;
    }
}

/* Accessibility improvements */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus indicators */
button:focus,
input:focus,
textarea:focus,
select:focus,
a:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    header,
    footer,
    #contact,
    .faq-item {
        display: none;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.5;
    }
    
    .service-card {
        break-inside: avoid;
        page-break-inside: avoid;
    }
}

/* Performance optimizations */
.service-card,
.team-member,
.faq-item {
    will-change: transform;
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
    .service-card,
    .team-member,
    .faq-item {
        background: #1f2937;
        color: white;
    }
    
    #contact-form input,
    #contact-form select,
    #contact-form textarea {
        background: #374151;
        border-color: #4b5563;
        color: white;
    }
}
