
@charset "utf-8";
/* ーーーーーーーーーーーーーーーーーーーーー */

body:has(dialog[open]) {
  overflow: hidden;
}

dialog {
  /* position: fixed で画面上の固定位置に配置 */
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, calc(-50% + 50px)); /* 中央より下に配置 */
    max-height: 90vh;
    overflow: hidden;
    margin: 0;
    border: none;
    border-radius: 12px;
    padding: 0;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    width: 75%;
    /* アニメーション用の初期状態（下から） */
    opacity: 0;
    transition: opacity 0.4s ease, transform 0.4s ease, display 0.4s allow-discrete;
}

/* 開いている状態 */
dialog[open] {
    opacity: 1;
    transform: translate(-50%, -50%); /* 中央に移動 */
}

/* 閉じるアニメーション用 */
@starting-style {
  dialog[open] {
    opacity: 0;
    transform: translate(-50%, calc(-50% + 50px)); /* 下から */
  }
}

/* 閉じる時のアニメーション */
dialog.closing {
  opacity: 0;
  transform: translate(-50%, calc(-50% + 50px)); /* 下に戻る */
  pointer-events: none; /* クリックを無効化 */
}

dialog.closing::backdrop {
  background-color: rgba(0, 0, 0, 0);
  backdrop-filter: blur(0px);
}

/* 背景のアニメーション */
dialog::backdrop {
  background-color: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(3px);
  transition: background-color 0.3s ease, backdrop-filter 0.3s ease, display 0.3s allow-discrete;
}

@starting-style {
  dialog[open]::backdrop {
    background-color: rgba(0, 0, 0, 0);
    backdrop-filter: blur(0px);
  }
}

/* ダイアログのコンテンツ */
.dialog-content {
  padding: 30px;
  max-height: calc(90vh - 60px);
  overflow-y: auto;
}

dd,
dl,
dt {
  margin: 0;
}

/* ボタンのスタイル */
button {
  padding: 12px 24px;
  border: none;
  border-radius: 6px;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-primary {
  background-color: #007bff;
  color: white;
}

.btn-primary:hover {
  background-color: #0056b3;
}

.btn-secondary {
  background-color: #6c757d;
  color: white;
}

.btn-secondary:hover {
  background-color: #545b62;
}

.dialog-body {
  color: #666;
  line-height: 1.6;
  margin-bottom: 25px;
}

.dialog-body img {
  /* max-width: 350px; */
  width: 100%;
  height: auto;
}

.dialog-footer {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

/* 個別のダイアログアニメーション（削除：統一するため） */
/* すべてのダイアログが同じアニメーションを使用 */

.dialog-poster-item {
  display: flex;
}

.dialog-poster-item dt {
  margin-bottom: 2%;
}

.dialog-poster-item dd {
  margin-bottom: 10%;
}

.dialog-poster-item dl {
  border-left: 1px #001933 solid;
  padding: 2%;
}

.dialog-poster-item div {
  padding: 2% 4% 2% 0;
}

.dialog-web-border {
  border-bottom: 1px #001933 solid;
  display: flex;
  justify-content: space-around;
}

.dialog-web-text {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 2% 0;

}

.dialog-web-text dl {
  width: calc(100% / 2 - 10px);
  flex-basis: calc(100% / 2 - 10px);
}

@media screen and (max-width:768px) {
  dialog {
    width: 70%;
  }

  .dialog-poster-item {
    display: block;
  }

  .dialog-poster-item dl {
    border: none;
    border-top: 1px #000 solid;
  }

  .dialog-poster-item-img {
    text-align: center;
  }

  .dialog-poster-item-img p {
    margin: auto;
    text-align: center;
  }
}
