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

:root {
    --bg-primary: #1a1a1a;
    --bg-secondary: #2a2a2a;
    --bg-tertiary: #3a3a3a;
    --text-primary: #e0e0e0;
    --text-secondary: #a0a0a0;
    --accent: #7c3aed;
    --accent-hover: #8b5cf6;
    --border: #404040;
    --success: #10b981;
    --error: #ef4444;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d1b4e 100%);
    color: var(--text-primary);
    min-height: 100vh;
    padding: 20px;
    line-height: 1.6;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

header {
    text-align: center;
    margin-bottom: 40px;
    padding: 30px;
    background: var(--bg-secondary);
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    background: linear-gradient(135deg, #7c3aed, #a855f7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.toggle-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.toggle-group {
    display: flex;
    gap: 0;
    background: var(--bg-primary);
    border-radius: 6px;
    padding: 3px;
    border: 1px solid var(--border);
}

.toggle-btn {
    padding: 6px 16px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.3s;
    font-family: inherit;
}

.toggle-btn:hover {
    color: var(--text-primary);
}

.toggle-btn.active {
    background: var(--accent);
    color: white;
}

.converter-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

@media (max-width: 968px) {
    .converter-section {
        grid-template-columns: 1fr;
    }
}

.input-section,
.output-section {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.section-header h2 {
    font-size: 1.5rem;
    color: var(--text-primary);
}

textarea {
    width: 100%;
    min-height: 400px;
    padding: 15px;
    background: var(--bg-primary);
    border: 2px solid var(--border);
    border-radius: 8px;
    color: var(--text-primary);
    font-family: 'Courier New', monospace;
    font-size: 14px;
    resize: vertical;
    transition: border-color 0.3s;
}

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

textarea[readonly] {
    background: var(--bg-tertiary);
    cursor: default;
}

.button-group {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.btn-primary,
.btn-secondary {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-family: inherit;
}

.btn-primary {
    background: var(--accent);
    color: white;
    flex: 1;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg-primary);
    border-color: var(--accent);
}

.info-section {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

details {
    cursor: pointer;
}

summary {
    font-size: 1.2rem;
    font-weight: 600;
    padding: 10px;
    user-select: none;
}

summary:hover {
    color: var(--accent);
}

.info-content {
    padding: 20px;
    margin-top: 10px;
    background: var(--bg-primary);
    border-radius: 8px;
}

.info-content h3 {
    margin-top: 20px;
    margin-bottom: 10px;
    color: var(--accent);
}

.info-content ul {
    margin-left: 20px;
    margin-bottom: 15px;
}

.info-content li {
    margin-bottom: 8px;
}

.info-content code {
    background: var(--bg-tertiary);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    color: var(--accent);
}

/* Notification styles */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 25px;
    background: var(--accent);
    color: white;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    animation: slideIn 0.3s ease-out;
}

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