/* SRSHerbal v2.40.0 — Global UI + workflow final polish
   Visual-only safety layer. No pricing, order, KYC, commission or settlement logic. */
:root{
  --srs-ink:#103947;--srs-ink-2:#315762;--srs-green:#0d7668;--srs-green-2:#126857;
  --srs-gold:#b8842f;--srs-line:#dce7e3;--srs-soft:#f5faf8;--srs-ivory:#fffdf7;
  --srs-danger:#c9404d;--srs-warn:#a66d12;--srs-shadow:0 12px 32px rgba(18,57,71,.08);
  --srs-radius:18px;--srs-max:1480px;
}
html{overflow-x:hidden;scroll-behavior:smooth}body{overflow-x:hidden;color:var(--srs-ink);background:#fff}
body *,body *::before,body *::after{box-sizing:border-box;min-width:0}
img,svg,video{max-width:100%;height:auto}button,input,select,textarea{font:inherit}
main{width:100%}.container,.page-shell,.content-shell{max-width:var(--srs-max);margin-inline:auto}

/* Header + navigation */
.site-header.locked-header{max-width:var(--srs-max);margin:0 auto;padding-inline:clamp(14px,2.2vw,34px);gap:clamp(10px,1.4vw,24px)}
.site-header .brand img{max-width:clamp(170px,16vw,245px);height:auto}.search.smart-search{min-width:240px}
.mainnav.locked-nav{overflow-x:auto;scrollbar-width:none;-webkit-overflow-scrolling:touch}.mainnav.locked-nav::-webkit-scrollbar{display:none}
.mainnav.locked-nav a{white-space:nowrap}.trustbar{overflow:hidden}.trustbar span{white-space:nowrap}

/* Universal cards/buttons/forms */
.btn,button,.mini-action,a.mini-action{min-height:42px;border-radius:12px;display:inline-flex;align-items:center;justify-content:center;gap:7px}
.btn.primary,button.primary{background:linear-gradient(135deg,var(--srs-green),var(--srs-green-2));border-color:transparent;color:#fff;box-shadow:0 7px 18px rgba(13,118,104,.16)}
input,select,textarea{max-width:100%;border-radius:12px}.panel,.audit-card,.v237-health-grid>div{box-shadow:0 6px 22px rgba(18,57,71,.045)}
.table-wrap{max-width:100%;overflow:auto;-webkit-overflow-scrolling:touch;border-radius:16px}
table{width:100%;border-collapse:separate;border-spacing:0}th,td{vertical-align:middle}td small{display:block}
.empty,.smart-empty-state{min-height:110px;display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:8px}

/* Public product grids — hard protection against narrow/tall broken cards */
.product-grid,.products-grid,.catalog-grid,.catalogue-grid,.related-products-grid,
[class*="product-grid"],[class*="products-grid"],[class*="catalog-grid"]{
  display:grid!important;grid-template-columns:repeat(5,minmax(0,1fr))!important;gap:18px!important;align-items:stretch!important;width:100%!important;
}
.product-card,.catalog-card,.product-tile,.v240-card,
[class*="product-card"],[class*="catalog-card"],[class*="product-tile"]{
  width:100%!important;min-width:0!important;max-width:none!important;height:auto!important;overflow:hidden!important;
  border:1px solid var(--srs-line)!important;border-radius:18px!important;background:#fff!important;box-shadow:0 8px 24px rgba(16,57,71,.07)!important;
}
.product-card img,.catalog-card img,.product-tile img,.v240-card img,
[class*="product-card"] img,[class*="catalog-card"] img,[class*="product-tile"] img{
  width:100%!important;aspect-ratio:4/3!important;object-fit:cover!important;display:block!important;background:#f5f8f5!important;
}
.product-card h2,.product-card h3,.product-card h4,.catalog-card h2,.catalog-card h3,.catalog-card h4,.v240-card h2,.v240-card h3,.v240-card h4{
  font-size:clamp(16px,1.3vw,21px)!important;line-height:1.18!important;overflow-wrap:anywhere!important;word-break:normal!important;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;margin-bottom:7px!important;
}
.product-card p,.catalog-card p,.product-tile p,.v240-card p{overflow-wrap:anywhere;line-height:1.45}
.product-card .btn,.catalog-card .btn,.product-tile .btn,.v240-card .btn{width:100%;margin-top:auto}

/* Related products — premium section, regardless of legacy markup */
.v240-related-products{position:relative;margin:34px auto 18px!important;padding:clamp(22px,3vw,42px)!important;border:1px solid #dbe9e2!important;border-radius:28px!important;
  background:radial-gradient(circle at 95% 0,rgba(184,132,47,.08),transparent 25%),linear-gradient(135deg,#fbfdfb 0%,#fffdf7 52%,#f2faf6 100%)!important;overflow:hidden!important}
.v240-related-products::before,.v240-related-products::after{content:"";position:absolute;width:180px;height:180px;border-radius:50%;background:rgba(13,118,104,.045);pointer-events:none}
.v240-related-products::before{left:-95px;bottom:-105px}.v240-related-products::after{right:-105px;top:-100px}
.v240-related-products>h2,.v240-related-products>h3,.v240-related-products .section-head h2,.v240-related-products .section-head h3{
  position:relative;z-index:1;font-size:clamp(26px,3vw,42px)!important;letter-spacing:-.02em!important;color:var(--srs-ink)!important;margin:0 0 18px!important}
.v240-related-products .v240-related-intro{position:relative;z-index:1;margin:-8px 0 24px;color:#5d747c;max-width:760px;font-size:15px;line-height:1.6}
.v240-related-products .product-grid,.v240-related-products .products-grid,.v240-related-products .catalog-grid,.v240-related-products [class*="grid"]{position:relative;z-index:1}
.v240-related-products .v240-card{display:flex!important;flex-direction:column!important;padding:10px!important;min-height:100%!important}
.v240-related-products .v240-card>*:not(img):not(picture){margin-left:6px;margin-right:6px}

/* Honest but attractive missing-photo state */
.v240-photo-pending,.real-photo-required,.admin-image-fallback.real-photo-required{
  display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;text-align:center!important;
  width:100%!important;min-height:150px!important;aspect-ratio:4/3!important;padding:18px!important;border:1px dashed #b8d7cc!important;border-radius:15px!important;
  background:linear-gradient(145deg,#f6fbf8,#fffaf0)!important;color:#1e6258!important;font-size:0!important;overflow:hidden!important;
}
.v240-photo-pending::before,.real-photo-required::before{content:"🌿";font-size:30px;line-height:1;margin-bottom:8px}
.v240-photo-pending::after,.real-photo-required::after{content:"Verified photo sourcing";font-size:13px;line-height:1.3;font-weight:850;letter-spacing:.01em}

/* Product detail stability */
.product-detail,.product-detail-grid,[class*="product-detail"]{max-width:var(--srs-max);margin-inline:auto}
.product-detail-grid,[class*="product-detail-grid"]{display:grid;grid-template-columns:minmax(0,1.02fr) minmax(320px,.98fr);gap:clamp(22px,3vw,48px);align-items:start}
.product-gallery,.product-media,[class*="product-gallery"],[class*="product-media"]{min-width:0;overflow:hidden}
.product-gallery img,.product-media img,[class*="product-gallery"] img,[class*="product-media"] img{max-height:620px;object-fit:contain;background:#fafbf8;border-radius:20px}


/* Product-page width rescue: old templates must not leave half the desktop empty. */
.v240-product-page main{width:100%!important;max-width:var(--srs-max)!important;margin-inline:auto!important;padding-inline:clamp(10px,2vw,28px)!important}
.v240-product-page main>*,.v240-product-page main>.container,.v240-product-page main>[class*="container"]{max-width:100%!important;width:100%!important}
.v240-product-page .related-products,.v240-product-page [class*="related"]{max-width:100%!important}

/* Admin global polish */
.admin-theme main{padding:clamp(14px,2vw,28px);max-width:100%}.admin-topbar{gap:14px}.admin-search{min-width:240px}
.v221-modulebar{scrollbar-width:none}.v221-modulebar::-webkit-scrollbar{display:none}.v221-modulebar a{white-space:nowrap}
.admin-shell,.smart-admin-products{max-width:var(--srs-max);margin:0 auto;gap:18px}.smart-admin-products>.dash-nav{display:none!important}.smart-admin-products{grid-template-columns:minmax(0,1fr)!important}
.smart-admin-head{gap:16px;align-items:flex-end}.smart-admin-head-actions{display:flex;flex-wrap:wrap;gap:8px}.smart-admin-head-actions .btn{min-height:42px}
.v240-catalogue-status{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:16px;align-items:center;padding:18px 20px;margin:16px 0 18px;background:linear-gradient(135deg,#f5faf8,#fffaf0);border:1px solid #dce8e3;border-radius:18px}
.v240-catalogue-status h3{margin:0 0 5px;font-size:18px}.v240-catalogue-status p{margin:0;color:#667d84;line-height:1.5}.v240-catalogue-status .actions{display:flex;gap:8px;flex-wrap:wrap}
.smart-filter-bar{display:grid!important;grid-template-columns:minmax(240px,2fr) repeat(4,minmax(150px,1fr)) auto!important;gap:10px!important;align-items:center}.smart-filter-bar>*{width:100%!important;min-height:44px}
.bulk-toolbar{display:flex;flex-wrap:wrap;gap:10px;align-items:center}.smart-product-table table{min-width:1120px}.smart-product-table th{position:sticky;top:0;z-index:1;background:#f7faf9}
.admin-product-cell{min-width:260px}.admin-product-cell img{width:66px!important;height:66px!important;aspect-ratio:1!important;object-fit:cover!important;border-radius:12px!important}.admin-product-cell .real-photo-required{width:66px!important;min-height:66px!important;aspect-ratio:1!important;padding:6px!important}.admin-product-cell .real-photo-required::before{font-size:20px}.admin-product-cell .real-photo-required::after{font-size:9px}
.product-actions{display:flex;flex-wrap:wrap;gap:6px;min-width:210px}.product-actions form{margin:0}
.v237-admin-kyc,.v216-health-page,.srs-audit{max-width:var(--srs-max)!important;margin-inline:auto!important}.v237-kyc-filters{display:grid!important;grid-template-columns:minmax(220px,2fr) repeat(3,minmax(160px,1fr)) auto;gap:10px}.v237-kyc-filters>*{width:100%;min-height:44px}
.v237-health-grid{grid-template-columns:repeat(6,minmax(0,1fr))!important;gap:12px!important}.v237-health-grid>div{border:1px solid #dce7e3;border-radius:15px;padding:15px;background:#fff}

/* Account + seller dashboards */
.dashboard-shell{max-width:var(--srs-max);margin-inline:auto;gap:20px}.dash-main{min-width:0}.metric-grid{gap:12px!important}.metric-grid>div{border-radius:16px!important;min-width:0!important}
.buyer-action-grid,.seller-growth-grid-v223{gap:14px!important}.buyer-action-grid>a,.seller-growth-grid-v223 article{border-radius:18px!important}

/* Long names / content never break layout */
.product-card *, .catalog-card *, .v240-card *, .admin-product-cell *, td, th{overflow-wrap:anywhere}

@media(max-width:1280px){
  .product-grid,.products-grid,.catalog-grid,.catalogue-grid,.related-products-grid,[class*="product-grid"],[class*="products-grid"],[class*="catalog-grid"]{grid-template-columns:repeat(4,minmax(0,1fr))!important}
  .smart-filter-bar{grid-template-columns:repeat(3,minmax(0,1fr))!important}.smart-filter-bar input[name="q"]{grid-column:span 2}
  .v237-health-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}
}
@media(max-width:980px){
  .product-grid,.products-grid,.catalog-grid,.catalogue-grid,.related-products-grid,[class*="product-grid"],[class*="products-grid"],[class*="catalog-grid"]{grid-template-columns:repeat(3,minmax(0,1fr))!important}
  .product-detail-grid,[class*="product-detail-grid"]{grid-template-columns:1fr}.v240-catalogue-status{grid-template-columns:1fr}.admin-topbar .admin-search{display:none}
}
@media(max-width:720px){
  .trustbar{justify-content:flex-start;gap:14px;padding-inline:12px}.trustbar span:nth-child(n+4){display:none}
  .site-header.locked-header{padding:10px 12px}.header-actions{display:none!important}.search.smart-search{order:3;width:100%;min-width:0}
  .product-grid,.products-grid,.catalog-grid,.catalogue-grid,.related-products-grid,[class*="product-grid"],[class*="products-grid"],[class*="catalog-grid"]{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:11px!important}
  .product-card,.catalog-card,.product-tile,.v240-card{border-radius:15px!important}.v240-related-products{margin:18px 10px!important;padding:18px 12px!important;border-radius:20px!important}
  .product-card h2,.product-card h3,.product-card h4,.catalog-card h2,.catalog-card h3,.catalog-card h4,.v240-card h2,.v240-card h3,.v240-card h4{font-size:15px!important;line-height:1.2!important}
  .product-card p,.catalog-card p,.product-tile p,.v240-card p{font-size:12px!important;line-height:1.35!important}
  .smart-filter-bar,.v237-kyc-filters{grid-template-columns:1fr 1fr!important}.smart-filter-bar input[name="q"],.v237-kyc-filters input[name="q"]{grid-column:1/-1}
  .smart-admin-head{align-items:flex-start}.smart-admin-head-actions{width:100%}.smart-admin-head-actions .btn{flex:1 1 46%}
  .v237-health-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .admin-theme main{padding:12px 10px 88px}.table-wrap{border-radius:12px}
}
@media(max-width:390px){
  .product-grid,.products-grid,.catalog-grid,.catalogue-grid,.related-products-grid,[class*="product-grid"],[class*="products-grid"],[class*="catalog-grid"]{gap:8px!important}
  .v240-related-products{margin-inline:6px!important;padding-inline:9px!important}.smart-filter-bar,.v237-kyc-filters{grid-template-columns:1fr!important}.smart-filter-bar input[name="q"],.v237-kyc-filters input[name="q"]{grid-column:auto}
}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important;animation:none!important}}

/* =========================================================
   SRSHerbal v2.41.0 — JOST GLOBAL TYPOGRAPHY LOCK
   Website + Admin + Buyer + Seller + KYC + Orders + B2B
   ========================================================= */
:root{
  --srs-font:'Jost','Segoe UI',Arial,sans-serif;
  --srs-font-devanagari:'Noto Sans Devanagari','Jost','Segoe UI',Arial,sans-serif;
}
html,body{font-family:var(--srs-font)!important;font-optical-sizing:auto;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased}
body:lang(hi),html:lang(hi){font-family:var(--srs-font-devanagari)!important}

/* Text surfaces: override legacy serif/mixed typography without touching icon-font <i> elements. */
h1,h2,h3,h4,h5,h6,
p,a,button,input,select,textarea,label,small,strong,b,
table,thead,tbody,tfoot,th,td,caption,
.btn,.mini-action,.badge,.pill,.chip,
.site-header,.mainnav,.trustbar,.header-actions,.mobile-category-strip-v224,
.admin-theme,.admin-topbar,.admin-search,.admin-actions,.admin-profile,.v221-modulebar,
.dashboard-shell,.dash-main,.metric-grid,
.product-card,.catalog-card,.product-tile,.v240-card,
.product-detail,.product-detail-grid,.v240-related-products,
.v237-admin-kyc,.v237-kyc-filters,.v237-health-grid,.srs-audit,
.smart-admin-products,.smart-admin-head,.smart-filter-bar,.bulk-toolbar,.smart-product-table,
.v238-wrap,.v238-hero,.v238-card,.v238-panel,.v238-btn,.v238-log{
  font-family:var(--srs-font)!important;
}
html[lang="hi"] h1,html[lang="hi"] h2,html[lang="hi"] h3,html[lang="hi"] h4,html[lang="hi"] h5,html[lang="hi"] h6,
html[lang="hi"] p,html[lang="hi"] a,html[lang="hi"] button,html[lang="hi"] input,html[lang="hi"] select,html[lang="hi"] textarea,html[lang="hi"] label,
html[lang="hi"] th,html[lang="hi"] td{font-family:var(--srs-font-devanagari)!important}

/* One consistent hierarchy everywhere. */
h1,.page-title,.hero-title,.smart-admin-head h1,.v238-hero h1{font-weight:800!important;letter-spacing:-.035em!important;line-height:1.08!important}
h2,.section-title,.panel-title,.v240-related-products h2{font-weight:750!important;letter-spacing:-.025em!important;line-height:1.12!important}
h3,h4,h5,h6{font-weight:700!important;letter-spacing:-.015em!important;line-height:1.18!important}
p,li,td,label,input,select,textarea{font-weight:400;letter-spacing:0;line-height:1.55}
nav a,.btn,button,.mini-action,.badge,.pill,.chip,th{font-weight:650!important;letter-spacing:.005em!important}
small,.muted,.meta,.help-text{font-weight:450;line-height:1.45}

/* Dashboard/admin density tuned for Jost. */
.admin-topbar,.v221-modulebar,.dash-nav{font-size:14px!important}
.admin-actions small,.admin-profile small{font-size:12px!important;font-weight:550!important}
.v221-modulebar a,.dash-nav a{line-height:1.15!important}
.smart-admin-head h1{font-size:clamp(30px,3vw,44px)!important}
.metric-grid b,.kpi-card b,.audit-card b,.v237-health-grid b{font-weight:800!important;letter-spacing:-.02em!important}

/* Public product typography tuned for long botanical names. */
.product-card h2,.product-card h3,.product-card h4,
.catalog-card h2,.catalog-card h3,.catalog-card h4,
.v240-card h2,.v240-card h3,.v240-card h4{font-weight:700!important;letter-spacing:-.015em!important;line-height:1.18!important}
.product-card p,.catalog-card p,.product-tile p,.v240-card p{font-weight:400!important}
.product-detail h1,[class*="product-detail"] h1{font-weight:800!important;letter-spacing:-.03em!important}
.v240-related-products>h2,.v240-related-products>h3,.v240-related-products .section-head h2,.v240-related-products .section-head h3{font-family:var(--srs-font)!important;font-weight:800!important}

/* Forms/tables stay readable and compact. */
input,select,textarea,button{font-size:14px!important}
th{font-size:12px!important;text-transform:uppercase;letter-spacing:.055em!important}
td{font-size:14px!important}

/* Prevent legacy script/serif decorative rules from leaking into core UI text. */
.trust-script,.eyebrow,.overline,.section-kicker,.catalog-kicker,.admin-kicker{font-family:var(--srs-font)!important}

@media(max-width:720px){
  body{font-size:14px}
  h1,.page-title,.hero-title,.smart-admin-head h1{letter-spacing:-.025em!important}
  .admin-topbar,.v221-modulebar,.dash-nav{font-size:13px!important}
  input,select,textarea,button{font-size:14px!important}
}
