@import url('https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@400;500;600;700&family=Lora:wght@400;500;600&display=swap');
:root{--red:#8e3028;--redlight:#f5e9e4;--ink:#292c29;--muted:#777b71;--line:#e5e4db;--paper:#f7f7f0;--green:#42604c;--gold:#b17838}*{box-sizing:border-box}body{margin:0;color:var(--ink);background:var(--paper);font:14px/1.65 'Be Vietnam Pro',system-ui,sans-serif}button,input,select{font:inherit}button,a{touch-action:manipulation}button{cursor:pointer}button:disabled{cursor:default;opacity:.5}a{color:var(--red)}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,summary:focus-visible{outline:3px solid #b18c48;outline-offset:3px}h1,h2,h3,p{margin:0}h1,h2{font-family:Lora,Georgia,serif;font-weight:500;line-height:1.25}h1{font-size:42px;letter-spacing:-1.3px}h2{font-size:29px}h3{font-size:17px;line-height:1.55}p{color:var(--muted)}.sidebar{position:fixed;inset:0 auto 0 0;width:252px;background:#fdfcf7;border-right:1px solid var(--line);padding:34px 22px;display:flex;flex-direction:column}.brand{display:flex;gap:12px;align-items:center;text-decoration:none;color:var(--ink);font-family:Lora,Georgia,serif;font-size:30px}.brandmark{height:42px;width:40px;background:var(--red);color:#fff7e6;text-align:center;line-height:42px;border-radius:5px 5px 16px 5px;font-size:29px}.brand small{display:block;font:8px/1.7 'Be Vietnam Pro',sans-serif;letter-spacing:1.4px;color:var(--muted)}.navlabel{font-size:10px;letter-spacing:1.8px;color:#989a90;margin:48px 14px 14px}nav{display:grid;gap:7px}.nav{display:flex;align-items:center;gap:12px;border:0;padding:12px 14px;border-radius:6px;background:transparent;color:#6b7066;text-align:left;font-size:18px}.nav span{font-size:12px;flex:1}.nav b{font-size:10px;font-weight:500}.nav:hover{background:#f0f0e8}.nav.active{background:var(--redlight);color:var(--red);font-weight:600}.sidebar-bottom{margin-top:auto;padding:20px 10px 0;border-top:1px solid var(--line);font-size:11px}.sidebar-bottom p{font-size:11px;margin:9px 0}.sidebar-bottom small{font-size:9px;color:#999c92}.dot{display:inline-block;width:6px;height:6px;background:var(--green);border-radius:50%;margin-right:6px}.shell{margin-left:252px}header{height:79px;padding:0 48px;border-bottom:1px solid var(--line);display:flex;justify-content:space-between;align-items:center;background:#fdfcf7;font-size:10px;letter-spacing:1px;color:#898d80}header i{margin:0 15px;color:#c0c2b7}header strong{color:#585d51;font-weight:500;letter-spacing:0}.avatar{width:32px;height:32px;line-height:32px;text-align:center;border:1px solid #d5d6ca;border-radius:50%;font-size:12px;color:var(--green)}main{max-width:1350px;padding:38px 48px 60px;margin:auto}footer{font-size:10px;padding:16px 48px 30px;color:#95988b;max-width:1350px;margin:auto}.eyebrow{font-size:10px;font-weight:600;letter-spacing:2px;color:var(--red);margin-bottom:15px}.hero{display:flex;justify-content:space-between;align-items:center;gap:30px;margin-bottom:30px}.hero p{max-width:480px;font-size:12px;margin-top:16px;line-height:1.9}.hero-art{width:190px;height:155px;position:relative;flex-shrink:0;overflow:hidden}.arch{position:absolute;width:135px;height:170px;border:1px solid #d9cab0;border-radius:75px 75px 0 0;right:5px;top:4px}.arch:after{content:'';position:absolute;inset:13px;border:1px solid #e7dbc5;border-radius:65px 65px 0 0}.book{position:absolute;top:31px;left:30px;height:119px;width:89px;background:var(--red);transform:rotate(-10deg);box-shadow:5px 4px 0 #d7bf9b;border-radius:3px 5px 5px 3px;border-left:8px solid #70271f;color:#f0dcb5;padding:15px 8px;text-align:center;font:16px/1.3 Lora,Georgia,serif}.book small{display:block;font:7px/1.9 sans-serif;letter-spacing:2px;margin-top:10px}.book .star{font-size:21px;display:block;margin-bottom:7px}.stats{display:grid;grid-template-columns:repeat(4,1fr);border:1px solid var(--line);background:#fdfcf7;border-radius:8px;margin-bottom:35px}.stat{padding:20px 24px;position:relative}.stat+.stat:before{content:'';position:absolute;left:0;top:22%;height:56%;width:1px;background:var(--line)}.stat label{display:block;font-size:10px;color:var(--muted);margin-bottom:7px}.stat strong{font:29px/1.2 Lora,Georgia,serif}.stat small{font-size:10px;color:#94978a;margin-left:7px}.sectionhead{display:flex;align-items:center;justify-content:space-between;gap:15px;margin:27px 0 17px}.sectionhead h2{font-size:24px}.sectionhead p{font-size:11px}.target-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}.target{border:1px solid var(--line);border-radius:7px;text-align:left;background:#fdfcf7;padding:19px 21px;position:relative;color:var(--ink)}.target.selected{border:1.5px solid var(--red);background:#faf1e9}.target .check{position:absolute;right:16px;top:18px;width:16px;height:16px;border:1px solid #d4d5c9;border-radius:50%;font-size:10px;text-align:center;line-height:14px}.target.selected .check{background:var(--red);border-color:var(--red);color:white}.target .score{font:29px/1.3 Lora,Georgia,serif;margin-bottom:7px}.target .score small{font:11px sans-serif;color:var(--muted)}.target strong{display:block;font-size:12px;margin-bottom:5px}.target p{font-size:10px;line-height:1.8}.target .count{font-size:10px;margin-top:13px;color:var(--gold)}.micro{font-size:10px;color:var(--muted);margin-top:10px}.chapters{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}.chapter{background:#fdfcf7;border:1px solid var(--line);border-radius:7px;overflow:hidden}.chapter-top{padding:21px 22px 18px;min-height:179px}.chapter .index{font-family:Lora,Georgia,serif;font-size:12px;color:var(--red);display:flex;justify-content:space-between;margin-bottom:13px}.chapter .index span{font:9px/1.8 'Be Vietnam Pro',sans-serif;color:var(--muted)}.chapter h3{font-family:Lora,Georgia,serif;font-size:21px;line-height:1.4;max-width:230px}.chapter .period{font-size:10px;letter-spacing:.8px;margin-top:10px;color:#878d7b}.chapter-bottom{border-top:1px solid var(--line);padding:15px 22px}.meter{height:4px;background:#eaece1;border-radius:4px;margin:8px 0 15px;overflow:hidden}.meter i{height:100%;display:block;background:var(--green);transition:width .2s}.progresslabel{display:flex;justify-content:space-between;font-size:9px;color:var(--muted)}.chapter-bottom button{display:flex;justify-content:space-between;width:100%;padding:0;background:none;border:0;color:var(--red);font-size:11px;font-weight:600}.studybox{margin-top:27px;padding:23px 26px;border:1px solid var(--line);background:#edefe4;border-radius:7px;display:flex;align-items:center;justify-content:space-between;gap:22px}.studybox h3{font-family:Lora,Georgia,serif;font-size:21px}.studybox p{font-size:11px;margin-top:7px}.btn{border:1px solid var(--line);border-radius:5px;padding:10px 16px;background:#fdfcf7;color:var(--ink);font-size:12px;font-weight:500;text-decoration:none;display:inline-flex;align-items:center;justify-content:center;gap:10px}.btn.primary{background:var(--red);color:#fff8ec;border-color:var(--red)}.btn:hover{filter:brightness(.96)}.btn.green{background:var(--green);color:white;border-color:var(--green)}.btn.link{border:0;background:none;color:var(--red);padding:6px 0}.row{display:flex;gap:10px;align-items:center;flex-wrap:wrap}.notice{border:1px solid #e4d4b5;border-radius:6px;background:#fbf4e5;color:#786136;font-size:11px;padding:13px 16px;margin-top:22px;line-height:1.9}.notice a{color:inherit}.pageintro{margin-bottom:25px}.pageintro h1{font-size:35px;margin:8px 0 12px}.pageintro p{font-size:12px}.filters{display:grid;grid-template-columns:1fr 1fr 1fr;gap:13px;padding:20px;background:#fdfcf7;border:1px solid var(--line);border-radius:7px;margin:20px 0}.field label{display:block;font-size:10px;margin-bottom:7px;color:var(--muted)}select,input[type=search]{width:100%;padding:10px 12px;border:1px solid #dddfd3;border-radius:5px;background:#fffef9;color:var(--ink);min-height:42px;font-size:12px}input[type=checkbox]{accent-color:var(--red)}.wide{grid-column:1/-1}.filtercheck{font-size:11px;display:flex;align-items:center;gap:7px}.topics{display:flex;gap:8px;flex-wrap:wrap;margin:16px 0}.chip{background:#fdfcf7;border:1px solid var(--line);border-radius:20px;padding:6px 11px;color:#717866;font-size:10px}.chip.active{background:var(--redlight);border-color:#cba79a;color:var(--red)}.panel{padding:24px;border:1px solid var(--line);background:#fdfcf7;border-radius:7px;margin:18px 0}.panel h3{margin-bottom:8px}.panel p{font-size:12px}.bankitem{background:#fdfcf7;border:1px solid var(--line);border-radius:6px;margin:12px 0;padding:17px 20px}.bankitem summary{cursor:pointer;list-style:none}.bankitem summary::-webkit-details-marker{display:none}.bankitem summary h3{font-size:13px;margin-top:8px;font-weight:500}.bankitem summary:after{content:'Xem đáp án & từ khóa +';font-size:10px;color:var(--red);display:block;margin-top:9px}.bankitem[open] summary:after{content:'Thu gọn −'}.meta{display:flex;align-items:center;gap:8px;flex-wrap:wrap;font-size:9px;color:var(--muted)}.badge{background:#edf0e5;color:var(--green);padding:2px 6px;border-radius:3px;font-size:9px}.badge.amber{background:#f6e9d0;color:#916523}.badge.red{background:var(--redlight);color:var(--red)}.option-list{list-style:none;padding:0;margin:16px 0;font-size:12px}.option-list li{padding:7px 10px;border-radius:4px;margin-bottom:3px}.option-list .correct{background:#e9efe2;color:#37513e}.explanation{padding:15px 17px;border-left:3px solid var(--gold);background:#f6f1e5;border-radius:0 4px 4px 0;font-size:12px;color:#645839;line-height:1.95}.explanation strong{font-size:9px;letter-spacing:1px;display:block;color:#8d753c;margin-bottom:5px}.source{display:block;font-size:10px;margin-top:7px}.bookmark{margin-left:auto;border:1px solid var(--line);background:transparent;border-radius:4px;color:var(--gold);padding:4px 8px;font-size:11px}.empty{padding:60px 20px;text-align:center;border:1px dashed #d8dacd;border-radius:8px;margin-top:20px}.empty h3{font-family:Lora,serif;font-size:24px}.empty p{font-size:12px;margin:12px 0 20px}.quizlayout{display:grid;grid-template-columns:minmax(0,1fr) 220px;gap:22px;margin-top:22px}.quizcard{padding:30px;background:#fffef9;border:1px solid var(--line);border-radius:8px}.quizcard h2{font-family:'Be Vietnam Pro',sans-serif;font-size:20px;font-weight:500;line-height:1.75;margin:22px 0}.options{display:grid;gap:10px}.option{display:flex;align-items:center;gap:13px;width:100%;padding:13px 15px;text-align:left;border:1px solid #dedfd4;border-radius:5px;background:transparent;color:var(--ink);font-size:13px;line-height:1.7}.option b{display:block;flex-shrink:0;width:28px;height:28px;text-align:center;line-height:28px;border:1px solid #dedfd4;border-radius:4px;font-size:11px;font-weight:500}.option.selected{border-color:var(--red);background:var(--redlight)}.option.correct{border-color:#7d9d70;background:#edf3e6}.option.correct b{background:var(--green);color:white;border-color:var(--green)}.option.incorrect{border-color:#c67d6d;background:#f9eae5}.option:disabled{opacity:1}.quiznav{display:flex;justify-content:space-between;gap:10px;margin-top:24px;flex-wrap:wrap}.quizaside{padding:20px;background:#eeefe5;border:1px solid var(--line);border-radius:7px;align-self:start}.quizaside h3{font-size:12px;margin-bottom:15px}.questiongrid{display:grid;grid-template-columns:repeat(5,1fr);gap:5px}.questiongrid button{aspect-ratio:1;min-height:29px;border:1px solid #d9ddcc;border-radius:4px;background:#fdfdf7;font-size:10px;color:var(--muted)}.questiongrid button.answered{background:#dec9bb;color:var(--red);border-color:#d0b6a4}.questiongrid button.good{background:#dbe7ce;color:var(--green);border-color:#c2d3b2}.questiongrid button.bad{background:#f2dcd3;color:var(--red);border-color:#ddbaa9}.questiongrid button.current{outline:2px solid var(--red);outline-offset:1px}.quizaside p{font-size:10px;margin-top:15px}.resultscore{font:60px/1.2 Lora,serif;color:var(--red);margin:15px 0}.resultscore small{font-size:21px;color:var(--muted)}.resultsummary{display:flex;gap:25px;font-size:12px;color:var(--muted);margin:10px 0 22px}.resultcard{padding:35px;border:1px solid var(--line);background:#f9f0e5;border-radius:8px}.resultcard h2{font-size:32px}.guidegrid{display:grid;grid-template-columns:1fr 1fr;gap:15px}.guidegrid .panel{margin:0}.guidegrid ul{padding-left:19px;font-size:12px;color:#6f7466;line-height:2}.timeline{border-left:1px solid #d5c8ac;margin:20px 0 20px 10px;padding-left:24px}.timeline li{list-style:none;position:relative;margin-bottom:17px;font-size:12px}.timeline li:before{content:'';width:7px;height:7px;border-radius:50%;background:var(--red);position:absolute;left:-28px;top:8px}.timeline strong{color:var(--red);margin-right:9px}.pagination{display:flex;align-items:center;justify-content:center;gap:16px;margin-top:23px;font-size:11px}.loading{padding:50px;text-align:center}.separator{height:1px;background:var(--line);margin:24px 0}.resumebox{padding:14px 18px;border:1px solid #bfd0b4;background:#eef3e6;border-radius:6px;display:flex;justify-content:space-between;align-items:center;margin:16px 0;font-size:11px}#toast{position:fixed;bottom:25px;left:50%;transform:translateX(-50%);padding:10px 20px;background:var(--ink);color:#fffef2;border-radius:5px;font-size:12px;display:none;z-index:9}.mobile-only{display:none}@media(min-width:1500px){main{padding-top:48px}.hero{margin-bottom:40px}.hero h1{font-size:48px}.hero-art{margin-right:55px}}@media(max-width:1150px){.sidebar{width:210px;padding:25px 16px}.shell{margin-left:210px}main{padding:30px 28px}.nav{padding:11px 10px}.nav span{font-size:11px}header{padding:0 28px}.chapter-top{padding:17px;min-height:183px}.chapter h3{font-size:19px}.chapter-bottom{padding:13px 17px}.quizlayout{grid-template-columns:1fr}.quizaside{order:2}.questiongrid{grid-template-columns:repeat(10,1fr)}.questiongrid button{aspect-ratio:auto;height:30px}.stat{padding:17px}.hero-art{width:155px}.target{padding:16px}.studybox{align-items:flex-start}}@media(max-width:800px){.sidebar{position:static;width:auto;padding:15px 18px;border-right:0;border-bottom:1px solid var(--line)}.brand{font-size:25px}.brandmark{height:35px;width:34px;line-height:35px;font-size:25px}.brand small{font-size:7px}.navlabel,.sidebar-bottom{display:none}nav{display:flex;overflow-x:auto;margin-top:16px;gap:5px;scrollbar-width:none}.nav{white-space:nowrap;padding:8px 10px;gap:7px;font-size:14px}.nav span{font-size:10px}.nav b{display:none}.shell{margin:0}header{display:none}main{padding:26px 20px 40px}.hero{gap:10px}.hero h1{font-size:35px}.hero p{font-size:11px;margin-top:12px}.hero-art{width:120px;height:130px}.book{left:12px;width:74px;height:105px;top:20px;font-size:13px}.arch{width:100px;height:135px}.book small{font-size:6px}.book .star{font-size:17px}.stats{margin-bottom:25px}.stat{padding:13px 10px}.stat label{font-size:9px}.stat strong{font-size:24px}.stat small{display:block;margin:4px 0 0;font-size:9px}.sectionhead{align-items:flex-start}.sectionhead h2{font-size:23px}.sectionhead p{font-size:10px}.target-grid{gap:8px}.target{padding:13px 11px}.target .score{font-size:27px}.target .check{right:9px;top:11px;width:13px;height:13px;line-height:11px}.target strong{font-size:10px}.target p{font-size:9px}.target .count{font-size:9px}.chapters{grid-template-columns:1fr}.chapter-top{min-height:0;padding:18px 20px}.chapter h3{max-width:100%;font-size:23px}.chapter .index{margin-bottom:7px}.chapter .period{margin-top:6px}.chapter-bottom{padding:12px 20px}.meter{margin-bottom:10px}.studybox{flex-direction:column;padding:20px}.studybox .btn{width:100%}.filters{grid-template-columns:1fr 1fr;padding:15px;gap:10px}.filters .field.topicfield{grid-column:1/-1}.pageintro h1{font-size:30px}.quizcard{padding:20px}.quizcard h2{font-size:17px}.option{font-size:12px;padding:11px 12px}.guidegrid{grid-template-columns:1fr}.sectionhead .btn{font-size:10px}.bankitem{padding:15px}.panel{padding:20px}.resultcard{padding:25px}.questiongrid{grid-template-columns:repeat(8,1fr)}footer{padding:10px 20px 25px;font-size:9px}.resultsummary{gap:16px}.row .btn{flex-grow:1}.hero-art{flex-shrink:0}.resumebox{align-items:flex-start;gap:10px;flex-direction:column}}@media(prefers-reduced-motion:reduce){*{transition:none!important;scroll-behavior:auto!important}}

/* Question hints */
.hint-wrap{margin:14px 0 18px}.hint-button{color:#88612e;border-color:#ddcba6;background:#faf3e3;font-size:11px;padding:8px 13px}.hint-button span{font-size:15px}.hint-button[aria-expanded="true"]{border-color:#bfa16b;background:#f6eacf}.hint-panel{padding:14px 16px;margin-top:10px;border:1px solid #e5d7b9;border-radius:5px;background:#fcf7e9}.hint-panel strong{display:block;font-size:9px;letter-spacing:1px;color:#947642;margin-bottom:6px}.hint-panel p{font-size:12px;line-height:1.95;color:#6b5e3e}.bank-question{font-size:13px;margin-top:10px;font-weight:500}.bank-answer{border-top:1px solid var(--line);padding-top:10px}.bankitem .bank-answer summary{font-size:10px;color:var(--red);padding:3px 0}.bankitem .bank-answer summary:after{content:' +';display:inline;font-size:12px}.bankitem .bank-answer[open] summary:after{content:' −'}.resultsummary{flex-wrap:wrap}

/* Sound and text-to-speech controls */
.media-controls{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0}.media-button{padding:8px 12px;font-size:10px;background:#fdfcf7}.media-button[data-tts]{color:var(--green);border-color:#becab6}.media-button[data-tts][aria-pressed="true"]{color:#fff;background:var(--green);border-color:var(--green)}.media-button[data-sound][aria-pressed="false"]{color:var(--muted);background:#f0f0e9}.media-button:disabled{opacity:.6}.bankitem .media-controls{margin-bottom:12px}.speech-rate{display:flex;align-items:center;gap:8px;min-height:35px;padding:5px 10px;border:1px solid var(--line);border-radius:5px;background:#fdfcf7;color:var(--muted);font-size:10px}.speech-rate input{width:92px;accent-color:var(--green)}.speech-rate output{min-width:30px;color:var(--green);font-weight:600}.key-highlight{padding:1px 3px;border-radius:3px;background:linear-gradient(transparent 18%,#f3df9c 18%,#f3df9c 88%,transparent 88%);color:inherit;font-weight:650;box-decoration-break:clone;-webkit-box-decoration-break:clone}.option .key-highlight{background:linear-gradient(transparent 20%,#e9dbac 20%,#e9dbac 90%,transparent 90%)}@media(max-width:800px){.media-controls{display:grid;grid-template-columns:1fr 1fr}.media-button{width:100%}.speech-rate{grid-column:1/-1;justify-content:center}.speech-rate input{flex:1;max-width:190px}}
