/* ============================================================
   Shopper Social — the member app (HQU-1593)
   --------------------------------------------------------------
   Wears the AuditTrace records PWA's look (Hque.Aspire.Records
   + records.css): paper ground, flat white cards with hairline
   borders, INK for the primary action, Public Sans / Archivo,
   and a 46px floor under anything a thumb has to hit.

   Every colour resolves through tokens.css. A literal here is a
   value that can never be re-pointed — don't add one.
   ============================================================ */

html, body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--panel-font-body);
    color: var(--panel-text);
    background: var(--panel-bg);
}

h1, h2, h3 {
    font-family: var(--panel-font-display);
}

/* ---- login shell ------------------------------------------------------- */

/* Records' anonymous shell: a COLUMN pinned near the top rather than a card centred in the
   viewport, which moves whenever a phone keyboard resizes the viewport under the PIN field. */
.panel-login-shell {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    padding: 24px 16px;
    box-sizing: border-box;
}

/* ---- the tile ---------------------------------------------------------- */

/* Records' .record-card: the centred single-message TILE — sign-in, choose a PIN, PIN help,
   the end of a survey. A message that owns an otherwise empty screen, and nothing else; a
   screen of content sits on the paper in .panel-section cards instead. */
.panel-card {
    width: 100%;
    max-width: 420px;
    box-sizing: border-box;
    margin-top: 8vh;
    padding: 32px 24px;
    background: var(--panel-surface);
    border-radius: var(--panel-radius-tile);
    box-shadow: 0 2px 16px var(--panel-shadow);
    text-align: center;
}

/* Inside the member shell the top bar already takes the first stretch of the screen. */
.panel-card--message {
    margin: 4vh auto 0;
}

