/* =========================
   Variables
========================= */
:root {
  --primary: #002870;
  --primary-light: #e8eef9;
  --text-gray: #555;
  --white: #fff;
  --border: #d0d7e2;

  --overlay: rgba(0, 0, 0, .7);
  --shadow: 0 2px 8px rgba(0, 0, 0, .3);
}

/* 共通幅 */
#langFilter,
#introArea,
#mapTitle,
#portFilter,
#searchBox,
#myTable {
  width: 70%;
  min-width: 700px;
}



/* =========================
   Table
========================= */


#myTable th {
  font-size: 14px;
  padding: 8px !important;
  background: #002870;
  color: #fff;
}

#myTable td {
  font-size: 14px;
  padding: 6px 8px !important;
}

#myTable thead th {
  background: #002870 !important;
  color: #fff !important;
}

/* =========================
   Search
========================= */
#searchBox {
  text-align: left;
  margin-bottom: 15px;
}

#searchname {
  border: 1px solid #666 !important;
  outline: none;
  background: #fff !important;
  appearance: auto;
  -webkit-appearance: auto;
}

#clearBtn {
  height: 30px;
  padding: 0 15px !important;
  font-size: 14px;

  background: #f5f5f5;
  border: 1px solid #999;
  cursor: pointer;

  transition: background-color .2s ease;
}

#clearBtn:hover,
#clearBtn:focus {
  background: #e5e5e5;
}

#clearBtn:active {
  background: #d5d5d5;
}

/* =========================
   Table Hover
========================= */
.map-row {
  cursor: pointer;
}

.map-row:hover td {
  background: var(--primary-light);
}

/* =========================
   Modal
========================= */
.refund-map-modal {
  position: fixed;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100vw;
  height: 100vh;
  background: var(--overlay);
  z-index: 99999;
}

.refund-modal-content {
  position: relative;
  width: 85vw;
  height: 85vh;
  background: var(--white);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

#modalMapImage {
  width: auto;
  height: auto;
  max-width: none;
  max-height: none;
  object-fit: contain;
  cursor: grab;
  user-select: none;
  touch-action: none;
  transform-origin: 0 0;
}

#mapMessage,
.map-modal-close {
  z-index: 100001;
  padding: 6px 10px !important;
  color: #000;
  background: rgba(255, 255, 255, .95);
  border-radius: 4px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .2);
}

#mapMessage {
  position: absolute;
  top: 15px;
  left: 15px;
  max-width: 70%;
  font-size: 16px;
  font-weight: bold;
  word-break: break-word;
}

.map-modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  font-size: 18px;
  font-weight: bold;
  line-height: 1;
}

.map-modal-close:hover {
  background: var(--white);
}


.map-modal-close,
.map-modal-close:link,
.map-modal-close:visited,
.map-modal-close:hover,
.map-modal-close:active,
.map-modal-close:focus {
  color: #000 !important;
  text-decoration: none !important;
}


/* =========================
   Language Filter
========================= */


.lang-tab {
  display: inline-block;

  padding: 7px 16px !important;

  margin-right: 8px;

  font-size: 16px;
  font-weight: bold;
  color: var(--primary);
  border: 2px solid var(--primary);
  background: #fff;

  border-radius: 6px;

  cursor: pointer;
}

.lang-tab.active {
  background: var(--primary);
  color: #fff;
}


.lang-tab:hover:not(.active) {
  background: #eef5ff;
}

/* =========================
   Port Filter
========================= */
#portFilter {
  margin-bottom: 10px;
}

.port-tab {
  display: inline-block;
  margin-right: 15px;
  padding: 4px 0 !important;
  cursor: pointer;
  font-size: 16px;
  font-weight: bold;
  color: var(--text-gray);
}

.port-tab.active {
  color: #000;
  border-bottom: 3px solid var(--primary);
}

/* =========================
   Popup
========================= */
.vjw-popup {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 500px !important;
  min-width: 500px !important;
  max-height: 85vh;
  overflow-y: auto;
  padding: 10px !important;
  background: var(--white);
  border: 2px solid #23384d;
  box-shadow: var(--shadow);
  z-index: 100000;
  overscroll-behavior: contain;
  transition:
    top 0.3s ease,
    right 0.3s ease,
    bottom 0.3s ease,
    left 0.3s ease;
}

