/* ==================================================
Studio Colorful v2.0
color-of-life.css
Hero / Serendipity Zone / Archive Masonry / Modal
================================================== */

/* ==================================================
Hero
================================================== */

.life-hero {
  position: relative;
  padding: 200px 6vw 70px;
  overflow: hidden;
}

.life-hero::before {
  content: "";
  position: absolute;
  inset: -14% -14% auto auto;
  z-index: -1;
  width: 56vw;
  height: 56vw;
  max-width: 760px;
  max-height: 760px;
  background:
    radial-gradient(circle at 22% 26%, rgba(178, 209, 190, 0.16), transparent 30%),
    radial-gradient(circle at 78% 32%, rgba(196, 197, 232, 0.14), transparent 30%),
    radial-gradient(circle at 50% 82%, rgba(247, 199, 189, 0.13), transparent 32%);
  filter: blur(46px);
  animation: lifeHeroColorMove 24s ease-in-out infinite alternate;
}

@keyframes lifeHeroColorMove {
  0% {
    transform: translate(-2%, -1%) scale(1);
  }

  50% {
    transform: translate(2%, 2%) scale(1.05);
  }

  100% {
    transform: translate(1%, -2%) scale(1.02);
  }
}

.life-hero__logo-word {
  top: 70px;
  left: 50%;
  width: 100%;
  transform: translateX(-50%);
  text-align: center;
  font-size: clamp(90px, 12vw, 240px);
}

.life-hero__inner {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  column-gap: 24px;
}

.life-hero__head {
  grid-column: 2 / 11;
}

.life-hero__title {
  margin: 14px 0 0;
  font-family: "LINE Seed JP", "Noto Sans JP", sans-serif;
  font-weight: 400;
  font-size: clamp(32px, 5vw, 64px);
  line-height: 1.35;
  letter-spacing: 0.03em;
}

.life-hero__lead {
  margin-top: 28px;
  max-width: 720px;
  font-size: 15px;
  line-height: 2.1;
  letter-spacing: 0.05em;
  color: #555;
}


/* ==================================================
Card（セレンディピティ／アーカイブ共通パーツ）
================================================== */

.life-card {
  display: block;
  width: 100%;
  padding: 8px;
  border: 2px solid #1a1a1a;
  border-radius: 16px;
  background: transparent;
  overflow: hidden;
  box-shadow: none;
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
}

.life-card__photo {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  border-radius: 10px;
  overflow: hidden;
  background: transparent;
}

.life-card__photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.life-card__date-tag {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  width: 80px;
  height: 26px;
  padding-left: 10px;
  box-sizing: border-box;
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  letter-spacing: 0.04em;
  color: #1a1a1a;
  pointer-events: none;
}

.life-card:hover .life-card__photo img {
  transform: scale(1.06);
}

.life-card__expand {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  color: #777;
  transition:
    background 0.25s ease,
    transform 0.25s ease;
}

.life-card__expand svg {
  width: 14px;
  height: 14px;
}

.life-card:hover .life-card__expand {
  background: rgba(255, 255, 255, 0.98);
  transform: scale(1.08);
}


/* ==================================================
Serendipity Zone
扇形に並んだ「スロット」の位置は固定し、
各カードの中身（担当スロット番号）だけが一定間隔で
隣のスロットへ移っていく（横スクロールではない）
================================================== */

.life-serendip {
  position: relative;
  padding: 20px 0 40px;
}

.life-serendip__stage {
  position: relative;
  height: 640px;
  max-width: 1200px;
  margin: 0 auto;
  overflow: visible;
}

.life-serendip-slot {
  position: absolute;
  left: 50%;
  top: 0;
  width: 230px;
  transition:
    transform 1.15s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.8s ease;
  transform:
    translate(-50%, 0)
    translate(var(--x, 0px), var(--y, 0px))
    rotate(var(--r, 0deg));
  opacity: var(--o, 1);
  z-index: var(--z, 1);
}

.life-serendip-slot.is-jumping {
  transition: none;
}


/* ==================================================
Divider
（About「philosophy__note」と同じ縦書きテキスト＋線の処理）
================================================== */

.life-divider {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: fit-content;
  margin: 0 auto;
  padding: 0 0 12px;
}

.life-divider span {
  flex-shrink: 0;
  writing-mode: vertical-rl;
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: #999;
}

.life-divider::after {
  content: "";
  width: 1px;
  height: 48px;
  margin-top: 18px;
  background: rgba(17, 17, 17, 0.35);
}


/* ==================================================
Archive
================================================== */

.life-archive {
  padding: 72px 6vw 170px;
}

