[hidden]{display:none!important}body{min-height:100dvh;font-family:'Noto Sans Bengali Variable','Noto Sans Devanagari',-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif}button,input,select{font:inherit}button{min-height:44px;border:1px solid var(--border);border-radius:10px;background:var(--surface);color:var(--text);padding:9px 14px;cursor:pointer;touch-action:manipulation}button:disabled{opacity:.55;cursor:wait}button:hover:not(:disabled){border-color:var(--teal)}:focus-visible{outline:3px solid var(--teal);outline-offset:3px}.primary{background:var(--teal);border-color:var(--teal);color:var(--bg);font-weight:700}input,select{width:100%;min-height:46px;background:var(--surface-2);color:var(--text);border:1px solid var(--border);border-radius:9px;padding:10px;font-size:16px}label{display:grid;gap:7px;font-size:13px;font-weight:600}form{display:grid;gap:17px}h1,h2,p{margin-top:0}h1{font-size:clamp(26px,3vw,39px);line-height:1.3;letter-spacing:-.8px;margin-bottom:12px}h2{font-size:19px;margin-bottom:0}.muted,small{color:var(--text-dim)}.topbar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px max(16px,env(safe-area-inset-right)) 12px max(16px,env(safe-area-inset-left));padding-top:max(12px,env(safe-area-inset-top));border-bottom:1px solid var(--border);background:var(--topbar-bg)}.brand{display:flex;align-items:center;gap:9px;text-decoration:none;font-weight:750}.brand img{object-fit:contain}.brand small{display:block;font-size:10px;font-weight:500}.topbar nav{display:flex;gap:6px}.topbar nav button{font-size:12px;padding:8px 10px}main{max-width:1120px;margin:auto;padding:24px 20px 40px;min-height:75dvh}.card{border:1px solid var(--border);background:var(--surface);border-radius:var(--radius);padding:22px}.eyebrow{color:var(--teal);font-size:11px;letter-spacing:1.8px;font-weight:750;margin-bottom:13px}.page-intro{display:flex;justify-content:space-between;align-items:center;margin:10px 0 24px}.page-intro p:last-child{color:var(--text-dim);font-size:14px;margin:0}.currency-chip{border:1px solid var(--border);border-radius:30px;padding:8px 16px;font-size:13px;font-weight:700;background:var(--surface)}.period-bar{display:flex;align-items:end;gap:12px;margin-bottom:18px;flex-wrap:wrap}.period-bar label{max-width:210px}#sync-status{font-size:12px;color:var(--text-dim);padding-bottom:10px}.summary-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-bottom:22px}.metric{display:grid;gap:12px;overflow-wrap:anywhere}.metric span{font-size:13px;color:var(--text-dim);display:flex;align-items:center;gap:7px}.metric strong{font-size:clamp(20px,2.4vw,29px);font-variant-numeric:tabular-nums;letter-spacing:-.6px}.metric small{font-size:11px}.metric:first-child strong{color:var(--teal)}.finance-columns{display:grid;grid-template-columns:1.3fr 1fr;gap:20px;margin-bottom:22px;align-items:start}.section-title{display:flex;justify-content:space-between;align-items:center;gap:8px;margin-bottom:20px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}.type-picker{display:flex;gap:6px}.type-picker button{flex:1;padding-inline:7px;font-size:13px}.type-picker button[aria-pressed=true],.auth-tabs button[aria-pressed=true]{background:var(--teal-dim);color:var(--teal);border-color:var(--teal)}.form-actions{display:flex;gap:10px}.form-actions .primary{flex:1}.form-status{font-size:13px;margin:0;min-height:1.5em}.form-status[data-error=true]{color:var(--red)}.account-row{display:flex;gap:12px;justify-content:space-between;align-items:center;padding:16px 0;border-bottom:1px solid var(--border);overflow-wrap:anywhere}.account-row strong{font-variant-numeric:tabular-nums;text-align:right}.accounts-card>p{font-size:12px;line-height:1.7;margin:16px 0 0}.entry-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:15px;padding:17px 0;border-bottom:1px solid var(--border)}.entry-row strong{display:block;overflow-wrap:anywhere}.entry-row small{display:block;margin-top:5px;overflow-wrap:anywhere}.entry-row .row-actions{display:flex;gap:6px;margin-top:9px}.row-actions button{font-size:12px;padding:6px 10px}.amount{font-variant-numeric:tabular-nums;text-align:right;font-weight:700;overflow-wrap:anywhere}.amount[data-kind=income]{color:var(--teal)}.amount[data-kind=expense]{color:var(--red)}.empty{color:var(--text-dim);font-size:14px;padding:22px 0;line-height:1.7}.auth-wrap{display:grid;grid-template-columns:1fr 1fr;gap:60px;align-items:center;max-width:900px;margin:45px auto}.auth-copy>p:not(.eyebrow){color:var(--text-dim);line-height:1.9;max-width:350px}.brand-note{font-size:12px;color:var(--text-dim);margin-top:40px}.auth-tabs{display:flex;gap:8px;margin-bottom:24px}.auth-tabs button{flex:1;font-size:13px}.auth-card form>h2{margin-bottom:6px}.text-button{border:0;background:transparent;min-height:35px;padding:3px;color:var(--text-dim);font-size:13px}.onboarding{max-width:580px;margin:35px auto}.onboarding>p{line-height:1.8}.info{min-width:32px;min-height:32px;border-radius:50%;padding:0;font-size:12px}footer{color:var(--text-dim);text-align:center;font-size:11px;padding:18px 16px max(18px,env(safe-area-inset-bottom))}dialog{border:1px solid var(--border);border-radius:18px;background:var(--surface);color:var(--text);padding:24px;width:min(540px,calc(100% - 28px));max-height:calc(100dvh - 40px);overflow:auto}dialog::backdrop{background:rgba(0,0,0,.48)}dialog>header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:20px}dialog p{line-height:1.85}dialog li{margin-bottom:13px;line-height:1.8}.dialog-actions{display:flex;gap:10px;margin-top:20px}.dialog-actions button{flex:1}.tour-highlight{outline:3px solid var(--teal);outline-offset:6px;scroll-margin-top:20px}#app-status{font-size:13px;color:var(--text-dim);margin-bottom:12px}.skip{position:absolute;top:-80px;left:10px}.skip:focus{top:10px;background:var(--surface);padding:12px;z-index:5}
@media(max-width:720px){main{padding:20px max(16px,env(safe-area-inset-left)) 30px}.finance-columns,.auth-wrap{grid-template-columns:1fr;gap:18px}.auth-wrap{margin:16px auto}.auth-copy h1{font-size:29px}.auth-copy .brand-note{display:none}.summary-grid{gap:8px}.summary-grid .card{padding:13px 10px}.metric{gap:9px}.metric span{font-size:11px}.metric strong{font-size:17px}.metric small{font-size:10px}.page-intro h1{font-size:27px}.card{padding:18px}.topbar{gap:8px}.brand{font-size:14px}.brand img{width:30px;height:30px}.topbar nav{gap:4px}.topbar nav button{padding:7px 8px;min-width:44px}.entry-row{gap:10px}.amount{font-size:13px;max-width:140px}}
@media(max-width:370px){.summary-grid{grid-template-columns:1fr}.metric{grid-template-columns:1fr auto}.metric small{grid-column:1/-1}.form-grid{grid-template-columns:1fr}.brand small{display:none}.page-intro h1{font-size:24px}}
@media(prefers-reduced-motion:no-preference){.page-intro{animation:appear .45s ease-out}.summary-grid .metric{animation:appear .4s ease-out}.summary-grid .metric:nth-child(2){animation-delay:.06s}.summary-grid .metric:nth-child(3){animation-delay:.12s}@keyframes appear{from{opacity:.4;transform:translateY(7px)}to{opacity:1;transform:none}}}
.history-card{margin-bottom:22px}.goal-totals{margin-bottom:16px}.goal-totals .metric{padding:12px 0}.goal-item{padding:22px 0;border-top:1px solid var(--border)}.goal-item h3{font-size:17px;margin:0 0 6px;overflow-wrap:anywhere}.goal-item .section-title{margin-bottom:12px;align-items:start}.goal-item .section-title>div{min-width:0}.goal-item p{margin:12px 0;overflow-wrap:anywhere}.goal-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:18px}.goal-alert{color:var(--red);border:1px solid var(--border);padding:12px;border-radius:10px;font-size:13px;line-height:1.8;overflow-wrap:anywhere}progress{display:block;max-width:100%;width:100%;height:10px;accent-color:var(--teal);border-radius:8px}.account-row>div{min-width:0}#goals-card>.section-title{flex-wrap:wrap}#goals-card>.section-title p{font-size:12px;margin:9px 0 0}
@media(prefers-reduced-motion:no-preference){.goal-item{animation:appear .5s ease-out}}
progress::-webkit-progress-bar{background:var(--surface-2);border-radius:8px}progress::-webkit-progress-value{background:var(--teal);border-radius:8px}progress::-moz-progress-bar{background:var(--teal);border-radius:8px}
#plans-card>.section-title{flex-wrap:wrap}#plans-card>.section-title>.goal-actions{margin-top:0}#plans-count{font-size:12px;margin:9px 0 0}.plan-item{border-top:1px solid var(--border);padding:20px 0}.plan-item h3{font-size:17px;margin:0 0 8px;overflow-wrap:anywhere}.plan-item .section-title{align-items:start;flex-wrap:wrap;margin-bottom:12px}.plan-item .section-title>div{min-width:0;flex:1}.plan-item small{overflow-wrap:anywhere}.plan-item p{margin:12px 0}.plan-status{font-size:13px;color:var(--text-dim)}.plan-status[data-state=overdue],.plan-status[data-state=entry_removed]{color:var(--red)}.plan-status[data-state=recorded],.plan-status[data-state=due_today]{color:var(--teal)}.plan-manager-row{padding:16px 0;border-bottom:1px solid var(--border)}.plan-manager-row strong,.plan-manager-row small{display:block;overflow-wrap:anywhere}.plan-manager-row small{margin-top:8px}
#reports-card>.section-title{flex-wrap:wrap}#reports-period{font-size:12px;margin:8px 0 0}.report-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin:20px 0}.report-metric{border:1px solid var(--border);border-radius:12px;padding:16px;min-width:0;overflow-wrap:anywhere}.report-metric h3{font-size:14px;margin:0 0 14px}.report-metric strong{font-size:20px;display:block;margin-bottom:10px}.report-metric small,.report-category small{display:block;line-height:1.8}.report-metric p,.report-category p{font-size:13px;margin:10px 0;line-height:1.8}.report-category{padding:20px 0;border-bottom:1px solid var(--border);overflow-wrap:anywhere}.report-category h3{font-size:16px;margin:0;min-width:0}.report-category .section-title{flex-wrap:wrap;align-items:start;margin-bottom:14px}.report-category .section-title strong{font-variant-numeric:tabular-nums}.report-category progress{margin-bottom:14px}#reports-body>.type-picker button[aria-pressed=true]{background:var(--teal-dim);color:var(--teal);border-color:var(--teal)}#reports-status{font-size:13px;line-height:1.8}
@media(max-width:720px){.report-grid{grid-template-columns:1fr}.report-metric{display:grid;grid-template-columns:1fr 1fr;gap:8px}.report-metric h3{margin:0}.report-metric strong{font-size:18px;text-align:right;margin:0}.report-metric p,.report-metric small{grid-column:1/-1;margin:0}}

