/* Version 23 presentation layer. Vocabulary, storage and speech behavior stay in app.js. */
:root{color:#142D50;background:#F7FAFF;font-size:18px;--blue:#0754A5;--line:#b9c9de}body{line-height:1.5}header,main,footer{max-width:1280px;padding:22px 28px}a{color:#0754A5;text-underline-offset:4px}button,.import,select,input[type=search]{background:#fff;color:#142D50;border:1px solid #9aabc1;min-height:48px;font-size:1rem}button,.import{border-radius:12px;box-shadow:0 3px 0 #c9d4e3;transition:background .15s,box-shadow .15s}button:hover,.import:hover{background:#edf3fc;border-color:#0754A5}button:active{box-shadow:0 1px 0 #c9d4e3;transform:translateY(1px)}button:focus-visible,a:focus-visible,select:focus-visible,input:focus-visible,summary:focus-visible,.import:focus-within{outline:3px solid #0754A5;outline-offset:4px}button.selected,.primary{background:#0754A5;color:#fff;border-color:#0754A5}button.selected::before{content:'✓ ';font-weight:800}button.selected{font-weight:700}.app-header{border-top:6px solid transparent;border-image:linear-gradient(90deg,#d7970e 0 20%,#1670cb 20% 40%,#d33b3b 40% 60%,#268044 60% 80%,#f0c626 80%) 1;background:#fff;border-radius:0 0 22px 22px;box-shadow:0 5px 20px #193f7110;padding-top:14px;padding-bottom:16px}.header-top,.header-bottom{display:flex;align-items:center;justify-content:space-between;gap:18px}.brand{text-decoration:none;color:#142D50;gap:18px;min-width:0}.brand img{width:138px;height:auto;object-fit:contain}.brand h1{font-size:1.5rem;margin:2px 0;line-height:1.25}.eyebrow{font-size:.68rem;letter-spacing:.09em;font-weight:750;color:#425777}.version{display:inline-block;font-size:.7rem;vertical-align:middle;background:#edf3fc;color:#0754A5;border:1px solid #b9c9de;border-radius:7px;padding:3px 7px}.website-links{display:flex;gap:8px;flex-wrap:wrap}.website-links a{font-size:.8rem;font-weight:650;padding:10px;border-radius:9px}.website-links a:hover{background:#edf3fc}.header-bottom{margin-top:9px}.philosophy p{margin:3px 0;font-size:.84rem;color:#425777}.philosophy .motto{font-size:.9rem;color:#142D50}.language-toolbar{margin:0;gap:10px;flex-wrap:nowrap}.language-toolbar label{font-size:.8rem}.language-toolbar select{font-weight:750;min-width:170px;border:2px solid #0754A5;box-shadow:0 3px 0 #d2def0}html[data-language=vi] .language-toolbar select{border-color:#a22b36;box-shadow:0 3px 0 #f2d2d5}.tag{background:#eef3fa;color:#425777;border-radius:7px;padding:4px 9px;margin-top:10px;font-size:.75rem}.language-note{margin:0 0 16px}.language-note,.voice-settings{background:white;border-color:var(--line);color:#344c6b}.tabs{gap:10px;margin:14px 0}.tabs button{min-width:0;font-weight:650}.modes button{border-width:2px;border-bottom-width:4px;padding:14px 8px;position:relative}.modes [data-mode=Learn]{--ink:#0754A5;--tint:#eaf2ff}.modes [data-mode=Practice]{--ink:#17603c;--tint:#eaf7ef}.modes [data-mode=Recall]{--ink:#a22b36;--tint:#fff0f1}.modes [data-mode=Review]{--ink:#79500b;--tint:#fff3df}.modes [data-mode=Build]{--ink:#695000;--tint:#fff7cc}.modes button{color:var(--ink);background:var(--tint);border-color:var(--ink);box-shadow:0 3px 0 #c9d4e3}.modes button.selected{background:var(--ink);color:white;box-shadow:inset 0 0 0 2px white,0 3px 0 #b6c7de}.playback-settings{gap:14px;margin:20px 0 14px}.playback-settings .speed-control{background:#e9f1fc;border:1px solid #b9c9de;border-radius:13px;padding:14px 18px}.speed-control label{font-size:.88rem;color:#294867}.speed-control input{max-width:none;accent-color:#0754A5;min-height:26px}.voice-settings{margin:14px 0}.layout{grid-template-columns:265px minmax(0,1fr);gap:24px;margin-top:24px}.workspace,aside{min-width:0}aside{background:#fff;border-color:var(--line);border-radius:18px;max-height:760px;padding:17px}aside h2{color:#0754A5;font-size:1.12rem;margin:2px 0 8px}aside p,.group h3{color:#425777;font-size:.82rem}.group h3{font-weight:750;margin-bottom:10px}.word{border-left:5px solid #17603c;margin:9px 0;padding:10px 12px;font-size:1rem;box-shadow:0 2px 0 #e0e7f0}.word:nth-child(4n+2){border-left-color:#a22b36}.word:nth-child(4n+3){border-left-color:#ad7610}.word:nth-child(4n+4){border-left-color:#0754A5}.word small{font-size:.82rem;color:#425777}.word.selected{background:#0754A5;border-color:#0754A5}.word.selected small{color:white}.stats,.foot{color:#425777;font-size:.82rem;gap:12px}.progress{height:7px;background:#dce5f2;border-radius:6px;margin:16px 0 24px;overflow:hidden}.progress div{background:#17603c}.card{background:#fff;border:1px solid #b9c9de;border-top:6px solid #0754A5;border-radius:22px;padding:28px;box-shadow:0 6px 0 #e1e8f2,0 12px 30px #183b6a0c;color:#142D50}.card .category{color:#425777;font-weight:650}.thai{color:#334963;font-size:1.5rem!important;line-height:1.65}.roman{color:#0754A5;font-size:2.65rem!important;font-weight:750;line-height:1.4;overflow-wrap:anywhere}.meaning{font-size:1.3rem;color:#142D50}.example{border-color:#c4d1e2;padding:24px 0}.example h3{font-size:.93rem;font-weight:750;color:#0754A5}.example-thai{font-size:1.2rem;color:#334963}.example-roman{font-size:1.65rem;font-weight:700;color:#0754A5;overflow-wrap:anywhere}.example-english{color:#142D50;font-size:1.1rem}.example .actions{gap:12px;margin:18px 0}.hint,.notice{color:#425777;font-size:.83rem}.states{padding-top:12px;border-top:1px solid #c4d1e2}.states button{font-size:.85rem;flex:1;min-width:140px}.states button.selected{background:#17603c;border-color:#17603c}.answer{background:#edf3fc;color:#142D50}.piece{border:2px solid #0754A5;background:#edf3fc;color:#0754A5}.piece small{color:#344c6b}.counting-practice{border-color:#b9c9de}.counting-practice h3{font-size:1.05rem;color:#0754A5}.counting-grid{gap:10px}.counting-number{max-width:100%;padding:10px 9px}.count-thai{color:#334963}.count-roman{color:#0754A5}.count-numeral{color:#142D50}.foot button{min-width:94px}details{border-color:#c4d1e2}summary{min-height:30px}footer{color:#425777;font-size:.78rem}.voice-settings a{color:#0754A5}#storage-status{font-size:.85rem}select{white-space:normal}.voice-settings select{width:min(100%,500px)}
/* Keep speech timing highlights distinct from all reading surfaces. */
.speaking-word,.speaking-word .count-thai,.speaking-word .count-roman,.speaking-word .count-numeral{color:#173e36!important}.speaking-phrase{background:#fff0bd}.speaking-word{background:#ffe28a!important}
@media(max-width:900px){.header-top{align-items:flex-start}.website-links{flex-direction:column;gap:0}.website-links a{padding:5px 8px}.layout{grid-template-columns:230px minmax(0,1fr);gap:16px}.card{padding:22px}.header-bottom{align-items:flex-start}.language-toolbar{flex-direction:column;gap:3px;align-items:flex-start}.brand h1{font-size:1.25rem}}
@media(max-width:750px){header,main,footer{padding:16px}.layout{grid-template-columns:1fr}.app-header{padding-top:12px}.brand{gap:10px}.brand img{width:100px;height:auto}.eyebrow{font-size:.58rem;letter-spacing:.04em}.brand h1{font-size:1.15rem}.header-top{gap:10px}.website-links a{font-size:.72rem}.header-bottom{gap:12px}.philosophy p{font-size:.76rem}.philosophy .motto{font-size:.8rem}.language-toolbar select{min-width:135px;padding:8px;font-size:.9rem}.language-toolbar label{font-size:.72rem}.tag{font-size:.68rem}aside{max-height:220px}.tabs button{padding:11px 8px;min-width:0}.modes{display:grid;grid-template-columns:repeat(5,minmax(0,1fr))}.modes button{font-size:.85rem;padding:12px 3px}.tabs:not(.modes){display:grid;grid-template-columns:repeat(3,minmax(0,1fr))}.tabs:not(.modes) button{font-size:.85rem}.roman{font-size:2.2rem!important}.card{padding:20px}.playback-settings{margin-top:18px;grid-template-columns:1fr 1fr;gap:10px}.playback-settings .speed-control{padding:12px}.speed-control label{font-size:.78rem}.foot{flex-wrap:wrap}.count-roman,.count-thai{white-space:normal;overflow-wrap:anywhere}}
@media(max-width:480px){.header-top{flex-wrap:wrap}.brand img{width:100px}.website-links{flex-direction:row;justify-content:space-between;width:100%}.website-links a{padding:5px 0;min-height:32px}.header-bottom{flex-direction:column;margin-top:3px;gap:10px}.language-toolbar{width:100%;flex-direction:row;align-items:center;justify-content:space-between}.language-toolbar select{min-width:170px}.philosophy p{font-size:.74rem}.modes{grid-template-columns:repeat(3,minmax(0,1fr))}.modes button{font-size:.9rem}.card{padding:16px;border-radius:16px}.example-roman{font-size:1.45rem}.example-english{font-size:1rem}.actions{gap:10px}.actions button{padding:11px;min-width:0}.states button{min-width:110px}.playback-settings{gap:8px}.speed-control label{font-size:.72rem}.foot span{font-size:.72rem}.foot button{min-width:78px;padding:10px}.card .category{font-size:.78rem}.counting-grid{gap:5px}.counting-number{min-width:61px}.count-roman{font-size:1.15rem}.count-numeral{font-size:1.25rem}.notice{font-size:.78rem}}
@media(prefers-reduced-motion:reduce){button,.spoken-word{transition:none}}

/* Approved double-L branding: original transparent asset, no filters or alteration. */
.brand img{width:64px;height:64px;object-fit:contain}.brand{gap:14px}.app-header{border-image:linear-gradient(90deg,#d7970e 0 38%,#1670cb 38% 85%,#d33b3b 85% 90%,#268044 90% 95%,#f0c626 95%) 1}.version{background:#fff3df;color:#79500b;border-color:#c5932b}
@media(max-width:750px){.brand img{width:54px;height:54px}.brand h1{font-size:1.08rem}}
@media(max-width:480px){.brand img{width:48px;height:48px}.brand{gap:10px}.brand h1{font-size:1rem}.app-header .eyebrow{font-size:.58rem}}

/* Permanent Nomad Speak identity. Supplied artwork is displayed unchanged. */
:root{--adventure-blue:#0754A5;--sunshine-gold:#FFC400;--sunset-orange:#F47721;--norman-red:#E52B32;--midnight-navy:#142D50;--cloud-white:#F7FAFF;--blue:var(--adventure-blue)}
.app-header{border-image:linear-gradient(90deg,#0754A5 0 65%,#FFC400 65% 91%,#F47721 91% 97%,#E52B32 97%) 1}.brand img{width:210px;height:70px;object-fit:contain}.brand-description h1{font-size:1.12rem}.brand-promise{font-size:.78rem!important;color:#142D50!important;margin:2px 0!important}.brand{gap:16px}.modes [data-mode=Learn]{--ink:#0754A5;--tint:#eaf2ff}.modes [data-mode=Practice]{--ink:#142D50;--tint:#edf3fc}.modes [data-mode=Recall]{--ink:#a21c25;--tint:#fff0f1}.modes [data-mode=Review]{--ink:#804000;--tint:#fff1e7}.modes [data-mode=Build]{--ink:#6d5300;--tint:#fff6cc}.card{border-top-color:#0754A5}.version{color:#142D50;background:#FFC400;border-color:#a17b00}.card .category{color:#425777}.website-links a{min-height:44px;display:flex;align-items:center}.language-toolbar select{border-radius:12px}.eyebrow{font-size:.72rem;letter-spacing:.04em}.speed-control label{font-size:.85rem}.motto{font-size:.9rem}.brand-description{min-width:0}select{appearance:none;padding-right:38px;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath d='m4 6 4 4 4-4' fill='none' stroke='%23142D50' stroke-width='2'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 12px center}
@media(max-width:900px){.brand img{width:180px;height:60px}.brand-description h1{font-size:1rem}.eyebrow{font-size:.67rem}.brand-promise{font-size:.72rem!important}}
@media(max-width:750px){.brand img{width:160px;height:54px}.header-top{flex-wrap:wrap}.website-links{flex-direction:row;width:100%;justify-content:space-between}.website-links a{font-size:.8rem;padding:4px 0}.brand-description h1{font-size:.95rem}.brand-promise{font-size:.72rem!important}.header-bottom{margin-top:4px}.eyebrow{font-size:.65rem}.language-toolbar label{font-size:.8rem}}
@media(max-width:480px){header,main,footer{padding:14px}.brand{gap:10px;width:100%}.brand img{width:146px;height:49px;flex-shrink:0}.brand-description h1{font-size:.95rem}.brand-promise{display:none}.eyebrow{font-size:.64rem}.philosophy p{font-size:.8rem}.philosophy .motto{font-size:.83rem}.tag{font-size:.72rem}.speed-control label{font-size:.78rem}.brand-description{flex:1}.version{font-size:.64rem;padding:2px 4px}}
