@import '../animation/variables.scss';

$name: 'ivue-date-picker-date';

:root {
  --#{$name}-height: 248px;
  --#{$name}-padding: 0 12px;
  --#{$name}-font-size: 14px;

  // table
  --#{$name}-table-th-padding: 8px 0;
  --#{$name}-table-td-width: 45px;
  --#{$name}-table-td-button-size: 33px;

  // 标记
  --#{$name}-note-size: 8px;
  --#{$name}-note-left: 50%;
  --#{$name}-note-bottom: 2px;
  --#{$name}-note-transform: translateX(-4px);

  // color
  --#{$name}-button-color: rgba(0, 0, 0, 0.87);
  --#{$name}-table-th-color: rgba(0, 0, 0, 0.38);
}

.#{$name} {
  position: relative;
  text-align: center;
  padding: var(--#{$name}-padding);
  height: var(--#{$name}-height);
  font-size: var(--#{$name}-font-size);

  table {
    table-layout: fixed;
    width: 100%;
    transition: $ivue-transition-default;
  }

  &--table {
    th {
      font-weight: 600;
      padding: var(--#{$name}-table-th-padding);
      color: var(--#{$name}-table-th-color);
    }

    td {
      position: relative;
      text-align: center;
      width: var(--#{$name}-table-td-width);

      button {
        text-align: center;
        height: var(--#{$name}-table-td-button-size);
        width: var(--#{$name}-table-td-button-size);
        min-width: var(--#{$name}-table-td-button-size);
        font-size: var(--ivue-font-base-size);
        margin: 0;
        color: var(--#{$name}-button-color);
        border: 1px solid;
        border-color: transparent;
      }
    }
  }

  // 标记
  &--note {
    position: absolute;
    left: var(--#{$name}-note-left);
    bottom: var(--#{$name}-note-bottom);
    transform: var(--#{$name}-note-transform);
    border-radius: 50%;
    width: var(--#{$name}-note-size);
    height: var(--#{$name}-note-size);
    background: currentColor;
  }
}