/* Reuse the existing palette and touch targets for local SMS drafts. */
textarea{font:inherit;resize:vertical;width:100%;min-height:120px;background:var(--surface-2);color:var(--text);border:1px solid var(--border);border-radius:9px;padding:10px;font-size:16px;box-sizing:border-box}.entry-tools{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.entry-card>.section-title{flex-wrap:wrap}#sms-panel{display:grid;gap:16px}#sms-panel>p{margin:0;font-size:13px;overflow-wrap:anywhere}#sms-review-form{border-top:1px solid var(--border);padding-top:18px}.sms-check{display:flex;align-items:start;gap:10px;line-height:1.8}.sms-check input{width:22px;min-width:22px;min-height:22px;margin:2px 0}#sms-status{min-height:1.6em}
/* Shared authenticated header and lightweight page transitions. */
[hidden]{display:none!important}.topbar{gap:.7rem;flex-wrap:wrap}.header-page-title{font-size:.95rem}.topbar nav[aria-label="User tools"]{display:flex;align-items:center;gap:.45rem;margin-left:auto}.icon-button{position:relative;width:42px;height:42px;padding:.55rem;display:inline-grid;place-items:center}.icon-button svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}.icon-badge{position:absolute;top:-4px;right:-4px;border-radius:20px;background:var(--teal);color:var(--bg);font-size:.65rem;min-width:18px;padding:1px 4px}.page-navigation{display:flex;gap:.4rem;max-width:100%;padding:.6rem 0;overflow-x:auto;overscroll-behavior-x:contain}.page-navigation button{flex:1;white-space:nowrap;min-height:44px}.page-navigation [aria-current=page]{border-color:var(--teal);box-shadow:inset 0 -3px var(--teal)}.help-tools{display:flex;gap:.6rem;justify-content:center;margin:1rem}.trading-totals{display:grid;grid-template-columns:repeat(auto-fit,minmax(135px,1fr));gap:.7rem}.trade-form-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:.8rem}.journal-trade,.inbox-item{padding:1rem;border:1px solid var(--border);border-radius:14px;margin:.8rem 0;overflow-wrap:anywhere}.journal-trade p,.inbox-item p{white-space:pre-wrap}.inbox-item[data-read=false]{border-left:4px solid var(--teal)}#trade-preview{padding:.8rem;border-radius:10px;background:var(--surface)}main>section:not([hidden]){animation:page-reveal .24s ease-out both}@keyframes page-reveal{from{opacity:.7;transform:translateX(12px)}to{opacity:1;transform:translateX(0)}}@media(prefers-reduced-motion:reduce){main>section:not([hidden]){animation:none}}@media(max-width:540px){.header-page-title{order:3;flex-basis:100%}.trade-form-grid{grid-template-columns:1fr 1fr}.topbar nav[aria-label="User tools"]{gap:.3rem}.page-navigation button{font-size:.8rem;padding:.65rem .45rem}}@media(max-width:360px){.trade-form-grid{grid-template-columns:1fr}}
textarea{font:inherit;width:100%;background:var(--surface-2);color:var(--text);border:1px solid var(--border);border-radius:9px;padding:10px;resize:vertical;font-size:16px}.journal-filters{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));align-items:end;gap:12px;margin:18px 0}#trade-form-card{margin-top:20px}.trading-totals .report-metric{min-width:0;overflow-wrap:anywhere;animation:tile-enter .42s ease-out both}.trading-totals .report-metric:nth-child(even){animation-name:tile-enter-left}@keyframes tile-enter{from{opacity:.65;transform:translateX(12px) scaleX(.97)}to{opacity:1;transform:none}}@keyframes tile-enter-left{from{opacity:.65;transform:translateX(-12px) scaleX(.97)}to{opacity:1;transform:none}}@media(prefers-reduced-motion:reduce){.trading-totals .report-metric{animation:none}}
#page-navigation{padding:.6rem max(16px,env(safe-area-inset-left));margin:auto;max-width:1120px}.trading-totals .report-metric{display:grid;grid-template-columns:minmax(0,1fr);gap:8px}.trading-totals .report-metric strong{text-align:left;grid-column:1;font-size:18px;margin:0;line-height:1.5;overflow-wrap:normal}.trading-totals .report-metric small{grid-column:1}#stats-pairs{margin:14px 0}
.analysis-toolbar{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:18px}#analysis-pair-form{display:flex;align-items:end;gap:10px;margin:20px 0;max-width:470px}#analysis-pair-form label{flex:1;min-width:0}.analysis-pair{margin:20px 0}.analysis-tfs{display:grid;grid-template-columns:repeat(auto-fit,minmax(145px,1fr));gap:12px}.analysis-tf h3{font-size:13px;margin:0 0 8px}.bias-buttons{display:flex;gap:4px;flex-wrap:wrap}.bias-buttons button{padding:8px;font-size:12px;flex:1}.analysis-sessions{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:8px;margin:12px 0 18px}.analysis-sessions button{padding:8px 4px;font-size:12px}.analysis-pair [data-bias=bull][aria-pressed=true],.analysis-sessions [data-bias=bull]{background:var(--teal-dim);color:var(--teal);border-color:var(--teal)}.analysis-pair [data-bias=bear][aria-pressed=true],.analysis-sessions [data-bias=bear]{background:var(--red-dim);color:var(--red);border-color:var(--red)}.analysis-pair [data-bias=neutral][aria-pressed=true],.analysis-sessions [data-bias=neutral]{background:var(--surface-3);color:var(--text);border-color:var(--text-dim);box-shadow:inset 0 -3px var(--text-dim)}.analysis-outcomes{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:14px}.analysis-outcomes [aria-pressed=true]{border-color:var(--teal);background:var(--teal-dim)}.analysis-pair>.section-title+div{margin-bottom:20px}#analysis-status{overflow-wrap:anywhere}@media(max-width:600px){.analysis-sessions{grid-template-columns:repeat(3,minmax(0,1fr))}.analysis-tfs{grid-template-columns:1fr}.analysis-pair .bias-buttons{flex-wrap:nowrap}.analysis-pair .bias-buttons button{font-size:13px}}
#trade-rules{border:1px solid var(--border);border-radius:12px;padding:14px;min-width:0}#trade-rules-list{display:grid;gap:12px}#trade-analysis-status{font-size:12px;color:var(--text-dim);overflow-wrap:anywhere}#trade-rules-list label{overflow-wrap:anywhere}
.analysis-sessions button:active,.bias-buttons button:active{transform:scale(.97)}@media(prefers-reduced-motion:reduce){.analysis-sessions button:active,.bias-buttons button:active{transform:none}}
.settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}.settings-grid>.card{min-width:0}.settings-grid h2{margin-bottom:16px}.settings-grid p{font-size:13px;line-height:1.8;overflow-wrap:anywhere}.settings-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:16px}.settings-actions button{font-size:13px}.setting-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px 0;border-bottom:1px solid var(--border)}.setting-row>div{min-width:0}.setting-row button{flex-shrink:0;font-size:12px}.setting-row p{margin-bottom:0}#settings-status{overflow-wrap:anywhere}@media(max-width:720px){.settings-grid{grid-template-columns:1fr}}@media(max-width:360px){.setting-row{align-items:start;flex-direction:column}}
.settings-grid input[type=checkbox]{accent-color:var(--teal)}

