/* ================================================
   2964 - 국내 우선주 괴리율 분석
   3206 디자인 기준으로 업데이트
   ================================================ */

@media (min-width: 1320px) {
  .postid-2964 #stock-table-header-2964,
  .postid-2964 #stock-table-container-2964,
  .postid-2964 .list-title-container-2964 {
    width: 1650px !important;
    max-width: 1650px !important;
    margin: 0 auto !important;
    position: relative !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
  }
}
@media (max-width: 1319px) {
  .postid-2964 #stock-table-header-2964,
  .postid-2964 #stock-table-container-2964,
  .postid-2964 .list-title-container-2964 {
    width: 100% !important;
    max-width: unset !important;
  }
}

/* 제목 */
.list-title-container-2964 { text-align: center; margin-bottom: 20px; }
.list-title-container-2964 h2 { font-size: 32px; font-weight: bold; color: #333; }

/* 헤더 컨트롤 */
#stock-table-header-2964 {
  display: flex; justify-content: space-between; align-items: center;
  background: #f8f9fa; padding: 16px; border-radius: 10px; margin-bottom: 16px;
  flex-wrap: wrap; gap: 10px;
}
#stock-table-header-2964 select {
  padding: 10px 14px; border: none; border-radius: 30px;
  background: linear-gradient(135deg, #6fb1fc, #4364f7);
  color: #fff; font-weight: bold; cursor: pointer;
  box-shadow: 0 4px 10px rgba(67, 100, 247, 0.4);
}
#stock-table-header-2964 select.filter-active {
  background: linear-gradient(135deg, #ffc371, #ff5f6d);
}
#search-input-2964 {
  padding: 10px 16px; border: 1px solid #ccc; border-radius: 30px; min-width: 200px;
}
.info-text-2964 { font-size: 14px; color: #666; margin-right: 6px; }
.header-left-controls-2964 { display: flex; align-items: center; gap: 8px; }
.filter-controls-2964 { display: flex; gap: 8px; flex-wrap: wrap; }

/* 테이블 컨테이너 - 한 화면에 고정 */
#stock-table-container-2964 {
  overflow-x: auto;
  max-height: 900px;
  overflow-y: auto;
  border: 1px solid #dee2e6; border-radius: 10px;
  background-color: #fff;
  position: relative;
}

/* 테이블 */
.stock-table-2964 {
  width: 100%; min-width: 1200px; border-collapse: separate; border-spacing: 0;
}

/* 헤더 고정 */
.stock-table-2964 th {
  background: #1f4e79; color: #fff; padding: 12px;
  white-space: nowrap;
  position: sticky; top: 0; z-index: 10;
  border-bottom: 2px solid #0d2d4a;
  font-size: 13px; text-align: center;
}

/* 모든 행 흰색 */
.stock-table-2964 td {
  padding: 10px 12px; border-bottom: 1px solid #e9ecef;
  white-space: nowrap; font-size: 14px;
  background-color: #ffffff;
}
.stock-table-2964 tr:hover td { background-color: #e8f0ff; }

/* 정렬 */
.ar { text-align: right !important; }
.ac { text-align: center !important; }
.al { text-align: left !important; }

/* 시장 배지 */
.badge-market-2964 {
  display: inline-block; padding: 3px 10px;
  border-radius: 20px; font-size: 12px; font-weight: 700;
}
.badge-kospi-2964  { background: #e3f2fd; color: #1565c0; }
.badge-kosdaq-2964 { background: #fff3e0; color: #e65100; }

/* 강조 열 - 괴리율 */
.col-highlight-2964 {
  background-color: #f4f4f4 !important;
}
.stock-table-2964 tr:hover td.col-highlight-2964 {
  background-color: #dce8ff !important;
}
.stock-table-2964 th.th-col-highlight-2964 {
  background: #2d6096 !important;
}

/* 괴리율 수치 강조 */
.discount-high  { color: #c0392b; font-weight: 700; }  /* 40% 이상 */
.discount-mid   { color: #e67e22; font-weight: 700; }  /* 20~40% */
.discount-low   { color: #27ae60; font-weight: 600; }  /* 20% 미만 */

/* 배당률 */
.div-highlight  { color: #1565c0; font-weight: 700; }

/* 종목명 */
.stock-name-common   { color: #333; font-weight: 600; }
.stock-name-pref     { color: #555; font-weight: 500; }

/* 공시 링크 */
.dart-link a {
  color: #1155cc; text-decoration: none; font-size: 13px;
}
.dart-link a:hover { text-decoration: underline; }

/* 모바일 */
@media (max-width: 768px) {
  #stock-table-header-2964 { flex-direction: column; align-items: stretch; }
  .filter-controls-2964 { justify-content: space-between; }
  #stock-table-header-2964 select { flex-grow: 1; }
}
