/* Tailwind Base, Components, Utilities are loaded via CDN */

/* Custom Styles for codebenchmark.lt Enhancements */

/* General Styling & Variables */
:root {
    --primary-color: #6366F1; /* Indigo 500 */
    --secondary-color: #3B82F6; /* Blue 500 */
    --dark-bg-100: #1F2937; /* Gray 800 */
    --dark-bg-200: #111827; /* Gray 900 */
    --dark-bg-300: #0f172a; /* Slate 900 */
    --text-light: #F9FAFB; /* Gray 50 */
    --text-medium: #D1D5DB; /* Gray 300 */
    --text-dark: #9CA3AF; /* Gray 400 */
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px; /* Adjust based on fixed header height */
}

body {
    background-color: var(--dark-bg-300);
    color: var(--text-medium);
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    color: var(--text-light);
}

/* Text Gradient & Animated Gradient */
.text-gradient {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-fill-color: transparent;
}

.gradient-text-animated {
    background: linear-gradient(90deg, #a855f7, #6366f1, #3b82f6, #a855f7);
    background-size: 300% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-fill-color: transparent;
    animation: gradient-flow 5s linear infinite;
}

@keyframes gradient-flow {
    0% { background-position: 0% 50%; }
    100% { background-position: 100% 50%; }
}

/* Background Patterns & Gradients */
.bg-grid-pattern {
    background-image:
        linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 30px 30px; /* Smaller grid */
}

.bg-matrix {
    position: relative;
}
.bg-matrix::before {
    content: "";
    position: absolute; inset: 0;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10 10h10v10H10zM30 10h10v10H30zM50 10h10v10H50zM70 10h10v10H70zM90 10h10v10H90zM10 30h10v10H10zM30 30h10v10H30zM50 30h10v10H50zM70 30h10v10H70zM90 30h10v10H90zM10 50h10v10H10zM30 50h10v10H30zM50 50h10v10H50zM70 50h10v10H70zM90 50h10v10H90zM10 70h10v10H10zM30 70h10v10H30zM50 70h10v10H50zM70 70h10v10H70zM90 70h10v10H90zM10 90h10v10H10zM30 90h10v10H30zM50 90h10v10H50zM70 90h10v10H70zM90 90h10v10H90z' fill='%237c3aed' fill-opacity='0.4'/%3E%3C/svg%3E");
    z-index: 0;
}

.bg-cta-gradient {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #a855f7 100%);
}

/* Header Styles */
#navbar {
    transition: background-color 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease;
}
#navbar.scrolled {
    background-color: rgba(15, 23, 42, 0.85); /* dark-bg-300 with opacity */
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.hexagon {
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
}

.animated-border {
    position: relative;
    display: inline-block; /* Needed for pseudo-element positioning */
    padding-bottom: 4px;
}
.animated-border::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: width 0.3s ease;
}
.animated-border:hover::after,
.nav-link.active .animated-border::after { /* Add .nav-link class to nav items */
    width: 100%;
}

/* Mobile Menu */
#mobile-menu {
    transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
    transform-origin: top;
}
#mobile-menu.hidden {
   transform: scaleY(0.95);
   opacity: 0;
   pointer-events: none;
}


/* Button Styles */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid transparent;
    position: relative; /* For pseudo-elements */
    overflow: hidden; /* For gradient/shine effects */
    z-index: 1;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}
.btn-primary:hover {
    background-color: #7c3aed; /* Primary 600 */
    border-color: #7c3aed;
    box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.3);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: var(--dark-bg-100);
    color: var(--text-light);
    border-color: var(--dark-bg-100);
}
.btn-secondary:hover {
    background-color: #374151; /* Gray 700 */
    border-color: #374151;
    box-shadow: 0 10px 15px -3px rgba(31, 41, 55, 0.3);
    transform: translateY(-2px);
}