/* Local feature finder: existing palette, no network images or animation. */
.feature-results{list-style:none;padding:0;margin:0;display:grid;gap:9px}.feature-results li{margin:0;min-width:0}.feature-results button{width:100%;display:grid;gap:5px;text-align:left;white-space:normal;overflow-wrap:anywhere}.feature-results small{line-height:1.7;font-weight:400}#feature-search-form{gap:12px}#feature-search-hint,#feature-search-status{margin:0;font-size:13px}.topbar nav[aria-label="User tools"]{flex-shrink:0}
@media(max-width:370px){.topbar .brand{gap:5px;font-size:12px}.topbar nav[aria-label="User tools"]{gap:2px}.topbar nav .icon-button{width:44px;min-width:44px;padding:7px}.topbar{gap:6px;padding-inline:max(10px,env(safe-area-inset-left))}}

.deletion-tools{display:grid;gap:12px;margin:18px 0}#deletion-panel form{margin:20px 0}#deletion-panel p{overflow-wrap:anywhere}#deletion-status{line-height:1.85}

#profile-card,#profile-information{overflow-wrap:anywhere}#profile-card h2{margin-bottom:14px}#profile-card form{margin-top:18px}#profile-status{margin:16px 0 0;font-size:13px}

/* Keep account recovery focused and compact without changing the palette. */
#auth-view[data-recovery=true]{grid-template-columns:minmax(0,1fr);max-width:480px;margin:16px auto}#auth-view[data-recovery=true] .auth-copy{display:none}#auth-view[data-recovery=true] #auth-form{gap:12px}#auth-reset-help{font-size:13px;line-height:1.6;margin:0}#auth-form [aria-invalid=true]{border-color:var(--red)}