.life-archive__label {
  max-width: 1200px;
  margin: 0 auto 76px;
  text-align: center;
}

.life-archive__label .index-label {
  color: #111;
}

.life-archive-grid {
  max-width: 1200px;
  margin: 0 auto;
  column-count: 5;
  column-gap: 14px;
}

.life-card--archive {
  break-inside: avoid;
  margin: 0 0 14px;
  transition:
    opacity 0.9s ease,
    transform 0.9s ease,
    box-shadow 0.35s ease;
}

.life-card--archive:hover {
  transition:
    transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.35s ease;
  transform: translateY(-6px);
  box-shadow: 0 26px 54px rgba(20, 20, 20, 0.12);
}

/* ==================================================
Modal（写真1枚固定）
================================================== */

.life-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

.life-modal.is-open {
  opacity: 1;
  visibility: visible;
}

.life-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 15, 15, 0.72);
  backdrop-filter: blur(6px);
}

.life-modal__panel {
  position: relative;
  z-index: 1;
  width: min(100%, 640px);
  max-height: 88vh;
  overflow-y: auto;
  background: #fdfcf9;
  border-radius: 22px;
  padding: 20px;
  transform: translateY(24px) scale(0.98);
  opacity: 0;
  transition:
    transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.35s ease;
}

.life-modal.is-open .life-modal__panel {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.life-modal__close {
  position: absolute;
  top: 32px;
  right: 32px;
  z-index: 2;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  font-size: 22px;
  line-height: 1;
  color: #222;
  cursor: pointer;
  transition: background 0.25s ease;
}

.life-modal__close:hover {
  background: #fff;
}

.life-modal__content {
  display: grid;
  grid-template-columns: 38% 1fr;
  grid-template-areas:
    "photo info"
    "photo body";
  column-gap: 24px;
}

.life-modal__photo {
  grid-area: photo;
  position: relative;
  aspect-ratio: 9 / 16;
  border-radius: 16px;
  background: #eeece6;
  overflow: hidden;
}

.life-modal__photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.life-modal__info {
  grid-area: info;
  min-width: 0;
  padding: 26px 10px 0 0;
}

.life-modal__date {
  font-family: "Montserrat", sans-serif;
  font-size: 13px;
  letter-spacing: 0.1em;
  opacity: 0.4;
}

.life-modal__title {
  margin: 12px 0 0;
  font-family: "LINE Seed JP", "Noto Sans JP", sans-serif;
  font-size: clamp(22px, 3vw, 30px);
  letter-spacing: 0.02em;
}

.life-modal__subtitle {
  margin-top: 8px;
  font-size: 14px;
  letter-spacing: 0.04em;
  color: #777;
}

.life-modal__subtitle[hidden] {
  display: none;
}

.life-modal__body {
  grid-area: body;
  margin-top: 24px;
  font-size: 14px;
  line-height: 2;
  letter-spacing: 0.04em;
  color: #555;
}


/* ==================================================
Responsive / Tablet
================================================== */

@media (max-width: 1024px) {
  .life-hero {
    padding: 160px 28px 60px;
  }

  .life-hero__head {
    grid-column: 1 / 13;
  }

  .life-archive {
    padding: 36px 28px 130px;
  }

  .life-archive-grid {
    column-count: 3;
  }
}


/* ==================================================
Responsive / Smartphone
================================================== */

@media (max-width: 760px) {
  .life-hero {
    padding: 130px 20px 48px;
  }

  .life-divider span {
    font-size: 9px;
  }

  .life-hero__lead {
    margin-top: 20px;
    font-size: 13.5px;
    line-height: 2;
  }

  .life-serendip {
    padding: 8px 0 20px;
  }

  .life-serendip__stage {
    height: 400px;
  }

  .life-serendip-slot {
    width: 148px;
  }

  .life-archive {
    padding: 32px 20px 96px;
  }

  .life-archive__label {
    margin: 0 auto 56px;
  }

  .life-archive-grid {
    column-count: 2;
    column-gap: 10px;
  }

  .life-card--archive {
    margin: 0 0 10px;
  }

  .life-modal {
    padding: 16px;
  }

  .life-modal__panel {
    padding: 16px;
    max-height: 92vh;
  }

  .life-modal__content {
    grid-template-columns: 100px 1fr;
    grid-template-areas:
      "photo info"
      "body body";
    column-gap: 14px;
  }

  .life-modal__info {
    padding: 0;
  }

  .life-modal__body {
    margin-top: 20px;
  }

  .life-modal__close {
    top: 24px;
    right: 24px;
  }
}
