/* COMELAB PHARM — mobile UX layer */
@media (max-width:980px){
  html,body{overflow-x:hidden}
  body{font-size:15px}
  .cn-shell{width:min(100% - 32px,1240px)}

  /* Header / mobile menu */
  .cn-header{position:sticky;top:0;z-index:100;background:rgba(255,255,255,.98);box-shadow:0 1px 0 rgba(15,45,74,.06)}
  .cn-header__bar{height:68px;gap:14px}
  .cn-brand--text{min-width:0}
  .cn-brand__main{font-size:23px;line-height:.9}
  .cn-brand__sub{font-size:8px;letter-spacing:.34em;margin-top:5px}
  .cn-menu-toggle{display:grid;place-items:center;width:46px;height:46px;flex:0 0 46px;border:1px solid #e5d7c2;border-radius:13px;background:#fff;color:var(--cp-navy)}
  .cn-mobile-nav{padding:6px 0 14px;background:#fff;border-top:1px solid #f0e7da;border-bottom:1px solid #eadfcf;box-shadow:0 16px 34px rgba(15,45,74,.08)}
  .cn-mobile-nav .cn-shell{display:grid;gap:3px}
  .cn-mobile-nav a{display:flex;align-items:center;min-height:48px;padding:0 14px;border-radius:11px;color:var(--cp-navy);font-size:14px;font-weight:650;text-decoration:none}
  .cn-mobile-nav a:hover,.cn-mobile-nav a:focus{background:#fbf6ed}
  .cn-mobile-nav a:nth-child(3){margin-top:5px;background:var(--cp-gold);color:#fff}

  /* Shared touch targets */
  .cn-btn,.cn-woo .button,.cn-woo button.button,.cn-woo input.button,
  .cn-b2b-panel #wp-submit,.cn-b2b-commerce-page .wc-block-components-button,
  .cn-b2b-commerce-page #place_order,.cn-b2b-commerce-page .checkout-button{
    min-height:48px!important;
  }

  /* Home hero */
  .cp-hero__grid{grid-template-columns:1fr;min-height:auto;gap:26px;padding-block:48px 34px}
  .cp-hero__copy{max-width:none}
  .cp-hero h1{max-width:760px;font-size:clamp(38px,7vw,52px);line-height:1.04;letter-spacing:-.035em;margin:14px 0 16px}
  .cp-hero p{max-width:680px;font-size:16px;line-height:1.6}
  .cp-actions{gap:10px;margin-top:22px}
  .cp-hero__art{min-height:280px}
  .cp-hero__art svg{max-width:390px}
  .cp-kicker{font-size:10px;letter-spacing:.17em}

  /* Sections */
  .cp-categories{padding:54px 0 44px}
  .cp-section-head{align-items:flex-start;gap:14px}
  .cp-section-head h2,.cp-professional h2,.cp-about h2{font-size:34px}
  .cp-category-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
  .cp-category{min-height:132px;padding:17px;border-radius:15px}
  .cp-category strong{font-size:14px}
  .cp-benefits__grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:0}
  .cp-benefit{min-height:76px;padding:14px 12px;border-bottom:1px solid #eee4d6}
  .cp-benefit:nth-child(2n){border-right:0}
  .cp-professional{padding:56px 0}
  .cp-professional__grid,.cp-about__grid{grid-template-columns:1fr;gap:26px}
  .cp-professional__actions{justify-content:flex-start}
  .cp-about{padding:58px 0 66px}

  /* Generic inner pages */
  .cn-subhero{padding:42px 0 34px}
  .cn-subhero__inner{max-width:none}
  .cn-subhero h1{font-size:clamp(34px,7vw,46px);line-height:1.06}
  .cn-subhero .cn-lede{font-size:14px;line-height:1.65}
  .cn-section{padding:58px 0}
  .cn-heading-row{display:block;margin-bottom:28px}
  .cn-heading-row h2{font-size:40px}
  .cn-heading-row p{margin-top:12px}

  /* Catalogue */
  .cn-catalog-pro-banner{display:grid;gap:12px;padding:16px}
  .cn-catalog-pro-banner a{justify-self:start}
  .cn-catalog-filters{
    display:flex!important;
    flex-wrap:nowrap!important;
    gap:8px;
    margin:0 -16px 16px;
    padding:0 16px 5px;
    overflow-x:auto;
    scroll-snap-type:x proximity;
    -webkit-overflow-scrolling:touch;
    scrollbar-width:none;
  }
  .cn-catalog-filters::-webkit-scrollbar{display:none}
  .cn-catalog-filters a{flex:0 0 auto;min-height:40px;display:inline-flex;align-items:center;scroll-snap-align:start;white-space:nowrap}
  .cn-catalog-search{display:grid;grid-template-columns:1fr auto;gap:8px;max-width:none;margin-bottom:22px}
  .cn-catalog-search input[type="search"]{min-width:0;min-height:48px;font-size:16px}
  .cn-catalog-search .cn-btn{padding-inline:17px}

  .cn-product-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
  .cn-product-card{border-radius:14px}
  .cn-product-card__image{padding:10px;aspect-ratio:1/1}
  .cn-product-card__body{padding:12px}
  .cn-product-card__kicker{font-size:8px;letter-spacing:.08em}
  .cn-product-card h3{min-height:0;font-size:14px;line-height:1.25;margin:6px 0 9px}
  .cn-product-card__pro-price{font-size:12px}
  .cn-product-card .cn-btn,.cn-product-card .button{width:100%;min-height:42px!important;padding:0 8px!important;font-size:10px!important}

  /* WooCommerce */
  .cn-woo div.product{display:block}
  .cn-woo div.product .product_title{font-size:34px;line-height:1.08}
  .cn-woo div.product div.images,.cn-woo div.product div.summary{width:100%!important;float:none!important}
  .cn-woo div.product div.summary{margin-top:24px}
  .cn-woo div.product form.cart{display:grid;gap:10px}
  .cn-woo div.product form.cart .quantity,
  .cn-woo div.product form.cart .single_add_to_cart_button{width:100%!important}
  .cn-woo div.product form.cart .qty{width:100%;min-height:48px}
  .cn-woo ul.products{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important}
  .cn-woo ul.products li.product{width:auto!important;margin:0!important}

  /* B2B / account */
  .cn-b2b-auth-grid{grid-template-columns:1fr;gap:14px}
  .cn-b2b-panel,.cn-b2b-state,.cn-b2b-dashboard__head{padding:22px;border-radius:15px}
  .cn-b2b-panel h2,.cn-b2b-dashboard h2,.cn-b2b-state h2{font-size:30px}
  .cn-b2b-benefits{display:flex;overflow-x:auto;flex-wrap:nowrap;padding-bottom:4px;scrollbar-width:none}
  .cn-b2b-benefits::-webkit-scrollbar{display:none}
  .cn-b2b-benefits span{flex:0 0 auto;white-space:nowrap}
  .cn-b2b-form__row{grid-template-columns:1fr}
  .cn-b2b-form input,.cn-b2b-form select,
  .cn-b2b-panel input[type="text"],.cn-b2b-panel input[type="password"],
  .cn-b2b-panel input[type="email"],.cn-b2b-panel input[type="tel"]{
    min-height:50px;
    font-size:16px!important;
  }
  .cn-b2b-panel #wp-submit,.cn-b2b-form .cn-btn{width:100%}
  .cn-b2b-panel .login-remember{margin:10px 0 14px}
  .cn-b2b-login-help{margin-top:14px}
  .cn-b2b-auth-grid--single{display:block}
  .cn-quick-order{overflow:hidden}
  .cn-quick-order__head,.cn-quick-order__footer{align-items:flex-start;flex-direction:column;gap:10px}
  .cn-quick-order__table{display:block;overflow-x:auto;-webkit-overflow-scrolling:touch}
  .cn-quick-order__table table{min-width:680px}

  /* Rewards */
  .cr-summary,.cr-bottom{grid-template-columns:1fr}
  .cr-rewards{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
  .cr-card{min-height:210px;padding:16px}
  .cr-card .cn-btn{width:100%}
  .cr-history__list>div,.cr-request{align-items:flex-start}

  /* Footer */
  .cn-footer--clean .cn-footer__top,.cn-footer__top{grid-template-columns:repeat(2,minmax(0,1fr));gap:28px 20px;padding:44px 0 34px}
  .cn-footer__bottom{display:block;line-height:1.8}
}

@media (max-width:640px){
  .cn-shell{width:min(100% - 24px,1240px)}

  /* Header */
  .cn-header__bar{height:64px}
  .cn-brand__main{font-size:21px}
  .cn-brand__sub{font-size:7px}
  .cn-menu-toggle{width:44px;height:44px;flex-basis:44px}

  /* Home */
  .cp-hero__grid{padding-block:38px 24px;gap:18px}
  .cp-hero h1{font-size:36px;line-height:1.06;margin:12px 0 14px}
  .cp-hero p{font-size:14.5px;line-height:1.58}
  .cp-actions{display:grid;grid-template-columns:1fr;margin-top:20px}
  .cp-actions .cn-btn{width:100%;min-height:50px}
  .cp-hero__art{min-height:200px}
  .cp-hero__art svg{max-width:280px}
  .cp-categories{padding:44px 0 36px}
  .cp-section-head{flex-direction:column}
  .cp-section-head h2,.cp-professional h2,.cp-about h2{font-size:30px}
  .cp-category-grid{gap:8px}
  .cp-category{min-height:118px;padding:14px;border-radius:13px}
  .cp-category__icon{width:32px;height:32px;border-radius:9px;font-size:17px}
  .cp-category strong{font-size:12.5px;line-height:1.25}
  .cp-category>span:last-child{font-size:10px}
  .cp-benefits{padding:0}
  .cp-benefit{min-height:78px;padding:13px 10px}
  .cp-benefit>span{width:34px;height:34px;font-size:15px}
  .cp-benefit strong{font-size:11.5px}
  .cp-benefit small{font-size:9.5px}
  .cp-professional{padding:46px 0}
  .cp-professional__actions{display:grid;width:100%;gap:12px}
  .cp-professional__actions .cn-btn{width:100%}
  .cp-about{padding:46px 0 54px}

  /* Inner */
  .cn-subhero{padding:34px 0 28px}
  .cn-subhero h1{font-size:32px}
  .cn-subhero .cn-lede{font-size:13px}
  .cn-section{padding:46px 0}
  .cn-heading-row h2{font-size:34px}

  /* Catalogue */
  .cn-catalog-pro-banner{font-size:12px}
  .cn-catalog-search{grid-template-columns:1fr}
  .cn-catalog-search .cn-btn{width:100%}
  .cn-product-grid{gap:8px}
  .cn-product-card__image{padding:8px}
  .cn-product-card__body{padding:10px}
  .cn-product-card h3{font-size:13px}
  .cn-product-card__pro-price{font-size:11px}
  .cn-product-card .cn-btn,.cn-product-card .button{font-size:9.5px!important}

  /* B2B */
  .cn-b2b-panel,.cn-b2b-state,.cn-b2b-dashboard__head{padding:18px;border-radius:14px}
  .cn-b2b-panel h2,.cn-b2b-dashboard h2,.cn-b2b-state h2{font-size:27px}
  .cn-b2b-form{gap:11px}
  .cn-b2b-notice{font-size:12px;line-height:1.55}
  .cn-pro-grid{padding:50px 0}
  .cn-pro-grid h2{font-size:34px}

  /* Cart / checkout */
  .cn-b2b-commerce-page{padding-top:24px}
  .cn-b2b-commerce-page .woocommerce-billing-fields,
  .cn-b2b-commerce-page .woocommerce-additional-fields{padding:14px}
  .cn-b2b-commerce-page input,.cn-b2b-commerce-page select,.cn-b2b-commerce-page textarea{
    font-size:16px!important;
  }
  .cn-b2b-commerce-page #place_order,.cn-b2b-commerce-page .checkout-button{width:100%!important;min-height:52px!important}

  /* Rewards */
  .cr-balance,.cr-how,.cr-history,.cr-requests{padding:16px}
  .cr-rewards{grid-template-columns:1fr}
  .cr-card{min-height:auto;padding:16px}
  .cr-section-head{align-items:flex-start;flex-direction:column;gap:6px}
  .cr-balance__row{align-items:flex-start;flex-direction:column;gap:9px}
  .cr-balance__row>strong{font-size:30px}

  /* Footer */
  .cn-footer--clean .cn-footer__top,.cn-footer__top{grid-template-columns:1fr;gap:24px;padding-top:38px}
}

@media (max-width:380px){
  .cn-shell{width:min(100% - 20px,1240px)}
  .cp-hero h1{font-size:33px}
  .cp-category{min-height:112px;padding:12px}
  .cp-category strong{font-size:12px}
  .cn-product-card h3{font-size:12.5px}
  .cn-product-card__body{padding:9px}
}
