@import url("golf.css");

.blind {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.market-page-main {
  padding: 1.5rem 0 0;
  background: #fff;
}

.market-page-main .bg_white {
  padding: 0rem 0 11.25rem;
  background-color: #ffffff;
}

.insights-head {
  margin-top: 2.5rem;
}

.insights-title {
  font-size: 3.75rem;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.04em;
  color: #2d3748;
}

.insights-lead {
  margin-top: 1.375rem;
  font-size: 1.125rem;
  line-height: 1.5;
  letter-spacing: -0.02em;
  color: #222;
  word-break: keep-all;
  font-weight: 300;
}

.market-tabs {
  margin: 0 0 5rem;
}

.market-tabs__list {
  display: flex;
  justify-content: center;
  margin: 0 auto;
  padding: 0;
  list-style: none;
  max-width: 46.875rem;
  border-bottom: 1px solid #e5e7eb;
}

.market-tabs__link {
  display: block;
  padding: 0.8125rem 2.5rem;
  font-size: 1.25rem;
  font-weight: 400;
  letter-spacing: -0.03em;
  color: rgba(26, 26, 26, 0.7);
  text-decoration: none;
  white-space: nowrap;
  transition: var(--transition);
}

.market-tabs__link:hover {
  color: #555;
}

.market-tabs__link.active {
  position: relative;
  font-weight: 700;
  color: #1a1d21;
}

.market-tabs__link.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 3px;
  background-color: #d45124;
}

/* Category-specific indicator bar colors */
.market-tabs__link--golf.active::after,
body.page-golf .market-tabs__link.active::after {
  background-color: #578f3b;
}

.market-tabs__link--resort.active::after,
body.page-resort .market-tabs__link.active::after {
  background-color: #d45124;
}

.market-tabs__link--fitness.active::after,
body.page-fitness .market-tabs__link.active::after {
  background-color: #3f4e82;
}

.market-tabs__link--golf:hover {
  color: #578f3b;
}

.market-tabs__link--resort:hover {
  color: #d45124;
}

.market-tabs__link--fitness:hover {
  color: #3f4e82;
}

.insight-board {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3.125rem;
}

.insight-board__text p {
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: #666;
  word-break: keep-all;
}

.insight-board__text p + p {
  margin-top: 1.5rem;
}

.chart-canvas-box {
  position: relative;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.1);
  overflow: visible;
}

.chart-canvas-header {
  position: relative;
  width: 100%;
  border: 1px solid #1a1d21;
  background: #ffffff;
  z-index: 40;
}

.custom-select-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.875rem 1.25rem;
  background: #ffffff;
  border: none;
  cursor: pointer;
  user-select: none;
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: #1a1d21;
  text-align: left;
  transition: background-color 0.15s ease;
}

.custom-select-trigger:hover {
  background-color: #fafafa;
}

.custom-select-label {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chart-select-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  margin-left: 0.75rem;
  flex-shrink: 0;
  pointer-events: none;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.chart-canvas-header.is-open .chart-select-chevron {
  transform: rotate(180deg);
}

.custom-select-menu {
  position: absolute;
  top: calc(100% + 2px);
  left: -1px;
  right: -1px;
  background: #ffffff;
  border: 1px solid #1a1d21;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12), 0 4px 10px rgba(0, 0, 0, 0.05);
  padding: 0.375rem 0;
  list-style: none;
  margin: 0;
  max-height: 280px;
  overflow-y: auto;
  z-index: 50;
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
}

.chart-canvas-header.is-open .custom-select-menu {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  visibility: visible;
}

.custom-select-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8125rem 1.25rem;
  font-size: 1.0625rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: #374151;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.custom-select-option:hover {
  background-color: #f3f4f6;
  color: #1a1d21;
}

.custom-select-option.is-selected {
  background-color: #f8fafc;
  color: #111827;
  font-weight: 700;
}

/* Category-tinted active colors */
.page-golf .custom-select-option.is-selected {
  background-color: #f2f8ee;
  color: #578f3b;
}
.page-golf .custom-select-option.is-selected .check-icon {
  color: #578f3b;
}

.page-resort .custom-select-option.is-selected {
  background-color: #fdf4f0;
  color: #d45124;
}
.page-resort .custom-select-option.is-selected .check-icon {
  color: #d45124;
}