/* Whose app this is (PanelBrandHead): an eyebrow, never the headline. */
.panel-org-head {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-bottom: 4px;
    color: var(--panel-muted);
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.panel-org-head .mud-icon-root {
    font-size: 16px;
}

/* !important because MudIcon's own size class sets the font-size the svg scales from. */
.panel-hero-icon.mud-icon-root {
    width: 56px;
    height: 56px;
    margin-top: 12px;
    font-size: 56px !important;
    color: var(--panel-muted);
}

.panel-card__title {
    margin: 8px 0 12px;
    font-family: var(--panel-font-display);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.012em;
    color: var(--panel-text);
}

.panel-card__subtitle {
    margin: 0 0 24px;
    color: var(--panel-muted);
    font-size: 1rem;
    line-height: 1.5;
}

/* The verdict-banner shape: tinted, bordered, and read left to right like the form under it. */
.panel-card__error {
    margin-bottom: 16px;
    padding: 10px 12px;
    border: 1px solid var(--panel-v-danger-bd);
    border-radius: 8px;
    background: var(--panel-v-danger-bg);
    color: var(--panel-v-danger-fg);
    font-size: 0.94rem;
    line-height: 1.4;
    text-align: left;
}

/* A form is read top to bottom, so it is left-aligned inside the centred tile. */
.panel-card form {
    text-align: left;
}

.panel-card__label {
    display: block;
    margin-bottom: 6px;
    color: var(--panel-body);
    font-size: 14px;
    font-weight: 600;
}

/* Plain inputs, not MudTextField — the sign-in posts as a static SSR form — drawn as Records'
   outlined Mud field: an edge-grey border that turns ink on focus. */
.panel-card__input {
    display: block;
    width: 100%;
    min-height: var(--panel-tap);
    box-sizing: border-box;
    margin-bottom: 16px;
    padding: 0 14px;
    border: 1px solid var(--panel-edge);
    border-radius: var(--panel-radius-control);
    background: var(--panel-surface);
    color: var(--panel-text);
    font-family: var(--panel-font-body);
    font-size: 16px; /* 16px stops iOS Safari zooming the page on focus */
}

.panel-card__input:hover {
    border-color: var(--panel-muted);
}

/* An inset second pixel rather than a 2px border, so focusing the field doesn't shift it. */
.panel-card__input:focus {
    outline: none;
    border-color: var(--panel-accent);
    box-shadow: inset 0 0 0 1px var(--panel-accent);
}

/* A select drawn as one of these fields (HQU-1937). The browser's own arrow sat hard against
   the right border, inside padding meant for text, so it is replaced with a chevron drawn
   in the field's padding: two token-coloured gradient triangles, so no colour is a literal. */
select.panel-card__input {
    appearance: none;
    -webkit-appearance: none;
    padding-right: 44px;
    background-image:
        linear-gradient(45deg, transparent 50%, var(--panel-body) 50%),
        linear-gradient(135deg, var(--panel-body) 50%, transparent 50%);
    background-position:
        right 23px center,
        right 18px center;
    background-size: 5px 5px;
    background-repeat: no-repeat;
    text-overflow: ellipsis;
    cursor: pointer;
}

/* Sits under the PIN field on the PIN-creation forms to carry the rules. */
.panel-card__hint {
    margin: -10px 0 16px;
    color: var(--panel-faint);
    font-size: 13px;
    line-height: 1.4;
}

/* A tick-list question (HQU-1808): one legend, a full-height tap row per box. */
.panel-ticks {
    margin: 0 0 16px;
    padding: 0;
    border: 0;
}

.panel-tick {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: var(--panel-tap);
    padding: 0 14px;
    margin-bottom: 8px;
    border: 1px solid var(--panel-edge);
    border-radius: var(--panel-radius-control);
    color: var(--panel-body);
    font-size: 15px;
    cursor: pointer;
}

.panel-tick:hover {
    border-color: var(--panel-muted);
}

.panel-tick input {
    width: 20px;
    height: 20px;
    margin: 0;
    accent-color: var(--panel-accent);
}

.panel-ticks__hint {
    color: var(--panel-faint);
    font-size: 13px;
    line-height: 1.4;
}

/* The account page's quick questions (HQU-1810): a question, then one tap per answer. */
.panel-quick {
    padding: 12px 0;
    border-top: 1px solid var(--panel-border-soft);
}

.panel-quick:first-of-type {
    border-top: 0;
}

.panel-quick.is-answered {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
    color: var(--panel-body);
    font-size: 14px;
}

.panel-quick__options {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.panel-quick__option {
    min-height: var(--panel-tap);
    padding: 0 14px;
    border: 1px solid var(--panel-edge);
    border-radius: var(--panel-radius-control);
    background: var(--panel-surface);
    color: var(--panel-text);
    font: inherit;
    font-size: 14px;
    cursor: pointer;
}

.panel-quick__option:hover {
    border-color: var(--panel-muted);
}

.panel-quick__option.is-current {
    border-color: var(--panel-accent);
    box-shadow: inset 0 0 0 1px var(--panel-accent);
    font-weight: 600;
}

.panel-quick__option:disabled {
    cursor: progress;
    opacity: 0.6;
}

/* Records' .record-btn--primary --block: the card's one action, ink, full width. */
.panel-card__button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: var(--panel-tap);
    box-sizing: border-box;
    margin-top: 8px;
    padding: 0 18px;
    border: 1px solid var(--panel-accent);
    border-radius: var(--panel-radius-control);
    background: var(--panel-accent);
    color: var(--panel-on-accent);
    font-family: var(--panel-font-body);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
}

.panel-card__button:hover {
    background: var(--panel-accent-hover);
}

.panel-card__button:focus-visible,
.panel-card__link:focus-visible {
    outline: 2px solid var(--panel-accent);
    outline-offset: 2px;
}

/* "Forgot your PIN?" beneath the form — Records' secondary .record-btn --block: white,
   bordered, full tap height. Records made its "Not you?" link a button for the same reason
   (HQU-747): as a small text link it read as a footnote rather than the way out. */
.panel-card__link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: var(--panel-tap);
    box-sizing: border-box;
    margin-top: 16px;
    padding: 0 18px;
    border: 1px solid var(--panel-border);
    border-radius: var(--panel-radius-control);
    background: var(--panel-surface);
    color: var(--panel-text);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
}

.panel-card__link:hover {
    background: var(--panel-hover);
}

/* A tile's stacked full-width controls (the end-of-survey screen). */
.panel-card__actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* The dev-login hints on the front door. */
.panel-card code {
    padding: 1px 4px;
    border-radius: 4px;
    background: var(--panel-sunken);
    color: var(--panel-body);
    font-size: 0.88em;
}

/* ---- member shell ------------------------------------------------------ */

/* Records' .record-topbar: white, one hairline under it, sticky rather than fixed so nothing
   has to pad the page down to clear it. */
.panel-topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    padding: max(6px, env(safe-area-inset-top, 0px)) 16px 6px;
    background: var(--panel-surface);
    border-bottom: 1px solid var(--panel-border);
}

/* The bar runs edge to edge but its contents keep to the page column, as the bottom bar's do
   (HQU-1747), so on a wide screen the brand and Sign out sit over the page, not in the corners. */
.panel-topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    max-width: var(--panel-page-max);
    min-height: 44px;
    margin: 0 auto;
}

