:root {
  --asbsq-color-accent: #DD3333;
  --asbsq-color-border: #DDD;
}

.l-header__content {
  padding-top: 0;

  .l-1row-header__branding {
    padding: 5px 0;

    .c-site-branding__title {
      .custom-logo {
        min-width: 240px;
      }
    }
  }
}

.logo-ruby {
  display: block;
  font-size: 0.8rem;
  font-weight: bold;
}

.key-visual.smb-spider-slider {
  width: 100vw;
  height: calc(100vh - 82px);

  @media screen and (min-width: 640px) {
    max-height: 1280px;
    height: 100vw;
    overflow: hidden;
  }

  @media screen and (min-width: 1024px) {
    max-height: 690px;
    height: 690px;
  }

  .spider,
  .spider__canvas,
  .smb-spider-slider__figure-wrapper {
    height: 100%;

    img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      object-position: center;
    }
  }

  .spider__slide {
    .smb-spider-slider__figure-wrapper {
      transform: scale(1.0);
      transition: transform 5s;
      transition-timing-function: ease-in;
    }

    &[data-active="true"] {
      .smb-spider-slider__figure-wrapper {
        transform: scale(1.06);
      }
    }
  }

  .logo-kv {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.4);
    z-index: 10;
    color: white;
    font-size: 0.9rem;
    font-weight: bold;

    img {
      width: 30vw;
      max-width: 120px;
    }
  }
}

h2.smb-section__title,
.c-entry__body h2.wp-block-heading {
  position: relative;
  padding: 0.5em 1em;

  &::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    width: 7px;
    height: 100%;
    background-color: var(--asbsq-color-accent);
  }
}

#aboutus .smb-section__lede-wrapper {
  font-weight: bold;
  color: var(--asbsq-color-accent);
  margin: 0;
}

#aboutus h2.smb-section__title {
  --_font-size-level: 3;
  display: inline-block;
  margin: var(--_margin-2) 0 0 0.5em;
  transform: translateY(2rem);
  opacity: 0;
  transition: transform 0.5s, opacity 0.5s;

  @media screen and (min-width: 640px) {
    --_font-size-level: 4;
  }

  &::before {
    display: inline-block;
    transform: rotate(-30deg);
    top: auto;
    bottom: 0.5rem;
    left: -1rem;
    width: 4px;
    height: 2.4em;
  }

  &::after {
    position: absolute;
    display: inline-block;
    transform: rotate(30deg);
    top: auto;
    bottom: 0.5rem;
    right: 0;
    width: 4px;
    height: 2.4em;
    margin: 0;
  }

  &.on-screen {
    transform: translateY(0);
    opacity: 1;
  }
}

.c-entry__header {
  display: flex;
  flex-direction: column-reverse;
  border-width: 1px 0 1px;
  border-color: var(--asbsq-color-border);
  border-style: solid;
  padding: 50px 0;

  .c-entry__meta {
    margin-top: 0;
    margin-bottom: var(--_margin-2);

    .c-meta {
      display: flex;
      flex-direction: row-reverse;
      justify-content: flex-end;

      .c-meta__item--modified,
      .c-meta__item--author {
        display: none;
      }

      .c-meta__item--categories {
        margin-right: 0.75em;

        .svg-inline--fa.fa-folder {
          display: none;
        }

        .c-meta__term a {
          border: 1px solid var(--asbsq-color-accent);
          border-radius: 999px;
          color: var(--asbsq-color-accent);
          padding: 5px 15px;
          text-decoration: none;
          transition: color 0.3s, background-color 0.3s;

          &:hover {
            color: white;
            background-color: var(--asbsq-color-accent);
          }
        }
      }
    }
  }
}

.smb-buttons {
  opacity: 0;
  transform: translateY(2rem);
  transition: opacity 1.2s, transform 1.2s;

  &.on-screen {
    opacity: 1;
    transform: translateY(0);
  }
}

a.smb-btn {
  border-radius: 9999px;
  padding: 0.7em 1.4em;

  &[target="_blank"] {
    &::before {
      content: "";
      padding-left: 1rem;
    }

    &::after {
      padding: 0 0.3rem;
    }
  }
}

a[target="_blank"]:not(:has(img)) {
  &::after {
    content: "➚";
  }
}

a .c-entry-summary .c-entry-summary__figure img {
  transition: transform 0.5s;
  transform: scale(1.0);
}

a:hover .c-entry-summary .c-entry-summary__figure img {
  transform: scale(1.2);
}

#feature>.smb-media-text[data-sm-split-point=lg] {
  margin-top: 0;

  &>.c-row--fill>.c-row__col {
    &>.smb-media-text__contents-wrapper {
      margin: calc(var(--_margin1) * var(--_margin-top)) var(--smb-media-text--gap) calc(var(--_margin1) * var(--_margin-top) * 2.5);

      @media screen and (min-width: 1024px) {
        margin-bottom: calc(var(--_margin1) * var(--_margin-top));
      }

      .smb-media-text__title {
        position: relative;
        --_font-size-level: 2;

        @media screen and (min-width: 640px) {
          --_font-size-level: 4;
        }

        &::before {
          content: '';
          display: inline-block;
          position: absolute;
          background-color: unset;
          background-image: url(img/bisky-shadow.webp);
          background-repeat: no-repeat;
          background-position: left top;
          background-size: 120px;
          width: 120px;
          height: 120px;
          opacity: 0;
          transition: opacity 1.2s 0.5s, transform 1.2s 0.5s;
          transform: scale(2.0) translate(calc(4px - var(--_container-margin-left)), 0);
        }

        &.on-screen::before {
          opacity: 0.15;
          transform: scale(1.0) translate(calc(4px - var(--_container-margin-left)), -20px);
        }
      }

      .has-sm-s-font-size {
        margin-top: 0;
      }
    }

    &>.smb-media-text__figure {
      min-height: 30vh;

      >img {
        filter: grayscale(100%);
        transition: filter 3s;

        &.on-screen {
          filter: grayscale(0);
        }
      }
    }
  }
}

