;(function () {
/* StatusChip — absolute-positioned "New" / status badge for service tiles. */

const StatusChip = ({ children, top = 0 }) => (
  <div
    style={{
      position: 'absolute',
      zIndex: 2,
      minWidth: '85px',
      paddingLeft: '6px',
      paddingRight: '6px',
      paddingTop: '2px',
      paddingBottom: '2px',
      backgroundColor: '#B5F5F3',
      border: '1px solid #33E4DE',
      borderRadius: '6px',
      display: 'flex',
      alignItems: 'center',
      justifyContent: 'center',
      top: `${top}px`,
      /* Center horizontally on the tile regardless of tile width — replaces
         the previous fixed `left: 45` that was tuned for a specific tile
         size and looked off-center as the layout flexed. */
      left: '50%',
      transform: 'translateX(-50%)',
    }}
  >
    <span
      style={{
        fontFamily: 'Gilroy',
        fontWeight: 600,
        fontSize: '11px',
        lineHeight: '16px',
        color: '#000',
      }}
    >
      {children}
    </span>
  </div>
);

Object.assign(window, { StatusChip });
})();
