:root {
    --bg-dark: #0f172a;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --secondary: #334155;
    --secondary-hover: #475569;
    --glass-bg: rgba(30, 41, 59, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
    --blob-1: #3b82f6;
    --blob-2: #8b5cf6;
}

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

.background-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    filter: blur(100px);
    opacity: 0.4;
    border-radius: 50%;
    animation: float 10s ease-in-out infinite alternate;
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: var(--blob-1);
}

.blob-2 {
    bottom: -10%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: var(--blob-2);
    animation-delay: -5s;
}

@keyframes float {
    0% { transform: translateY(0) scale(1); }
    100% { transform: translateY(40px) scale(1.1); }
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 3rem 1.5rem;
}

header {
    text-align: center;
    margin-bottom: 3rem;
}

.badge {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    border-radius: 2rem;
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.highlight {
    background: linear-gradient(to right, #60a5fa, #a78bfa);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

header p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.api-setup {
    background: rgba(15, 23, 42, 0.8);
    padding: 1rem 1.5rem;
    border-radius: 0.75rem;
    border: 1px solid var(--glass-border);
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.api-setup label {
    font-weight: 600;
    color: var(--text-muted);
    white-space: nowrap;
}

.api-setup input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-main);
    font-size: 1rem;
    font-family: monospace;
    outline: none;
}

.input-section {
    margin-bottom: 2rem;
}

textarea {
    width: 100%;
    height: 150px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--glass-border);
    border-radius: 0.75rem;
    padding: 1rem;
    color: var(--text-main);
    font-family: 'Outfit', sans-serif;
    font-size: 1.1rem;
    resize: vertical;
    outline: none;
    transition: border-color 0.3s ease;
    margin-bottom: 1.5rem;
}

textarea:focus {
    border-color: var(--primary);
}

.actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    padding: 0.8rem 1.5rem;
    border-radius: 0.5rem;
    border: none;
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 14px rgba(59, 130, 246, 0.4);
}

.btn-primary:hover {
    background: var(--primary-hover);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.6);
}

.btn-secondary {
    background: var(--secondary);
    color: white;
}

.btn-secondary:hover {
    background: var(--secondary-hover);
}

.response-section {
    margin-bottom: 3rem;
}

.response-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 1rem;
}

.response-header h3 {
    font-size: 1.2rem;
    color: var(--text-muted);
}

.response-content pre {
    background: rgba(0, 0, 0, 0.3);
    padding: 1.5rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    font-family: monospace;
    font-size: 1rem;
    color: #a78bfa;
    min-height: 100px;
}

.loader {
    width: 24px;
    height: 24px;
    border: 3px solid rgba(255,255,255,0.1);
    border-radius: 50%;
    border-top-color: var(--primary);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.features-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.feature-card {
    padding: 1.5rem;
}

.feature-card h3 {
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.feature-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

footer {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--glass-border);
}

footer p {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
}

@media (max-width: 600px) {
    h1 { font-size: 2.2rem; }
    .actions { flex-direction: column; }
    .btn { width: 100%; justify-content: center; }
}