.btn-primary-gradient {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    background-size: 200% auto;
    color: white;
    border: none;
    transition: background-position 0.4s ease, box-shadow 0.3s ease, transform 0.3s ease;
}
.btn-primary-gradient:hover {
    background-position: right center; /* Change gradient direction */
    box-shadow: 0 10px 20px rgba(99, 102, 241, 0.4);
    transform: translateY(-2px);
}
.btn-primary-gradient-lg {
     padding: 1rem 2rem;
     font-size: 1.125rem; /* text-lg */
}

.btn-secondary-outline {
    background-color: transparent;
    color: var(--secondary-color);
    border: 2px solid var(--secondary-color);
}
.btn-secondary-outline:hover {
    background-color: rgba(59, 130, 246, 0.1);
    color: #60a5fa; /* secondary-400 */
    transform: translateY(-2px);
    box-shadow: 0 5px 10px rgba(59, 130, 246, 0.2);
}

.btn-cta {
    background-color: white;
    color: var(--primary-color); /* primary-500 */
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    padding: 1rem 2.5rem;
    border-radius: 0.5rem;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
}
.btn-cta:hover {
    background-color: #f3f4f6; /* gray-100 */
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 15px 25px -5px rgba(0, 0, 0, 0.2);
}


/* Enhanced Animation Keyframes */
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-15px); } }
@keyframes pulse-slow { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.7; transform: scale(1.03); } }
@keyframes spin-slow { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes blob-animation { 0%, 100% { border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%; } 50% { border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%; } }
@keyframes line-grow { from { width: 0; } to { width: 100%; } }
@keyframes fade-in-up { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulse-border { 0%, 100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4); } 50% { box-shadow: 0 0 0 10px rgba(99, 102, 241, 0); } }

/* Animation Utility Classes */
.animate-float { animation: float 10s ease-in-out infinite; }
.animate-pulse-slow { animation: pulse-slow 6s ease-in-out infinite; }
.blob-animation { animation: blob-animation 15s ease-in-out infinite; }
.animation-delay-500 { animation-delay: 0.5s; }
.animation-delay-1000 { animation-delay: 1s; }
.animation-delay-1500 { animation-delay: 1.5s; }
.animation-delay-2000 { animation-delay: 2s; }
.animation-delay-3000 { animation-delay: 3s; }

