/* The public demo's wrapper around the new interface (/try/, /try/reader/): a slim bar above the app, the
   Try this list as a band under it, and the failure state. The interface's own styles come from
   ../design/web/. Colours use the interface's tokens, so light and dark follow it. */
body.try-web { display: flex; flex-direction: column; height: 100vh; height: 100dvh; margin: 0; overflow: hidden; }
body.try-web > .pc-app, body.try-web > .pl-app { flex: 1; min-height: 0; height: auto; position: relative; }

.try-bar { flex: none; display: flex; align-items: center; gap: 6px 10px; min-height: 40px; padding: 4px max(10px, env(safe-area-inset-right)) 4px max(12px, env(safe-area-inset-left)); padding-top: max(4px, env(safe-area-inset-top)); background: var(--pc-chrome); border-bottom: 1px solid var(--pc-border); color: var(--pc-text-2); font: 13px/1.35 "DS Sans", system-ui, sans-serif; }
.try-bar__note { margin: 0; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.try-bar__note strong { color: var(--pc-text); font-weight: 600; }
.try-bar__classic { display: flex; align-items: center; gap: 2px; flex: 1; justify-content: flex-end; min-width: 0; margin: 0; white-space: nowrap; }
.try-bar__classic[hidden] { display: none; }
.try-bar__short { display: none; }
.try-bar__classic a { color: var(--pc-accent-text, var(--pc-text)); font-weight: 600; text-underline-offset: 3px; margin-left: 4px; }
.try-bar__classic[hidden] + .try-bar__btn { margin-left: auto; }
.try-bar__btn { flex: none; height: 32px; padding: 0 12px; border: 1px solid var(--pc-border); border-radius: 16px; background: var(--pc-surface); color: var(--pc-text); font: 500 13px "DS Sans", system-ui, sans-serif; cursor: pointer; }
.try-bar__btn[aria-expanded="true"] { background: var(--pc-surface-3); }
.try-bar__x { flex: none; display: inline-grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 16px; background: none; color: var(--pc-text-2); font: 18px/1 system-ui, sans-serif; cursor: pointer; }
.try-bar__btn:hover, .try-bar__x:hover { background: var(--pc-surface-2); }
.try-bar :focus-visible, .try-tips :focus-visible { outline: 2px solid var(--pc-focus, #2C4F73); outline-offset: 2px; }

.try-tips { flex: none; max-height: 38dvh; overflow: auto; padding: 8px max(16px, env(safe-area-inset-right)) 12px max(16px, env(safe-area-inset-left)); background: var(--pc-chrome); border-bottom: 1px solid var(--pc-border); color: var(--pc-text); font: 14px/1.45 "DS Sans", system-ui, sans-serif; }
.try-tips[hidden] { display: none; }
.try-tips__head { display: flex; align-items: center; justify-content: space-between; }
.try-tips h2 { margin: 0; font: 600 16px "DS Sans", system-ui, sans-serif; }
.try-tips h2:focus { outline: none; }
.try-tips ol { margin: 4px 0 0; padding-left: 20px; columns: 2 320px; column-gap: 32px; }
.try-tips li { margin: 0 0 6px; break-inside: avoid; }

.try-failed { position: fixed; inset: 0; z-index: 300; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 24px; text-align: center; background: var(--pc-bg); color: var(--pc-text); font: 15px/1.45 "DS Sans", system-ui, sans-serif; }
.try-failed[hidden] { display: none; }
.try-failed h1 { margin: 0 0 6px; font: 600 22px "DS Sans", system-ui, sans-serif; }
.try-failed a { color: inherit; font-weight: 600; }

/* Narrower windows: the note keeps its first word; the classic line stays whole. */
@media (max-width: 1099px) { .try-bar__note .try-bar__more { display: none; } }

/* Phone: one short line; the long note and the classic sentence give way to the buttons. */
@media (max-width: 699px) {
  .try-bar { gap: 4px; padding-left: max(10px, env(safe-area-inset-left)); }
  .try-bar__more { display: none; }
  .try-bar__long { display: none; } .try-bar__short { display: inline; }
  .try-bar__ask { display: none; } /* the question goes; the link and its close button stay */
  .try-bar__classic a { margin-left: 0; }
  .try-bar__btn { height: 32px; padding: 0 10px; }
}
@media (max-width: 380px) { .try-bar__note { display: none; } }
