@import 'variables';

.ltag__stackexchange--container {
  max-width: 620px;
  border: 1px solid $light-medium-gray;
  border-radius: 3px;
  box-shadow: $shadow;
  margin: 1.1em auto 1.3em;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial,
    sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol' !important;
  overflow: hidden;

  .ltag__stackexchange--title-container {
    border-bottom: 1px solid #eaecef;
    display: flex;
    flex-direction: column;

    header {
      display: flex;
      justify-content: space-between;
      .ltag__stackexchange--title {
        h1 {
          margin-left: 5px;
          margin-bottom: 0;
          margin-top: 8px;
          font-size: 1.4em;
          padding-bottom: 0;
          .title-flare {
            background: $sky-blue;
            color: white;
            padding: 0px 7px;
            border-radius: 3px;
          }
          img {
            height: 44px;
            width: 44px;
            display: inline-block;
            vertical-align: -9px;
          }
        }
      }
      .ltag__stackexchange--post-metadata {
        font-size: 0.6em;
        span {
          display: inline-block;
          padding: 7px 6px;
          margin-left: 6px;
        }
      }
      .ltag__stackexchange--score-container {
        margin-right: 15px;
        display: flex;
        width: 50px;
        flex-direction: column;
        flex-wrap: nowrap;
        color: gray;
        font-size: 0.85em;
        align-self: center;
        img {
          position: initial;
          width: 16px;
          height: 16px;
        }
        .ltag__stackexchange--score-number {
          width: 100%;
          height: 20px;
          text-align: center;
          padding-bottom: 10px;
          font-size: 0.8em;
        }
      }
    }
  }

  .ltag__stackexchange--body {
    padding: 1em 0.5em;
    max-height: calc(21vw + 165px);
    overflow: hidden;
    @media screen and (min-width: 430px) {
      max-height: calc(20vw + 153px);
    }
    @media screen and (min-width: 800px) {
      max-height: 310px;
    }

    h1,
    h2,
    h3,
    h4,
    h5,
    h6 {
      font-weight: 500 !important;
    }

    p {
      margin-top: 0px;
      padding: 0px;
      margin-bottom: 15px;
      font-size: 1.1rem;
    }

    code {
      border-radius: 3px;
      padding: 0.2em 5px 0px;
      margin: 0px;
      font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier,
        monospace;
    }

    pre {
      width: 100%;
      margin: 0px;
      padding: 0.2em 0.6em;
      code {
        background-color: #f6f8fa;
        color: black;
        padding: 0em 0px 0px !important;
        line-height: 2em !important;
      }
    }

    .highlight pre,
    pre,
    pre code {
      overflow: auto;
      background-color: #f7f7f7;
      border-radius: 3px;
      box-sizing: border-box;
      color: black;
    }

    .highlight {
      font-size: 14px;
      margin-bottom: 16px;
      border-radius: 3px;
    }
  }

  .ltag__stackexchange--btn--container {
    padding: 0.1em 0 1.15em;
    z-index: 100;
    text-align: center;
    position: relative;
    box-shadow: 0px 0px 60px 42px #fff;
    box-shadow: 0px 0px 60px 42px var(--card-bg);
  }

  .ltag__stackexchange--btn {
    color: #0366d6;
    background-color: #f1f8ff;
    border-radius: 3px;
    line-height: 20px;
    padding: 0.25em 1.2em;
    opacity: 0.9;
    font-weight: bold;
    border: 1px solid #0366d6;
    font-size: 0.75em;
    &:hover {
      opacity: 1;
    }
  }
}
