/* Khayrat Al Jazeera V8 mobile/tablet UI. Desktop >=1024px is intentionally untouched. */
:root {
  --color-primary: #F2790A;
  --color-primary-dark: #D9660A;
  --color-primary-tint: #FFF1E1;
  --color-secondary: #5FA746;
  --color-secondary-dark: #4C8B37;
  --color-secondary-tint: #EFF7EA;
  --color-price: #EA580C;
  --color-dark: #16223A;
  --color-dark-2: #1E2E4D;
  --color-danger: #DC2626;
  --color-text: #1F2937;
  --color-text-muted: #667085;
  --color-border: #E6E8EC;
  --color-surface: #FFFFFF;
  --color-surface-tint: #F3F8EE;
  --color-focus: #1D4ED8;
  --font-base: 'Rubik', 'Cairo', 'Tajawal', system-ui, -apple-system, sans-serif;
  --fs-xs: 0.75rem;
  --fs-sm: 0.8125rem;
  --fs-base: 0.9375rem;
  --fs-md: 1.0625rem;
  --fs-lg: 1.25rem;
  --lh-tight: 1.25;
  --lh-normal: 1.6;
  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 16px;
  --sp-5: 20px;
  --sp-6: 24px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 999px;
  --shadow-card: 0 2px 10px rgba(20, 30, 20, 0.07);
  --shadow-elevated: 0 8px 24px rgba(20, 30, 20, 0.14);
  --shadow-nav: 0 -2px 12px rgba(20, 30, 20, 0.08);
  --header-h: 64px;
  --tabbar-h: 62px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --touch-target: 44px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --dur: 220ms;
}

.mobile-shell,
.mobile-home-hero,
.mobile-home-feed,
.mobile-products-screen,
.related-products-mobile,
.product-card--v8 {
  display: none;
}

.desktop-home-only {
  display: contents;
}

@media (prefers-reduced-motion: reduce) {
  @media (max-width: 1023px) {
    * {
      animation-duration: 0.01ms !important;
      animation-iteration-count: 1 !important;
      transition-duration: 0.01ms !important;
      scroll-behavior: auto !important;
    }
  }
}

