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

:root {
    --bg: #080c10;
    --surface: #0d1117;
    --surface-2: #161b22;
    --surface-3: #21262d;
    --border: #30363d;
    --border-light: #21262d;
    --accent: #58a6ff;
    --accent-glow: rgba(88, 166, 255, 0.15);
    --accent-dim: rgba(88, 166, 255, 0.6);
    --green: #3fb950;
    --green-glow: rgba(63, 185, 80, 0.12);
    --text-primary: #e6edf3;
    --text-secondary: #8b949e;
    --text-muted: #484f58;
    --radius: 10px;
}

body {
    font-family: 'Syne', sans-serif;
    background: var(--bg);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 48px 24px;
    position: relative;
    overflow-x: hidden;
}

/* Subtle grid background */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(48, 54, 61, 0.25) 1px, transparent 1px),
        linear-gradient(90deg, rgba(48, 54, 61, 0.25) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
    z-index: 0;
}

/* Glow orb */
body::after {
    content: '';
    position: fixed;
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 400px;
    background: radial-gradient(ellipse, rgba(88, 166, 255, 0.06) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.wrapper {
    width: 100%;
    max-width: 760px;
    position: relative;
    z-index: 1;
    animation: fadeUp 0.5s ease both;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header */
.header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 36px;
}

.header-icon {
    width: 44px;
    height: 44px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    flex-shrink: 0;
}

.header-text h1 {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: var(--text-primary);
    line-height: 1;
}

.header-text p {
    font-size: 13px;
    color: var(--text-secondary);
    font-family: 'DM Mono', monospace;
    font-weight: 300;
    margin-top: 4px;
}

/* Card */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
}

/* Section */
.section {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-light);
}

.section:last-child {
    border-bottom: none;
}

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

.section-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-secondary);
}

.section-label svg {
    color: var(--accent);
}

/* Textarea */
textarea {
    width: 100%;
    height: 200px;
    background: var(--surface-2);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 14px 16px;
    font-family: 'DM Mono', monospace;
    font-size: 13px;
    font-weight: 300;
    line-height: 1.7;
    resize: vertical;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

textarea::placeholder {
    color: var(--text-muted);
}

textarea:focus {
    border-color: var(--accent-dim);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

/* Generate Button */
.btn-generate {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--accent);
    color: #0d1117;
    border: none;
    padding: 11px 20px;
    border-radius: 8px;
    font-family: 'Syne', sans-serif;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    letter-spacing: 0.02em;
}

.btn-generate:hover {
    background: #79c0ff;
    box-shadow: 0 0 20px rgba(88, 166, 255, 0.3);
    transform: translateY(-1px);
}

.btn-generate:active {
    transform: translateY(0);
}

/* Output area */
.output-wrapper {
    position: relative;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.output-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    border-bottom: 1px solid var(--border);
}

.output-dots {
    display: flex;
    gap: 6px;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border);
}

.dot:nth-child(1) {
    background: #ff5f56;
}

.dot:nth-child(2) {
    background: #ffbd2e;
}

.dot:nth-child(3) {
    background: #27c93f;
}

.output-lang {
    font-family: 'DM Mono', monospace;
    font-size: 11px;
    color: var(--text-muted);
    letter-spacing: 0.06em;
}

pre {
    font-family: 'DM Mono', monospace;
    font-size: 13px;
    font-weight: 300;
    line-height: 1.8;
    color: #a5d6ff;
    padding: 16px 18px;
    min-height: 140px;
    overflow-x: auto;
    white-space: pre;
}

pre:empty::before,
pre.empty::before {
    content: 'Output will appear here...';
    color: var(--text-muted);
    font-style: italic;
}

/* Copy button */
.btn-copy {
    display: flex;
    align-items: center;
    gap: 7px;
    background: var(--surface-3);
    color: var(--text-secondary);
    border: 1px solid var(--border);
    padding: 8px 14px;
    border-radius: 7px;
    font-family: 'Syne', sans-serif;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-copy:hover {
    background: var(--surface-2);
    color: var(--text-primary);
    border-color: var(--accent-dim);
}

.btn-copy.copied {
    color: var(--green);
    border-color: rgba(63, 185, 80, 0.4);
    background: var(--green-glow);
}

/* Actions row */
.actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Line count badge */
.badge {
    font-family: 'DM Mono', monospace;
    font-size: 11px;
    color: var(--text-muted);
    letter-spacing: 0.04em;
}

/* Dropdown */
.dropdown {
    position: relative;
    font-family: 'DM Mono', monospace;
    font-size: 11px;
    color: var(--text-muted);
    cursor: pointer;
}

.dropdown-selected {
    padding: 4px 10px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--surface-3);
    transition: all 0.2s;
}

.dropdown-selected:hover {
    border-color: var(--accent-dim);
    color: var(--text-primary);
}

.dropdown-options {
    position: absolute;
    top: 120%;
    right: 0;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 6px;
    display: none;
    overflow: hidden;
    min-width: 120px;
    z-index: 10;
}

.dropdown-options div {
    padding: 8px 10px;
    transition: background 0.2s;
}

.dropdown::selection{
    background: none;
}

.dropdown-options div:hover {
    background: var(--surface-3);
    color: var(--text-primary);
}

.dropdown.open .dropdown-options {
    display: block;
}

/* Footer */
.footer {
    margin-top: 20px;
    text-align: center;
    font-family: 'DM Mono', monospace;
    font-size: 11px;
    color: var(--text-muted);
    letter-spacing: 0.05em;
}

.footer>a {
    color: var(--text-muted);

}