/*
 * TamirSet dedicated service mobile navigation canonical v1.
 * Owns only the fixed bottom navigation used by the four appliance service pages.
 * The generic public mobile dock is intentionally suppressed on these routes so
 * there is exactly one fixed bottom navigation layer per service page.
 */

html[data-tmset-shell-css="v1"] {
  --tmset-service-nav-inline-gap: max(8px, env(safe-area-inset-left, 0px), env(safe-area-inset-right, 0px));
  --tmset-service-nav-bottom-gap: max(8px, env(safe-area-inset-bottom, 0px));
  --tmset-service-nav-height: 74px;
  --tmset-service-nav-reserved: calc(var(--tmset-service-nav-height) + var(--tmset-service-nav-bottom-gap) + 22px);
  --tmset-z-service-mobile-nav: 7060;
  --tmset-service-nav-bg: rgba(255, 255, 255, .96);
  --tmset-service-nav-border: rgba(13, 143, 154, .18);
  --tmset-service-nav-ink: #17384a;
  --tmset-service-nav-muted: #526b78;
  --tmset-service-nav-primary: #0e7c86;
  --tmset-service-nav-primary-2: #157e40;
}

body.tmset-page-dishwasher-service {
  --tmset-service-nav-height: 60px;
  --tmset-service-nav-reserved: calc(var(--tmset-service-nav-height) + var(--tmset-service-nav-bottom-gap) + 16px);
}

/* Architectural fallback: even if an old cached Blade/layout renders the common
   dock, it must never compete with a dedicated service-page navigation. */
