@charset "UTF-8";
:root {
  color-scheme: light;
  --paper: #f4f5f9;
  --ink: #252b3a;
  --muted: #616b7f;
  --line: #dce2ed;
  --accent: #526a9f;
  --accent-dark: #405786;
  --app-height: 100dvh;
  --app-top: 0px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-synthesis: none;
}
* { box-sizing: border-box; }
html { min-width: 300px; min-height: 100%; }
body { margin: 0; color: var(--ink); background: var(--paper); font-size: 18px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
button, textarea, input { font: inherit; }
button, a, input, textarea { -webkit-tap-highlight-color: transparent; }
button { color: inherit; cursor: pointer; touch-action: manipulation; }
button:disabled { cursor: default; opacity: .45; }
button, a { text-decoration: none; }
button:focus-visible, a:focus-visible, textarea:focus-visible { outline: 3px solid #8398c2; outline-offset: 4px; }
button { border: 0; }
[hidden] { display: none !important; }
.icon { display: block; width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.icon-library, .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.ambient { position: fixed; inset: 0; z-index: -1; pointer-events: none; background: radial-gradient(ellipse at 14% 44%,#d9e7fb88,transparent 50%),radial-gradient(ellipse at 85% 23%,#e6defb77,transparent 45%),radial-gradient(ellipse at 60% 90%,#dceee866,transparent 50%); }
.glass { background: linear-gradient(145deg,#ffffffca,#ffffff75); border: 1px solid #fff; box-shadow: inset 0 1px 1px #fff,0 8px 28px #41486809; backdrop-filter: blur(22px) saturate(130%); -webkit-backdrop-filter: blur(22px) saturate(130%); }
#main-content, .site-footer { width: 100%; max-width: 1220px; margin-inline: auto; padding-inline: 40px; }
.text-link { background: transparent; color: var(--muted); font-size: 14px; padding: 9px 4px; min-height: 44px; }
.text-link:hover { color: var(--accent-dark); }
.conversation-progress { height: 4px; flex-shrink: 0; background: #e6eaf3; overflow: hidden; }
.conversation-progress span { display: block; height: 100%; width: 0; background: linear-gradient(90deg,#93c9ee,#b7a8e8 70%,#dcc2ea); border-radius: 0 5px 5px 0; transition: width .35s ease; }
.recognition-indicator { min-height: 104px; display: flex; align-items: center; justify-content: center; gap: 12px; color: #52658c; font-size: 16px; }
.composer-box.is-transcribing { border-color: #b6bfdf; background: linear-gradient(105deg,#edf5fc,#f1edfb); box-shadow: 0 0 0 3px #a4b9e215; }
.recognition-wave { display: flex; align-items: center; gap: 3px; height: 24px; }
.recognition-wave i { display: block; width: 3px; height: 10px; border-radius: 3px; background: #9ba5d0; animation: recognition-pulse 1.2s ease-in-out infinite; }
.recognition-wave i:nth-child(2), .recognition-wave i:nth-child(4) { height: 17px; animation-delay: .15s; }
.recognition-wave i:nth-child(3) { height: 24px; animation-delay: .3s; }
@keyframes recognition-pulse { 50% { opacity: .45; transform: scaleY(.55); } }
.welcome-view { text-align: center; padding: 70px 0 20px; max-width: 760px; margin: auto; }
.eyebrow { color: #697389; font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; font-weight: 550; }
.welcome-view > .eyebrow { margin: 26px 0 20px; }
h1, h2, p { margin-top: 0; }
.welcome-view h1 { font-size: clamp(42px,5.7vw,68px); font-weight: 600; line-height: 1.08; letter-spacing: -3px; margin: 0 0 24px; }
.welcome-description { color: var(--muted); font-size: 20px; line-height: 1.7; margin: 0; }
.invitation { color: #505d76; font-size: 18px; margin: 21px 0 28px; }
.start-area { border-radius: 28px; padding: 18px 22px 16px; max-width: 440px; margin: 0 auto; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 48px; padding: 13px 22px; border-radius: 24px; font-size: 16px; font-weight: 550; transition: background .2s,box-shadow .2s; }
.button-primary { color: #fff; background: var(--accent); box-shadow: 0 4px 14px #4e659b16; }
.button-primary:hover:not(:disabled) { background: var(--accent-dark); }
.button-secondary, .button-small { color: #405477; background: #e4eaf5; border: 1px solid #d5dff0; }
.start-button { width: 100%; min-height: 56px; font-size: 18px; }
.start-note { color: var(--muted); font-size: 13px; margin: 12px 0 0; }
.site-footer { color: #6d7689; text-align: center; padding-top: 34px; padding-bottom: 24px; font-size: 12px; }
/* Explicit clipping keeps animated, filtered layers round in Safari's compositor. */
.orb { position: relative; display: block; flex-shrink: 0; isolation: isolate; overflow: hidden; border-radius: 50%; -webkit-clip-path: circle(50% at 50% 50%); clip-path: circle(50% at 50% 50%); -webkit-mask-image: -webkit-radial-gradient(white,black); transform: translateZ(0); background: radial-gradient(circle at 30% 20%,#fff 0,#e4eaff 25%,#c9d8fc 65%,#f5e6ff 100%); box-shadow: inset 0 0 14px #fff; border: 1px solid #ffffffb3; }
.orb i { position: absolute; width: 78%; height: 75%; border-radius: 50%; filter: blur(14px); opacity: .68; animation: orb-drift 7s ease-in-out infinite alternate; }
.orb i:nth-child(1) { background: #93c9ee; top: -12%; left: -10%; }
.orb i:nth-child(2) { background: #b7a8e8; right: -18%; top: 13%; animation-delay: -3s; }
.orb i:nth-child(3) { background: #fff3f9; bottom: -30%; left: 8%; animation-delay: -5s; }
.welcome-orb { width: 94px; height: 94px; margin: 0 auto; }
.small-orb { width: 100px; height: 100px; margin: 26px 0 36px; }
@keyframes orb-drift { to { transform: translate(18%,18%) rotate(35deg); } }
.is-thinking .orb i { animation-duration: 2.2s; }
.is-recording .orb i { animation-duration: 1.4s; }
/* The transcript scrolls independently, keeping the answer box inside the visual viewport. */
body.is-chat { position: fixed; top: var(--app-top); left: 0; width: 100%; height: var(--app-height,100dvh); overflow: hidden; display: flex; flex-direction: column; }
.is-chat #main-content { display: flex; flex: 1; min-height: 0; padding-top: 32px; padding-bottom: max(22px,env(safe-area-inset-bottom)); }
.is-chat .site-footer { display: none; }
.conversation-view { display: grid; grid-template-columns: 240px minmax(0,1fr); gap: 48px; flex: 1; min-height: 0; width: 100%; }
.conversation-sidebar { padding-top: 20px; overflow: auto; min-height: 0; }
.conversation-sidebar .eyebrow { font-size: 10px; letter-spacing: 1px; margin-bottom: 15px; }
.conversation-sidebar h1 { font-size: 38px; letter-spacing: -1.5px; font-weight: 550; line-height: 1.16; margin: 0 0 18px; }
.sidebar-description { color: var(--muted); font-size: 15px; line-height: 1.6; }
.conversation-panel { min-width: 0; min-height: 0; display: flex; flex-direction: column; border-radius: 28px; overflow: hidden; }
.conversation-header { display: flex; align-items: center; gap: 12px; padding: 14px 28px; border-bottom: 1px solid #e2e6ef; flex-shrink: 0; }
.conversation-title { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 550; white-space: nowrap; }
.live-dot { width: 6px; height: 6px; background: #809c93; border-radius: 50%; }
.ai-badge { padding: 1px 5px; border: 1px solid #d9dfec; border-radius: 4px; font-size: 10px; color: #69788f; font-weight: 400; }
.conversation-status { color: var(--muted); font-size: 12px; margin-left: auto; }
.thinking-indicator { display: flex; align-items: center; gap: 10px; padding: 0 30px 10px; color: var(--muted); font-size: 13px; flex-shrink: 0; }
.thinking-dots { display: flex; gap: 4px; }
.thinking-dots i { width: 4px; height: 4px; background: #8498b9; border-radius: 50%; animation: dot-pulse 1.2s infinite ease-in-out; }
.thinking-dots i:nth-child(2) { animation-delay: .15s; }
.thinking-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes dot-pulse { 50% { opacity: .3; transform: translateY(-2px); } }
.composer-area { flex-shrink: 0; padding: 14px 22px 17px; border-top: 1px solid #e5e9f0; }
.composer-box { border: 1px solid #d6deed; border-radius: 20px; background: #ffffffb8; padding: 10px 12px 8px; }
.composer-box:focus-within { border-color: #8ea4ca; box-shadow: 0 0 0 2px #90a4ca12; }
.composer-box textarea { width: 100%; display: block; min-height: 56px; max-height: 140px; resize: none; padding: 4px 4px 6px; border: 0; outline: none; border-radius: 4px; background: transparent; font-size: 18px; line-height: 1.5; color: var(--ink); box-shadow: none; }
.composer-box textarea:focus-visible { outline: none; }
.composer-box textarea::placeholder { color: #7b879b; }
.composer-bottom, .composer-left, .composer-right { display: flex; align-items: center; gap: 10px; }
.composer-bottom { justify-content: space-between; }
.composer-left { min-width: 0; }
.composer-hint { color: var(--muted); font-size: 12px; line-height: 1.35; }
.icon-button, .send-button { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; min-width: 44px; padding: 0; border-radius: 50%; background: transparent; }
.voice-button { border: 1px solid #d8e1ef; color: #536c93; background: #eef2f8; }
.send-button { background: var(--accent); color: #fff; }
.send-button:hover:not(:disabled) { background: var(--accent-dark); }
.character-count { color: var(--muted); font-size: 11px; }
.character-count.limit { color: #a14251; }
.composer-footnote { display: flex; gap: 10px; justify-content: space-between; color: var(--muted); font-size: 11px; line-height: 1.45; padding: 9px 4px 0; }
.enter-hint { white-space: nowrap; }
.rating-options { margin: 0 0 12px; }
.rating-options > p { font-size: 14px; color: #4f607b; margin: 0 0 8px; }
.rating-buttons { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 8px; }
.rating-button { min-height: 44px; border: 1px solid #d4dfef; border-radius: 10px; background: #ffffffb3; color: #4c6183; font-size: 18px; }
.rating-button:hover:not(:disabled), .rating-button.selected { background: #dce6f7; border-color: #899fc6; color: #304b79; }
.rating-labels { display: flex; justify-content: space-between; gap: 12px; font-size: 11px; color: var(--muted); margin-top: 5px; }
.recording-panel { min-height: 104px; display: flex; flex-direction: column; justify-content: space-between; gap: 16px; padding: 7px 4px; }
.recording-details { display: flex; align-items: center; gap: 8px; color: #4f5e76; font-size: 15px; }
.recording-dot { width: 7px; height: 7px; border-radius: 50%; background: #bd6672; animation: dot-pulse 1.3s ease-in-out infinite; }
#recording-timer { font-variant-numeric: tabular-nums; margin-left: 3px; }
.waveform { display: flex; gap: 3px; height: 22px; align-items: center; margin-left: auto; }
.waveform i { width: 3px; height: 40%; border-radius: 2px; background: #8d9fc1; animation: wave 1s ease-in-out infinite alternate; }
.waveform i:nth-child(3n) { height: 80%; animation-delay: -.3s; }
.waveform i:nth-child(3n+1) { height: 60%; animation-delay: -.6s; }
@keyframes wave { to { transform: scaleY(.35); } }
.recording-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.button-small { font-size: 14px; min-height: 44px; padding: 10px 14px; }
.completed-panel { min-height: 0; overflow: auto; flex: 1; padding: 50px 28px; text-align: center; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.completed-icon { display: inline-flex; align-items: center; justify-content: center; width: 50px; height: 50px; color: #648078; border-radius: 50%; background: #e7eeeb; margin-bottom: 24px; }
.completed-panel h2 { font-size: 30px; font-weight: 550; line-height: 1.2; letter-spacing: -.8px; margin-bottom: 15px; }
.completed-panel p { font-size: 17px; line-height: 1.6; color: var(--muted); max-width: 420px; margin-bottom: 25px; }
.notice { position: fixed; bottom: max(20px,env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); width: max-content; max-width: min(620px,calc(100% - 24px)); padding: 12px 14px; background: #fff; border: 1px solid #d8e0ed; border-radius: 18px; box-shadow: 0 8px 30px #34446422; display: flex; align-items: center; gap: 14px; z-index: 10; font-size: 14px; }
.notice.error { border-color: #e7ccd1; }
.notice .text-link { color: var(--accent-dark); font-weight: 600; }
.notice .icon-button { flex-shrink: 0; }
.dialog { border: 1px solid #fff; border-radius: 26px; padding: 0; width: min(560px,calc(100% - 28px)); max-height: min(85dvh,760px); color: var(--ink); background: #f8f9fc; box-shadow: 0 20px 80px #26354c33; }
.dialog::backdrop { background: #24304655; backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); }
.dialog h2 { font-size: 24px; font-weight: 550; letter-spacing: -.5px; margin: 0 42px 22px 0; }
.history-dialog { width: min(760px,calc(100% - 28px)); }
.history-dialog[open] { display: flex; flex-direction: column; }
.dialog-heading { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 15px 22px; border-bottom: 1px solid var(--line); flex-shrink: 0; }
.dialog-heading h2 { margin: 0; font-size: 21px; }
.messages { overflow-y: auto; min-height: 0; padding: 24px; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; scrollbar-width: thin; scrollbar-color: #bdc9dd transparent; overflow-anchor: none; }
.chat-messages { flex: 1; padding: 28px 30px; }
.chat-messages:focus-visible { outline: 2px solid #a1b3d2; outline-offset: -3px; }
.chat-messages .message.assistant .message-body { font-size: 21px; line-height: 1.6; letter-spacing: -.15px; }
.message { margin-bottom: 30px; }
.message:last-child { margin-bottom: 0; }
.message-label { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.mini-dot { width: 5px; height: 5px; border-radius: 50%; background: #8da1c6; }
.message-mode { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; }
.message-mode .icon { width: 12px; height: 12px; }
.message-body { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 18px; line-height: 1.65; }
.message-paragraph { margin: 0; }
.message-paragraph + .message-paragraph { margin-top: 20px; }
.message.assistant .message-paragraph:not(:last-child) { color: var(--muted); }
.message.user { margin-left: 10%; background: #eaf0f8; border: 1px solid #dfe7f3; border-radius: 17px 17px 4px 17px; padding: 14px 17px; }
.message.user .message-body { color: #4f6078; }
.demo-banner { padding: 6px 12px; background: #e6ecf6; color: #536884; text-align: center; font-size: 12px; flex-shrink: 0; }
.noscript-note { margin: 30px auto; text-align: center; padding: 20px; }
@media(max-width:1000px) {
  #main-content, .site-footer { padding-inline: 26px; }
  .conversation-view { grid-template-columns: 195px minmax(0,1fr); gap: 26px; }
  .conversation-sidebar h1 { font-size: 33px; }
  .conversation-status { display: none; }
  .conversation-header { padding-inline: 22px; }
}
@media(max-width:760px) {
  .conversation-sidebar { display: none; }
  .conversation-view { display: flex; }
  .conversation-panel { flex: 1; }
}
@media(max-width:600px) {
  #main-content, .site-footer { padding-inline: 20px; }
  .welcome-view { padding-top: 44px; padding-bottom: 4px; }
  .welcome-orb { width: 76px; height: 76px; }
  .welcome-view > .eyebrow { font-size: 10px; letter-spacing: 1px; margin: 24px 0 20px; }
  .welcome-view h1 { font-size: clamp(36px,9.8vw,51px); line-height: 1.1; letter-spacing: -1.9px; margin-bottom: 24px; }
  .welcome-description { font-size: 18px; line-height: 1.65; }
  .desktop-break { display: none; }
  .invitation { font-size: 16px; margin: 21px 0 26px; }
  .start-area { padding: 14px 15px; border-radius: 26px; }
  .start-button { font-size: 17px; min-height: 54px; }
  .start-note { font-size: 12px; }
  .site-footer { font-size: 11px; padding-top: 28px; line-height: 1.7; }
  .is-chat #main-content { padding: max(10px,env(safe-area-inset-top)) 10px max(10px,env(safe-area-inset-bottom)); }
  .conversation-panel { border-radius: 22px; }
  .conversation-header { min-height: 52px; padding: 4px 16px; gap: 7px; }
  .conversation-title { font-size: 14px; gap: 6px; }
  .thinking-indicator { font-size: 12px; padding: 0 20px 9px; }
  .composer-area { padding: 11px 12px 12px; }
  .composer-box { padding: 7px 9px 7px; border-radius: 17px; }
  .composer-box textarea { font-size: 18px; min-height: 54px; max-height: 100px; }
  .composer-hint { font-size: 11px; }
  .composer-footnote { font-size: 10px; padding-top: 7px; }
  .enter-hint { display: none; }
  .rating-options { margin-bottom: 9px; }
  .rating-options > p { font-size: 13px; margin-bottom: 6px; }
  .rating-buttons { gap: 6px; }
  .rating-labels { font-size: 10px; }
  .recording-details { font-size: 13px; }
  .recording-actions .text-link { font-size: 13px; }
  .button-small { font-size: 12px; padding-inline: 10px; gap: 6px; }
  .completed-panel { padding: 30px 23px; }
  .completed-panel h2 { font-size: 27px; }
  .completed-panel p { font-size: 16px; }
  .messages { padding: 20px; }
  .message-body { font-size: 18px; }
  .message-paragraph + .message-paragraph { margin-top: 16px; }
  .chat-messages .message.assistant .message-body { font-size: 19px; line-height: 1.55; }
  .message.user { padding: 12px 14px; margin-left: 7%; }
  .notice { font-size: 13px; padding: 9px 10px; gap: 8px; }
}
/* Preserve the transcript and reply box when the onscreen keyboard is open. */
@media(max-height:650px) and (min-width:761px) {
  .small-orb { display: none; }
  .is-chat #main-content { padding-top: 12px; }
}
@media(max-height:650px) and (max-width:760px) {
  .composer-footnote { display: none; }
  .chat-messages { padding-block: 14px; }
  .composer-area { padding-block: 9px; }
}
@media(max-width:760px) {
  .keyboard-open .composer-footnote { display: none; }
  .keyboard-open .chat-messages { padding-block: 12px; }
  .keyboard-open .chat-messages .message.assistant .message-body { font-size: 18px; line-height: 1.45; }
  .keyboard-open .message-label { font-size: 11px; margin-bottom: 5px; }
  .keyboard-open #main-content { padding-top: 4px; padding-bottom: 4px; }
  .keyboard-open .conversation-header { min-height: 40px; padding-top: 0; padding-bottom: 0; }
  .keyboard-open .composer-area { padding-top: 7px; padding-bottom: 7px; }
  .keyboard-open .composer-box textarea { min-height: 36px; max-height: 58px; padding-top: 2px; padding-bottom: 2px; }
  .keyboard-open .rating-options > p, .keyboard-open .rating-labels { display: none; }
  .keyboard-open .rating-options { margin-bottom: 6px; }
}
@media(max-width:365px) {
  #main-content, .site-footer { padding-inline: 16px; }
  .welcome-view > .eyebrow { font-size: 9px; letter-spacing: .7px; }
  .welcome-view h1 { font-size: 35px; letter-spacing: -1.7px; }
  .welcome-description { font-size: 17px; }
  .chat-messages .message.assistant .message-body { font-size: 18px; }
  .conversation-title { font-size: 13px; }
  .ai-badge { display: none; }
  .composer-hint { font-size: 10px; }
  .recording-details { gap: 5px; font-size: 12px; }
  .waveform { max-width: 50px; overflow: hidden; gap: 2px; }
}
@media(prefers-reduced-motion:reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