/* Hero Section Styles */
.hero-background { position: absolute; inset: 0; overflow: hidden; z-index: 0; }
.perspective-grid { position: absolute; inset: 0; background-image: radial-gradient(circle at center, rgba(99, 102, 241, 0.1) 0%, transparent 70%), linear-gradient(to right, rgba(99, 102, 241, 0.05) 1px, transparent 1px), linear-gradient(to bottom, rgba(99, 102, 241, 0.05) 1px, transparent 1px); background-size: 100% 100%, 40px 40px, 40px 40px; background-position: center; transform: perspective(1000px) rotateX(60deg) scale(2.5); transform-origin: center center; opacity: 0.15; top: -120%; height: 200%; }
.gradient-orb { position: absolute; border-radius: 50%; filter: blur(100px); }
.orb-1 { width: 800px; height: 800px; background: radial-gradient(circle, rgba(79, 70, 229, 0.2) 0%, rgba(139, 92, 246, 0.15) 50%, transparent 80%); top: -200px; right: -200px; }
.orb-2 { width: 600px; height: 600px; background: radial-gradient(circle, rgba(59, 130, 246, 0.2) 0%, rgba(99, 102, 241, 0.15) 50%, transparent 80%); bottom: -100px; left: -100px; }
.floating-shape { position: absolute; border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%; background-color: rgba(99, 102, 241, 0.1); z-index: 1; box-shadow: 0 0 20px rgba(139, 92, 246, 0.2); opacity: 0.5; }
.shape-1 { width: 150px; height: 150px; top: 15%; left: 10%; animation-duration: 18s; }
.shape-2 { width: 80px; height: 80px; top: 20%; right: 15%; border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%; background-color: rgba(59, 130, 246, 0.1); animation-duration: 12s; }
.shape-3 { width: 120px; height: 120px; bottom: 25%; left: 20%; border-radius: 50% 50% 70% 30% / 30% 30% 70% 70%; background-color: rgba(139, 92, 246, 0.1); animation-duration: 15s; }
.shape-4 { width: 100px; height: 100px; bottom: 15%; right: 25%; border-radius: 30% 70% 50% 50% / 50% 50% 50% 50%; background-color: rgba(99, 102, 241, 0.1); animation-duration: 20s; }
.code-particle { position: absolute; font-family: monospace; color: rgba(99, 102, 241, 0.3); opacity: 0.4; font-size: 1.5rem; pointer-events: none; animation: float 12s ease-in-out infinite; }
.cp-1 { top: 15%; left: 20%; animation-delay: -2s; font-size: 2rem; } .cp-2 { top: 75%; left: 15%; animation-delay: -4s; } .cp-3 { top: 35%; right: 10%; animation-delay: -6s; font-size: 1.8rem; } .cp-4 { top: 65%; right: 25%; animation-delay: -1s; } .cp-5 { bottom: 15%; left: 38%; animation-delay: -3s; font-size: 2.2rem; } .cp-6 { top: 22%; left: 50%; animation-delay: -5s; }
.hero-underline { position: absolute; bottom: 0; left: 0; width: 100%; height: 4px; background: linear-gradient(90deg, var(--primary-color), var(--secondary-color)); z-index: 0; border-radius: 2px; transform-origin: left; animation: grow-underline 0.8s ease forwards; animation-delay: 0.5s; opacity: 0; transform: scaleX(0); }
@keyframes grow-underline { to { opacity: 1; transform: scaleX(1); } }
.hero-partner { transform: translateY(0); transition: transform 0.3s ease, filter 0.3s ease; filter: grayscale(60%); }
.hero-partner:hover { transform: translateY(-5px); filter: grayscale(0%); }

/* Process Section Animations */
.process-line { width: 0; /* JS will trigger animation */ }
.process-step { opacity: 0; transform: translateY(30px); animation-fill-mode: forwards; }
.process-step-mobile { animation: pulse-border 2s infinite; }
.particles-container { position: absolute; inset: 0; overflow: hidden; z-index: 0; }

/* Stats Counter */
.counter { transition: all 0.3s ease; }

/* Card Hover Effects */
.feature-card-hover { transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); border: 1px solid transparent; }
.feature-card-hover:hover { transform: translateY(-10px) scale(1.02); border-color: rgba(99, 102, 241, 0.3); box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.3); }
.feature-icon { position: relative; z-index: 1; overflow: hidden; transition: all 0.3s ease; display: flex; align-items: center; justify-content: center; border-radius: 50%; } /* Ensures icon is centered */
.feature-icon::before { content: ''; position: absolute; inset: -20%; background: radial-gradient(circle at center, rgba(124, 58, 237, 0.2) 0%, transparent 70%); z-index: -1; opacity: 0; transform: scale(0.5); transition: opacity 0.4s ease, transform 0.4s ease; border-radius: 50%; }
.feature-card-hover:hover .feature-icon::before { opacity: 1; transform: scale(1); }
.feature-card-hover:hover .feature-icon i { transform: scale(1.1); color: var(--primary-color); }
.feature-icon i { transition: transform 0.3s ease, color 0.3s ease; }

/* Technology Stack Item Hover */
.tech-item .group-hover\:border-primary-500 { transition: border-color 0.3s ease; }
.tech-item .group-hover\:opacity-100 { transition: opacity 0.3s ease; }

/* Portfolio Filter Buttons */
.portfolio-filter button.active { background-color: rgba(99, 102, 241, 0.1); color: var(--primary-color); border-color: rgba(99, 102, 241, 0.5); }
/* Portfolio Item Animations (Optional) */
@keyframes fadeInPortfolio { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }
@keyframes fadeOutPortfolio { from { opacity: 1; transform: scale(1); } to { opacity: 0; transform: scale(0.95); } }
.portfolio-item.fade-in { display: block !important; animation: fadeInPortfolio 0.4s ease forwards; }
.portfolio-item.fade-out { animation: fadeOutPortfolio 0.4s ease forwards; }

