:root {
  --bg: #f5efe4;
  --panel: rgba(255, 255, 255, 0.8);
  --ink: #1f2933;
  --muted: #6b7280;
  --brand: #0c6b58;
  --brand-deep: #0a4f41;
  --accent: #ef8354;
  --line: rgba(17, 24, 39, 0.08);
}

body {
  min-height: 100vh;
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top right, rgba(239, 131, 84, 0.2), transparent 24%),
    radial-gradient(circle at bottom left, rgba(12, 107, 88, 0.18), transparent 28%),
    linear-gradient(135deg, #f8f1e6 0%, #f4f8f5 100%);
}

.app-nav {
  background: linear-gradient(90deg, var(--brand-deep), var(--brand));
  box-shadow: 0 10px 30px rgba(12, 107, 88, 0.18);
}

.app-nav .navbar-toggler {
  background: rgba(255, 255, 255, 0.12);
}

.app-nav .navbar-toggler-icon {
  filter: brightness(0) invert(1);
}

.navbar-brand,
.navbar-brand:hover {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: #fff;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
}

.brand-logo {
  width: 2.5rem;
  height: 2.5rem;
  object-fit: contain;
  border-radius: 0.85rem;
  background: rgba(255, 253, 250, 0.95);
  padding: 0.15rem;
}

.auth-brand {
  display: flex;
  justify-content: center;
}

.auth-brand-logo {
  width: min(260px, 100%);
  height: auto;
  object-fit: contain;
}

.app-menu .nav-link {
  color: rgba(255, 255, 255, 0.82);
  font-weight: 600;
  border-radius: 999px;
  padding: 0.55rem 0.9rem;
  transition: background-color 0.18s ease, color 0.18s ease;
}

.app-menu .nav-link:hover,
.app-menu .nav-link.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
}

.app-nav-actions {
  flex-wrap: wrap;
}

.auth-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem;
}

.auth-card,
.hero-panel,
.upload-panel,
.inline-card,
.stat-card {
  background: var(--panel);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 1.5rem;
}

.auth-card {
  max-width: 540px;
}

.hero-panel {
  overflow: hidden;
  position: relative;
}

.hero-panel::after {
  content: "";
  position: absolute;
  inset: auto -3rem -3rem auto;
  width: 14rem;
  height: 14rem;
  border-radius: 50%;
  background: rgba(239, 131, 84, 0.15);
}

.eyebrow {
  margin-bottom: 0.5rem;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brand);
}

.stat-card {
  padding: 1rem;
  border: 1px solid var(--line);
}

.stat-card-link {
  display: block;
  color: inherit;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.stat-card-link:hover,
.stat-card-link:focus-visible {
  color: inherit;
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.08);
  border-color: rgba(12, 107, 88, 0.2);
}

.stat-card span {
  display: block;
  color: var(--muted);
  font-size: 0.85rem;
}

.stat-card strong {
  font-size: 1.9rem;
}

.upload-panel,
.inline-card {
  border: 1px solid var(--line);
}

.card {
  border-radius: 1.25rem;
}

.card-body {
  padding: 1.5rem;
}

.form-control,
.form-select {
  border-radius: 0.95rem;
  border-color: rgba(17, 24, 39, 0.08);
  padding: 0.9rem 1rem;
}

.btn-primary {
  border: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--brand-deep));
  padding-inline: 1.3rem;
}

.btn-outline-primary {
  border-radius: 999px;
  color: var(--brand);
  border-color: rgba(12, 107, 88, 0.25);
}

.list-group-item {
  background: transparent;
  border-color: var(--line);
}

.table th {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.clickable-row {
  cursor: pointer;
}

.clickable-row td {
  transition: background-color 0.18s ease;
}

.clickable-row:hover td,
.clickable-row:focus-visible td {
  background: rgba(12, 107, 88, 0.06);
}

.row-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  position: relative;
  z-index: 1;
}

.btn-icon {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.btn-icon i {
  font-size: 0.95rem;
}

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

.detail-grid span {
  display: block;
  margin-bottom: 0.3rem;
  color: var(--muted);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.detail-grid strong {
  display: block;
  font-size: 1rem;
}

.json-preview {
  padding: 1rem;
  background: rgba(17, 24, 39, 0.04);
  border: 1px solid var(--line);
  border-radius: 1rem;
  white-space: pre-wrap;
  word-break: break-word;
}

@media (max-width: 991.98px) {
  .app-menu {
    padding: 0.75rem 0;
  }

  .app-nav-actions {
    padding-top: 0.75rem;
  }
}
