:root {
  --bg: #0b0f19;
  --card: #131c2c;
  --card-2: #1a2438;
  --border: #26324a;
  --text: #e8edf7;
  --muted: #93a1b8;
  --accent: #e94560;
  --accent-2: #7c3aed;
  --good: #34d399;
  --bad: #f87171;
  --warn: #fbbf24;
  --radius: 16px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: "Segoe UI", Tahoma, -apple-system, BlinkMacSystemFont, sans-serif;
  background:
    radial-gradient(1000px 520px at 88% -10%, rgba(124, 58, 237, 0.28), transparent 62%),
    radial-gradient(900px 480px at -5% 0%, rgba(233, 69, 96, 0.18), transparent 58%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  min-height: 100vh;
  line-height: 1.75;
  direction: rtl;
}

a { color: #a5b4fc; text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  width: min(860px, 100% - 32px);
  margin: 0 auto;
  padding: 56px 0 40px;
}

.hero { text-align: center; margin-bottom: 36px; }

.logo {
  width: 66px;
  height: 66px;
  margin: 0 auto 18px;
  display: grid;
  place-items: center;
  border-radius: 20px;
  font-size: 28px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 18px 40px rgba(124, 58, 237, 0.35);
}

h1 { font-size: clamp(28px, 5vw, 42px); line-height: 1.25; letter-spacing: -0.5px; }
h1 span {
  background: linear-gradient(90deg, #fb7185, #a78bfa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.tagline { color: var(--muted); margin-top: 10px; font-size: 16px; }

.chips { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 22px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid var(--border);
  background: rgba(19, 28, 44, 0.75);
  color: var(--muted);
}
.chip::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.chip.good { color: var(--good); border-color: rgba(52, 211, 153, 0.35); }
.chip.bad { color: var(--bad); border-color: rgba(248, 113, 113, 0.35); }

.card {
  background: linear-gradient(180deg, rgba(26, 36, 56, 0.92), rgba(19, 28, 44, 0.92));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  margin-bottom: 20px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
}

.card h2 { font-size: 20px; margin-bottom: 16px; }
.card h2::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 20px;
  border-radius: 3px;
  margin-left: 10px;
  vertical-align: -3px;
  background: linear-gradient(180deg, var(--accent), var(--accent-2));
}

.install-buttons { display: flex; flex-wrap: wrap; gap: 12px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 22px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--card-2);
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.btn:hover { transform: translateY(-1px); background: #22304b; text-decoration: none; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }

.btn.primary {
  background: linear-gradient(135deg, var(--accent), #c026d3);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 12px 28px rgba(233, 69, 96, 0.3);
}
.btn.primary:hover { background: linear-gradient(135deg, #f0506a, #a21caf); }

.btn.ghost { background: transparent; }

.steps { padding-right: 22px; display: grid; gap: 10px; color: #cbd5e1; }
.steps li::marker { color: var(--accent); font-weight: 700; }

.note {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: 10px;
  border: 1px solid rgba(251, 191, 36, 0.25);
  background: rgba(251, 191, 36, 0.08);
  color: #fde68a;
  font-size: 13.5px;
}
.note.info {
  border-color: rgba(165, 180, 252, 0.25);
  background: rgba(99, 102, 241, 0.1);
  color: #c7d2fe;
}
.note.danger {
  border-color: rgba(248, 113, 113, 0.3);
  background: rgba(248, 113, 113, 0.08);
  color: #fecaca;
}

.muted { color: var(--muted); }
.small { font-size: 13px; }
.mt { margin-top: 14px; }

label { display: block; margin: 18px 0 6px; font-size: 13px; font-weight: 700; color: #b8c4d8; }

input[type="password"],
input[type="url"],
input[type="text"] {
  width: 100%;
  padding: 13px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #0d1420;
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
input:focus {
  outline: none;
  border-color: var(--accent-2);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.18);
}
input:disabled { opacity: 0.6; cursor: not-allowed; }
input::placeholder { color: #5f6f88; }

.row { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; margin-top: 22px; }

.status { font-size: 14px; font-weight: 600; }
.status.ok { color: var(--good); }
.status.err { color: var(--bad); }

details.danger {
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px dashed var(--border);
}
details.danger summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  user-select: none;
}
details.danger summary:hover { color: var(--text); }

.check {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 12px;
  font-size: 13.5px;
  font-weight: 500;
  color: #cbd5e1;
  cursor: pointer;
}
.check input { width: 16px; height: 16px; accent-color: var(--accent); cursor: pointer; }

.footer {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  padding: 8px 0 0;
  font-size: 13px;
  color: var(--muted);
}

.back { display: inline-block; margin-bottom: 18px; font-size: 14px; }

.badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  background: rgba(148, 163, 184, 0.15);
  color: #cbd5e1;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.brand { display: flex; align-items: center; gap: 14px; }
.brand-badge {
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 18px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 10px 26px rgba(124, 58, 237, 0.3);
}
.brand h1 { font-size: 22px; line-height: 1.25; }
.brand p { margin-top: 2px; }

.topbar-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.small-btn { padding: 9px 14px; font-size: 13px; }

.dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 172px;
  padding: 26px;
  margin: 8px 0 22px;
  border: 2px dashed var(--border);
  border-radius: 14px;
  background: rgba(13, 20, 32, 0.55);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}
.dropzone:hover,
.dropzone.drag {
  border-color: var(--accent-2);
  background: rgba(124, 58, 237, 0.1);
}
.dropzone.drag { transform: scale(1.01); }
.drop-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 20px;
  color: #c4b5fd;
  background: rgba(124, 58, 237, 0.18);
  border: 1px solid rgba(124, 58, 237, 0.35);
}
.drop-title { font-size: 15px; font-weight: 600; }

.file-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  margin-bottom: 18px;
  border: 1px solid rgba(52, 211, 153, 0.3);
  background: rgba(52, 211, 153, 0.08);
  border-radius: 10px;
  overflow-wrap: anywhere;
}

select {
  width: 100%;
  padding: 13px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #0d1420;
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
}
select:focus {
  outline: none;
  border-color: var(--accent-2);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.18);
}
option { background: #0d1420; color: var(--text); }

.result-chips { justify-content: flex-start; margin: 0 0 10px; }

.preview {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px dashed var(--border);
}
.preview summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  user-select: none;
}
.preview summary:hover { color: var(--text); }
.preview pre {
  margin-top: 12px;
  padding: 16px;
  max-height: 360px;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #0a101b;
  font-size: 12.5px;
  line-height: 1.65;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.login-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 40px);
  padding: 24px 0;
}
.login-card {
  width: min(430px, 100%);
  margin: 0;
  text-align: center;
}
.login-card .logo { margin-bottom: 18px; }
.login-card h1 { font-size: 26px; margin-bottom: 8px; }
.login-card form { text-align: right; margin-top: 6px; }
.login-card .row { justify-content: center; }

code {
  padding: 2px 6px;
  border-radius: 5px;
  background: rgba(148, 163, 184, 0.15);
  font-size: 12.5px;
}

@media (max-width: 560px) {
  .container { padding-top: 36px; }
  .card { padding: 22px 18px; }
  .install-buttons .btn { width: 100%; }
  .topbar { align-items: flex-start; }
  .topbar-actions { width: 100%; }
  .topbar-actions .btn { flex: 1; }
  .file-info { flex-direction: column; align-items: flex-start; gap: 2px; }
}

