*,
*::before,
*::after {
  min-width: 0px;
  min-height: 0px;
}

html {
  /* 最小値13pxを保証し、1200px未満では最大22pxまでフォントサイズが流動する */
  font-size: clamp(13px, var(--font-size-base), 22px);

  @media screen and (min-width: 1200px) {
    font-size: clamp(0.1rem, var(--font-size-base), 24px);
  }
}

body {
  font-family: var(--font-serif);
  color: var(--ink);
  background-color: var(--light-gray);
  letter-spacing: 0.08em;
}

#root {
  margin: 0 auto;
}

p,
h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  text-box-trim: trim-both;
}
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: inherit;
  line-height: inherit;
}

img,
iframe {
  max-width: 100%;
}
iframe {
  border: none;
  box-shadow: none;
}

a,
a:hover {
  color: var(--ink);
}

[id] {
  scroll-margin-top: 3.75rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

button {
  position: relative;
  appearance: none;
  cursor: pointer;
  box-shadow: none;
  border: 0;
  outline: none;
  background: none;
  padding: 0;
}

.list {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding-left: 1.5rem;
  list-style: disc outside none;

  & > p {
    margin: 0;
    display: list-item;
  }
}

.webgene-pagination {
  & ul {
    list-style: none;
    display: flex;
    justify-content: center;
    gap: 1.25rem;
    padding: 0;
    margin: 0;

    & li {
      & a {
        display: inline-block;
        width: 3rem;
        line-height: 3rem;
        text-align: center;
        background-color: var(--snow);
        box-shadow: var(--elevation);
        &:hover {
          text-decoration: none;
        }
      }

      &.selected {
        & a {
          background: var(--grad-blue-1);
          color: var(--snow);
          &:hover {
            color: var(--snow);
          }
        }
      }
    }
  }
}

.webgene-no-items {
  width: 100%;
  text-align: center;
  font-size: 0.875rem;
}

.thumbnail {
  position: relative;

  &.thumbnail--16x9 {
    padding-top: 56.25%;
  }
  &.thumbnail--square {
    padding-top: 100%;
  }

  & img,
  & video,
  &:empty::before {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  &:empty::before {
    content: "";
    background-image: url("/system_panel/uploads/images/ogp.png");
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
  }
}

.article-body {
  & > p {
    margin: 1em 0;
  }

  & > h1,
  & > h2,
  & > h3,
  & > h4,
  & > h5,
  & > h6 {
    margin: 2em 0 1em;
  }

  & > *:first-child {
    margin-top: 0;
  }

  & > *:last-child {
    margin-bottom: 0;
  }

  & a,
  & a:hover {
    color: var(--blue);
    text-decoration: underline;
  }
}

.backdrop-object {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  object-fit: cover;
  width: 100%;
  height: 100%;
}

.__mat.__mat--processed {
  word-break: keep-all;
  word-wrap: break-word;
}

:root {
  --elevation: 0 4px 24px 12px rgba(0, 0, 0, 0.08), 0 8px 32px 16px rgba(0, 0, 0, 0.04);
}

.elevation {
  box-shadow: var(--elevation);
}

.footer-links {
  & a {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    
    & p {
      flex: 1 0 0%;
    }
    &::before {
      content: "";
      width: 0.625rem;
      height: 1px;
      background: var(--snow);
    }
    
    &:hover {
      text-decoration: none;
    }
  }
}

.hero-image {
  &::after {
    content: "";
    pointer-events: none;
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0 0 0 / 30%);
  }
  & img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}

.button {
  line-height: 1.25;
  font-size: 1rem;
  font-weight: 700;
  color: var(--snow);
  background: var(--grad-blue-1);
  display: flex;
  align-items: center;
  gap: 2rem;
  padding-block: 1.25rem;
  padding-left: 2.5rem;
  padding-right: 1.25rem;
  text-box-trim: trim-both;
  
  & * {
    text-box-trim: trim-both;
  }
  
  &::after {
    content: "";
    width: 0.875rem;
    height: 0.875rem;
    background-image: url("data:image/svg+xml,%3Csvg%20width%3D%2214%22%20height%3D%2214%22%20viewBox%3D%220%200%2014%2014%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0A%3Cmask%20id%3D%22mask0_150_315%22%20style%3D%22mask-type%3Aalpha%22%20maskUnits%3D%22userSpaceOnUse%22%20x%3D%220%22%20y%3D%220%22%20width%3D%2214%22%20height%3D%2214%22%3E%0A%3Crect%20width%3D%2214%22%20height%3D%2214%22%20fill%3D%22%23D9D9D9%22%2F%3E%0A%3C%2Fmask%3E%0A%3Cg%20mask%3D%22url(%23mask0_150_315)%22%3E%0A%3Cpath%20d%3D%22M4.67018%2012.4289L4.0498%2011.8085L8.85895%206.99934L4.0498%202.1902L4.67018%201.56982L10.0997%206.99934L4.67018%2012.4289Z%22%20fill%3D%22white%22%2F%3E%0A%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A");
    background-repeat: no-repeat;
    transition: transform 200ms linear;
  }
  
  &:hover::after {
    transform: translateX(3px);
  }
  
  &:hover {
    color: var(--snow);
    text-decoration: none;
  }
  
  @media (min-width: 768px) {
    gap: 2.5rem;
  }
}

.blog-list {
  & .webgene-blog {
    display: grid;
    gap: 2.5rem;
  }
  @media (min-width: 768px) {
   	& .webgene-blog {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    & .webgene-no-items, & .webgene-pagination {
      grid-column: span 2 / span 2;
    }
  }
  @media (min-width: 1200px) {
   	& .webgene-blog {
      grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    & .webgene-no-items, & .webgene-pagination {
      grid-column: span 3 / span 3;
    }
  }
}

.news-list {
  & .webgene-blog {
    display: grid;
    gap: 2.5rem;
  }
  @media (min-width: 768px) {
   	& .webgene-blog {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    & .webgene-no-items, & .webgene-pagination {
      grid-column: span 2 / span 2;
    }
  }
}

.clamp-1 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  overflow: hidden;
}

.text-shadow {
  filter: drop-shadow(0 4px 4px rgba(0, 0, 0, 0.16)) drop-shadow(0 -2px 4px rgba(0, 0, 0, 0.08));
}

.elevation-red {
  box-shadow: 0 4px 24px 12px rgba(235, 51, 15, 0.08), 0 8px 32px 16px rgba(235, 51, 15, 0.04);
}

.deco-text {
  position: absolute;
  letter-spacing: 0;
  line-height: 1;
  font-weight: 700;
  font-family: var(--font-display);
  color: var(--snow);
  font-size: 5rem;
  white-space: nowrap;
  
  &.deco-text--blue {
    color: var(--blue);
    opacity: 0.05;
  }
}

.about-concept .deco-text {
  top: -4rem;
  left: 2rem;
  
  @media (min-width: 1024px) {
    left: -4rem;
    font-size: 12.5rem;
  }
}
.about-director .deco-text {
  top: -4rem;
  left: 2rem;
  
  @media (min-width: 1024px) {
    top: -9.625rem;
    left: -4.875rem;
    font-size: 12.5rem;
  }
}
.about-outline .deco-text {
  top: -4rem;
  left: 2rem;
  
  @media (min-width: 1024px) {
    top: -6.5rem;
    left: 4.875rem;
    font-size: 12.5rem;
  }
}
.service-section {
  position: relative;
}
.service-section .deco-text {
  top: 2rem;
  left: 1rem;
  
  @media (min-width: 1024px) {
    top: 1rem;
    left: 5rem;
    font-size: 10rem;
  }
  @media (min-width: 1200px) {
    font-size: 15rem;
  }
}

.facilities {
  overflow: visible;
  &.swiper:not(.swiper-initialized) {
    & .swiper-wrapper {
      overflow: auto;
      display: flex;
    }
    & .swiper-slide {
      width: 25rem;
      min-width: 25rem;
    }
  }
}

.access-map {
  aspect-ratio: 4 / 3;
  position: relative;
  
  & iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
  }
  
  @media(min-width: 1024px) {
    aspect-ratio: unset;
  }
}

.flow-list {
  counter-reset: flow-list;
  & .flow-item {
    counter-increment: flow-list;
    &::before {
      content: counter(flow-list);
      display: flex;
      width: 7.5rem;
      height: 7.5rem;
      align-items: center;
      justify-content: center;
      background-image: url("data:image/svg+xml,%3Csvg%20width%3D%2295%22%20height%3D%2295%22%20viewBox%3D%220%200%2095%2095%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0A%3Cpath%20d%3D%22M79%2040C79%2018.4609%2061.5391%201%2040%201C18.4609%201%201%2018.4609%201%2040C1%2061.5391%2018.4609%2079%2040%2079V80C17.9086%2080%200%2062.0914%200%2040C0%2017.9086%2017.9086%200%2040%200C62.0914%200%2080%2017.9086%2080%2040C80%2062.0914%2062.0914%2080%2040%2080V79C61.5391%2079%2079%2061.5391%2079%2040Z%22%20fill%3D%22url(%23paint0_linear_154_1396)%22%2F%3E%0A%3Cpath%20d%3D%22M94%2055C94%2033.4609%2076.5391%2016%2055%2016C33.4609%2016%2016%2033.4609%2016%2055C16%2076.5391%2033.4609%2094%2055%2094V95C32.9086%2095%2015%2077.0914%2015%2055C15%2032.9086%2032.9086%2015%2055%2015C77.0914%2015%2095%2032.9086%2095%2055C95%2077.0914%2077.0914%2095%2055%2095V94C76.5391%2094%2094%2076.5391%2094%2055Z%22%20fill%3D%22url(%23paint1_linear_154_1396)%22%2F%3E%0A%3Cdefs%3E%0A%3ClinearGradient%20id%3D%22paint0_linear_154_1396%22%20x1%3D%220%22%20y1%3D%2247.5%22%20x2%3D%2295%22%20y2%3D%2247.5%22%20gradientUnits%3D%22userSpaceOnUse%22%3E%0A%3Cstop%20stop-color%3D%22%235EA6DA%22%2F%3E%0A%3Cstop%20offset%3D%221%22%20stop-color%3D%22%233E54AB%22%2F%3E%0A%3C%2FlinearGradient%3E%0A%3ClinearGradient%20id%3D%22paint1_linear_154_1396%22%20x1%3D%220%22%20y1%3D%2247.5%22%20x2%3D%2295%22%20y2%3D%2247.5%22%20gradientUnits%3D%22userSpaceOnUse%22%3E%0A%3Cstop%20stop-color%3D%22%235EA6DA%22%2F%3E%0A%3Cstop%20offset%3D%221%22%20stop-color%3D%22%233E54AB%22%2F%3E%0A%3C%2FlinearGradient%3E%0A%3C%2Fdefs%3E%0A%3C%2Fsvg%3E%0A");
      background-size: contain;
      background-repeat: no-repeat;
      color: var(--blue);
      font-weight: 700;
      font-size: 2rem;
    }
  }
}

.home-slideshow {
  overflow: visible;
  
  &:not(.swiper-initialized) {
    & .swiper-wrapper {
      overflow-x: auto;
      display: flex;
    }
    & .swiper-slide {
      width: 400px;
      min-width: 400px;
    }
  }
  & .swiper-wrapper {
    transition-timing-function: linear;
  }
  & .swiper-slide {
    aspect-ratio: 3 / 4;
    & img {
      width: 100%;
      height: 100%;
      object-fit: cover;
    }
  }
}

.home-service-1, .home-service-2 {
  & *:not(.deco-text) {
    position: relative;
  }
}
.home-service-1 .deco-text {
  top: -7.5rem;
  left: 0.375rem;
}
.home-service-2 .deco-text {
  top: -7.5rem;
  right: 0.375rem;
}
@media (min-width: 1024px) {
  .home-service-1 .deco-text {
    font-size: 12.5rem;
    z-index: -1;
    top: -17rem;
    left: 2.5rem;
  }
  .home-service-2 .deco-text {
    font-size: 12.5rem;
    z-index: -1;
    top: -17rem;
    right: 2.5rem;
  }
}
.home-cataract .deco-text {
  top: -1rem;
  left: -2rem;
  font-size: 2.8rem;
  
  @media (min-width: 1024px) {
    font-size: 7.5rem;
    right: 2.5rem;
    left: unset;
  }
}


.insta-list {
  &.swiper {
    overflow: visible;
  }
  & .swiper-wrapper {
    transition-timing-function: linear;
  }
}

.home-hero {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: clamp(37.5rem, 100dvh, 75rem);
  
  & .home-hero__slider {
    &:not(.swiper-initialized) {
      & .swiper-wrapper {
        overflow-x: auto;
        display: flex;
      }
      & .swiper-slide {
        width: 100%;
        min-width: 100%;
      }
    }
    & .swiper-wrapper {
      height: 100%;
    }
    & .swiper-slide {
      position: relative;
      height: 100%;
    }
  }
}

.home-news {
  z-index: 2;
  & .webgene-blog {
    width: 100%;
  }
  
  @media (min-width: 1024px) {
    position: absolute;
    bottom: 2.5rem;
    left: 2.5rem;
    width: 25rem;
  }
}

.contact-button {
  position: fixed;
  z-index: 2;
  width: 12.5rem;
  bottom: 4rem;
  right: 0rem;
  
  @media (min-width: 1024px) {
    bottom: 0.5rem;
    right: 0.5rem;
    width: 17.5rem;
  }
}

