/* page-map.css - 地図選択ページのスタイル */

._map {
  padding-bottom: 150px;
}
.s ._map {
  padding: 74px 0px 110px !important;
}

.s .map-region-select{
  padding: 0 14px;
}

/* 地図で探す　タイトル部分 */
.map-title {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
}
.map-region-title ._break {
  display: none;
}
.map-titile_center {
  justify-self: center;
  text-align: center;
  max-width: 769px;
  width: 100%;
}
.map-title_right {
  width: 100%;
  justify-self: end;
}

.map-region-help {
  /* position: absolute; */
  display: flex;
  justify-content: flex-end;
  gap: 20px;
  top: 9%;
  right: 7%;
}

.help-link {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #0c72be;
  background-color: #fff;
  text-decoration: none;
  font-weight: bold;
  font-size: 0.875rem;
  transition: color 0.3s ease;
  border-radius: 6px;
  padding: 8px 12px;
  box-shadow: 4px 4px 10px #00648033;
}
.s .help-link {
  gap: 5px;
  font-size: 0.75rem;
  border-radius: 6px;
  padding: 8px;
}

.help-link:hover {
  color: #0c72be;
  text-decoration: underline;
}

.help-text {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
  hyphens: auto;
}

.icon-help {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: #fff;
  color: #666;
  border: 2px solid #ccc;
  border-radius: 50%;
  font-size: 1rem;
  flex-shrink: 0;
}

@media screen and (max-width: 1250px) {
  .map-title {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
  }
  .map-region-help {
    justify-content: center;
    gap: 10px;
    padding-top: 16px;
  }
}

