/* Shared website surfaces. Explicit template tones keep adjacent modules distinct. */
:root{--surface-paper:#ffffff;--surface-sage:#f7f9f5;--surface-sand:#faf3e2;--surface-edge:#dbe4d3}
.site-head{background:#f4f7f1;border-bottom-color:#e4e9df;box-shadow:0 2px 10px #293d2505;backdrop-filter:none}
.site-head .main-nav.open{background:#f4f7f1}.site-head .main-nav>a.active{color:#34563c}

.tone-paper{--band-color:var(--surface-paper)}.tone-sage{--band-color:var(--surface-sage)}.tone-sand{--band-color:var(--surface-sand)}
.page-band[class*="tone-"]{background:var(--band-color);box-shadow:0 0 0 100vmax var(--band-color);clip-path:inset(0 -100vmax);border-top:1px solid #dce4d36b;border-bottom:1px solid #dce4d36b;isolation:isolate}
.page-band.section{margin:0;padding-top:56px;padding-bottom:56px}
.page-band.method-section,.page-band.method-compare{margin:0;padding-top:52px;padding-bottom:52px}
.page-band.context-roadmap{margin:0;border-radius:0;padding-top:52px;padding-bottom:52px}
body[data-page="download"] .download-showcase.page-band{margin-top:26px;padding:32px 0 44px}
.purchase-options.page-band,.test-intro.page-band{padding-top:32px;padding-bottom:40px}
.content-panel{background:var(--band-color);border:1px solid var(--surface-edge);border-radius:20px;padding:28px;margin-bottom:24px}
.content-panel.plan-block>h2{margin-top:0}
.platform-band{border-color:#d5dfcb}



.news-panel{padding:28px;background:var(--surface-sage);border:1px solid var(--surface-edge);border-radius:24px}
.reading>.prose{background:#fff;border:1px solid var(--surface-edge);border-radius:20px;padding:30px}
.reading>.sidebar .card{background:var(--surface-sand)}
.prose blockquote,.article-summary{background:var(--surface-sage)}
.evidence-prose{padding:28px;background:#fff;border:1px solid var(--surface-edge);border-radius:20px}
.evidence-summary{background:var(--surface-sage)}

#main>.wrap>.card.prose{background:var(--surface-sand)}
.account-auth>section{background:#fff;padding:28px;border:1px solid var(--surface-edge);border-radius:24px}
.account-page form[data-redeem-form]{background:var(--surface-sand)}

.test-shell>#guest-assessment{background:#fff;border-color:#cddbc4;box-shadow:0 0 0 12px var(--surface-sage)}
body.vip-page .app-vip .intro-content .section-block{padding:24px 18px;border:1px solid #eee2c4;border-radius:18px;margin-bottom:22px;background:#fff}
body.vip-page .app-vip .intro-content .section-block:nth-child(2n){background:#fff7e4}
@media(max-width:900px){.page-band.section,.page-band.method-section,.page-band.method-compare,.page-band.context-roadmap{padding-top:38px;padding-bottom:38px}}
@media(max-width:600px){.news-panel{padding:18px 14px;border-radius:18px}.content-panel{padding:22px 18px}.reading>.prose,.evidence-prose{padding:22px 18px}.account-auth>section{padding:22px 16px}.account-auth .sms-row{flex-wrap:wrap}.account-auth .sms-row input{min-width:120px}.page-band.section{padding-top:36px;padding-bottom:36px}.page-band.context-roadmap{padding-left:0;padding-right:0}body.vip-page .app-vip .intro-content .section-block{padding:20px 12px}}

/* Compact banners keep their own original background, with breathing room. */
.page-band+.free-start{margin-top:32px}.free-start+.page-band{margin-top:32px}

/* Shared dialog action and verified official contact details. */
#info-dialog .dialog-head{gap:20px;align-items:flex-start}#info-dialog .dialog-head h2{min-width:0}
#info-dialog .info-dialog-close{flex:0 0 36px;width:36px;min-width:36px;max-width:36px;height:36px;padding:8px;display:inline-flex;align-items:center;justify-content:center;border:1px solid #e3e9df;border-radius:50%;background:#f5f7f3;color:#617061;transition:background .18s,color .18s,border-color .18s}
#info-dialog .info-dialog-close svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;pointer-events:none}
#info-dialog .info-dialog-close:hover{background:#eaf0e5;border-color:#c9d6c1;color:#304e38}#info-dialog .info-dialog-close:focus-visible{outline:3px solid #45674e;outline-offset:3px}
/* Footer navigation and a unified contact area on the right. */
.site-footer .footer-grid{grid-template-columns:repeat(3,minmax(130px,1fr)) minmax(370px,1.65fr);gap:32px}
.site-footer .footer-grid>div:first-child{grid-column:auto}
.footer-contact-group{display:flex;justify-content:flex-end;align-items:flex-start;gap:26px}
.footer-contact-details{min-width:0}.footer-grid .footer-contact-details h3{margin-bottom:14px}
.footer-grid .footer-contact-details p{margin:8px 0;max-width:none;font-size:13px}
.footer-grid .footer-contact-details a{display:inline;margin:0;overflow-wrap:anywhere}
.footer-wechat{flex:0 0 112px}.footer-wechat img{display:block;width:112px;height:112px;object-fit:contain;background:#fff;padding:5px;border:1px solid var(--line);border-radius:10px}
.footer-grid .footer-wechat p{margin:10px 0 0;font-size:12px;line-height:1.7}
.footer-contact-details a:hover,.footer-bottom a:hover{text-decoration:underline}
@media(max-width:1000px){.site-footer .footer-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:28px}.footer-contact-group{grid-column:1/-1;padding-top:20px;border-top:1px solid var(--line)}}
@media(max-width:600px){.site-footer .footer-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:28px 20px}.footer-contact-group{justify-content:flex-start;gap:20px;flex-wrap:wrap;padding-right:56px}.footer-bottom{gap:10px;flex-wrap:wrap}}

/* Shared support dock: panels are anchored to each entry, never page sections. */
.support-dock{position:fixed;right:var(--support-right,max(12px,calc((100% - 1200px)/2 - 70px)));bottom:26px;z-index:45;display:flex;flex-direction:column;gap:8px}
.support-item{position:relative}
.support-dock .support-trigger,.support-dock .back-to-top{position:static;display:flex;flex-direction:column;gap:5px;align-items:center;justify-content:center;width:54px;min-width:0;height:62px;padding:7px 0;border:1px solid #dbe3d6;border-radius:14px;background:#fff;color:#45674e;box-shadow:0 4px 18px #263e2812;font-family:inherit;font-size:12px;line-height:1.2;cursor:pointer;transition:background .18s,border-color .18s}
.support-dock .back-to-top[hidden]{display:flex;visibility:hidden;pointer-events:none}
.support-dock svg{width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.support-trigger:hover,.support-trigger[aria-expanded=true],.support-dock .back-to-top:hover{background:#f2f6ee;border-color:#b7c7ae}
.support-dock button:focus-visible,.support-popover a:focus-visible{outline:3px solid #45674e;outline-offset:3px}
.support-popover{position:absolute;right:calc(100% + 12px);bottom:0;width:222px;max-width:calc(100vw - 90px);padding:20px;border:1px solid #e1e7dc;border-radius:18px;background:#fff;color:#27332b;box-shadow:0 10px 36px #263e2824;text-align:center}
.support-popover[hidden]{display:none}.support-popover::after{content:"";position:absolute;left:100%;top:0;width:13px;height:100%}
.support-popover strong{display:block;font-size:16px}.support-popover img{display:block;width:168px;max-width:100%;height:auto;margin:14px auto 0}.support-popover p{font-size:12px;line-height:1.6;color:#74806f;margin:12px 0 0}
.support-phone a{display:block;margin-top:14px;font-size:22px;font-weight:700;letter-spacing:.3px;color:#45674e;white-space:nowrap}
body[data-page=vip] .support-dock,body.vip-page .support-dock{bottom:126px}
@media(max-width:700px){.support-dock{right:12px;bottom:18px;gap:6px}.support-dock .support-trigger,.support-dock .back-to-top{width:46px;height:54px;border-radius:12px;font-size:11px}.support-dock svg{width:21px;height:21px}.support-popover{padding:16px;width:212px;max-width:calc(100vw - 82px)}}

/* Catalog lists: stable row geometry, striped reading rows and clear actions. */
body[data-page="materials"] .table-scroll tbody>tr,
body[data-page="materials"] .layout .book-row:has(>.tag),
.book-entry{transition:background-color .2s ease,box-shadow .2s ease,border-color .2s ease}
body[data-page="materials"] .table-scroll tbody>tr,
body[data-page="materials"] .layout .book-row:has(>.tag){background:#fff}
body[data-page="materials"] .table-scroll tbody>tr:nth-child(even),
body[data-page="materials"] .layout .book-row:has(>.tag):nth-child(even){background:#f6f8f4}
body[data-page="materials"] .layout .book-row:has(>.tag),
.book-entry{padding-left:16px;padding-right:16px;border-radius:10px}
body[data-page="materials"] .layout .book-row:has(>.tag)>span:last-child{
 display:inline-flex;align-items:center;justify-content:center;justify-self:end;min-height:40px;padding:8px 16px;
 border:1px solid #cbd9c6;border-radius:10px;background:#fff;color:#45674e;font-size:13px;font-weight:600;white-space:nowrap;
 transition:background-color .2s ease,color .2s ease,border-color .2s ease,box-shadow .2s ease
}
/* Apply to an actual hovering pointer even on touch-capable computers. */
body[data-page="materials"] .table-scroll tbody>tr:hover,
body[data-page="materials"] .table-scroll tbody>tr:has(:focus-visible){background:#e6efdf;box-shadow:inset 0 0 0 1px #a9c0a0,inset 3px 0 #628368}
body[data-page="materials"] .layout .book-row:has(>.tag):hover,
body[data-page="materials"] .layout .book-row:has(>.tag):focus-visible,
.book-entry:hover,
.book-entry:has(:focus-visible){background:#e6efdf;box-shadow:inset 0 0 0 1px #a9c0a0,0 5px 16px #304b3610;border-bottom-color:#a9c0a0}
body[data-page="materials"] .layout .book-row:has(>.tag):hover>span:last-child,
body[data-page="materials"] .layout .book-row:has(>.tag):focus-visible>span:last-child,
.book-entry:hover>.btn,
.book-entry:has(:focus-visible)>.btn{background:#45674e;color:#fff;border-color:#45674e;box-shadow:0 2px 6px #304b3614}
@media(max-width:600px){
 body[data-page="materials"] .layout .book-row:has(>.tag)>span:last-child{grid-column:2;justify-self:start;font-size:12px;padding:8px 12px}
}
@media(prefers-reduced-motion:reduce){
 body[data-page="materials"] .table-scroll tbody>tr,
 body[data-page="materials"] .layout .book-row:has(>.tag),
 body[data-page="materials"] .layout .book-row:has(>.tag)>span:last-child,
 .book-entry,.book-entry>.btn{transition:none}
}

/* Functional action icons replace decorative text arrows. */
.action-icon{display:inline-block;width:17px;height:17px;min-width:17px;margin-right:7px;vertical-align:-3px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}
.btn>.action-icon{margin-right:0;flex-shrink:0}
a:has(>.action-icon):not(.btn){text-decoration:none}
.book-row>span:last-child>.action-icon{margin-right:7px}
@media(max-width:600px){.action-icon{width:15px;height:15px;min-width:15px;margin-right:5px}}

/* Download choices: highlight the whole card as the pointer enters it. */
.download-options>.download-option{transition:background-color .2s ease,border-color .2s ease,box-shadow .2s ease,transform .2s ease}
.download-options>.download-option .device-mark{transition:background-color .2s ease,transform .2s ease}
.download-options>.download-option:hover,
.download-options>.download-option:has(:focus-visible){background:#edf4e8;border-color:#87a47c;box-shadow:0 12px 28px #304b3624;transform:translateY(-4px)}
.download-options>.download-option:hover .device-mark,
.download-options>.download-option:has(:focus-visible) .device-mark{background:#d4e5c8;transform:scale(1.08)}
@media(prefers-reduced-motion:reduce){
 .download-options>.download-option,.download-options>.download-option .device-mark{transition:none}
 .download-options>.download-option:hover,.download-options>.download-option:has(:focus-visible),
 .download-options>.download-option:hover .device-mark,.download-options>.download-option:has(:focus-visible) .device-mark{transform:none}
}

/* Word audio is requested on click; bilingual examples remain server-rendered. */
.word-heading{display:flex;align-items:center;gap:9px;margin-bottom:4px}
.word-audio{display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;width:32px;height:32px;padding:6px;border:1px solid #d4dfcd;border-radius:50%;background:#f4f8ef;color:#45674e;transition:background .18s,color .18s,border-color .18s}
.word-audio svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.word-audio:hover,.word-audio.is-playing{background:#45674e;color:#fff;border-color:#45674e}
.word-audio.is-loading{background:#e3ecd9;border-style:dashed}
.word-audio.is-playing .sound-waves{animation:word-sound .7s ease-in-out infinite alternate}
.word-example .example-translation{margin-top:7px;color:#737b72;font-size:13px;line-height:1.7;white-space:normal}
.audio-unavailable{white-space:nowrap;font-size:11px}
#word-audio-status{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@keyframes word-sound{from{opacity:.4}to{opacity:1}}
@media(prefers-reduced-motion:reduce){.word-audio{transition:none}.word-audio.is-playing .sound-waves{animation:none}}
