import styled from 'styled-components/macro'

import { devices } from 'config'
import { ProfileLink } from 'features/ProfileLink'
import { UserSportFavItemLogoWrapper } from 'features/UserFavorites/styled'

type Props = {
  active?: boolean,
}

export const BlockWrapper = styled.div`
  margin-top: 20px;
  width: 32%;

  @media ${devices.mobile} {
    font-size: 14px;
    width: 100%;
  }
`

export const TitleWrapper = styled.div`
  display: flex;
  justify-content: space-between;
  align-items: center;
`

export const ContentWrapper = styled.div`
  margin-top: 10px;
  background-color: #3F3F3F;
  border-radius: 1.4px;
`

export const Item = styled.div`
  display: flex;
  align-items: center;
  padding: 10px;
  font-size: 11px;

  @media ${devices.mobile} {
    padding-left: 2rem;
    font-size: 11px;
  }
`

export const CountryAndTeamInfo = styled.div`
  margin-top: 0.4rem;
  display: flex;
  align-items: center;
  color: rgba(255, 255, 255, 0.7);
`

export const SportItemLogoWrapper = styled(UserSportFavItemLogoWrapper)`
  margin-right: 0.5rem;
  
  :not(:last-child) {
    margin-bottom: 0;
  }

  @media ${devices.mobile} {
    width: 4.6rem;
    height: 4.6rem;
  }
`

export const Arrows = styled.span<Props>`
  display: inline-block;
  width: 1rem;
  height: 1rem;
  background-repeat: no-repeat;
  background-position: center;
  background-image: url(/images/arrowUpWhite.svg);
  transform: ${({ active }) => (active ? '' : 'rotate(180deg)')};

  @media ${devices.mobile} {
    width: 2.5rem;
    height: 1.5rem;
  }
`

export const Name = styled.div`
  @media ${devices.mobile} {
    font-size: 10px;
  }
`

export const FavLink = styled(ProfileLink)`
  color: inherit;
`

export const EmptySpan = styled.span``

export const EmptyDiv = styled.div``
