/* ─── Custom Properties ─── */ :root { --bg: #0f1117; --surface: #1a1d27; --surface2: #23263a; --accent: #7c3aed; --accent-hover: #6d28d9; --text: #e2e8f0; --text-muted: #8892a4; --border: #2a2d3e; --error: #f87171; --radius: 6px; --mono: 'Fira Code', 'Cascadia Code', 'Consolas', 'Monaco', monospace; --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; } *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; } html, body { height: 100%; } body { background: var(--bg); color: var(--text); font-family: var(--sans); line-height: 1.5; display: flex; flex-direction: column; min-height: 100vh; } /* ─── Header ─── */ header { background: var(--surface); border-bottom: 1px solid var(--border); height: 54px; padding: 0 1.5rem; display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; } .logo { font-size: 1.15rem; font-weight: 700; color: var(--accent); text-decoration: none; letter-spacing: -0.01em; } .header-actions { display: flex; align-items: center; gap: 0.75rem; } /* ─── Main ─── */ main { flex: 1; display: flex; flex-direction: column; padding: 1.5rem; max-width: 1040px; width: 100%; margin: 0 auto; } /* ─── Buttons ─── */ .btn, button { display: inline-flex; align-items: center; justify-content: center; background: var(--accent); color: #fff; border: none; border-radius: var(--radius); padding: 0.4rem 0.9rem; font-size: 0.85rem; font-weight: 600; cursor: pointer; text-decoration: none; transition: background 0.15s, opacity 0.15s; white-space: nowrap; line-height: 1.4; font-family: var(--sans); } .btn:hover, button:hover { background: var(--accent-hover); } button:disabled { opacity: 0.55; cursor: not-allowed; } /* ─── Editor Card ─── */ .editor-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); display: flex; flex-direction: column; flex: 1; width: calc(100vw - 3rem); margin-left: calc(50% - 50vw + 1.5rem); overflow: hidden; } .toolbar { display: flex; align-items: center; gap: 0.75rem; padding: 0.5rem 0.75rem; background: var(--surface2); border-bottom: 1px solid var(--border); flex-shrink: 0; } select { background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: var(--radius); padding: 0.3rem 0.55rem; font-size: 0.85rem; font-family: var(--sans); cursor: pointer; outline: none; } select:focus { border-color: var(--accent); } .char-count { font-size: 0.78rem; color: var(--text-muted); margin-left: auto; margin-right: 0.25rem; font-variant-numeric: tabular-nums; } .char-count.over { color: var(--error); } /* ─── Editor body (line numbers + textarea side by side) ─── */ .editor-body { display: flex; flex: 1; overflow: hidden; min-height: 440px; } .editor-stack { position: relative; flex: 1; overflow: hidden; } .line-numbers { padding: 1rem 0.65rem 1rem 0.75rem; font-family: var(--mono); font-size: 0.9rem; line-height: 1.65; color: var(--text-muted); text-align: right; white-space: pre; overflow: hidden; user-select: none; -webkit-user-select: none; flex-shrink: 0; min-width: 2.8rem; background: var(--surface2); border-right: 1px solid var(--border); } textarea#content { position: absolute; inset: 0; background: transparent; color: transparent; caret-color: var(--text); border: none; outline: none; padding: 1rem; font-family: var(--mono); font-size: 0.9rem; line-height: 1.65; resize: none; tab-size: 2; overflow: auto; z-index: 2; } textarea#content::placeholder { color: var(--text-muted); } #editor-highlight { position: absolute; inset: 0; margin: 0; padding: 1rem; overflow: hidden; pointer-events: none; z-index: 1; } #editor-highlight-code { font-family: var(--mono); font-size: 0.9rem; line-height: 1.65; white-space: pre; display: block; min-height: 100%; } #editor-highlight-code.hljs { background: transparent; padding: 0; } /* ─── Result / Error boxes ─── */ .result-box { margin-top: 1rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 0.85rem 1.1rem; display: flex; align-items: center; gap: 0.9rem; flex-wrap: wrap; } .result-label { font-size: 0.8rem; color: var(--text-muted); flex-shrink: 0; } .result-box a { color: var(--accent); font-family: var(--mono); font-size: 0.875rem; word-break: break-all; flex: 1; min-width: 0; } .error-box { margin-top: 0.9rem; color: var(--error); background: rgba(248, 113, 113, 0.08); border: 1px solid rgba(248, 113, 113, 0.25); border-radius: var(--radius); padding: 0.75rem 1rem; font-size: 0.875rem; } .hidden { display: none !important; } /* ─── Paste View ─── */ .paste-view { padding-top: 1.25rem; max-width: none; width: calc(100vw - 3rem); margin-left: calc(50% - 50vw + 1.5rem); } .paste-meta { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.75rem; min-height: 1.5rem; } .paste-meta #copy-btn { margin-left: auto; } .paste-meta-actions { margin-left: auto; display: flex; gap: 0.4rem; } .meta-action { display: inline-flex; align-items: center; background: transparent; color: var(--text-muted); border: 1px solid var(--border); border-radius: var(--radius); padding: 0.2rem 0.6rem; font-size: 0.78rem; font-weight: 500; cursor: pointer; text-decoration: none; transition: color 0.15s, border-color 0.15s; font-family: var(--sans); white-space: nowrap; line-height: 1.4; } .meta-action:hover { color: var(--text); border-color: var(--text-muted); background: transparent; } .lang-badge { background: var(--surface2); border: 1px solid var(--border); border-radius: 4px; padding: 0.15rem 0.5rem; font-size: 0.75rem; font-family: var(--mono); color: var(--text-muted); text-transform: lowercase; } .paste-date { font-size: 0.78rem; color: var(--text-muted); } .meta-url-btn { max-width: 360px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--accent); font-family: var(--mono); } .meta-url-btn:hover { color: var(--text); } .paste-url-status { font-size: 0.78rem; color: var(--accent); min-width: 3.8rem; text-align: center; } #paste-content { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: auto; flex: 1; display: flex; width: calc(100vw - 3rem); margin-left: calc(50% - 50vw + 1.5rem); } #paste-content pre { flex: 1; margin: 0; padding: 1rem; overflow: visible; } #paste-content code { font-family: var(--mono); font-size: 0.9rem; line-height: 1.65; white-space: pre; color: var(--text); display: block; } #paste-content code.hljs { background: transparent; padding: 0; } /* ─── Not Found / Error state ─── */ .not-found { display: flex; flex-direction: column; align-items: center; justify-content: center; flex: 1; padding: 4rem 2rem; text-align: center; gap: 0.75rem; } .not-found h2 { font-size: 4rem; font-weight: 800; color: var(--border); line-height: 1; } .not-found p { color: var(--text-muted); margin-bottom: 0.5rem; } /* ─── Responsive ─── */ @media (max-width: 600px) { main, header { padding-left: 1rem; padding-right: 1rem; } .toolbar { flex-wrap: wrap; } .char-count { order: 3; width: 100%; margin: 0; } }