:root {
  --ebsuite-bg: #070511;
  --ebsuite-panel: #120f22;
  --ebsuite-border: rgba(255, 255, 255, 0.08);
  --ebsuite-highlight: linear-gradient(135deg, #8b5cf6, #ec4899);
  --ebsuite-muted: rgba(255, 255, 255, 0.6);
  --ebsuite-text: #f8f7ff;
}

.ebsuite-wrapper {
  margin: 30px 0;
  font-family: 'Kanit', 'Segoe UI', Tahoma, sans-serif;
  color: var(--ebsuite-text);
}

.ebsuite-shell {
  display: flex;
  gap: 24px;
  background: radial-gradient(circle at top, rgba(139, 92, 246, 0.18), transparent) var(--ebsuite-bg);
  border-radius: 26px;
  border: 1px solid var(--ebsuite-border);
  overflow: hidden;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.35);
}

.ebsuite-sidebar {
  width: 260px;
  padding: 28px 24px;
  background: rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  gap: 24px;
  border-right: 1px solid var(--ebsuite-border);
}

.ebsuite-sidebar__header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.ebsuite-logo {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  letter-spacing: 0.04em;
  background: var(--ebsuite-highlight);
  color: #fff;
}

.ebsuite-subtitle {
  margin: 0;
  font-size: 0.9rem;
  color: var(--ebsuite-muted);
}

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

.ebsuite-nav button {
  display: flex;
  align-items: center;
  gap: 10px;
  background: transparent;
  border: 1px solid transparent;
  color: var(--ebsuite-text);
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.25s ease;
}

.ebsuite-nav button:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
}

.ebsuite-nav button.is-active {
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(139, 92, 246, 0.15);
  box-shadow: inset 0 0 20px rgba(139, 92, 246, 0.25);
}

.ebsuite-user {
  margin-bottom: 8px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid var(--ebsuite-border);
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.9rem;
  color: var(--ebsuite-muted);
}

.ebsuite-user p {
  margin: 0 0 10px;
}

.ebsuite-logout {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  color: #f87171;
  text-decoration: none;
}

.ebsuite-logout:hover {
  color: #fecdd3;
}

.ebsuite-nav .dashicons {
  font-size: 20px;
}

.ebsuite-content {
  flex: 1;
  padding: 24px;
  background: var(--ebsuite-panel);
}

.ebsuite-panel {
  display: none;
  animation: ebsuiteFade 0.35s ease;
}

.ebsuite-panel.is-active {
  display: block;
}

.ebsuite-login {
  display: flex;
  justify-content: center;
}

.ebsuite-login__panel {
  width: min(520px, 100%);
  padding: 32px;
  border-radius: 24px;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid var(--ebsuite-border);
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
}

.ebsuite-login__panel h2 {
  margin-top: 0;
  margin-bottom: 8px;
}

.ebsuite-login__panel p {
  color: var(--ebsuite-muted);
}

.ebsuite-login__form {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.ebsuite-login__form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-weight: 500;
}

.ebsuite-login__form input {
  border-radius: 10px;
  border: 1px solid var(--ebsuite-border);
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--ebsuite-text);
}

.ebsuite-login__form input:focus {
  outline: 2px solid rgba(139, 92, 246, 0.4);
  outline-offset: 1px;
}

.ebsuite-login__form button {
  border: 0;
  border-radius: 12px;
  padding: 12px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  background: var(--ebsuite-highlight);
  color: #fff;
  transition: opacity 0.2s ease;
}

.ebsuite-login__form button:hover {
  opacity: 0.9;
}

.ebsuite-login__alert {
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
}

.ebsuite-login__alert.is-error {
  background: rgba(248, 113, 113, 0.15);
  border: 1px solid rgba(248, 113, 113, 0.4);
  color: #fecaca;
}

.ebsuite-login__alert.is-success {
  background: rgba(74, 222, 128, 0.15);
  border: 1px solid rgba(74, 222, 128, 0.4);
  color: #bbf7d0;
}

.ebsuite-login__hint {
  margin-top: 16px;
  font-size: 0.9rem;
  color: var(--ebsuite-muted);
}

.ebsuite-admin-board {
  background: rgba(6, 0, 22, 0.65);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 30px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.ebsuite-admin-board__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.ebsuite-admin-board__header h3 {
  margin: 0 0 6px;
  font-size: 1.4rem;
}

.ebsuite-admin-board__header p {
  margin: 0;
  color: var(--ebsuite-muted);
}

.ebsuite-add-admin-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  border: 0;
}

.ebsuite-add-admin-button:hover {
  opacity: 0.9;
}

