/* THE CATALOGUE'S OWN RULES (Nxt.Atrium#1494): App management (.nxt-catalog*) and the App Catalogue (.nxt-catalogue*),
   whose only users are these views. They were in Atrium's shell.css until the views left it, and are moved here as they
   were. The host declares this sheet after its own: _content/Nxt.Atrium.Apps.Presentation.Blazor/css/apps.css.

   What is NOT here is the host's: the administration layout (.nxt-admin*), the panel, the buttons, the badge, the link
   and the outlined message (.nxt-panel, .nxt-btn*, .nxt-badge*, .nxt-link, .nxt-outlined-message*), and every --nxt-*
   token. TheViewsNameNothingOfAtriumTests holds the views to that list. */

/* #522: the package picker is a button-shaped label over a transparent file input, as the licence panel's is. */
.nxt-catalog__choose { position: relative; display: inline-block; }
.nxt-catalog__file { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.nxt-catalog__file:disabled { cursor: not-allowed; }

/* == App catalogue (#2580) =====================================================================
   The panel, the buttons and the inputs are the shared control chrome's own selectors
   (.nxt-panel, .nxt-btn, element rules), and the screen reuses the administration layout's
   .nxt-admin__split / __detail / __hint / __refusal rather than declaring a second set of them —
   one concept, one spelling. Only what is genuinely new to this screen is here, and every colour
   is an --nxt-* token (C3). */
.nxt-catalog {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    padding: 16px;
    gap: 12px;
    overflow: auto;
}

/* #700 (row 5u.1): the list is a pane of its own, 420 wide with a hairline on its right, and its rows scroll inside
   it. The four columns are one grid template, shared by the header and every row so they line up. */
.nxt-catalog__list {
    width: 420px;
    flex: 0 0 auto;
    align-self: stretch;
    min-height: 0;
    display: flex;
    flex-direction: column;
    border-right: 1px solid var(--nxt-border-primary);
}
.nxt-catalog__list-top { display: flex; gap: 8px; padding: 16px; align-items: center; }
.nxt-catalog__search { position: relative; flex: 1 1 auto; display: flex; }
.nxt-catalog__search-icon {
    position: absolute; left: 8px; top: 50%; transform: translateY(-50%);
    width: 14px; height: 14px; color: var(--nxt-text-secondary); pointer-events: none;
}
.nxt-catalog__search > .nxt-admin__input { margin: 0; padding-left: 28px; }
.nxt-catalog__columns {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 64px 64px 64px;
    gap: 8px;
    align-items: start;
}
.nxt-catalog__head {
    padding: 6px 16px;
    background: var(--nxt-surface-standard);
    font-family: var(--nxt-font-mono);
    font-size: 10px;
    text-transform: uppercase;
    color: var(--nxt-text-secondary);
}
.nxt-catalog__no-match { margin: 12px 16px; color: var(--nxt-text-secondary); }
.nxt-catalog__apps { overflow-y: auto; min-height: 0; flex: 1 1 auto; }
.nxt-catalog__app { border-bottom: 1px solid var(--nxt-border-primary); }
.nxt-catalog__app--muted { background: var(--nxt-surface-standard); color: var(--nxt-text-secondary); }
.nxt-catalog__app--selected {
    background: var(--nxt-accent-secondary-soft);
    box-shadow: inset 3px 0 0 var(--nxt-accent-primary);
}
.nxt-catalog__app-button {
    display: block;
    width: 100%;
    padding: 12px 16px;
    text-align: left;
    background: none;
    border: 0;
    color: inherit;
    cursor: pointer;
}
.nxt-catalog__app-name { display: flex; flex-wrap: wrap; align-items: center; gap: 0 8px; min-width: 0; }
.nxt-catalog__app-title { font-weight: 600; font-size: 14px; }
.nxt-catalog__app-product {
    flex: 1 0 100%;
    font-family: var(--nxt-font-mono);
    font-size: 11.5px;
    color: var(--nxt-text-secondary);
    overflow: hidden;
    text-overflow: ellipsis;
}
.nxt-catalog__version {
    font-family: var(--nxt-font-mono);
    font-size: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.nxt-catalog__version--none { color: var(--nxt-text-muted); }
.nxt-catalog__app-warning {
    display: flex;
    gap: 6px;
    margin-top: 6px;
    font-size: 12px;
    color: var(--nxt-semantic-warning-strong);
}
.nxt-catalog__app-warning-icon { width: 14px; height: 14px; flex: 0 0 auto; }

/* The shared detail grid caps its field column, which would cap the cards too: a third, flexible column lets a block
   that spans every column (the header, the cards, the versions) take the pane's width while a field keeps its cap. */
.nxt-admin__detail.nxt-catalog__detail {
    padding: 24px;
    grid-template-columns: auto minmax(0, var(--nxt-atrium-field-long)) minmax(0, 1fr);
}
.nxt-admin__detail.nxt-catalog__detail > button { justify-self: start; }
.nxt-catalog__header { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 20px; }
.nxt-catalog__header-icon {
    width: 44px; height: 44px; flex: 0 0 auto;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px; background: var(--nxt-surface-standard);
}
.nxt-catalog__header-icon svg { width: 24px; height: 24px; }
.nxt-catalog__header-text { flex: 1 1 auto; min-width: 0; }
.nxt-catalog__header-name { display: flex; align-items: center; gap: 10px; font-size: 22px; font-weight: 600; }
.nxt-catalog__header-product { font-family: var(--nxt-font-mono); font-size: 13px; color: var(--nxt-text-secondary); }
.nxt-catalog__cards {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 20px minmax(0, 1fr) 20px minmax(0, 1fr);
    align-items: stretch;
    margin-bottom: 16px;
}
.nxt-catalog__chevron { width: 16px; height: 16px; align-self: center; justify-self: center; color: var(--nxt-text-muted); }
.nxt-catalog__card { padding: 16px; display: flex; flex-direction: column; }
.nxt-admin-card.nxt-catalog__card--next { border: 1.5px solid var(--nxt-accent-secondary); }
.nxt-catalog__card-eyebrow { font-family: var(--nxt-font-mono); font-size: 10.5px; color: var(--nxt-text-secondary); }
.nxt-catalog__card-version { font-family: var(--nxt-font-mono); font-size: 22px; margin: 6px 0; }
.nxt-catalog__card-version--empty { color: var(--nxt-text-muted); }
.nxt-catalog__card-audience { font-size: 12.5px; }
.nxt-catalog__card-deadline { font-size: 12.5px; margin-top: 4px; color: var(--nxt-text-secondary); }
.nxt-catalog__card-body { flex: 1 1 auto; display: flex; flex-direction: column; padding-bottom: 12px; }
.nxt-catalog__card-foot { padding-top: 12px; border-top: 1px solid var(--nxt-border-primary); }
.nxt-catalog__card-foot > .nxt-admin__hint { font-size: 12px; margin: 4px 0 0 0; }
.nxt-catalog__card-links { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 10px; }
.nxt-catalog__card-links .nxt-link { color: var(--nxt-accent-primary); }
.nxt-catalog__card-links .nxt-catalog__withdraw { color: var(--nxt-semantic-error-strong); }
.nxt-catalog__card-links .nxt-link:disabled { color: var(--nxt-text-disabled); cursor: not-allowed; }
.nxt-catalog__back { color: var(--nxt-accent-primary); margin-bottom: 12px; justify-self: start; }

/* #702 (row 5u.3): one act at a time, in the card it applies to. The open card widens; the other two are narrow and
   dimmed beside it. The twins are AppStateCardView.xaml and AppReleaseActView.xaml. */
.nxt-catalog__card-eyebrow { display: flex; justify-content: space-between; gap: 8px; }
.nxt-catalog__card-eyebrow > span + span { font-size: 11px; }
.nxt-admin-card.nxt-catalog__card--open { border: 1.5px solid var(--nxt-accent-secondary); }
.nxt-admin-card.nxt-catalog__card--withdrawing { border: 1.5px solid var(--nxt-semantic-error); }
.nxt-catalog__card--dimmed { opacity: 0.55; }
.nxt-catalog__cards--open { grid-template-columns: minmax(0, 1fr) 20px minmax(0, 1.6fr); }
.nxt-catalog__cards--open > .nxt-catalog__cards-narrow { grid-column: 1; display: flex; flex-direction: column; gap: 12px; }
.nxt-catalog__cards--open > .nxt-catalog__card { grid-column: 3; }
.nxt-catalog__card-act { margin-top: 12px; }
.nxt-catalog__act { display: flex; flex-direction: column; gap: 4px; }
.nxt-catalog__act-sentence { margin: 0 0 8px 0; }
.nxt-catalog__act-reason { min-height: 64px; }
.nxt-catalog__act .nxt-admin__input { margin: 0; }
.nxt-catalog__act-date.nxt-admin__input { width: var(--nxt-atrium-field-short); }
.nxt-catalog__act-reason-foot { display: flex; justify-content: space-between; gap: 12px; }
.nxt-catalog__act-reason-foot > .nxt-admin__hint { margin: 4px 0 0 0; font-size: 12px; }
.nxt-catalog__act-remaining { font-family: var(--nxt-font-mono); font-size: 11px; color: var(--nxt-text-secondary); margin-top: 4px; }
.nxt-catalog__act-buttons {
    display: flex; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--nxt-border-primary);
}
.nxt-catalog__act-below { margin-bottom: 16px; }
.nxt-catalog__sign-earlier {
    margin-bottom: 16px; padding: 12px; border: 1px solid var(--nxt-accent-secondary); border-radius: 5px;
    background: var(--nxt-bg-panel);
}
.nxt-catalog__sign-earlier > p { margin: 0 0 8px 0; }

/* #704 (row 5u.5): Attach is one dashed panel, the only dashed edge on the screen, and it takes a dropped package; every
   version is a row of one table. The twins are in AppReleasesPanelView.xaml. */
.nxt-catalog__attach {
    position: relative;
    margin-bottom: 24px;
    padding: 16px 18px;
    border: 1.5px dashed var(--nxt-border-control);
    border-radius: 8px;
}
.nxt-catalog__attach--over { background: var(--nxt-accent-secondary-soft); }
.nxt-catalog__attach-head { display: flex; gap: 12px; align-items: flex-start; }
.nxt-catalog__attach-icon { width: 24px; height: 24px; flex: 0 0 auto; color: var(--nxt-accent-primary); }
.nxt-catalog__attach-text { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.nxt-catalog__attach-text > .nxt-admin__hint { margin: 0; font-size: 12px; }
.nxt-catalog__attach-title { font-size: 14.5px; font-weight: 600; }
.nxt-catalog__attach > .nxt-admin__hint { margin: 8px 0 0 36px; font-size: 12px; }
.nxt-catalog__attach-form {
    display: grid;
    grid-template-columns: auto minmax(0, var(--nxt-atrium-field-long));
    column-gap: 8px;
    align-items: start;
    margin-top: 12px;
    position: relative;
    z-index: 1;
    background: var(--nxt-bg-panel);
}
.nxt-catalog__attach-form > *                   { grid-column: 1 / -1; }
.nxt-catalog__attach-form > .nxt-admin__label   { grid-column: 1; align-self: center; }
.nxt-catalog__attach-form > .nxt-admin__input   { grid-column: 2; }
.nxt-catalog__attach-form > .nxt-admin__input + .nxt-admin__hint { grid-column: 2; }
.nxt-catalog__attach-form > button              { justify-self: start; }
.nxt-catalog__versions-title { display: flex; justify-content: space-between; align-items: baseline; }
.nxt-catalog__versions-title > .nxt-catalog__section-title { font-size: 15px; }
.nxt-catalog__versions-counts { font-family: var(--nxt-font-mono); font-size: 11.5px; color: var(--nxt-text-secondary); }
.nxt-catalog__versions {
    border: 1px solid var(--nxt-border-primary);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 8px;
}
.nxt-catalog__versions-row {
    display: grid;
    grid-template-columns: 90px 110px 150px minmax(0, 1fr);
    gap: 4px 0;
    width: 100%;
    padding: 8px 12px;
    text-align: left;
    background: none;
    border: 0;
    border-top: 1px solid var(--nxt-border-primary);
    color: inherit;
    font: inherit;
    cursor: pointer;
}
.nxt-catalog__versions-head { border-top: 0; background: var(--nxt-surface-standard); font-size: 12px; color: var(--nxt-text-secondary); cursor: default; }
.nxt-catalog__versions-row--selected { background: var(--nxt-accent-secondary-soft); }
.nxt-catalog__versions-row--withdrawn { background: var(--nxt-surface-standard); color: var(--nxt-text-secondary); }
.nxt-catalog__versions-version { font-family: var(--nxt-font-mono); font-size: 13px; }
.nxt-catalog__versions-published { font-family: var(--nxt-font-mono); font-size: 12px; }
.nxt-catalog__versions-by { display: flex; flex-direction: column; }
.nxt-catalog__versions-detail { font-family: var(--nxt-font-mono); font-size: 12px; color: var(--nxt-text-secondary); }
.nxt-catalog__versions-byline { font-size: 12px; color: var(--nxt-text-secondary); }
.nxt-catalog__versions-withdrawn { grid-column: 2 / -1; font-size: 12px; }
.nxt-catalog__versions-second { grid-column: 1 / -1; display: flex; flex-direction: column; font-size: 12px; }
.nxt-catalog__versions-package { font-family: var(--nxt-font-mono); font-size: 11.5px; color: var(--nxt-text-secondary); }
.nxt-catalog__icons { display: flex; flex-wrap: wrap; gap: 6px; }
.nxt-admin__detail > .nxt-catalog__icons-label { align-self: start; padding-top: 12px; }
.nxt-catalog__icon {
    width: 44px; height: 44px;
    display: flex; align-items: center; justify-content: center;
    border: 1px solid var(--nxt-border-primary); border-radius: 6px;
    background: var(--nxt-bg-panel); color: inherit; cursor: pointer;
}
.nxt-catalog__icon svg { width: 20px; height: 20px; }
.nxt-catalog__icon--selected { border: 1.5px solid var(--nxt-accent-secondary); background: var(--nxt-accent-secondary-soft); }
.nxt-catalog__preview { margin: 16px 0; padding: 16px; border-radius: 8px; background: var(--nxt-surface-standard); }
.nxt-catalog__preview-eyebrow { display: block; margin-bottom: 10px; font-family: var(--nxt-font-mono); font-size: 10.5px; color: var(--nxt-text-secondary); }
.nxt-catalog__preview-tiles { display: flex; gap: 12px; }
.nxt-catalog__preview-tile {
    width: 120px; height: 96px; padding: 8px; box-sizing: border-box;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
    border: 1px solid var(--nxt-border-primary); border-radius: 8px; background: var(--nxt-bg-panel);
    font-size: 12.5px; text-align: center; overflow: hidden;
}
.nxt-catalog__preview-tile svg { width: 28px; height: 28px; flex: 0 0 auto; }
.nxt-catalog__preview-tile > span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nxt-catalog__preview-tile > .nxt-catalog__preview-state {
    margin-top: -6px; font-family: var(--nxt-font-mono); font-size: 10px; text-transform: uppercase;
    color: var(--nxt-text-secondary);
}
.nxt-catalog__definition-actions { padding-top: 12px; border-top: 1px solid var(--nxt-border-primary); }
.nxt-catalog__rows,
.nxt-catalog__release-rows,
.nxt-catalog__group-rows { list-style: none; margin: 0; padding: 0; }
.nxt-catalog__row,
.nxt-catalog__release-row { border-bottom: 1px solid var(--nxt-border-primary); }
.nxt-catalog__row--selected,
.nxt-catalog__release-row--selected { background: var(--nxt-btn-hover); }
.nxt-catalog__row-button {
    display: grid;
    grid-template-columns: 1fr auto auto auto;
    gap: 4px 12px;
    width: 100%;
    padding: 6px 8px;
    text-align: left;
    background: none;
    border: 0;
    color: inherit;
    cursor: pointer;
}
.nxt-catalog__row-title       { font-weight: 600; }
.nxt-catalog__row-version     { }
.nxt-catalog__row-state       { color: var(--nxt-text-secondary); }
.nxt-catalog__audience        { margin-bottom: 12px; }
.nxt-catalog__row-product,
.nxt-catalog__row-notes   { grid-column: 1 / -1; font-size: 11px; color: var(--nxt-text-secondary); }
.nxt-catalog__row-offered { color: var(--nxt-semantic-active); }
.nxt-catalog__row-withdrawn { grid-column: 1 / -1; font-size: 11px; color: var(--nxt-semantic-warning); }
.nxt-catalog__row-warning {
    grid-column: 1 / -1;
    font-size: 11px;
    color: var(--nxt-semantic-warning);
}
.nxt-catalog__empty {
    padding: 16px;
    color: var(--nxt-text-secondary);
    border: 1px dashed var(--nxt-border-primary);
}
.nxt-catalog__section-title { margin: 16px 0 6px 0; font-size: 14px; }
.nxt-catalog__group-row     { padding: 2px 0; }
.nxt-catalog__confirm {
    margin: 8px 0 12px 0;
    padding: 12px;
    background: var(--nxt-banner-warn-bg);
    border: 1px solid var(--nxt-semantic-warning);
    color: var(--nxt-banner-warn-text);
}

/* THE APP CATALOGUE (#1006 FR-6 to FR-8, row 5v.2): the list on the left in two sections, the chosen app's entry beside
   it. The twin is AppCatalogueView.xaml. A row and its selection mark are App management's (nxt-catalog__app). */
.nxt-catalogue { display: flex; flex-direction: column; flex: 1 1 auto; min-height: 0; padding: 16px; }
.nxt-catalogue__split { flex: 1 1 auto; align-items: stretch; }
.nxt-catalogue__list {
    width: 420px; flex: 0 0 auto; min-height: 0;
    display: flex; flex-direction: column;
    border: 1px solid var(--nxt-border-primary);
}
.nxt-catalogue__find { display: flex; flex-direction: column; gap: 6px; padding: 16px; }
.nxt-catalogue__find-label { font-size: 12px; color: var(--nxt-text-secondary); }
.nxt-catalogue__rows { overflow-y: auto; min-height: 0; flex: 1 1 auto; }
.nxt-catalogue__note { margin: 0 16px 16px; color: var(--nxt-text-secondary); }
.nxt-catalogue__section {
    padding: 6px 16px;
    background: var(--nxt-surface-standard);
    border-top: 1px solid var(--nxt-border-primary);
    border-bottom: 1px solid var(--nxt-border-primary);
    font-family: var(--nxt-font-mono);
    font-size: 10px;
    color: var(--nxt-text-secondary);
}
.nxt-catalogue__row { display: flex; gap: 12px; align-items: center; }
.nxt-catalogue__row-icon {
    width: 36px; height: 36px; flex: 0 0 auto;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px; background: var(--nxt-surface-standard);
}
.nxt-catalogue__row-icon svg { width: 20px; height: 20px; }
.nxt-catalogue__row-text { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.nxt-catalogue__row-name { font-weight: 600; font-size: 14px; }
.nxt-catalogue__row-summary { font-size: 12px; color: var(--nxt-text-secondary); }
.nxt-catalogue__entry {
    flex: 1 1 auto; min-width: 0; overflow-y: auto;
    padding: 28px 36px;
    border: 1px solid var(--nxt-border-primary);
}
.nxt-catalogue__entry-head { display: flex; gap: 20px; align-items: flex-start; margin-bottom: 20px; }
.nxt-catalogue__entry-icon {
    width: 72px; height: 72px; flex: 0 0 auto;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px; border: 1px solid var(--nxt-border-primary);
}
.nxt-catalogue__entry-icon svg { width: 40px; height: 40px; }
.nxt-catalogue__entry-text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.nxt-catalogue__entry-name { margin: 0; font-size: 24px; font-weight: 600; }
.nxt-catalogue__entry-line { font-size: 13px; color: var(--nxt-text-secondary); }
.nxt-catalogue__action {
    margin-bottom: 20px; padding: 12px;
    border: 1px solid var(--nxt-border-primary); border-radius: 3px;
    font-size: 13px;
}

/* #1006 S2: a Released group's placement, beside the group in App management. */
.nxt-catalog__placement { display: inline-flex; gap: 12px; margin-left: 16px; }

/* #1006 S2: Pin and Unpin in the entry's action slot, and the unpin confirmation in its place. */
.nxt-catalogue__action-slot { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin-bottom: 20px; }
.nxt-catalogue__confirm p { margin: 6px 0; }
.nxt-catalogue__buttons { display: flex; gap: 8px; margin-top: 8px; }
.nxt-catalogue__rule { height: 1px; margin-bottom: 20px; background: var(--nxt-border-primary); }
.nxt-catalogue__screenshots { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 20px; align-items: center; }
.nxt-catalogue__screenshot { max-height: 180px; max-width: 320px; border: 1px solid var(--nxt-border-primary); border-radius: 3px; }
.nxt-catalogue__body { display: flex; gap: 32px; align-items: flex-start; }
.nxt-catalogue__about { flex: 1 1 auto; max-width: 520px; }
.nxt-catalogue__heading { margin: 0 0 8px; font-size: 15px; font-weight: 600; }
.nxt-catalogue__description { margin: 0 0 20px; font-size: 14px; line-height: 1.6; white-space: pre-line; }
.nxt-catalogue__facts {
    width: 280px; flex: 0 0 auto; margin: 0;
    display: grid; grid-template-columns: 110px 1fr; row-gap: 8px;
    font-size: 13px;
}
.nxt-catalogue__facts dt { color: var(--nxt-text-secondary); }
.nxt-catalogue__facts dd { margin: 0; }
.nxt-catalogue__mono { font-family: var(--nxt-font-mono); }

/* #705 (row 5u.7): the icon grid, its hint and the preview sit in the form's field column; the host's stylesheet places
   the form's other hints there itself. */
.nxt-admin__detail > .nxt-catalog__icons,
.nxt-admin__detail > .nxt-catalog__icons + .nxt-admin__hint,
.nxt-admin__detail > .nxt-catalog__preview { grid-column: 2; }

/* Nxt.Atrium#1520: when Nxt's releases were last received, the line of an app Nxt offers, and the badge on its versions. */
.nxt-catalog__nxt-received { margin: 0 0 12px 0; font-size: 12px; }
.nxt-catalog__offered-by-nxt { margin: 0 0 16px 0; max-width: 520px; font-size: 12px; }
.nxt-catalog__versions-nxt { align-self: flex-start; margin-bottom: 4px; }
