/* Horns Sentinel Group: shared styles for the interactive demo pages.
   Loaded after site.css and before each demo page's own app styles, so the
   app screens can still override these where they need to. */

/* ---------- Hero and demo notice ---------- */

.demo-hero {
  padding-bottom: clamp(24px, 5vw, 44px);
}

.demo-hero .hero__lede + .hero__lede {
  margin-top: -16px;
}

.demo-notice {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
  margin: 0;
  padding: 10px 14px;
  border: 1px solid var(--accent-line);
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  color: var(--text);
  font-size: 0.95rem;
}

.demo-notice strong {
  color: var(--accent-text);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.demo-notice a {
  color: var(--accent-text);
  font-weight: 600;
}

/* ---------- Tabs ---------- */

.demo-tabs {
  display: flex;
  gap: 8px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--gutter) 20px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  scroll-padding-inline: var(--gutter);
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.demo-tabs::-webkit-scrollbar {
  display: none;
}

.demo-tab {
  flex: none;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--text-muted);
  font: 500 0.95rem/1 var(--font-sans);
  white-space: nowrap;
  cursor: pointer;
  scroll-snap-align: start;
  transition:
    background-color 0.2s var(--ease),
    border-color 0.2s var(--ease),
    color 0.2s var(--ease);
}

.demo-tab:hover {
  border-color: var(--text-faint);
  color: var(--text);
}

.demo-tab.active {
  border-color: var(--accent);
  background: var(--accent);
  color: #0a0c0f;
  font-weight: 600;
}

/* ---------- App stage ---------- */

.demo-content {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--gutter) clamp(56px, 9vw, 96px);
}

/* Headings inside app screens take the app's own sizes, not the site's large
   marketing headings. One class of specificity: beats site.css element rules,
   ties with (and loses to, by load order) the page's own app class rules. */
.demo-content :where(h1, h2, h3, h4) {
  font-size: revert;
  line-height: 1.3;
  letter-spacing: -0.01em;
  text-wrap: wrap;
}

.demo-content :where(p) {
  margin: 0;
}

/* ---------- Feature cards (section below the app, or inside a tab) ---------- */

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 16px;
}

.feature-card {
  position: relative;
  padding: 28px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  text-align: left;
  transition:
    border-color 0.25s var(--ease),
    background-color 0.25s var(--ease);
}

.feature-card:hover {
  border-color: var(--line-strong);
  background: var(--surface-2);
}

.feature-card h3 {
  margin: 0 0 10px;
  color: var(--text);
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}

.feature-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.98rem;
  line-height: 1.6;
}

.feature-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 18px;
  border: 1px solid var(--accent-line);
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--accent-text);
  font-size: 1.3rem;
}

.feature-icon svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
}

/* ---------- Pricing pills in the call to action ---------- */

.pricing-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 24px;
}

.pricing-pill {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--text-muted);
  font-size: 0.92rem;
}

.pricing-pill strong {
  margin-left: 4px;
  color: var(--text);
}

/* ---------- Coverage panel ----------
   Mirrors CoveragePanel in the real dashboard: it says what the last check
   actually reached, so an empty list is not mistaken for a clean result. */

.coverage-panel {
  margin-bottom: 16px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.02);
}

.coverage-panel--partial {
  border-color: rgba(234, 179, 8, 0.4);
  background: rgba(234, 179, 8, 0.06);
}

.coverage-panel__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.coverage-panel__title {
  margin: 0;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 600;
}

.coverage-panel__note {
  margin: 4px 0 0;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.coverage-panel__actions {
  display: flex;
  gap: 8px;
}

.coverage-button {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text);
  font: 500 0.82rem/1 var(--font-sans);
  cursor: pointer;
}

.coverage-button:hover {
  background: rgba(255, 255, 255, 0.05);
}

.coverage-button[disabled] {
  opacity: 0.6;
  cursor: progress;
}

.coverage-sources {
  margin: 12px 0 0;
  padding: 8px 0 0;
  border-top: 1px solid var(--line);
  list-style: none;
}

.coverage-source {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
}

.coverage-source:last-child {
  border-bottom: 0;
}

.coverage-source__id {
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

.coverage-source__detail {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.coverage-outcome {
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 500;
}

.coverage-outcome--ok {
  background: rgba(61, 220, 151, 0.12);
  color: #5ce4ab;
}

.coverage-outcome--error {
  background: rgba(255, 138, 138, 0.12);
  color: #ff9d9d;
}

.coverage-outcome--ambiguous {
  background: rgba(234, 179, 8, 0.14);
  color: #f0c453;
}

/* The link out of the demo notice is a real destination, so it gets a real
   tap target rather than the height of its own text. */

.demo-notice a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 4px;
  color: var(--accent-text);
  font-weight: 600;
}