.panel-topbar-brand {
    min-width: 0;
    overflow: hidden;
    color: var(--panel-text);
    font-family: var(--panel-font-display);
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.012em;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

a.panel-topbar-brand:focus-visible {
    outline: 2px solid var(--panel-accent);
    outline-offset: 2px;
    border-radius: 2px;
}

.panel-topbar-signout {
    display: inline-flex;
    flex: none;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    /* Pulled out by its own padding so the label, not the hover tile, lines up with the column. */
    margin-right: -10px;
    padding: 0 10px;
    border-radius: var(--panel-radius-control);
    color: var(--panel-text);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}

.panel-topbar-signout:hover {
    background: var(--panel-hover);
}

.panel-topbar-signout:focus-visible,
.panel-navlink:focus-visible {
    outline: 2px solid var(--panel-accent);
    outline-offset: -2px;
}

/* The paper column. The bottom padding keeps the last card clear of the bottom bar and the
   iOS home indicator under it. */
.panel-shell {
    padding: 24px 16px calc(var(--panel-nav-height) + 32px + env(safe-area-inset-bottom, 0px));
}

.panel-page {
    max-width: var(--panel-page-max);
    margin: 0 auto;
}

/* ---- bottom nav -------------------------------------------------------- */

/* Records' phone bar: icon over a short label, the current place marked by an ink top edge.
   A filled tile was too much colour across a bar. Sits above the iOS home indicator rather
   than under it. */
.panel-nav {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1200;
    padding-bottom: env(safe-area-inset-bottom, 0px);
    background: var(--panel-surface);
    border-top: 1px solid var(--panel-border);
}

.panel-nav-inner {
    display: flex;
    max-width: var(--panel-page-max);
    margin: 0 auto;
}

.panel-navlink {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    min-width: 0;
    min-height: var(--panel-nav-height);
    box-sizing: border-box;
    padding: 6px 2px 8px;
    color: var(--panel-muted);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
}

.panel-navlink:hover {
    color: var(--panel-text);
}

.panel-navlink .panel-navlink-icon {
    font-size: 1.75rem;
}

/* NavLink's own class, and aria-current for whichever version of it sets that instead. */
.panel-navlink.active,
.panel-navlink[aria-current="page"] {
    color: var(--panel-text);
    font-weight: 600;
    box-shadow: inset 0 3px 0 var(--panel-accent);
}

/* The unread-messages count on the Messages tab (HQU-1693): a small accent pill on the
   icon's corner. */
.panel-navlink-iconwrap {
    position: relative;
    display: inline-flex;
}

.panel-navlink-badge {
    position: absolute;
    top: -4px;
    right: -10px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    box-sizing: border-box;
    border-radius: 9px;
    background: var(--panel-accent);
    color: var(--panel-on-accent);
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
}

/* ---- the screen on paper ----------------------------------------------- */

/* Back up to the page above (HQU-1935), over the title. Pulled out by its own padding, as Sign
   out is, so the arrow lines up with the column while the hover tile has room around it. */
.panel-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    margin: -12px 0 4px -10px;
    padding: 0 10px;
    border-radius: var(--panel-radius-control);
    color: var(--panel-text);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}

.panel-back:hover {
    background: var(--panel-hover);
}

.panel-back:focus-visible {
    outline: 2px solid var(--panel-accent);
    outline-offset: -2px;
}

/* Records' .record-head-title: left-aligned display type, 25px on a phone, 30px beyond. */
.panel-head-title {
    margin: 0 0 16px;
    color: var(--panel-text);
    font-family: var(--panel-font-display);
    font-size: 25px;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.012em;
    overflow-wrap: anywhere;
}

@media (min-width: 601px) {
    .panel-head-title {
        font-size: 30px;
    }
}

/* A section's card. Flat — a border, no shadow — because structure on this surface is
   carried by hairlines, and a stack of drop shadows on paper reads as clutter. */
.panel-section {
    margin-bottom: 16px;
    padding: 16px;
    background: var(--panel-surface);
    border: 1px solid var(--panel-border);
    border-radius: var(--panel-radius-card);
}

/* The heading OVER a card, as Records heads its sections. */
.panel-section-head {
    margin: 28px 0 10px;
    color: var(--panel-muted);
    font-family: var(--panel-font-display);
    font-size: 15px;
    font-weight: 600;
}

/* A heading INSIDE a card. */
.panel-section-title {
    margin: 0 0 6px;
    color: var(--panel-text);
    font-family: var(--panel-font-body);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.3;
}

.panel-section-text {
    margin: 0;
    color: var(--panel-body);
    font-size: 15px;
    line-height: 1.5;
}

