/* * @bitbaum/chatkit — the look of the one chat. * * Every colour, radius and face is a --ck-* variable. By default they read * @bitbaum/design-tokens' HSL-triplet variables, so apps on those tokens match * without doing anything. An app whose variables are full colours (loki's are * OKLCH under the same names) maps them once — `:root { --ck-bg: * var(--surface-base); … }` — and any other app sets --ck-* to keep its own * look. The BEHAVIOUR is what is shared, and it is not configurable. * * Non-negotiable, and why: * - 16px text in the input and the messages: under 16px iOS zooms the whole * page when the input is focused (loki globals.css). * - 44px touch targets on every control (WCAG 2.5.8, loki's audit). * - Nothing wider than its container at 320px (min-width: 0 on flex rows — * heidi composer.tsx). */ :where(:root) { /* Defaults at ZERO specificity on the root: an app's own :root (or any container) rule setting a --ck-* variable always wins. Declaring these on the chat's elements instead would silently override the app. */ --ck-page: hsl(var(--surface-page, 0 0% 99%)); --ck-bg: hsl(var(--surface-base, 0 0% 100%)); --ck-raised: hsl(var(--surface-raised, 0 0% 96%)); --ck-overlay: hsl(var(--surface-overlay, 0 0% 98%)); --ck-fg: hsl(var(--text-primary, 0 0% 10%)); --ck-fg-2: hsl(var(--text-secondary, 0 0% 30%)); --ck-fg-3: hsl(var(--text-tertiary, 0 0% 42%)); --ck-muted: hsl(var(--text-muted, 0 0% 50%)); --ck-line: hsl(var(--border-subtle, 0 0% 90%)); --ck-line-2: hsl(var(--border-default, 0 0% 82%)); --ck-accent: var(--accent-primary, #ff5c00); --ck-on-accent: hsl(var(--on-accent, 0 0% 8%)); --ck-accent-soft: color-mix(in srgb, var(--ck-accent) 14%, transparent); --ck-danger: hsl(var(--status-negative, 0 65% 50%)); --ck-danger-soft: color-mix(in srgb, var(--ck-danger) 12%, transparent); --ck-on-danger: #fff; --ck-warning: hsl(var(--status-warning, 38 92% 45%)); --ck-radius: 1rem; --ck-radius-sm: var(--radius-control, 0.5rem); --ck-font: var(--font-sans, system-ui, -apple-system, "Segoe UI", sans-serif); --ck-mono: var(--font-mono, ui-monospace, "SF Mono", Menlo, monospace); --ck-text: 1rem; --ck-leading: 1.6; --ck-target: 2.75rem; /* ChatScreen: the reading column, and the margin it keeps from the edge. */ --ck-measure: 48rem; --ck-gutter: 1rem; /* ChatScreen measures the floating header and dock into these; with no ChatScreen they are 0. --ck-viewport-height is set by useViewportHeight. */ --ck-top-inset: 0px; --ck-bottom-inset: 0px; --ck-viewport-height: 100dvh; /* The person's own words. Neutral, not the accent: the accent is for the one thing to press, and a column of tinted pills spent it on every turn. */ --ck-bubble: var(--ck-raised); } .ck-screen, .ck-composer-wrap, .ck-thread-wrap, .ck-starters, .ck-replies { font-family: var(--ck-font); color: var(--ck-fg); } .ck-screen *, .ck-composer-wrap *, .ck-thread-wrap *, .ck-starters *, .ck-replies * { box-sizing: border-box; } /* ── composer ───────────────────────────────────────────────────────────── */ .ck-composer-wrap { display: flex; flex-direction: column; gap: 0.5rem; min-width: 0; } .ck-composer-frame { position: relative; min-width: 0; } .ck-composer { display: flex; flex-direction: column; gap: 0.5rem; min-width: 0; padding: 0.75rem 0.75rem 0.625rem; border: 1px solid var(--ck-line); border-radius: var(--ck-radius); background: var(--ck-bg); transition: border-color 0.15s ease; } .ck-composer:focus-within { border-color: var(--ck-line-2); } .ck-composer-compact { gap: 0.375rem; padding: 0.5rem; border-radius: calc(var(--ck-radius) * 0.75); } .ck-input { display: block; width: 100%; min-height: 2.5rem; max-height: 15rem; resize: none; overflow-y: auto; padding: 0.375rem 0.25rem; border: 0; outline: none; background: transparent; color: var(--ck-fg); font: inherit; font-size: max(16px, var(--ck-text)); line-height: var(--ck-leading); } .ck-input::placeholder { color: var(--ck-muted); /* One line, always: an empty box is one row high on every phone, and a long placeholder is cut at the edge rather than wrapped into a second line that the box then clips in half (320px, 2026-10-21). */ white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .ck-input:placeholder-shown { overflow: hidden; } .ck-actions { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; min-width: 0; } .ck-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 0.375rem; min-width: 0; } .ck-submit { display: flex; align-items: center; gap: 0.5rem; flex-shrink: 0; } .ck-hint { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ck-muted); font-size: 0.8125rem; } @media (max-width: 480px) { .ck-hint { display: none; } } .ck-icon-btn, .ck-send { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; min-width: var(--ck-target); min-height: var(--ck-target); padding: 0; border-radius: 999px; font-size: 1.125rem; cursor: pointer; transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, opacity 0.15s ease; } .ck-icon-btn { border: 1px solid var(--ck-line); background: var(--ck-raised); color: var(--ck-fg-2); } .ck-icon-btn:hover:not(:disabled) { border-color: var(--ck-line-2); color: var(--ck-fg); } .ck-mic-on { border-color: var(--ck-danger); background: var(--ck-danger-soft); color: var(--ck-danger); } .ck-send { border: 0; background: var(--ck-accent); color: var(--ck-on-accent); } .ck-send:hover:not(:disabled) { opacity: 0.9; } .ck-send:disabled, .ck-icon-btn:disabled { cursor: not-allowed; opacity: 0.45; } .ck-send:disabled { background: var(--ck-raised); color: var(--ck-muted); opacity: 1; } .ck-send-stop { background: var(--ck-raised); color: var(--ck-fg); border: 1px solid var(--ck-line-2); } :where(.ck-composer-wrap, .ck-thread-wrap, .ck-starters, .ck-replies) button:focus-visible, .ck-input:focus-visible { outline: 2px solid var(--ck-accent); outline-offset: 2px; } .ck-input:focus-visible { outline: none; } .ck-modes { display: flex; flex-wrap: wrap; gap: 0.25rem; } .ck-mode { min-height: 2rem; padding: 0 0.75rem; border: 1px solid var(--ck-line); border-radius: 999px; background: transparent; color: var(--ck-fg-2); font: inherit; font-size: 0.875rem; cursor: pointer; } .ck-mode[aria-pressed="true"] { border-color: var(--ck-accent); background: var(--ck-accent-soft); color: var(--ck-fg); } /* voice: the bar covers the box while a take is live, so what is happening — and how to keep or throw it away — is unmissable */ .ck-voice-bar { position: absolute; inset: 0; z-index: 2; display: flex; align-items: center; gap: 0.75rem; padding: 0 0.75rem; border: 1px solid var(--ck-line-2); border-radius: var(--ck-radius); background: var(--ck-bg); color: var(--ck-fg-2); } .ck-voice-dot { width: 0.625rem; height: 0.625rem; flex-shrink: 0; border-radius: 999px; background: var(--ck-danger); animation: ck-pulse 1.2s ease-in-out infinite; } .ck-voice-wave { display: flex; flex: 1; align-items: center; justify-content: center; gap: 0.25rem; height: 1.75rem; min-width: 0; overflow: hidden; } .ck-voice-wave > span { width: 0.25rem; height: 100%; border-radius: 999px; background: var(--ck-accent); transform: scaleY(0.3); animation: ck-wave 1s ease-in-out infinite; } .ck-voice-wave > span:nth-child(2n) { animation-delay: -0.3s; } .ck-voice-wave > span:nth-child(3n) { animation-delay: -0.6s; } .ck-voice-wave > span:nth-child(5n) { animation-delay: -0.8s; } /* the words as they are heard: one line, its end always in view, the start fading out — the person reads the newest words, not the oldest */ .ck-voice-live { flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; font-size: 0.9375rem; line-height: 1.4; color: var(--ck-fg); -webkit-mask-image: linear-gradient(to right, transparent, #000 1.75rem); mask-image: linear-gradient(to right, transparent, #000 1.75rem); } .ck-voice-live-dim { color: var(--ck-fg-3); } .ck-voice-timer { flex-shrink: 0; font-size: 0.9375rem; font-variant-numeric: tabular-nums; } .ck-voice-confirm { display: inline-flex; align-items: center; justify-content: center; min-width: var(--ck-target); min-height: var(--ck-target); border: 0; border-radius: 999px; background: var(--ck-danger); color: var(--ck-on-danger); font-size: 1.125rem; cursor: pointer; } .ck-problem { display: flex; align-items: flex-start; gap: 0.5rem; margin: 0; padding: 0.5rem 0.625rem; border: 1px solid color-mix(in srgb, var(--ck-warning) 40%, transparent); border-radius: var(--ck-radius-sm); color: var(--ck-fg-2); font-size: 0.9375rem; line-height: 1.45; } .ck-problem > span { flex: 1; min-width: 0; } .ck-problem-detail { color: var(--ck-muted); } .ck-problem-retry { flex-shrink: 0; min-height: 2rem; padding: 0 0.75rem; border: 1px solid var(--ck-line-2); border-radius: 999px; background: transparent; color: var(--ck-fg); font: inherit; font-size: 0.875rem; cursor: pointer; } .ck-problem-retry:disabled { opacity: 0.5; cursor: default; } .ck-problem-x { display: inline-flex; flex-shrink: 0; padding: 0.125rem; border: 0; background: transparent; color: var(--ck-muted); cursor: pointer; } /* attachments */ .ck-attach-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; } .ck-attach-item { position: relative; } .ck-attach-thumb { display: block; width: 3.5rem; height: 3.5rem; object-fit: cover; border: 1px solid var(--ck-line); border-radius: var(--ck-radius-sm); } .ck-attach-file { display: flex; align-items: center; gap: 0.375rem; max-width: 11rem; height: 3.5rem; padding: 0 0.5rem; border: 1px solid var(--ck-line); border-radius: var(--ck-radius-sm); background: var(--ck-raised); color: var(--ck-fg-2); font-size: 0.8125rem; } .ck-attach-remove { position: absolute; top: -0.5rem; right: -0.5rem; display: inline-flex; align-items: center; justify-content: center; width: 1.5rem; height: 1.5rem; border: 1px solid var(--ck-line-2); border-radius: 999px; background: var(--ck-overlay); color: var(--ck-fg-2); font-size: 0.75rem; cursor: pointer; } .ck-attach-remove::after { content: ""; position: absolute; inset: -0.625rem; } .ck-note { border: 0; background: transparent; color: var(--ck-warning); font: inherit; font-size: 0.8125rem; text-align: left; cursor: pointer; } .ck-truncate { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } /* ── thread ─────────────────────────────────────────────────────────────── */ .ck-thread-wrap { position: relative; display: flex; flex: 1; flex-direction: column; min-height: 0; min-width: 0; } .ck-thread { display: flex; flex: 1; flex-direction: column; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 0.5rem 0; } .ck-thread-inner { display: flex; flex-direction: column; gap: 1.25rem; margin-top: auto; min-width: 0; } .ck-thread-loading { display: flex; flex: 1; align-items: center; justify-content: center; color: var(--ck-muted); } .ck-turn { display: flex; flex-direction: column; min-width: 0; } .ck-turn-user { align-items: flex-end; } .ck-bubble { max-width: min(85%, 42rem); padding: 0.625rem 1rem; border-radius: calc(var(--ck-radius) * 1.25); background: var(--ck-bubble); color: var(--ck-fg); font-size: var(--ck-text); line-height: var(--ck-leading); white-space: pre-wrap; overflow-wrap: anywhere; } .ck-speaker { margin-bottom: 0.25rem; color: var(--ck-fg-3); font-family: var(--ck-mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; } .ck-turn-actions { display: flex; gap: 0.25rem; margin-top: 0.25rem; } .ck-action { display: inline-flex; align-items: center; gap: 0.375rem; min-height: 2.25rem; padding: 0 0.5rem; border: 0; border-radius: var(--ck-radius-sm); background: transparent; color: var(--ck-muted); font: inherit; font-size: 0.875rem; cursor: pointer; } .ck-action:hover { background: var(--ck-raised); color: var(--ck-fg-2); } @media (hover: hover) { .ck-turn-answer .ck-turn-actions { opacity: 0; transition: opacity 0.15s ease; } .ck-turn-answer:hover .ck-turn-actions, .ck-turn-answer:focus-within .ck-turn-actions, .ck-turn-pinned .ck-turn-actions { opacity: 1; } } .ck-failed { margin: 0; padding: 0.625rem 0.875rem; border: 1px solid color-mix(in srgb, var(--ck-danger) 35%, transparent); border-radius: var(--ck-radius-sm); background: var(--ck-danger-soft); color: var(--ck-fg); font-size: var(--ck-text); } .ck-live { display: flex; align-items: center; gap: 0.5rem; margin: 0; color: var(--ck-fg-3); font-size: var(--ck-text); } .ck-dots { display: inline-flex; gap: 0.25rem; } .ck-dots > span { width: 0.375rem; height: 0.375rem; border-radius: 999px; background: var(--ck-muted); animation: ck-dot 1.2s ease-in-out infinite; } .ck-dots > span:nth-child(2) { animation-delay: 0.15s; } .ck-dots > span:nth-child(3) { animation-delay: 0.3s; } .ck-stop { display: inline-flex; align-items: center; gap: 0.375rem; align-self: flex-start; min-height: 2.25rem; margin-top: 0.5rem; padding: 0 0.875rem; border: 1px solid var(--ck-line); border-radius: 999px; background: transparent; color: var(--ck-fg-3); font: inherit; font-size: 0.875rem; cursor: pointer; } .ck-stopped { margin: 0; color: var(--ck-muted); } .ck-jump { position: absolute; bottom: 0.75rem; left: 50%; transform: translateX(-50%); display: inline-flex; align-items: center; justify-content: center; width: var(--ck-target); height: var(--ck-target); border: 1px solid var(--ck-line-2); border-radius: 999px; background: var(--ck-overlay); color: var(--ck-fg-2); font-size: 1.125rem; cursor: pointer; box-shadow: 0 6px 20px -8px rgb(0 0 0 / 0.35); } /* ── screen ───────────────────────────────────────────────────────────── The whole display is the conversation; header and composer float over it. --ck-top-inset / --ck-bottom-inset are measured by ChatScreen. */ .ck-screen { position: relative; display: flex; flex-direction: column; height: 100%; min-height: 0; min-width: 0; overflow: hidden; background: var(--ck-page); } .ck-screen-viewport { height: var(--ck-viewport-height, 100dvh); } .ck-screen-body { position: relative; display: flex; flex: 1; flex-direction: column; min-height: 0; min-width: 0; } /* Words pass under the header and fade as they do: the page colour at the very top, nothing by the bottom of the row. No bar, no border. */ .ck-screen-header { position: absolute; inset: 0 0 auto; z-index: 3; /* Mostly page behind the row itself, so a title in it stays one line of text and not two on top of each other; the words only show through dimly, and the fade runs out in the strip below the row. */ padding: env(safe-area-inset-top, 0px) var(--ck-gutter) 0.75rem; background: linear-gradient( to bottom, var(--ck-page) 0%, color-mix(in srgb, var(--ck-page) 88%, transparent) 55%, color-mix(in srgb, var(--ck-page) 55%, transparent) 80%, transparent 100% ); pointer-events: none; } .ck-screen-header-row { display: flex; align-items: center; gap: 0.5rem; min-width: 0; min-height: 3.5rem; padding-block: 0.375rem; } .ck-screen-header-row > * { pointer-events: auto; } .ck-screen-dock { position: absolute; inset: auto 0 0; z-index: 3; padding: 1.5rem var(--ck-gutter) calc(0.5rem + env(safe-area-inset-bottom, 0px)); background: linear-gradient(to top, var(--ck-page) 0%, var(--ck-page) 40%, transparent 100%); pointer-events: none; } .ck-screen-column { display: flex; flex-direction: column; gap: 0.5rem; width: 100%; max-width: var(--ck-measure); margin-inline: auto; pointer-events: auto; } .ck-screen-footnote { margin: 0; color: var(--ck-muted); font-size: 0.75rem; line-height: 1.4; text-align: center; } /* The composer as a floating pill: see-through enough to show the words passing under it, solid enough to type on. */ .ck-screen-dock .ck-composer { border-color: color-mix(in srgb, var(--ck-line-2) 70%, transparent); border-radius: 1.75rem; background: color-mix(in srgb, var(--ck-bg) 86%, transparent); -webkit-backdrop-filter: blur(20px) saturate(1.4); backdrop-filter: blur(20px) saturate(1.4); box-shadow: 0 6px 28px -12px rgb(0 0 0 / 0.28); } .ck-screen-dock .ck-voice-bar { border-radius: 1.75rem; } /* With no header, the words still fade at the top edge instead of being cut off mid-line. */ .ck-screen:not(:has(> .ck-screen-header)) .ck-thread { -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 1.5rem); mask-image: linear-gradient(to bottom, transparent 0, #000 1.5rem); } /* The thread scrolls the full width (the scrollbar sits at the screen's edge, and a swipe anywhere moves it); its column keeps a reading measure. */ .ck-screen .ck-thread { padding: var(--ck-top-inset, 0px) var(--ck-gutter) calc(var(--ck-bottom-inset, 0px) + 0.75rem); scroll-padding-top: var(--ck-top-inset, 0px); scroll-padding-bottom: var(--ck-bottom-inset, 0px); } .ck-screen .ck-thread-inner { width: 100%; max-width: var(--ck-measure); margin-inline: auto; } .ck-screen .ck-jump { bottom: calc(var(--ck-bottom-inset, 0px) + 0.5rem); z-index: 4; } .ck-screen-body > .ck-starters, .ck-screen-body > .ck-thread-loading { flex: 1; justify-content: center; width: 100%; max-width: calc(var(--ck-measure) + 2 * var(--ck-gutter)); margin-inline: auto; padding: var(--ck-top-inset, 0px) var(--ck-gutter) var(--ck-bottom-inset, 0px); overflow-y: auto; } /* A control floating over the conversation: a frosted pill, the way the header buttons sit over the words in the ChatGPT app. For an app's own header buttons inside ChatScreen. */ .ck-glass { display: inline-flex; align-items: center; justify-content: center; gap: 0.375rem; min-width: var(--ck-target); min-height: var(--ck-target); padding: 0 0.75rem; border: 1px solid color-mix(in srgb, var(--ck-line-2) 60%, transparent); border-radius: 999px; background: color-mix(in srgb, var(--ck-bg) 70%, transparent); -webkit-backdrop-filter: blur(16px) saturate(1.4); backdrop-filter: blur(16px) saturate(1.4); box-shadow: 0 2px 10px -4px rgb(0 0 0 / 0.18); color: var(--ck-fg); font: inherit; font-size: 0.9375rem; cursor: pointer; } .ck-glass:hover { background: color-mix(in srgb, var(--ck-bg) 88%, transparent); } .ck-glass:focus-visible { outline: 2px solid var(--ck-accent); outline-offset: 2px; } @supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) { .ck-glass, .ck-screen-dock .ck-composer { background: var(--ck-bg); } } /* markdown: 16px, readable measure, no leaked ** or > */ .ck-md { min-width: 0; color: var(--ck-fg); font-size: var(--ck-text); line-height: var(--ck-leading); overflow-wrap: anywhere; } .ck-md > * { margin: 0; } .ck-md > * + * { margin-top: 0.75em; } .ck-md ul, .ck-md ol { padding-left: 1.25em; } .ck-md li + li { margin-top: 0.25em; } .ck-md-h { margin: 0; font-weight: 650; line-height: 1.3; } .ck-md > .ck-md-h + * { margin-top: 0.5em; } .ck-md > * + .ck-md-h { margin-top: 1.25em; } .ck-md-h1 { font-size: 1.375em; } .ck-md-h2 { font-size: 1.1875em; } .ck-md-h3 { font-size: 1.0625em; } .ck-md ul ul, .ck-md ol ul { margin-top: 0.25em; } .ck-task { list-style: none; margin-left: -1.25em; } .ck-task > input { margin: 0 0.5em 0 0; vertical-align: -0.1em; accent-color: var(--ck-accent); pointer-events: none; } .ck-hr { height: 1px; margin: 1.25em 0; border: 0; background: var(--ck-line); } .ck-img { display: block; max-width: 100%; height: auto; margin: 0.25em 0; border: 1px solid var(--ck-line); border-radius: var(--ck-radius-sm); } /* A list of named things, as cards: a badge, the name, the body. The row is a grid so a long name wraps under itself, never under the badge. */ .ck-cards { display: flex; flex-direction: column; gap: 0.875em; margin: 0; padding: 0; list-style: none; } .ck-card { display: grid; grid-template-columns: 2.5em minmax(0, 1fr); gap: 0.75em; align-items: start; } .ck-card-badge { display: flex; align-items: center; justify-content: center; width: 2.5em; height: 2.5em; border-radius: 0.75em; background: var(--ck-raised); color: var(--ck-fg-2); font-size: 1em; font-weight: 600; font-variant-numeric: tabular-nums; } .ck-cards:not(.ck-cards-numbered) .ck-card-badge:not(.ck-card-icon) { font-size: 1.5em; line-height: 1; } .ck-card-icon { font-size: 1.25em; } .ck-card-body { min-width: 0; padding-top: 0.2em; } .ck-card-title { font-weight: 650; } .ck-card-text { margin-top: 0.25em; color: var(--ck-fg-2); } .ck-card-body > ul { margin-top: 0.375em; } /* A table that scrolls sideways on a phone instead of breaking the page. */ .ck-table-wrap { max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; } .ck-table { width: 100%; border-collapse: collapse; font-size: 0.9375em; line-height: 1.45; } .ck-table th, .ck-table td { padding: 0.5em 0.75em 0.5em 0; border-bottom: 1px solid var(--ck-line); text-align: left; vertical-align: top; } .ck-table th { color: var(--ck-fg); font-weight: 650; } .ck-table td { color: var(--ck-fg); } .ck-table tr:last-child td { border-bottom: 0; } /* The sources an answer cites, once, under it: a label and a chip each. */ .ck-sources { display: flex; flex-wrap: wrap; align-items: center; gap: 0.375rem; margin-top: 1em; } .ck-sources-label { margin-right: 0.25rem; color: var(--ck-muted); font-size: 0.8125rem; } .ck-source { display: inline-flex; align-items: center; gap: 0.375em; max-width: 100%; min-height: 2rem; padding: 0 0.625rem; border: 1px solid var(--ck-line); border-radius: 999px; background: var(--ck-raised); color: var(--ck-fg-2); font-size: 0.8125rem; text-decoration: none; } a.ck-source:hover { border-color: var(--ck-line-2); color: var(--ck-fg); } .ck-source-id { font-family: var(--ck-mono); font-size: 0.75em; color: var(--ck-muted); } .ck-source-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .ck-md blockquote { padding-left: 0.875em; border-left: 3px solid var(--ck-line-2); color: var(--ck-fg-2); } .ck-md strong { font-weight: 650; } .ck-code { padding: 0.1em 0.35em; border-radius: 0.3em; background: var(--ck-raised); font-family: var(--ck-mono); font-size: 0.875em; } .ck-pre { overflow-x: auto; padding: 0.75rem 0.875rem; border: 1px solid var(--ck-line); border-radius: var(--ck-radius-sm); background: var(--ck-raised); font-family: var(--ck-mono); font-size: 0.875rem; line-height: 1.55; } .ck-pre code { white-space: pre; } .ck-link { color: inherit; text-decoration: underline; text-decoration-color: var(--ck-accent); text-underline-offset: 0.18em; } .ck-cite { margin-left: 0.15em; color: var(--ck-muted); font-size: 0.7em; cursor: help; } /* starters */ .ck-starters { display: flex; flex-direction: column; gap: 0.75rem; min-width: 0; } .ck-starters-title { color: var(--ck-fg-2); font-size: var(--ck-text); } .ck-starters-list { display: flex; flex-wrap: wrap; gap: 0.5rem; } .ck-starter { min-height: var(--ck-target); padding: 0.5rem 0.875rem; border: 1px solid var(--ck-line); border-radius: calc(var(--ck-radius) * 0.75); background: var(--ck-bg); color: var(--ck-fg-2); font: inherit; font-size: 0.9375rem; text-align: left; cursor: pointer; } .ck-starter:hover { border-color: var(--ck-accent); color: var(--ck-fg); } /* suggested replies — under the latest answer, one tap sends */ .ck-replies { display: flex; flex-wrap: wrap; gap: 0.5rem; min-width: 0; margin-top: 0.75rem; } .ck-reply { min-width: var(--ck-target); min-height: var(--ck-target); max-width: 100%; padding: 0.5rem 0.875rem; border: 1px solid var(--ck-line); border-radius: 999px; background: var(--ck-bg); color: var(--ck-fg); font: inherit; font-size: 0.9375rem; line-height: 1.25; text-align: left; overflow-wrap: anywhere; cursor: pointer; } .ck-reply:hover { border-color: var(--ck-accent); } /* The first reply is the recommended next step: the same pill, drawn as the lead — a firmer line and the reading colour — so the eye lands on it. */ .ck-reply-lead { border-color: var(--ck-line-2); background: var(--ck-raised); font-weight: 500; } .ck-reply:disabled { opacity: 0.5; cursor: default; } .ck-spin { animation: ck-spin 0.9s linear infinite; } @keyframes ck-spin { to { transform: rotate(360deg); } } @keyframes ck-pulse { 50% { opacity: 0.35; } } @keyframes ck-wave { 50% { transform: scaleY(1); } } @keyframes ck-dot { 0%, 80%, 100% { opacity: 0.3; } 40% { opacity: 1; } } @media (prefers-reduced-motion: reduce) { .ck-spin, .ck-voice-dot, .ck-voice-wave > span, .ck-dots > span { animation: none; } } /* attach sheet: Camera / Photos / Files, from the bottom edge on a phone — where the thumb already is after tapping the paperclip. A native in the top layer, so no panel around the composer can clip it. */ .ck-sheet { width: 100%; max-width: 32rem; max-height: none; margin: auto auto 0; padding: 0; border: 0; background: transparent; color: var(--ck-fg); font-family: var(--ck-font); } .ck-sheet::backdrop { background: color-mix(in srgb, #000 40%, transparent); } .ck-sheet[open] .ck-sheet-panel { animation: ck-rise 0.18s ease-out; } .ck-sheet-panel { padding: 0.75rem 1rem calc(1rem + env(safe-area-inset-bottom, 0px)); border: 1px solid var(--ck-line); border-bottom: 0; border-radius: var(--ck-radius) var(--ck-radius) 0 0; background: var(--ck-bg); } .ck-sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.75rem; } .ck-sheet-title { font-size: 1rem; font-weight: 600; } .ck-sheet-close { border-color: transparent; background: transparent; } .ck-attach-sources { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 0.5rem; } .ck-attach-source { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.375rem; min-height: 5rem; padding: 0.75rem 0.25rem; border: 1px solid var(--ck-line); border-radius: var(--ck-radius-sm); background: var(--ck-raised); color: var(--ck-fg); font: inherit; font-size: 0.9375rem; cursor: pointer; } .ck-attach-source > svg { font-size: 1.375rem; color: var(--ck-fg-2); } .ck-attach-source:hover { border-color: var(--ck-line-2); } .ck-attach-source:focus-visible, .ck-sheet-close:focus-visible { outline: 2px solid var(--ck-accent); outline-offset: 2px; } .ck-attach-trigger { display: inline-flex; align-items: center; justify-content: center; gap: 0.375rem; min-height: var(--ck-target); padding: 0 1rem; border: 1px solid var(--ck-line); border-radius: 999px; background: var(--ck-raised); color: var(--ck-fg); font: inherit; font-size: 0.9375rem; cursor: pointer; } .ck-attach-trigger:disabled { cursor: not-allowed; opacity: 0.45; } /* An app's own rows under Camera · Photos · Files in the attach sheet. */ .ck-sheet-extra { display: flex; flex-direction: column; gap: 0.125rem; margin-top: 0.75rem; padding-top: 0.75rem; border-top: 1px solid var(--ck-line); } /* while an answer is read aloud: Stop, a quiet wave, the time so far */ .ck-player { align-items: center; } .ck-action-stop { color: var(--ck-fg); } .ck-player-wave { display: inline-flex; align-items: center; gap: 2px; height: 1rem; } .ck-player-wave > span { display: block; width: 2px; height: 0.375rem; border-radius: 1px; background: var(--ck-fg-2); animation: ck-wave 1s ease-in-out infinite; } .ck-player-wave > span:nth-child(2n) { animation-delay: 0.15s; } .ck-player-wave > span:nth-child(3n) { animation-delay: 0.3s; } @keyframes ck-wave { 50% { height: 1rem; } } .ck-player-time { font-size: 0.8125rem; font-variant-numeric: tabular-nums; color: var(--ck-fg-2); } @media (prefers-reduced-motion: reduce) { .ck-player-wave > span { animation: none; height: 0.75rem; } } /* the sources sheet on a touch screen: one row per record */ .ck-sources-open { cursor: pointer; font: inherit; } .ck-sources-open > svg { font-size: 1rem; } .ck-source-list { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; } .ck-source-row { display: flex; align-items: flex-start; gap: 0.75rem; min-height: var(--ck-target); padding: 0.625rem 0.25rem; border-top: 1px solid var(--ck-line); color: var(--ck-fg); text-decoration: none; } .ck-source-list > li:first-child .ck-source-row { border-top: 0; } .ck-source-row .ck-source-id { margin-top: 0.125rem; } .ck-source-body { display: flex; min-width: 0; flex-direction: column; gap: 0.125rem; } .ck-source-title { font-weight: 500; overflow-wrap: anywhere; } .ck-source-detail { font-size: 0.8125rem; color: var(--ck-fg-2); overflow-wrap: anywhere; } a.ck-source-row:hover .ck-source-title { text-decoration: underline; } @keyframes ck-rise { from { transform: translateY(1.5rem); opacity: 0; } } @media (prefers-reduced-motion: reduce) { .ck-sheet[open] .ck-sheet-panel { animation: none; } }