/* Restore the established gold accents and page artwork using local SVGs. */
.primary{background:var(--ui-gold);border-color:var(--ui-gold);color:var(--ui-gold-ink)}.card{box-shadow:var(--ui-shadow)}.page-navigation [aria-current=page]{background:var(--ui-gold-soft);color:var(--ui-gold-text);border-color:var(--ui-gold);box-shadow:inset 0 -3px var(--ui-gold)}.page-intro{gap:14px;padding:20px 24px;border:1px solid var(--border);border-radius:20px;background:linear-gradient(120deg,var(--ui-gold-soft),var(--surface) 55%,var(--ui-lilac-soft));overflow:hidden}.page-intro>div{min-width:0;flex:1}.page-intro h1{font-size:clamp(23px,3vw,29px)}.page-intro .eyebrow{color:var(--ui-gold-text)}.ui-art{width:112px;height:88px;flex:none;color:var(--ui-gold)}.ui-art-paper{fill:var(--surface);stroke:var(--border)}.ui-art-line{stroke:var(--text-dim)}.ui-art-accent{stroke:var(--ui-gold);fill:none}.ui-art-orbit{fill:var(--ui-lilac-soft)}.metric{position:relative}.summary-grid>.metric:before{content:"";position:absolute;top:0;left:18px;width:28px;height:3px;background:var(--ui-gold);border-radius:0 0 3px 3px}
@media(max-width:540px){.page-intro{padding:16px;flex-wrap:wrap}.page-intro .ui-art{width:86px;height:70px}.page-intro .currency-chip{margin-left:auto}.page-intro h1{font-size:23px}}
@media(prefers-reduced-motion:no-preference){main>section:not([hidden]) .page-intro{animation:appear .65s ease-out both}.ui-art-bar,.ui-art-float,.ui-art-pop{transform-box:fill-box;transform-origin:center}.ui-art-bar{animation:tb-art-box .85s ease-out both}.ui-art-bar:nth-child(even){--art-from:-9px;animation-delay:.12s}.ui-art-float,.ui-art-pop{animation:tb-art-box 1s ease-out both}.ui-art-draw{stroke-dasharray:1;animation:tb-art-draw 1.2s ease-out both}@keyframes tb-art-box{from{transform:translateX(var(--art-from,9px)) scaleX(.94);opacity:.6}70%{transform:scaleX(1.035)}to{transform:none;opacity:1}}@keyframes tb-art-draw{from{stroke-dashoffset:1}to{stroke-dashoffset:0}}}

