/* Signed-in screens (/home, /webinar): the approved after-login skin (warm paper, charcoal ink, clay accent),
   light and dark. Phone first (390 px), then laptop. Every box 2px corners; nothing rounder. */
.app-page {
  --bg: #f5f2ec; --surface: #fffdf9; --surface-raised: #eee8dd; --text: #1f1d1a; --muted: #6b655c;
  --mint: #a8492b; --line: #dcd4c6; --on-accent: #ffffff;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .app-page {
    --bg: #1c1b19; --surface: #252320; --surface-raised: #322f2a; --text: #ede7dd; --muted: #aaa195;
    --mint: #e39573; --line: #3f3a34; --on-accent: #1c1b19;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] .app-page {
  --bg: #1c1b19; --surface: #252320; --surface-raised: #322f2a; --text: #ede7dd; --muted: #aaa195;
  --mint: #e39573; --line: #3f3a34; --on-accent: #1c1b19;
  color-scheme: dark;
}
.app-page .site-header, .app-page .site-footer { border-color: var(--line); }
.app-page .brand img { filter: invert(1); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .app-page .brand img { filter: none; } }
:root[data-theme="dark"] .app-page .brand img { filter: none; }
.app-page .nav-signin { border-color: var(--line); }
.app-page .beta { color: var(--mint); background: var(--surface-raised); border-color: var(--line); }
.app-page .ask-box { background: var(--surface); border-color: var(--line); box-shadow: none; }
.app-page .ask-box textarea::placeholder { color: var(--muted); }
.app-page .ask-button, .app-page .qg-button.primary { background: var(--mint); border-color: var(--mint); color: var(--on-accent); }
.app-page .feature { background: var(--surface); border-color: var(--line); }
.app-page .feature-icon { background: var(--surface-raised); color: var(--mint); }

.app-main { width: min(100%, 48rem); align-self: center; padding: 1.25rem 1rem 2.5rem; }
.app-main h1 { margin: 0; font-size: clamp(1.45rem, 6vw, 2.1rem); line-height: 1.25; letter-spacing: -.02em; font-weight: 600; }
.app-tag { margin: .35rem 0 0; color: var(--text); line-height: 1.55; }
.app-kicker { margin: 0 0 .5rem; color: var(--mint); font-weight: 650; font-size: .9rem; }
.app-kicker a { color: inherit; }
.app-line { margin: .5rem 0 0; color: var(--muted); font-size: .92rem; }

/* The Beta demo entry and card */
.demo-entry {
  display: flex; align-items: center; justify-content: space-between; gap: .75rem;
  margin: 1.1rem 0; padding: .85rem 1rem; min-height: 3.5rem;
  border: 1px solid var(--mint); border-left-width: 3px; border-radius: 2px;
  background: var(--surface); color: var(--text); text-decoration: none; font-weight: 600;
}
.demo-entry > span:last-child { color: var(--mint); }
.demo-entry:hover { background: var(--surface-raised); }

/* Three talk buttons, one row, equal width, 48 px tall */
.talk { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; margin: 1rem 0; }
.talk a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .1rem;
  min-height: 48px; padding: .35rem .25rem; border: 1px solid var(--text); border-radius: 2px;
  color: var(--text); background: var(--surface); text-decoration: none; font-weight: 600; font-size: .9rem; text-align: center;
}
.talk a.primary { background: var(--mint); border-color: var(--mint); color: var(--on-accent); }
.talk a.primary .beta { color: var(--on-accent); background: transparent; border-color: currentColor; }
.talk .beta { font-size: .65rem; }

.app-section-title { margin: 1.5rem 0 .6rem; font-size: 1.05rem; }
.app-page .feature-grid { margin-top: 0; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.app-page .feature { min-height: 4.2rem; padding: .7rem; gap: .6rem; }
.app-page .feature-icon { width: 2.3rem; height: 2.3rem; }
.app-page .feature-icon svg { width: 1.5rem; height: 1.5rem; }
.app-notes { margin-top: 1.5rem; color: var(--muted); font-size: .8rem; line-height: 1.55; }
.app-notes p { margin: .2rem 0; }

/* /webinar */
.demo-card {
  margin: 1rem 0; padding: 1.25rem 1rem; border: 1px solid var(--line); border-top: 2px solid var(--mint);
  border-radius: 2px; background: var(--surface);
}
.demo-card p { margin: 0; }
.demo-card .demo-when { margin-top: .5rem; font-size: 1.35rem; font-weight: 650; }
.demo-card .demo-small { margin-top: .5rem; color: var(--muted); font-size: .9rem; }
.player { margin: 1rem 0; }
.player video {
  display: block; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: 2px; border: 1px solid var(--line);
}
.player-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; margin-top: .5rem; }
.player-bar p { margin: 0; color: var(--muted); font-size: .88rem; }
.player-bar .qg-button { width: auto; min-height: 44px; }
/* /webinar: the countdown, and one big "Join the webinar" button over the film. 2px corners. */
.demo-card .webinar-count { font-size: 2rem; font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.player-stage { position: relative; }
.player-stage .webinar-join {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: auto; max-width: calc(100% - 2rem); min-height: 56px; padding: .8rem 1.6rem;
  font-size: 1.1rem; white-space: nowrap; border-radius: 2px; box-shadow: 0 2px 12px rgba(0, 0, 0, .35);
}
.demo-ask { margin-top: 1.5rem; }
.demo-ask h2 { font-size: 1.05rem; margin: 0 0 .6rem; }

@media (min-width: 56rem) {
  .app-main { padding-top: 2rem; }
  .app-page .feature-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* /webinar: answers under the ask box (sign-in H). Text only; 2px corners at most. */
.demo-answers { display: grid; gap: .75rem; margin-top: .75rem; }
.demo-turn strong { display: block; margin-bottom: .3rem; font-size: .8rem; color: var(--muted); }
.demo-reply strong { color: var(--mint); }
.demo-turn p { margin: 0 0 .5rem; white-space: pre-wrap; overflow-wrap: anywhere; }
.demo-turn pre { margin: .5rem 0; padding: .7rem; overflow-x: auto; border: 1px solid var(--line); border-radius: 2px; background: var(--surface); }
.demo-turn pre code { font: .85rem/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; white-space: pre; }
.demo-waiting { display: flex; gap: .3rem; min-height: 1.4rem; align-items: center; }
.demo-waiting i { width: .4rem; height: .4rem; background: var(--mint); border-radius: 1px; animation: demo-dot 1s infinite ease-in-out; }
.demo-waiting i:nth-child(3) { animation-delay: .15s; }
.demo-waiting i:nth-child(4) { animation-delay: .3s; }
@keyframes demo-dot { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .demo-waiting i { animation: none; opacity: .7; } }
.demo-note { margin: 0; padding: .6rem .7rem; border: 1px solid var(--line); border-radius: 2px; background: var(--surface); }
.demo-note a, .demo-full-chat a { color: var(--mint); text-decoration: underline; }
.demo-full-chat { margin: .6rem 0 0; font-size: .9rem; }
.qg-support { margin: 0; padding: .6rem .7rem; border: 1px solid var(--mint); border-radius: 2px; background: var(--surface); }
.qg-support-title { margin: 0 0 .4rem; font-weight: 700; }
.qg-support ul { margin: 0; padding-left: 1.1rem; }
.qg-support li { margin: .3rem 0; overflow-wrap: anywhere; }
.qg-support a { color: var(--mint); text-decoration: underline; }
