/*
 * 响应式适配样式
 * 移动端与桌面端自适应
 */

@media (max-width: 480px) {
    .captcha-container {
        max-width: 100%;
        border-radius: 8px;
        margin: 0;
        box-shadow: none;
    }
    
    .captcha-header {
        padding: 12px 14px 10px;
    }
    
    .captcha-title {
        font-size: 13px;
    }
    
    .captcha-body {
        padding: 14px;
        min-height: 120px;
    }
    
    /* 滑块 - 移动端 */
    .captcha-slider-bg {
        height: 130px;
    }
    
    .captcha-slider-track {
        height: 38px;
    }
    
    .captcha-slider-btn {
        width: 42px;
        height: 42px;
        top: -4px;
        left: -4px;
    }
    
    .captcha-slider-piece {
        width: 42px !important;
        height: 42px !important;
    }
    
    /* 点击 - 移动端 */
    .captcha-click-bg {
        height: 150px;
    }
    
    .captcha-click-target {
        width: 28px;
        height: 28px;
        font-size: 11px;
    }
    
    /* 拼图 - 移动端 */
    .captcha-puzzle-grid {
        gap: 3px;
    }
    
    .captcha-puzzle-piece {
        border-radius: 4px;
    }
    
    /* 文字 - 移动端 */
    .captcha-text-input {
        height: 38px;
        font-size: 14px;
    }
    
    .captcha-text-img {
        width: 100%;
        max-width: 280px;
        height: auto;
        aspect-ratio: 320 / 180;
    }
    
    .captcha-result {
        padding: 10px 14px;
        font-size: 12px;
    }
}

@media (min-width: 481px) and (max-width: 768px) {
    .captcha-container {
        max-width: 340px;
    }
    
    .captcha-slider-bg {
        height: 140px;
    }
}

/* 触摸设备优化 */
@media (pointer: coarse) {
    .captcha-slider-btn {
        width: 48px;
        height: 48px;
    }
    
    .captcha-puzzle-piece {
        min-height: 60px;
    }
}

/* 横屏模式 */
@media (orientation: landscape) and (max-height: 500px) {
    .captcha-body {
        padding: 10px;
        min-height: 80px;
    }
    
    .captcha-slider-bg {
        height: 100px;
    }
    
    .captcha-click-bg {
        height: 120px;
    }
}
