/* Scraper AI — Custom Styles */

/* App layout with sidebar */
#app {
  display: flex;
  min-height: calc(100vh - 52px);
}

.sidebar {
  width: 220px;
  min-width: 220px;
  padding: 1.5rem 0.75rem;
  background: hsl(var(--bulma-scheme-h), var(--bulma-scheme-s), var(--bulma-scheme-main-ter-l));
  border-right: 1px solid hsl(var(--bulma-scheme-h), var(--bulma-scheme-s), var(--bulma-border-l));
  position: sticky;
  top: 52px;
  height: calc(100vh - 52px);
  overflow-y: auto;
}

.sidebar .menu-label {
  padding-left: 0.75rem;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: hsl(var(--bulma-scheme-h), var(--bulma-scheme-s), var(--bulma-text-weak-l));
}

.sidebar .menu-list a {
  border-radius: 4px;
  font-size: 0.9rem;
  padding: 0.5em 0.75em;
  color: hsl(var(--bulma-scheme-h), var(--bulma-scheme-s), var(--bulma-text-strong-l));
  font-weight: 500;
}

.sidebar .menu-list a:hover {
  background: hsl(var(--bulma-scheme-h), var(--bulma-scheme-s), var(--bulma-background-l));
  color: hsl(var(--bulma-scheme-h), var(--bulma-scheme-s), var(--bulma-text-strong-l));
}

.sidebar .menu-list a.is-active {
  background: hsl(var(--bulma-link-h), var(--bulma-link-s), var(--bulma-link-l));
  color: #fff;
  font-weight: 600;
}

.main-content {
  flex: 1;
  min-width: 0;
}

/* Cards */
.card {
  box-shadow: 0 2px 3px rgba(10, 10, 10, 0.1), 0 0 0 1px rgba(10, 10, 10, 0.05);
}

.card-header-title .tag {
  margin-left: 0.5rem;
}

/* Stat tiles */
.tile.is-child.box {
  transition: transform 0.15s ease;
}

.tile.is-child.box:hover {
  transform: translateY(-2px);
}

.tile .heading {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #7a7a7a;
  margin-bottom: 0.25rem;
}

/* Table tweaks */
.table th {
  white-space: nowrap;
}

.table pre {
  background: #f5f5f5;
  padding: 0.5rem;
  border-radius: 4px;
  max-height: 200px;
  overflow: auto;
  font-size: 0.75rem;
}

/* Modal */
.modal-card {
  max-width: 800px;
  width: 90%;
}

.modal-card-body {
  max-height: 70vh;
  overflow-y: auto;
}

/* Badge spacing */
.tag + .tag {
  margin-left: 0.25rem;
}

/* Login hero */
.hero.is-fullheight-with-navbar {
  min-height: calc(100vh - 52px);
}

/* Responsive: collapse sidebar on small screens */
@media screen and (max-width: 768px) {
  #app {
    flex-direction: column;
  }
  .sidebar {
    width: 100%;
    min-width: 100%;
    height: auto;
    position: static;
    border-right: none;
    border-bottom: 1px solid #dbdbdb;
    padding: 0.75rem;
  }
  .sidebar .menu-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
  }
  .sidebar .menu-label {
    display: none;
  }
}
