import { Input, TextArea } from '@bjsdistribution/dms-component-library';
import styled from 'styled-components';

export const IconContainer = styled.div`
  cursor: pointer;
`;

export const StyledInput = styled(Input)`
  border-radius: 66px;
  min-width: 700px;
`;

export const StyledTextArea = styled(TextArea)`
  display: flex;
  padding: 12px;
  align-items: flex-start;
  gap: 4px;
  flex: 1 0 0;
  align-self: stretch;
  border-radius: 10px;
  border: 1px solid #e0e2e7;
  background: #fff;
  resize: none;
  min-height: 200px;
`;

export const StyledTextAreas = styled(TextArea)`
  display: flex;
  padding: 12px;
  align-items: flex-start;
  gap: 4px;
  flex: 1 0 0;
  align-self: stretch;
  border-radius: 10px;
  border: 1px solid #e0e2e7;
  background: #fff;
  resize: none;
  min-height: 50px;
`;

export const SplitLayout = styled.div`
  display: flex;
  justify-content: space-between;
  gap: 10px;
`;

export const SplitText = styled.div`
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-direction: column;
  margin-bottom: 4px;
`;

export const Row = styled.div`
  flex: 1 0 0;
  display: grid;
  gap: 5px;
  justify-content: center;
`;
export const HoldRow = styled.div`
  flex: 1 0 0;
  display: grid;
  gap: 5px;
  justify-content: center;
  /* margin-bottom: 25px; */
`;

export const Label = styled.label`
  color: #758588;
  font-family: 'Lato', sans-serif;
  font-size: 14px;
  font-style: normal;
  font-weight: 500;
`;

export const ContentContainer = styled.div`
  display: flex;
  padding: 12px 12px;
  margin: 5px 14px;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 15px;
  flex: 1 0 0;
  border-radius: 15px;
  background: #f8fafc;
`;
export const HoldContentContainer = styled.div`
  display: flex;
  padding: 20px 20px;
  margin: 5px 14px;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 15px;
  flex: 1 0 0;
  border-radius: 15px;
`;

export const Container = styled.div`
  border-radius: 15px;
  border: 1px solid #e0e2e7;
  background: #fff;
  display: flex;
  padding: 15px;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 15px;
  flex: 1 0 0;
  width: 450px;
`;

export const StaticText = styled.div`
  color: #3a3630;
  font-family: 'lato', sans-serif;
  font-size: 14px;
  font-style: normal;
  font-weight: 600;
  line-height: 18px; /* 128.571% */
  flex: 1 0 0;
`;

export const ImageCircle = styled.div`
  display: flex;
  padding: 10px;
  justify-content: center;
  align-items: center;
  gap: 10px;
  border-radius: 50px;
  background: #f2f4f6;
`;

export const ImageRow = styled.div`
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
  align-self: stretch;
`;
export const HoldFooterText = styled.div`
  color: #aea9a1;
  font-family: 'lato', sans-serif;
  font-size: 13px;
  font-style: normal;
  font-weight: 400;
  line-height: 16px;
  margin-top: 32px;
  margin-bottom: 22px;
`;
export const FooterText = styled.div`
  color: #aea9a1;
  font-family: 'lato', sans-serif;
  font-size: 13px;
  font-style: normal;
  font-weight: 400;
  line-height: 16px;
`;

export const HoldDatePickerWrap = styled.div`
  position: relative;
  border-radius: 66px;
  border: 1px solid #e0e2e7;
  box-shadow: 0px 1px 2px 0px rgba(16, 24, 40, 0.05);

  input[type='text'] {
    border-radius: 20px;
    background: #fff;
    border: none;
    color: #6a7378;
    font-size: 14px;
    font-weight: 400;
    line-height: 18px;
    padding: 10px 0;
    padding-left: 33px;
    min-width: 21.5vw;
    &:focus-visible {
      outline: none;
    }
  }
  svg {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
  }
  .react-datepicker-wrapper {
    background-color: white;
    border-radius: 66px;
  }
  .ant-picker-outlined {
    border-style: none;
    border-radius: 66px;
    outline: none;
    width: 346px;
  }
`;

