import { Platform } from 'react-native';
import { StyleSheet } from 'react-native';
import { Colors } from 'src/theme';
import { getFontSize } from 'src/utils';

export const styles = StyleSheet.create({
  replyContent: {},
  replyAuthorName: {
    fontWeight: '600',
    fontSize: getFontSize(13)
  },
  replyMessageText: {
    fontWeight: '400',
    fontSize: getFontSize(13)
  },
  unreadMessagesContainer: {
    padding: 8,
    backgroundColor: Colors.FILL_LIGHT,
    alignItems: 'center'
  },
  unreadMessagesText: {
    color: Colors.DARK_BLUE,
    fontWeight: '700',
    fontSize: getFontSize(12)
  },
  modalBackground: {
    flex: 1
  },
  mediaContainer: {
    borderRadius: 10,
    overflow: 'hidden',
    margin: 5
  },
  chatMedia: {
    width: 200,
    height: 200,
    borderRadius: 10
  },
  fullScreenMedia: {
    width: '90%',
    height: '80%'
  },
  replyMessageContainer: {
    borderLeftWidth: 2,
    borderRadius: 2,
    margin: 8,
    marginBottom: 0,
    padding: 4,
    paddingLeft: 6,
    gap: 2
  },
  composer: {
    backgroundColor: Colors.WHITE,
    borderRadius: 12,
    borderWidth: 0.5,
    borderColor: Colors.LIGHT_GRAY,
    paddingHorizontal: 10,
    fontSize: 16,
    marginBottom: 5
  },
  container: {
    flex: 1,
    backgroundColor: 'white'
  },
  imageContainer: {
    borderRadius: 10,
    overflow: 'hidden',
    margin: 6
  },
  chatImage: {
    width: 200,
    height: 200,
    borderRadius: 10
  },
  modalContainer: {
    flex: 1,
    backgroundColor: 'rgba(0, 0, 0, 0.9)',
    justifyContent: 'center',
    alignItems: 'center'
  },
  reactModalContainer: {
    justifyContent: 'flex-end',
    margin: 0
  },
  closeButton: {
    position: 'absolute',
    top: 40,
    right: 20
  },
  avatar: {
    width: 30,
    height: 30,
    borderRadius: 15,
    borderWidth: 1,
    borderColor: Colors.FILL_LIGHT
  },
  emptyChat: {
    height: '95%',
    alignItems: 'center',
    justifyContent: 'center',
    transform: Platform.OS === 'ios' ? [{ scaleY: -1 }] : [{ scaleY: -1 }, { scaleX: -1 }]
  },
  emptyChatText: {
    fontSize: getFontSize(14),
    fontWeight: '600',
    textAlign: 'center',
    color: Colors.DARK_BLUE
  },
  scrollToBottom: {
    position: 'absolute',
    bottom: -20,
    right: -20,
    backgroundColor: Colors.DARK_BLUE,
    borderRadius: 20,
    padding: 8
  },
  sendBtn: {
    flexDirection: 'row',
    height: '100%',
    alignItems: 'center',
    justifyContent: 'center',
    paddingHorizontal: 14
  },
  timeContainer: {
    flexDirection: 'row',
    gap: 4,
    alignItems: 'center',
    alignSelf: 'flex-end'
  },
  timeText: {
    color: Colors.LIGHT_GRAY,
    fontSize: getFontSize(10),
    fontWeight: '600',
    paddingLeft: 8,
    flexShrink: 0
  },
  bottomContainer: {
    flexDirection: 'row',
    alignItems: 'center',
    paddingHorizontal: 8,
    paddingBottom: 6,
    flexShrink: 1,
    flexGrow: 1,
    gap: 12
  },
  bottomCustomContainer: {
    flexDirection: 'row',
    alignItems: 'center',
    flexShrink: 0,
    borderRadius: 12,
    paddingHorizontal: 6,
    paddingVertical: 4,
    gap: 6
  },
  optionsContainer: {
    width: '100%',
    backgroundColor: Colors.FILL_LIGHT
    // borderTopWidth: 1,
    // borderTopColor: '#ccc'
  },
  optionRow: {
    flexDirection: 'row',
    justifyContent: 'space-between',
    paddingHorizontal: '5%',
    marginVertical: 20,
    flexWrap: 'wrap'
  },
  optionItem: {
    width: '30%',
    paddingVertical: 8,
    marginBottom: 12,
    alignItems: 'center'
  },
  optionLabel: {
    marginTop: 6,
    fontSize: 12,
    color: Colors.DARK_BLUE,
    fontWeight: '700'
  },
  fileContainer: {
    flexDirection: 'row',
    alignItems: 'center',
    padding: 6,
    borderRadius: 8,
    marginVertical: 6,
    marginHorizontal: 6
  },
  fileNameText: {
    marginLeft: 4,
    fontSize: 14,
    fontWeight: '600',
    maxWidth: 200
  },
  fileTypeText: {
    marginLeft: 6,
    fontSize: 12,
    color: Colors.LIGHT_GRAY
  }
});