.vjw-header {
  padding: 4px !important;
  text-align: right;
  border-bottom: 1px solid #ddd;
}

.vjw-btn {
  width: 30px;
  height: 30px;
  border: 1px solid #666;
  background: var(--white);
  cursor: pointer;
}

.vjw-summary {
  padding: 12px 16px 6px !important;
}

.vjw-detail {
  padding: 0 16px 12px !important;
}

.vjw-detail,
.vjw-summary {
  box-sizing: border-box;
  width: 100%;
}

.vjw-detail b {
  display: block;
  margin-top: 10px;
}

.vjw-link {
  color: #0066cc;
  text-decoration: underline;
  cursor: pointer;
}

/* =========================
   Wi-Fi
========================= */
.wifiBox {
  margin: 8px 0 !important;
  padding: 10px 12px !important;
  background: var(--white);
  border-radius: 20px;
}

.wifiTitle {
  margin-bottom: 10px;
  text-align: center;
  font-weight: bold;
}

.wifiContents {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.wifiInfo {
  flex: 1;
  min-width: 240px;
  line-height: 1.4;
}

.wifiLabel {
  font-weight: bold;
}

.wifiQrWrap {
  flex-shrink: 0;
}

.wifiQr {
  width: 80px;
  display: block;
  height: auto;
}

/* =========================
   Direction
========================= */
.directionBox {
  margin: 8px 0 !important;
  overflow: hidden;
  border-radius: 20px;
  background: #dfeaf5;
}

.directionTitle {
  padding: 8px 15px !important;
  font-size: 14px;
  font-weight: bold;
  color: var(--white);
  background: #4f8fce;
}

.directionBody {
  padding: 8px 10px !important;
}

.stepTitle {
  margin-bottom: 5px;
  font-size: 14px;
  font-weight: bold;
}

.stepText {
  margin-bottom: 8px;
  padding-left: 10px !important;
}


#noMapNotice {
  display: none;

  width: 100%;
  height: 100%;

  padding: 80px 40px 40px !important;

  box-sizing: border-box;

  text-align: center;

  align-items: center;
  justify-content: center;

  font-size: 20px;
  line-height: 1.8;
}

body.modal-open {
  overflow: hidden;
}

/* =========================
   title
========================= */

.titleArea {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;

  border-bottom: 2px solid var(--border);
  padding-bottom: 10px !important;
  margin-bottom: 20px;
}

#pageTitle {
  flex: 1;
  margin-bottom: 0;
}

.titleImage img {
  width: 220px;
  height: auto;
}

/* =========================
   Intro
========================= */
.introTop {
  display: block;
  justify-content: space-between;
  align-items: flex-start;
  gap: 30px;
}

.introTextBlock {
  width: 100%;
  padding-right: 0 !important;
}

.introTextBlock p {
  margin: 0;
}

.intro-right {
  position: static;
  flex-shrink: 0;
}

.intro-right img {
  width: 180px;
  max-width: 100%;
  height: auto;
}

.legendItem {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
}

.legendItem img {
  width: 55px;
  height: auto;
}

.legendItem span {
  font-size: 16px;
  font-weight: 600;
}

.legendArea {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;

  flex-wrap: nowrap;
  /* 折り返し禁止 */
  padding-left: 0 !important;
}

#mapTitle {
  font-weight: bold;
  color: #002870;
  border-bottom: 3px solid #002870;
  padding-bottom: 5px !important;
}

.notes {
  width: 100%;
  line-height: 1.6;

  font-size: 14px;
  color: #444;
}

.scroll-hint-icon-wrap {
  display: none;
}

#pageTitle {
  font-size: 28px;
  line-height: 1.4;
  color: #002870;
  font-weight: bold;
  margin-bottom: 0px;
}



