:root {
    --bg-grad-1: #0f172a;
    --bg-grad-2: #1e293b;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --accent: #3b82f6;
    --accent-hover: #2563eb;
    --success: #10b981;
}

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

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(135deg, var(--bg-grad-1), var(--bg-grad-2));
    min-height: 100vh;
    color: var(--text-primary);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.glass-container {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 3rem;
    width: 100%;
    max-width: 900px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

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

header h1 {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.badge {
    background: rgba(59, 130, 246, 0.2);
    color: var(--accent);
    font-size: 1rem;
    padding: 4px 10px;
    border-radius: 12px;
    font-weight: 500;
}

header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Tabs */
.tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 1rem;
}

.tab-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.tab-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.tab-btn.active {
    color: var(--accent);
    background: rgba(59, 130, 246, 0.1);
}

/* Sections */
.section {
    display: none;
    animation: fadeIn 0.4s ease forwards;
}

.section.active {
    display: block;
}

/* Drop Zone */
.drop-zone {
    border: 2px dashed var(--glass-border);
    border-radius: 16px;
    padding: 4rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(0, 0, 0, 0.2);
}

.drop-zone:hover, .drop-zone.dragover {
    border-color: var(--accent);
    background: rgba(59, 130, 246, 0.05);
}

.drop-zone-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    color: var(--text-secondary);
}

.drop-zone-content .icon {
    color: var(--accent);
    transition: transform 0.3s ease;
}

.drop-zone:hover .icon {
    transform: translateY(-5px);
}

.drop-zone-text {
    font-size: 1.2rem;
}

/* Text Area */
textarea {
    width: 100%;
    height: 250px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1.5rem;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    outline: none;
    transition: border-color 0.3s ease;
    margin-bottom: 1.5rem;
}

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

textarea::placeholder {
    color: var(--text-secondary);
    opacity: 0.7;
}

/* Buttons */
.primary-btn, .secondary-btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.primary-btn {
    background: var(--accent);
    color: white;
    width: 100%;
}

.primary-btn:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -10px rgba(59, 130, 246, 0.5);
}

.secondary-btn {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.secondary-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* Result Area */
.result-area {
    margin-top: 2rem;
    border-top: 1px solid var(--glass-border);
    padding-top: 2rem;
}

.result-area.hidden {
    display: none;
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.count-badge {
    font-size: 0.9rem;
    background: rgba(16, 185, 129, 0.2);
    color: var(--success);
    padding: 2px 8px;
    border-radius: 8px;
    margin-left: 8px;
}

.code-container {
    background: #000;
    border-radius: 12px;
    padding: 1.5rem;
    overflow-x: auto;
    position: relative;
    max-height: 400px;
    overflow-y: auto;
}

pre {
    margin: 0;
    color: #a5b4fc;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}
