/* Product page composition. The pinned DesignTap navigation and print layouts
   keep their own rules. Match the control-centre canvas and page gutters. */
@media screen {
  html:has(.tt-food-safety-page:not(.hidden)) #tapContent .main {
    width: 100%;
    max-width: none !important;
    padding: 32px 30px 40px;
    box-sizing: border-box;
  }
  #app .tt-food-safety-page {
    width: 100%;
    min-width: 0;
    max-width: none;
    margin-inline: 0;
  }
  #app .tt-food-safety-page > .screen-head {
    margin: 0 0 28px;
    padding: 0;
    gap: 16px;
    align-items: center;
  }
  #app .tt-food-safety-page > .screen-head .asset-title {
    font-size: clamp(26px, 2.4vw, 34px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -.035em;
    color: #191919;
  }
  #app .tt-food-safety-page :is(.haccp-wrap, .wv-body, .eho-controls, .eho-doc,
    .eho-report-actions, .asset-panel, #weekAtAGlanceBody) {
    max-width: none !important;
    min-width: 0;
    margin-inline: 0;
    box-sizing: border-box;
  }
  #app .tt-food-safety-page :is(.haccp-wrap, .eho-wrap) {
    padding-inline: 0;
  }
  /* Match management actions without resizing matrix cells, answers or icons. */
  #app :is(.tt-food-safety-page, .review-overview) :is(.btn-primary, .btn-secondary, .btn-ghost) {
    min-height: 44px;
    height: auto;
    padding: 10px 16px;
    border-radius: 12px !important;
    font: inherit;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.35;
    white-space: normal;
    box-shadow: none;
  }
  #app :is(.tt-food-safety-page, .review-overview) :is(button, summary, input, select, textarea):focus-visible {
    outline: 2px solid #1d3a8a;
    outline-offset: 3px;
  }
  /* Use the same quiet, underlined view selector as Manage Users. */
  #app .portfolio-week-switch {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 24px;
    border-bottom: 1px solid #e2e8f0;
  }
  #app .portfolio-week-switch button {
    appearance: none;
    min-height: 44px;
    padding: 12px 20px;
    border: 0;
    border-bottom: 3px solid transparent;
    border-radius: 0;
    background: transparent;
    color: #536278;
    font: inherit;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.35;
    box-shadow: none;
    cursor: pointer;
  }
  #app .portfolio-week-switch button[aria-pressed="true"] {
    color: #203d87;
    border-bottom-color: #203d87;
    background: transparent;
  }
  #app .portfolio-week-switch button:hover { color: #203d87; background: #f1f4f9; }
  #app .portfolio-week-switch button:focus-visible { outline: 2px solid #1d3a8a; outline-offset: -2px; }
  #app .review-report-filters summary {
    gap: 8px;
    padding: 10px 16px;
    border: 1px solid #d8dde5;
    border-radius: 12px;
    background: #fff;
    color: #191919;
    font-size: 15px;
    font-weight: 700;
    box-sizing: border-box;
  }
  @media (max-width: 1000px) {
    html:has(.tt-food-safety-page:not(.hidden)) #tapContent .main {
      padding: 24px 24px calc(112px + env(safe-area-inset-bottom, 0px));
    }
  }
  @media (max-width: 600px) {
    html:has(.tt-food-safety-page:not(.hidden)) #tapContent .main {
      padding: 24px 16px calc(112px + env(safe-area-inset-bottom, 0px));
    }
    #app .tt-food-safety-page > .screen-head { margin-bottom: 22px; align-items: flex-start; }
    #app .portfolio-week-switch button { padding-inline: 14px; }
  }
}