.blog,
.archive {
  .l-contents__main .p-archive .c-entries.c-entries--simple .c-entries__item {
    >a {
      @media screen and (min-width: 1024px) {
        padding: 0;
      }

      &:hover {
        .c-entry-summary__header {
          color: var(--asbsq-color-accent);
        }
      }

      .c-entry-summary {
        display: flex;
        flex-direction: column;

        .c-entry-summary__figure {
          width: 100%;
          height: 150px;
          margin: 0;
          overflow: hidden;

          &::before {
            content: none;
          }

          >img {
            width: 100%;
            height: 100%;
            object-fit: cover;
          }

          >.c-entry-summary__term {
            display: none;
          }
        }

        .c-entry-summary__body {
          width: 100%;
          padding: 50px;

          .c-entry-summary__meta .c-meta__item--categories {
            display: inline-block;

            .c-entry-summary__term {
              border: 1px solid var(--asbsq-color-accent);
              border-radius: 999px;
              color: var(--asbsq-color-accent);
              background-color: white;
              padding: 5px 15px;
              transition: color 0.3s, background-color 0.3s;
            }
          }
        }

        @media screen and (min-width: 640px) {
          .c-entry-summary__figure {
            height: 200px;
          }
        }

        @media screen and (min-width: 1024px) {
          flex-direction: row-reverse;

          .c-entry-summary__figure {
            width: 50%;
            height: auto;
            margin: 0;
          }

          .c-entry-summary__body {
            width: 50%;
          }
        }
      }
    }
  }
}

.p-breadcrumbs-wrapper .c-breadcrumbs li:last-child {
  color: var(--asbsq-color-accent);
}

#topics {
  .spider__arrow {
    background-color: var(--asbsq-color-accent);
    transition: opacity 0.3s;

    &::before {
      border-width: 2px;
    }

    &:hover {
      opacity: 0.5;
    }
  }

  .spider__dot[aria-current="true"] {
    background-color: var(--asbsq-color-accent);
  }

  .smb-rss .c-entry-summary__content {
    display: none;
  }

  .wp-block-social-links .wp-social-link {
    &.wp-social-link-chain {
      color: white;
      background-color: var(--asbsq-color-accent);
    }

    a::after {
      font-size: var(--_font-size);
    }
  }
}

#inquiry {
  label {
    font-size: larger;
    font-weight: bold;

    .require {
      color: var(--asbsq-color-accent);
      font-size: small;

      &::before {
        content: '※';
      }
    }
  }

  .wpcf7-not-valid-tip {
    border: 1px solid var(--asbsq-color-accent);
    border-radius: 4px;
    margin: 0.8rem 0;
    padding: 0.5rem 1rem;
    font-size: var(--_font-size);
  }

  .wpcf7 form.invalid .wpcf7-response-output,
  .wpcf7 form.unaccepted .wpcf7-response-output,
  .wpcf7 form.payment-required .wpcf7-response-output {
    border: none;
    border-radius: 4px;
    color: white;
    background-color: var(--asbsq-color-accent);
    padding: 0.5rem 1rem;
    font-weight: bold;
  }

  .wpcf7 form.sent .wpcf7-response-output {
    border-radius: 4px;
    padding: 0.5rem 1rem;
    font-weight: bold;
  }

  .wpcf7 .wpcf7-submit:disabled {
    background-color: var(--asbsq-color-border);
    opacity: 0.8;
    transition: opacity 0.3s, background-color 0.3s;
  }
}

.privacy-policy .wp-block-list li::before {
  content: counter(sme-count, lower-alpha);
  color: white;
  background-color: var(--asbsq-color-accent);
  font-weight: bold;
}

.l-footer {
  .l-footer__header {
    padding: 0.8rem 0;
  }

  .l-footer__footer {
    background-color: inherit;
    padding: 0;

    .c-fluid-container {
      padding-left: 0;
      padding-right: 0;

      .c-row {
        display: block;
        text-align: center;

        .l-footer__copyright {
          position: relative;

          >div {
            padding: 0.8rem 0;

            &.footer-links {
              border-top: 1px solid var(--asbsq-color-border);

              @media screen and (min-width: 640px) {
                position: absolute;
                padding-left: var(--_container-margin-left);
              }

              a {
                display: inline-block;
                border: 1px solid var(--asbsq-color-border);
                border-radius: 50%;
                width: 25px;
                height: 25px;
                vertical-align: text-top;
                transition: opacity 0.3s, background-color 0.3s, border-color 0.3s;

                &:hover {
                  background-color: var(--asbsq-color-border);
                  opacity: 0.5;
                  border-color: var(--asbsq-color-accent);
                }

                img {
                  vertical-align: baseline;
                }
              }
            }

            &.c-copyright {
              padding: 0.8rem 0;
              border-top: 1px solid var(--asbsq-color-border);
            }
          }
        }
      }
    }
  }
}

#page-top.c-page-top {
  background-color: unset;
  background-image: url(img/bisky-shadow.webp);
  background-repeat: no-repeat;
  background-position: left top;
  background-size: 100px;
  width: 60px;
  height: 100px;
  transition: opacity 0.8s, transform 0.8s;
  transform: translateX(60px);

  &[aria-hidden=false] {
    transform: translateX(0);
  }

  a {
    flex-direction: column;

    &::after {
      content: 'TOP';
      font-size: 0.8rem;
      padding: 0.8rem 0;
    }
  }
}