/* ==========================================================================
   COMPANY MICROSITE  —  two templates, one stylesheet
   --------------------------------------------------------------------------
   Every colour comes from a CSS custom property that the layout prints
   inline from micro_theme() in PHP, so the client's own accent colour
   (Profile › Website template › Brand colour) flows through everything.

     [data-tpl="pcd"]  PCD Pharma Franchise      — teal / amber
     [data-tpl="tpm"]  Third Party Manufacturing — indigo / gold

   Both templates share ONE design: same type scale, same spacing, same
   radii, same components. Only the palette changes between them.
   ========================================================================== */

.ms {
  --brand: #0E7C66;
  --brand-dark: #0A5B4B;
  --brand-soft: #E6F5F1;
  --accent: #F2994A;
  --ink: #10231F;
  --ink-soft: #4A615C;
  --line: #DCE8E5;
  --surface: #fff;
  --surface-2: #F4F9F8;
  --band: #0B5F4F;
  --band-2: #0E7C66;
  --r: 18px;
  --shadow: 0 1px 2px rgba(16, 35, 31, .05), 0 12px 32px -12px rgba(16, 35, 31, .16);
  --shadow-sm: 0 1px 2px rgba(16, 35, 31, .06), 0 4px 12px -6px rgba(16, 35, 31, .12);
  --wrap: 1200px;

  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--ink);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
}

.ms *, .ms *::before, .ms *::after { box-sizing: border-box; }

.ms img { max-width: 100%; height: auto; display: block; }

.ms-wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: 20px; }

.ms a { color: inherit; text-decoration: none; }
.ms a:hover { color: var(--brand); }

.ms h1, .ms h2, .ms h3, .ms h4 { margin: 0; line-height: 1.18; letter-spacing: -.02em; font-weight: 800; }
.ms p { margin: 0 0 14px; line-height: 1.7; color: var(--ink-soft); }
.ms ul { margin: 0; padding: 0; list-style: none; }

/* --------------------------------------------------------------- shared bits */

.ms-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase;
  color: var(--brand); background: var(--brand-soft);
  padding: 7px 14px; border-radius: 999px; margin-bottom: 16px;
}
.ms-eyebrow::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }

.ms-h2 { font-size: clamp(26px, 3.4vw, 40px); margin-bottom: 12px; }
.ms-h2 em { font-style: italic; font-weight: 700; color: var(--brand); }
.ms-lede { font-size: 16px; max-width: 64ch; }