.panel-muted {
    color: var(--panel-muted);
}

.panel-subhead {
    margin: 16px 0 8px;
    color: var(--panel-muted);
    font-size: 14px;
    font-weight: 600;
}

.panel-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

/* Loading / empty — every non-list outcome gets the box the list's card would have given it. */
.panel-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 22px 16px;
    background: var(--panel-surface);
    border: 1px solid var(--panel-border);
    border-radius: var(--panel-radius-card);
    color: var(--panel-muted);
    font-size: 15px;
    line-height: 1.5;
    text-align: center;
}

.panel-state-text {
    margin: 0;
    color: var(--panel-muted);
    font-size: 15px;
}

.panel-foot {
    margin: 12px 2px 0;
    font-size: 14px;
}

/* Records' .record-link: the one place blue appears, and only on a plain text link. */
.panel-link {
    color: var(--panel-link);
    font-weight: 500;
    text-decoration: none;
}

.panel-link:hover {
    text-decoration: underline;
}

.panel-support {
    margin-top: 8px;
}

.panel-support-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    font-size: 14px;
}

/* ---- list rows: the shopping list, reviews, the rewards balance -------- */

/* ONE card, rows divided by a soft rule — Records' worklist, not a stack of cards. */
.panel-list {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--panel-surface);
    border: 1px solid var(--panel-border);
    border-radius: var(--panel-radius-card);
}

.panel-list > * + * {
    border-top: 1px solid var(--panel-border-soft);
}

.panel-item {
    padding: 14px;
}

/* Finished and dead items stay on the list for the "did I do that one?" check,
   but recede so the aisle read is the open ones. On the children, so the rule
   between rows keeps its weight. */
.panel-item--closed > * {
    opacity: .65;
}

