/* ============================================
   PURCHASE APPLICATION - RESPONSIVE CSS
   ============================================ */

/* Desktop/Mobile 전환 기본 설정 */
.purchase-desktop-only {
    display: block;
}

.purchase-mobile-only {
    display: none;
}

/* ===== 모바일 폼 스타일 ===== */
.purchase-mobile-form {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.purchase-mobile-field {
    border: 1px solid #888;
    border-bottom: none;
    background: #fff;
}

.purchase-mobile-field:last-child {
    border-bottom: 1px solid #888;
}

.purchase-mobile-field label {
    display: block;
    background: #f0f0f0;
    padding: 5px 10px;
    font-weight: 600;
    font-size: 14px;
    border-bottom: 1px solid #ddd;
}

.purchase-mobile-field input[type="text"],
.purchase-mobile-field input[type="tel"],
.purchase-mobile-field input[type="email"],
.purchase-mobile-field select {
    width: 100%;
    padding: 6px 10px;
    border: none;
    font-size: 16px;
    background: #fff;
    outline: none;
}

.purchase-mobile-field input::placeholder {
    color: #bbb;
}

.purchase-messenger-checkboxes-mobile {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    padding: 6px 10px;
    background: #fff;
}

.purchase-messenger-checkboxes-mobile label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    padding: 0;
    font-weight: normal;
    font-size: 14px;
    border: none;
    cursor: pointer;
}

/* ===== 모바일 상품 카드 ===== */
.purchase-product-cards {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.product-type-header {
    padding: 12px 15px;
    font-weight: 700;
    font-size: 15px;
    text-align: center;
    margin-top: 10px;
    border-radius: 8px 8px 0 0;
}

.product-type-header.tower {
    background: #e3f2fd;
    color: #1565c0;
}

.product-type-header.courtyard {
    background: #fff3e0;
    color: #e65100;
}

.product-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.product-card-header {
    background: #f5f5f5;
    padding: 8px 15px;
    font-weight: 700;
    font-size: 18px;
    text-align: center;
    border-bottom: 1px solid #ddd;
}

.product-card-body {
    padding: 0;
}

.product-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 15px;
    border-bottom: 1px solid #eee;
}

.product-row:last-child {
    border-bottom: none;
}

.product-label {
    font-size: 13px;
    color: #666;
    font-weight: 500;
}

.product-value {
    font-size: 14px;
    font-weight: 600;
    text-align: right;
}

.product-value.price {
    color: #d32f2f;
}

.product-value input[type="number"] {
    width: 70px;
    padding: 2px 6px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: center;
    font-size: 16px;
}

/* ===== 반응형 미디어 쿼리 ===== */
@media (max-width: 768px) {
    .purchase-desktop-only {
        display: none !important;
    }

    .purchase-mobile-only {
        display: block !important;
    }

    .purchase-main {
        padding: 20px 15px;
        padding-top: 80px;
    }

    .purchase-main h1 {
        font-size: 24px;
        margin-bottom: 25px;
    }

    .purchase-section-title {
        font-size: 16px;
        margin-bottom: 15px;
    }

    .purchase-form-section {
        margin-bottom: 30px;
        overflow-x: visible;
    }

    /* 투자 안내 */
    .purchase-investment-notice {
        font-size: 13px;
        padding: 15px;
        background: #fff5f5;
        border-radius: 8px;
        margin-top: 15px;
        line-height: 1.6;
    }

    /* 파일 업로드 */
    .purchase-upload-area {
        flex-direction: column;
        align-items: stretch;
    }

    .purchase-btn-upload {
        width: 100%;
        padding: 12px;
    }

    .purchase-file-name {
        margin-top: 8px;
        text-align: center;
    }

    /* 면책조항 */
    .purchase-disclaimer {
		margin-top:20px !important;
        font-size: 14px;
        padding: 15px;
        background: #f9f9f9;
        border-radius: 8px;
        line-height: 1.6;
    }

    .purchase-disclaimer p {
        margin-bottom: 10px;
    }

    .purchase-disclaimer p:last-child {
        margin-bottom: 0;
    }

    /* 동의 섹션 */
    .purchase-consent-section {
        padding: 15px;
    }

    .purchase-consent-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .purchase-consent-item label {
        font-size: 14px;
        line-height: 1.5;
    }

    .purchase-view-btn {
        align-self: flex-end;
    }

    /* 제출 버튼 */
    .purchase-submit-section {
        margin-top: 30px;
    }

    .purchase-submit-btn {
        width: 100%;
        padding: 15px;
        font-size: 16px;
    }

    /* 모달 */
    .purchase-modal-box {
        width: 95%;
        padding: 20px;
        max-height: 85vh;
    }

    .purchase-modal-box h2 {
        font-size: 18px;
        padding-right: 30px;
    }

    .purchase-modal-body p {
        font-size: 13px;
    }
}

/* 더 작은 화면 */
@media (max-width: 480px) {
    .purchase-main h1 {
        font-size: 22px;
    }

    .purchase-messenger-checkboxes-mobile {
        flex-direction: column;
        gap: 6px;
    }

    .product-value input[type="number"] {
        width: 60px;
    }
}
