/* =========================================
   Dplaza 월간랭킹 TOP10 리뉴얼
   - 업체 크기는 동일하게 유지
   - 1~3위는 배지 색상만 강조
   - 큰폰트 24 / 중간폰트 16 / 작은폰트 14 기준
========================================= */

.dprank-page{
    width:980px;
    margin:0 auto;
    box-sizing:border-box;
    font-family:"Malgun Gothic","맑은 고딕",Dotum,Arial,sans-serif;
    color:#222;
}

.dprank-title{
    margin:0 0 18px 0;
    padding:14px 18px;
    background:#fafbfd;
    border:1px solid #e5e7eb;
    border-radius:7px;
    box-sizing:border-box;
}

.dprank-title h2{
    margin:0 0 6px 0;
    font-size:24px;
	font-weight: 600;
    line-height:1.25;
    color:#111827;
    letter-spacing: -.7px;
}

.dprank-title h2 strong{
    color: #dd1032;
}

.dprank-title p{
    margin:0;
    font-size:15px;
	font-weight: 500;letter-spacing: -.7px;
    line-height:1.5;
    color:#666;
}

.dprank-section{
    margin-top:22px;
}

.dprank-section-head{
    display:flex;
    align-items:flex-end;
    justify-content:space-between;
    gap:12px;
    margin-bottom:12px;
    padding-bottom:10px;
    border-bottom:2px solid #111827;
}

.dprank-section-head h3{
    margin:0;
    font-size:24px;
    line-height:1.2;
    color:#111827;
    font-weight: 600;letter-spacing: -.7px;
	margin: 0 0 6px 0;
}

.dprank-section-head p{
    margin:0;
    font-size:15px;
    color:#666;
    line-height:1.4;
	font-weight: 500;letter-spacing: -.7px;
}

.dprank-section-head a{
    font-size:15px;
    color:#dd1032;
    font-weight: 600;letter-spacing: -.7px;
}

.dprank-grid{
    display:grid;
    grid-template-columns:repeat(2, 1fr);
    gap:12px;
}

.dprank-card{
    position:relative;
	width:484px;
    min-height:146px;
    padding:26px 16px;
    background:#fff;
    border:1px solid #e0e7f1;
    border-radius:7px;
    box-sizing:border-box;
    box-shadow:0 2px 8px rgba(15,23,42,.05);
    transition:border-color .15s ease, box-shadow .15s ease, transform .15s ease;
	cursor: pointer;
}

.dprank-card:hover{
    border-color:#b9cff0;
    box-shadow:0 14px 28px rgba(20,40,80,.14);
    transform:translateY(-4px);
}

.dprank-card-main{
    display:flex;
    gap:14px;
    align-items:center;
}

.dprank-logo{
    flex:0 0 118px;
    width:118px;
    height:72px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#fff;
    border:1px solid #eef0f3;
    border-radius:7px;
    overflow:hidden;
    box-sizing:border-box;
}

.dprank-logo img{
    display:block;
    max-width:104px;
    max-height:58px;
    width:auto;
    height:auto;
}

.dprank-info{
    min-width:0;
    flex:1;
}

.dprank-name-row{
    display:flex;
    align-items:center;
    gap:8px;
    margin-bottom:7px;
}

.dprank-badge{
    flex:0 0 auto;
    min-width:44px;
    height:28px;
    padding:0 8px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    border-radius:999px;
    background:#F4F6F8;
    color:#444444;
    font-size:15px;
    font-weight: 600;letter-spacing: -.7px;
    box-sizing:border-box;
}

