.notice-dialog {
  position: fixed;
  inset: 0;
  margin: auto;
  padding: 0;
  border: 1px solid #e2e8df;
  width: min(400px, calc(100% - 32px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
  border-radius: 8px;
  color: #253025;
  background: #fff;
  box-shadow: 0 12px 36px rgba(20, 35, 18, 0.16);
}

.notice-dialog::backdrop {
  background: rgba(17, 26, 17, 0.42);
}

.notice-dialog__header {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  border-bottom: 1px solid #e8ece6;
}

.notice-dialog__title {
  margin: 0;
  min-width: 0;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.notice-dialog__body {
  padding: 20px;
  overflow-wrap: anywhere;
}

.notice-dialog__body img {
  max-width: 100%;
  height: auto;
}

.notice-dialog__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 3px 8px 3px 12px;
  border-top: 1px solid #e8ece6;
  background: #f8faf7;
}

.notice-dialog__today,
.notice-dialog__confirm {
  min-height: 44px;
  padding: 8px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  font: inherit;
  font-size: 13px;
  line-height: 1.4;
  cursor: pointer;
}

.notice-dialog__today {
  color: #626e62;
  text-align: left;
}

.notice-dialog__confirm {
  min-width: 64px;
  color: #315d1b;
  font-weight: 700;
}

.notice-dialog__today:focus-visible,
.notice-dialog__confirm:focus-visible,
.notice-dialog__body a:focus-visible {
  outline: 2px solid #6c9f28;
  outline-offset: -2px;
}

@media (max-width: 600px) {
  .notice-dialog {
    width: calc(100% - 32px);
    max-height: calc(100dvh - 32px);
  }

  .notice-dialog__body {
    padding: 16px;
  }
}

.notice-dialog[open] {
  display: flex;
  flex-direction: column;
  width: min(var(--notice-width, 360px), calc(100% - 32px));
  height: min(var(--notice-height, 440px), calc(100dvh - 32px));
  overflow: hidden;
}

.notice-dialog__header,
.notice-dialog__footer {
  flex: none;
}

.notice-dialog__body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
}

.notice-dialog__title:focus {
  outline: none;
}

.notice-dialog__nav[hidden] {
  display: none;
}

.notice-dialog__nav {
  flex: none;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  padding: 0 10px 4px;
}

.notice-dialog__arrow {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #315d1b;
  font-size: 24px;
  cursor: pointer;
}

.notice-dialog__arrow:hover:not(:disabled) {
  background: #edf3e9;
}

.notice-dialog__arrow:disabled {
  color: #b1b9af;
  cursor: default;
}

.notice-dialog__arrow:focus-visible {
  outline: 2px solid #6c9f28;
  outline-offset: -2px;
}

.notice-dialog__count {
  min-width: 42px;
  text-align: center;
  font-size: 13px;
  color: #606b60;
}