/* =========================
   Smartphone
========================= */
@media screen and (max-width:767px) {

  .tableWrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  #pageTitle {
    font-size: 18px;
  }


  #langFilter,
  #introArea,
  #mapTitle,
  #portFilter,
  #searchBox,
  #myTable {
    width: 100%;
    min-width: 0;
  }



  #myTable th,
  #myTable td {
    font-size: 15px;
    white-space: nowrap;
  }

  #langFilter,
  #portFilter,
  #searchLabel {
    font-size: 16px;
  }

  #searchLabel {
    font-weight: bold;
  }

  .lang-tab {
    font-size: 16px;
  }

  .port-tab {
    font-size: 16px;
  }

  #searchname {
    width: 100%;
    max-width: 100%;
  }

  #clearBtn {
    margin-top: 10px;
  }

  .refund-modal-content {
    width: 85vw;
    height: 85dvh;
    margin: auto;
    border-radius: 8px;
  }


  #mapModal {
    width: 100vw !important;
    height: 100vh !important;
  }

  #mapModal .refund-modal-content {
    width: 95% !important;
    max-width: 900px !important;
    height: 80vh !important;
    max-height: 80vh !important;
  }

  #contents #mapModal {
    position: fixed !important;
    width: 100vw !important;
    height: 100vh !important;
  }

  #contents #mapModal .refund-modal-content {
    height: 85dvh !important;
  }


  #contents #mapModal #modalMapImage {
    flex: 1;
    max-width: none !important;
    max-height: none !important;
    margin: 0 !important;
  }


  #mapMessage {
    max-width: 60vw;
    font-size: 12px;
  }

  .map-modal-close {
    font-size: 16px;
  }

  .vjw-popup {
    position: fixed;
    top: calc(100dvh - 180px);
    left: 10px;
    right: 10px;
    bottom: 10px;
    max-width: calc(100vw - 20px) !important;
    min-width: 0 !important;
    width: auto !important;

    padding: 0 !important;

    height: auto;
    max-height: calc(100dvh - 40px) !important;
    overflow-x: hidden;
    overflow-y: auto !important;
    font-size: 14px;
    transition:
      top 0.3s ease,
      right 0.3s ease,
      bottom 0.3s ease,
      left 0.3s ease;
    box-sizing: border-box;
  }

  .vjw-popup.expanded {
    position: fixed;

    top: 10px;
    bottom: 10px;
    left: 10px;
    right: 10px;

    width: auto;

    overflow-y: auto;

    z-index: 100002;

    border: none;
    border-radius: 0;

    overscroll-behavior: contain;
  }

  .vjw-popup,
  .vjw-popup.expanded {
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
  }


  .directionBox,
  .wifiBox {
    margin: 10px 0 !important;
  }

  .directionBody,
  .wifiBox {
    padding: 10px !important;
  }

  .wifiContents {
    gap: 10px;
  }

  .wifiInfo {
    min-width: 0;
  }

  .wifiLabel,
  .wifiValue {
    font-size: 12px;
  }


  .wifiValue {
    margin-left: 20px;
    white-space: normal;
    overflow-wrap: anywhere;
  }


  .vjw-summary,
  .vjw-detail,
  .directionTitle,
  .stepTitle,
  .stepText,
  .wifiTitle,
  .wifiLabel,
  .wifiValue {
    font-size: 14px;
    line-height: 1.5;
  }


  .introTop {
    display: block;
  }

  .intro-right {
    display: none;
  }

  .introTextBlock {
    padding-right: 0 !important;
    line-height: 1.6;
  }

  .legendArea {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 25px;

    padding-left: 0 !important;
  }

  .legendItem {
    flex-direction: column;
    text-align: center;
    gap: 5px;
  }

  .legendItem img {
    width: 50px;
  }


  .legendItem span {
    font-size: 12px;
    line-height: 1.3;
  }


  .notes {
    width: 100%;
  }


  #mapTitle {
    margin-top: 25px;
    margin-bottom: 15px;
  }

  #portFilter {
    margin-bottom: 15px;
  }

  #myTable {
    width: auto !important;
    min-width: fit-content !important;
  }

  .scroll-hint-icon-wrap {
    display: block !important;
    left: 50% !important;
    top: 180px !important;
    transform: translateX(-50%) !important;
  }


}



