:root {
  --bg: #0f1115;
  --panel: #181b22;
  --line: #262b35;
  --txt: #e8eaed;
  --muted: #9aa3b2;
  --accent: #4f8cff;
  --accent-2: #2bd4a4;
  --err: #ff6b6b;
}
* { box-sizing: border-box; }
body {
  margin: 0; font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg); color: var(--txt);
}
.hidden { display: none !important; }
.muted { color: var(--muted); }
.err { color: var(--err); }

/* Login */
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px;
  padding: 32px; width: 100%; max-width: 360px; text-align: center;
}
.login-card h1 { margin: 0 0 4px; letter-spacing: .5px; }
.login-card input {
  width: 100%; margin: 18px 0 12px; padding: 12px 14px; border-radius: 10px;
  border: 1px solid var(--line); background: #11141a; color: var(--txt);
}
.login-card button, .action, .ghost {
  cursor: pointer; border: none; border-radius: 10px; font-weight: 600;
}
.login-card button {
  width: 100%; padding: 12px; background: var(--accent); color: #fff;
}

/* App */
header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 24px; border-bottom: 1px solid var(--line);
}
.brand { font-weight: 800; font-size: 18px; letter-spacing: .5px; }
nav select {
  padding: 8px 12px; border-radius: 8px; background: #11141a;
  color: var(--txt); border: 1px solid var(--line);
}
main {
  display: grid; grid-template-columns: 1fr 1fr; gap: 20px;
  padding: 24px; max-width: 1200px; margin: 0 auto;
}
@media (max-width: 880px) { main { grid-template-columns: 1fr; } }
.panel {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 14px; padding: 20px;
}
.panel h2 { font-size: 14px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); }
textarea {
  width: 100%; min-height: 240px; resize: vertical; padding: 14px;
  border-radius: 10px; border: 1px solid var(--line);
  background: #11141a; color: var(--txt); font-size: 14px; line-height: 1.5;
}
.actions { display: grid; gap: 10px; margin-top: 8px; }
.action {
  padding: 14px; background: #20242e; color: var(--txt);
  text-align: left; border: 1px solid var(--line); font-size: 15px;
}
.action:hover { border-color: var(--accent); }
.action.publish { background: linear-gradient(90deg, var(--accent), var(--accent-2)); color: #06121a; }
.result-head { display: flex; justify-content: space-between; align-items: center; }
.ghost { background: transparent; color: var(--accent); padding: 6px 12px; border: 1px solid var(--line); }
.status { color: var(--muted); min-height: 20px; margin: 8px 0; font-size: 13px; }
.result {
  white-space: pre-wrap; word-break: break-word; background: #11141a;
  border: 1px solid var(--line); border-radius: 10px; padding: 16px;
  min-height: 240px; font-size: 14px; line-height: 1.55; margin: 0;
}
