/* Mayabin Shop 8.3.1 - accessibility & mobile polish layer.
   Scoped to plugin wrappers only, so the active theme is never affected. */

/* 1. Visible keyboard focus (several inputs had outline:none with only a faint 10-12% glow) */
:is(.sp-shop2,.sp-ca-wrap,.sp-pd-wrap,.sp-auth-wrap,.sp-co,.mp-embed,.mp-checkout-form,.mp-buy-field,.mp-account-login,.spfo-modal,.spfo-step) :is(a,button,input,select,textarea,summary,[role="button"],[tabindex]):focus-visible{
	outline:2px solid var(--sp-primary,#e91c63);
	outline-offset:2px;
	box-shadow:0 0 0 4px rgba(var(--sp-primary-rgb,233,28,99),.2);
}
:is(.sp-shop2,.sp-ca-wrap,.sp-pd-wrap,.sp-auth-wrap,.sp-co,.mp-embed,.mp-checkout-form,.mp-buy-field,.mp-account-login,.spfo-modal,.spfo-step) :is(input,select,textarea):focus-visible{outline-offset:0}

/* 2. Phones: 16px minimum font in fields stops the iOS Safari zoom-on-focus; comfortable tap targets */
@media (max-width:782px){
	:is(.sp-shop2,.sp-ca-wrap,.sp-pd-wrap,.sp-auth-wrap,.sp-co,.mp-embed,.mp-checkout-form,.mp-buy-field,.mp-account-login,.spfo-modal,.spfo-step) :is(input:not([type=checkbox]):not([type=radio]):not([type=range]),select,textarea),
	.mps-search input[type=search],.mp-cart-qty input{font-size:16px}
	.sp-ca-item-qty input{min-height:40px;font-size:16px}
	.sp-ca-rm{width:40px;height:40px}
	.spfo-modal .spfo-x{height:40px;min-width:40px}
}

/* 3. Never let long Bangla/English strings, e-mails or TRX ids break the layout sideways */
:is(.sp-shop2,.sp-ca-wrap,.sp-pd-wrap,.sp-auth-card,.mp-embed,.spfo-modal) :is(h1,h2,h3,h4,p,td,th,li,a,span,code){overflow-wrap:anywhere}
:is(.sp-shop2,.sp-ca-wrap,.sp-pd-wrap,.mp-embed) img{max-width:100%}
:is(.sp-ca-wrap,.mp-embed) table{max-width:100%}

/* 4. Respect "reduce motion" */
@media (prefers-reduced-motion:reduce){
	:is(.sp-shop2,.sp-ca-wrap,.sp-pd-wrap,.sp-auth-wrap,.sp-co,.mp-embed,.mp-checkout-form,.mp-buy-field,.spfo-modal) *,
	:is(.sp-shop2,.sp-ca-wrap,.sp-pd-wrap,.sp-auth-wrap,.sp-co,.mp-embed,.mp-checkout-form,.mp-buy-field,.spfo-modal) *::before,
	:is(.sp-shop2,.sp-ca-wrap,.sp-pd-wrap,.sp-auth-wrap,.sp-co,.mp-embed,.mp-checkout-form,.mp-buy-field,.spfo-modal) *::after{
		animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important;
	}
}

/* 5. Print: invoice / receipt without chrome */
@media print{
	.sp-ca-tabs,.sp-ca-btn-logout,.mp-toast,.spfo-modal{display:none!important}
}

/* 6. Payment-method picker: selected option was only a faint grey border - make the choice obvious */
.sp-gwp .sp-gwp-list.is-multi .sp-gwp-item{position:relative}
.sp-gwp .sp-gwp-list.is-multi .sp-gwp-item.is-on{
	border-color:var(--sp-co-c,var(--sp-primary,#e91c63));
	background:rgba(var(--sp-primary-rgb,233,28,99),.06);
	box-shadow:0 0 0 1px var(--sp-co-c,var(--sp-primary,#e91c63));
}
.sp-gwp .sp-gwp-list.is-multi .sp-gwp-item.is-on::after{
	content:"✓";position:absolute;top:8px;right:10px;width:22px;height:22px;border-radius:50%;
	background:var(--sp-co-c,var(--sp-primary,#e91c63));color:#fff;font-size:13px;line-height:22px;text-align:center;font-weight:700;
}
.sp-gwp .sp-gwp-list.is-multi .sp-gwp-item:has(.sp-gwp-in:focus-visible){outline:2px solid var(--sp-primary,#e91c63);outline-offset:2px}

/* 7. One brand colour by default. With the Colour tab empty, Cart / Account were blue (#2563eb) while Shop, Product,
   Checkout and Login were pink (#e91c63). :where() keeps these defaults at zero specificity, so any colour chosen in
   Store Settings -> Colour (colors.php) always wins. */
:where(:root){
	--sp-primary:#e91c63;--sp-primary-d:#c2154f;--sp-primary-rgb:233,28,99;--sp-primary-soft:rgba(233,28,99,.08);--sp-primary-line:rgba(233,28,99,.28);
	--sp-primary-tint0:#fff8fb;--sp-primary-tint:#fdeef3;--sp-primary-tint2:#fad2e0;--sp-primary-bd:#f5b3cb;--sp-primary-ink:#6b0b2f;--sp-on-primary:#fff;
}
.sp-ca-wrap{--ca-primary:var(--sp-primary);--ca-primary-h:var(--sp-primary-d)}

/* 8. Readability: text that was 10-11px and/or below WCAG AA contrast (measured in a browser audit) */
.mps .mps-desc{font-size:13px;line-height:1.6;color:#5f6270}
.mps .mps-cat{font-size:12px}
.mps .mps-sale,.mps .mps-badge{font-size:11.5px}
.mps .mps-sale{background:var(--sp-accent,#dc2626)}
.mps .mps-old{color:#6b6e7b;font-size:12.5px}
.sp-pd-wrap .sp-pd-old-price{color:#64748b}
.sp-ca-btn-danger,.sp-ca-rm{color:#b91c1c}
.spfo-box .spfo-date{color:#667085}
.mp-embed .mp-pill{font-size:12px}
.mp-embed .mp-tr-step{font-size:12px}
.mp-embed .mp-tr-step .dim{color:#64748b}
.mp-embed .mp-lock-tx small{font-size:12px}
.mp-embed .mp-tip{font-size:13px;color:#475467}
@media (max-width:480px){.mp-embed .mp-tr-step{font-size:11.5px}}
.sp-pd-wrap .sp-pd-price-card .sp-pd-old-price{color:#64748b}
.sp-ca-wrap{--ca-danger:#dc2626}
