/* ==========================================================================
   PROJECT-10 — PHASE-5B : 실거래 조회 페이지 (realtx.html) 전용 스타일
   Design Freeze v1.0(assets/css/style.css)의 색상/폰트/Radius/Shadow 변수를
   그대로 상속합니다. 이 파일은 새 클래스(rx- 접두사)만 정의하며
   style.css의 기존 선택자는 전혀 건드리지 않습니다.
   ========================================================================== */

.rx-main{ max-width:1180px; margin:0 auto; padding:0 32px 40px; }

.rx-breadcrumb{ font-size:12.5px; color:var(--text-muted); padding:16px 0 8px; }
.rx-breadcrumb a{ color:var(--text-muted); text-decoration:none; }
.rx-breadcrumb a:hover{ color:var(--navy2); }
.rx-breadcrumb .sep{ margin:0 6px; }
.rx-breadcrumb .current{ color:var(--text-headline); font-weight:600; }

.rx-page-head{ display:flex; align-items:flex-start; justify-content:space-between; gap:20px; padding:8px 0 20px; flex-wrap:wrap; }
.rx-page-title{ font-size:24px; font-weight:800; color:var(--text-headline); margin:0 0 6px; }
.rx-page-sub{ font-size:13px; color:var(--text-body); margin:0; }
.rx-data-meta{ text-align:right; font-size:12px; color:var(--text-muted); }
.rx-data-meta strong{ color:var(--text-headline); }
.rx-source-btn{
  margin-top:8px; display:inline-block; border:1px solid var(--border); background:#fff;
  color:var(--text-headline); font-size:12px; font-weight:600; padding:7px 14px; border-radius:999px; text-decoration:none;
}
.rx-source-btn:hover{ background:var(--bg-alt); }

/* ---------------------------------------------------------------------
   레이아웃 : 좌측 필터 + 우측 콘텐츠
   --------------------------------------------------------------------- */
.rx-layout{ display:grid; grid-template-columns:260px 1fr; gap:24px; align-items:start; min-width:0; }
.rx-layout > *{ min-width:0; }

/* 필터 사이드바 */
.rx-filter-card{
  background:#fff; border:1px solid var(--border); border-radius:var(--radius-lg);
  padding:20px; display:flex; flex-direction:column; gap:16px;
}
.rx-filter-group label{ display:block; font-size:12px; font-weight:600; color:var(--text-headline); margin-bottom:6px; }
.rx-filter-group select,
.rx-filter-group input[type="date"],
.rx-filter-group input[type="number"]{
  width:100%; border:1px solid var(--border); border-radius:8px; padding:9px 10px;
  font-size:12.5px; font-family:inherit; color:var(--text-headline); background:#fff;
}
.rx-area-range{ display:flex; align-items:center; gap:6px; }
.rx-area-range input{ min-width:0; }
.rx-area-slider{ width:100%; margin:6px 0 2px; accent-color:var(--green); }