/* モーダル */
._map .c-modal,
._map-region .c-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  background-color: rgba(0, 0, 0, 0.1);
  display: none;
  z-index: 100;
}
._map .c-modal_content,
._map-region .c-modal_content {
  width: 70%;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.s ._map .c-modal_content,
.s ._map-region .c-modal_content {
  width: 90%;
}
._map .c-modal_cancel_btn,
._map-region .c-modal_cancel_btn {
  color: #fff !important;
  border: none !important;
}
._map .c-modal_body,
._map-region .c-modal_body {
  height: 360px;
  padding: 20px;
  background-color: #f8f8f8;
  border-radius: 16px;
  overflow-y: auto;
  overscroll-behavior-y: none;
}
.s ._map .c-modal_body,
.s ._map-region .c-modal_body {
  height: 270px;
}
._map .c-modal_body h4,
._map-region .c-modal_body h4 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.125rem;
  font-weight: 700;
  margin-top: 20px;
}
._map .c-modal_body h4::before,
._map-region .c-modal_body h4::before {
  flex-shrink: 0;
  content: '';
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(to bottom, #27c5ff 10%, #006ed6 50%);
}
._map .c-modal_body .c-text-panel__body,
._map-region .c-modal_body .c-text-panel__body {
  width: 85.8%;
  margin: 0 auto;
}
.s ._map .c-modal_body .c-text-panel__body,
.s ._map-region .c-modal_body .c-text-panel__body {
  width: 100%;
}
._map .c-modal_body p,
._map-region .c-modal_body p {
  color: #222;
  font-size: 1rem;
  line-height: 1.8;
}
.s ._map .c-modal_body p,
.s ._map-region .c-modal_body p {
  font-size: 0.8125rem;
}

/* 地域部分 */
.map-region-container {
  position: relative;
  margin: 30px auto 0;
  max-width: 1328px;
}
.map-region-visual {
  position: relative;
  width: 100%;
}

.map-region-intro {
  position: absolute;
  top: -18%;
  left: 30%;
  transform: translatex(-50%);
  width: 74.4%;
}
@media screen and (max-width: 1024px) {
  .map-region-intro {
    top: -15%;
  }
}

.s .map-region-intro {
  top: -20%;
  width: 68%;
  z-index: 1;
}

.map-region-title {
  position: absolute;
  top: 2.5%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  width: 97.5%;
  padding: 1.2% 0;
  border-radius: 12px;
  text-align: center;
  font-size: 1.25rem;
  font-weight: 500;
  color: #fff;
  letter-spacing: 2px;
  background: linear-gradient(90deg, #27c5ff, #1782e7 25%, #006ed6 50%, #1782e7 75%, #1db0f5);
}
.s .map-region-title {
  width: 100%;
  padding: 2% 0;
  font-size: 16px;
}

.map-region-message {
  background: white;
  border: 3px solid #333;
  border-radius: 20px;
  padding: 15px 25px;
  position: relative;
  font-weight: bold;
  font-size: 1rem;
  line-height: 1.8;
}

.map-region-message::before {
  content: '';
  position: absolute;
  left: -15px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 10px 15px 10px 0;
  border-color: transparent #333 transparent transparent;
}

.map-region-message::after {
  content: '';
  position: absolute;
  left: -10px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 8px 12px 8px 0;
  border-color: transparent white transparent transparent;
}

.map-region-instruction {
  background: #1e88e5;
  color: white;
  text-align: center;
  padding: 30px 20px;
  border-radius: 15px;
  margin-bottom: 40px;
}

.map-region-instruction h3 {
  font-size: 1.25rem;
  line-height: 1.8;
  margin: 0;
  font-weight: bold;
}

.yokohama-map {
  width: 100%;
  height: auto;
}

.yokohama-map_pc {
  display: block;
}
.s .yokohama-map_pc {
  display: none;
}

.yokohama-map_sp {
  display: none;
}

/* 地図イラスト */
svg {
  width: 29%;
  position: absolute;
  top: 14%;
  left: 13%;
  transition: 0.3s;
  cursor: pointer;
}

svg path {
  transition: fill 0.3s;
  cursor: pointer;
}
g:hover .st0,
g:hover .st1,
g.active .st0,
g.active .st1 {
    fill: #0C72BE !important;
}

.st2 {
    transition: fill .2s;
}
g:hover .st2,
g.active .st2 {
    fill: #fff !important;
}

@media screen and (max-width: 1024px) {
  .map-region-button {
    font-size: 0.75rem;
  }
}
.s .map-region-button {
  border-radius: 3px;
  padding: 6px 8px 5px 8px;
  font-size: 0.8125rem;
}

._map-region .category_center {
  max-width: unset;
}


/* 地域選択ボタン */
.map-region-wrapper {
  max-width: 540px;
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  border: 4px solid #fff;
  padding: 2.4% 2% 2.4% 3%;
  border-radius: 16px;
  position: absolute;
  top: 22%;
  right: 8%;
  background-color: #e7f7ff;
}
.map-region-wrapper_pc,
.map-region-wrapper_pc .map-region-list {
  display: flex;
}

.map-region-wrapper_sp,
.map-region-wrapper_sp .map-region-list {
  display: none;
}
.map-region-list {
  display: flex;
  gap: 12px;
  padding: 0;
  list-style: none;
  margin: 0;
}
.s .map-region-list {
  gap: 5px 8px;
}
.map-region-item {
  background-color: #fff;
  border-radius: 6px;
  border: 1px solid #ccc;
  text-align: center;
  list-style: none;
  transition: 0.3s all;
}
.map-region-item a {
  display: block;
  padding: 13px 12px 13px 24px;
  color: #222;
  font-size: 1rem;
  text-decoration: none;
  transition: 0.3s all;
}
.map-region-item a::after {
  content: '';
  display: inline-block;
  background: url(../../common/img/arrow-right-02.svg);
  width: 0.75rem;
  height: 0.75rem;
  margin-left: 0.5rem;
}

@media (hover: hover) {
  .map-region-item a:hover {
    color: #fff;
    background-color: #0c72be;
    border-radius: 6px;
  }
}

.map-region-item a:focus,
.map-region-item a.active {
  color: #fff;
  background-color: #0c72be;
  border-radius: 6px;
}
.map-region-item a:hover::after,
.map-region-item a:focus::after,
.map-region-item a.active::after {
  background: url(../../common/img/arrow-right.svg);
}

@media screen and (max-width: 1200px) {
  .map-region-wrapper_pc,
  .map-region-wrapper_pc .map-region-list {
    display: flex !important;
  }

  .map-region-wrapper_sp,
  .map-region-wrapper_sp .map-region-list {
    display: none !important;
  }
  .map-region-wrapper {
    max-width: 450px;
    width: 55%;
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    border: 4px solid #fff;
    padding: 2% 2% 2% 3%;
    border-radius: 16px;
    position: absolute;
    top: 20%;
    right: 1%;
    background-color: #e7f7ff;
  }

  .map-region-item a {
    padding: 8px 7px 8px 15px;
    font-size: 0.78rem;
  }

  .map-region-title {
    padding: 1.2% 0;
    font-size: 1.1rem;
  }
}

@media screen and (max-width: 840px) {
  .map-region-visual,
  .s .map-region-visual {
    position: relative !important;
    width: 100% !important;
    height: 0 !important;
    padding-top: 125% !important; /* SP地図画像の (高さ / 幅 * 100) */
  }

  .yokohama-map_sp,
  .s .yokohama-map_sp {
    display: block !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
  }
  .yokohama-map_pc {
    display: none;
  }
  .map-region-wrapper_pc,
  .map-region-wrapper_pc .map-region-list {
    display: none !important;
  }

  .map-region-wrapper_sp,
  .map-region-wrapper_sp .map-region-list {
    display: flex !important;
    flex-wrap: wrap;
  }
  .map-region-group {
    border: 4px solid #ccc;
    border-radius: 32px;
    background: #fafeff;
    margin-top: 30px;
    padding: 10px;
  }
  .map-region-container {
    position: relative;
    margin: 0 auto;
    max-width: 1328px;
  }
  .map-region-wrapper_pc .map-region-list {
    display: none;
  }
  .map-region-wrapper_sp .map-region-list {
    display: block;
  }
  .map-region-wrapper {
    max-width: unset;
    width: fit-content;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    border: unset;
    padding: 3.8% 3.8% 3.8% 3.8%;
    margin: 10px auto 0;
    border-radius: 16px;
    position: relative;
    top: unset !important;
    right: unset !important;
  }

  .map-region-title {
    position: unset;
    transform: unset;
    width: 96%;
    padding: 2% 0;
    margin: 0 auto 10px;
  }
  .map-region-title ._break {
    display: block;
  }

  svg {
    width: 89%;
    position: absolute;
    top: 3.1%;
    left: 6.7%;
    transition: 0.3s;
    cursor: pointer;
  }

  /* 地域イラスト */
  .map-region-item a {
    padding: 12px 3px 12px 10px;
    width: 92px;
    font-size: 0.8rem;
    text-align: left;
  }
  .map-region-item a::after {
    width: 10px;
    height: 10px;
    background-size: contain !important;
    background-repeat: no-repeat !important;
    margin-left: 0.3rem;
  }
}

@media screen and (max-width: 575px) {
  .map-region-group {
    border: 2px solid #ccc;
  }
  .map-region-visual,
  .s .map-region-visual {
    padding-top: 135% !important;
  }
  .s svg {
    width: 96%;
    position: absolute;
    top: 3.1%;
    left: 1.5%;
    transition: 0.3s;
    cursor: pointer;
  }
}

@media screen and (max-width: 480px) {
  .s .map-region-title {
    width: 100%;
    padding: 2.5% 0;
    font-size: 13px;
    letter-spacing: 1px;
  }
  .map-region-visual,
  .s .map-region-visual {
    padding-top: 126% !important;
  }

  .s svg {
    width: 91%;
    position: absolute;
    top: 2.5%;
    left: 5.7%;
    transition: 0.3s;
    cursor: pointer;
  }
}

._map .c-text-panel__header,
._map-region .c-text-panel__header {
  margin-bottom: 16px;
  padding-top: 40px;
  padding-bottom: 14px;
  font-size: 1.5rem;
}
.s ._map .c-text-panel__header,
.s ._map-region .c-text-panel__header {
  margin-bottom: 16px;
  padding-top: 40px;
  padding-bottom: 14px;
  font-size: 1rem;
}

._map .c-text-panel__header:first-of-type,
._map-region .c-text-panel__header:first-of-type {
  padding-top: 16px;
}

.c-text-panel_smallText {
  font-size: 0.75rem;
}
.text-indent {
  padding-left: 1.7em;
  text-indent: -1em;
}
._map .c-modal_body ul,
._map-region .c-modal_body ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 5px 30px;
}
._map .c-modal_body ul li,
._map-region .c-modal_body ul li {
  width: 100px;
}
._map .c-modal_body ul li a,
._map-region .c-modal_body ul li a {
  width: 100%;
  display: contents;
}

._map .c-text-panel__link,
._map-region .c-text-panel__link,
.c-text-panel__email,
.c-text-panel_link {
  text-decoration: none;
  color: #1a0dab;
}
.s ._map .c-text-panel__link,
.s ._map-region .c-text-panel__link,
.s .c-text-panel__email,
.s .c-text-panel_link {
  font-size: 0.8125rem;
}
._map .c-text-panel__link:hover,
._map-region .c-text-panel__link:hover,
.c-text-panel__email:hover,
.c-text-panel_link:hover {
  text-decoration: underline;
}
/* ボックス */
.c-text-panel__box {
  padding: 20px 24px;
  border: 1px solid #ccc;
  border-radius: 12px;
  background-color: #fff;
}
.c-text-panel__box .c-text-panel_smallText {
  color: #666666;
}
.c-text-panel__box-liner {
  padding: 10px;
  border-bottom: 2px dotted #e5e5e5;
}
/* リンク */
._map .c-text-panel__link--external::after,
._map-region .c-text-panel__link--external::after {
  width: 24px;
  height: 24px;
  background-image: url(../../common/img/icon-outLink.png);
}
.s ._map .c-text-panel__link--external::after,
.s ._map-region .c-text-panel__link--external::after {
  width: 16px;
  height: 16px;
}

/* h4テキスト */
._map .c-modal_body h4 span {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
  hyphens: auto;
}
/* PDFボタンのスタイル */
.s ._map .c-pdf-card__inner,
.s ._map-region .c-pdf-card__inner {
  padding: 12px 26px 12px 12px;
}

/* 指定緊急避難場所　リスト */
.c-text-panel__flex {
  display: flex;
  gap: 40px;
  padding-top: 30px;
}
.s .c-text-panel__flex {
  flex-direction: column;
  gap: 40px;
  padding-top: 30px;
}
.c-text-panel__flex-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.c-text-panel__flex-list ul {
  width: 234px;
}
.c-text-panel_largeItem {
  width: 280px !important;
}
.c-text-panel_largeItem .c-text-panel__link--external::after {
  top: 0.1em;
}
.c-text-panel__flex-list h4 {
  margin-top: 0 !important;
}
