
*{box-sizing:border-box}html{background:#f4f6f9}body{margin:0;font-family:"Pretendard","Noto Sans KR","Malgun Gothic",Arial,sans-serif;color:#17263b;background:#f4f6f9;line-height:1.5;padding-bottom:82px}.topbar{position:sticky;top:0;z-index:30;background:rgba(255,255,255,.98);border-bottom:1px solid #e2e7ed}.top-inner{max-width:760px;margin:auto;height:58px;padding:0 16px;display:flex;align-items:center;justify-content:space-between}.brand img{width:128px}.page-title{font-weight:900;font-size:12px;color:#34455d}main{max-width:760px;margin:auto;padding:0 14px 28px}.intro{padding:21px 4px 16px}.eyebrow{margin:0 0 8px;color:#b87509;font-size:11px;font-weight:900;letter-spacing:.12em}.intro h1{font-size:28px;line-height:1.15;letter-spacing:-.04em;margin:0 0 10px}.intro>p:last-child{margin:0;color:#677487;font-size:14px}.search-sticky{position:sticky;top:58px;z-index:20;background:#f4f6f9;padding:8px 0 10px}.search-wrap{display:grid;grid-template-columns:1fr 66px;background:#fff;border:2px solid #123b61;border-radius:16px;overflow:hidden;box-shadow:0 7px 24px rgba(20,50,80,.08)}.search-wrap input{min-width:0;border:0;outline:0;padding:15px 13px;font-size:16px}.search-wrap button{border:0;background:#123b61;color:#fff;font-weight:900;font-size:14px}.suggestions{position:absolute;left:0;right:0;top:66px;background:#fff;border:1px solid #dfe5ec;border-radius:14px;box-shadow:0 12px 28px rgba(20,40,70,.15);max-height:270px;overflow:auto}.suggestion{display:block;width:100%;text-align:left;border:0;background:#fff;padding:13px 15px;border-bottom:1px solid #eef1f5}.suggestion strong{display:block;font-size:15px}.suggestion small{color:#788598}.controls{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:7px 2px 12px}.switch-row{display:flex;align-items:center;gap:7px;font-size:13px;font-weight:900}.switch-row input{width:20px;height:20px}.controls select{border:1px solid #d9e0e8;background:#fff;border-radius:10px;padding:9px 10px}.demo-banner{background:#fff4d8;border:1px solid #f0d18b;color:#76510b;border-radius:14px;padding:11px 13px;font-size:11px;margin-bottom:12px}.empty-card{text-align:center;background:#fff;border:1px solid #e4e9ef;border-radius:20px;padding:44px 20px;color:#6c788b}.search-icon{font-size:44px;color:#b8c0ca}.empty-card strong{display:block;color:#2e4057;font-size:18px}.example{border:0;background:#edf3fa;color:#123b61;border-radius:999px;padding:6px 10px;font-weight:900}.selected-card{background:#102b49;color:#fff;border-radius:22px;padding:20px;box-shadow:0 14px 34px rgba(13,43,73,.18)}.selected-head{display:flex;justify-content:space-between;gap:14px}.label{font-size:11px;color:#e7b34e;font-weight:900}.selected-card h2{font-size:24px;margin:7px 0 3px}.selected-head p{margin:0;color:#b9c6d5}.status{height:max-content;border-radius:999px;padding:6px 9px;font-size:10px;font-weight:900}.pending{background:#fff0cf;color:#9b6200}.selected-meta{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:19px}.selected-meta div:first-child{grid-column:1/-1}.selected-meta div{background:rgba(255,255,255,.08);border-radius:12px;padding:10px}.selected-meta span,.selected-meta strong{display:block}.selected-meta span{font-size:10px;color:#aebdce}.selected-meta strong{font-size:12px;margin-top:3px}.result-head{display:flex;align-items:end;justify-content:space-between;gap:10px;margin:25px 2px 12px}.result-head h3{font-size:21px;margin:0}.result-head p{font-size:12px;color:#7b8796;margin:3px 0 0}.criteria{font-size:10px;font-weight:900;color:#a46706;background:#fff3dd;padding:6px 8px;border-radius:999px;white-space:nowrap}.cards{display:grid;gap:11px}.drug-card{background:#fff;border:1px solid #e1e6ed;border-radius:18px;padding:15px}.drug-top{display:flex;justify-content:space-between;gap:12px}.drug-name{font-size:17px;font-weight:900}.company{font-size:13px;color:#6f7d90;margin-top:3px}.price{text-align:right;white-space:nowrap}.price strong{display:block;font-size:16px;color:#123b61}.price small{color:#8893a1}.drug-meta{display:flex;flex-wrap:wrap;gap:6px;margin-top:13px}.chip{background:#f3f6f9;color:#43546b;border-radius:999px;padding:5px 8px;font-size:10px;font-weight:800}.notice{margin-top:22px;background:#fff;border:1px solid #e0e6ed;border-radius:16px;padding:16px;color:#667487;font-size:12px}.bottom-nav{position:fixed;display:grid;grid-template-columns:1fr 1fr;bottom:0;left:0;right:0;background:rgba(255,255,255,.98);border-top:1px solid #dfe5eb;z-index:40;padding-bottom:env(safe-area-inset-bottom)}.bottom-nav a{text-decoration:none;color:#718095;text-align:center;padding:9px 4px 8px;font-size:11px;font-weight:800}.bottom-nav span{display:block;font-size:20px;line-height:1.15}.bottom-nav .active{color:#123b61}

/* V5.1 - 제약회사명 우선 표시 */
.selected-company{
  margin-top:7px;
  font-size:20px;
  font-weight:900;
  color:#ffffff;
  letter-spacing:-.02em;
}
.selected-card h2{
  margin-top:4px;
  font-size:18px;
  color:#c8d4e2;
  font-weight:800;
}
.company-primary{
  font-size:18px;
  font-weight:900;
  color:#123b61;
  line-height:1.25;
  margin:0 0 5px;
}
.drug-name{
  font-size:16px;
  font-weight:800;
  color:#28394f;
  line-height:1.35;
}
@media(max-width:640px){
  .selected-company{font-size:21px}
  .company-primary{font-size:19px}
  .drug-name{font-size:15px}
}

/* V5.2 - 모바일 검색 결과 압축형 */
.intro{
  padding:14px 4px 10px;
}
.intro h1{
  font-size:24px;
  margin-bottom:6px;
}
.intro>p:last-child{
  font-size:12px;
}
.controls{
  padding:5px 2px 8px;
}
.demo-banner{
  padding:8px 10px;
  margin-bottom:9px;
  font-size:10px;
}
.selected-card{
  padding:15px 16px;
  border-radius:16px;
}
.selected-company{
  font-size:18px;
}
.selected-card h2{
  font-size:15px;
  margin-top:2px;
}
.selected-meta{
  margin-top:12px;
  gap:6px;
}
.selected-meta div{
  padding:7px 8px;
  border-radius:9px;
}
.selected-meta span{
  font-size:9px;
}
.selected-meta strong{
  font-size:11px;
}
.result-head{
  margin:17px 2px 8px;
}
.result-head h3{
  font-size:18px;
}
.cards{
  gap:7px;
}
.drug-card{
  padding:11px 12px;
  border-radius:14px;
}
.company-primary{
  font-size:17px;
  margin-bottom:2px;
}
.drug-name{
  font-size:14px;
  line-height:1.3;
}
.price strong{
  font-size:15px;
}
.price small{
  font-size:9px;
}
.drug-meta{
  margin-top:8px;
  gap:4px;
}
.chip{
  padding:3px 6px;
  font-size:9px;
}
.notice{
  margin-top:15px;
  padding:12px;
  font-size:11px;
}
@media(max-width:640px){
  .search-sticky{padding-top:5px;padding-bottom:7px}
  .search-wrap input{padding:12px 12px}
  .search-wrap button{font-size:13px}
  .company-primary{font-size:18px}
  .drug-card{padding:10px 11px}
}

/* V5.3 - 타사제품 한 줄형 + 청구코드 */
.selected-name-line{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:7px;
  margin-top:2px;
}
.selected-name-line h2{
  margin:0;
}
.selected-code{
  display:inline-block;
  font-size:10px;
  font-weight:800;
  color:#d3dfeb;
  background:rgba(255,255,255,.10);
  border-radius:999px;
  padding:3px 7px;
}

.cards{
  display:grid;
  gap:5px;
}
.drug-card{
  display:none;
}
.drug-row{
  min-width:0;
  display:grid;
  grid-template-columns:minmax(78px,27%) minmax(0,1fr) 54px;
  align-items:center;
  gap:8px;
  background:#fff;
  border:1px solid #e1e6ed;
  border-radius:11px;
  padding:8px 10px;
  min-height:42px;
}
.row-company{
  min-width:0;
  font-size:14px;
  font-weight:900;
  color:#123b61;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.row-product{
  min-width:0;
  display:flex;
  align-items:center;
  gap:5px;
  white-space:nowrap;
  overflow:hidden;
}
.row-name{
  min-width:0;
  font-size:13px;
  font-weight:800;
  color:#28394f;
  overflow:hidden;
  text-overflow:ellipsis;
}
.row-code{
  flex:0 0 auto;
  font-size:9px;
  font-weight:800;
  color:#7a8797;
  background:#f2f5f8;
  border-radius:6px;
  padding:2px 4px;
}
.row-price{
  text-align:right;
  font-size:12px;
  font-weight:900;
  color:#123b61;
  white-space:nowrap;
}
@media(max-width:430px){
  .drug-row{
    grid-template-columns:minmax(72px,29%) minmax(0,1fr) 48px;
    gap:6px;
    padding:7px 8px;
    min-height:39px;
  }
  .row-company{font-size:13px}
  .row-name{font-size:12px}
  .row-code{font-size:8px;padding:2px 3px}
  .row-price{font-size:11px}
}

/* V5.4 - 생산/공급 상태 표시 */
.filter-group{
  display:flex;
  align-items:center;
  gap:12px;
  flex-wrap:wrap;
}
.selected-statuses{
  display:flex;
  flex-direction:column;
  gap:5px;
  align-items:flex-end;
}
.status.active{
  background:#dff3e5;
  color:#16723b;
}
.status.warning{
  background:#fff0cf;
  color:#9b6200;
}
.status.stopped{
  background:#ffe0e0;
  color:#a32020;
}
.status.pending{
  background:#edf1f5;
  color:#667487;
}

/* 기존 3칸 → 4칸: 회사 | 제품+청구코드 | 상태 | 약가 */
.drug-row{
  grid-template-columns:minmax(78px,23%) minmax(0,1fr) 86px 52px;
}
.row-status{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:2px;
}
.mini-status{
  display:block;
  text-align:center;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  border-radius:6px;
  padding:2px 4px;
  font-size:8px;
  font-weight:900;
}
.mini-status.active{
  background:#e4f5e9;
  color:#1b713e;
}
.mini-status.warning{
  background:#fff0cf;
  color:#9b6200;
}
.mini-status.stopped{
  background:#ffe1e1;
  color:#a51f1f;
}
.mini-status.pending{
  background:#eef1f4;
  color:#7a8797;
}

@media(max-width:430px){
  .filter-group{gap:8px}
  .switch-row{font-size:12px}
  .drug-row{
    grid-template-columns:minmax(70px,22%) minmax(0,1fr) 76px 45px;
    gap:5px;
  }
  .mini-status{font-size:7px;padding:2px 3px}
}

/* V5.6 - 정보별 색상 위계 강화 */
.row-company{
  color:#0d4f8b;
  font-weight:900;
}
.row-name{
  color:#17212f;
  font-weight:900;
}
.row-code{
  color:#6b7280;
  background:#eef2f6;
  border:1px solid #e1e7ee;
}
.row-price{
  color:#a96700;
  font-weight:900;
}

/* 상태는 색으로 바로 구분 */
.mini-status.active{
  background:#e2f5e8;
  color:#13733b;
  border:1px solid #bfe4cb;
}
.mini-status.warning{
  background:#fff2cf;
  color:#9a6200;
  border:1px solid #f0d58d;
}
.mini-status.stopped{
  background:#ffe3e3;
  color:#b11f1f;
  border:1px solid #f2bebe;
}
.mini-status.pending{
  background:#f0f2f5;
  color:#7a8491;
  border:1px solid #dfe4ea;
}

/* 한 줄 안에서도 구분이 더 잘 되도록 아주 약한 구분선 */
.drug-row{
  border-left:4px solid #d8e5f1;
}
.drug-row:hover{
  background:#fbfdff;
}

/* 검색 결과 제목도 제약회사/제품명 색상 차이 */
.selected-company{
  color:#ffffff;
  font-weight:900;
}
.selected-name-line h2{
  color:#d7e2ed;
}
.selected-code{
  color:#f1f5f9;
  background:rgba(255,255,255,.12);
}

/* V5.7 - 기준일 상단 + 많은 결과 더보기 */
.data-date-bar{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  margin:0 0 9px;
  padding:8px 11px;
  border:1px solid #d9e4ef;
  border-radius:11px;
  background:#ffffff;
  font-size:11px;
}
.data-date-bar span{
  color:#718096;
  font-weight:800;
}
.data-date-bar strong{
  color:#0d4f8b;
  font-size:12px;
}

.load-more-wrap{
  padding:12px 0 2px;
  text-align:center;
}
.load-more-btn{
  width:100%;
  border:1px solid #b9cbe0;
  background:#ffffff;
  color:#123b61;
  border-radius:12px;
  padding:11px 12px;
  font-size:13px;
  font-weight:900;
}
.load-more-btn:active{
  transform:translateY(1px);
  background:#f3f7fb;
}

/* 주성분코드/그룹키를 없애면서 선택제품 정보칸 2열 정리 */
.selected-meta{
  grid-template-columns:1fr 1fr !important;
}
.selected-meta div:first-child{
  grid-column:auto !important;
}

@media(max-width:430px){
  .data-date-bar{
    padding:7px 9px;
    font-size:10px;
  }
  .data-date-bar strong{
    font-size:11px;
  }
}


/* V6.7 - 공개용 최종 검색 메인 */
.company-link{
  text-decoration:none;color:#123b61;font-size:12px;font-weight:900;
  background:#eef4fa;border-radius:999px;padding:7px 10px;
}
.data-banner{
  display:flex;gap:6px;align-items:center;flex-wrap:wrap;
  background:#eef6f0;border:1px solid #cbe3d1;color:#225d38;
  border-radius:12px;padding:9px 11px;font-size:11px;margin-bottom:10px;
}
.data-banner strong{font-weight:900}
.data-banner.warning{background:#fff5db;border-color:#efd28c;color:#76510b}
.data-banner.error{background:#ffe8e8;border-color:#efbcbc;color:#982c2c}
.data-date-bar{
  display:flex;justify-content:space-between;align-items:center;
  padding:0 3px 7px;color:#667487;font-size:11px;
}
.data-date-bar strong{color:#123b61}
.suggestion{cursor:pointer}
.suggestion-company{display:block;color:#0d4f8b;font-size:14px;font-weight:900}
.suggestion-product{display:flex;gap:6px;align-items:center;margin-top:2px;min-width:0}
.suggestion-product span:first-child{font-size:13px;font-weight:800;color:#25364a;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.suggestion-code{flex:0 0 auto;font-size:9px;color:#6b7280;background:#eef2f6;border-radius:6px;padding:2px 4px}
.message-box{
  margin:0 0 10px;padding:12px 13px;border-radius:12px;
  background:#fff5db;border:1px solid #efd28c;color:#76510b;font-size:12px;
}
.selected-statuses{min-width:94px}
.selected-meta{grid-template-columns:1fr 1fr}
.selected-meta div:first-child{grid-column:1/-1}
.selected-meta div:last-child{grid-column:auto}
#selectedBasis{color:#536174!important;font-weight:800}
.result-head p + p{margin-top:1px}
.mini-status.permit-active{background:#e7f4ec;color:#17663a;border:1px solid #c7e2d0}
.mini-status.permit-warning{background:#ffe3e3;color:#9c2323;border:1px solid #f1c4c4}
.status.permit-active{background:#dff3e5;color:#16723b}
.status.permit-warning{background:#ffe0e0;color:#a32020}
.row-status{min-width:88px}
.drug-row{grid-template-columns:minmax(78px,23%) minmax(0,1fr) 92px 54px}
.load-more-wrap{text-align:center;padding:14px 0 2px}
.load-more-btn{
  border:1px solid #cfd9e4;background:#fff;color:#123b61;font-weight:900;
  border-radius:12px;padding:10px 18px;min-width:160px;
}
@media(max-width:430px){
  main{padding-left:10px;padding-right:10px}
  .intro h1{font-size:22px}
  .intro>p:last-child{font-size:11px}
  .controls{align-items:flex-start}
  .controls select{padding:8px 7px;font-size:11px}
  .drug-row{
    grid-template-columns:minmax(66px,21%) minmax(0,1fr) 78px 43px;
    gap:4px;padding:7px 7px;
  }
  .row-company{font-size:12px}
  .row-name{font-size:11px}
  .row-status{min-width:0}
  .mini-status{font-size:6.8px;padding:2px}
  .row-price{font-size:10px}
  .selected-head{gap:8px}
  .selected-statuses{min-width:82px}
  .status{font-size:8px;padding:5px 6px}
}

/* V6.8.2 급여 + 식약처 전체 허가 의약품 */
.suggestion-pay{
  margin-left:auto;flex:0 0 auto;font-size:8px;font-weight:800;
  color:#5f6b78;background:#eef2f6;border-radius:999px;padding:2px 5px;
}
.row-pay{
  display:inline-block;margin-left:5px;font-size:8px;font-weight:800;
  color:#17663a;background:#e7f4ec;border-radius:999px;padding:2px 5px;
}
.row-pay.not-listed{color:#7a5200;background:#fff1cf}
#reimbursement{color:#6a4a00}
@media(max-width:430px){
  .suggestion-pay{font-size:7px}
  .row-pay{font-size:7px;margin-left:3px}
}