.rx-period-btns{ display:flex; gap:6px; flex-wrap:wrap; }
.rx-period-btns button{
  flex:1; min-width:0; border:1px solid var(--border); background:#fff; color:var(--text-body);
  font-size:11.5px; font-weight:600; padding:7px 4px; border-radius:8px; cursor:pointer;
}
.rx-period-btns button.is-active{ background:var(--navy2); color:#fff; border-color:var(--navy2); }
.rx-date-range{ display:flex; align-items:center; gap:6px; }

.rx-btn-search{
  border:none; background:var(--green); color:#fff; font-size:13.5px; font-weight:700;
  padding:11px; border-radius:999px; cursor:pointer; width:100%;
}
.rx-btn-search:hover{ background:#365f52; }
.rx-btn-reset{
  border:1px solid var(--border); background:#fff; color:var(--text-headline); font-size:13px; font-weight:600;
  padding:10px; border-radius:999px; cursor:pointer; width:100%;
}
.rx-btn-reset:hover{ background:var(--bg-alt); }

.rx-alert-card{
  background:var(--bg-cream); border-radius:var(--radius-lg); padding:16px;
}
.rx-alert-head{ display:flex; align-items:center; gap:8px; font-size:12.5px; font-weight:700; color:var(--text-headline); margin-bottom:6px; }
.rx-alert-desc{ font-size:11.5px; color:var(--text-body); line-height:1.5; margin:0 0 10px; }
.rx-alert-btn{
  display:block; text-align:center; border:none; background:var(--navy2); color:#fff;
  font-size:12px; font-weight:600; padding:9px; border-radius:999px; text-decoration:none;
}
.rx-alert-btn:hover{ background:#081430; }

/* ---------------------------------------------------------------------
   우측 콘텐츠
   --------------------------------------------------------------------- */
.rx-complex-card{
  background:#fff; border:1px solid var(--border); border-radius:var(--radius-lg);
  padding:16px 20px; display:flex; align-items:center; gap:16px; margin-bottom:20px;
}
.rx-complex-photo{ width:72px; height:56px; border-radius:10px; overflow:hidden; flex-shrink:0; background:var(--bg-alt); }
.rx-complex-photo img{ width:100%; height:100%; object-fit:cover; display:block; }
.rx-complex-info{ flex:1; min-width:0; }
.rx-complex-name{ font-size:16px; font-weight:800; color:var(--text-headline); margin:0 0 3px; }
.rx-complex-address{ font-size:12px; color:var(--text-body); margin:0 0 4px; }
.rx-complex-meta{ font-size:11.5px; color:var(--text-muted); }
.rx-complex-meta span + span{ margin-left:10px; }
.rx-complex-actions{ display:flex; flex-direction:column; gap:8px; }
.rx-complex-btn{
  border:1px solid var(--border); background:#fff; color:var(--text-headline);
  font-size:12px; font-weight:600; padding:8px 14px; border-radius:999px; text-decoration:none; white-space:nowrap; text-align:center;
}
.rx-complex-btn:hover{ background:var(--bg-alt); }

.rx-section-title{ font-size:15px; font-weight:700; color:var(--text-headline); margin:0 0 12px; }

/* 요약 카드 5개 */
.rx-summary-row{ display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:14px; margin-bottom:24px; }
.rx-summary-card{
  background:#fff; border:1px solid var(--border); border-radius:var(--radius-lg); padding:16px; min-width:0;
}
.rx-summary-label{ font-size:11.5px; color:var(--text-body); margin-bottom:6px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.rx-summary-value{ font-size:18px; font-weight:800; color:var(--text-headline); margin-bottom:4px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.rx-summary-delta{ font-size:11px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.rx-summary-delta.up{ color:var(--green); }
.rx-summary-delta.down{ color:#C0392B; }
.rx-summary-delta.neutral{ color:var(--text-muted); }

/* 차트 2열 */
.rx-chart-row{ display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:20px; margin-bottom:24px; }
.rx-chart-card{
  background:#fff; border:1px solid var(--border); border-radius:var(--radius-lg); padding:20px;
}
.rx-chart-head{ display:flex; align-items:center; justify-content:space-between; margin-bottom:12px; }
.rx-chart-legend{ display:flex; gap:12px; font-size:11.5px; color:var(--text-body); }
.rx-legend-dot{ display:inline-block; width:8px; height:8px; border-radius:50%; margin-right:4px; }
.rx-chart-select{
  border:1px solid var(--border); border-radius:8px; padding:5px 8px; font-size:11.5px; color:var(--text-body); background:#fff;
}
.rx-chart-canvas-wrap{ height:210px; }
.rx-chart-canvas-wrap canvas{ max-width:100%; }

/* 거래 내역 테이블 */
.rx-table-card{
  background:#fff; border:1px solid var(--border); border-radius:var(--radius-lg); padding:20px; margin-bottom:20px;
}
.rx-table-head{ display:flex; align-items:center; justify-content:space-between; margin-bottom:14px; flex-wrap:wrap; gap:10px; }
.rx-table-tabs{ display:flex; gap:6px; }
.rx-table-tabs button{
  border:1px solid var(--border); background:#fff; color:var(--text-body);
  font-size:12.5px; font-weight:600; padding:8px 14px; border-radius:999px; cursor:pointer;
}
.rx-table-tabs button.is-active{ background:var(--navy2); color:#fff; border-color:var(--navy2); }
.rx-download-btn{
  border:1px solid var(--border); background:#fff; color:var(--text-headline);
  font-size:12px; font-weight:600; padding:8px 14px; border-radius:999px; cursor:pointer; display:inline-flex; align-items:center; gap:6px;
}
.rx-download-btn:hover{ background:var(--bg-alt); }

.rx-table-wrap{ overflow-x:auto; }
.rx-table{ width:100%; border-collapse:collapse; font-size:12px; white-space:nowrap; }
.rx-table th{ text-align:left; color:var(--text-muted); font-weight:600; padding:9px 8px; border-bottom:1px solid var(--border); }
.rx-table td{ padding:10px 8px; border-bottom:1px solid var(--border); color:var(--text-body); }
.rx-table td.rx-deal-type{ color:var(--green); font-weight:700; }
.rx-table tbody tr:hover{ background:var(--bg-alt); }

.rx-table-footer{ display:flex; align-items:center; justify-content:space-between; margin-top:14px; flex-wrap:wrap; gap:10px; }
.rx-total-count{ font-size:12.5px; color:var(--text-body); }
.rx-pagination{ display:flex; align-items:center; gap:4px; }
.rx-pagination button{
  border:1px solid var(--border); background:#fff; color:var(--text-body);
  width:28px; height:28px; border-radius:6px; font-size:12px; cursor:pointer;
}
.rx-pagination button.is-active{ background:var(--navy2); color:#fff; border-color:var(--navy2); }
.rx-pagination button:disabled{ opacity:0.4; cursor:default; }
.rx-page-size{ border:1px solid var(--border); border-radius:8px; padding:6px 10px; font-size:12px; color:var(--text-body); background:#fff; }

/* 하단 정보 4열 */
.rx-info-row{ display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:16px; }
.rx-info-card{ background:var(--bg-alt); border-radius:var(--radius-md); padding:16px; display:flex; gap:10px; align-items:flex-start; }
.rx-info-icon{ width:30px; height:30px; border-radius:8px; background:#fff; color:var(--text-muted); display:flex; align-items:center; justify-content:center; flex-shrink:0; }
.rx-info-title{ font-size:12px; font-weight:700; color:var(--text-headline); margin:0 0 3px; }
.rx-info-desc{ font-size:11px; color:var(--text-muted); line-height:1.4; margin:0; }

/* ---------------------------------------------------------------------
   RESPONSIVE
   --------------------------------------------------------------------- */
@media (max-width: 1080px){
  .rx-layout{ grid-template-columns:1fr; }
  .rx-summary-row{ grid-template-columns:repeat(3,1fr); }
  .rx-chart-row{ grid-template-columns:1fr; }
  .rx-info-row{ grid-template-columns:1fr 1fr; }
}
@media (max-width: 620px){
  .rx-summary-row{ grid-template-columns:1fr 1fr; }
  .rx-info-row{ grid-template-columns:1fr; }
  .rx-complex-card{ flex-wrap:wrap; }
}
