.main {
    height: auto;
    min-height: 70%;
}
.landing {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.container {
    width: 1080px;
    margin: 0 auto;
}
.container-region {
    width: 1080px;
    margin: 0 auto;
    background: #fff;
    border-radius: 4px;
    box-shadow: 0 2px 8px 0 rgba(0, 0, 0, .16);
}

.region-header {
    margin: 48px 0 38px;
}

.region-title {
    font-weight: 500;
    font-size: 24px;
    line-height: 36px;
    justify-content: space-between;
    align-items: baseline;
    color: #212121;

    margin-top: 40px;
    margin-bottom: 40px;
}

.divider1 {
    margin-top : 30px;
    width: 100%;
    border-bottom: 1px solid #000000;
    margin-bottom: 30px;
    justify-content: center;
}

.section-region {
    width: 1080px;
    margin: 0 auto;
    background: #fff;
    border-radius: 4px;
}

.region-buttons {
    padding: 48px 0 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 0 auto;
    max-width: 900px;
}

.r-button {
    font-weight: 500;
    font-size: 20px;
    padding: 10px 30px;
    box-sizing: border-box;
    border: 1px solid #005792;
    background-color: #ffffff;
    color: #001A2C;
    border-radius: 10px;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

/* 선택된 버튼 스타일 */
.r-button.selected {
    background: linear-gradient(90deg, #005792 0%, #001A2C 100%);
    color: white;
    border: 1px solid #001A2C;
}
.r-button:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}
.map-svg path:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.map-wrapper {
    display: flex;
    justify-content: center;
    overflow: visible;
}

.map-svg {
    width: 100%;
    max-width: 1000px;
    height: auto;
    aspect-ratio: 1 / 1;
    display: block;
    border: none;
    background: white;
}

.map-svg path {
    fill: #ffffff;
    stroke: #005792;
    stroke-width: 1;
    cursor: pointer;
    transition: fill 0.2s;
}

.map-svg path.selected {
    fill: #00589237;
    filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, 0.537));
}
.map-svg text {
    font-size: 20px;
    font-weight: 500;
    fill: black;
    text-anchor: middle;
    alignment-baseline: central;
    cursor: pointer;
    user-select: none;
}
.map-svg text.selected {
    fill: #005792;
    font-weight: 700;
}
.selected-region-container {
    width: 100%;
    margin-top: 30px;
}

#selected-regions {
    width: 1080px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
    justify-content: flex-start;
}

#selected-regions .tag {
    background: linear-gradient(90deg, #005792 0%, #001A2C 100%);
    color: white;
    font-weight: 400;
    border-radius: 25px;
    padding: 10px 20px;
    font-size: 20px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.container-recommand-service {
    width: 100%;
    padding: 53px 0 52px;
    margin-top: 10px;
    background-image: -image-set(url("/static/image/recommand-tourist-attractions-detail/background.png?20250620") 1x, url("/static/img/acquisition/background@2x.png?20250620") 2x, url("/static/img/acquisition/background@3x.png") 3x);
    background-position: top center;
    background-repeat: no-repeat;
}
.container-recommand-title {
    margin: 0 auto;
    height: 45px;
    background: linear-gradient(90deg, #005792 0%, #001A2C 100%);
    display: flex;
    align-items: center;
    padding-left: 20px;
    font-weight: 500;
    font-size: 20px;
    color: white;
}

svg text {
    cursor: default;
    user-select: none;
}

.container-choice-region {
    width: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    padding-left: 20px;
    padding-right: 20px;
    font-weight: 200;
    font-size: 20px;
}

.sort-select {
    margin: 30px 50px 20px auto;
    background-color: #ffffff;
    border: 0px solid #ffffff;
    border-radius: 12px;
    padding: 10px 20px;
    margin-bottom: 20px;
    transition: all 0.3s ease;
    display:flex;
    justify-content: flex-end;
}

.tour-section {
    width: 1080px;
    margin: 30px 40px;
}


.tour-card-list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

.tour-card {
    width:  195px;
    height: 300px;               /* ✅ 전체 높이 고정 */
    display: flex;
    flex-direction: column;
    border: 1px solid #eee;
    border-radius: 14px;
    overflow: hidden;
    background: #fff;

}

.card-image-wrapper{ aspect-ratio: 4/3; overflow:hidden; }
.card-image{ width:100%; height:100%; object-fit:cover; display:block; }
.card-content{ padding:12px; }
.card-title{ font-size:15px; line-height:1.35; margin:6px 0 0; }
.card-meta .category{ color:#6b7280; font-size:12px; }

.empty, .error {
    text-align: center;
    color: #6b7280;
    padding: 24px 0;
}


.pagination{
    display:flex;
    flex-wrap:wrap;
    justify-content:center;
    gap:6px;
    margin:20px 0 8px;
}
.pagination button{
    min-width:34px;
    height:34px;
    padding:0 10px;
    border:1px solid #e5e7eb;
    background:#fff;
    border-radius:8px;
    cursor:pointer;
}
.pagination button:hover{ background:#f3f4f6; }
.pagination button.active{
    background:#111827;
    color:#fff;
    border-color:#111827;
    cursor:default;
}
.pagination button:disabled{
    opacity:.45;
    cursor:default;
}
@media (max-width: 1200px) {
    .tour-card-list { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
    .tour-card-list { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
    .tour-card-list { grid-template-columns: 1fr; }
}

/* 480px */

@media (max-width: 480px) {
    .main,
    .container,
    .container-region,
    .section-region,
    #selected-regions,
    .container-choice-region,
    .tour-section,
    .container-review,
    .review-container {
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        margin: 0 auto;
        box-sizing: border-box;
    }

    /* 관광지 카드: 2열 */
    .tour-card-list {
        grid-template-columns: repeat(3, 1fr); /* 3개 딱 맞춤 */
        gap: 8px;
        justify-content: center;

        /* 여백 */
        margin: 20px 8px;   /* 위/아래 16px, 좌/우 8px */
    }


    .tour-card {
        width: 100%;     /* 칸 비율에 맞춰 자동 줄어듦 */
        height: auto;    /* 필요하면 고정 높이 복원 가능 */
        border-radius: 10px;
    }

    .card-image-wrapper { aspect-ratio: 4 / 3; }
    .card-image { width: 100%; height: 100%; object-fit: cover; }

    .map-wrapper {
        display: flex;
        justify-content: center;
        overflow: hidden;   /* 넘친 부분은 잘라내 */
    }
    .map-svg {
        width: 120%;
        height: auto;
        transform: scale(1.2, 1.05);
        transform-origin: center center;   /* 가운데 기준으로 확대 */
    }


    /* 지역 버튼: 레이아웃 강제 줄이기 (여러 줄 허용) */
    .region-buttons {
        max-width: 100%;
        gap: 6px;
        justify-content: center;
    }
    .r-button {
        font-size: 12px;
        padding: 13px 5px;
        flex: 1 1 calc(25% - 6px);
        text-align: center;
        font-size: 15px;
    }

    /* 선택된 지역 태그도 폭 맞춤 */
    #selected-regions {
        width: 100%;
        gap: 6px;
        padding: 0 8px;
    }
    #selected-regions .tag {
        font-size: 12px;
        padding: 4px 8px;
    }

    /* 페이지네이션 버튼 크기 조정 */
    .pagination button {
        min-width: 28px;
        height: 28px;
        font-size: 11px;
    }

    /* 타이틀/텍스트 축소 */
    .region-title { font-size: 18px; margin: 16px 0; text-align: center; }
    .place-name { font-size: 16px; margin: 16px 0; text-align: center; }
}