/* Visual adapter only: preserve the existing TTS React tree and all handlers. */
body:has(#root){--tts-primary:#7366f5;--tts-border:#dfd9f5;--tts-soft:#f1edff;padding-bottom:90px}
#root>.min-h-screen{background:transparent;color:var(--text)}
#root header{background:#ffffffb8;border-color:#e6e2f5;box-shadow:none;backdrop-filter:blur(12px)}
#root main{padding-top:28px;padding-bottom:32px;max-width:1000px}
#root :is(.bg-orange-50,.bg-orange-50\/50,.bg-orange-50\/60){background:#f3efff}
#root .bg-orange-100{background:#eae3ff}
#root :is(.bg-orange-500,.bg-orange-600){background:linear-gradient(110deg,#6484ee,#8d68e9);color:#fff}
#root .bg-orange-300{background:#c8b8f6}
#root :is(.text-orange-500,.text-orange-600,.text-orange-700){color:#705ac5}
#root :is(.border-orange-200,.border-orange-300,.border-orange-400){border-color:var(--tts-border)}
#root .border-orange-500{border-color:#8b73df}
#root .border-t-orange-600{border-top-color:#7366f5}
#root .fill-orange-500{fill:#8c6de0}
#root .ring-orange-300{--tw-ring-color:#c7b8f6}
#root .shadow-orange-600\/20,#root .shadow-orange-600\/30{--tw-shadow-color:#8c73df26}
#root .bg-white{background:#ffffffed}
#root .bg-orange-50\/70{background:#f3efffb3}
#root .bg-orange-50\/90{background:#f3efffe6}
#root .bg-orange-50:hover,#root .hover\:bg-orange-50:hover,#root .hover\:bg-orange-100:hover{background:#ece6ff}
#root .hover\:bg-orange-500:hover,#root .active\:bg-orange-700:active{background:linear-gradient(110deg,#5577db,#7e59d5);color:white}
#root .hover\:border-orange-500:hover,#root .focus\:border-orange-500:focus{border-color:#9b84df}
#root button{letter-spacing:normal}
#root button[class*="bg-orange-600"]{color:white}
#root button[class*="p-1.5"],#root button[class*="w-5"],#root button[class*="w-8"]{min-height:36px;min-width:36px}
#root textarea{background:#fff;border-color:#ded8f4;color:#172044;font-size:16px;line-height:1.7}
#root .rounded-2xl{border-radius:22px}
#root footer{border-color:#e6e2f5;color:#687394;background:transparent}
@media(max-width:700px){#root main{padding-left:16px;padding-right:16px;padding-top:20px}#root header{backdrop-filter:none}#root header button{min-height:40px}#root .rounded-xl{border-radius:16px}}
/* The reading task comes first; rewards stay available below recent tasks. */
#root main{display:flex;flex-direction:column;reading-flow:flex-visual}
#root main>div{order:1}
#root main>div:first-child{order:0;text-align:left;margin-bottom:20px}
#root main>div:first-child>p{display:none}
#root main>section{order:2}
#root main>section:first-of-type{order:3;margin-top:24px}
#root main>div[class*="backdrop-blur"]{backdrop-filter:none;box-shadow:0 8px 28px #716eaa0c;background:#ffffffdc}
/* Keep the primary TTS tabs readable and compact on narrow screens. */
@media(max-width:700px){
  #root main .grid-cols-3:has(>button .lucide-volume-2){display:flex;width:100%;max-width:100%;min-width:0;overflow-x:auto}
  #root main .grid-cols-3:has(>button .lucide-volume-2)>button{flex:1 1 0;min-height:44px;min-width:0;padding:8px 2px;font-size:11px;line-height:1.4;white-space:normal}
  #root main .grid-cols-3:has(>button .lucide-volume-2)>button>svg{display:none}
}