.page-fitness .custom-select-option.is-selected {
  background-color: #f0f3fa;
  color: #3f4e82;
}
.page-fitness .custom-select-option.is-selected .check-icon {
  color: #3f4e82;
}

.custom-select-option .check-icon {
  width: 1.125rem;
  height: 1.125rem;
  opacity: 0;
  transform: scale(0.85);
  transition: opacity 0.15s ease, transform 0.15s ease;
  flex-shrink: 0;
  margin-left: 0.5rem;
}

.custom-select-option.is-selected .check-icon {
  opacity: 1;
  transform: scale(1);
}

.blind {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.chart-canvas-body {
  position: relative;
  padding: 1.125rem 1.125rem 0 0;
}

.chart-menu-wrapper {
  position: absolute;
  top: 0.75rem;
  right: 1.125rem;
  z-index: 30;
}

.chart-menu-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 4px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.chart-menu-btn:hover,
.chart-menu-wrapper.is-open .chart-menu-btn {
  background-color: #f3f4f6;
  border-color: #e5e7eb;
}

.chart-menu-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  min-width: 190px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1), 0 4px 8px rgba(0, 0, 0, 0.04);
  padding: 0.375rem 0;
  z-index: 45;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s;
}

.chart-menu-wrapper.is-open .chart-menu-dropdown {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  visibility: visible;
}

.chart-menu-item {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 0.625rem 1rem;
  border: none;
  background: transparent;
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.12s ease, color 0.12s ease;
}

.chart-menu-item:hover {
  background-color: #f9fafb;
  color: #111827;
}

.chart-menu-item svg {
  margin-right: 0.5rem;
  flex-shrink: 0;
}

.chart-y-axis-label {
  position: absolute;
  left: 0.75rem;
  top: 46%;
  transform: translateY(-50%);
  writing-mode: vertical-rl;
  font-size: 0.75rem;
  letter-spacing: -0.03em;
  color: #8a8f98;
}

.chart-svg-main {
  width: 100%;
  height: auto;
  display: block;
}

.chart-svg-main circle {
  cursor: pointer;
  transition: r 0.2s ease, stroke-width 0.2s ease;
}

.chart-x-axis-label {
  padding-bottom: 1rem;
  font-size: 0.75rem;
  color: #8a8f98;
  text-align: center;
}

.center-search-section {
  display: flex;
  justify-content: center;
  margin-bottom: 2.1875rem;
}

.search-pill-container {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 45rem;
  height: 3.75rem;
  padding: 0 1.5rem;
  border: 1px solid #dcdfe3;
  border-radius: 999px;
  background: #ffffff;
}

.search-pill-select {
  position: relative;
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  padding-right: 2.25rem;
  margin-right: 1.25rem;
  border-right: 1px solid #e5e7eb;
}

.search-type-select {
  border: none;
  outline: none;
  background: transparent;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
  color: #1e2124;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  padding-right: 1.25rem;
}

.search-select-chevron {
  position: absolute;
  right: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  display: inline-flex;
  pointer-events: none;
}

.search-keyword-input {
  flex: 1 1 auto;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  font-size: 0.9375rem;
  letter-spacing: -0.03em;
  color: #222;
}

.search-keyword-input::placeholder {
  color: #b0b4ba;
}

.btn-search-trigger {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border: none;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
}

.matrix-table-wrap {
  width: 100%;
  overflow-x: auto;
  background: #ffffff;
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid #DCDEEA;
}

.price-matrix-table {
  width: 100%;
  min-width: 56.25rem;
  border-collapse: separate;
  border-spacing: 0;
}

.price-matrix-table th {
  position: relative;
  height: 3.75rem;
  padding: 0 1.25rem;
  font-size: 0.9375rem;
  font-weight: 300;
  letter-spacing: -0.03em;
  color: #fff;
  background-color: #222;
}

.price-matrix-table th.spe {
  text-align: left;
}

/* .price-matrix-table th + th::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 0.875rem;
  background-color: #DCDEEA;
} */

