:root {
    --bg: #0d1117;
    --surface: #161b22;
    --fg: #e6edf3;
    --muted: #7d8590;
    --accent: #58a6ff;
    --success: #238636;
    --success-hover: #2ea043;
    --error: #f85149;
    --border: #30363d;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
    background: var(--bg);
    color: var(--fg);
    line-height: 1.5;
    min-height: 100vh;
}

main {
    max-width: 720px;
    margin: 0 auto;
    padding: 4rem 1.5rem;
}

h1 {
    font-weight: 600;
    margin-top: 0;
    margin-bottom: 1.5rem;
    font-size: 1.75rem;
}

p { color: var(--muted); }
p strong { color: var(--fg); }

form {
    display: grid;
    gap: 1rem;
}

label {
    display: grid;
    gap: 0.35rem;
    color: var(--muted);
    font-size: 0.9rem;
}

input, textarea, button {
    font: inherit;
    background: var(--surface);
    color: var(--fg);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 0.6rem 0.8rem;
    width: 100%;
}

input:focus, textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(88, 166, 255, 0.15);
}

textarea {
    resize: vertical;
    min-height: 18rem;
    font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
    font-size: 0.95rem;
}

button {
    cursor: pointer;
    background: var(--success);
    border-color: var(--success);
    color: white;
    font-weight: 600;
    padding: 0.7rem 1.2rem;
    width: auto;
    justify-self: start;
}

button:hover {
    background: var(--success-hover);
    border-color: var(--success-hover);
}

.error {
    background: rgba(248, 81, 73, 0.1);
    border: 1px solid var(--error);
    color: var(--error);
    padding: 0.75rem 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

pre {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 1rem;
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-word;
    font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
    font-size: 0.9rem;
    color: var(--fg);
}

pre.link {
    word-break: break-all;
    user-select: all;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover { text-decoration: underline; }

.actions {
    display: flex;
    gap: 1.5rem;
    margin-top: 1.5rem;
    color: var(--muted);
}