html[data-tmset-shell-css="v1"] body:is(
  .tmset-page-washer-service,
  .tmset-page-dishwasher-service,
  .tmset-page-fridge-service,
  .tmset-page-ac-service
) .tmset-mobile-dock {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

@media (max-width: 1060px) {
  html[data-tmset-shell-css="v1"] body.tmset-page-washer-service .tm-mobile-nav,
  html[data-tmset-shell-css="v1"] body.tmset-page-dishwasher-service .tm-dw-mobile-nav,
  html[data-tmset-shell-css="v1"] body.tmset-page-fridge-service .tm-fridge-bottom-nav,
  html[data-tmset-shell-css="v1"] body.tmset-page-ac-service .tm-ac-mobile-nav {
    position: fixed !important;
    inset-inline: var(--tmset-service-nav-inline-gap) !important;
    inset-block-end: var(--tmset-service-nav-bottom-gap) !important;
    top: auto !important;
    bottom: var(--tmset-service-nav-bottom-gap) !important;
    inline-size: auto !important;
    width: auto !important;
    max-inline-size: calc(100vw - (var(--tmset-service-nav-inline-gap) * 2)) !important;
    min-inline-size: 0 !important;
    min-block-size: var(--tmset-service-nav-height) !important;
    margin: 0 auto !important;
    box-sizing: border-box !important;
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    align-items: stretch !important;
    gap: 5px !important;
    z-index: var(--tmset-z-service-mobile-nav) !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: translate3d(0, 0, 0) !important;
    isolation: isolate !important;
    padding: 7px !important;
    border: 1px solid var(--tmset-service-nav-border) !important;
    border-radius: 24px !important;
    background: var(--tmset-service-nav-bg) !important;
    -webkit-backdrop-filter: blur(18px) saturate(1.12) !important;
    backdrop-filter: blur(18px) saturate(1.12) !important;
    box-shadow: 0 18px 44px rgba(7, 23, 38, .18) !important;
    contain: layout paint style;
  }

  /* Reserve the fixed navigation once, after the document's final content. */
  html[data-tmset-shell-css="v1"] body:is(
    .tmset-page-washer-service,
    .tmset-page-dishwasher-service,
    .tmset-page-fridge-service,
    .tmset-page-ac-service
  ) #tmset-footer {
    padding-block-end: max(var(--tmset-service-nav-reserved), var(--tmset-mobile-ux-fixed-space, 0px)) !important;
  }

  html[data-tmset-shell-css="v1"] body.tmset-page-washer-service .tm-mobile-nav > a,
  html[data-tmset-shell-css="v1"] body.tmset-page-dishwasher-service .tm-dw-mobile-nav > a,
  html[data-tmset-shell-css="v1"] body.tmset-page-fridge-service .tm-fridge-bottom-nav > a,
  html[data-tmset-shell-css="v1"] body.tmset-page-ac-service .tm-ac-mobile-nav > a {
    min-inline-size: 0 !important;
    max-inline-size: 100% !important;
    min-block-size: 56px !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    padding: 6px 2px !important;
    border: 1px solid transparent !important;
    border-radius: 15px !important;
    background: transparent !important;
    color: var(--tmset-service-nav-muted) !important;
    text-align: center !important;
    text-decoration: none !important;
    font-size: 11px !important;
    font-weight: 900 !important;
    line-height: 1.2 !important;
  }

  /* Page bundles may define historical nav styles; canonical rules above own the final container. */

  html[data-tmset-shell-css="v1"] body.tmset-page-washer-service .tm-mobile-nav__icon,
  html[data-tmset-shell-css="v1"] body.tmset-page-fridge-service .tm-fridge-bottom-nav__icon,
  html[data-tmset-shell-css="v1"] body.tmset-page-ac-service .tm-ac-mobile-nav > a > img,
  html[data-tmset-shell-css="v1"] body.tmset-page-dishwasher-service .tm-dw-mobile-nav > a > img {
    inline-size: 26px !important;
    block-size: 26px !important;
    min-inline-size: 26px !important;
    flex: 0 0 auto !important;
    object-fit: contain !important;
  }

  html[data-tmset-shell-css="v1"] body.tmset-page-washer-service .tm-mobile-nav__icon,
  html[data-tmset-shell-css="v1"] body.tmset-page-fridge-service .tm-fridge-bottom-nav__icon {
    display: grid !important;
    place-items: center !important;
    padding: 4px !important;
    border: 1px solid rgba(16, 151, 162, .12) !important;
    border-radius: 13px !important;
    background: rgba(236, 253, 245, .95) !important;
    box-sizing: border-box !important;
  }

  html[data-tmset-shell-css="v1"] body.tmset-page-washer-service .tm-mobile-nav__icon > img,
  html[data-tmset-shell-css="v1"] body.tmset-page-fridge-service .tm-fridge-bottom-nav__icon > img {
    inline-size: 18px !important;
    block-size: 18px !important;
  }

  html[data-tmset-shell-css="v1"] body:is(
    .tmset-page-washer-service,
    .tmset-page-dishwasher-service,
    .tmset-page-fridge-service,
    .tmset-page-ac-service
  ) [data-tmset-service-mobile-nav] > [data-tmset-repair-modal-open] {
    color: #fff !important;
    background: linear-gradient(135deg, var(--tmset-service-nav-primary), var(--tmset-service-nav-primary-2)) !important;
    border-color: rgba(255, 255, 255, .22) !important;
    box-shadow: 0 12px 24px rgba(16, 151, 162, .22) !important;
  }

  html[data-tmset-shell-css="v1"] body:is(
    .tmset-page-washer-service,
    .tmset-page-dishwasher-service,
    .tmset-page-fridge-service,
    .tmset-page-ac-service
  ) [data-tmset-service-mobile-nav] > [data-tmset-repair-modal-open] img {
    filter: brightness(0) invert(1);
  }

  /* Dishwasher uses short text labels only; five icon tiles consumed too much mobile viewport height. */
  html[data-tmset-shell-css="v1"] body.tmset-page-dishwasher-service .tm-dw-mobile-nav {
    gap: 4px !important;
    padding: 5px !important;
    border-radius: 18px !important;
  }
  html[data-tmset-shell-css="v1"] body.tmset-page-dishwasher-service .tm-dw-mobile-nav > a {
    min-block-size: 48px !important;
    flex-direction: row !important;
    gap: 0 !important;
    padding: 7px 3px !important;
    border-radius: 12px !important;
    font-size: 10.8px !important;
    line-height: 1.2 !important;
  }
  html[data-tmset-shell-css="v1"] body.tmset-page-dishwasher-service .tm-dw-mobile-nav > a > img {
    display: none !important;
  }

  html[data-tmset-shell-css="v1"] body.tmset-page-dishwasher-service .tm-dw-mobile-nav > a:is(.is-active, [aria-current="page"]),
  html[data-tmset-shell-css="v1"] body.tmset-page-washer-service .tm-mobile-nav > a:is(.is-active, [aria-current="page"]),
  html[data-tmset-shell-css="v1"] body.tmset-page-fridge-service .tm-fridge-bottom-nav > a:is(.is-active, [aria-current="page"]),
  html[data-tmset-shell-css="v1"] body.tmset-page-ac-service .tm-ac-mobile-nav > a:is(.is-active, [aria-current="page"]) {
    z-index: 1;
    color: var(--tmset-service-nav-ink) !important;
    background: linear-gradient(180deg, rgba(236, 253, 245, .96), rgba(255, 255, 255, .82)) !important;
    border-color: rgba(16, 151, 162, .18) !important;
  }

  html[data-tmset-shell-css="v1"] body:is(.tmset-modal-open, .tmset-repair-modal-open, .ts-modal-open, .tmset-keyboard-open) :is(
    .tm-mobile-nav,
    .tm-dw-mobile-nav,
    .tm-fridge-bottom-nav,
    .tm-ac-mobile-nav
  ) {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transform: translate3d(0, 14px, 0) !important;
  }
}

@media (min-width: 1061px) {
  html[data-tmset-shell-css="v1"] body.tmset-page-washer-service .tm-mobile-nav,
  html[data-tmset-shell-css="v1"] body.tmset-page-dishwasher-service .tm-dw-mobile-nav,
  html[data-tmset-shell-css="v1"] body.tmset-page-fridge-service .tm-fridge-bottom-nav,
  html[data-tmset-shell-css="v1"] body.tmset-page-ac-service .tm-ac-mobile-nav {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }
}

@media (max-width: 390px) {
  html[data-tmset-shell-css="v1"] {
    --tmset-service-nav-inline-gap: max(6px, env(safe-area-inset-left, 0px), env(safe-area-inset-right, 0px));
    --tmset-service-nav-height: 70px;
  }

  html[data-tmset-shell-css="v1"] body.tmset-page-dishwasher-service .tm-dw-mobile-nav,
  html[data-tmset-shell-css="v1"] body.tmset-page-washer-service .tm-mobile-nav,
  html[data-tmset-shell-css="v1"] body.tmset-page-fridge-service .tm-fridge-bottom-nav,
  html[data-tmset-shell-css="v1"] body.tmset-page-ac-service .tm-ac-mobile-nav {
    gap: 3px !important;
    padding: 6px !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  html[data-tmset-shell-css="v1"] :is(.tm-mobile-nav, .tm-dw-mobile-nav, .tm-fridge-bottom-nav, .tm-ac-mobile-nav) {
    transition: none !important;
  }
}