.ms-sec { padding: clamp(52px, 7vw, 92px) 0; }
.ms-sec--alt { background: var(--surface-2); }
.ms-sec--band { background: linear-gradient(150deg, var(--band) 0%, var(--band-2) 100%); color: #fff; }
.ms-sec--band .ms-h2, .ms-sec--band h3 { color: #fff; }
.ms-sec--band p { color: rgba(255,255,255,.72); }
.ms-sec--band .ms-eyebrow { color: #fff; background: rgba(255,255,255,.12); }

.ms-center { text-align: center; }
.ms-center .ms-lede { margin-inline: auto; }

.ms-grid { display: grid; gap: 22px; }
.ms-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ms-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ms-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.ms-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 700; font-size: 13.5px; line-height: 1;
  padding: 12px 20px; border-radius: calc(var(--r) - 8px);
  border: 1.5px solid transparent; cursor: pointer;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease,
              color .16s ease, border-color .16s ease;
  white-space: nowrap;
}
.ms-btn:hover { transform: translateY(-2px); }

/* solid amber/orange call-to-action */
.ms-btn--accent { background: var(--accent); color: #241703; box-shadow: 0 10px 22px -10px var(--accent); }
.ms-btn--accent:hover { background: var(--accent); color: #241703; filter: brightness(1.06); }

/* solid brand */
.ms-btn--brand { background: var(--brand); color: #fff; box-shadow: 0 10px 22px -10px var(--brand); }
.ms-btn--brand:hover { color: #fff; background: var(--brand-dark); }

/* outline on a LIGHT surface — brand tinted, never dark */
.ms-btn--outline { background: var(--brand-soft); color: var(--brand); border-color: var(--brand-soft); }
.ms-btn--outline:hover { background: #fff; color: var(--brand); border-color: var(--brand); }

/* on a COLOURED band — frosted white, not a black slab */
.ms-btn--ghost {
  background: rgba(255, 255, 255, .16);
  border-color: rgba(255, 255, 255, .5);
  color: #fff;
  backdrop-filter: blur(3px);
}
.ms-btn--ghost:hover { background: #fff; border-color: #fff; color: var(--brand); }

.ms-btn--light, .ms-btn--white { background: #fff; color: var(--brand); border-color: #fff; }
.ms-btn--light:hover, .ms-btn--white:hover { background: var(--brand-soft); color: var(--brand-dark); }

.ms-btn--wa { background: #1FA855; color: #fff; }
.ms-btn--wa:hover { color: #fff; background: #179046; }
.ms-btn--block { width: 100%; }
.ms-btn--sm { padding: 9px 15px; font-size: 12.5px; }

/* ============================================================ HEADER */

.ms-top {
  background: var(--brand-dark); color: rgba(255,255,255,.82);
  font-size: 12px; font-weight: 600;
}
.ms-top .ms-wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 38px; flex-wrap: wrap; }
.ms-top a { color: rgba(255,255,255,.88); }
.ms-top a:hover { color: #fff; }
.ms-top-list { display: flex; gap: 18px; flex-wrap: wrap; align-items: center; }
.ms-top-list span { display: inline-flex; align-items: center; gap: 6px; }

.ms-head {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255,255,255,.94); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.ms-head .ms-wrap { display: flex; align-items: center; gap: 22px; min-height: 72px; }

.ms-brand { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.ms-brand-logo {
  width: 46px; height: 46px; border-radius: 12px; overflow: hidden; flex-shrink: 0;
  display: grid; place-items: center; background: var(--brand-soft);
  color: var(--brand); font-weight: 800; font-size: 17px; letter-spacing: -.02em;
  border: 1px solid var(--line);
}
.ms-brand-logo img { width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.ms-brand-name { font-size: 16px; font-weight: 800; line-height: 1.2; letter-spacing: -.02em; }
.ms-brand-sub { font-size: 10px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; color: var(--brand); margin-top: 3px; }

.ms-nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.ms-nav a {
  font-size: 14px; font-weight: 650; padding: 9px 14px; border-radius: 9px;
  color: var(--ink-soft); transition: .16s;
}
.ms-nav a:hover { background: var(--brand-soft); color: var(--brand); }
.ms-nav a.is-active { color: var(--brand); background: var(--brand-soft); }

.ms-head-cta { display: flex; align-items: center; gap: 10px; }
.ms-head-cta .ms-btn { padding: 11px 18px; font-size: 13px; }

.ms-burger {
  display: none; width: 42px; height: 42px; border-radius: 10px;
  border: 1px solid var(--line); background: #fff; cursor: pointer;
  align-items: center; justify-content: center; font-size: 19px; color: var(--ink);
}

/* ============================================================ HERO — PCD */

.ms-hero {
  position: relative; overflow: hidden; color: #fff;
  background: linear-gradient(135deg, var(--band) 0%, var(--band-2) 58%, var(--brand) 100%);
}
.ms-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(760px 380px at 88% 8%, rgba(255,255,255,.14), transparent 68%);
}
.ms-hero-bg { position: absolute; inset: 0; opacity: .13; object-fit: cover; width: 100%; height: 100%; mix-blend-mode: luminosity; }
.ms-hero .ms-wrap { position: relative; z-index: 2; padding-block: clamp(48px, 6vw, 84px); }
.ms-hero-grid { display: grid; grid-template-columns: 1fr 344px; gap: 40px; align-items: start; }

.ms-hero .ms-eyebrow { background: rgba(255,255,255,.14); color: #fff; }
.ms-hero h1 { font-size: clamp(30px, 4.4vw, 52px); color: #fff; margin-bottom: 16px; }
.ms-hero h1 em { font-style: italic; color: var(--accent); }
.ms-hero p { color: rgba(255,255,255,.76); font-size: 16px; max-width: 58ch; }
.ms-hero-acts { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }

.ms-hero-chips { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 26px; }
.ms-hero-chip {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; font-weight: 700; padding: 8px 14px; border-radius: 999px;
  background: rgba(255,255,255,.10); border: 1px solid rgba(255,255,255,.16); color: #fff;
}

/* inline enquiry card sitting in the hero */
.ms-quote {
  background: #fff; border-radius: var(--r); padding: 18px;
  border-top: 5px solid var(--accent);
  box-shadow: 0 26px 54px -26px rgba(0,0,0,.45); color: var(--ink);
}
.ms-quote h3 { font-size: 16.5px; margin-bottom: 2px; }
.ms-quote > p { font-size: 12px; color: var(--ink-soft); margin-bottom: 11px; }

/* ============================================================ CERT MARQUEE */

.ms-marquee { background: var(--brand); color: #fff; overflow: hidden; padding: 11px 0; }
.ms-marquee-track { display: flex; gap: 46px; width: max-content; animation: ms-scroll 34s linear infinite; }
.ms-marquee-track span { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700; white-space: nowrap; }
.ms-marquee:hover .ms-marquee-track { animation-play-state: paused; }
@keyframes ms-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ============================================================ ABOUT */

.ms-about { display: grid; grid-template-columns: 380px 1fr; gap: 48px; align-items: start; }
.ms-about-media { position: relative; }
.ms-about-media img, .ms-about-logo {
  width: 100%; aspect-ratio: 1 / 1; object-fit: contain; background: #fff;
  border: 1px solid var(--line); border-radius: var(--r); padding: 26px;
}
.ms-about-logo { display: grid; place-items: center; font-size: 56px; font-weight: 800; color: var(--brand); }
.ms-about-badge {
  position: absolute; right: -12px; bottom: -12px; background: var(--accent); color: #17140e;
  border-radius: 999px; width: 92px; height: 92px; display: grid; place-items: center; text-align: center;
  font-size: 11px; font-weight: 800; line-height: 1.25; box-shadow: var(--shadow);
}
.ms-about-badge b { display: block; font-size: 21px; }

.ms-facts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 26px; }
.ms-fact { display: flex; gap: 12px; align-items: flex-start; }
.ms-fact i {
  width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0;
  background: var(--brand-soft); color: var(--brand); font-size: 16px;
}
.ms-fact small { display: block; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }
.ms-fact b { font-size: 14px; font-weight: 700; }

/* ============================================================ STATS */

.ms-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border-radius: var(--r); overflow: hidden; }
.ms-stat { background: var(--surface); padding: 30px 22px; text-align: center; }
.ms-stat b { display: block; font-size: clamp(26px, 3.4vw, 38px); font-weight: 800; color: var(--brand); letter-spacing: -.03em; }
.ms-stat span { font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); }
.ms-sec--band .ms-stats { background: rgba(255,255,255,.14); }
.ms-sec--band .ms-stat { background: transparent; }
.ms-sec--band .ms-stat b { color: #fff; }
.ms-sec--band .ms-stat span { color: rgba(255,255,255,.62); }

/* ============================================================ CARDS */

.ms-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  padding: 24px; box-shadow: var(--shadow-sm); transition: transform .18s ease, box-shadow .18s ease;
  display: flex; flex-direction: column;
}
.ms-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.ms-card h3 { font-size: 17px; margin-bottom: 8px; }
.ms-card p { font-size: 13.5px; margin-bottom: 0; }
.ms-card-ico {
  width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand); font-size: 20px; margin-bottom: 16px;
}

/* listing card (a post) */
.ms-listing { padding: 0; overflow: hidden; }
.ms-listing-tag {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 13px 18px; border-bottom: 1px solid var(--line); background: var(--surface-2);
}
.ms-listing-tag b { font-size: 12.5px; font-weight: 800; line-height: 1.35; }
.ms-listing-pill { font-size: 9.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--brand); background: var(--brand-soft); padding: 4px 9px; border-radius: 999px; }
.ms-listing-img { aspect-ratio: 16 / 11; object-fit: cover; width: 100%; background: var(--surface-2); }
.ms-listing-body { padding: 18px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.ms-listing-body p { font-size: 13px; margin: 0; flex: 1; }
.ms-chiprow { display: flex; gap: 6px; flex-wrap: wrap; }
.ms-chip { font-size: 10.5px; font-weight: 700; padding: 5px 10px; border-radius: 7px; background: var(--brand-soft); color: var(--brand); }
.ms-chip--accent { background: color-mix(in srgb, var(--accent) 22%, #fff); color: #8a5310; }

/* product card */
.ms-prod { padding: 0; overflow: hidden; }
.ms-prod-img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; background: var(--surface-2); }
.ms-prod-body { padding: 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.ms-prod-body h3 { font-size: 15px; margin: 0; }
.ms-prod-comp { font-size: 12px; color: var(--ink-soft); line-height: 1.5; flex: 1; }
.ms-prod-meta { display: flex; gap: 12px; font-size: 11px; font-weight: 700; color: var(--ink-soft); flex-wrap: wrap; }
.ms-prod-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 10px; border-top: 1px dashed var(--line); }

/* ============================================================ DARK FEATURE BAND */

.ms-feature { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.ms-feature-cell {
  background: rgba(255, 255, 255, .09);
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: calc(var(--r) - 4px);
  padding: 24px 20px; transition: background .2s ease, transform .2s ease;
}
.ms-feature-cell:hover { background: rgba(255, 255, 255, .16); transform: translateY(-3px); }
.ms-feature-cell i { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 11px; background: rgba(255,255,255,.16); color: var(--accent); font-size: 18px; margin-bottom: 14px; }
.ms-feature-cell h3 { font-size: 15px; margin-bottom: 7px; color: #fff; }
.ms-feature-cell p { font-size: 12.5px; margin: 0; color: rgba(255,255,255,.62); }

/* ============================================================ STEPS */

.ms-steps { display: grid; gap: 18px; }
.ms-step { display: grid; grid-template-columns: 44px 1fr; gap: 16px; align-items: start; }
.ms-step-n {
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  background: var(--brand); color: #fff; font-weight: 800; font-size: 15px;
}
.ms-step h3 { font-size: 15.5px; margin-bottom: 5px; }
.ms-step p { font-size: 13px; margin: 0; }

.ms-ticks { display: grid; gap: 13px; }
.ms-tick { display: grid; grid-template-columns: 22px 1fr; gap: 12px; align-items: start; font-size: 14px; line-height: 1.6; color: var(--ink-soft); }
.ms-tick i { color: var(--brand); font-size: 15px; margin-top: 2px; }

/* ============================================================ TABLE */

.ms-tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: #fff; }
.ms-table { width: 100%; border-collapse: collapse; min-width: 620px; font-size: 13.5px; }
.ms-table th {
  text-align: left; font-size: 10.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-soft); background: var(--surface-2); padding: 13px 16px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
.ms-table td { padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: top; color: var(--ink-soft); }
.ms-table tr:last-child td { border-bottom: 0; }
.ms-table td b { color: var(--ink); font-weight: 700; }

/* ============================================================ FAQ */

.ms-faq { border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; background: #fff; }
.ms-faq details { border-bottom: 1px solid var(--line); }
.ms-faq details:last-child { border-bottom: 0; }
.ms-faq summary {
  list-style: none; cursor: pointer; padding: 18px 52px 18px 20px; position: relative;
  font-weight: 700; font-size: 14.5px; line-height: 1.5;
}
.ms-faq summary::-webkit-details-marker { display: none; }
.ms-faq summary::after {
  content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%);
  width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand); font-size: 17px; font-weight: 700;
}
.ms-faq details[open] summary::after { content: "–"; }
.ms-faq details[open] summary { color: var(--brand); }
.ms-faq-a { padding: 0 20px 18px; font-size: 13.5px; line-height: 1.75; color: var(--ink-soft); }

/* ============================================================ FORM */

.ms-form { display: grid; gap: 9px; }
.ms-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.ms-field label { display: block; font-size: 10px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; margin-bottom: 4px; color: inherit; opacity: .72; }
.ms-input, .ms-select, .ms-textarea {
  width: 100%; font: inherit; font-size: 13px; padding: 9px 11px;
  border: 1.5px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink);
  transition: border-color .16s ease, box-shadow .16s ease;
}
.ms-textarea { resize: vertical; min-height: 56px; }
.ms-input:focus, .ms-select:focus, .ms-textarea:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 18%, transparent);
}
.ms-form-note { font-size: 10.5px; opacity: .62; text-align: center; margin: 2px 0 0; line-height: 1.45; }
.ms-form .ms-btn { padding: 11px 18px; }
.ms-quote .ms-input, .ms-quote .ms-select, .ms-quote .ms-textarea { border-color: var(--line); }

.ms-alert { padding: 14px 18px; border-radius: 12px; font-size: 14px; font-weight: 600; margin-bottom: 18px; }
.ms-alert--ok { background: #E7F7EE; color: #10633C; border: 1px solid #BCE7CE; }
.ms-alert--err { background: #FDECEC; color: #96231F; border: 1px solid #F5C6C4; }

/* ============================================================ CONTACT */

.ms-contact { display: grid; grid-template-columns: 1fr 400px; gap: 44px; align-items: start; }
.ms-contact-list { display: grid; gap: 16px; margin-top: 26px; }
.ms-contact-item { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: start; }
.ms-contact-item i { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); font-size: 18px; }
.ms-contact-item small { display: block; font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 3px; }
.ms-contact-item b { font-size: 14.5px; font-weight: 700; }
.ms-contact-card { background: var(--brand-soft); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; }

/* ============================================================ FOOTER */

.ms-foot { background: linear-gradient(160deg, var(--band) 0%, var(--band-2) 130%); color: rgba(255,255,255,.72); padding: 52px 0 0; font-size: 13.5px; }
.ms-foot a { color: rgba(255,255,255,.66); }
.ms-foot a:hover { color: #fff; }
.ms-foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1.2fr 1.2fr; gap: 36px; padding-bottom: 40px; }
.ms-foot h4 { font-size: 11px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; color: #fff; margin-bottom: 16px; }
.ms-foot li { margin-bottom: 9px; line-height: 1.6; }
.ms-foot-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.ms-foot-brand .ms-brand-logo { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.14); color: #fff; }
.ms-foot-brand .ms-brand-name { color: #fff; }
.ms-foot-bottom {
  border-top: 1px solid rgba(255,255,255,.12); padding: 18px 0; font-size: 12px;
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
}
.ms-foot-badge {
  display: inline-flex; align-items: center; gap: 8px; font-size: 11.5px; font-weight: 700;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14);
  padding: 8px 13px; border-radius: 999px; color: #fff;
}

/* ============================================================ FLOATING ACTIONS */

.ms-dock { position: fixed; right: 16px; bottom: 16px; z-index: 70; display: grid; gap: 10px; }
.ms-dock a, .ms-dock button {
  width: 48px; height: 48px; border-radius: 50%; border: 0; cursor: pointer;
  display: grid; place-items: center; color: #fff; font-size: 20px;
  box-shadow: 0 10px 24px -8px rgba(0,0,0,.42); transition: transform .16s ease;
}
.ms-dock a:hover, .ms-dock button:hover { transform: scale(1.08); color: #fff; }
.ms-dock .d-wa { background: #1FA855; }
.ms-dock .d-call { background: var(--brand); }
.ms-dock .d-mail { background: var(--accent); color: #17140e; }

.ms-mobilebar { display: none; }

/* ============================================================ POPUP ENQUIRY MODAL */

.ms-modal {
  position: fixed; inset: 0; z-index: 200; display: none;
  align-items: center; justify-content: center; padding: 18px;
  background: rgba(8, 18, 16, .62); backdrop-filter: blur(4px);
}
.ms-modal.is-open { display: flex; animation: ms-fade .22s ease; }
@keyframes ms-fade { from { opacity: 0; } to { opacity: 1; } }

.ms-modal-box {
  background: #fff; border-radius: 20px; width: min(800px, 100%);
  max-height: calc(100dvh - 36px); overflow: hidden;
  display: grid; grid-template-columns: 268px 1fr;
  box-shadow: 0 40px 90px -30px rgba(0,0,0,.6);
  animation: ms-pop .26s cubic-bezier(.2, .9, .3, 1.2);
}
@keyframes ms-pop { from { transform: translateY(18px) scale(.97); opacity: 0; } to { transform: none; opacity: 1; } }

.ms-modal-side { background: linear-gradient(160deg, var(--band), var(--band-2)); color: #fff; padding: 24px 22px; display: flex; flex-direction: column; gap: 13px; }
.ms-modal-side h3 { font-size: 19px; color: #fff; }
.ms-modal-side p { color: rgba(255,255,255,.7); font-size: 13px; }
.ms-modal-side ul { display: grid; gap: 11px; margin-top: auto; }
.ms-modal-side li { display: grid; grid-template-columns: 18px 1fr; gap: 10px; font-size: 12.5px; color: rgba(255,255,255,.82); line-height: 1.5; }
.ms-modal-side li i { color: var(--accent); }

.ms-modal-main { padding: 20px; overflow-y: auto; }
.ms-modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 14px; }
.ms-modal-head h3 { font-size: 18px; margin-bottom: 3px; }
.ms-modal-head p { font-size: 13px; margin: 0; }
.ms-modal-x {
  width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--line);
  background: #fff; cursor: pointer; font-size: 18px; line-height: 1; color: var(--ink-soft); flex-shrink: 0;
}
.ms-modal-x:hover { background: var(--surface-2); color: var(--ink); }

/* ============================================================ MISC */

.ms-crumbs { font-size: 12.5px; color: var(--ink-soft); padding: 16px 0; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.ms-crumbs a { color: var(--brand); font-weight: 600; }
.ms-crumbs span.sep { opacity: .45; }

.ms-pagehead { background: var(--surface-2); border-bottom: 1px solid var(--line); padding: 0 0 34px; }
.ms-pagehead h1 { font-size: clamp(26px, 3.6vw, 40px); margin-bottom: 10px; }
.ms-pagehead p { max-width: 70ch; margin: 0; }

.ms-rich { font-size: 15px; line-height: 1.85; color: var(--ink-soft); }
.ms-rich h2 { font-size: 24px; margin: 30px 0 12px; color: var(--ink); }
.ms-rich h3 { font-size: 19px; margin: 24px 0 10px; color: var(--ink); }
.ms-rich ul, .ms-rich ol { margin: 0 0 16px; padding-left: 22px; list-style: revert; }
.ms-rich li { margin-bottom: 7px; }
.ms-rich table { width: 100%; border-collapse: collapse; margin: 18px 0; font-size: 14px; }
.ms-rich th, .ms-rich td { border: 1px solid var(--line); padding: 10px 13px; text-align: left; }
.ms-rich th { background: var(--surface-2); font-weight: 700; color: var(--ink); }
.ms-rich img { border-radius: 12px; margin: 16px 0; }
.ms-rich a { color: var(--brand); text-decoration: underline; }

.ms-side { display: grid; gap: 20px; position: sticky; top: 92px; }
.ms-side-card { border: 1px solid var(--line); border-radius: var(--r); padding: 20px; background: #fff; }
.ms-side-card h4 { font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 14px; }
.ms-side-card li { padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 13.5px; }
.ms-side-card li:last-child { border-bottom: 0; }

.ms-pager { display: flex; gap: 6px; justify-content: center; margin-top: 34px; flex-wrap: wrap; }
.ms-pager a, .ms-pager span {
  min-width: 38px; height: 38px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line);
  display: grid; place-items: center; font-size: 13px; font-weight: 700; background: #fff; color: var(--ink-soft);
}
.ms-pager .is-active { background: var(--brand); border-color: var(--brand); color: #fff; }

.ms-empty { text-align: center; padding: 60px 20px; color: var(--ink-soft); }
.ms-empty i { font-size: 38px; color: var(--line); display: block; margin-bottom: 14px; }

/* ==========================================================================
   TEMPLATE PALETTES
   --------------------------------------------------------------------------
   Both templates share ONE design — same type scale, same spacing, same
   radii, same components. The only difference between them is the colour
   set, which the layout prints as CSS variables:

     [data-tpl="pcd"]  PCD Pharma Franchise      teal / amber
     [data-tpl="tpm"]  Third Party Manufacturing indigo / gold

   Nothing structural belongs below this line — if a rule changes layout,
   typography or spacing for one template only, it is a bug.
   ========================================================================== */

/* quick-facts spec strip */
.ms-spec { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.ms-spec-cell { background: #fff; padding: 20px; }
.ms-spec-cell small { display: block; font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 7px; }
.ms-spec-cell b { font-size: 16px; font-weight: 800; }

/* numbered process rail */
.ms-rail { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0; counter-reset: rail; }
.ms-rail-node { position: relative; padding: 0 18px 0 0; }
.ms-rail-node::before {
  counter-increment: rail; content: counter(rail, decimal-leading-zero);
  font-size: 12px; font-weight: 800; color: var(--accent); letter-spacing: .1em;
}
.ms-rail-node::after {
  content: ""; display: block; height: 3px; background: var(--line); margin: 12px 0 16px;
  position: relative;
}
.ms-rail-node:hover::after { background: var(--brand); }
.ms-rail-node h3 { font-size: 15px; margin-bottom: 6px; }
.ms-rail-node p { font-size: 12.5px; margin: 0; }

/* ============================================================ RESPONSIVE */

@media (max-width: 1080px) {
  .ms-hero-grid { grid-template-columns: 1fr; }
  .ms-quote { max-width: 520px; }
  .ms-about { grid-template-columns: 1fr; gap: 30px; }
  .ms-about-media { max-width: 320px; }
  .ms-contact { grid-template-columns: 1fr; }
  .ms-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ms-feature { grid-template-columns: repeat(2, 1fr); }
  .ms-foot-grid { grid-template-columns: repeat(2, 1fr); }
  .ms-side { position: static; }
}

@media (max-width: 900px) {
  .ms-nav {
    position: fixed; inset: 0 0 0 auto; width: min(320px, 84vw); background: #fff;
    flex-direction: column; align-items: stretch; gap: 2px; padding: 84px 18px 26px;
    box-shadow: -18px 0 40px -18px rgba(0,0,0,.3); transform: translateX(100%);
    transition: transform .26s ease; z-index: 65; overflow-y: auto;
  }
  .ms-nav.is-open { transform: none; }
  .ms-nav a { padding: 13px 14px; font-size: 15px; border-bottom: 1px solid var(--line); border-radius: 0; }
  .ms-burger { display: grid; margin-left: auto; }
  .ms-head-cta { display: none; }
  .ms-stats { grid-template-columns: repeat(2, 1fr); }
  .ms-modal-box { grid-template-columns: 1fr; }
  .ms-modal-side { display: none; }
  .ms-dock { bottom: 74px; }
  .ms-mobilebar {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 68;
    background: var(--line); border-top: 1px solid var(--line);
  }
  .ms-mobilebar a, .ms-mobilebar button {
    background: #fff; border: 0; padding: 11px 6px; font: inherit; font-size: 11px; font-weight: 800;
    display: grid; gap: 4px; justify-items: center; color: var(--ink); cursor: pointer;
  }
  .ms-mobilebar i { font-size: 17px; color: var(--brand); }
  .ms-mobilebar .is-primary { background: var(--accent); }
  body.ms-has-bar { padding-bottom: 60px; }
}

@media (max-width: 640px) {
  .ms-grid--2, .ms-grid--3, .ms-grid--4 { grid-template-columns: 1fr; }
  .ms-feature { grid-template-columns: 1fr; }
  .ms-facts { grid-template-columns: 1fr; }
  .ms-form-row { grid-template-columns: 1fr; }
  .ms-foot-grid { grid-template-columns: 1fr; gap: 26px; }
  .ms-top .ms-wrap { justify-content: center; }
  .ms-stats { grid-template-columns: 1fr 1fr; }
  .ms-hero .ms-wrap { padding-block: 38px; }
}

/* ==========================================================================
   RESPONSIVE FIXES v4 — dono templates (pcd + tpm), saare pages + popup form
   ========================================================================== */

/* page kabhi side-scroll nahi hona chahiye (marquee / off-canvas nav ki wajah se) */
html, body.ms { overflow-x: clip; max-width: 100%; }
.ms main { overflow-x: clip; }
.ms h1, .ms h2, .ms h3, .ms p, .ms li, .ms td, .ms b { overflow-wrap: anywhere; }
.ms-rich { overflow-wrap: anywhere; }
.ms-rich img, .ms-rich iframe, .ms-rich video { max-width: 100%; height: auto; }
.ms-rich iframe { aspect-ratio: 16 / 9; width: 100%; }
.ms-rich table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* brand block can shrink — lamba company name ab header ko bahar nahi dhakelta */
.ms-brand { min-width: 0; flex-shrink: 1; }
.ms-brand > span:last-child { min-width: 0; display: flex; flex-direction: column; }
.ms-brand-name, .ms-brand-sub { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* product / post page: content + sidebar */
.ms-split { grid-template-columns: minmax(0, 1fr) 380px; gap: 44px; align-items: start; }
.ms-spec-th { width: 190px; }

/* mobile nav extras — desktop par hidden */
.ms-nav-backdrop, .ms-nav-close, .ms-nav-cta { display: none; }

@media (max-width: 1080px) {
  .ms-split { grid-template-columns: minmax(0, 1fr); gap: 30px; }
  .ms-split > aside, .ms-split .ms-side { position: static; }
}

@media (max-width: 900px) {
  .ms-head .ms-wrap { min-height: 62px; gap: 12px; }
  .ms-brand-logo { width: 40px; height: 40px; border-radius: 10px; }
  .ms-brand-name { font-size: 15px; }
  .ms-burger { flex-shrink: 0; }

  /* off-canvas nav: band hone par poori tarah hidden (side overflow nahi banata) */
  .ms-nav { visibility: hidden; padding-top: 76px; z-index: 90; }
  .ms-nav.is-open { visibility: visible; }
  .ms-nav-close {
    display: grid; place-items: center; position: absolute; top: 16px; right: 16px; width: 40px; height: 40px; border-radius: 10px;
    border: 1px solid var(--line); background: #fff; font-size: 22px; line-height: 1; cursor: pointer; color: var(--ink);
  }
  .ms-nav-cta { display: grid; gap: 10px; margin-top: 18px; }
  .ms-nav-cta .ms-btn { width: 100%; padding: 13px 16px; }
  .ms-nav-backdrop {
    display: block; position: fixed; inset: 0; z-index: 85; background: rgba(8, 18, 16, .5);
    opacity: 0; visibility: hidden; transition: opacity .2s ease;
  }
  .ms-nav-backdrop.is-open { opacity: 1; visibility: visible; }
  body.ms-lock { overflow: hidden; }

  /* section heads + hero */
  .ms-hero-grid { gap: 28px; }
  .ms-quote { max-width: none; }
  .ms-hero-acts .ms-btn { flex: 1 1 auto; }
  .ms-about-media { max-width: 280px; margin-inline: auto; }
  .ms-about-badge { right: -6px; bottom: -6px; width: 80px; height: 80px; }
  .ms-contact-card { padding: 16px; }

  /* dock + mobile bar ek doosre ke upar na aayein */
  .ms-dock { display: none; }
  .ms-mobilebar { padding-bottom: env(safe-area-inset-bottom); }
  body.ms-has-bar { padding-bottom: calc(62px + env(safe-area-inset-bottom)); }

  /* ---------- popup form → bottom sheet ---------- */
  .ms-modal { padding: 0; align-items: flex-end; }
  .ms-modal-box {
    width: 100%; max-width: 100%; border-radius: 18px 18px 0 0;
    max-height: 92dvh; display: flex; flex-direction: column;
    animation: ms-sheet .26s ease;
  }
  @keyframes ms-sheet { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
  .ms-modal-main { padding: 0 16px calc(16px + env(safe-area-inset-bottom)); overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; flex: 1; }
  .ms-modal-head {
    position: sticky; top: 0; z-index: 2; background: #fff;
    padding: 16px 0 12px; margin-bottom: 8px; border-bottom: 1px solid var(--line);
  }
  .ms-modal-head h3 { font-size: 17px; }
  .ms-modal-head p { font-size: 12.5px; }
  .ms-modal-x { width: 38px; height: 38px; font-size: 22px; }
}

@media (max-width: 640px) {
  .ms-wrap { padding-inline: 16px; }
  .ms-top { font-size: 11px; }
  .ms-top .ms-wrap { min-height: 32px; padding-block: 6px; gap: 6px 14px; }
  .ms-top .ms-top-list:last-child { display: none; }       /* email / back link → footer + menu mein hai */
  .ms-top-list { gap: 6px 14px; justify-content: center; }

  .ms-brand-sub { font-size: 9px; letter-spacing: .1em; }
  .ms-sec { padding: 46px 0; }
  .ms-h2 { font-size: clamp(23px, 6.4vw, 30px); }
  .ms-lede { font-size: 14.5px; }
  .ms-hero h1 { font-size: clamp(27px, 8vw, 34px); }
  .ms-hero p { font-size: 14.5px; }
  .ms-hero-acts { flex-direction: column; }
  .ms-hero-acts .ms-btn { width: 100%; }
  .ms-hero-chip { font-size: 11px; padding: 7px 11px; }
  .ms-btn { white-space: normal; text-align: center; line-height: 1.25; }

  .ms-card { padding: 18px; }
  .ms-stat { padding: 20px 10px; }
  .ms-stat span { font-size: 10px; letter-spacing: .08em; }
  .ms-spec { grid-template-columns: 1fr 1fr; }
  .ms-spec-cell { padding: 14px; }
  .ms-spec-cell b { font-size: 14px; }
  .ms-rail { grid-template-columns: 1fr; gap: 6px; }
  .ms-rail-node { padding: 0; }
  .ms-rail-node::after { margin: 8px 0 10px; }

  .ms-table { font-size: 12.5px; }
  .ms-table th, .ms-table td { padding: 11px 12px; }
  .ms-spec-th { width: 38%; }
  .ms-faq summary { padding: 15px 48px 15px 16px; font-size: 14px; }
  .ms-faq-a { padding: 0 16px 16px; }

  .ms-pagehead { padding-bottom: 24px; }
  .ms-rich { font-size: 14.5px; line-height: 1.75; }
  .ms-rich h2 { font-size: 20px; }
  .ms-rich h3 { font-size: 17px; }
  .ms-side-card { padding: 16px; }
  .ms-foot { padding-top: 38px; }
  .ms-foot-bottom { justify-content: center; text-align: center; }

  /* inputs 16px → iOS zoom-in nahi karta; tap target bade */
  .ms-input, .ms-select, .ms-textarea { font-size: 16px; padding: 11px 12px; }
  .ms-form { gap: 10px; }
  .ms-form-row { gap: 10px; }
  .ms-form .ms-btn { padding: 14px 18px; font-size: 14.5px; }
  .ms-modal-box { max-height: 94dvh; }
}

@media (max-width: 380px) {
  .ms-stats, .ms-spec { grid-template-columns: 1fr; }
  .ms-brand-sub { display: none; }
  .ms-mobilebar a, .ms-mobilebar button { font-size: 10.5px; }
}
body.ms-modal-open { overflow: hidden; }
@media (max-width: 900px) { .ms-nav-cta { display: grid; } }
@media (max-width: 900px) {
  .ms-nav .ms-nav-cta .ms-btn { border-radius: calc(var(--r) - 8px); border: 1.5px solid transparent; font-size: 14px; padding: 13px 16px; }
  .ms-nav .ms-nav-cta .ms-btn--outline { border-color: var(--brand-soft); color: var(--brand); }
  .ms-nav .ms-nav-cta .ms-btn--outline:hover { border-color: var(--brand); }
}
/* backdrop-filter fixed children (off-canvas nav) ka containing block ban jaata tha
   → menu header ke andar hi clip ho raha tha. Mobile par solid header. */
@media (max-width: 900px) {
  .ms-head { backdrop-filter: none; -webkit-backdrop-filter: none; background: #fff; }
  body.ms-lock .ms-head { z-index: 95; }
}
@media (max-width: 900px) {
  .ms-nav { transition: transform .26s ease, visibility 0s linear .26s; }
  .ms-nav.is-open { transition: transform .26s ease, visibility 0s; }
}