/* Testimonial Cards Enhancement */
.testimonial-card { position: relative; overflow: hidden; border: 1px solid var(--dark-bg-100); transition: border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease; }
.testimonial-card:hover { border-color: var(--primary-color); transform: translateY(-5px); box-shadow: 0 10px 20px rgba(0,0,0,0.2); }
.testimonial-card::before { content: '"'; position: absolute; top: 5px; right: 15px; font-size: 100px; font-family: serif; color: rgba(124, 58, 237, 0.08); line-height: 1; pointer-events: none; z-index: 0; }

/* FAQ Accordion Styles */
details > summary { list-style: none; }
details > summary::-webkit-details-marker { display: none; }
.faq-item { transition: all 0.3s ease; }
.faq-question { transition: background-color 0.2s ease; }
.faq-item[open] .faq-question { background-color: rgba(124, 58, 237, 0.05); } /* Slight bg highlight when open */
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.4s ease-out, padding 0.4s ease-out; padding-top: 0; padding-bottom: 0;}
details[open] .faq-answer { max-height: 500px; /* Adjust max height as needed */ padding-top: 0.5rem; padding-bottom: 1.5rem;} /* Needs padding adjustment for smooth open */

/* Footer Links */
.footer-link {
    @apply text-gray-400 hover:text-white transition-colors text-sm hover:underline underline-offset-2;
}
.footer-social-link {
     @apply text-gray-400 hover:text-primary-400 transition-colors text-lg w-8 h-8 flex items-center justify-center rounded-full hover:bg-dark-100;
}


/* --- Hero Particle Container Style --- */
#hero-particles {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    /* z-index is set inline in HTML (z-[5]) */
}

/* Ensure canvas generated by particles.js is positioned correctly */
#hero-particles canvas {
    display: block;
    vertical-align: bottom;
}

/* --- Professional Contact Section Styles --- */

/* Contact Info Column */
.contact-info-column .group:hover i {
    color: var(--text-light); /* Slightly brighten icon on hover */
}
.contact-info-column a:hover i { /* Keep external link icon consistent */
    color: var(--secondary-color);
}

/* Contact Form Column */
.contact-form-column .bg-dark-100 {
     box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.15), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

/* Input transition defined directly via Tailwind utility classes in HTML */
/* Removed: .contact-input { transition: border-color 0.3s ease, box-shadow 0.3s ease; } */

/* Focus styles defined directly via Tailwind utility classes in HTML */
/* Removed: .contact-input:focus { box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2); } */


/* Custom Select Styling */
.contact-select {
    appearance: none; /* Remove default arrow */
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: none; /* Ensure no BG image residue */
    padding-right: 2.5rem; /* Make space for custom arrow */
    /* background-color: var(--dark-bg-200); -- REMOVED: Apply bg via utility class */
}
/* Position the custom arrow icon (using the parent div added in HTML) */
.contact-select + div { /* Targets the div directly after the select */
    top: 0; /* Align with top of label */
    /* Adjust margin-top to align arrow correctly with the input field */
    /* This depends on the label's line-height and margin-bottom */
    /* Rough estimate: label margin-bottom + half of label line-height + half of input padding */
    margin-top: calc(0.375rem + 1.25em / 2 + 0.75rem / 2); /* mb-1.5 + half of label height + half of input padding p-3 */
     /* Adjust height to fill remaining space */
     height: calc(100% - (0.375rem + 1.25em / 2 + 0.75rem / 2));
     pointer-events: none; /* Ensure div doesn't block select interaction */
     position: absolute; /* Ensure it's positioned relative to the parent div */
     right: 0; /* Position on the right */
     display: flex; /* Use flex to center the icon vertically */
     align-items: center; /* Center icon vertically */
     padding-right: 0.75rem; /* px-3 */
}