.ebsuite-panel-alert {
  margin: 16px 0;
  padding: 12px 16px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.ebsuite-panel-alert.is-error {
  background: rgba(248, 113, 113, 0.15);
  border: 1px solid rgba(248, 113, 113, 0.4);
  color: #fecaca;
}

.ebsuite-panel-alert.is-success {
  background: rgba(74, 222, 128, 0.15);
  border: 1px solid rgba(74, 222, 128, 0.4);
  color: #bbf7d0;
}

.ebsuite-admin-table {
  display: flex;
  flex-direction: column;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 18px;
  border: 1px solid var(--ebsuite-border);
  overflow: hidden;
}

.ebsuite-admin-table__head {
  display: grid;
  grid-template-columns: 2.4fr 2fr 1.4fr 1fr;
  gap: 14px;
  padding: 14px 20px;
  font-weight: 600;
  font-size: 0.9rem;
  background: rgba(255, 255, 255, 0.04);
}

.ebsuite-admin-row {
  display: grid;
  grid-template-columns: 2.4fr 2fr 1.4fr 1fr;
  gap: 14px;
  padding: 16px 20px;
  border-top: 1px solid var(--ebsuite-border);
  align-items: center;
}

.ebsuite-admin-row.is-owner {
  background: rgba(255, 255, 255, 0.02);
}

.ebsuite-admin-cell {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.95rem;
}

.ebsuite-admin-cell--user {
  flex-direction: row;
  align-items: center;
  gap: 12px;
}

.ebsuite-avatar {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
}

.ebsuite-admin-user {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ebsuite-display-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.8rem;
}

.ebsuite-display-field input {
  border-radius: 10px;
  border: 1px solid var(--ebsuite-border);
  padding: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--ebsuite-text);
}

.ebsuite-username {
  font-size: 0.85rem;
  color: var(--ebsuite-muted);
}

.ebsuite-admin-user small {
  color: var(--ebsuite-muted);
}

.ebsuite-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  margin-left: 8px;
}

.ebsuite-tag.is-owner {
  background: rgba(248, 250, 92, 0.2);
  color: #fef08a;
}

.ebsuite-switch {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid var(--ebsuite-border);
  background: rgba(255, 255, 255, 0.03);
}

.ebsuite-switch input {
  width: 42px;
  height: 22px;
  appearance: none;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  position: relative;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.1);
}

.ebsuite-switch input::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #f8fafc;
  transition: transform 0.2s ease;
}

.ebsuite-switch input:checked {
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  border-color: #7c3aed;
}

.ebsuite-switch input:checked::after {
  transform: translateX(18px);
}

.ebsuite-switch--status input {
  border-color: rgba(59, 130, 246, 0.6);
}

.ebsuite-switch span {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ebsuite-switch strong {
  font-size: 0.95rem;
}

.ebsuite-switch small {
  color: var(--ebsuite-muted);
  font-size: 0.8rem;
}

.ebsuite-admin-cell--password input {
  border-radius: 10px;
  border: 1px solid var(--ebsuite-border);
  padding: 10px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--ebsuite-text);
}

.ebsuite-admin-cell--password small {
  color: var(--ebsuite-muted);
  font-size: 0.75rem;
}

.ebsuite-admin-cell--actions {
  align-items: flex-start;
}

.ebsuite-lock-note {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ebsuite-muted);
}

.ebsuite-action-delete {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fecdd3;
}

.ebsuite-action-delete input {
  transform: scale(1.1);
}

.ebsuite-panel-note {
  margin: 12px 0 18px;
  color: var(--ebsuite-muted);
  font-size: 0.9rem;
}

.ebsuite-add-user {
  border: 1px dashed var(--ebsuite-border);
  border-radius: 14px;
  padding: 18px;
  margin-bottom: 18px;
}

.ebsuite-add-user__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.ebsuite-add-user__grid label,
.ebsuite-add-user__permissions label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.9rem;
}

.ebsuite-add-user__grid input,
.ebsuite-admin-table input[type="password"] {
  border-radius: 10px;
  border: 1px solid var(--ebsuite-border);
  padding: 10px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--ebsuite-text);
}

.ebsuite-add-user__permissions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.ebsuite-admin-actions {
  text-align: right;
}

.ebsuite-admin-actions .button {
  padding: 10px 24px;
}

@keyframes ebsuiteFade {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1024px) {
  .ebsuite-shell {
    flex-direction: column;
  }

  .ebsuite-sidebar {
    width: 100%;
    border-right: 0;
    border-bottom: 1px solid var(--ebsuite-border);
    padding-bottom: 18px;
  }

  .ebsuite-content {
    padding: 18px;
  }

  .ebsuite-panel {
    padding: 4px 0;
  }

  .ebsuite-sidebar {
    gap: 18px;
  }

  .ebsuite-admin-table {
    font-size: 0.85rem;
  }
}

@media (max-width: 768px) {
  .ebsuite-login__panel {
    padding: 22px;
  }

  .ebsuite-admin-panel {
    padding: 18px;
  }

  .ebsuite-admin-table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }

  .ebsuite-admin-table__head,
  .ebsuite-admin-row {
    grid-template-columns: repeat(1, minmax(240px, 1fr));
  }

  .ebsuite-admin-cell--permissions {
    flex-direction: column;
  }
}