@media (max-width: 1023px) {
  html {
    -webkit-text-size-adjust: 100%;
  }

  body {
    background: var(--color-surface);
    padding-top: var(--header-h);
    padding-bottom: calc(var(--tabbar-h) + var(--safe-bottom));
    font-family: var(--font-base);
    overflow-x: hidden;
  }

  img {
    max-width: 100%;
  }

  :focus-visible {
    outline: 3px solid var(--color-focus);
    outline-offset: 2px;
    border-radius: 4px;
  }

  .gheader,
  .gshop-hero,
  .gshop-footer,
  .footer-curve,
  .site-footer,
  .footer-section,
  .mobile-toolbar,
  .scroll-top-btn {
    display: none !important;
  }

  .mobile-shell {
    display: block;
    max-width: 760px;
    margin: 0 auto;
    background: #fff;
    min-height: 0;
    height: 0;
  }

  .mobile-home-hero {
    display: block;
    max-width: 760px;
    margin: 0 auto;
    background: #fff;
  }

  .mobile-home-feed {
    display: block;
    max-width: 760px;
    margin: 0 auto;
    background: #fff;
    padding-bottom: 18px;
  }

  .mobile-products-screen {
    display: block;
    max-width: 760px;
    margin: 0 auto;
    background: #fff;
  }

  .screen-head {
    padding: 16px 16px 6px;
  }

  .screen-head h1 {
    margin: 0;
    font-size: 22px;
    line-height: 1.25;
    font-weight: 900;
    color: var(--color-text);
  }

  .screen-head p {
    margin: 3px 0 0;
    color: var(--color-text-muted);
    font-size: 12px;
    line-height: 1.5;
  }

  .mobile-search-panel {
    padding-top: 10px;
    padding-bottom: 8px;
  }

  .search-field {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: var(--touch-target);
    padding: 0 14px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-pill);
    background: var(--color-surface-tint);
  }

  .search-field .ui-icon {
    width: 19px;
    height: 19px;
    color: #8c96a3;
    flex: 0 0 auto;
  }

  .search-field input {
    flex: 1;
    min-width: 0;
    min-height: var(--touch-target);
    border: 0;
    background: transparent;
    color: var(--color-text);
    font: 700 13px/1 var(--font-base);
  }

  .search-field input:focus {
    outline: 0;
  }

  .mobile-filter-panel {
    padding-top: 0;
    padding-bottom: 10px;
  }

  .filter-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }

  .filter-tabs::-webkit-scrollbar {
    display: none;
  }

  .filter-tab {
    min-height: 38px;
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 14px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-pill);
    background: #fff;
    color: var(--color-text);
    font-size: 12px;
    line-height: 1;
    font-weight: 900;
  }

  .filter-tab[aria-selected="true"] {
    border-color: var(--color-primary);
    background: var(--color-primary);
    color: #fff;
  }

  .desktop-home-only {
    display: none !important;
  }

  .home-intro {
    padding: 12px 16px 2px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
  }

  .home-intro__copy {
    min-width: 0;
  }

  .home-intro__copy h1 {
    margin: 0;
    color: var(--color-text);
    font-size: 17px;
    line-height: 1.35;
    font-weight: 900;
  }

  .home-intro__copy p {
    margin: 2px 0 0;
    color: var(--color-text-muted);
    font-size: 11px;
    line-height: 1.55;
  }

  .home-intro__pill {
    flex: 0 0 auto;
    border-radius: var(--radius-pill);
    padding: 6px 10px;
    background: var(--color-secondary-tint);
    color: var(--color-secondary-dark);
    font-size: 10px;
    font-weight: 900;
  }

  .search-stub {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    width: calc(100% - 32px);
    margin: 8px 16px 0;
    min-height: var(--touch-target);
    background: var(--color-surface-tint);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-pill);
    padding: 0 var(--sp-4);
    color: var(--color-text-muted);
    font-size: var(--fs-sm);
    font-family: inherit;
  }

  .search-stub .ui-icon {
    width: 19px;
    height: 19px;
    color: #8c96a3;
    flex: 0 0 auto;
  }

  .home-primary-promo {
    padding: 14px 16px 4px;
  }

  .promo-banner {
    min-height: 132px;
    padding: 17px 18px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-3);
    overflow: hidden;
    color: #fff;
  }

  .promo-banner--orange {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  }

  .promo-banner__tag {
    display: inline-block;
    background: rgba(255,255,255,.2);
    padding: 2px 10px;
    border-radius: var(--radius-pill);
    font-size: 11px;
    font-weight: 700;
    margin-bottom: var(--sp-2);
  }

  .promo-banner h3 {
    margin: 0 0 var(--sp-1);
    font-size: 16px;
    line-height: 1.4;
    font-weight: 800;
  }

  .promo-banner p {
    margin: 0 0 10px;
    max-width: 210px;
    font-size: var(--fs-xs);
    line-height: 1.6;
    opacity: .9;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
  }

  .promo-banner .btn {
    min-height: 38px;
    padding: 8px 14px;
    border: 0;
    background: #fff;
    color: var(--color-primary-dark);
    font-size: 12px;
    font-weight: 900;
  }

  .promo-banner__media {
    width: 86px;
    height: 86px;
    flex: 0 0 86px;
    display: grid;
    place-items: center;
  }

  .promo-banner__media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 8px 18px rgba(0,0,0,.18));
  }

  .m-hero {
    margin: 14px 16px 0;
    padding: 18px 18px 20px;
    border-radius: 22px;
    background: linear-gradient(180deg, var(--color-secondary-tint), #fff 78%);
    border: 1px solid #e8f1e4;
    overflow: hidden;
  }

  .m-hero__eyebrow {
    margin: 0 0 4px;
    color: var(--color-primary);
    font-size: 12px;
    line-height: 1.45;
    font-weight: 800;
  }

  .m-hero h1 {
    margin: 0 0 7px;
    color: var(--color-text);
    font-size: 24px;
    line-height: 1.2;
    font-weight: 900;
  }

  .m-hero p {
    margin: 0 0 14px;
    color: var(--color-text-muted);
    font-size: 12px;
    line-height: 1.7;
  }

  .m-hero__actions {
    display: flex;
    gap: 8px;
  }

  .m-hero__actions .btn {
    flex: 1;
    min-height: 40px;
    padding: 9px 12px;
    font-size: 12px;
    border-radius: var(--radius-pill);
  }

  .m-hero__media {
    height: 94px;
    margin-top: 12px;
    display: grid;
    place-items: center;
  }

  .m-hero__media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 10px 20px rgba(38,58,31,.16));
  }

  .deal-card {
    background: linear-gradient(135deg, var(--color-dark-2, #1E2E4D), var(--color-dark, #16223A));
    color: #fff;
    border-radius: 20px;
    padding: 18px;
    margin-bottom: 12px;
  }

  .deal-card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
  }

  .deal-card__head h3 {
    margin: 0;
    font-size: 16px;
    line-height: 1.4;
    font-weight: 900;
  }

  .deal-card__date {
    display: inline-block;
    margin-top: 10px;
    color: rgba(255,255,255,.72);
    font-size: 11px;
    font-weight: 800;
  }

  .countdown {
    display: flex;
    gap: 8px;
  }

  .countdown__unit {
    min-width: 52px;
    padding: 8px 5px;
    border-radius: 12px;
    background: rgba(255,255,255,.12);
    text-align: center;
  }

  .countdown__unit strong {
    display: block;
    font-size: 15px;
    line-height: 1;
    font-weight: 900;
    font-variant-numeric: tabular-nums;
  }

  .countdown__unit span {
    display: block;
    margin-top: 4px;
    font-size: 9px;
    color: rgba(255,255,255,.78);
    white-space: nowrap;
  }

  .trust-strip {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border-radius: 18px;
    background: var(--color-surface-tint);
    border: 1px solid #e7efdf;
  }

  .trust-strip__score {
    flex: 0 0 auto;
    color: var(--color-primary);
    font-size: 18px;
    line-height: 1;
    font-weight: 900;
  }

  .trust-strip p {
    margin: 0;
    min-width: 0;
    color: var(--color-text-muted);
    font-size: 12px;
    line-height: 1.65;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
  }

  .mobile-shell .ui-icon {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .app-header {
    position: fixed;
    top: 0;
    inset-inline: 0;
    z-index: 90;
    min-height: 64px;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: rgba(255, 255, 255, .96);
    backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--color-border);
    max-width: 760px;
    margin: 0 auto;
  }

  .app-header__btn {
    width: var(--touch-target);
    height: var(--touch-target);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: #fff;
    color: var(--color-text);
    display: grid;
    place-items: center;
    cursor: pointer;
    padding: 0;
  }

  .app-header__logo {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1px;
    color: var(--color-text);
    line-height: 1.15;
  }

  .app-header__brand {
    font-size: 14px;
    font-weight: 900;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .app-header__delivery {
    border: 0;
    background: transparent;
    padding: 0;
    color: var(--color-text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
    font-family: inherit;
    font-size: 11px;
    font-weight: 700;
    max-width: 210px;
    cursor: pointer;
  }

  .app-header__delivery .ui-icon {
    width: 14px;
    height: 14px;
    color: var(--color-secondary-dark);
    flex: 0 0 auto;
  }

  .app-header__cart {
    position: relative;
  }

  .app-header__cart-badge,
  .app-tabbar__badge {
    position: absolute;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: var(--radius-pill);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--color-primary);
    color: #fff;
    font-size: 10px;
    font-weight: 900;
    line-height: 1;
  }

  .app-header__cart-badge {
    top: -5px;
    inset-inline-start: -5px;
    border: 2px solid #fff;
  }

  .app-drawer {
    position: fixed;
    inset: 0;
    z-index: 140;
    visibility: hidden;
    pointer-events: none;
  }

  .app-drawer.is-open {
    visibility: visible;
    pointer-events: auto;
  }

  .app-drawer__scrim {
    position: absolute;
    inset: 0;
    background: rgba(17, 24, 39, .42);
    opacity: 0;
    backdrop-filter: blur(2px);
    transition: opacity var(--dur) var(--ease);
  }

  .app-drawer.is-open .app-drawer__scrim {
    opacity: 1;
  }

  .app-drawer__panel {
    position: absolute;
    top: 0;
    right: 0;
    width: min(86vw, 380px);
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #fbfcfa;
    border-radius: 24px 0 0 24px;
    overflow: hidden;
    transform: translateX(100%);
    transition: transform var(--dur) var(--ease);
    box-shadow: var(--shadow-elevated);
  }

  .app-drawer.is-open .app-drawer__panel {
    transform: translateX(0);
  }

  .app-drawer__head {
    padding: 18px 16px;
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #fff;
    background: linear-gradient(135deg, var(--color-secondary), var(--color-primary));
  }

  .app-drawer__brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    font-size: 17px;
  }

  .app-drawer__brand-mark {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    object-fit: contain;
    background: rgba(255, 255, 255, .18);
  }

  .app-drawer__close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,.2);
    color: #fff;
    border: 0;
    display: grid;
    place-items: center;
    cursor: pointer;
  }

  .app-drawer__body {
    padding: 18px 16px 28px;
    overflow-y: auto;
    flex: 1;
  }

  .app-drawer__section {
    background: #fff;
    border: 1px solid #edf0ea;
    border-radius: 18px;
    overflow: hidden;
    margin-bottom: var(--sp-4);
    box-shadow: 0 1px 0 rgba(17,24,39,.03);
  }

  .app-drawer__label {
    display: block;
    padding: 12px 14px 8px;
    font-size: var(--fs-xs);
    font-weight: 900;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: .04em;
  }

  .app-drawer__link {
    min-height: 50px;
    padding: 11px 14px;
    display: flex;
    align-items: center;
    gap: 11px;
    border: 0;
    background: #fff;
    color: var(--color-text);
    font: 800 13px/1.4 var(--font-base);
    width: 100%;
    text-align: start;
  }

  .app-drawer__link + .app-drawer__link {
    border-top: 1px solid #f0f2ef;
  }

  .drawer-link__icon,
  .account-action__icon {
    width: 34px;
    height: 34px;
    border-radius: 11px;
    background: var(--color-primary-tint);
    color: var(--color-primary);
    display: grid;
    place-items: center;
    flex: 0 0 auto;
  }

  .drawer-link__icon--green,
  .account-action__icon--green {
    background: var(--color-secondary-tint);
    color: var(--color-secondary-dark);
  }

  .account-action__icon--neutral {
    background: #f2f4f7;
    color: #667085;
  }

  .drawer-link__text,
  .account-action__label {
    flex: 1;
    min-width: 0;
  }

  .drawer-link__chevron,
  .account-action__chevron,
  .account-support__chevron {
    width: 17px;
    height: 17px;
    color: #a7aeb8;
  }

  .app-drawer__contact {
    padding: var(--sp-4);
    background: var(--color-surface-tint);
    border-radius: var(--radius-md);
    font-size: var(--fs-sm);
    color: var(--color-text-muted);
    line-height: 1.8;
  }

  .app-drawer__contact strong {
    color: var(--color-text);
    display: block;
    margin-bottom: 2px;
  }

  .app-tabbar {
    position: fixed;
    bottom: 0;
    inset-inline: 0;
    z-index: 100;
    height: calc(66px + var(--safe-bottom));
    padding: 0 8px var(--safe-bottom);
    display: flex;
    align-items: stretch;
    justify-content: space-around;
    background: rgba(255,255,255,.98);
    border-top: 1px solid var(--color-border);
    border-radius: 18px 18px 0 0;
    box-shadow: var(--shadow-nav);
  }

  .app-tabbar__item {
    position: relative;
    min-width: 58px;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    border: 0;
    background: transparent;
    color: var(--color-text-muted);
    font: 800 10px/1.2 var(--font-base);
    cursor: pointer;
    transition: color var(--dur) var(--ease), transform var(--dur) var(--ease);
  }

  .app-tabbar__item:active {
    transform: scale(.96);
  }

  .app-tabbar__item[aria-current="page"] {
    color: var(--color-primary);
  }

  .app-tabbar__item[aria-current="page"]::before {
    content: "";
    position: absolute;
    top: 0;
    width: 30px;
    height: 3px;
    border-radius: 0 0 4px 4px;
    background: var(--color-primary);
  }

  .app-tabbar__item .icon {
    height: 24px;
    display: grid;
    place-items: center;
  }

  .app-tabbar__badge {
    top: 8px;
    inset-inline-start: 50%;
    transform: translateX(-20px);
  }

  .m-section {
    padding: 18px 16px;
  }

  .section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-3);
    margin-bottom: var(--sp-4);
  }

  .section-head h2 {
    font-size: 16px;
    font-weight: 900;
    margin: 0;
  }

  .section-head__link {
    color: var(--color-primary-dark);
    font-size: 11px;
    font-weight: 800;
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    border: 0;
    background: transparent;
    padding: 6px 0;
  }

  .hscroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 4px 16px 8px;
    scroll-padding-inline: 16px;
    scrollbar-width: none;
    overscroll-behavior-inline: contain;
  }

  .hscroll::-webkit-scrollbar {
    display: none;
  }

  .home-category-section {
    display: block !important;
    margin: 0;
    padding: 18px 0 20px;
    border: 0;
    border-radius: 0;
    background: #fff;
  }

  .home-category-section .section-head {
    padding-inline: 16px;
    margin-bottom: 14px !important;
  }

  .gshop-category-section.d-lg-block,
  .gshop-category-section,
  .account-nav.d-lg-block {
    display: none !important;
  }

  .m-section.d-lg-none {
    display: block !important;
  }

  .account-login-card.d-lg-none {
    display: flex !important;
  }

  .account-menu.d-lg-none {
    display: flex !important;
    flex-direction: column;
  }

  .account-support.d-lg-none {
    display: block !important;
  }

  .cat-chip {
    appearance: none;
    -webkit-appearance: none;
    border: 0;
    outline: 0;
    margin: 0;
    padding: 10px 8px 9px;
    width: 98px;
    min-width: 98px;
    height: 108px;
    border-radius: 20px;
    background: #f7faf5;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 7px;
    box-shadow: 0 1px 0 rgba(17,24,39,.03), 0 6px 18px rgba(39,65,30,.055);
    font-family: var(--font-base);
    color: var(--color-text);
    cursor: pointer;
    flex: 0 0 auto;
  }

  .cat-chip:nth-child(6n+1){background:#fff1eb;}
  .cat-chip:nth-child(6n+2){background:#eef8ea;}
  .cat-chip:nth-child(6n+3){background:#fff8dc;}
  .cat-chip:nth-child(6n+4){background:#fff0f1;}
  .cat-chip:nth-child(6n+5){background:#f3efff;}
  .cat-chip:nth-child(6n+6){background:#eaf7f8;}

  .cat-chip__icon {
    width: 52px;
    height: 52px;
    flex: 0 0 52px;
    border: 0;
    border-radius: 17px;
    background: rgba(255,255,255,.78) !important;
    display: grid;
    place-items: center;
    box-shadow: inset 0 0 0 1px rgba(31,41,55,.045);
    overflow: hidden;
  }

  .cat-chip__icon img {
    width: 42px;
    height: 42px;
    object-fit: contain;
  }

  .cat-chip__label {
    width: 100%;
    font-size: 11px;
    font-weight: 800;
    line-height: 1.25;
    color: #263238;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
  }

  .cat-chip__count {
    display: none;
  }

  .category-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding-top: 12px;
  }

  .category-grid--v8 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    padding-top: 10px;
  }

  .category-grid--v8 .cat-chip {
    width: 100%;
    min-width: 0;
    height: 108px;
    flex: initial;
  }

  .category-tile {
    appearance: none;
    -webkit-appearance: none;
    border: 0;
    min-height: 116px;
    padding: 14px;
    border-radius: 22px;
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    grid-template-rows: auto auto;
    align-items: center;
    justify-items: start;
    column-gap: 10px;
    row-gap: 3px;
    text-align: right;
    overflow: hidden;
    box-shadow: 0 7px 20px rgba(38,58,31,.06);
    color: var(--color-text);
  }

  .category-grid--v8 .category-tile {
    border: 0 !important;
    min-height: 0;
    padding: 10px 8px 9px;
    border-radius: 20px;
    display: flex;
    grid-template-columns: none;
    grid-template-rows: none;
    align-items: center;
    justify-items: center;
    text-align: center;
    box-shadow: 0 1px 0 rgba(17,24,39,.03), 0 6px 18px rgba(39,65,30,.055);
  }

  .category-tile:nth-child(6n+1){background:#fff1eb;}
  .category-tile:nth-child(6n+2){background:#eef8ea;}
  .category-tile:nth-child(6n+3){background:#fff8dc;}
  .category-tile:nth-child(6n+4){background:#fff0f1;}
  .category-tile:nth-child(6n+5){background:#f3efff;}
  .category-tile:nth-child(6n+6){background:#eaf7f8;}

  .category-tile__icon {
    grid-row: 1 / span 2;
    width: 52px;
    height: 52px;
    border-radius: 17px;
    background: rgba(255,255,255,.82);
    display: grid;
    place-items: center;
    box-shadow: inset 0 0 0 1px rgba(31,41,55,.04);
  }

  .category-grid--v8 .category-tile__icon {
    grid-row: auto;
    width: 52px;
    height: 52px;
    flex: 0 0 52px;
    border-radius: 17px;
  }

  .category-tile__icon img {
    width: 42px;
    height: 42px;
    object-fit: contain;
  }

  .category-tile__label {
    align-self: end;
    font-size: 13px;
    font-weight: 900;
    line-height: 1.35;
    max-width: 100%;
  }

  .category-grid--v8 .category-tile__label {
    align-self: auto;
    width: 100%;
    font-size: 11px;
    line-height: 1.25;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .category-tile__count {
    align-self: start;
    padding: 0;
    min-height: auto;
    background: transparent;
    font-size: 10px;
    font-weight: 700;
    color: #667085;
  }

  .category-grid--v8 .category-tile__count {
    display: none;
  }

  .product-card--desktop {
    display: none !important;
  }

  .product-card--v8 {
    display: flex;
  }

  .product-card {
    position: relative;
    background: var(--color-surface);
    border: 1px solid #edf0ea;
    border-radius: 16px;
    overflow: hidden;
    flex-direction: column;
    box-shadow: 0 2px 10px rgba(31,41,55,.035);
    min-width: 0;
  }

  .hscroll .product-card {
    width: 154px;
    flex: 0 0 154px;
  }

  .related-products-desktop {
    display: none !important;
  }

  .related-product-slider {
    padding-top: 44px !important;
    padding-bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 40px) !important;
    overflow: hidden;
  }

  .related-product-slider .container {
    max-width: 760px;
    padding-inline: 16px;
  }

  .related-product-slider .row {
    justify-content: center !important;
  }

  .related-product-slider .section-title {
    text-align: center !important;
  }

  .related-product-slider .section-title h2 {
    font-size: 24px;
    line-height: 1.2;
    font-weight: 900;
    color: var(--color-text);
  }

  .related-product-slider .rl-slider-btns {
    display: none !important;
  }

  .related-products-mobile {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 4px 16px 10px;
    margin-inline: -16px;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
  }

  .related-products-mobile::-webkit-scrollbar {
    display: none;
  }

  .related-products-mobile .product-card--v8 {
    width: 154px;
    min-width: 154px;
    max-width: 154px;
    flex: 0 0 154px;
    scroll-snap-align: start;
  }

  .grid-2,
  .shop-grid .row {
    --bs-gutter-x: 10px;
    --bs-gutter-y: 10px;
  }

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

  .shop-grid .row > [class*="col-"] {
    width: 50%;
    flex: 0 0 auto;
  }

  .product-card__media {
    aspect-ratio: 1 / 1;
    background: #f8faf7;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    border-radius: 15px 15px 0 0;
  }

  .product-card__media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 12px;
  }

  .product-card__badge {
    position: absolute;
    top: 8px;
    inset-inline-start: 8px;
    background: var(--color-secondary);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    z-index: 2;
  }

  .product-card__favorite {
    position: absolute;
    top: 8px;
    inset-inline-end: 8px;
    width: 32px;
    height: 32px;
    border: 1px solid rgba(0,0,0,.06);
    border-radius: 50%;
    background: rgba(255,255,255,.92);
    display: grid;
    place-items: center;
    color: #6b7280;
    z-index: 2;
    cursor: pointer;
  }

  .product-card__favorite .ui-icon {
    width: 17px;
    height: 17px;
  }

  .product-card__body {
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
    min-width: 0;
  }

  .product-card__cat {
    display: none;
    color: var(--color-text-muted);
    font-size: var(--fs-xs);
  }

  .product-card__title {
    font-size: 13px;
    font-weight: 800;
    line-height: 1.35;
    min-height: 35px;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    color: var(--color-text);
  }

  .product-card__meta {
    display: block;
    min-height: 16px;
    font-size: 10px;
    color: var(--color-text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .product-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    min-width: 0;
    min-height: 38px;
    margin-top: auto;
    padding-top: 6px;
  }

  .product-card--v8 .product-card__footer .price {
    min-width: 0;
    max-width: calc(100% - 48px);
    display: inline-flex;
    align-items: baseline;
    gap: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 11px;
    line-height: 1.2;
    color: var(--color-price);
    font-weight: 900;
  }

  .product-card--v8 .product-card__footer .price span,
  .product-card--v8 .product-card__footer .price .h4,
  .product-card--v8 .product-card__footer .price small {
    margin: 0 !important;
    color: var(--color-price) !important;
    font-size: 11px !important;
    line-height: 1.2 !important;
    font-weight: 900 !important;
    white-space: nowrap;
  }

  .product-card--v8 .product-card__footer .price small {
    color: var(--color-text-muted) !important;
    font-size: 9px !important;
    font-weight: 800 !important;
  }

  .product-card--v8 .product-card__footer .price .deleted {
    font-size: 9px !important;
    color: var(--color-text-muted) !important;
  }

  .product-card--v8 .product-card__add {
    width: 34px;
    height: 34px;
    min-width: 34px;
    min-height: 34px;
    flex: 0 0 34px;
    border-radius: 11px;
    background: var(--color-primary);
    color: #fff;
    border: 0;
    display: grid;
    place-items: center;
    cursor: pointer;
    font-size: 0 !important;
    line-height: 1 !important;
    padding: 0 !important;
    box-shadow: none !important;
  }

  .product-card--v8 .product-card__add:disabled {
    opacity: .55;
    cursor: not-allowed;
  }

  .product-card--v8 .product-card__add::before {
    content: "+";
    font-size: 20px;
    line-height: 1;
    font-weight: 600;
  }

  .product-card--v8 .product-card__add[hidden],
  .product-card--v8[data-in-cart="true"] .product-card__add {
    display: none !important;
  }

  .product-card--v8 .product-card__qty {
    height: 30px;
    min-width: 72px;
    max-width: 78px;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 0;
    padding: 2px;
    border: 1px solid #ffd5b0;
    background: #fff7ef;
    border-radius: 10px;
    overflow: hidden;
    color: var(--color-primary);
  }

  .product-card--v8 .product-card__qty[hidden] {
    display: none !important;
  }

  .product-card--v8 .product-card__qty button {
    width: 23px;
    height: 24px;
    min-width: 23px;
    padding: 0;
    font: 800 14px/1 var(--font-base);
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: inherit;
    cursor: pointer;
  }

  .product-card--v8 .product-card__qty span {
    min-width: 20px;
    width: 20px;
    text-align: center;
    font-size: 10px;
    line-height: 1;
    font-weight: 900;
    color: var(--color-text);
  }

  .listing-top {
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 12px 0 !important;
    margin-bottom: 16px !important;
    background: transparent !important;
  }

  .listing-top .number-count-filter,
  .listing-top .select-filter {
    display: none !important;
  }

  .listing-top p {
    font-size: 12px;
    color: var(--color-text-muted);
  }

  #offcanvasProductFilter {
    width: min(92vw, 390px);
    max-width: 390px;
  }

  #offcanvasProductFilter .offcanvas-body {
    padding: 12px;
    overflow-y: auto;
  }

  #offcanvasProductFilter .gshop-sidebar,
  #offcanvasProductFilter .sidebar-widget {
    overflow: visible !important;
    height: auto !important;
  }

  #offcanvasProductFilter .sidebar-widget {
    padding: 16px !important;
  }

  #offcanvasProductFilter .widget-title {
    align-items: center;
    gap: 8px;
  }

  #offcanvasProductFilter .widget-title h6 {
    flex: 0 0 auto;
    margin: 0;
    font-size: 15px;
    line-height: 1.35;
    white-space: nowrap;
  }

  #offcanvasProductFilter .search-form {
    gap: 0;
  }

  #offcanvasProductFilter .search-form input {
    min-width: 0;
  }

  #offcanvasProductFilter .price-filter-widget .d-flex {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 8px;
    align-items: center;
  }

  #offcanvasProductFilter .price-filter-widget input {
    width: 100% !important;
    min-width: 0;
    height: 42px;
    font-size: 13px;
  }

  #offcanvasProductFilter .price-filter-widget .btn {
    min-height: 38px;
    padding: 8px 14px;
    font-size: 12px;
  }

  #offcanvasProductFilter .tags-widget .btn {
    min-height: 34px;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 12px;
    line-height: 1;
    white-space: nowrap;
  }

  .gshop-gshop-grid {
    padding-top: 18px !important;
    padding-bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 28px) !important;
  }

  .breadcrumb-section {
    display: none !important;
  }

  .cart-section {
    padding: 18px 0 calc(var(--tabbar-h) + var(--safe-bottom) + 28px) !important;
    max-width: 760px;
    margin: 0 auto;
  }

  .cart-section .container {
    padding-inline: 16px;
  }

  .cart-table {
    display: block;
    background: transparent !important;
  }

  .cart-table thead {
    display: none;
  }

  .cart-table tbody,
  .cart-table tr,
  .cart-table td {
    display: block;
    width: 100%;
  }

  .cart-table tr {
    margin-bottom: 12px;
    padding: 12px;
    border: 1px solid #edf0ea;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 1px 0 rgba(17,24,39,.03);
  }

  .voucher-box,
  .cart-summery {
    border: 1px solid #edf0ea;
    border-radius: 18px !important;
    box-shadow: 0 1px 0 rgba(17,24,39,.03);
  }

  .voucher-box {
    padding: 16px !important;
  }

  .cart-summery {
    padding: 18px !important;
  }

  .account-login-card {
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: 18px;
    box-shadow: var(--shadow-card);
    padding: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
  }

  .account-avatar {
    width: 46px;
    height: 46px;
    border-radius: 15px;
    display: grid;
    place-items: center;
    background: var(--color-secondary-tint);
    color: var(--color-secondary-dark);
    flex: 0 0 auto;
  }

  .account-login-card strong {
    display: block;
    font-size: 14px;
    font-weight: 900;
    margin-bottom: 2px;
  }

  .account-login-card p {
    font-size: 11px;
    line-height: 1.6;
    color: var(--color-text-muted);
    margin: 0;
  }

  .account-menu,
  .account-support {
    border: 1px solid #edf0ea;
    border-radius: 18px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 1px 0 rgba(17,24,39,.03);
  }

  .account-support__toggle {
    min-height: 52px;
    padding: 11px 14px;
    display: flex;
    align-items: center;
    gap: 11px;
    border: 0;
    background: #fff;
    color: var(--color-text);
    width: 100%;
    text-align: start;
    font: 800 13px/1.4 var(--font-base);
  }

  .account-support__panel {
    display: none;
    padding: 0 14px 12px;
    color: var(--color-text-muted);
    font-size: 12px;
  }

  .account-support__toggle[aria-expanded="true"] + .account-support__panel {
    display: block;
  }

  .account-support__toggle[aria-expanded="true"] .account-support__chevron {
    transform: rotate(180deg);
  }

  .account-support__panel ul {
    margin: 0;
    padding: 4px 0 0;
    list-style: none;
  }

  .account-support__panel li {
    padding: 8px 0;
    border-bottom: 1px dashed #e9ece7;
  }

  .account-support__panel li:last-child {
    border-bottom: 0;
  }
}

@media (max-width: 359px) {
  .app-header { padding-inline: 10px; }
  .app-header__btn { width: 40px; height: 40px; }
  .app-header__delivery { max-width: 145px; font-size: 9px; }
  .m-section { padding-inline: 12px; }
  .hscroll { padding-inline: 12px; }
  .shop-grid .row { --bs-gutter-x: 8px; --bs-gutter-y: 8px; }
  .product-card__body { padding: 8px; }
  .product-card__title { font-size: 11px; }
  .product-card__footer .price { font-size: 11px; }
  .product-card__qty { min-width: 68px; max-width: 72px; }
  .product-card__qty button { width: 23px; height: 25px; min-width: 23px; }
  .product-card__qty span { min-width: 18px; width: 18px; }
}

@media (min-width: 768px) and (max-width: 1023px) {
  .m-section { padding: var(--sp-6); }
  .hscroll .product-card { width: 200px; flex-basis: 200px; }
  .app-drawer__panel { width: min(60vw, 380px); }
  .shop-grid .row > [class*="col-"] { width: 33.333333%; }
  .category-grid--v8 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
