@import "variables";

:host {
  display: flex;
  flex-direction: column;
}

.header {
  display: flex;
  align-items: center;
  border-bottom: 1px solid mat-color($app-foreground, divider);
  padding-bottom: 10px;
  margin-bottom: 25px;

  .title {
    font-size: 2rem;
    font-weight: 300;
    align-self: flex-end;
    margin-right: auto;
  }
}

.header-action {
  display: flex;
  border-right: 1px solid mat-color($app-foreground, divider);
  padding: 0 20px;
  height: 100%;

  button {
    color: mat-color($app-foreground, hint-text);

    .mat-icon {
      width: 26px;
      height: 26px;
    }

    &:first-of-type {
      margin-right: 5px;
    }

    &.active {
      color: mat-color($app-foreground, icon);
    }
  }

  select {
    height: 100%;
    border: none;
  }
}

.many-inputs {
  padding-bottom: 10px;

  input:not([type=file]), select {
    background-color: mat-color($app-background, card);
  }
}

.label {
  display: flex;
  flex: 0 0 30px;
  align-items: flex-end;

  .type {
    font-size: 1.5rem;
    color: mat-color($app-foreground, secondary-text);
    display: inline-block;
    font-weight: bold;

    &.selected {
      color: mat-color($app-foreground, text);
      pointer-events: none;
      cursor: default;
    }

    &:last-of-type {
      border-left: 1px solid mat-color($app-foreground, divider);
      padding-left: 7px;
      margin-left: 5px;
    }
  }

  .actions {
    margin-left: auto;
  }
}

.template {
  display: flex;
  min-height: calc(100vh - 445px);
  margin-top: 10px;

  &.column {
    flex-direction: column;

    .editor {
      min-height: 450px;
    }

    mail-template-preview {
      overflow: visible;
      border-left: 1px solid mat-color($app-foreground, divider);
      margin: 25px 0;
    }
  }

  .editor {
    flex: 0 0 50%;
    border: 1px solid mat-color($app-foreground, divider);
    background-color: mat-color($app-background, dialog);
    color: inherit;;
  }
}

@media only screen and (max-width: $medium) {
  .change-layout-action {
    display: none;
  }
}
