/* 正则测试器样式 */
.regex-section {
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.regex-input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    transition: border-color 0.3s;
}

.regex-input:focus {
    outline: none;
    border-color: #667eea;
}

.test-textarea {
    width: 100%;
    min-height: 200px;
    padding: 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    line-height: 1.6;
    resize: vertical;
}

.test-textarea:focus {
    outline: none;
    border-color: #667eea;
}

.flags-group {
    display: flex;
    gap: 20px;
    margin-top: 10px;
}

.flag-checkbox {
    display: flex;
    align-items: center;
    gap: 5px;
}

.flag-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.flag-checkbox label {
    margin: 0;
    cursor: pointer;
    user-select: none;
}

.result-box.show {
    display: block;
}

.match-item {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 10px;
    margin-bottom: 10px;
}

.match-index {
    font-size: 12px;
    color: #667eea;
    font-weight: 600;
    margin-bottom: 5px;
}

.match-text {
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: #2d3748;
    background: #fef5e7;
    padding: 5px 8px;
    border-radius: 4px;
    display: inline-block;
}

.match-groups {
    margin-top: 8px;
    font-size: 13px;
    color: #718096;
}

.highlighted-text {
    background: #fef5e7;
    padding: 2px 4px;
    border-radius: 3px;
    font-weight: 600;
}

.examples-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 10px;
    margin-top: 15px;
}

.example-item {
    background: #f7fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 10px;
    cursor: pointer;
    transition: all 0.3s;
}

.example-item:hover {
    background: #edf2f7;
    border-color: #667eea;
}

.example-title {
    font-size: 13px;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 5px;
}

.example-regex {
    font-family: 'Courier New', monospace;
    font-size: 12px;
    color: #667eea;
}

@media (max-width: 768px) {
    .examples-grid {
        grid-template-columns: 1fr;
    }
}