:root {
  --bg: #0d1117;
  --panel: #161b22;
  --panel-2: #1c2230;
  --line: #2a3140;
  --text: #e8edf4;
  --muted: #9aa6b8;
  --gold: #e3b341;
  --accent: #6ea8fe;
  --accent-2: #a855f7;
  --radius: 14px;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: "Segoe UI", Tahoma, system-ui, sans-serif;
  background: radial-gradient(1200px 600px at 80% -10%, #1a2030 0, var(--bg) 60%);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.7;
}
a { color: var(--accent); text-decoration: none; }

.top {
  display: flex; align-items: center; gap: 14px;
  padding: 18px 22px; border-bottom: 1px solid var(--line);
}
.brand {
  font-size: 26px; font-weight: 800;
  background: linear-gradient(90deg, var(--gold), var(--accent-2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.top .tag { color: var(--muted); font-size: 14px; }
.top .logout { margin-inline-start: auto; color: var(--muted); font-size: 14px; }

.wrap { max-width: 820px; margin: 0 auto; padding: 26px 18px 60px; }

.card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px;
}
.form .row { display: flex; gap: 14px; }
.form .row > * { flex: 1; }
@media (max-width: 620px) { .form .row { flex-direction: column; } }

label { display: block; font-size: 14px; color: var(--muted); margin-bottom: 12px; }
label.full { display: block; }
input[type=text], input[type=password], textarea, select {
  width: 100%; margin-top: 6px;
  background: var(--panel-2); border: 1px solid var(--line);
  color: var(--text); border-radius: 10px; padding: 11px 12px;
  font-family: inherit; font-size: 15px;
}
textarea { resize: vertical; }
input:focus, textarea:focus, select:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(110,168,254,.15);
}

.controls { align-items: end; flex-wrap: wrap; gap: 18px; }
.controls .num { flex: 0 0 120px; }
.switch {
  display: flex; align-items: center; gap: 7px; color: var(--text);
  font-size: 15px; margin: 0; flex: 0 0 auto;
}
.switch input { width: auto; margin: 0; }
.go {
  margin-inline-start: auto; flex: 0 0 auto;
  background: linear-gradient(90deg, var(--gold), #f0c869);
  color: #1a1407; font-weight: 800; font-size: 16px;
  border: none; border-radius: 10px; padding: 12px 22px; cursor: pointer;
  transition: transform .12s ease, filter .12s ease;
}
.go:hover { filter: brightness(1.05); transform: translateY(-1px); }
.go:disabled { opacity: .7; cursor: progress; }

.results { margin-top: 28px; }
.results h2 { font-size: 18px; margin: 0 0 16px; }
.post {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 18px; margin-bottom: 14px;
}
.post-head { display: flex; align-items: center; margin-bottom: 10px; }
.badge {
  background: var(--panel-2); border: 1px solid var(--line);
  color: var(--gold); font-size: 13px; padding: 3px 10px; border-radius: 999px;
}
.copy {
  margin-inline-start: auto; background: var(--accent); color: #07121f;
  border: none; border-radius: 8px; padding: 6px 14px; font-weight: 700;
  cursor: pointer; font-size: 13px;
}
.copy.done { background: #2ea043; color: #fff; }
.post-body { white-space: pre-wrap; font-size: 15.5px; }

.alert {
  background: rgba(248,81,73,.12); border: 1px solid rgba(248,81,73,.4);
  color: #ffb4af; border-radius: 10px; padding: 12px 14px;
}

.foot { text-align: center; color: var(--muted); font-size: 13px; padding: 30px 0; }

/* صفحة الدخول */
.login-body { display: grid; place-items: center; }
.login-card {
  width: min(360px, 92vw); margin-top: 16vh; text-align: center;
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 30px 26px;
}
.login-card .brand { font-size: 34px; margin-bottom: 4px; }
.login-card .muted { color: var(--muted); margin: 0 0 18px; font-size: 14px; }
.login-card button {
  width: 100%; margin-top: 12px; background: var(--gold); color: #1a1407;
  font-weight: 800; border: none; border-radius: 10px; padding: 12px; cursor: pointer;
}
