.menu_dialog {
  --ease: cubic-bezier(.22, .72, .24, 1);
  inset: 0 0 0 auto;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  width: min(440px, calc(100% - 16px));
  max-width: none;
  height: 100%;
  height: 100dvh;
  max-height: none;
  overflow-y: auto;
  overscroll-behavior: contain;
  color: var(--color-ink);
  background: var(--color-paper);
  border: 0;
  box-shadow: -12px 0 48px rgb(35 24 17 / .16);

  &[open] { display: flex; flex-direction: column; }
  &::backdrop { background: rgb(32 24 20 / .48); }
  .top {
    padding: 16px 18px 24px 28px;
    min-height: clamp(148px, 24dvh, 212px);
    flex: none;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    background: linear-gradient(90deg, rgb(26 17 17 / .78), rgb(26 17 17 / .08)), url("../images/november.webp") center 48% / cover;
    color: var(--color-paper);
    .title { align-self: end; }
    .wordmark { font-size: 40px; }
    h2 { margin-top: 8px; font-size: 16px; font-weight: 500; line-height: 1.5em; }
  }
  .close {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border: 1px solid rgb(247 243 235 / .68);
    border-radius: 50%;
    color: var(--color-paper);
    background: rgb(32 24 20 / .55);
    cursor: pointer;
    span {
      display: grid;
      &::before, &::after {
        grid-area: 1 / 1;
        width: 18px;
        height: 1px;
        background: currentColor;
        content: "";
      }
      &::before { transform: rotate(45deg); }
      &::after { transform: rotate(-45deg); }
    }
  }
  .menu_slot { display: flex; flex: 1 0 auto; }
  .page_index {
    padding: 28px 28px max(28px, env(safe-area-inset-bottom));
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 24px;
    .group_title {
      margin-bottom: 6px;
      display: flex;
      align-items: center;
      gap: 10px;
      color: var(--color-wine);
      font-size: 14px;
      line-height: 1.6em;
      &::before { width: 22px; height: 1px; background: currentColor; content: ""; }
    }
    ul { display: grid; }
    .menu_group:first-child ul {
      grid-template-columns: repeat(2, minmax(0, 1fr));
      column-gap: 20px;
    }
    li { border-bottom: 1px solid var(--color-line); }
    a {
      min-height: 52px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
      font-size: 18px;
      line-height: 1.5em;
      word-break: normal;
      &::after {
        margin-right: 3px;
        flex: none;
        width: 6px;
        height: 6px;
        border-top: 1px solid currentColor;
        border-right: 1px solid currentColor;
        transform: rotate(45deg);
        color: var(--color-wine);
        content: "";
      }
    }
    .plan_link {
      margin-top: auto;
      padding: 14px 20px;
      color: var(--color-paper);
      background: var(--color-wine);
      &::after { width: 8px; height: 8px; color: inherit; }
    }
  }
  @media (max-width: 359px) {
    width: 100%;
    .top { padding-left: 20px; }
    .page_index { padding-inline: 20px; }
  }
  @media (prefers-reduced-motion: no-preference) {
    &[open] {
      transform: translateX(0);
      transition: transform .4s var(--ease);
      @starting-style { transform: translateX(100%); }
    }
    &[open]::backdrop {
      opacity: 1;
      transition: opacity .32s ease-out;
      @starting-style { opacity: 0; }
    }
    &[open] .title, &[open] .menu_group, &[open] .plan_link {
      animation: drawer_content .36s var(--ease) backwards;
    }
    &[open] .title { animation-delay: .06s; }
    &[open] .menu_group:first-child { animation-delay: .11s; }
    &[open] .menu_group:nth-child(2) { animation-delay: .17s; }
    &[open] .plan_link { animation-delay: .23s; }
    &[open].is_closing { transform: translateX(100%); transition: transform .2s ease-in; }
    &[open].is_closing::backdrop { opacity: 0; transition-duration: .2s; }
    a { transition: color .2s, background-color .2s; }
    a::after, .close span { transition: transform .22s var(--ease); }
  }
  @media (hover: hover) {
    .page_index li a:hover { color: var(--color-wine); }
    .page_index a:hover::after { transform: translateX(3px) rotate(45deg); }
    .page_index .plan_link:hover { background-color: var(--color-wine-dark); }
    .close:hover span { transform: rotate(90deg); }
  }
}

@keyframes drawer_content {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

/* 最終更新: 2026-11-27 17:29 */
