@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600&display=swap");

:root {
  color-scheme: dark;
  --bg: #0b0f14;
  --bg-2: #111827;
  --ink: #e6e9f0;
  --muted: #9aa3b2;
  --card: #141c29;
  --card-2: #0f1520;
  --accent: #63e6c7;
  --accent-ink: #061311;
  --stroke: rgba(230, 233, 240, 0.12);
  --glow: rgba(99, 230, 199, 0.2);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at top left, rgba(99, 230, 199, 0.16), transparent 45%),
    radial-gradient(circle at 20% 30%, rgba(83, 119, 255, 0.18), transparent 40%),
    linear-gradient(160deg, var(--bg), var(--bg-2));
}

a {
  color: inherit;
  text-decoration: none;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 32px clamp(20px, 4vw, 56px);
  gap: 40px;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border: 1px solid var(--stroke);
  border-radius: 999px;
  background: rgba(15, 20, 30, 0.72);
  backdrop-filter: blur(6px);
}

.brand {
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 14px;
}

.nav-links {
  display: flex;
  gap: 18px;
  font-weight: 500;
  font-size: 14px;
}

.nav-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 13px;
}

.nav-org select {
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  font-family: inherit;
  font-size: 13px;
  background: var(--card-2);
  color: inherit;
}

.org-name {
  font-weight: 600;
}

.nav-user {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.user-name {
  font-weight: 600;
}

.user-email {
  color: var(--muted);
  font-size: 12px;
}

.content {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.hero {
  max-width: 720px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.hero h1 {
  font-size: clamp(32px, 4vw, 56px);
  line-height: 1.05;
  margin: 0;
}

.hero p {
  font-size: 18px;
  color: var(--muted);
  margin: 0;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.button {
  padding: 12px 20px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  border: 1px solid rgba(0, 0, 0, 0.1);
  transition: transform 120ms ease, box-shadow 120ms ease, filter 120ms ease;
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.25);
  cursor: pointer;
}

.button-wide {
  display: inline-flex;
  justify-content: center;
  width: 100%;
}

.button.ghost {
  background: transparent;
  border: 1px solid var(--stroke);
  color: var(--ink);
  box-shadow: none;
}

.button.primary {
  background: var(--accent);
  color: var(--accent-ink);
}

.button.danger {
  background: transparent;
  color: #ffb18f;
  border: 1px solid rgba(255, 138, 91, 0.8);
  box-shadow: none;
}

.button:active {
  transform: translateY(1px) scale(0.99);
  filter: brightness(0.95);
}

.button.is-busy,
.button:disabled {
  cursor: progress;
  opacity: 0.7;
  filter: grayscale(0.2);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: rgba(15, 20, 30, 0.5);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  color: var(--muted);
}

.filter-chip.active {
  color: var(--accent-ink);
  background: var(--accent);
  border-color: rgba(0, 0, 0, 0.2);
  box-shadow: 0 10px 20px var(--glow);
}

.card {
  background: var(--card);
  border-radius: 20px;
  padding: 20px;
  border: 1px solid var(--stroke);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.card h2 {
  margin: 0;
}

.deploy-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.deploy-locked {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 8px;
}

.input-label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}

.text-input {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  font-size: 14px;
  font-family: inherit;
  background: var(--card-2);
  color: inherit;
}

.section {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.login-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.dev-login {
  margin-top: 16px;
}

.link-button {
  border: none;
  background: none;
  color: var(--muted);
  text-decoration: underline;
  cursor: pointer;
  font: inherit;
}

.form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 360px;
}

.form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}

.form input {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  font-size: 14px;
  font-family: inherit;
  background: var(--card-2);
  color: inherit;
}

.form select {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  font-size: 14px;
  font-family: inherit;
  background: var(--card-2);
  color: inherit;
}

.members {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.member-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: rgba(20, 28, 41, 0.7);
}

.member-name {
  font-weight: 600;
}

.member-email {
  color: var(--muted);
  font-size: 12px;
}

.section-header h1 {
  margin: 0 0 8px;
  font-size: clamp(28px, 3vw, 40px);
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.section-header h1::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 1.6em;
  background: var(--accent);
  border-radius: 999px;
  box-shadow: 0 0 18px var(--glow);
}

.section-header p {
  margin: 0;
  color: var(--muted);
}

.section-header h2 {
  margin: 0 0 8px;
  font-size: clamp(22px, 2.4vw, 32px);
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.section-header h2::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 1.4em;
  background: var(--accent);
  border-radius: 999px;
  box-shadow: 0 0 18px var(--glow);
}

.empty-state {
  padding: 32px;
  border-radius: 16px;
  border: 1px dashed var(--stroke);
  background: rgba(20, 28, 41, 0.5);
}

.meta {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.status {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.status-pending {
  background: rgba(242, 183, 5, 0.18);
  color: #ffd78a;
}

.status-running {
  background: rgba(55, 146, 86, 0.2);
  color: #a6f3c1;
}

.status-failed {
  background: rgba(215, 71, 71, 0.2);
  color: #ffb6b6;
}

.tag {
  display: inline-flex;
  align-self: flex-start;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(99, 230, 199, 0.2);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 600;
}

.card-actions {
  margin-top: auto;
  display: flex;
  gap: 10px;
}

.deployments-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.alert {
  padding: 12px 16px;
  border-radius: 12px;
  background: rgba(215, 71, 71, 0.2);
  border: 1px solid rgba(215, 71, 71, 0.45);
  color: #ffb6b6;
}

.details {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.deployments-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

@media (max-width: 1200px) {
  .deployments-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .deployments-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .nav {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    border-radius: 20px;
  }

  .nav-links {
    flex-wrap: wrap;
  }
}
