/* ============================================
   메인 페이지 반응형 스타일
   분기: 1300 → 1024 → 768 → 480 → 345 (max-width)
   ============================================ */

/* ========== 1300px 이하 ========== */
@media (max-width: 1300px) {
    .pc-text {
        display: none;
    }

    .mobile-text {
        display: block;
    }
    .rw-break {
        display: block;
    }
    .main-banner{
        height:760px;
    }

    .main-box {
        padding-top: 140px;
    }

    .main-box-title {
        font-size: 52px;
        line-height: 60px;
    }

    .main-flex-p-text {
        font-size: 52px;
        line-height: 60px;
    }

    .main-flex-p-text-br {
        display: block;
    }

    .main-box-desc {
        font-size: 15px;
        line-height: 1.55;
        margin-top: 0;
    }

    .main-flex-p {
        display: flex;
        flex-direction: column;
    }

    .main-desc-wrapper {
        margin-top: 24px;
    }

    .rw-start {
        padding: 0 20px;
    }

    .rw-start-text {
        font-size: 14px;
        height: 16px;
    }

    .rw-input-field {
        font-size: 14px;
        padding: 12px 16px;
    }

    .rw-input-btn {
        font-size: 14px;
        padding: 12px 24px;
    }
    
    .rw-cate {
        justify-content: center;
        width:100%;
        gap: 10px 7.5px;
        flex-wrap: wrap;
    }

    .rw-cate-item {
        font-size: 14px;
        min-width: 73px;
        height: 30px;
        padding: 8px 14px;
    }

    .blue-effect {
        position: absolute;
        bottom: 0;
        width: 100%;
    }

    .bottom-tap-btn{
        width: 90%;
    height: 20px;
    font-size:12px;
    margin-top: 16px;
    }
    .rw-showcase {
        margin-top: 40px;
    }

    .rw-showcase-title {
        font-size: 30px;
        line-height: 38px;
    }

    .rw-showcase-desc {
        font-size: 17px;
        line-height: 26px;
        margin-top: 28px;
    }

    .rw-showcase-desc-main {
        margin: 0;
    }

    .rw-showcase-desc-main span {
        display: block;
    }

    .rw-showcase-desc-sub {
        display: none;
        margin: 0;
    }

    /* PC와 동일한 모자이크(인라인 높이) 유지, 열만 조정: 1300이하 4열 */
    .rw-list {
        margin-top: 34px;
        gap: 2px;
        column-count: 4;
        max-height: 2000px;
    }

    .rw-tile {
        margin-bottom: 2px;
    }

    /*
     * 1920 기준 가로 372px, 세로는 타일 순서별 $tileHeights(index.php)와 동일
     * 인라인 --rw-aspect-w / --rw-aspect-h 로 타일마다 비율 적용
     */
    .rw-showcase .rw-list .rw-tile {
        width: 100%;
        height: auto !important;
        aspect-ratio: var(--rw-aspect-w, 372) / var(--rw-aspect-h, 385.6);
    }

    .rw-showcase .rw-list .rw-tile > img {
        position: absolute;
        top: 0;
        left: 0;
        width: 100% !important;
        height: 100% !important;
        object-fit: cover;
        object-position: center;
        z-index: 0;
    }

    .rw-showcase .rw-list .rw-tile .tile-cover {
        justify-content: center;
        padding: 12px 0;
    }

    .more-btn{
        width: fit-content;
        height:30px;
        font-size:14px;
        margin-top:20px;
        padding: 6px 18px;
    }

    .rw-tiny{
        margin-top:60px;
        padding: 0 20px;
    }

    .tiny-box {
        display: flex;
        flex-direction: column;
        height: auto;
        align-items: stretch;
        gap: 0;
        padding-top: 10px;
    }

    .tiny-left {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 20px;
        flex: 1;
        justify-content: flex-start;
        padding: 0px 20px 10px;
    }

    .tiny-left-img {
        margin: 20px 0;
        width: 120px;
        height: auto;
    }

    .tiny-left-text-box {
        display: flex;
        margin-top: 0;
        flex-direction: row;
        gap: 6px;
        align-items: center;
    }

    .tiny-left-text {
        font-size: 16px;
        line-height: 24px;
        margin: 0;
    }

    .tiny-left-text-count {
        font-size: 16px;
        line-height: 24px;
        margin: 0;
    }

    .tiny-left-btn {
        width: 170px;
        height: 48px;
        margin-top:10px;
        font-size: 16px;
    }

    .tiny-track {
        flex: 1;
        width: 100%;
        position:relative;
    }

    .tiny-right {
        gap: 8px;
    }

    .tiny-image {
        width: calc((100vw - 40px - 16px) / 3);
        flex: 0 0 calc((100vw - 40px - 16px) / 3);
    }

    .tiny-arrow {
        display: none;
    }

    .tiny-mobile-nav {
        display: flex;
        position: absolute;
        top: 50%;
        left: 0;
        right: 0;
        transform: translateY(-50%);
        justify-content: flex-end;
        align-items: center;
        padding: 0 10px;
        gap: 16px;
        pointer-events: none;
        z-index: 10;
    }

    .tiny-mobile-prev,
    .tiny-mobile-next {
        width: 40px;
        height: 40px;
        background: transparent;
        border: transparent;
        color: #fff;
        font-size: 24px;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        pointer-events: auto;
    }
    .tiny-mobile-prev {
        display: none;
    }

    .rw-active {
        margin-top: 60px;
        padding: 0 20px;
    }

    .active-box {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 16px;
        height: auto;
        padding: 18px;
    }

    .act-left {
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .act-left-title {
        font-size: 18px;
        line-height: 24px;
    }

    .act-left-desc {
        font-size: 14px;
        line-height: 20px;
        margin-top: 12px;
    }

    .act-left-btn {
        width: 140px;
        height: 40px;
        font-size: 14px;
        margin-top: 20px;
    }

    .act-right {
        aspect-ratio: 1;
        width: 100%;
        height: auto;
    }

    .rw-exp {
        margin-top: 20px;
        padding: 0 20px;
    }

    .exp-box {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 16px;
        height: auto;
        padding: 18px;
    }

    .exp-left {
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .exp-left-title {
        font-size: 16px;
        line-height: 24px;
    }

    .exp-left-desc {
        font-size: 14px;
        line-height: 20px;
        margin-top: 12px;
    }

    .exp-left-btn {
        width: 140px;
        height: 40px;
        font-size: 14px;
        margin-top: 20px;
    }

    .edutech-grid {
        grid-column: 2;
        grid-row: 1;
    }


    .edutech-list {
        display: flex;
        flex-direction: column;
        gap: 12px;
        margin-top: 20px;
    }

    .edutech-list p {
        font-size: 14px;
        line-height: 20px;
        color: #fff;
        margin: 0;
        text-align: center;
        padding: 4px 0;
        background: #643FCE;
        border-radius: 8px;
    }

    .rw-school{
        margin-top: 80px;
        padding: 0 20px;
    }

    .school-title {
        font-size: 36px;
        line-height: 48px;
    }

    .school-desc {
        font-size: 16px;
        line-height: 24px;
    }

    .school-card-box {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .school-card-btn{
        height:42px;
    }

    .dash-box {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .dash-line-value {
        font-size: 36px;
        margin-top: 16px;
    }

    .dash-line-label {
        font-size: 16px;
        margin-top: 5px;
    }

    .dash-line{
        height: fit-content;
        padding: 20px;
    }

  

    .rw-review{
        margin-top: 100px;
    }


    .rw-review-title {
        font-size: 34px;
    }

    .rw-review-desc {
        font-size: 18px;
    }

    .review-list-box{
        margin-top:40px;
    }

    .rw-bot{
        padding: 100px 20px 60px;
    }

    .rw-bot-title {
        font-size: 38px;
        line-height: 48px;
    }

    .rw-bot-desc {
        font-size: 18px;
    }
    

    .review-img{
        max-height:234px;
    }

    .rw-btn{
        gap:6px;
    }
    .rw-btn-item{
        height: auto;
        font-size:17px;
        padding: 11px 20px;
    }
    .right-btn{
        flex: 1;
    }

    .bottom-tap-title {
        font-size: 16px;
        line-height: 1.35;
    }
}

/* ========== 1024px 이하 ========== */
@media (max-width: 1024px) {
    .rw-showcase-title {
        font-size: 26px;
        line-height: 34px;
    }

    .rw-showcase-desc {
        font-size: 16px;
        line-height: 24px;
        margin-top: 24px;
    }

    .review-list-box {
        margin-top: 30px;
        padding: 12px 0;
    }

    .review-img-box {
        margin-right: 14px;
    }

    .review-thumb {
        height: 280px;
        border-radius: 14px;
    }

    .review-overlay {
        padding: 36px 24px;
    }

    .review-text {
        font-size: 15px;
    }

    .review-txt {
        font-size: 17px;
        margin-top: 14px;
    }

    .rw-bot {
        padding: 90px 24px 56px;
    }

    .rw-bot-bg {
        width: 115%;
        max-width: none;
    }

    .rw-bot-title {
        font-size: 32px;
        line-height: 40px;
    }

    .rw-bot-desc {
        margin-top: 24px;
        font-size: 17px;
        line-height: 1.6;
        text-align: center;
        word-break: keep-all;
    }

    .rw-btn {
        margin-top: 40px;
    }

    .rw-btn-item {
        min-width: 180px;
    }
}

/* ========== 768px 이하 ========== */
@media (max-width: 768px) {  

    .main-banner{
        height:680px;
    }

    .main-box-title {
        font-size: 40px;
        line-height: 48px;
    }

    .main-flex-p-text {
        font-size: 40px;
        line-height: 48px;
    }

    .main-desc-wrapper {
        margin-top: 20px;
    }

    .rw-input {
        width: 90%;
        height: 50px;
    }

    .rw-input-btn {
        padding: 10px 16px;
        width: 140px;
    }

    .move-icon {
        width: 10px;
        height: 10px;
    }

    .tiny-left-btn {
        width: 120px;
        height: 40px;
        font-size: 14px;
    }

    .school-title {
        font-size: 34px;
        line-height: 42px;
    }

    .school-desc {
        font-size: 15px;
        line-height: 22px;
    }

    .school-card-list-item{
        font-size:15px;
    }

    .dash-box {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .dash-line-value {
        font-size: 28px;
    }

    .dash-line-label {
        font-size: 15px;
    }

    .rw-review-title {
        font-size: 32px;
    }

    .rw-review-desc {
        font-size: 17px;
    }

    .review-list-box {
        margin-top: 26px;
        padding: 10px 0;
    }

    .review-slide-track {
        animation-duration: 110s;
    }

    .review-img-box {
        margin-right: 12px;
    }

    .review-thumb {
        height: 240px;
    }

    .review-overlay {
        padding: 24px 18px;
    }

    .review-text {
        font-size: 14px;
        -webkit-line-clamp: 9;
        line-clamp: 9;
    }

    .review-txt {
        font-size: 15px;
        margin-top: 12px;
    }

    .rw-bot-title {
        font-size: 31px;
        line-height: 40px;
    }

    .rw-bot-desc {
        font-size: 17px;
        margin-top: 20px;
        text-align: center;
    }

    .rw-bot-desc br {
        display: none;
    }

    .rw-btn {
        margin-top: 32px;
        width: 100%;
        justify-content: center;
    }

    .rw-btn-item {
        min-width: 170px;
    }

    .rw-showcase-title {
        font-size: 22px;
        line-height: 30px;
    }

    .rw-showcase-desc {
        font-size: 15px;
        line-height: 22px;
        margin-top: 20px;
    }

    /* 쇼케이스: 768 이하 3열 (1300의 4열 덮어씀) */
    .rw-list {
        column-count: 3;
    }

}

/* ========== 480px 이하 ========== */
@media (max-width: 480px) {
    /* 481~767px: 4열(1300) → 3열(768). 480 이하만 2열 */
    .rw-list {
        column-count: 2;
    }

    .rw-showcase-title {
        font-size: 18px;
        line-height: 26px;
    }

    .rw-showcase-desc {
        font-size: 14px;
        line-height: 21px;
        margin-top: 18px;
    }

    .main-box-title {
        font-size: 28px;
        line-height: 36px;
    }

    .main-flex-p-text {
        font-size: 28px;
        line-height: 36px;
    }

    .main-desc-wrapper {
        margin-top: 16px;
    }

    .rw-start {
        margin-top: 40px;
    }

    .rw-input {
        width: 100%;
        height: 44px;
        max-width: 100%;
        border-radius: 22px;
    }

    .act-left-title{
        font-size:16px;
    }

    .rw-input-btn {
        padding: 8px 12px;
        width: 120px;
        border-radius: 20px;
    }

    .move-icon {
        width: 8px;
        height: 8px;
        border-top: 1.5px solid #fff;
        border-right: 1.5px solid #fff;
    }

    .tiny-left-img {
        width: 110px;
        height: auto;
    }

    .act-left-desc {
        font-size:13px;
    }

    .act-left-btn {
        width: 100px;
        height:28px;
    }

    .exp-left-desc{
        font-size:12px;
    }
    .exp-left-btn {
        width: 100px;
        height:28px;
    }

    .edutech-list p {
        font-size:12px;
    }

    .school-title {
        font-size: 32px;
        line-height: 40px;
    }

    .school-desc {
        font-size: 15px;
        line-height: 22px;
    }

    .school-card-box {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .school-card-title {
        font-size: 20px;
        margin-bottom: 12px;
    }

    .school-card-desc {
        font-size: 14px;
        line-height: 20px;
        margin-bottom: 20px;
    }

    .dash-box {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .dash-line-value {
        font-size: 20px;
    }

    .dash-line-label {
        font-size: 14px;
    }

    .rw-review-title {
        font-size: 30px;
    }

    .rw-review-desc {
        font-size: 17px;
    }

    .review-list-box {
        margin-top: 22px;
        padding: 8px 0;
    }

    .review-slide-track {
        animation-duration: 90s;
    }

    .review-img-box {
        margin-right: 10px;
    }

    .review-thumb {
        height: 200px;
        border-radius: 12px;
    }

    .review-overlay {
        padding: 18px 14px;
    }

    .review-text {
        font-size: 13px;
        -webkit-line-clamp: 7;
        line-clamp: 7;
    }

    .review-txt {
        font-size: 14px;
        margin-top: 10px;
    }

    .rw-bot-title {
        font-size: 24px;
        line-height: 32px;
    }

    .rw-bot-desc {
        font-size: 16px;
        line-height: 1.55;
        margin-top: 16px;
        text-align: center;
    }

    .rw-bot {
        padding: 72px 16px 44px;
    }

    .rw-bot-bg {
        width: 135%;
        left: 50%;
        transform: translateX(-50%);
    }

    .rw-btn {
        margin-top: 24px;
        width: 100%;
    }

    .rw-btn-item {
        width: 100%;
        max-width: 260px;
        min-width: 0;
        justify-content: center;
    }

    .rw-btn-item{
        font-size:15px;
    }

    .bottom-tap-title {
        font-size: 15px;
    }

    .rw-showcase .tile-info-item {
        font-size: 13px;
    }

    /* 각 항목: 아이콘(위) · 텍스트(아래), 항목끼리는 가로 유지 */
    .rw-showcase .tile-info > .tile-info-item {
        flex-direction: column;
        gap: 4px;
        align-items: center;
    }

}

/* ========== 345px 이하 ========== */
@media (max-width: 345px) {
    .rw-showcase-title {
        font-size: 16px;
        line-height: 24px;
    }

    .rw-showcase-desc {
        font-size: 13px;
        line-height: 20px;
        margin-top: 16px;
    }

    .main-box-title {
        font-size: 24px;
        line-height: 32px;
    }

    .main-flex-p-text {
        font-size: 24px;
        line-height: 32px;
    }

    .act-left-title{
        font-size:15px;
    }
    .act-left-desc{
        font-size:12px;
    }
    .exp-left-desc{
        font-size:11px;
    }
    .school-desc{
        font-size:13px;
    }
    .rw-cate{
        gap : 10px 4px;
    }

    .rw-input-btn {
        font-size: 13px;
    }

    .rw-btn-item{
        font-size:13px;
    }

    .rw-bot {
        padding: 60px 12px 34px;
    }

    .rw-bot-bg {
        width: 145%;
    }

    .rw-bot-title {
        font-size: 21px;
        line-height: 28px;
    }

    .rw-bot-desc {
        font-size: 14px;
        line-height: 1.5;
        margin-top: 14px;
    }

    .rw-btn {
        margin-top: 18px;
    }

    .bottom-tap-title {
        font-size: 13px;
    }

    .review-list-box {
        margin-top: 18px;
    }

    .review-slide-track {
        animation-duration: 80s;
    }

    .review-img-box {
        margin-right: 8px;
    }

    .review-thumb {
        height: 172px;
        border-radius: 10px;
    }

    .review-overlay {
        padding: 14px 10px;
    }

    .review-text {
        font-size: 12px;
        -webkit-line-clamp: 6;
        line-clamp: 6;
    }

    .review-txt {
        font-size: 13px;
        margin-top: 8px;
    }

    .rw-showcase .tile-info > .tile-info-item {
        font-size: 12px;
    }

}