/* =========================
   Tablet
========================= */
@media screen and (min-width:768px) and (max-width:1024px) {



  .tableWrap {

    -webkit-overflow-scrolling: touch;

    overflow-x: auto !important;
    overflow-y: visible !important;

    height: auto !important;
    max-height: none !important;
  }

  #pageTitle {
    font-size: 18px;
  }


  #langFilter,
  #introArea,
  #mapTitle,
  #portFilter,
  #searchBox,
  #myTable {
    width: 100%;
    min-width: 0;
  }



  #myTable th,
  #myTable td {
    font-size: 15px;
    white-space: nowrap;
  }

  #langFilter,
  #portFilter,
  #searchLabel {
    font-size: 16px;
  }

  #searchLabel {
    font-weight: bold;
  }

  .lang-tab {
    font-size: 16px;
  }

  .port-tab {
    font-size: 16px;
  }

  #searchname {
    width: 100%;
    max-width: 100%;
  }

  #clearBtn {
    margin-top: 10px;
  }

  .refund-modal-content {

    margin: auto;
    border-radius: 8px;
  }


  #mapModal {
    width: 100vw !important;
    height: 100vh !important;
    inset: 0 !important;

  }

  #mapModal .refund-modal-content {
    width: 90% !important;
    max-width: 900px !important;
    height: 90% !important;
    max-height: 90vh !important;
  }



  #contents #mapModal #modalMapImage {
    flex: 1;
    max-width: none !important;
    max-height: none !important;
    margin: 0 !important;
  }


  #mapMessage {
    max-width: 60vw;
    font-size: 12px;
  }

  .map-modal-close {
    font-size: 16px;
  }

  .vjw-popup {
    position: fixed;
    top: auto;
    left: auto;
    right: 10px;
    bottom: 10px;
    max-height: 180px;
    min-width: 0 !important;
    width: 500px !important;
    max-width: 70vw !important;

    padding: 0 !important;

    height: auto;
    max-height: calc(100dvh - 40px) !important;
    overflow-x: hidden;
    overflow-y: auto !important;
    font-size: 14px;
    transition:
      top 0.3s ease,
      right 0.3s ease,
      bottom 0.3s ease,
      left 0.3s ease;
    box-sizing: border-box;
  }

  .vjw-popup.expanded {
    position: fixed;

    left: auto;
    right: 10px;
    bottom: 10px;

    width: auto;
    height: auto;

    max-height: 70vh;
    height: fit-content;
    overflow-y: auto;

    z-index: 100002;

    border: none;
    border-radius: 0;

    overscroll-behavior: contain;
  }

  .vjw-popup,
  .vjw-popup.expanded {
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
  }


  .directionBox,
  .wifiBox {
    margin: 10px 0 !important;
  }

  .directionBody,
  .wifiBox {
    padding: 10px !important;
  }

  .wifiContents {
    gap: 10px;
  }

  .wifiInfo {
    min-width: 0;
  }

  .wifiLabel,
  .wifiValue {
    font-size: 12px;
  }


  .wifiValue {
    margin-left: 20px;
    white-space: normal;
    overflow-wrap: anywhere;
  }


  .vjw-summary,
  .vjw-detail,
  .directionTitle,
  .stepTitle,
  .stepText,
  .wifiTitle,
  .wifiLabel,
  .wifiValue {
    font-size: 14px;
    line-height: 1.5;
  }


  .introTop {
    display: block;
  }

  .intro-right {
    display: none;
  }

  .introTextBlock {
    padding-right: 0 !important;
    line-height: 1.6;
  }

  .legendArea {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 25px;

    padding-left: 0 !important;
  }

  .legendItem {
    flex-direction: column;
    text-align: center;
    gap: 5px;
  }

  .legendItem img {
    width: 50px;
  }


  .legendItem span {
    font-size: 12px;
    line-height: 1.3;
  }


  .notes {
    width: 100%;
  }


  #mapTitle {
    margin-top: 25px;
    margin-bottom: 15px;
  }

  #portFilter {
    margin-bottom: 15px;
  }

  #myTable {
    width: 100% !important;
    min-width: 0 !important;
  }



}