.panel-item-body,
.panel-product {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.panel-product {
    align-items: center;
}

.panel-item-main {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.panel-item-eyebrow {
    color: var(--panel-faint);
    font-size: 13px;
}

.panel-item-title {
    color: var(--panel-text);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.panel-item-meta {
    color: var(--panel-muted);
    font-size: 14px;
    line-height: 1.4;
}

.panel-item-facts {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
    margin-top: 8px;
}

.panel-item-amount {
    color: var(--panel-text);
    font-size: 15px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.panel-item-hint {
    margin-top: 6px;
    color: var(--panel-muted);
    font-size: 13px;
    line-height: 1.4;
}

.panel-item-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

/* A product's pack shot, in a raised well so a white-background image still has an edge. */
.panel-thumb {
    display: flex;
    flex: none;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    box-sizing: border-box;
    object-fit: contain;
    border: 1px solid var(--panel-border-soft);
    border-radius: 8px;
    background: var(--panel-raised);
    color: var(--panel-faint);
}

/* The shopping list's is bigger (HQU-1739): it's what tells two packs on a shelf apart, and
   tapping it opens the full image. */
.panel-thumb--list {
    width: 104px;
    height: 104px;
}

/* The thumbnail as the button that opens its photo popup (HQU-1934): no chrome of its own,
   the image's well is the whole target. */
.panel-thumb-button {
    flex: none;
    display: block;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: none;
    line-height: 0;
    cursor: zoom-in;
}

.panel-thumb-button:focus-visible {
    outline: 2px solid var(--panel-accent);
    outline-offset: 2px;
}

/* The full-size product photo, over the list in the top layer (HQU-1934). A flat white tile,
   as the sign-in tile is, sized to the phone and centred by the popover's own inset/margin. */
.panel-photo {
    width: min(92vw, 560px);
    max-height: 88vh;
    box-sizing: border-box;
    padding: 48px 16px 16px;
    border: 0;
    border-radius: var(--panel-radius-tile);
    background: var(--panel-surface);
    box-shadow: 0 2px 16px var(--panel-shadow);
    color: var(--panel-text);
    overflow: auto;
}

.panel-photo::backdrop {
    background: var(--panel-scrim);
}

.panel-photo-img {
    display: block;
    width: 100%;
    max-height: 64vh;
    object-fit: contain;
    border-radius: 8px;
    background: var(--panel-raised);
}

.panel-photo-caption {
    margin-top: 12px;
}

.panel-photo-close {
    position: absolute;
    top: 4px;
    right: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var(--panel-tap);
    height: var(--panel-tap);
    padding: 0;
    border: 0;
    border-radius: var(--panel-radius-control);
    background: none;
    color: var(--panel-text);
    cursor: pointer;
}

.panel-photo-close:hover {
    background: var(--panel-hover);
}

.panel-photo-close:focus-visible {
    outline: 2px solid var(--panel-accent);
    outline-offset: -2px;
}

/* Records' lifecycle tag: a soft pill with a dot, the dot carrying the tone at a glance. */
.panel-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;
    white-space: nowrap;
}

.panel-tag::before {
    content: "";
    flex: none;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
}

.panel-tag.tone-neutral  { background: var(--panel-tone-neutral-bg);  color: var(--panel-tone-neutral-fg); }
.panel-tag.tone-active   { background: var(--panel-tone-active-bg);   color: var(--panel-tone-active-fg); }
.panel-tag.tone-positive { background: var(--panel-tone-positive-bg); color: var(--panel-tone-positive-fg); }
.panel-tag.tone-warning  { background: var(--panel-tone-warning-bg);  color: var(--panel-tone-warning-fg); }
.panel-tag.tone-muted    { background: var(--panel-tone-muted-bg);    color: var(--panel-tone-muted-fg); }

.panel-account-status {
    margin-top: 12px;
}

/* A label-and-value row. */
.panel-balance {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
}

.panel-balance-label {
    color: var(--panel-text);
    font-size: 16px;
    font-weight: 600;
}

.panel-balance-amount {
    color: var(--panel-text);
    font-family: var(--panel-font-display);
    font-size: 20px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.panel-balance-amount.is-paid {
    color: var(--panel-v-success-fg);
}

/* ---- scanner ----------------------------------------------------------- */

.scan-video {
    display: block;
    width: 100%;
    max-height: 60vh;
    border-radius: 8px;
    background: var(--panel-video-bg);
    object-fit: cover;
}

.panel-scan-target {
    padding: 12px;
}

.panel-camera-wait {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px;
}

.panel-camera-wait .panel-camera-wait-icon {
    color: var(--panel-muted);
}

.panel-camera-hint {
    margin-top: 10px;
    font-size: 14px;
    text-align: center;
}

/* The barcode field and its Check button share one row and one height — the dense outlined
   field grows to the tap floor rather than the button shrinking under it. */
.panel-manual-entry {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 12px;
}

.panel-manual-entry .mud-input-control {
    flex: 1 1 auto;
    margin: 0;
}

.panel-manual-entry .mud-input.mud-input-outlined {
    min-height: var(--panel-tap);
}

/* ---- MudBlazor controls, drawn as Records draws its own -------------------
   PanelTheme gives Mud the palette and the faces; these give it the SHAPE: Records' .record-btn
   — flat, the tap floor, 16px labels — and a white, hairline-bordered secondary rather than
   Mud's primary-coloured outline. */

.mud-button-root.mud-button-filled,
.mud-button-root.mud-button-outlined,
.mud-button-root.mud-button-text {
    min-height: var(--panel-tap);
    font-size: 16px;
}

.mud-button-root.mud-button-filled,
.mud-button-root.mud-button-outlined {
    padding: 0 18px;
}

.mud-button-root.mud-button-filled,
.mud-button-root.mud-button-filled:hover,
.mud-button-root.mud-button-filled:active,
.mud-button-root.mud-button-filled:focus-visible {
    box-shadow: none;
}

.mud-button-root.mud-button-outlined {
    border-color: var(--panel-border);
    background-color: var(--panel-surface);
    color: var(--panel-text);
}

.mud-button-root.mud-button-outlined:hover {
    background-color: var(--panel-hover);
}

#blazor-error-ui {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1300;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    border-top: 1px solid var(--panel-v-danger-bd);
    background: var(--panel-v-danger-bg);
    color: var(--panel-v-danger-fg);
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

/* ---- messages (HQU-1693) ----------------------------------------------- */

/* One thread, oldest at the top. The tester's own messages sit right on the accent, staff's
   sit left on white, as any phone's messages app draws them. */
.panel-thread {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
}

.panel-msg {
    max-width: 85%;
}

.panel-msg-mine {
    align-self: flex-end;
}

.panel-msg-theirs {
    align-self: flex-start;
}

.panel-msg-body {
    padding: 10px 14px;
    border-radius: var(--panel-radius-card);
    font-size: 15px;
    line-height: 1.45;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.panel-msg-mine .panel-msg-body {
    background: var(--panel-accent);
    color: var(--panel-on-accent);
}

.panel-msg-theirs .panel-msg-body {
    background: var(--panel-surface);
    border: 1px solid var(--panel-border);
    color: var(--panel-text);
}

.panel-msg-meta {
    margin-top: 3px;
    padding: 0 4px;
    color: var(--panel-muted);
    font-size: 12px;
}

.panel-msg-mine .panel-msg-meta {
    text-align: right;
}
