/* Live demo page (docs/CANLI_DENEME.md). Computer: the guest's chat in a phone frame on the left, the team's Telegram
   group on the right. Phone: one side at a time with tabs. Colors come from ask.css (--bg, --card, --text, --hint,
   --accent) so dark mode follows; the few extra ones are below. */
:root {
  --stage: #e9edf4;
  --frame: #15181e;
  --tg-feed: #dfe8f1;
  --tg-bot: #ffffff;
  --tg-me: #e3f4d7;
  --tg-head: #ffffff;
}
@media (prefers-color-scheme: dark) {
  :root { --stage: #0b0d12; --frame: #000; --tg-feed: #0e1621; --tg-bot: #182533; --tg-me: #2b5278; --tg-head: #17212b; }
}

body.demo { max-width: none; height: 100dvh; overflow: hidden; background: var(--stage); }
.demobar { flex: none; display: flex; align-items: center; gap: 14px; padding: 10px 24px; background: var(--card); border-bottom: 1px solid color-mix(in srgb, var(--hint) 22%, transparent); }
.demobar .brand { font-weight: 700; color: var(--text); text-decoration: none; }
.demobar .what { flex: 1; min-width: 0; color: var(--hint); font-size: 14px; }
.demobar .cta { flex: none; border-radius: 12px; padding: 9px 14px; font-weight: 600; font-size: 14px; color: #fff; text-decoration: none; background: linear-gradient(135deg, var(--ai1), var(--ai2)); }

.tabs { display: none; }
.panes { flex: 1; min-height: 0; width: 100%; max-width: 1240px; margin: 0 auto; padding: 22px 24px; box-sizing: border-box;
  display: grid; grid-template-columns: minmax(340px, 400px) minmax(0, 1fr); gap: 28px; }
.pane { min-height: 0; display: flex; flex-direction: column; overflow: hidden; }

/* the guest's phone */
.pane.guest { background: var(--bg); border: 10px solid var(--frame); border-radius: 38px; box-shadow: 0 18px 50px rgb(15 23 42 / 18%); max-height: 860px; align-self: center; height: 100%; box-sizing: border-box; }
.pane.guest .hero { border-radius: 0; }
.pane.guest main { min-height: 0; }
.pane.guest .composer { padding-bottom: 12px; }

.tries { flex: none; padding: 0 12px; }
.tries .label { font-size: 12px; color: var(--hint); margin: 4px 0; }
.tries .row { display: flex; flex-wrap: wrap; gap: 6px; padding-bottom: 6px; } /* wraps: never a scrollbar or a cut-off question */
.tries button { flex: none; max-width: 100%; white-space: normal; text-align: left; border: 1px dashed color-mix(in srgb, var(--accent) 50%, transparent); border-radius: 999px; padding: 6px 12px; font: inherit; font-size: 13px; background: var(--card); color: var(--text); cursor: pointer; }

/* the team's Telegram group */
.pane.team { background: var(--tg-feed); border-radius: 18px; box-shadow: 0 10px 34px rgb(15 23 42 / 12%); }
.tghead { flex: none; display: flex; align-items: center; gap: 12px; padding: 12px 16px; background: var(--tg-head); border-bottom: 1px solid color-mix(in srgb, var(--hint) 20%, transparent); }
.tgav { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 14px; color: #fff; background: linear-gradient(135deg, #f59e0b, #ef4444); }
.tgtitle { font-weight: 700; font-size: 15px; }
.tgsub { color: var(--hint); font-size: 12px; }
.teamnote { flex: none; padding: 8px 16px; font-size: 12px; color: var(--hint); background: color-mix(in srgb, var(--tg-head) 70%, transparent); }
.tgfeed { flex: 1; min-height: 0; overflow-y: auto; padding: 14px 16px 20px; display: flex; flex-direction: column; gap: 8px; }
.tgfeed .empty { margin: auto; text-align: center; max-width: 320px; }
.tgpin { align-self: center; font-size: 12px; padding: 4px 12px; border-radius: 999px; background: color-mix(in srgb, var(--tg-head) 85%, transparent); color: var(--text); }
.tg { max-width: min(560px, 88%); border-radius: 14px; padding: 8px 12px 9px; box-shadow: 0 1px 1px rgb(0 0 0 / 8%); }
.tg.bot { align-self: flex-start; background: var(--tg-bot); border-bottom-left-radius: 4px; }
.tg.me { align-self: flex-end; background: var(--tg-me); border-bottom-right-radius: 4px; }
.tgwho { display: flex; justify-content: space-between; gap: 14px; font-size: 12px; font-weight: 600; color: var(--accent); }
.tgwho .at { color: var(--hint); font-weight: 400; }
.tgline { font-weight: 600; margin-top: 2px; }
.tg .text { overflow-wrap: anywhere; white-space: pre-wrap; }
.tg .orig { margin-top: 4px; font-size: 12px; color: var(--hint); overflow-wrap: anywhere; }
.muted { color: var(--hint); font-size: 13px; }
.st { display: inline-block; margin-top: 6px; font-size: 12px; font-weight: 600; border-radius: 999px; padding: 1px 9px; background: color-mix(in srgb, var(--hint) 18%, transparent); }
.st-accepted, .st-in_progress, .st-preparing, .st-on_the_way { background: color-mix(in srgb, #f5a524 32%, transparent); }
.st-delivered, .st-done { background: color-mix(in srgb, #30a46c 32%, transparent); }

@media (max-width: 899px) {
  body.demo { background: var(--bg); }
  .demobar { flex-wrap: wrap; gap: 6px 10px; padding: 8px 16px; }
  .demobar .what { order: 3; flex-basis: 100%; font-size: 13px; }
  .demobar .cta { margin-left: auto; padding: 7px 10px; font-size: 13px; }
  .tabs { flex: none; display: flex; background: var(--card); border-bottom: 1px solid color-mix(in srgb, var(--hint) 25%, transparent); }
  .tabs button { flex: 1; border: 0; background: transparent; color: var(--hint); font: inherit; font-weight: 600; padding: 10px; cursor: pointer; border-bottom: 2px solid transparent; position: relative; }
  .tabs button[aria-selected="true"] { color: var(--text); border-bottom-color: var(--accent); }
  .tabs button.new::after { content: ""; position: absolute; top: 9px; margin-left: 6px; width: 8px; height: 8px; border-radius: 50%; background: #e5484d; }
  /* phones: no frames, the tab already names the side */
  .panes { display: flex; padding: 0; max-width: none; gap: 0; }
  .pane { flex: 1; min-width: 0; }
  .pane.guest { border: 0; border-radius: 0; box-shadow: none; max-height: none; }
  .pane.team { border-radius: 0; box-shadow: none; }
  .tghead { padding: 8px 12px; }
  .teamnote { padding: 6px 12px; }
  body[data-tab="guest"] .pane.team, body[data-tab="team"] .pane.guest { display: none; }
  body.sent .tries { display: none; } /* after the first message the examples make way for the chat */
}

/* inside the phone frame the header has a phone's width: one line each */
.pane.guest .hero { padding: 14px 14px 12px; }
.pane.guest .biz, .pane.guest .sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pane.guest .sub { display: block; }
.pane.guest .sub .dot { display: inline-block; margin-right: 6px; vertical-align: middle; }
.pane.guest #privacy { display: none; } /* the menu below has "Privacy" already: one way to it, not two */
body.sent .tries { display: none; } /* after the first message the examples make way for the chat (computer too) */

/* phones: the chat gets the room. One-line top bar (the tabs say what the two sides are), a slim hotel header, no
   "ask us anything" box over the welcome that says the same, smaller keys. */
@media (max-width: 899px) {
  .demobar .what { display: none; }
  .demobar { padding: 6px 12px; }
  .demobar .cta { padding: 6px 10px; font-size: 12px; }
  .tabs button { padding: 8px; }
  .pane.guest .hero { padding: 8px 12px; }
  .pane.guest .hero .avatar { width: 32px; height: 32px; font-size: 18px; }
  .pane.guest main .empty { display: none; }
  .pane.guest .chips button, .tries button { padding: 5px 10px; font-size: 12px; }
  .tries .label { display: none; }
}
