/* Pico CSS overrides and custom additions */

:root {
  --color-primary: #1a6fc4;
  --color-warning: #e67e22;
  --color-success: #27ae60;
  --color-danger: #e74c3c;
  --color-muted: #888;
}

/* Navigation */
nav {
  border-bottom: 1px solid var(--pico-muted-border-color);
  flex-wrap: wrap;
}

nav a {
  text-decoration: none;
}

/* Hamburger toggle — hidden on desktop */
.nav-toggle {
  display: none !important;
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  font-size: 1.5rem;
  padding: 0.25rem 0.5rem;
  color: inherit;
  cursor: pointer;
  margin: 0;
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block !important;
  }

  #nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    padding: 0.5rem 0;
    margin: 0;
  }

  #nav-links.nav-open {
    display: flex;
  }

  #nav-links li {
    padding: 0.25rem 0;
  }
}

/* Review count badge */
.badge {
  display: inline-block;
  background: var(--color-warning);
  color: #fff;
  border-radius: 12px;
  padding: 0.1rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 600;
  vertical-align: middle;
  margin-left: 0.4rem;
}

/* Status tags */
.tag {
  display: inline-block;
  border-radius: 4px;
  padding: 0.15rem 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
}

.tag-review {
  background: #fff3cd;
  color: #856404;
}

.tag-verified {
  background: #d1fae5;
  color: #065f46;
}

.tag-pending {
  background: #e2e8f0;
  color: #475569;
}

/* Pipeline progress banners */
.pipeline-banner {
  padding: 0.75rem 1rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.pipeline-banner.info {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
}

.pipeline-banner.warning {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
}

/* Monitor tag */
.monitor-tag {
  display: inline-block;
  background: #e8f0fe;
  color: var(--color-primary);
  border-radius: 3px;
  padding: 0.1rem 0.4rem;
  font-size: 0.8rem;
  margin: 0.1rem 0.2rem 0.1rem 0;
}

/* Detail layout (side-by-side on wider screens) */
.detail-layout {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: flex-start;
}

.detail-layout > * {
  flex: 1;
  min-width: 320px;
}

/* Buttons should only be as wide as their content */
button {
  width: auto !important;
}

/* Centered form action row */
.form-actions {
  text-align: center;
  margin-top: 1rem;
}

/* Muted text */
.text-muted {
  color: var(--color-muted);
  font-size: 0.9rem;
}

/* Browse grid (units / regions) */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  color: inherit;
  border: 1px solid var(--pico-muted-border-color);
  border-radius: 8px;
  overflow: hidden;
  transition: box-shadow 0.15s;
}

.card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.card img {
  width: 100%;
  height: 120px;
  object-fit: cover;
}

.card span {
  padding: 0.5rem;
  font-size: 0.9rem;
  text-align: center;
}
