@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700;800&family=Manrope:wght@400;500;600;700;800&display=swap');
.bsa-portal{--gold:#ffbf00;--ink:#101010;--muted:#747474;--line:#ece8df;--paper:#fff;max-width:1120px;margin:0 auto;padding:18px 18px 0;color:var(--ink);font-family:'DM Sans',Arial,sans-serif;line-height:1.55}
.bsa-portal *{box-sizing:border-box}.bsa-header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:8px 0 20px;border-bottom:1px solid var(--line)}.bsa-brand img{display:block;width:min(260px,55vw);height:auto}.bsa-member-pill{font-size:10px;font-weight:800;letter-spacing:1px;background:#fff7df;border:1px solid #f4df9e;padding:8px 11px;border-radius:30px;white-space:nowrap}.bsa-live-dot{display:inline-block;width:7px;height:7px;background:#20a56b;border-radius:50%;margin-right:6px;box-shadow:0 0 0 4px #20a56b1c}
.bsa-hero{position:relative;overflow:hidden;display:grid;grid-template-columns:1.05fr .95fr;align-items:center;min-height:400px;margin:26px 0 38px;padding:40px 46px;background:linear-gradient(120deg,#101010 0%,#1b1b1b 70%,#282115 100%);border-radius:26px;color:white}.bsa-hero:after{content:"";position:absolute;width:330px;height:330px;border:1px solid #ffbf0029;border-radius:50%;right:4%;top:8%;box-shadow:0 0 0 32px #ffbf0008,0 0 0 70px #ffbf0005;pointer-events:none}.bsa-hero-copy{position:relative;z-index:2}.bsa-eyebrow{font-size:10px;letter-spacing:1.8px;font-weight:800;color:#9a8d6b;margin:0 0 9px}.bsa-hero .bsa-eyebrow{color:#ffcf45}.bsa-hero h1{font-family:Manrope,Arial,sans-serif;font-size:clamp(36px,5vw,58px);line-height:1.08;letter-spacing:-2px;margin:0 0 16px;color:white}.bsa-hero h1 em{font-style:normal;color:var(--gold)}.bsa-hero-copy>p:not(.bsa-eyebrow){max-width:430px;color:#d0d0d0;font-size:15px}.bsa-hero-tags{display:flex;gap:9px;flex-wrap:wrap;margin-top:24px}.bsa-hero-tags span{font-size:11px;color:#f5d985;border:1px solid #ffffff26;border-radius:30px;padding:7px 12px}
.bsa-avatar-wrap{position:relative;z-index:2;justify-self:center;width:min(100%,310px);text-align:center;padding:12px}.bsa-avatar-glow{position:absolute;inset:12% 7% 20%;border-radius:50%;background:#ffbf0040;filter:blur(42px);transition:all .5s}.bsa-avatar{position:relative;display:block;width:100%;max-height:320px;object-fit:cover;object-position:center 22%;border:5px solid #ffffff18;border-radius:46% 46% 25px 25px;box-shadow:0 15px 50px #0008;transition:filter .5s,transform .5s}.bsa-avatar-caption{position:relative;display:inline-block;margin-top:-18px;background:var(--gold);color:#171717;font-weight:800;font-size:12px;padding:9px 16px;border-radius:30px;box-shadow:0 5px 20px #0005}.bsa-answer-spark{position:absolute;right:8px;top:25px;color:var(--gold);font-size:34px;opacity:0;transform:scale(.2) rotate(-40deg);transition:.5s}.bsa-avatar-wrap.is-answered .bsa-avatar{filter:saturate(1.18) brightness(1.06);transform:translateY(-5px)}.bsa-avatar-wrap.is-answered .bsa-avatar-glow{background:#ffbf0080;filter:blur(55px)}.bsa-avatar-wrap.is-answered .bsa-answer-spark{opacity:1;transform:scale(1) rotate(0)}.bsa-avatar-wrap.is-answered .bsa-avatar-caption{background:#fff;color:#171717}
.bsa-content{max-width:850px;margin:0 auto}.bsa-section-heading{display:flex;align-items:center;gap:14px;margin:38px 0 17px}.bsa-step{display:grid;place-items:center;flex:0 0 42px;height:42px;border-radius:13px;background:var(--gold);font-weight:800;font-size:13px}.bsa-section-heading .bsa-eyebrow{margin-bottom:2px}.bsa-section-heading h2{font:800 clamp(22px,4vw,28px)/1.2 Manrope,Arial,sans-serif;margin:0;letter-spacing:-.7px}.bsa-panel{background:#fff;border:1px solid var(--line);border-radius:20px;padding:24px;box-shadow:0 10px 35px #17171708}.bsa-muted{color:var(--muted);font-size:13px}.bsa-panel form{display:grid;gap:17px}.bsa-panel label{display:grid;gap:8px;font-size:12px;font-weight:800}.bsa-panel input,.bsa-panel textarea{width:100%;border:1px solid #e5e1d8!important;border-radius:12px!important;padding:14px 15px!important;font:500 14px 'DM Sans',sans-serif!important;color:#171717!important;background:#fff!important;box-shadow:none!important;outline:none}.bsa-panel input:focus,.bsa-panel textarea:focus{border-color:#dca500!important;box-shadow:0 0 0 3px #ffbf0026!important}.bsa-panel textarea{resize:vertical;min-height:120px}.bsa-button{display:inline-flex;align-items:center;justify-content:center;gap:18px;width:max-content;max-width:100%;border:0!important;border-radius:12px!important;background:var(--gold)!important;color:#171717!important;padding:13px 19px!important;font-weight:800!important;font-size:13px!important;text-decoration:none!important;cursor:pointer;transition:transform .2s,box-shadow .2s}.bsa-button:hover{transform:translateY(-2px);box-shadow:0 8px 20px #ffbf0040}.bsa-button:disabled{opacity:.6;cursor:wait}.bsa-form-message{font-size:13px;font-weight:600}.bsa-form-message.success{color:#13824d}.bsa-form-message.error{color:#bd3333}.bsa-verified-panel{display:flex;align-items:center;gap:14px}.bsa-verified-icon{display:grid;place-items:center;width:42px;height:42px;border-radius:50%;background:#e7f7ed;color:#16834d;font-weight:900}.bsa-verified-panel>div:nth-child(2){display:grid;gap:2px}.bsa-verified-panel strong{font-size:16px}.bsa-verified-panel small{color:var(--muted)}.bsa-verified-label{margin-left:auto;color:#16834d;background:#e7f7ed;padding:5px 10px;border-radius:30px;font-size:11px;font-weight:800}.bsa-form-bottom{display:flex;justify-content:space-between;align-items:center;gap:15px}.bsa-form-bottom small{color:var(--muted);font-size:11px}.bsa-answer-list{display:grid;gap:13px}.bsa-answer-card{border:1px solid var(--line);border-radius:17px;padding:20px;background:#fff;animation:bsa-rise .5s both}.bsa-answer-card.is-answered{border-left:4px solid var(--gold)}.bsa-answer-card h3{font-size:14px;margin:8px 0 12px;line-height:1.5}.bsa-answer-card p{font-size:13px;color:#505050;margin:0;white-space:normal}.bsa-answer-card .bsa-answer-text{padding:14px;background:#fff9e8;border-radius:12px;margin-top:10px;color:#262116}.bsa-card-meta{display:flex;align-items:center;gap:8px;flex-wrap:wrap;color:#888;font-size:10px}.bsa-card-status{margin-left:auto;padding:4px 9px;border-radius:30px;font-weight:800;background:#fff2d0;color:#8c6800}.bsa-card-status.answered{background:#e8f7ed;color:#16834d}.bsa-empty,.bsa-loading{padding:22px;border:1px dashed #ddd5c4;border-radius:14px;color:#888;text-align:center;font-size:13px}.bsa-library-intro{margin-top:-5px}.bsa-library-tools{margin:15px 0}.bsa-search{display:flex;align-items:center;gap:9px;border:1px solid var(--line);border-radius:12px;padding:0 13px}.bsa-search span{font-size:22px;color:#a17a00}.bsa-search input{border:0!important;box-shadow:none!important;outline:0!important;width:100%;padding:13px 0!important;font:13px 'DM Sans',sans-serif!important}.bsa-footer{display:flex;align-items:center;justify-content:space-between;gap:15px;border-top:1px solid var(--line);margin-top:55px;padding:22px 0;color:#888;font-size:11px}.bsa-footer img{width:170px;height:auto}.bsa-login-wall{max-width:560px;margin:55px auto 90px;text-align:center;padding:45px 25px;border:1px solid var(--line);border-radius:24px;box-shadow:0 15px 45px #00000008}.bsa-login-icon{font-size:40px}.bsa-login-wall h1{font:800 32px/1.15 Manrope,Arial;margin:10px 0}.bsa-login-wall>p:not(.bsa-eyebrow){color:var(--muted);font-size:14px}.bsa-login-wall .bsa-button{margin:16px auto}.bsa-login-wall small{display:block;color:#999;font-size:11px}
@keyframes bsa-rise{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}.bsa-portal .bsa-section-heading,.bsa-portal .bsa-panel,.bsa-portal .bsa-answer-card{animation:bsa-rise .55s both}
@media(max-width:700px){.bsa-portal{padding:12px 13px 0}.bsa-header{padding-bottom:14px}.bsa-brand img{width:min(205px,53vw)}.bsa-member-pill{font-size:8px;padding:7px 8px;letter-spacing:.7px}.bsa-hero{grid-template-columns:1fr;gap:10px;padding:28px 22px 20px;margin:18px 0 28px;min-height:0;text-align:center;border-radius:20px}.bsa-hero h1{font-size:40px;letter-spacing:-1.5px}.bsa-hero-copy>p:not(.bsa-eyebrow){font-size:13px;margin:0 auto}.bsa-hero-tags{justify-content:center;margin-top:15px}.bsa-avatar-wrap{width:min(72%,240px);padding:5px}.bsa-avatar{max-height:220px}.bsa-hero:after{width:230px;height:230px;right:calc(50% - 115px);top:45%}.bsa-section-heading{margin:29px 0 13px;gap:10px}.bsa-step{flex-basis:36px;height:36px;border-radius:11px}.bsa-section-heading h2{font-size:22px}.bsa-panel{padding:17px;border-radius:16px}.bsa-form-bottom{align-items:stretch;flex-direction:column}.bsa-form-bottom .bsa-button{width:100%}.bsa-verified-panel{gap:10px}.bsa-verified-panel strong{font-size:14px}.bsa-verified-label{font-size:9px}.bsa-answer-card{padding:16px}.bsa-footer{margin-top:38px;flex-direction:column;text-align:center}.bsa-footer img{width:155px}}
@media(prefers-reduced-motion:reduce){.bsa-portal *{animation:none!important;transition:none!important;scroll-behavior:auto!important}}

.bsa-credit-panel{display:flex;align-items:center;justify-content:space-between;gap:15px;margin:18px 0 28px;padding:18px 22px;border:1px solid #f0d98f;border-radius:17px;background:linear-gradient(110deg,#fff8e4,#fffdf7)}.bsa-credit-panel>div:first-child{display:grid;gap:3px}.bsa-credit-panel .bsa-eyebrow{margin:0;color:#927000}.bsa-credit-panel strong{font:800 20px/1.25 Manrope,Arial,sans-serif;color:#171717}.bsa-credit-panel small{font-size:11px;color:#80734f}.bsa-credit-icon{display:grid;place-items:center;width:46px;height:46px;flex:0 0 46px;border-radius:14px;background:#ffbf00;color:#171717;font-size:24px}.bsa-membership-login{display:grid;gap:13px;margin:22px auto 12px;max-width:360px;text-align:left}.bsa-membership-login label{display:grid;gap:7px;font-size:12px;font-weight:800}.bsa-membership-login input{width:100%;padding:14px;border:1px solid #e5e1d8;border-radius:12px;font:14px 'DM Sans',sans-serif}.bsa-membership-login .bsa-button{width:100%}.bsa-login-wall .bsa-membership-login+.bsa-form-message{margin-top:8px}
@media(max-width:700px){.bsa-credit-panel{padding:15px 16px;margin:14px 0 23px}.bsa-credit-panel strong{font-size:17px}.bsa-credit-panel small{font-size:10px}}

/* Version 2.0.1: mobile-first refinements */
.bsa-portal{width:100%;min-width:0;overflow:hidden;padding-left:clamp(12px,3vw,24px);padding-right:clamp(12px,3vw,24px)}
.bsa-portal img{max-width:100%;height:auto}
.bsa-membership-login input,.bsa-panel input,.bsa-panel textarea,.bsa-search input{font-size:16px!important;min-height:48px}
.bsa-membership-login .bsa-button,.bsa-panel .bsa-button{min-height:48px;touch-action:manipulation}
.bsa-login-wall{width:100%;max-width:520px;margin:clamp(24px,7vh,70px) auto;padding:clamp(20px,5vw,42px);background:#fff}
.bsa-login-wall h1{font-size:clamp(27px,7vw,38px);letter-spacing:-1px}
.bsa-login-wall>p:not(.bsa-eyebrow){max-width:360px;margin:0 auto}
.bsa-membership-login{width:100%;max-width:390px}
.bsa-membership-login input{min-height:54px;font-size:16px!important}
.bsa-hero,.bsa-panel,.bsa-credit-panel,.bsa-answer-card{min-width:0;max-width:100%}
.bsa-answer-card{overflow-wrap:anywhere}
.bsa-answer-card .bsa-answer-text{overflow-wrap:anywhere}
.bsa-form-message{line-height:1.5;overflow-wrap:anywhere}
@media(max-width:700px){
 .bsa-portal{padding-top:8px}
 .bsa-header{align-items:center;gap:8px;padding:7px 0 12px}
 .bsa-brand{min-width:0;flex:1}.bsa-brand img{width:min(190px,100%)}
 .bsa-member-pill{font-size:8px;letter-spacing:.35px;padding:6px 8px}
 .bsa-login-wall{margin:22px auto 40px;padding:25px 17px;border-radius:18px}
 .bsa-login-icon{font-size:34px}.bsa-login-wall h1{margin:9px 0 12px}
 .bsa-membership-login{gap:12px;margin:20px auto 10px}
 .bsa-membership-login label{font-size:13px}
 .bsa-membership-login .bsa-button{width:100%;min-height:52px}
 .bsa-hero{padding:25px 16px 18px;margin:15px 0 23px;gap:8px}
 .bsa-hero h1{font-size:clamp(34px,10vw,43px)}
 .bsa-hero-copy>p:not(.bsa-eyebrow){font-size:14px;line-height:1.55}
 .bsa-avatar-wrap{width:min(68%,220px)}
 .bsa-avatar{width:100%;max-height:205px;object-fit:cover}
 .bsa-content{width:100%}
 .bsa-section-heading{align-items:center;margin:25px 0 12px}
 .bsa-section-heading h2{font-size:21px;overflow-wrap:anywhere}
 .bsa-section-heading .bsa-eyebrow{font-size:9px;letter-spacing:1.2px}
 .bsa-panel{padding:15px;border-radius:15px}
 .bsa-panel label{font-size:13px}
 .bsa-panel input,.bsa-panel textarea{padding:13px!important}
 .bsa-panel textarea{min-height:130px}
 .bsa-form-bottom{display:grid;grid-template-columns:1fr;gap:11px}
 .bsa-form-bottom .bsa-button{width:100%;min-height:50px}
 .bsa-credit-panel{padding:14px;margin:12px 0 20px;gap:10px}
 .bsa-credit-panel strong{font-size:17px}
 .bsa-credit-panel .bsa-eyebrow{font-size:9px;letter-spacing:1.1px}
 .bsa-credit-panel small{font-size:10px;line-height:1.4}
 .bsa-credit-icon{width:40px;height:40px;flex-basis:40px}
 .bsa-verified-panel{align-items:flex-start;flex-wrap:wrap}
 .bsa-verified-panel>div:nth-child(2){min-width:0;flex:1}
 .bsa-verified-panel strong{overflow-wrap:anywhere}
 .bsa-verified-label{margin-left:52px}
 .bsa-card-meta{font-size:10px;gap:6px}
 .bsa-card-status{margin-left:0}
 .bsa-answer-card h3{font-size:14px;line-height:1.55}
 .bsa-answer-card p{font-size:13px;line-height:1.6}
 .bsa-search{min-height:48px}
 .bsa-search input{font-size:16px!important;min-height:46px}
 .bsa-footer{padding:18px 0 24px}
}
@media(max-width:360px){.bsa-member-pill{font-size:7px}.bsa-brand img{width:150px}.bsa-hero h1{font-size:32px}.bsa-step{flex-basis:32px;height:32px}}

/* v2.0.2: compact student-only top bar; no academy logo at the top */
.bsa-header-logged-in{justify-content:flex-end;min-height:48px;padding:4px 0 12px;border-bottom:1px solid var(--line)}
.bsa-header-logged-in .bsa-member-pill{margin-right:auto}
.bsa-logout-button{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:42px;padding:9px 15px;border:1px solid #e6dfd0;border-radius:12px;background:#fff;color:#171717;font:700 12px 'DM Sans',Arial,sans-serif;cursor:pointer;transition:background .2s,border-color .2s,transform .2s}
.bsa-logout-button:hover{background:#fff5d9;border-color:#e6bd45;transform:translateY(-1px)}
.bsa-logout-button:disabled{opacity:.6;cursor:wait;transform:none}
@media(max-width:700px){.bsa-header-logged-in{padding:2px 0 10px;min-height:44px}.bsa-logout-button{min-height:40px;padding:8px 13px;font-size:12px}}

/* v2.1.0 conversational doubt desk */
.bsa-google-login-wall{display:flex;flex-direction:column;align-items:center;gap:13px}
.bsa-google-login-wall h1{margin:0;font-size:clamp(28px,5vw,38px)}
.bsa-google-login-wall>p:not(.bsa-eyebrow){margin:0 auto;max-width:390px}
.bsa-google-button{min-height:44px;display:flex;justify-content:center;margin:8px auto}
.bsa-google-login-wall small{line-height:1.6}
.bsa-chat-thread{padding:18px 0;border-bottom:1px solid var(--line);display:grid;gap:12px}
.bsa-chat-date{text-align:center;color:#969696;font-size:10px;font-weight:600}
.bsa-chat-row{display:flex;align-items:flex-end;gap:9px;width:100%}
.bsa-chat-row.student{justify-content:flex-end}
.bsa-chat-row.tutor{justify-content:flex-start}
.bsa-chat-bubble{max-width:min(82%,650px);padding:13px 16px;border-radius:18px;font-size:14px;line-height:1.65;overflow-wrap:anywhere;box-shadow:0 2px 8px #11100008}
.bsa-chat-row.student .bsa-chat-bubble{background:#fff2c8;border:1px solid #f5e2a7;border-bottom-right-radius:5px;color:#252018}
.bsa-chat-row.tutor .bsa-chat-bubble{background:#f5f5f5;border:1px solid #ececec;border-bottom-left-radius:5px;color:#222}
.bsa-chat-author{font-size:10px;font-weight:800;letter-spacing:.3px;margin-bottom:5px;color:#8a6b12}
.bsa-chat-row.tutor .bsa-chat-author{color:#555}
.bsa-chat-author span{color:#16834d}
.bsa-chat-bubble small{display:block;text-align:right;margin-top:7px;color:#999;font-size:9px}
.bsa-chat-avatar{width:30px;height:30px;flex:0 0 30px;border-radius:50%;display:grid;place-items:center;background:#ffbf00;color:#171717;font-size:12px;font-weight:900}
.bsa-chat-pending{font-size:11px;color:#927000;background:#fff9e8;border:1px solid #f2e4b8;border-radius:20px;padding:7px 11px;width:max-content;max-width:100%;margin-left:39px}
.bsa-answer-list{gap:0}
.bsa-answer-card{border-radius:18px}
.bsa-header-logged-in{position:relative}
.bsa-logout-button{margin-left:auto}
.bsa-footer{display:none!important}
@media(max-width:700px){
 .bsa-chat-thread{padding:14px 0;gap:10px}
 .bsa-chat-bubble{max-width:88%;padding:12px 13px;font-size:13px}
 .bsa-chat-pending{margin-left:34px}
 .bsa-login-wall{margin:24px auto}
}
/* v2.3.0 WhatsApp-style student chat dashboard */
.bsa-library-button{display:inline-flex;align-items:center;justify-content:center;min-height:42px;padding:9px 14px;border:1px solid #e8dcae;border-radius:12px;background:#fff9e8;color:#5e4a08;text-decoration:none;font:700 12px 'DM Sans',Arial,sans-serif;white-space:nowrap}
.bsa-library-button:hover{background:#fff0bd;color:#171717}
.bsa-chat-dashboard{max-width:900px;margin:22px auto 34px;border:1px solid #e5e7df;border-radius:20px;overflow:hidden;background:#efeae2;box-shadow:0 12px 35px #1717170b}
.bsa-chat-topbar{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:14px 18px;background:#fff;border-bottom:1px solid #e8e8e4}
.bsa-chat-profile{display:flex;align-items:center;gap:11px;min-width:0}.bsa-chat-profile-icon{width:42px;height:42px;flex:0 0 42px;border-radius:50%;display:grid;place-items:center;background:#ffbf00;color:#171717;font-weight:900;font-size:17px}.bsa-chat-profile>div:last-child{display:grid;gap:3px;min-width:0}.bsa-chat-profile strong{font-size:14px;color:#171717}.bsa-chat-profile small{font-size:10px;color:#777}
.bsa-chat-credit{display:grid;gap:2px;text-align:right;padding:8px 12px;border:1px solid #f0dda0;border-radius:12px;background:#fff9e8;min-width:130px}.bsa-chat-credit span{font-size:9px;text-transform:uppercase;letter-spacing:.7px;color:#856500;font-weight:800}.bsa-chat-credit strong{font-size:15px;color:#171717}.bsa-chat-credit small{font-size:9px;color:#88784d;line-height:1.3}
.bsa-chat-welcome{display:grid;gap:4px;margin:16px auto 4px;padding:10px 15px;width:max-content;max-width:calc(100% - 24px);text-align:center;background:#fff9e8;border:1px solid #f2e8cb;border-radius:12px;color:#655b42}.bsa-chat-welcome strong{font-size:12px}.bsa-chat-welcome span{font-size:10px}
.bsa-chat-dashboard .bsa-answer-section{padding:0 18px;max-height:55vh;overflow-y:auto;overscroll-behavior:contain}.bsa-chat-dashboard .bsa-answer-list{display:grid;gap:0}.bsa-chat-dashboard .bsa-chat-thread:last-child{border-bottom:0}
.bsa-chat-dashboard .bsa-question-section{padding:12px 16px;background:#f7f7f3;border-top:1px solid #e2e3dc}.bsa-chat-composer{display:flex;align-items:flex-end;gap:10px;position:relative}.bsa-chat-composer textarea{flex:1;min-height:48px;max-height:150px;resize:vertical;border:1px solid #e0e1dc!important;border-radius:16px!important;padding:13px 15px!important;background:#fff!important;font:13px 'DM Sans',Arial,sans-serif!important}.bsa-chat-send{width:46px;height:46px;flex:0 0 46px;border:0;border-radius:50%;background:#ffbf00;color:#171717;font-size:20px;font-weight:900;cursor:pointer}.bsa-chat-send:disabled{opacity:.55;cursor:wait}.bsa-chat-composer .bsa-form-message{position:absolute;left:4px;bottom:-21px;font-size:10px}.bsa-chat-hint{margin:7px 0 0 4px;color:#8b8b83;font-size:9px}.bsa-library-section{max-width:900px;margin:34px auto}.bsa-library-section .bsa-section-heading{margin-top:0}
@media(max-width:700px){.bsa-header-logged-in{justify-content:space-between;gap:7px;flex-wrap:wrap}.bsa-library-button,.bsa-logout-button{min-height:38px;padding:7px 10px;font-size:10px}.bsa-chat-dashboard{margin:14px -2px 25px;border-radius:15px}.bsa-chat-topbar{padding:11px;gap:7px}.bsa-chat-profile-icon{width:36px;height:36px;flex-basis:36px}.bsa-chat-profile strong{font-size:12px}.bsa-chat-profile small{font-size:9px}.bsa-chat-credit{min-width:112px;padding:7px 8px}.bsa-chat-credit strong{font-size:13px}.bsa-chat-dashboard .bsa-answer-section{padding:0 10px;max-height:58vh}.bsa-chat-dashboard .bsa-question-section{padding:10px}.bsa-chat-composer textarea{font-size:13px!important}.bsa-chat-send{width:42px;height:42px;flex-basis:42px}.bsa-chat-welcome{margin-top:12px}}


/* v2.4.0: compact chat, media attachments, tutor identity and mobile-first layout */
.bsa-login-avatar{display:block;width:104px;height:104px;object-fit:cover;object-position:center;border-radius:50%;margin:0 auto 14px;border:4px solid #fff0c2;box-shadow:0 8px 28px #00000012}
.bsa-header-logged-in{justify-content:flex-end;flex-wrap:wrap;gap:9px}
.bsa-library-button,.bsa-library-back{display:inline-flex;align-items:center;justify-content:center;min-height:42px;padding:9px 14px;border-radius:12px;background:#fff7df;border:1px solid #f0dda5;color:#171717!important;font-size:12px;font-weight:800;text-decoration:none!important}
.bsa-logout-button{min-height:42px;padding:9px 14px;border:1px solid #e8e2d7;border-radius:12px;background:#fff;color:#333;font-weight:800;cursor:pointer}
.bsa-chat-dashboard{max-width:900px;margin:18px auto 35px;border:1px solid #e9e4da;border-radius:22px;overflow:hidden;background:#f8f5ed;box-shadow:0 12px 36px #11111108}
.bsa-chat-topbar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:15px 18px;background:#fff;border-bottom:1px solid #eee8dd}
.bsa-chat-profile{display:flex;align-items:center;gap:11px;min-width:0}.bsa-chat-profile>div{display:grid;gap:2px;min-width:0}.bsa-chat-profile strong{font-size:14px;overflow-wrap:anywhere}.bsa-chat-profile small{font-size:10px;color:#777}
.bsa-chat-tutor-avatar,.bsa-chat-avatar{width:42px;height:42px;flex:0 0 42px;object-fit:cover;border-radius:50%;border:2px solid #ffedb5;background:#fff}
.bsa-chat-credit{display:grid;gap:2px;text-align:right;max-width:180px}.bsa-chat-credit>span{font-size:10px;color:#777}.bsa-chat-credit strong{font-size:14px;color:#171717}.bsa-chat-credit small{font-size:9px;color:#8a7a53;line-height:1.3}
.bsa-chat-welcome{display:flex;flex-direction:column;gap:2px;padding:12px 18px;background:#fff9e9;border-bottom:1px solid #f0e6cb}.bsa-chat-welcome strong{font-size:13px}.bsa-chat-welcome span{font-size:11px;color:#766b51}
.bsa-answer-section{max-height:min(58vh,620px);min-height:220px;overflow-y:auto;padding:15px 14px;background-color:#f6f1e7;background-image:radial-gradient(#cfc6b3 0.55px,transparent .55px);background-size:16px 16px;scroll-behavior:smooth}
.bsa-answer-section .bsa-answer-list{gap:12px}.bsa-chat-thread{max-width:100%;padding:0 0 9px;border:0;background:transparent;animation:none}.bsa-chat-date{text-align:center;font-size:9px;color:#817a6b;margin:2px 0 8px}
.bsa-chat-row{display:flex;align-items:flex-end;gap:7px;margin:6px 0}.bsa-chat-row.student{justify-content:flex-end}.bsa-chat-row.tutor{justify-content:flex-start}.bsa-chat-bubble{max-width:min(82%,620px);padding:10px 12px;border-radius:14px;box-shadow:0 1px 2px #0000000c;font-size:13px;overflow-wrap:anywhere}.bsa-chat-row.student .bsa-chat-bubble{background:#fff4cf;border:1px solid #f0e2b8;border-bottom-right-radius:4px}.bsa-chat-row.tutor .bsa-chat-bubble{background:#fff;border:1px solid #ece7dd;border-bottom-left-radius:4px}.bsa-chat-author{font-size:10px;font-weight:800;color:#806000;margin-bottom:4px}.bsa-chat-row.tutor .bsa-chat-author{color:#333}.bsa-chat-bubble small{display:block;text-align:right;margin-top:6px;font-size:9px;color:#8b826e}.bsa-message-tick{color:#2897b8;font-weight:900;margin-left:3px}.bsa-chat-pending{width:max-content;max-width:90%;margin:4px 0 10px auto;padding:6px 10px;border-radius:20px;background:#fff;border:1px solid #eee6d5;color:#89784c;font-size:10px}
.bsa-chat-attachment{display:block;margin-top:8px}.bsa-chat-attachment img{display:block;max-width:min(100%,260px);max-height:260px;object-fit:contain;border-radius:9px}.bsa-chat-audio{display:block;width:min(100%,280px);height:38px;margin-top:8px}
.bsa-question-section{padding:12px 14px 10px;background:#fff;border-top:1px solid #e9e4da}.bsa-chat-composer{display:grid;grid-template-columns:1fr;gap:8px}.bsa-chat-composer textarea{width:100%;min-height:66px;max-height:180px;resize:vertical;border:1px solid #e6e0d4!important;border-radius:13px!important;padding:12px 13px!important;background:#fff!important;font:14px 'DM Sans',sans-serif!important;box-shadow:none!important}.bsa-composer-tools{display:flex;align-items:center;gap:8px;min-width:0}.bsa-attach-button{display:inline-flex;align-items:center;justify-content:center;gap:5px;min-height:40px;padding:8px 11px;border-radius:10px;background:#f7f4ed;border:1px solid #e9e2d5;color:#514a3d;font-size:15px;font-weight:800;cursor:pointer}.bsa-attach-button span{font-size:10px}.bsa-attachment-name{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:10px;color:#82765d}.bsa-chat-send{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-width:84px;min-height:42px;padding:9px 15px;border:0;border-radius:11px;background:#ffbf00;color:#171717;font-size:14px;font-weight:900;cursor:pointer}.bsa-chat-send span{font-size:11px}.bsa-chat-send:disabled{opacity:.55;cursor:not-allowed}.bsa-chat-hint{margin:7px 2px 0;color:#8b8578;font-size:10px}.bsa-send-spinner{width:13px;height:13px;border:2px solid #17171755;border-top-color:#171717;border-radius:50%;animation:bsa-spin .7s linear infinite}.bsa-chat-send.is-sending{opacity:.85}.bsa-message-arrive{animation:bsa-chat-in .38s cubic-bezier(.2,.8,.2,1) both}
.bsa-library-page{max-width:900px;margin:20px auto 40px}.bsa-library-page-heading{display:flex;align-items:center;gap:13px;margin:20px 0}.bsa-library-page-heading img{width:58px;height:58px;object-fit:cover;border-radius:50%;border:2px solid #ffedb5}.bsa-library-page-heading h1{margin:0;font:800 clamp(22px,5vw,30px)/1.15 Manrope,Arial,sans-serif}.bsa-library-page-heading p{margin:4px 0 0;color:#777;font-size:12px}.bsa-library-filters{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:16px 0 20px;padding:15px;background:#fff;border:1px solid #eee8dd;border-radius:15px}.bsa-library-filters label{display:grid;gap:6px;font-size:11px;font-weight:800}.bsa-library-filters input{width:100%;min-height:45px;padding:10px 12px;border:1px solid #e7e1d6;border-radius:10px;font:14px 'DM Sans',sans-serif}
@keyframes bsa-spin{to{transform:rotate(360deg)}}@keyframes bsa-chat-in{from{opacity:0;transform:translateY(14px) scale(.985)}to{opacity:1;transform:translateY(0) scale(1)}}
@media(max-width:640px){.bsa-portal{padding-left:8px;padding-right:8px}.bsa-header-logged-in{justify-content:space-between;gap:7px}.bsa-member-pill{margin-right:auto}.bsa-library-button,.bsa-library-back,.bsa-logout-button{min-height:39px;padding:8px 10px;font-size:10px}.bsa-chat-dashboard{margin:10px -1px 22px;border-radius:15px}.bsa-chat-topbar{align-items:flex-start;padding:12px 11px;gap:8px}.bsa-chat-tutor-avatar{width:38px;height:38px;flex-basis:38px}.bsa-chat-profile{gap:8px}.bsa-chat-profile strong{font-size:12px}.bsa-chat-profile small{font-size:9px}.bsa-chat-credit{max-width:130px}.bsa-chat-credit strong{font-size:12px}.bsa-chat-credit small{font-size:8px}.bsa-chat-welcome{padding:10px 12px}.bsa-answer-section{max-height:55vh;min-height:200px;padding:11px 8px}.bsa-chat-bubble{max-width:88%;padding:9px 10px;font-size:12px}.bsa-chat-avatar{width:32px;height:32px;flex-basis:32px}.bsa-question-section{padding:10px 9px 8px}.bsa-chat-composer textarea{min-height:60px;font-size:16px!important}.bsa-attach-button{min-height:39px;padding:7px 9px}.bsa-attach-button span{font-size:9px}.bsa-chat-send{min-width:70px;min-height:40px;padding:8px 10px}.bsa-chat-hint{font-size:9px}.bsa-library-filters{grid-template-columns:1fr;padding:12px;gap:9px}.bsa-library-page{margin:12px auto 28px}.bsa-library-page-heading{margin:12px 0}.bsa-library-page-heading img{width:48px;height:48px}}
@media(prefers-reduced-motion:reduce){.bsa-message-arrive,.bsa-send-spinner{animation:none!important}}
.bsa-attach-button.is-recording{background:#fff0ef;border-color:#e9aaa4;color:#b52d24;animation:bsa-record-pulse 1.2s ease-in-out infinite}@keyframes bsa-record-pulse{50%{box-shadow:0 0 0 5px #e24d3b20}}
/* v2.5.0 media capture, attachment previews and mobile controls */
.bsa-recording-status{display:flex;align-items:center;gap:10px;padding:10px 12px;margin-top:8px;border:1px solid #f0c3be;border-radius:12px;background:#fff5f4;color:#a52d26;font-size:12px}
.bsa-recording-status[hidden],.bsa-media-preview[hidden]{display:none!important}
.bsa-recording-status time{font-variant-numeric:tabular-nums;font-weight:800}
.bsa-recording-status>span:last-child{margin-left:auto;color:#8b625e;font-size:10px}
.bsa-recording-bars{height:22px;display:flex;align-items:center;gap:3px}
.bsa-recording-bars i{display:block;width:3px;height:7px;border-radius:3px;background:#dc493f;animation:bsa-wave .65s ease-in-out infinite alternate}
.bsa-recording-bars i:nth-child(2){animation-delay:.12s}.bsa-recording-bars i:nth-child(3){animation-delay:.24s}.bsa-recording-bars i:nth-child(4){animation-delay:.36s}.bsa-recording-bars i:nth-child(5){animation-delay:.48s}
.bsa-media-preview{display:flex;flex-wrap:wrap;gap:9px;margin-top:9px;padding:9px;border:1px solid #e9e2d5;border-radius:12px;background:#fff}
.bsa-preview-item{position:relative;display:flex;align-items:center;gap:9px;max-width:100%;min-width:0;padding:5px 32px 5px 5px;border-radius:9px;background:#f8f6f1;font-size:11px;color:#514a3d}
.bsa-preview-item>img{width:76px;height:64px;object-fit:cover;border-radius:7px}
.bsa-preview-item>span{max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.bsa-preview-item audio{width:min(300px,55vw);height:36px}
.bsa-preview-item button{position:absolute;right:5px;top:5px;width:23px;height:23px;border:0;border-radius:50%;background:#eadfd4;color:#4b4037;font-size:18px;line-height:1;cursor:pointer}
@keyframes bsa-wave{from{height:5px;opacity:.65}to{height:21px;opacity:1}}
@media(max-width:640px){.bsa-composer-tools{flex-wrap:wrap;gap:6px}.bsa-attachment-name{flex-basis:100%;order:3}.bsa-chat-send{margin-left:auto}.bsa-recording-status{gap:7px;padding:9px;font-size:11px}.bsa-recording-status>span:last-child{font-size:9px}.bsa-preview-item audio{width:calc(100vw - 130px)}}
@media(prefers-reduced-motion:reduce){.bsa-recording-bars i{animation:none!important;height:9px}}
/* v2.6.0 FAQ library and website notifications */
.bsa-library-intro{margin:12px 0;padding:12px 14px;background:#fff9e9;border:1px solid #f0e6cb;border-radius:12px;color:#716342;font-size:12px}
.bsa-faq-item{margin:0 0 10px;border:1px solid #e9e4da;border-radius:13px;background:#fff;overflow:hidden;box-shadow:0 2px 8px #00000006}
.bsa-faq-item>summary{display:grid;gap:5px;position:relative;list-style:none;cursor:pointer;padding:15px 46px 15px 15px;font-size:14px;font-weight:800;color:#26231d}
.bsa-faq-item>summary::-webkit-details-marker{display:none}
.bsa-faq-item>summary:after{content:'＋';position:absolute;right:15px;top:50%;transform:translateY(-50%);width:25px;height:25px;display:grid;place-items:center;border-radius:50%;background:#fff4cf;color:#705400;font-size:17px}
.bsa-faq-item[open]>summary:after{content:'−'}
.bsa-faq-question{line-height:1.45;overflow-wrap:anywhere}.bsa-faq-meta{font-size:10px;font-weight:500;color:#898274}
.bsa-faq-answer{padding:14px 15px 16px;border-top:1px solid #eee8dd;background:#fffdf8;color:#403b32;font-size:13px;line-height:1.65}.bsa-faq-answer>strong{display:block;margin-bottom:7px;color:#806000;font-size:11px;text-transform:uppercase;letter-spacing:.04em}.bsa-faq-answer>small{display:block;margin-top:9px;color:#8b8578;font-size:10px}
.bsa-site-notification{margin:8px 12px 0;padding:10px 13px;border:1px solid #c7e5d0;border-radius:11px;background:#effaf2;color:#176b36;font-size:12px;font-weight:700;opacity:0;transform:translateY(-5px);transition:opacity .2s,transform .2s}
.bsa-site-notification.is-visible{opacity:1;transform:translateY(0)}.bsa-site-notification[hidden]{display:none!important}
@media(max-width:640px){.bsa-faq-item>summary{padding:13px 42px 13px 12px;font-size:13px}.bsa-faq-answer{padding:12px;font-size:12px}}

.bsa-thread-select-label{display:block;font-size:13px;font-weight:700;margin:0 0 6px}.bsa-chat-composer select[name=thread_no]{width:100%;max-width:100%;padding:12px;border:1px solid #ddd;border-radius:10px;margin-bottom:10px;background:#fff}.bsa-membership-login input[name=passcode],.bsa-membership-login input[name=passcode_confirm]{letter-spacing:.35em;font-size:20px;max-width:220px}
