/* ===== CSS Variables ===== */
:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-glow: rgba(99, 102, 241, 0.4);
    --secondary: #ec489a;
    --dark-bg: #0f0f1a;
    --darker-bg: #0a0a0f;
    --card-bg: rgba(15, 15, 26, 0.95);
    --text-primary: #e2e8f0;
    --text-secondary: #94a3b8;
    --border-color: rgba(99, 102, 241, 0.2);
    --success: #10b981;
    --warning: #f59e0b;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', monospace;
    background: var(--dark-bg);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%, rgba(99, 102, 241, 0.08) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(236, 72, 153, 0.08) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 4rem;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.logo-icon {
    font-size: 3rem;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
}

h1 {
    font-size: 4rem;
    font-weight: 800;
    background: linear-gradient(135deg, #6366f1, #ec489a);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.badge {
    display: inline-block;
    background: rgba(99, 102, 241, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 100px;
    font-size: 0.875rem;
    color: var(--primary);
    border: 1px solid var(--border-color);
}

.status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    margin-right: 0.5rem;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

/* Cards */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.card-header {
    padding: 1.5rem 1.5rem 0 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

.icon {
    font-size: 1.75rem;
}

.card-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.card-content {
    padding: 2rem 1.5rem;
    min-height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.content-text {
    font-size: 1.1rem;
    line-height: 1.6;
    text-align: center;
    color: var(--text-secondary);
    transition: opacity 0.3s ease;
}

.rizz-text {
    background: linear-gradient(135deg, #6366f1, #ec489a);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 500;
}

/* Buttons */
.btn {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
    border-radius: 12px;
    width: calc(100% - 3rem);
    margin: 0 1.5rem 1.5rem 1.5rem;
}

.btn:hover:not(:disabled) {
    border-color: var(--primary);
    transform: translateY(-2px);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary {
    background: linear-gradient(135deg, #6366f1, #ec489a);
    border: none;
    color: white;
    width: auto;
    margin: 0 auto;
    padding: 1rem 2rem;
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.4);
}

/* API Section */
.api-section {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    border: 1px solid var(--border-color);
    padding: 2rem;
    margin-top: 2rem;
}

.api-header {
    text-align: center;
    margin-bottom: 2rem;
}

.api-header h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.api-badge {
    display: inline-block;
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    padding: 0.25rem 0.75rem;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 500;
}

.endpoints-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.endpoint {
    background: rgba(0, 0, 0, 0.3);
    padding: 0.75rem 1rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    cursor: pointer;
}

.endpoint:hover {
    border-color: var(--primary);
    transform: translateX(4px);
}

.method {
    font-family: monospace;
    font-weight: 700;
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    background: var(--primary);
    color: white;
}

.method.get {
    background: var(--success);
}

.url {
    font-family: monospace;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Footer */
footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    text-align: center;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.footer-symbol {
    color: var(--primary);
    animation: pulse 2s ease-in-out infinite;
}

/* Animations */
@keyframes glowPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4); }
    50% { box-shadow: 0 0 20px 5px rgba(99, 102, 241, 0.2); }
}

.glow-effect {
    animation: glowPulse 0.5s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card {
    animation: slideIn 0.5s ease forwards;
}

.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
}

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

::-webkit-scrollbar-track {
    background: var(--darker-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .logo-icon {
        font-size: 2rem;
    }
    
    .cards {
        gap: 1rem;
    }
    
    .card-content {
        padding: 1.5rem;
        min-height: 150px;
    }
    
    .content-text {
        font-size: 0.95rem;
    }
    
    .endpoints-grid {
        grid-template-columns: 1fr;
    }
    
    .btn-primary {
        width: 100%;
    }
}