.dprank-card.rank-1 .dprank-badge{background:#D4AF37;color:#ffffff;}
.dprank-card.rank-2 .dprank-badge{background:#9EA7AD;color:#ffffff;}
.dprank-card.rank-3 .dprank-badge{background:#B87333;color:#ffffff;}

.dprank-shopname{
    display:block;
    min-width:0;
    font-size:24px;
    line-height:1.2;
    color:#111827;
    font-weight: 600;letter-spacing: -.7px;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
}

.dprank-location{
    margin:0 0 5px 0;
    font-size:15px;
    font-weight:600;
    letter-spacing:-.7px;
    line-height:1.35;
    color:#374151;

    /* 긴 매장주소는 말줄임 없이 다음 줄로 표시 */
    white-space:normal;
    overflow:visible;
    text-overflow:clip;
    word-break:keep-all;
}

.dprank-count{
    margin:0;
    font-size:15px;
	font-weight: 500;letter-spacing: -.7px;
    line-height:1.35;
    color:#6b7280;
}

.dprank-keywords{
    display:flex;
    flex-wrap:wrap;
    gap:6px;
    margin-top:13px;
    padding-top:12px;
    border-top:1px dashed #e5e7eb;
}

.dprank-keywords span{
    display: inline-flex;
    align-items: center;
    height: 27px;
    margin: 0 6px 6px 0;
    padding: 0 10px;
    border-radius: 7px;
    background: #eaf6f1;
    color: #2563eb;
    font-size: 15px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: -.7px;
    white-space: nowrap;
}

.dprank-youtube{
    width:100%;
    aspect-ratio:16/9;
    margin-bottom:12px;
    border-radius:12px;
    overflow:hidden;
    background:#111;
}

.dprank-youtube iframe{
    display:block;
    width:100%;
    height:100%;
    border:0;
}

.dprank-youtube-card{
    min-height:330px;
}

.dprank-section-visit .dprank-section-head{border-bottom-color:#dd1032;}
.dprank-section-md .dprank-section-head{border-bottom-color:#1f64d8;}
.dprank-section-youtube .dprank-section-head{border-bottom-color:#0b8f50;}

@media screen and (max-width:980px){
    .dprank-page{
        width:100%;
        padding:14px 12px 28px 12px;
    }
    .dprank-grid{
        grid-template-columns:1fr;
    }
}

@media screen and (max-width:560px){
    .dprank-card-main{
        align-items:flex-start;
    }
    .dprank-logo{
        flex-basis:96px;
        width:96px;
        height:64px;
    }
    .dprank-logo img{
        max-width:84px;
        max-height:50px;
    }
    .dprank-shopname{
        font-size:22px;
    }
    .dprank-location{
        white-space:normal;
    }
}

.dprank-card:focus {
    outline: none;
}

/* =========================================
   전월 자동랭킹 추가 스타일
========================================= */

/* 등록된 매장 로고가 없는 경우 깨진 이미지 대신 표시 */
.dprank-no-logo{
    display:flex;
    align-items:center;
    justify-content:center;
    width:100%;
    height:100%;
    color:#9ca3af;
    font-size:15px;
    font-weight:600;
    letter-spacing:-.4px;
}

/* 패션MD추천은 실제 11~20위지만,
   화면에서는 별도 추천 TOP10처럼 1~10위 배지를 사용 */
.dprank-section-md .dprank-badge{
    white-space:nowrap;
}

/* =========================================
   랭킹용 매장정보 카드
   - search3.php 매장정보 구성을 랭킹 페이지에 적용
   - 순위 배지만 추가
========================================= */

.dprank-store-card{
    position:relative;
    width:484px;
    min-height:314px;
    padding:26px 16px;
    background:#fff;
    border:1px solid #dfe6ef;
    border-radius:7px;
    box-sizing:border-box;
    box-shadow:0 2px 8px rgba(15,23,42,.04);
    cursor:pointer;
    transition:border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.dprank-store-card:hover{
    border-color:#b9cff0;
    box-shadow:0 14px 28px rgba(20,40,80,.12);
    transform:translateY(-3px);
}

.dprank-store-card:focus{
    outline:none;
}

/* 순위 배지
   매장명 바로 앞에 자연스럽게 배치 */
.dprank-store-rank{
    position:static;

    display:inline-flex;
    align-items:center;
    justify-content:center;

    flex:0 0 auto;

    min-width:44px;
    height:27px;
    padding:0 8px;

    border-radius:999px;

    background:#f1f4f7;
    color:#4b5563;

    font-size:13px;
    font-weight:700;
    letter-spacing:-.5px;

    box-sizing:border-box;
}

.dprank-store-rank.rank-1{
    background:#D4AF37;
    color:#fff;
}

.dprank-store-rank.rank-2{
    background:#9EA7AD;
    color:#fff;
}

.dprank-store-rank.rank-3{
    background:#B87333;
    color:#fff;
}

.dprank-store-visit{
    flex:0 0 auto;
    margin-left:3px;

    color:#8a929a;
    font-size:12px;
    font-weight:500;
    white-space:nowrap;
}

.dprank-store-top{
    display:flex;
    align-items:flex-start;
    gap:16px;
    padding:0;
}

.dprank-store-logo{
    flex:0 0 132px;
    width:132px;
    height:100px;
    display:flex;
    align-items:center;
    justify-content:center;
    overflow:hidden;
    border:1px solid #e4e8ed;
    border-radius:7px;
    background:#fff;
    box-sizing:border-box;
}

.dprank-store-logo a{
    display:flex;
    align-items:center;
    justify-content:center;
    width:100%;
    height:100%;
}

.dprank-store-logo img{
    display:block;
    max-width:120px;
    max-height:88px;
    width:auto;
    height:auto;
}

.dprank-store-no-logo{
    display:flex;
    align-items:center;
    justify-content:center;
    width:100%;
    height:100%;
    color:#9ca3af;
    font-size:15px;
    font-weight:700;
}

.dprank-store-main{
    min-width:0;
    flex:1;
}

.dprank-store-title-row{
    display:flex;
    align-items:center;
    flex-wrap:wrap;
    gap:7px;
    min-height:34px;
}

.dprank-store-title-row h4{
    margin:0;
    color:#111827;
    font-size:24px;
    font-weight:700;
    line-height:1.2;
    letter-spacing:-.8px;
}

.dprank-store-title-row h4 a{
    color:#111827;
    text-decoration:none;
}

.dprank-store-badges{
    display:flex;
    align-items:center;
    flex-wrap:wrap;
    gap:5px;
}

.dprank-store-badge{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    height:27px;
    padding:0 9px;
    border-radius:5px;
    font-size:13px;
    font-weight:700;
    line-height:1;
    white-space:nowrap;
}

.dprank-store-badge.badge-sale{
    background:#fff1c7;
    color:#c47700;
}

.dprank-store-badge.badge-best{
    background:#eaf8df;
    color:#24831b;
}

.dprank-store-badge.badge-premium{
    background:#eef3ff;
    color:#385dba;
}

.dprank-store-badge.badge-hit{
    background:#fff0f3;
    color:#c33d58;
}

.dprank-store-memo{
    margin:8px 0 0;
    color:#59636d;
    font-size:13px;
    font-weight:500;
    line-height:1.5;
    letter-spacing:-.5px;
    word-break:keep-all;
}

.dprank-store-keywords{
    display:flex;
    flex-wrap:wrap;
    gap:7px;
    margin-top:14px;
}

.dprank-store-keywords span{
    display:inline-flex;
    align-items:center;
    min-height:27px;
    padding:4px 10px;
    border-radius:7px;
    background:#eaf6f1;
    color:#2563eb;
    font-size:15px;
    font-weight:600;
    line-height:1.25;
    letter-spacing:-.6px;
    box-sizing:border-box;
}

.dprank-store-meta{
    margin-top:16px;
    padding-top:13px;
    border-top:1px dashed #dfe4e9;
}

.dprank-store-meta p{
    display:flex;
    align-items:flex-start;
    gap:8px;
    margin:0 0 7px;
    color:#4b5563;
    font-size:15px;
    line-height:1.45;
    letter-spacing:-.5px;
}

.dprank-store-meta p:last-child{
    margin-bottom:0;
}

.dprank-store-meta strong{
    flex:0 0 auto;
    color:#6b7280;
    font-weight:500;
}

.dprank-store-meta span{
    color:#111827;
    font-weight:600;
    word-break:keep-all;
}

@media screen and (max-width:980px){
    .dprank-store-card{
        width:100%;
    }
}

@media screen and (max-width:560px){
    .dprank-store-card{
        min-height:0;
        padding:22px 14px 16px;
    }

    .dprank-store-top{
        gap:12px;
        padding-right:0;
        padding-top:34px;
    }

    .dprank-store-logo{
        flex-basis:104px;
        width:104px;
        height:82px;
    }

    .dprank-store-logo img{
        max-width:94px;
        max-height:72px;
    }

    .dprank-store-title-row h4{
        font-size:21px;
    }
}

