.speech-view{max-width:900px;margin:0 auto;padding:60px 32px}
.speech-heading{margin-bottom:28px}
.speech-heading h1{font-size:30px;line-height:1.35;font-weight:600;letter-spacing:-.025em;margin:0 0 10px}
.speech-heading p{color:var(--muted);line-height:1.7;margin:0;max-width:65ch}
.speech-composer{padding:24px}
.speech-composer>label{display:block;font-size:14px;font-weight:500;margin-bottom:12px}
#speech-text{width:100%;resize:vertical;min-height:180px;border:0;padding:0;line-height:1.8;background:transparent}
.speech-settings{display:flex;gap:16px;flex-wrap:wrap;margin-top:20px}
.speech-settings label{display:flex;flex-direction:column;gap:8px;font-size:12px;color:var(--muted);flex:1;min-width:200px}
.speech-settings select{max-width:100%;width:100%;color:var(--ink);font-size:13px;padding:10px;border:1px solid var(--line);border-radius:8px;background:white}
.speech-submit-row{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-top:24px}
#speech-availability{font-size:13px;line-height:1.6}
.speech-submit-row button{flex-shrink:0}
.speech-result{padding:24px;background:var(--wash);border-radius:12px;margin:24px 0}
.speech-player{display:block;width:100%;margin:20px 0 12px}
.speech-actions{display:flex;gap:12px;flex-wrap:wrap;align-items:center}
.speech-text-heading{font-size:16px;margin:36px 0 14px}
.speech-transcript{white-space:pre-wrap;overflow-wrap:anywhere;max-width:72ch;line-height:1.9;margin:0}
.speech-history-wrap{margin-top:48px}
.speech-history-row{display:flex;align-items:center;gap:16px;width:100%;text-align:left;background:none;border:0;border-bottom:1px solid var(--line);padding:18px 4px;color:inherit}
.speech-history-row:hover{background:var(--wash)}
.speech-history-copy{display:flex;flex-direction:column;gap:6px;min-width:0;flex:1}
.speech-history-copy strong{font-weight:500;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.audio-cover{background:var(--wash);height:140px;aspect-ratio:auto}
.audio-cover>.icon{width:36px;height:36px;color:var(--muted)}
.audio-tile .tile-title{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;white-space:normal}
.speech-view button:focus-visible,.speech-view select:focus-visible{outline:2px solid var(--blue);outline-offset:3px}
@media(max-width:640px){.speech-view{padding:32px 20px}.speech-heading h1{font-size:26px}.speech-composer{padding:20px}.speech-settings{display:grid;grid-template-columns:minmax(0,1fr)}.speech-settings label{min-width:0}.speech-submit-row{align-items:stretch;flex-direction:column}.speech-submit-row .button{justify-content:center}.speech-history-row{gap:10px}.speech-history-row>.icon{display:none}.speech-actions .button{flex:1;justify-content:center}.speech-result{padding:18px}.speech-history-row .badge{font-size:11px}}

/* Keep every library title within two readable lines, including long URLs. */
.tile-info{min-width:0}
.tile-title,.tile-title-text{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;line-clamp:2;line-height:1.65;max-height:3.3em;overflow:hidden;overflow-wrap:anywhere;white-space:normal}
.audio-tile .tile-title{display:block;max-height:none;overflow:visible}
.audio-tile .tile-title-text{width:100%;max-height:3.3em;overflow:hidden}
.speech-progress{display:block;width:100%;height:6px;margin:20px 0 16px;accent-color:var(--blue)}
.speech-phase{font-weight:500;margin:0 0 8px}
.speech-elapsed{font-variant-numeric:tabular-nums;margin:0 0 8px}
.speech-cost{font-size:13px;margin:12px 0 0}
.audio-progress{overflow-wrap:anywhere;margin-top:8px}
@media(prefers-reduced-motion:reduce){.speech-progress{appearance:none}.speech-progress::-webkit-progress-bar{background:var(--line)}.speech-progress::-webkit-progress-value{background:var(--blue)}}