.price-matrix-table td {
  height: 3.75rem;
  padding: 0 1.25rem;
  border-bottom: 1px solid #DCDEEA;
  font-size: 0.9375rem;
  letter-spacing: -0.02em;
  color: #222;
  font-weight: 400;
  text-align: center;
}

.price-matrix-table tr:last-child td {
  border-bottom: none;
}

.price-matrix-table td.td-name {
  font-size: 1.125rem;
  color: #000;
  text-align: left;
}

.price-matrix-table td.td-region {
  text-align: left;
}

/* .price-matrix-table td.td-price--deal {
  font-weight: 500;
} */

.price-matrix-table .clickable-row {
  cursor: pointer;
  transition: var(--transition);
}

.price-matrix-table .clickable-row:hover td {
  background-color: #fafbfc;
}

.td-no {
  color: #8a8f98;
}

.td-name {
  padding-left: 2.5rem;
  font-size: 0.875rem;
  color: #1a1d21;
  text-align: left;
}

.td-name a {
  color: inherit;
  text-decoration: none;
}

.td-name a:hover {
  text-decoration: underline;
  text-underline-offset: 0.25rem;
}

.td-region {
  font-size: 0.75rem;
  color: #8a8f98;
}

.td-price {
  color: #b0b4ba;
}

/* .td-price--deal {
  font-weight: 500;
  color: #1a1d21;
} */

.trend {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.9375rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.trend__icon {
  display: inline-block;
  width: 0;
  height: 0;
  border-left: 0.25rem solid transparent;
  border-right: 0.25rem solid transparent;
}

.trend--up {
  color: #e5484d;
}

.trend--up .trend__icon {
  border-bottom: 0.375rem solid currentColor;
}

.trend--down {
  color: #2f80ed;
}

.trend--down .trend__icon {
  border-top: 0.375rem solid currentColor;
}

.trend--flat {
  color: #9aa0a6;
}

.trend--flat .trend__icon {
  width: 0.4375rem;
  height: 0.4375rem;
  border: 0;
  border-radius: 50%;
  background-color: currentColor;
}

.market-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 3.75rem;
}

.market-pager__list {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.market-pager__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.5rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  color: #6b7078;
  text-decoration: none;
  transition: var(--transition);
}

.market-pager__num:hover {
  background-color: #f2f3f5;
  color: #1a1d21;
}

.market-pager__num.active {
  background-color: #C9A14A;
  font-weight: 700;
  color: #ffffff;
}

.market-pager__nav {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0 0.5rem;
  font-size: 0.875rem;
  color: #6b7078;
  text-decoration: none;
  transition: var(--transition);
}

.market-pager__nav:hover {
  color: #1a1d21;
}

.market-pager__nav.is-disabled {
  color: #c4c8cd;
  pointer-events: none;
}

.market-info {
  padding: 3.0625rem 3.5rem 4.0625rem 2.25rem;
  border-radius: 2rem;
  background: #FFF;
  box-shadow: 0 0 25px 0 rgba(0, 0, 0, 0.10);
  margin: 5rem 0 6.25rem;
}

.market-tabs__heading {
  display: none;
}

@media (min-width: 851px) {
  .page-market .sub-tab-bar__inner {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    width: 100%;
    max-width: 1900px;
  }

  .insights-head {
    margin-top: 6.25rem;
  }

  .insights-title {
    font-size: 3rem;
  }

  .market-tabs {
    margin: 0 0 5rem;
  }

  .insight-board {
    grid-template-columns: 1fr 1fr;
    gap: 3.125rem;
  }

  .insight-board__chart {
    padding-top: 0;
  }

  .chart-canvas-box {
    width: 47.125rem;
    position: relative;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    overflow: visible;
  }
}

