/* 备案信息footer手机端三行居中 */
@media (max-width: 600px) {
    .beian-footer > div {
        flex-direction: column !important;
        align-items: center !important;
        padding: 12px 0 !important;
    }
    .beian-footer span {
        display: block;
        text-align: center;
        margin-bottom: 6px !important;
    }
    .beian-footer .beian-links {
        flex-direction: column !important;
        gap: 0 !important;
        width: 100% !important;
        align-items: center !important;
        margin-top: 0 !important;
    }
    .beian-footer .beian-links a {
        display: block !important;
        text-align: center !important;
        margin: 2px 0 !important;
    }
}
/* 手机端自定义尺寸输入区域优化 */
@media (max-width: 600px) {
    .custom-size-section > div {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 4px !important;
    }
    .custom-size-section label,
    .custom-size-section input {
        width: 100% !important;
        margin-right: 0 !important;
        margin-bottom: 2px !important;
        text-align: left !important;
    }
        #customSizeRatioBox, #customSizeRatioLabel {
            display: inline-block;
            margin-top: 6px !important;
            margin-left: 0 !important;
            vertical-align: middle;
        }
            .custom-size-section .custom-ratio-row {
                display: flex;
                flex-direction: row;
                align-items: center;
                gap: 4px;
                margin-top: 0;
                margin-bottom: 0;
                white-space: nowrap;
            }
        #customSizeRatioBox {
            order: 0;
        }
        #customSizeRatioLabel {
            order: 1;
            margin-left: 0 !important;
        }
}
/* 增加表单行间距 */
.sandphoto-form .form-step {
    margin-bottom: 18px;
    line-height: 1.8;
}

/* 自定义尺寸输入行间距 */
.custom-size-section {
    margin-bottom: 12px;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 40px;
    color: white;
}

header h1 {
    font-size: 3rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

header p {
    font-size: 1.2rem;
    opacity: 0.9;
}

main {
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.upload-section {
    margin-bottom: 40px;
}

.upload-area {
    border: 3px dashed #ddd;
    border-radius: 15px;
    padding: 60px 20px;
    text-align: center;
    transition: all 0.3s ease;
    background: #fafafa;
    cursor: pointer;
}

.upload-area:hover {
    border-color: #667eea;
    background: #f0f4ff;
}

.upload-area.dragover {
    border-color: #667eea;
    background: #e8f0ff;
    transform: scale(1.02);
}

.upload-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.upload-content h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #333;
}

.upload-content p {
    color: #666;
    margin-bottom: 20px;
}

.upload-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.upload-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.settings-section {
    margin-bottom: 40px;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.setting-group {
    display: flex;
    flex-direction: column;
}

.setting-group label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
}

.form-control {
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
    background: white;
}

.form-control:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Custom size input styling */
#customSizeGroup,
#customSizeGroup2,
#customCountGroup {
    transition: all 0.3s ease;
}

#customSizeGroup.show,
#customSizeGroup2.show,
#customCountGroup.show {
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Number input specific styling */
input[type="number"].form-control {
    appearance: textfield;
    -moz-appearance: textfield;
}

input[type="number"].form-control::-webkit-outer-spin-button,
input[type="number"].form-control::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.preview-section {
    border-top: 2px solid #eee;
    padding-top: 30px;
}

.preview-section h3 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

.preview-container {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

#previewCanvas {
    border: 2px solid #ddd;
    border-radius: 10px;
    max-width: 100%;
    height: auto;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.preview-info {
    text-align: center;
}

#photoCount {
    font-size: 1.1rem;
    margin-bottom: 15px;
    color: #666;
}

#photoCount span {
    font-weight: bold;
    color: #667eea;
}

.download-btn {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    border-radius: 25px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.4);
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.6);
}

.download-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

footer {
    text-align: center;
    color: white;
    opacity: 0.8;
}

/* Loading animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    main {
        padding: 20px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .settings-grid {
        grid-template-columns: 1fr;
    }
    
    .upload-area {
        padding: 40px 20px;
    }
    
    #previewCanvas {
        width: 100%;
        height: auto;
    }
} 