/* Allveltro — product section: the bento of ITSM modules and the queue mock-up. */

/* ---------- Product: bento of modules ---------- */

.modules {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  background: var(--line);
  overflow: hidden;
}
.module {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: clamp(22px, 2.6vw, 30px);
  background: var(--surface);
  transition: background-color 0.25s var(--ease);
}
.module:hover {
  background: var(--raised);
}
.module .icon {
  width: 28px;
  height: 28px;
  color: var(--accent);
  margin-bottom: 6px;
}
.module p {
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--muted);
}
.module-wide {
  grid-column: span 2;
}
/* Featured module: the single queue, drawn as a tiny live queue */
.module-feature {
  grid-column: span 2;
  grid-row: span 2;
  align-content: space-between;
  gap: 28px;
  background: var(--ink);
  color: var(--bone);
  --muted: var(--stone);
  --accent: var(--terracotta);
  --line: rgb(224 222 212 / 0.11);
  --line-strong: rgb(224 222 212 / 0.22);
}
.module-feature:hover {
  background: var(--ink);
}
.module-feature > div {
  display: grid;
  gap: 12px;
}
.module-feature .h3 {
  font-size: clamp(1.5rem, 2.4vw, 1.875rem);
}
.module-feature p {
  font-size: 1rem;
  max-width: 460px;
}
.queue-wrap {
  display: grid;
  gap: 10px;
}
.queue-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  white-space: nowrap;
  gap: 12px;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.queue {
  display: grid;
  gap: 8px;
}
.queue li {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 13px 14px;
  border-radius: var(--radius-s);
  background: var(--surface-dark);
  border: 1px solid var(--line);
  font-size: 0.875rem;
}
.queue .q-key {
  white-space: nowrap;
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 0.7812rem;
  color: var(--stone);
}
.queue .q-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.js .module.reveal {
  transition: var(--reveal-transition), background-color 0.25s var(--ease);
}
@media (max-width: 1080px) {
  .modules {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .module-feature {
    grid-column: 1 / -1;
    grid-row: auto;
  }
}
@media (max-width: 640px) {
  .modules {
    grid-template-columns: minmax(0, 1fr);
  }
  .module-feature,
  .module-wide {
    grid-column: auto;
  }
  /* Key and status share a row while they fit; the title takes a full row below */
  .queue li {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
  }
  .queue .chip {
    order: 1;
    margin-left: auto;
  }
  .queue .q-title {
    order: 2;
    flex-basis: 100%;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
  }
}