#finance-view>.page-intro{position:relative}#finance-view>.page-intro .currency-chip{position:absolute;top:12px;right:16px;font-size:11px;padding:3px 8px}#finance-view>.page-intro .ui-art{margin-top:24px}
/* Shared secondary surfaces: existing tokens, no new theme colours. */
#dialog-body:has(#user-admin-access){display:flex;flex-wrap:wrap;gap:10px}
#dialog-body:has(#user-admin-access)>p,#dialog-body:has(#user-admin-access)>div{flex-basis:100%;margin:0 0 6px}
#dialog-body:has(#user-admin-access)>button{flex:1 1 calc(50% - 10px);min-width:0;margin:0;padding:13px;text-align:left;background:var(--surface-2);overflow-wrap:anywhere}
#app-dialog{box-shadow:var(--ui-shadow);border-radius:22px;padding:24px}
#app-dialog>header{padding-bottom:16px;border-bottom:1px solid var(--border);margin-bottom:20px}
#app-dialog>header h2{font-size:20px;line-height:1.45;overflow-wrap:anywhere}
#dialog-close{flex:none;width:42px;height:42px;min-height:42px;border-radius:50%;padding:0;background:var(--surface-2)}
#dialog-body>button{margin:4px 6px 4px 0}
#dialog-body>form{padding:18px;border:1px solid var(--border);border-radius:16px;background:var(--surface-2)}
#app-dialog input:focus,#app-dialog textarea:focus,#app-dialog select:focus{border-color:var(--ui-control-border)}
#subscription-status-card,#admin-access-card{border-top:3px solid var(--ui-gold)}
@media(max-width:540px){#app-dialog{padding:18px}#app-dialog>header h2{font-size:18px}#dialog-body>form{padding:15px}}
@media(prefers-reduced-motion:no-preference){#app-dialog[open]{animation:tb-dialog-enter .32s cubic-bezier(.16,.75,.25,1) both}#app-dialog::backdrop{animation:tb-backdrop-enter .24s ease-out both}#app-dialog button,#app-dialog a{transition:transform .16s ease-out,border-color .16s ease-out,background-color .16s ease-out}#app-dialog button:active:not(:disabled),#app-dialog a:active{transform:scale(.98)}.settings-grid>.card,.finance-columns>.card{animation:tb-box-enter .55s ease-out both}.settings-grid>.card:nth-child(even),.finance-columns>.card:nth-child(even){animation-name:tb-box-enter-left;animation-delay:.08s}@keyframes tb-dialog-enter{from{opacity:.25;transform:translateY(12px) scale(.985)}to{opacity:1;transform:none}}@keyframes tb-backdrop-enter{from{opacity:0}to{opacity:1}}@keyframes tb-box-enter{from{opacity:.55;transform:translateX(8px) scaleX(.98)}to{opacity:1;transform:none}}@keyframes tb-box-enter-left{from{opacity:.55;transform:translateX(-8px) scaleX(.98)}to{opacity:1;transform:none}}}

/* Password visibility stays inside its own field without changing the theme. */
.password-field{display:grid;gap:7px}.password-input{position:relative}.password-input input{padding-inline-end:56px}
#auth-form .password-eye{position:absolute;inset-inline-end:2px;top:50%;transform:translateY(-50%);width:44px;height:44px;min-height:44px;padding:0;display:grid;place-items:center;border:0;background:transparent;color:var(--text-dim);border-radius:8px}
#auth-form .password-eye:hover:not(:disabled){color:var(--teal)}.password-eye svg{width:22px;height:22px;pointer-events:none}
.password-eye .password-eye-closed,.password-eye[aria-pressed=true] .password-eye-open{display:none}.password-eye[aria-pressed=true] .password-eye-closed{display:block}
#auth-form input::-ms-reveal{display:none}

/* Public placeholder only: no saved account or financial data is cached. */
body[data-starting="true"] .help-tools,body[data-starting="true"] .official-follow,body[data-starting="true"] .public-extras{visibility:hidden}
.startup-shell{max-width:42rem;margin:2rem auto;padding:2rem;text-align:center}.startup-shell>img{object-fit:contain}.startup-lines{display:grid;gap:.75rem;margin:1.5rem auto;max-width:28rem}.startup-lines span{height:1rem;border-radius:1rem;background:currentColor;opacity:.08;animation:startup-pulse 1.4s ease-in-out infinite alternate}.startup-lines span:nth-child(2){width:85%;animation-delay:.15s}.startup-lines span:nth-child(3){width:65%;animation-delay:.3s}@keyframes startup-pulse{to{opacity:.16}}@media(prefers-reduced-motion:reduce){.startup-lines span{animation:none}}
[aria-busy="true"][inert]{opacity:.65}

/* Navigation decoration stays in the existing single-row tab layout. */
#page-navigation button{display:inline-flex;flex-direction:row;align-items:center;justify-content:center;gap:6px}#page-navigation button>svg{width:18px;height:18px;flex:none}@media(max-width:540px){#page-navigation button>svg{width:16px;height:16px}}

/* Native vertical scrolling; horizontal page gestures are handled in navigation. */
main>section:not(#auth-view):not(#startup-shell){touch-action:pan-y pinch-zoom}.auth-guide-video{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:8px 14px;margin:10px 0 16px;border:1px solid var(--border);border-radius:10px;background:var(--surface);color:var(--text);text-decoration:none}.auth-guide-video svg{width:22px;height:22px;fill:#d93025;flex:none}

#auth-view:not([hidden])~#public-extras .public-guide-video,body[data-starting] .public-guide-video{display:none}

.feedback-stars{display:flex;gap:8px;flex-wrap:wrap;border:0;padding:0;margin:12px 0}.feedback-stars legend{margin-bottom:8px}.feedback-stars label{position:relative;display:grid;place-items:center;width:44px;height:44px;cursor:pointer;border:1px solid var(--border);border-radius:10px}.feedback-stars input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}.feedback-stars svg{width:26px;height:26px;fill:none;stroke:var(--text-dim);stroke-width:1.5;pointer-events:none}.feedback-stars [data-active=true] svg{fill:var(--ui-gold);stroke:var(--ui-gold-text)}.feedback-stars label:focus-within{outline:2px solid var(--text);outline-offset:3px}#feedback-form textarea{width:100%;box-sizing:border-box;resize:vertical}
/* Community shares the established palette, cards and reduced-motion rules. */
.community-post{margin-block:14px;padding:18px;overflow-wrap:anywhere}.community-post-head{display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap}.community-text{white-space:pre-wrap;overflow-wrap:anywhere}.community-preview{display:block;max-width:100%;max-height:480px;object-fit:contain;border-radius:14px;margin-block:12px}.community-actions{display:flex;gap:8px;flex-wrap:wrap}.community-actions button{min-height:44px;min-width:44px}.community-actions button[aria-pressed=true]{outline:2px solid var(--ui-gold-ink);background:var(--ui-gold);color:var(--ui-gold-ink)}#journal-stats{margin-top:24px;border-top:1px solid var(--border);padding-top:18px}#journal-stats>summary{cursor:pointer;font-size:1.2rem;font-weight:700;padding:14px;min-height:48px}#community-view textarea{width:100%}@media(prefers-reduced-motion:reduce){.community-post{animation:none}}

#community-feed-tools{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}#community-feed-tools button{min-height:44px;white-space:normal;width:100%}.community-actions button:has(svg){display:inline-flex;align-items:center;justify-content:center;gap:6px}.community-actions svg{width:20px;height:20px;flex:none}

/* Five visible tabs: the grid owns its width; labels never widen the page. */
#page-navigation{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));width:100%;min-width:0;overflow:visible;gap:6px;box-sizing:border-box}
#page-navigation button{min-width:0;max-width:100%;white-space:normal;overflow-wrap:anywhere;line-height:1.35}
/* One compact header row; selected tabs already identify the active page. */
.topbar{display:flex;flex-wrap:nowrap;align-items:center;gap:8px;min-width:0;padding-block:10px;padding-top:max(10px,env(safe-area-inset-top))}
.topbar>.brand{flex:0 1 auto;min-width:0;margin-right:auto;gap:6px;white-space:nowrap}
.topbar>.brand img{flex:none;width:30px;height:30px}
.topbar>.brand>span{min-width:0;font-size:14px}
.topbar>.header-page-title{display:none!important}
.topbar>#user-button{flex:none;width:44px;height:44px;min-width:44px;padding:9px}
.topbar #header-tools{width:max-content!important;order:0!important;display:flex;flex:0 0 auto!important;flex-wrap:nowrap;align-items:center;gap:6px;margin:0;min-width:0;max-width:none}
.topbar #header-tools .icon-button{flex:none;width:44px;height:44px;min-width:44px;padding:9px}
@media(max-width:430px){.topbar{gap:3px;padding-inline:max(8px,env(safe-area-inset-left)) max(8px,env(safe-area-inset-right))}.topbar>.brand{gap:4px}.topbar>.brand img{width:22px;height:22px}.topbar>.brand>span{font-size:11px}.topbar>.brand small{display:none}.topbar #header-tools{gap:3px}}
@media(max-width:350px){.topbar{gap:2px;padding-inline:max(6px,env(safe-area-inset-left)) max(6px,env(safe-area-inset-right))}.topbar>.brand img{width:18px;height:18px}.topbar>.brand>span{font-size:10px}.topbar>#user-button,.topbar #header-tools .icon-button{width:40px;height:44px;min-width:40px;padding:9px}.topbar #header-tools{gap:2px}}
@media(max-width:720px){#page-navigation{gap:4px;padding-inline:max(12px,env(safe-area-inset-left)) max(12px,env(safe-area-inset-right))}#page-navigation button{flex-direction:column;gap:4px;padding:8px 2px;min-height:66px;font-size:11px}#page-navigation button>svg{width:20px;height:20px}}
@media(min-width:721px){#page-navigation button{padding-inline:8px}}
/* Academy-first admission; reuse existing brand colours and motion preferences. */
.learning-welcome{max-width:1120px;margin-inline:auto}.learning-welcome>label{display:grid;gap:.5rem;max-width:420px;margin-block:1.25rem}.learning-welcome h1{font-size:clamp(1.8rem,4vw,3.3rem);line-height:1.18}.learning-benefits{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-block:24px}.learning-benefit{position:relative;overflow:hidden;padding:24px;animation:learning-benefit-enter .55s ease-out both}.learning-benefit:nth-child(2){animation-delay:.09s}.learning-benefit:nth-child(3){animation-delay:.18s}.learning-benefit svg{width:38px;height:38px;fill:none;stroke:var(--teal-strong);stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}.learning-benefit h2{font-size:1.15rem;line-height:1.35}.learning-benefit p{line-height:1.7}.learning-start-actions{display:flex;gap:12px;flex-wrap:wrap}.learning-start-actions button{min-height:48px}.learning-welcome>p{line-height:1.7}@keyframes learning-benefit-enter{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}@media(max-width:680px){.learning-benefits{grid-template-columns:1fr}.learning-benefit{padding:20px}.learning-start-actions>*{width:100%}}@media(prefers-reduced-motion:reduce){.learning-benefit{animation:none}}

/* Shared account destinations and saved progress reuse the existing theme. */
#dialog-body .user-menu-link{display:flex;align-items:center;min-height:44px;padding:12px 16px;border:1px solid var(--border);border-radius:12px;color:var(--text);text-decoration:none;background:var(--surface-2)}.saved-learning-items{list-style:none;padding:0;display:grid;gap:12px}.saved-learning-items li{padding:16px;overflow-wrap:anywhere}.saved-learning-progress>label{display:grid;gap:8px}.saved-learning-progress select{max-width:100%}.saved-learning-progress>[aria-busy]{opacity:.8}

/* Academy entry: primary action stays above benefits, with the existing palette. */
.learning-welcome>label{margin-block:14px 12px}.learning-start-actions{margin-bottom:18px}.learning-start-actions #learning-start{display:inline-flex;align-items:center;justify-content:center;gap:18px;min-height:56px;min-width:240px;padding:13px 24px;font-size:18px;font-weight:800;border-radius:14px;box-shadow:0 6px 18px var(--teal-dim);transition:box-shadow .18s ease,transform .18s ease}.learning-start-actions #learning-start svg{width:24px;height:24px;flex:none;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}.learning-start-actions #learning-start:hover:not(:disabled){box-shadow:0 8px 24px var(--teal-dim);transform:translateY(-1px)}.learning-start-actions #learning-start:active:not(:disabled){transform:translateY(1px)}.learning-secondary-action{margin-block:12px}.learning-secondary-action button{font-size:14px}@media(max-width:680px){.learning-start-actions #learning-start{width:100%;min-width:0}.learning-secondary-action button{width:100%}}@media(prefers-reduced-motion:reduce){.learning-start-actions #learning-start{transition:none;transform:none!important}}
/* Brief invitation, not a continuous distraction. */
.learning-start-actions #learning-start{position:relative;overflow:hidden;isolation:isolate}.learning-start-actions #learning-start::after{content:'';position:absolute;inset:-40% auto -40% -70%;width:35%;background:linear-gradient(90deg,transparent,rgba(255,255,255,.38),transparent);transform:skewX(-18deg);pointer-events:none;animation:learning-cta-shine 2.8s ease-in-out 3}.learning-start-actions #learning-start svg{animation:learning-cta-arrow 2.8s ease-in-out 3}@keyframes learning-cta-shine{0%,20%{left:-70%}65%,100%{left:140%}}@keyframes learning-cta-arrow{0%,35%,75%,100%{transform:translateX(0)}50%,60%{transform:translateX(5px)}}@media(prefers-reduced-motion:reduce){.learning-start-actions #learning-start::after,.learning-start-actions #learning-start svg{animation:none}.learning-start-actions #learning-start::after{display:none}}

#learning-resources{display:grid;grid-template-columns:1fr;gap:12px}#learning-resources>[hidden]{display:none!important}#learning-resources .card{padding:18px}#extra-materials-content{display:grid;gap:12px;margin-top:14px}#extra-materials-content[hidden]{display:none!important}#free-materials p,#extra-materials>p{margin-block:6px 12px;font-size:14px}#extra-materials-content>button{justify-self:start}

/* v25-compact-feedback: routine diagnostics do not consume working space. */
.routine-status{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:0!important;overflow:hidden!important;clip-path:inset(50%)!important;white-space:nowrap!important;border:0!important;min-height:0!important}#analysis-summary{display:none!important}#finance-view>.page-intro,#analysis-view>.page-intro,#trade-view>.page-intro,#journal-view>.page-intro,#community-view>.page-intro{padding:10px 14px;margin:4px 0 10px;min-height:0}.page-intro .eyebrow{display:none}.page-intro h1{font-size:clamp(22px,2.5vw,28px);line-height:1.3;margin:0}.analysis-toolbar{margin-top:8px;gap:8px}#analysis-status:not(.routine-status){margin-block:6px;font-size:13px;line-height:1.5}#analysis-status:empty{margin:0}#analysis-pair-form{margin-block:10px}.period-bar{margin-bottom:8px}#finance-view .card{margin-block:10px}#entry-card>p.muted:empty{display:none}@media(max-width:600px){main{padding-top:12px}.page-intro{padding:10px 12px;margin-block:4px 10px}.page-intro .ui-art{max-width:52px;max-height:42px}#finance-view .card{padding:16px}#entry-form{gap:12px}}

/* v27: compact contextual help, no automatic popup or extra instruction row. */
.page-heading-help{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.page-heading-help h1{margin:0}.page-help-button{min-height:44px;min-width:44px;padding:6px 10px;font-size:12px;white-space:nowrap;border:1px solid var(--border,#cfd8e5);border-radius:999px;background:var(--surface,#fff);color:var(--text,#12243b)}.page-help-content{font-size:15px;line-height:1.65}.page-help-content p{margin:8px 0}.page-help-content ol{padding-inline-start:22px;margin:10px 0}.page-help-content li+li{margin-top:10px}.page-help-button:focus-visible{outline:2px solid currentColor;outline-offset:3px}
/* v28 branding balance: larger mark/type; smaller visuals with usable touch targets. */
.topbar>.brand{gap:8px;flex:1 1 auto;min-width:0}.topbar>.brand img{width:42px;height:42px}.topbar>.brand>span{font-size:21px;line-height:1.18;white-space:nowrap}.topbar>.brand small{font-size:10px;display:block;margin-top:3px}.topbar #header-tools{gap:2px}.topbar #header-tools .icon-button{width:40px;min-width:40px;height:44px;padding:11px}.topbar #header-tools .icon-button svg{width:19px;height:19px}.topbar>#user-button{width:40px;min-width:40px;height:44px;padding:9px}
.page-heading-help{justify-content:space-between;gap:10px}.page-help-button{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:40px;padding:6px 12px;border-radius:12px;border-color:var(--ui-gold);background:linear-gradient(135deg,var(--ui-gold-soft),var(--surface));color:var(--text);font-size:13px;font-weight:650;box-shadow:0 2px 5px rgb(0 0 0 / .04);transition:background .15s,border-color .15s}.page-help-mark{display:inline-grid;place-items:center;width:20px;height:20px;border:1px solid currentColor;border-radius:50%;font-size:12px;color:var(--ui-gold-text);font-weight:750}.page-help-content{max-width:580px;line-height:1.75}.page-help-content>p:first-child{font-weight:650}.page-help-content ol{counter-reset:help;list-style:none;padding:0}.page-help-content li{position:relative;padding:10px 12px 10px 42px;background:var(--surface-2);border:1px solid var(--border);border-radius:12px}.page-help-content li:before{counter-increment:help;content:counter(help);position:absolute;inset-inline-start:12px;top:11px;color:var(--ui-gold-text);font-weight:750}.page-help-content .muted{padding-top:8px;border-top:1px solid var(--border)}
@media(max-width:540px){.topbar{gap:4px;padding-inline:8px}.topbar>.brand{gap:5px}.topbar>.brand img{width:34px;height:34px}.topbar>.brand>span{font-size:17px}.topbar>.brand small{font-size:8px}.topbar #header-tools .icon-button,.topbar>#user-button{width:34px;min-width:34px;height:44px;padding:8px}.topbar #header-tools{gap:1px}.page-help-button{min-height:44px;padding:6px 10px;font-size:12px}}
@media(max-width:350px){.topbar{padding-inline:5px;gap:2px}.topbar>.brand img{width:28px;height:28px}.topbar>.brand>span{font-size:15px}.topbar>.brand small{font-size:7px}.topbar #header-tools .icon-button,.topbar>#user-button{width:32px;min-width:32px;padding:7px}.topbar #header-tools{gap:0}}
@media(prefers-reduced-motion:reduce){.page-help-button{transition:none}}

/* v30: native pair selection and focused trade form */
#trade-pair-picker{appearance:auto;touch-action:manipulation;min-height:46px}
.trade-optional{grid-column:1/-1;border:1px solid var(--border,#d6dfeb);border-radius:12px;padding:10px 12px;min-width:0}.trade-optional>summary{cursor:pointer;min-height:32px;font-weight:600}.trade-optional[open]>label{margin-top:10px}
#trade-preview{display:block}.trade-preview-cards{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.trade-preview-cards>div{padding:8px;border-radius:10px;background:var(--surface-2);min-width:0}.trade-preview-cards small,.trade-preview-cards strong{display:block;overflow-wrap:anywhere}.trade-position{font-size:.8rem;margin:6px 0}
#trading-totals{gap:8px;margin-block:10px}#trading-totals .report-metric{padding:10px 12px;min-height:0}#trading-totals .report-metric strong{font-size:1.05rem}.trade-fund-tools>summary{cursor:pointer;font-size:.82rem;min-height:32px;padding:6px 0}.trade-fund-tools .goal-actions{margin-top:8px}
#trade-form-card{margin-top:12px}#trade-form-card>.section-title,#trade-form-card>h2{margin-bottom:12px}#trade-form{gap:12px}#trade-form .form-grid{gap:10px 12px}#trade-form label{gap:5px}#trade-form input,#trade-form select{padding:8px 10px}#trading-account-card{margin-top:16px}@media(min-width:1000px){#trade-form .form-grid{grid-template-columns:repeat(4,minmax(0,1fr))}.trade-preview-cards{grid-template-columns:repeat(4,minmax(0,1fr))}}

/* v31: restore screenshot trade flow without changing financial logic */
#trade-view>.page-intro{padding:10px 12px;margin-bottom:10px;min-height:0}#trade-view>.page-intro h1{font-size:21px}.trade-form-header{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:10px}.trade-form-header h2{font-size:18px;margin:0}.trade-form-header button{min-height:40px;padding:6px 12px;font-size:12px;border-color:var(--ui-gold);background:var(--ui-gold-soft)}.trade-balance-summary{display:flex;justify-content:flex-end;align-items:center;gap:6px 10px;flex-wrap:wrap;font-size:11px;margin:4px 0 12px}.trade-balance-summary strong{font-size:13px;color:var(--teal)}#trade-form-card{padding:14px}#trade-form label{font-size:12px}#trade-form .form-grid{gap:10px}#trade-preview{margin:0;padding:10px;background:var(--surface-2);border:1px solid var(--border);border-radius:10px}.trade-preview-cards>div{padding:5px;background:transparent}.trade-preview-cards small{font-size:10px;line-height:1.4}.trade-preview-cards strong{font-size:13px;line-height:1.6}.trade-rule-tools{display:flex;align-items:center;justify-content:space-between;gap:8px}.trade-rule-tools button{font-size:11px;padding:5px 10px;min-height:40px}#trade-rules{border:1px dashed var(--border);border-radius:10px;padding:10px;margin:0}#trade-rules legend{font-size:12px}#trade-rules .sms-check{font-size:12px}#trade-analysis-status{font-size:10px;margin:0 0 8px}#trade-warning:empty,#trade-preview:empty{display:none}#trade-save{background:var(--ui-gold);color:var(--ui-gold-text);border-color:var(--ui-gold);width:100%}.trade-bias-summary{margin-top:12px;padding:12px;border:1px solid var(--border);border-radius:12px}.trade-bias-summary h2{font-size:15px;margin-bottom:8px}.trade-bias-values{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px}.trade-bias-values>span{padding:6px 9px;border-radius:8px;background:var(--surface-2);font-size:12px}.trade-bias-values [data-bias=bull]{color:var(--teal)}.trade-bias-values [data-bias=bear]{color:var(--red)}.trade-bias-values [data-bias=neutral]{color:var(--text-dim)}.trade-plan-preview{white-space:pre-wrap;padding:12px;background:var(--surface-2);border-radius:10px;font:inherit;line-height:1.7}#trade-form .form-grid input,#trade-form .form-grid select{min-height:44px}#trading-totals .report-metric{box-shadow:none}#trading-totals .report-metric:after{display:none}@media(min-width:1000px){.trade-preview-cards{grid-template-columns:repeat(6,minmax(0,1fr))}#trading-totals{grid-template-columns:repeat(7,minmax(0,1fr))}}
/* Keep the legacy checklist flat and notes compact; retain usable touch targets. */
#trade-form textarea[name=notes]{min-height:64px;height:64px;resize:vertical}#trade-rules-list{display:grid;gap:2px}#trade-rules-list .sms-check{display:flex;align-items:center;gap:9px;min-height:36px;padding:5px 0;background:transparent;border:0;box-shadow:none;border-radius:0;font-weight:400}#trade-rules-list .sms-check input{flex:0 0 20px;width:20px;height:20px;min-height:20px;margin:0}#trading-totals .report-metric{animation:none;opacity:1;transform:none;min-width:0}#trading-totals .report-metric small,#trading-totals .report-metric strong{overflow-wrap:anywhere}
.trade-preview-cards [data-tone=loss] strong{color:var(--red)}.trade-preview-cards [data-tone=gain] strong{color:var(--teal)}.trade-preview-cards [data-tone=risk] strong{color:var(--ui-gold-text)}
#trade-form #trade-rules-list .sms-check{background:transparent;border:0;box-shadow:none;padding:5px 0;border-radius:0;min-height:36px}

/* Align the shared brand mark with the 32px profile avatar. */
body.tb-app .topbar > .brand > img{width:32px;height:32px;flex:none;object-fit:contain}
body.tb-app .topbar > #user-button > svg{position:absolute;inset:0;margin:auto;width:32px;height:32px}

/* Compact only the action boxes in the account dialog. */
body.tb-app #app-dialog #dialog-body > [data-user-action]{min-height:40px;padding-block:6px}

#dialog-body > .user-menu-link + .user-menu-link {
  margin-block-start: 8px;
}
