* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    padding: 20px;
    line-height: 1.6;
    color: #2c3e50;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    box-shadow: 0 25px 50px rgba(0,0,0,0.15);
    overflow: hidden;
}

.header {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    padding: 40px 30px;
    text-align: center;
}

.header h1 {
    font-size: 2.8em;
    margin-bottom: 15px;
    font-weight: 300;
    letter-spacing: -0.5px;
}

.header p {
    font-size: 1.2em;
    opacity: 0.95;
    font-weight: 300;
}

.content {
    padding: 40px;
}

.form-group {
    margin-bottom: 25px;
}

label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #2c3e50;
    font-size: 1.1em;
}

textarea {
    width: 100%;
    min-height: 200px;
    padding: 20px;
    border: 2px solid #e1e8ed;
    border-radius: 12px;
    font-size: 16px;
    font-family: inherit;
    resize: vertical;
    transition: all 0.3s ease;
    background: #fafbfc;
}

textarea:focus {
    outline: none;
    border-color: #2c3e50;
    background: white;
    box-shadow: 0 0 0 4px rgba(44, 62, 80, 0.1);
}

.button-group {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.btn {
    padding: 14px 28px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-primary {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(44, 62, 80, 0.4);
}

.btn-secondary {
    background: #f8f9fa;
    color: #495057;
    border: 2px solid #e9ecef;
}

.btn-secondary:hover {
    background: #e9ecef;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.btn-success {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    color: white;
}

.btn-success:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(39, 174, 96, 0.4);
}

.btn-info {
    color: #495057;
}

.btn-info:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(52, 152, 219, 0.4);
}

.options-section {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    border: 1px solid #e9ecef;
}

.basic-settings {
    margin-bottom: 25px;
}

.basic-settings .option-group {
    padding: 15px;
    margin-bottom: 0;
}

.settings-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
    margin-bottom: 25px;
}

.option-group {
    background: white;
    padding: 20px;
    border-radius: 10px;
    border: 1px solid #e9ecef;
}

.option-group h4 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.1em;
    display: flex;
    align-items: center;
    gap: 8px;
}

.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #2c3e50;
}

.checkbox-item label {
    margin: 0;
    font-weight: 500;
    font-size: 0.95em;
    cursor: pointer;
}

.select-group {
    margin-bottom: 15px;
}

select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e1e8ed;
    border-radius: 8px;
    font-size: 16px;
    background: white;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

select:focus {
    outline: none;
    border-color: #2c3e50;
    box-shadow: 0 0 0 3px rgba(44, 62, 80, 0.1);
}

.result-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 15px;
    padding: 30px;
    border-left: 5px solid #2c3e50;
}

.result-section h3 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 1.4em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.error {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    border-left: 5px solid #dc3545;
    font-weight: 500;
}

.success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    border-left: 5px solid #28a745;
    font-weight: 500;
}

.copy-btn {
    background: #6c757d;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    margin-top: 15px;
    transition: all 0.3s ease;
    font-weight: 600;
}

.copy-btn:hover {
    background: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 25px;
}

.stat-item {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    text-align: center;
    border: 1px solid #e9ecef;
}

.stat-item h4 {
    color: #2c3e50;
    margin-bottom: 8px;
    font-size: 1em;
    font-weight: 600;
}

.stat-item p {
    font-size: 1.5em;
    font-weight: 700;
    color: #2c3e50;
}

.quota-info {
    background: white;
    padding: 20px;
    border-radius: 12px;
    margin-top: 20px;
    border: 1px solid #e9ecef;
}

.quota-info h4 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.quota-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #f1f3f4;
}

.quota-item:last-child {
    border-bottom: none;
}

.quota-label {
    font-weight: 500;
    color: #495057;
}

.quota-value {
    font-weight: 600;
    color: #2c3e50;
}

