:root {
  --bg-primary: #0b0f19;
  --bg-secondary: #111827;
  --bg-card: #1f2937;
  --bg-card-hover: #263346;
  --border-color: #374151;
  --text-main: #f9fafb;
  --text-muted: #9ca3af;
  --seedtag-primary: #ec4899;
  --seedtag-secondary: #8b5cf6;
  --tenant-a-accent: #6366f1;
  --tenant-b-accent: #06b6d4;
  --success: #10b981;
  --danger: #ef4444;
  --warning: #f59e0b;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow-x: hidden;
}

body.is-authenticated {
  justify-content: flex-start;
}

main {
  width: 100%;
  max-width: 1200px;
  margin: auto 0;
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

body.is-authenticated main {
  margin: 1.5rem auto 3rem auto;
}

/* Centered Seedtag Brand Logo */
.auth-brand-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 2rem;
  text-align: center;
}

.auth-brand-logo {
  max-width: 250px;
  max-height: 140px;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.5));
  transition: transform 0.25s ease, filter 0.25s ease;
}

.auth-brand-logo:hover {
  transform: scale(1.02);
  filter: drop-shadow(0 10px 30px rgba(236, 72, 153, 0.2));
}


/* Minimalist Auth Card */
.auth-card {
  max-width: 400px;
  width: 100%;
  margin: 0 auto;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.4);
}

.user-email-display {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0.85rem;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  margin-bottom: 1.25rem;
  font-size: 0.9rem;
  color: var(--text-main);
  word-break: break-all;
}

.btn-edit {
  background: none;
  border: none;
  color: #ec4899;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0.2rem 0.5rem;
  margin-left: 0.5rem;
  flex-shrink: 0;
}

.btn-edit:hover {
  text-decoration: underline;
}

.auth-error {
  background-color: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.35);
  color: #fca5a5;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  font-size: 0.875rem;
  margin-bottom: 1.25rem;
  line-height: 1.4;
}

/* Form Styles */
.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: #cbd5e1;
  margin-bottom: 0.4rem;
}

.form-input {
  width: 100%;
  padding: 0.75rem 1rem;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-main);
  font-size: 0.95rem;
  transition: border-color 0.15s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--seedtag-primary);
}

.btn-primary {
  width: 100%;
  padding: 0.85rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  background: var(--seedtag-primary);
  color: #fff;
  transition: all 0.2s ease;
  display: flex;
  justify-content: center;
  align-items: center;
}

.btn-primary:hover {
  opacity: 0.95;
  box-shadow: 0 4px 14px rgba(236, 72, 153, 0.35);
  transform: translateY(-1px);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

#unauthenticated-view {
  width: 100%;
}

/* Logged-In Section */
.session-container {
  display: none;
  width: 100%;
}

.session-container.active {
  display: block;
}

.session-header {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem 1.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--seedtag-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
}

.btn-logout {
  background-color: transparent;
  border: 1px solid #4b5563;
  color: #e5e7eb;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-logout:hover {
  background-color: #374151;
  border-color: #6b7280;
}

/* Dashboard Grid - Single Card Layout */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr;
  max-width: 880px;
  margin: 0 auto;
  gap: 2rem;
}

.dashboard-card {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.card-subtitle {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
}

.claims-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.claim-tag {
  background-color: #1e293b;
  border: 1px solid #334155;
  border-radius: 6px;
  padding: 0.4rem 0.75rem;
  font-size: 0.85rem;
  font-family: var(--font-mono);
}

.claim-tag.highlight {
  background-color: rgba(236, 72, 153, 0.15);
  border-color: var(--seedtag-primary);
  color: #f472b6;
  font-weight: 600;
}

.jwt-box {
  background-color: #030712;
  border: 1px solid #1f2937;
  border-radius: 8px;
  padding: 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: #94a3b8;
  max-height: 480px;
  overflow-y: auto;
  white-space: pre-wrap;
  word-break: break-all;
  flex: 1;
}


