/* Custom Styles for Flash API Landing Page */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    overflow-x: hidden;
}

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

/* Glassmorphism Effect */
.glass-card {
    background: rgba(243, 237, 247, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* Enhanced Glass Effect for Hero and Code Sections */
section .glass-card {
    background: rgba(243, 237, 247, 0.6);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
}

/* Typewriter Effect */
.cursor {
    animation: blink 1s infinite;
    color: #6750A4;
    font-weight: normal;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.typewriter-text {
    border-right: 2px solid transparent;
}

/* Code Block Styling */
.code-block {
    display: none;
    background: #1e1e1e;
    color: #d4d4d4;
    padding: 1.5rem;
    border-radius: 12px;
    overflow-x: auto;
    font-family: 'Courier New', monospace;
    line-height: 1.6;
}

.code-block.active {
    display: block;
}

.code-block code {
    white-space: pre;
}

/* Language Tab Styling */
.lang-tab {
    color: #79747E;
    background: transparent;
    border: none;
    cursor: pointer;
}

.lang-tab.active {
    color: #6750A4;
    border-bottom: 2px solid #6750A4;
}

.lang-tab:hover {
    color: #6750A4;
    background: rgba(103, 80, 164, 0.05);
}

/* Copy Button */
.copy-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
}

/* Filter Button Active State */
.filter-btn.active {
    background: #6750A4 !important;
    color: white !important;
}

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

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

::-webkit-scrollbar-thumb {
    background: #6750A4;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #7D5260;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .code-block {
        font-size: 0.75rem;
        padding: 1rem;
    }
    
    .glass-card {
        backdrop-filter: blur(15px);
        -webkit-backdrop-filter: blur(15px);
    }
    
    /* Better mobile spacing */
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    /* Hero section mobile adjustments */
    h1 {
        font-size: 2rem !important;
        line-height: 1.2 !important;
    }
    
    /* Button adjustments for mobile */
    .glass-card .flex.flex-col.sm\:flex-row {
        gap: 0.75rem;
    }
    
    /* Hero container width consistency */
    .glass-card.rounded-\[48px\] {
        border-radius: 24px;
        padding: 1.5rem !important;
    }
    
    /* Mobile typewriter cursor */
    .cursor {
        font-size: 0.9em;
    }
}

@media (max-width: 640px) {
    /* Extra small screens */
    .glass-card {
        margin: 0 0.5rem;
        padding: 1.5rem !important;
    }
    
    /* Navigation adjustments */
    nav .container {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
    
    /* Hero title size for very small screens */
    h1 {
        font-size: 1.75rem !important;
    }
    
    /* Model cards mobile optimization */
    .model-card {
        padding: 1rem !important;
    }
    
    /* Filter buttons mobile */
    .filter-btn, .group-btn {
        font-size: 0.75rem;
        padding: 0.5rem 1rem;
    }
}

/* Transitions */
.transition-all {
    transition-property: all;
    transition-timing-function: cubic-bezier(0.2, 0, 0, 1);
}

/* Focus Visible for Accessibility */
*:focus-visible {
    outline: 2px solid #6750A4;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Prevent Layout Shift */
img {
    max-width: 100%;
    height: auto;
}

/* Animation for Page Load */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

section {
    animation: fadeInUp 0.6s ease-out;
}
