:root { color-scheme: light; font-family: "Avenir Next", Avenir, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: #283731; background: #fff; font-size: 16px; line-height: 1.5; letter-spacing: 0; --green: #245b49; --muted: #69756f; --line: #e6ebe7; }
* { box-sizing: border-box; letter-spacing: 0; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100svh; display: flex; flex-direction: column; }
header, main, footer { width: min(100% - 64px, 1040px); margin-inline: auto; }
header { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: #26392e; text-decoration: none; font-size: 18px; font-weight: 650; }
.brand img { flex: 0 0 28px; }
.tag { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
.preview-dot { width: 6px; height: 6px; border-radius: 50%; background: #dc9964; }
main { flex: 1; padding: 16px 0 28px; }
h1, h2 { margin: 0; }
h1 { font-family: "Trebuchet MS", "Avenir Next", sans-serif; font-size: 42px; line-height: 1.2; font-weight: 700; color: #254735; }
h2 { font-size: 23px; line-height: 1.3; font-weight: 600; }
.toy-stage { display: flex; flex-direction: column; align-items: center; text-align: center; }
.toy-image-wrap { position: relative; width: min(100%, 450px); height: min(38svh, 330px); margin-top: 4px; flex: 0 0 auto; }
.toy-image { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: contain; transition: transform .4s ease; }
body[data-session="signed-out"] .toy-image-wrap { height: min(27svh, 220px); }
.state-row { display: flex; justify-content: center; align-items: center; gap: 9px; min-height: 34px; font-size: 16px; font-weight: 550; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #b9c2bd; flex: 0 0 7px; }
.status-dot[data-active="true"] { background: #3b8a68; }
.status-dot[data-recording="true"] { background: #cf684f; }
.voice-wave { display: none; align-items: center; gap: 3px; height: 22px; margin-left: 3px; }
.voice-wave i { width: 3px; height: 6px; border-radius: 2px; background: #507b63; transform-origin: center; animation: wave .8s ease-in-out infinite alternate; }
.voice-wave i:nth-child(2) { animation-delay: -.4s; }
.voice-wave i:nth-child(3) { animation-delay: -.15s; }
.voice-wave i:nth-child(4) { animation-delay: -.6s; }
.voice-wave i:nth-child(5) { animation-delay: -.3s; }
body[data-mode="listening"] .voice-wave, body[data-mode="speaking"] .voice-wave, body[data-mode="processing"] .voice-wave { display: inline-flex; }
body[data-mode="listening"] .voice-wave i { background: #c26c55; }
body[data-mode="speaking"] .toy-image { animation: sway 2.4s ease-in-out infinite; }
body[data-mode="listening"] .toy-image { transform: translateY(-4px) rotate(-1deg); }
@keyframes wave { to { transform: scaleY(2.7); } }
@keyframes sway { 0%, 100% { transform: translateY(0) rotate(-.6deg); } 50% { transform: translateY(-5px) rotate(.6deg); } }
button, input { font: inherit; }
button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid #c8d4cc; border-radius: 6px; background: #fff; color: var(--green); padding: 10px 16px; min-height: 44px; cursor: pointer; line-height: 1.3; font-size: 14px; font-weight: 600; transition: background .15s, border-color .15s, transform .15s; }
button:hover:not(:disabled) { background: #f0f6f1; border-color: #7eaa8c; }
button:active:not(:disabled) { transform: translateY(1px); }
button:disabled { opacity: .4; cursor: not-allowed; }
.primary { background: var(--green); color: #fff; border-color: var(--green); }
.primary:hover:not(:disabled) { background: #184334; color: #fff; }
.icon { width: 21px; height: 21px; display: block; flex: 0 0 21px; overflow: visible; }
:focus-visible { outline: 3px solid #599b7a; outline-offset: 4px; }
#lab { width: min(100%, 620px); margin-inline: auto; }
.voice-surface { padding-top: 18px; }
.turn-controls { display: grid; grid-template-columns: 48px 92px 48px; align-items: center; justify-content: center; gap: 30px; }
.icon-button { width: 48px; height: 48px; min-height: 48px; padding: 0; border-color: transparent; background: #f2f5f3; }
.talk { flex-direction: column; gap: 5px; width: 92px; height: 92px; min-height: 92px; border-radius: 50%; padding: 12px; background: var(--green); color: #fff; border: 0; box-shadow: 0 5px 0 #dce8df; font-size: 12px; }
.talk .icon { width: 28px; height: 28px; flex-basis: 28px; }
.talk:hover:not(:disabled) { background: #184334; color: #fff; }
.talk.recording, .talk.recording:hover:not(:disabled) { background: #be614c; box-shadow: 0 5px 0 #f0dbd4; }
.level-row { width: 186px; margin: 18px auto 0; display: flex; align-items: center; gap: 12px; height: 20px; }
meter { width: 100%; height: 5px; accent-color: #4e8867; }
meter::-webkit-meter-bar { height: 5px; border: 0; background: #e5ece6; }
meter::-webkit-meter-optimum-value { background: #4e8867; border-radius: 4px; }
#remaining { width: 36px; flex: 0 0 36px; font-size: 11px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.connection-row { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 14px; min-height: 60px; margin-top: 8px; }
.connection-button { min-width: 128px; min-height: 40px; padding: 8px 12px; font-size: 12px; }
.connection-button .icon { width: 16px; height: 16px; flex-basis: 16px; }
#backend { font-size: 11px; color: var(--muted); }
.session-settings { margin-top: 16px; padding: 15px 0 0; border-top: 1px solid var(--line); }
.settings-heading, .identity { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.settings-heading { color: #4c6053; font-size: 12px; font-weight: 600; }
.session-caption { color: var(--muted); font-weight: 400; font-size: 11px; }
.session-caption > span[aria-hidden] { padding: 0 6px; }
.consent { display: flex; align-items: flex-start; gap: 9px; margin-top: 12px; font-size: 12px; line-height: 1.5; color: #5d6c62; }
input[type="checkbox"] { width: 16px; height: 16px; flex: 0 0 16px; margin: 2px 0 0; accent-color: var(--green); }
.identity { margin-top: 10px; font-size: 11px; color: var(--muted); }
#account { overflow-wrap: anywhere; max-width: 100%; }
.quiet-button { min-height: 36px; padding: 5px 0 5px 10px; border: 0; font-size: 11px; color: var(--muted); }
.quiet-button .icon { width: 14px; height: 14px; flex-basis: 14px; }
#login, #setup { width: min(100%, 340px); margin: 18px auto 0; padding-block: 14px 8px; }
#login h2, #setup h2 { margin-bottom: 20px; }
form { display: flex; flex-direction: column; gap: 7px; }
form label { font-size: 12px; font-weight: 600; color: #4c6053; }
form input { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid #c8d4cc; border-radius: 6px; background: #fcfdfc; margin-bottom: 10px; }
#cancel-setup { margin-top: 16px; width: 100%; }
#error { width: min(100%, 620px); margin: 16px auto 0; color: #a13f37; border-left: 3px solid #c27766; padding-left: 12px; font-size: 13px; overflow-wrap: anywhere; }
.sr-only, #status { position: absolute; width: 1px; height: 1px; padding: 0; margin: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
footer { min-height: 56px; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; border-top: 1px solid var(--line); font-size: 11px; color: #7b887e; }
.footer-dot { padding: 0 8px; color: #b5bfb7; }
@media (max-width: 560px) {
  header, main, footer { width: calc(100% - 36px); }
  header { min-height: 64px; gap: 8px; }
  .brand { gap: 7px; font-size: 15px; }
  .brand img { width: 24px; height: 24px; flex-basis: 24px; }
  .tag { gap: 5px; font-size: 10px; }
  main { padding-top: 18px; }
  h1 { font-size: 36px; }
  .toy-image-wrap { height: min(31svh, 250px); width: min(100%, 340px); }
  body[data-session="signed-out"] .toy-image-wrap { height: min(24svh, 190px); }
  .state-row { font-size: 14px; }
  .turn-controls { gap: 24px; }
  .session-settings { margin-top: 12px; }
  .consent { font-size: 11px; }
  .settings-heading { font-size: 11px; }
  .session-caption { font-size: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