@media (max-width: 768px) {
    .content {
        padding: 20px;
    }
    
    .header {
        padding: 30px 20px;
    }
    
    .header h1 {
        font-size: 2.2em;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .settings-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .options-grid {
        grid-template-columns: 1fr;
    }
    
    .stats {
        grid-template-columns: 1fr;
    }
}

/* 新增样式 - 从index.php内联CSS移入 */
/* 折叠面板样式 */
.collapsible {
    background-color: #f8f9fa;
    color: #495057;
    cursor: pointer;
    padding: 15px 20px;
    width: 100%;
    border: none;
    text-align: left;
    outline: none;
    font-size: 16px;
    font-weight: 600;
    border-radius: 10px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.collapsible:hover {
    background-color: #e9ecef;
}

.collapsible:after {
    content: '\002B'; /* Unicode character for "plus" sign (+) */
    font-weight: bold;
    float: right;
    margin-left: 5px;
    font-size: 20px;
    transition: transform 0.3s ease;
}

.active:after {
    content: "\2212"; /* Unicode character for "minus" sign (-) */
    transform: rotate(180deg);
}

.collapsible-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    background-color: white;
    border-radius: 10px;
    margin-bottom: 10px;
}

.collapsible-content.show {
    max-height: 2000px;
    padding: 20px;
    border: 1px solid #e9ecef;
}

/* 左右分布布局 */
.main-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.input-section, .result-section {
    background: white;
    border-radius: 15px;
    padding: 25px;
    border: 1px solid #e9ecef;
}

.section-title {
    font-size: 1.3em;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.text-area-container {
    position: relative;
}

.text-area-container textarea {
    height: 400px;
    font-size: 16px;
    line-height: 1.6;
    resize: none;
}

.result-textarea {
    background: white;
    height: 400px;
    resize: none;
}

.char-count {
    position: absolute;
    bottom: 10px;
    right: 15px;
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 5px 10px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 500;
}

.action-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.action-btn {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.result-placeholder {
    color: #6c757d;
    font-style: italic;
    text-align: center;
    padding: 40px 20px;
    border: 2px dashed #dee2e6;
    border-radius: 10px;
    background: #f8f9fa;
}

.copy-btn {
    background: #6c757d;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    margin-top: 15px;
    transition: all 0.3s ease;
    font-weight: 600;
}

.copy-btn:hover {
    background: #5a6268;
    transform: translateY(-1px);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.stat-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 15px;
    border-radius: 10px;
    text-align: center;
    border: 1px solid #dee2e6;
}

.stat-value {
    font-size: 1.5em;
    font-weight: 700;
    color: #2c3e50;
}

.stat-label {
    font-size: 0.9em;
    color: #6c757d;
    margin-top: 5px;
}

/* 响应式设计 */
/* 二维码悬停样式 */
.qr-trigger {
    position: relative;
    cursor: pointer;
    color: #FFFFFF;
    text-decoration: none;
    opacity: 0.8;
    display: inline-block;
}

.qr-popup {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 1000;
    margin-top: 5px;
    display: none;
    min-width: 170px;
}

.qr-popup img {
    width: 150px;
    height: 150px;
    display: block;
}

.qr-popup div {
    text-align: center;
    margin-top: 8px;
    font-size: 12px;
    color: #666;
}

.qr-trigger:hover .qr-popup {
    display: block !important;
}

/* 积分信息样式 */
.credits-info {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    font-size: 0.9em;
    color: #495057;
}

/* 登录页面样式 */
.login-required {
    text-align: center;
    padding: 60px 20px;
    max-width: 600px;
    margin: 0 auto;
}

.login-required h1 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 2.5em;
}

.login-required p {
    color: #6c757d;
    font-size: 1.2em;
    margin-bottom: 30px;
    line-height: 1.6;
}

.login-btn {
    display: inline-block;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    padding: 15px 30px;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1.1em;
    transition: all 0.3s ease;
}

.login-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(44, 62, 80, 0.4);
}

.back-link {
    margin-top: 30px;
    display: block;
    color: #6c757d;
    text-decoration: none;
    font-size: 0.9em;
}

.back-link:hover {
    color: #2c3e50;
}

/* 进度条样式 */
.progress-container {
    margin-top: 20px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
    border: 1px solid #e9ecef;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #2c3e50 0%, #3498db 50%, #2ecc71 100%);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 4px;
}

.progress-text {
    text-align: center;
    color: #495057;
    font-weight: 500;
    font-size: 14px;
}

/* 版权信息样式 */
.site-footer {
    background: transparent;
    padding: 30px 20px;
    margin-top: 40px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9em;
    line-height: 1.6;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-link {
    color: #007bff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: #0056b3;
    text-decoration: underline;
}

.footer-separator {
    margin: 0 10px;
    color: rgba(255, 255, 255, 0.3);
}

.footer-heart {
    color: #e74c3c;
}

.footer-version {
    background: rgba(40, 167, 69, 0.2);
    color: #28a745;
    padding: 2px 8px;
    border-radius: 8px;
    font-size: 0.8em;
    border: 1px solid rgba(40, 167, 69, 0.3);
}

@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        font-size: 0.8em;
        line-height: 1.8;
    }
    
    .footer-separator {
        display: block;
        margin: 5px 0;
    }
}