@media (max-width: 850px) {
  .market-page-main {
    padding: 1.231rem 0 0;
  }

  .market-page-main .bg_white {
    padding: 3.077rem 0 4.615rem;
  }

  .insights-head {
    margin-top: 1.538rem;
  }

  .insights-title {
    font-size: 3.077rem;
  }

  .insights-lead {
    margin-top: 1.077rem;
    font-size: 0.923rem;
    line-height: 1.8;
  }

  .market-tabs {
    margin: 0 0 1.538rem;
    margin-right: 0;
    padding-right: 0;
    overflow-x: visible;
  }

  .market-tabs__heading {
    display: block;
    margin: 0 0 0.923rem;
    font-size: 1.231rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: #1a1d21;
    text-align: center;
  }

  .market-tabs__list {
    justify-content: center;
    min-width: 0;
    width: 100%;
    max-width: none;
  }

  .market-tabs__item {
    position: relative;
    flex: 1 1 0;
    min-width: 0;
  }

  .market-tabs__item + .market-tabs__item::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 0.923rem;
    background-color: #dcdee5;
  }

  .market-tabs__link {
    padding: 0.692rem 0.308rem;
    font-size: 1.077rem;
    text-align: center;
  }

  .insight-board {
    gap: 1.923rem;
  }

  .insight-board__text p {
    font-size: 1rem;
    line-height: 1.8;
  }

  .insight-board__text p + p {
    margin-top: 1.077rem;
  }

  .insight-board__text br {
    display: none;
  }

  .custom-select-trigger {
    padding: 0.769rem 0.923rem;
    font-size: 1.077rem;
  }

  .custom-select-option {
    padding: 0.692rem 0.923rem;
    font-size: 0.923rem;
  }

  .chart-y-axis-label {
    font-size: 0.646rem;
    left: 0.5rem;
  }

  .center-search-section {
    margin-bottom: 1.538rem;
  }

  .search-pill-container {
    height: 3.385rem;
    padding: 0 1.077rem;
  }

  .search-pill-select {
    padding-right: 0.769rem;
    margin-right: 0.769rem;
  }

  .search-type-select,
  .search-keyword-input {
    font-size: 1rem;
    padding-right: 2.25rem;
  }

  .search-select-chevron {
    right: 0.769rem;
  }

  .btn-search-trigger {
    width: 2.308rem;
    height: 2.308rem;
  }

  .btn-search-trigger svg {
    width: 1.385rem;
    height: 1.385rem;
  }

  .matrix-table-wrap {
    margin-right: 0;
    padding-right: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 0.769rem;
  }

  .price-matrix-table {
    min-width: 44.615rem;
  }

  .price-matrix-table colgroup col:nth-child(1) { width: 8%; }
  .price-matrix-table colgroup col:nth-child(2) { width: 26%; }
  .price-matrix-table colgroup col:nth-child(3) { width: 12%; }
  .price-matrix-table colgroup col:nth-child(4) { width: 13%; }
  .price-matrix-table colgroup col:nth-child(5) { width: 13%; }
  .price-matrix-table colgroup col:nth-child(6) { width: 13%; }
  .price-matrix-table colgroup col:nth-child(7) { width: 15%; }

  .price-matrix-table th {
    height: 2.769rem;
    font-size: 0.846rem;
    padding: 0 0.385rem;
    white-space: nowrap;
  }

  .price-matrix-table td {
    height: 3.385rem;
    font-size: 0.846rem;
    padding: 0 0.385rem;
    white-space: nowrap;
  }

  .price-matrix-table td.td-name {
    font-size: 0.923rem;
  }

  .td-name {
    padding-left: 0.769rem;
    font-size: 0.923rem;
  }

  .td-region,
  .trend {
    font-size: 0.846rem;
  }

  .trend {
    gap: 0.154rem;
  }

  .trend__icon {
    display: none;
  }

  .price-matrix-table th {
    height: 3.077rem;
    font-size: 0.923rem;
    padding: 0 0.5rem;
  }

  .price-matrix-table td {
    height: 3.692rem;
    font-size: 0.923rem;
    padding: 0 0.5rem;
  }

  .td-name {
    padding-left: 1.231rem;
    font-size: 1rem;
  }

  .td-region,
  .trend {
    font-size: 0.923rem;
  }

  .market-pager {
    gap: 0.462rem;
    margin-top: 2.308rem;
  }

  .market-pager__num {
    min-width: 1.923rem;
    height: 1.923rem;
    font-size: 1rem;
  }

  .market-pager__nav {
    font-size: 1rem;
  }

  .market-info {
    padding: 2rem;
    border-radius: 2rem;
    background: #FFF;
    box-shadow: 0 0 25px 0 rgba(0, 0, 0, 0.10);
    margin: 3rem 0;
  }
}