export const DatePickerWrap = styled.div`
  position: relative;

  border-radius: 66px;
  border: 1px solid #e0e2e7;
  box-shadow: 0px 1px 2px 0px rgba(16, 24, 40, 0.05);

  input[type='text'] {
    border-radius: 20px;
    background: #fff;
    border: none;
    color: #6a7378;
    font-size: 14px;
    font-weight: 400;
    line-height: 18px;
    padding: 10px 0;
    padding-left: 33px;
    min-width: 18vw;
    &:focus-visible {
      outline: none;
    }
  }
  svg {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
  }
  .react-datepicker-wrapper {
    background-color: white;
    border-radius: 66px;
  }
  .ant-picker-outlined {
    border-style: none;
    border-radius: 66px;
    outline: none;
    width: 100%;
  }
`;

export const DeleteCircleIcon = styled.div`
  border-radius: 20px;
  border: 1px solid #e2e0db;
  background: #fff;
  display: flex;
  padding: 6px;
  justify-content: center;
  align-items: center;
  height: 25px;
  width: 25px;
`;

export const RoundedTableSkelton = styled.div`
  margin-top: -8px;
  min-height: auto;
  max-height: 60vh;
  table {
    border-collapse: separate;
    width: 100%;
    border-spacing: 0px 8px;
    thead {
      tr {
        th {
          font-size: 14px;
          font-weight: 600;
          padding: 8px 15px;
          text-align: left;
          border-top: 1px solid rgba(0, 0, 0, 0.08);
          border-bottom: 1px solid rgba(0, 0, 0, 0.08);

          background: #f0f2f2;
          &:first-child {
            border-radius: 20px 0 0 20px;
          }
          &:last-child {
            border-radius: 0 20px 20px 0;
          }
        }
      }
    }
    tbody {
      tr {
        td {
          color: #3a3630;
          font-size: 13px;
          font-weight: 400;
          line-height: 16px;
          padding: 6px 15px;
          text-align: left;
          box-shadow: 3px 1px 3px 0px rgba(16, 24, 40, 0.1);

          background: #fff;

          &:first-child {
            border-radius: 20px 0 0 20px;
          }

          &:last-child {
            border-radius: 0 20px 20px 0;
          }
        }
      }
    }
  }
`;

export const TableWrapper = styled.div`
  width: 800px;
  min-height: 200px;
  max-height: 400px;
`;

export const TableContainer = styled.div`
  max-height: 200px; /* Adjust height as needed */
  overflow-y: auto;
  position: relative;

  &::-webkit-scrollbar {
    width: 8px; /* Adjust width for thin scrollbar */
  }

  &::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2); /* Adjust color and transparency */
    border-radius: 4px;
  }

  &::-webkit-scrollbar-track {
    background: transparent;
  }

  &::-webkit-scrollbar {
    display: none; /* Hide the scrollbar */
  }

  -ms-overflow-style: none; /* Internet Explorer 10+ */
  scrollbar-width: none; /* Firefox */
`;

export const StyledTable = styled.table`
  width: 100%;
  border-collapse: collapse;
`;

export const StyledThead = styled.thead`
  position: sticky;
  top: 0;
  background: white;
  z-index: 1;
`;

export const Heading = styled.div`
  color: #3a3630;
  font-family: 'Roboto';
  font-size: 16px;
  font-style: normal;
  font-weight: 500;
  line-height: 24px;
  text-transform: uppercase;
`;

export const SuccessText = styled.span`
  color: #29cc6a;
  font-size: 13px;
  font-style: normal;
  font-weight: 400;
  line-height: 16px;
`;

export const Td = styled.td`
  color: #3a3630;
  font-size: 12px;
  font-style: normal;
  font-weight: 400;
  line-height: normal;
  padding: 5px 15px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-right: none;
  border-left: none;
`;

export const StyledTr = styled.tr`
  border-radius: 30px;
  background: #fff;
  box-shadow: 0px 1px 3px 0px rgba(16, 24, 40, 0.1);
`;

export const AmountContainer = styled.div`
  display: flex;
  align-items: center;
`;

export const AmountSymbol = styled.span`
  margin-right: 4px;
`;

export const StyledAmountInput = styled(Input)`
  padding: 5px;
  width: 50%;
`;

export const StatusWrapper = styled.div`
  color: #3a3630;
  font-size: 13px;
  font-style: normal;
  font-weight: 400;
  line-height: 16px;
`;