/* Submit Button States */
.submit-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: linear-gradient(90deg, #a78bfa, #93c5fd); /* Lighter gradient when disabled */
}
.submit-button .icon-loading {
    /* Display handled by JS */
}

/* Form Status Message Styling */
#form-status {
    padding: 0.75rem 1rem;
    border-radius: 0.375rem; /* rounded-md */
    border-width: 1px;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: opacity 0.3s ease, max-height 0.3s ease, padding 0.3s ease, margin 0.3s ease;
    margin-top: 0;
}
#form-status.visible {
     opacity: 1;
     max-height: 100px; /* Allow space for message */
     margin-top: 1rem;
     padding: 0.75rem 1rem;
}
#form-status.success {
    background-color: rgba(34, 197, 94, 0.1); /* green-500 with alpha */
    border-color: rgba(34, 197, 94, 0.3);
    color: #a7f3d0; /* green-200 */
}
#form-status.error {
    background-color: rgba(239, 68, 68, 0.1); /* red-500 with alpha */
    border-color: rgba(239, 68, 68, 0.3);
    color: #fecaca; /* red-200 */
}

/* --- AI Chatbot Popup Specific Styles --- */

#ai-chatbot-popup {
    /* Base container styles (overlay, flex) are reused via .popup-container */
    transition: opacity 0.3s ease-in-out;
}

#ai-chatbot-popup.hidden {
    opacity: 0;
    pointer-events: none;
}

#ai-chatbot-popup #ai-popup-content {
    /* Base styles in HTML - Tailwind */
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease-out; /* Added bounce ease */
}

/* Animation Classes for Popup Content */
#ai-chatbot-popup.popup-visible #ai-popup-content {
    transform: scale(1);
    opacity: 1;
}

#ai-chatbot-popup.popup-hiding #ai-popup-content {
    transform: scale(0.9); /* Slightly more shrink */
    opacity: 0;
}

#ai-popup-close:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--primary-color); /* Focus ring */
}

/* SVG Styling & Animation */
.ai-svg-container svg {
    width: 100%;
    height: 100%;
    overflow: visible; /* Allow glow filter to extend slightly */
}

/* Pulsing background animation */
@keyframes pulse-bg {
    0%, 100% { transform: scale(0.95); opacity: 0.7; }
    50% { transform: scale(1.05); opacity: 1; }
}
.ai-pulse-bg {
    transform-origin: center center;
    animation: pulse-bg 5s ease-in-out infinite;
}

/* Subtle line animation (optional) */
@keyframes draw-lines {
    to { stroke-dashoffset: 0; }
}
.ai-lines path {
    stroke-dasharray: 50; /* Adjust based on path length */
    stroke-dashoffset: 50;
    animation: draw-lines 2s ease-out forwards 0.5s; /* Delay start */
     opacity: 0.6;
}
/* Stagger line animations */
.ai-lines path:nth-child(2) { animation-delay: 0.7s; }
.ai-lines path:nth-child(3) { animation-delay: 0.9s; }
.ai-lines path:nth-child(4) { animation-delay: 1.1s; }
.ai-lines path:nth-child(5) { animation-delay: 1.3s; }
.ai-lines path:nth-child(6) { animation-delay: 1.5s; }
.ai-lines path:nth-child(7) { animation-delay: 1.7s; }
.ai-lines path:nth-child(8) { animation-delay: 1.9s; }


/* Pulsing/glowing nodes animation */
@keyframes pulse-nodes {
    0%, 100% { opacity: 0.7; transform: scale(0.9); }
    50% { opacity: 1; transform: scale(1.1); }
}
.ai-nodes circle {
    transform-origin: center center;
    animation: pulse-nodes 3s ease-in-out infinite;
}
/* Stagger node animations */
.ai-nodes circle:nth-child(odd) { animation-delay: 0.5s; }
.ai-nodes circle:nth-child(3n) { animation-delay: 1s; }